Jump to content

Gttsu

Members
  • Posts

    7
  • Credits

  • Joined

  • Last visited

  • Feedback

    0%

Posts posted by Gttsu

  1. 19 minutes ago, Anarchy said:

    meh extra scripting engine isn't really necessary on l2npc, l2server scripting engine though that'd be where it's at, event systems and all that shit yo

    Dont know

    • don`t exists full compiler
    • standard ai.obj byte code not optimized
    • Every existing compiler don`t support HLL abstraction, only: for, while, switch standard statements.
    • Can`t allocate some custom object or structure
    • Problem with variables local and globals
    • Problem with adding extra native method or events
    • Can`t add inner methods
    • ... etc

    so on and so on

  2. Hello everyone. On current moment i`m develope new script engine for PTS server. Attach mono engine to the L2NPC server

     

    MakerScript example

    Spoiler
    
    using System;
    
    public class SpecialBossSpawn : MakerScript
    {
    	public override void onStart(MakerEvent e)
    	{
    		NpcMakerEx ex = e.myself;
    		e.gg.SendMakerScriptEvent(ex, 1, 2, 3);
    		for (int i = 0; i < ex.def_count; i++)
    		{
    			NpcSpawnDefineEx def = ex.GetSpawnDefine(i);
    			Logger.Info($"def {def.name} {def.dbname}");
    			if(def.has_dbname != 0)
    				def.LoadDBNpcInfo(1010);
    		}
    	}
    
    	public override void onDBNpcInfo(MakerEvent e)
    	{
    		Logger.Info($"Time {e.loaded_def.dbname} {e.loaded_def.respawn_rand} {e.loaded_def.respawn_time}");
    		DBNpcInfo info = e.record0;
    		if (info.is_alive == 0)
    		{
    			Logger.Info($"onDBNpcInfo dead {info.death_time}");
    		}
    		else
    			e.loaded_def.SpawnEx(1, 0, info.x, info.y, info.z, 0, info.hp, info.mp, info.db_value);
    	}
    
    	public override void onNpcCreated(MakerEvent e)
    	{
    		e.gg.Announce($"onNpcCreated {e.created_def.dbname}");
    	}
    
    	public override void onNpcDeleted(MakerEvent e)
    	{
    		Logger.Info("onNpcDeleted ");
    	}
    
    	public override void onScriptEvent(MakerEvent e)
    	{
    		Logger.Info($"SciptEvent {e.script_event_arg1} {e.script_event_arg2} {e.script_event_arg3}");
    	}
    }

    5a4af4947864a_PTSairesult.thumb.jpg.aaee24a3fa07e1125e3793d13b44e761.jpg

     

    Allowed using old and new script engine.

     

    Profit: 

    • Using .net frameworks
    • Easy developing. Using any program language supported mono.
    • Easy adding new features
      • add new methods
      • add new fields
      • add new script events (for some need extend l2server)
    • Better performance. Mono support JIT compilation.

     

    Now i`m testing technology on PTS C4, after will be add support for GF.

    In future will be work not only on l2npc.

     

    Planning for sell

     

    I will listen to any suggestions

  3. Version 0.1
    Support only interlude version
    For using need java version 1.8
     
    Properties(compile.property):
    xdat.original=target/interface.xdat
    Source of decompilation(from xdat to xml files)
    xdat.src = target/xml
    folder where creating decompile xml files.
    xdat.target = C:/Games/Interlude/system/interface.xdat
    Target of compilation from xml files to xdat.
     
    How to use
    Archive contains two bat files compile.bat and decompile.bat.
    compile.bat - compile from xml files to xdat
    decompile.bat - decompile from xdat to xml files
     
    Recommendation for use:
    Use client folder for compilation, after compile, use ingame command ///reloadui(needs admin rights)
     
    Sample

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <L2UI>
        <Window parent="undefined" backTex="undefined" script="AbnormalStatusWnd" state="GamingState" frame="1" resizeframe="-1" iconable="-1" hidden="1" alwaysFullAlpha="1" stuckable="1" title="2" savePosition="1" saveSize="-1" draggable="-1" hookKeyInput="-1" WorkingConfiguration="Game">
            <DefaultProperty name="AbnormalStatusWnd" extend="undefined" alwaysOnTop="-1" alwaysOnBack="-1" parentName="" virtual="-1" passThrough="-1" nWindowStyle="0" sized="1" isAbsolute="1" hasPosition="1">
                <RelativeSize relativeTo="" widthRate="0.0" heightRate="0.0" offsetWidth="0" offsetHeight="0"/>
                <AbsoluteSize width="38" height="26"/>
                <Position relativePoint="TopLeft" anchorPoint="TopLeft" relativeTo="" offsetX="176" offsetY="0" anchored="0"/>
                <Tooltip type="undefined" text="-9999"/>
                <TabOrder preOrder="undefined" postOrder="undefined"/>
            </DefaultProperty>
            <Drawer ownerWindow="" direction="None" offset="369129583" directionFixed="300419844"/>
            <ShowHideAnim>
                <ShowAnim type="None" seconds="1.0092554E7" direction="None"/>
                <HideAnim type="None" seconds="-9999.0" direction="None"/>
            </ShowHideAnim>
            <Frame size="Big" direction="Left" exitbutton="0" expandbutton="0" expandOrgHeight="0" expandExpHeight="0"/>
            <Iconable iconName="undefined" tooltipIdx="-9999"/>
            <ResizeFrame x="-9999" y="-9999" width="-9999.0" height="-9999.0" direction="None" maxIncrease="469988021"/>
            <StatusIconCtrl noClip="0" noTooltip="0">
                <DefaultProperty name="StatusIcon" extend="undefined" alwaysOnTop="-1" alwaysOnBack="-1" parentName="AbnormalStatusWnd" virtual="-1" passThrough="-1" nWindowStyle="0" sized="1" isAbsolute="1" hasPosition="1">
                    <RelativeSize relativeTo="" widthRate="0.0" heightRate="0.0" offsetWidth="0" offsetHeight="0"/>
                    <AbsoluteSize width="26" height="26"/>
                    <Position relativePoint="TopLeft" anchorPoint="TopLeft" relativeTo="" offsetX="12" offsetY="0" anchored="0"/>
                    <Tooltip type="AbnormalStatus" text="-9999"/>
                    <TabOrder preOrder="undefined" postOrder="undefined"/>
                </DefaultProperty>
            </StatusIconCtrl>
        </Window>
    </L2UI>
     

     
     

     

    url

×
×
  • Create New...