Jump to content

Gracia Final Ai Compiler (Nasc) By L2Shrine.com


Recommended Posts

Hi everyone,

 

I've made a brand new AI compiler for Gracia Final based servers (based on l2npc.exe)

 

Download: http://download.l2shrine.com/compiler.zip

Source: https://bitbucket.org/l2shrine/extender-public (the compiler is part of MyExt64 open source extender)

 

Some basic info

  • it uses the official NASC syntax for Gracia Final, so
  • use class a : b, not class 0 a : b and define set_compiler_opt base_event_type(@NTYPE_NPC_EVENT) or set_compiler_opt base_event_type(@NTYPE_MAKER_EVENT)
  • use UTF-16LE input files
  • use myself.something, not myself::something
  • it should work the very same way as AdvExt compiler including all new functions, variables, handlers and types they've added
  • it also accepts PSTATE_, MSTATE_ ... constants
  • if you run l2npc.exe without command line parameters, it runs as a standard l2npc.exe (with MyExt64 extender)
  • if you run l2npc.exe with command line parameters, it runs as a compiler

Enjoy!

Edited by eressea
  • Thanks 1
  • Upvote 3
Link to comment
Share on other sites

I've added stubs for all new AdvExt functions: https://bitbucket.org/l2shrine/extender-public/commits/746b743bba9d2bb46bc74dc45a1317fa7129ab39

Next step is adding stubs for new AdvExt handlers and variables, then it should compile with 100% compatibility with AdvExt! :)

 

EDIT: Handlers added, now just those variables... It will be bit harder than handlers :)

Edited by eressea
Link to comment
Share on other sites

Thanks you for this awesome share.

For use your compiler i need to launch  server normally or can i compile only with l2npc and command ?

 

if i run l2npc without command  l2npc dont load npcs only show window  with help about syntax usage

Link to comment
Share on other sites

Thanks you for this awesome share.

For use your compiler i need to launch  server normally or can i compile only with l2npc and command ?

 

if i run l2npc without command  l2npc dont load npcs only show window  with help about syntax usage

 

Hi, you don't need have the server running (but it can run, it doesn't matter), just run (in command line):

 

l2npc.exe file.nasc

 

and it should compile. Just make sure you're in the right folder etc.

 

 

Also some news, I've uploaded new version of the compiler http://download.l2shrine.com/compiler.zip and now it should be FULLY COMPATIBLE WITH ADVEXT. I've added all functions, handlers, CreatureData2 type and all new variables, so have fun :) The source is still on bitbucket https://bitbucket.org/l2shrine/extender-public

Link to comment
Share on other sites

Fantastic job eressea, I missed your PM cuz I was away for the holidays but looks like you got it on your own, awesome :D I got a new gf bug for you ima stick over in your other topic

Link to comment
Share on other sites

I've just found and fixed one "small" bug https://bitbucket.org/l2shrine/extender-public/commits/9d2273e5c373eda9b087ef70f78999d42fc30ed8

Please download compiler again to get the newest fixed version http://download.l2shrine.com/compiler.zip

Link to comment
Share on other sites

Thanks you  compiler work for me, but only if i have l2server running else l2npc crashed  and if y want run normal npc server i have add command "-c" else show compile help windows.

Here is linerror dump:

 

http://www72.zippyshare.com/v/wYrwEMTa/file.html

 

Edited by zconll
Link to comment
Share on other sites

Thanks you  compiler work for me, but only if i have l2server running else l2npc crashed  and if y want run normal npc server i have add command "-c" else show compile help windows.

Here is linerror dump:

 

http://www72.zippyshare.com/v/wYrwEMTa/file.html

 

Try it now (download again http://download.l2shrine.com/compiler.zip)

When running npc without parameters, the help shown is just info on how to invoke the compiler - you can ignore it.

Link to comment
Share on other sites

New dll work fine without l2server now, but if i want run normal npc server show popup how compile but never  to begin npc server load.

for start npc normal npc server i need to run batch file (l2npc.exe) and then work how normal npc server.

Edited by zconll
Link to comment
Share on other sites

New dll work fine without l2server now, but if i want run normal npc server show popup how compile but never  to begin npc server load.

for start npc normal npc server i need to run batch file (l2npc.exe) and then work how normal npc server.

 

I'm not sure I understand well - I'm running l2npc.exe without arguments (to run l2npc as npc daemon) and it runs fine...

 

Can you show some screenshot where it's visible where it's stuck? Thanks!

Link to comment
Share on other sites

Sorry for my english, here you have screenshott when i am to running  l2npc server for load npcs (without arguments).

I am doing double click on l2npcmyext64.exe and then happen it.

 

http://www66.zippyshare.com/v/q2FOTSji/file.html

 

Bt iif i run from command prompt then l2npc work (load ai.obj and npcpos.txt).

Edited by zconll
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



  • Posts

    • First of all you need to understand that there is no ultimate guide "how to", server sources has some similar things but it also has some differences that you will be hard to adapt without skills. Saying skills I mean not only java skills, the most required ones is understanding lineage 2 core processes task-scheduling and client-server networking  communication.   You need to: -learn some core information about Java language -learn some lessons about java programming to understand what is java classes, packages, imports etc. -learn how to edit java source code with some IDE (one of them eclipse) -learn how to compile java source code (with ant for example)   Then for the best way you need to get most popular sources form thread above and try to integrate that scripts like for native, I mean as I can see that mostly provided scripts are for acis, so take acis sources and ty to integrate or find something directly for mobius etc.   Doing all this you will need to understand three things First - How player communicates with server What is action bypasses (when player clicks some link in HTML) and where your server handles it (find RequestBypassToServer packet and learn how its working) What is user/voice/admin commands (when player writes some in chat with "." or "/" or "//") and where your server handles it (find VoiceCommandHandler and learn how its working)   Second - How server doing core logic If addon has some logic that not depends on direct user action it will mostly required some scheduled task (some logic that will be runs periodically), so you need to  find some ThreadPoolManager and Runnable usages and understand how its working Maybe you will need some data storage, so you will need to find how server working with database (try to find how server executes SQL requests, SELECT, INSERT, UPDATE)   Third - How server communicates back to player You need to find how server sends packets to player, find some sendPacket() method and its usages, for example Say2 packet (its when server sends some chat message to client) etc   Unfortunately there is no easy way, some sources will be easier to adapt cuz of similarity between sources some will be harder  
    • I'm starting on this. I know enough to be able to make my website with php, html and css. I also know linux to maintain a server but I don't know anything about java and its compilation.   Can anyone help me learn how to add this type of code to a server? I'm using L2jMobius, but I have no idea or concept of how to start to add codes. Do I need to add it before compiling? Can it be added once the datapack is compiled? How do I know where I should add it?   I would appreciate any kind of information, please!   I wanna to add some codes nex collection, like TvT events, etc:     See you guys and thanks for all the help are in the forum!
    • it says standard here , that is , without protection , it is made from another source code , the goal of my dll is just to kill the game guard , the hwid code is cut out there , since no one uses the old protections on projects - but your answer is clear   ps then choose another option for yourself )
    • remove  DisableGameGuard() from code at all.  compile and send here new dsetup.dll  
    • I shared my dsetup with the HWID system but I can't log in that Error. When I put yours it gave this error.
  • Topics

×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock