Script Loading and Command-line syntax checker

Old feature requests stored here for reference.
Locked
User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Script Loading and Command-line syntax checker

Post by John Adams » Thu Aug 14, 2008 7:38 am

LE,
How much of a load would it put on server/zone startup if we did not load spawnscripts (or others) "just because they exist"? I see some spawnscripts that do not belong to any NPC (there is no spawn_script set for their zonespawngroup) yet the server start is reporting errors in the scripts.
We know about the errors, but do not need the server telling us about them. :) Will this strain the startup much to check if it is assigned before parsing/processing it?
And secondly, can you whip up a quicky command-line "syntax checker" for our scripting, just for basic validation?
Thanks

User avatar
Scatman
Retired
Posts: 1688
Joined: Wed Apr 16, 2008 5:44 am
EQ2Emu Server: Scatman's Word
Characters: Scatman
Location: New Jersey

Re: Script Loading and Command-line syntax checker

Post by Scatman » Thu Aug 14, 2008 8:10 am

John Adams wrote: And secondly, can you whip up a quicky command-line "syntax checker" for our scripting, just for basic validation?
Pfft, my scripts always work first try! :P
/sarcasim off hehe

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Thu Aug 14, 2008 9:07 am

Heh, mine sure as hell don't!

LethalEncounter
Team: Zombie
Posts: 2717
Joined: Wed Jul 25, 2007 10:10 pm

Re: Script Loading and Command-line syntax checker

Post by LethalEncounter » Thu Aug 14, 2008 2:22 pm

John Adams wrote: And secondly, can you whip up a quicky command-line "syntax checker" for our scripting, just for basic validation?
Thanks
You mean like checking them on startup? :P
I can add an in game command that will check a file for errors if that is OK with you, but I would rather not remove the automatic loading of scripts upon world startup as it would create other problems.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Thu Aug 14, 2008 4:47 pm

As to the command-line checker, no. Smarty pants. I was hoping to not have to start the world completely and get a stream of bad syntaxes because I am such a proficient script writer. :| Maybe you do not see how we are planning to write many of our scripts, but the authors cannot see the syntax errors on TessEQ2, because they are editing/building scripts via my editor... this is why I asked, not because I think you have nothing better to do with your time. :D
But we can move on... it's not that critical. Maybe I can build it into the editor.
As for loading all scripts at startup... I didn't know it did that. I thought it only read the files when they were needed. How is this going to effect server over-head once 10,000 scripts are all loaded at once? If you say negligible, I believe you. Just checking.

LethalEncounter
Team: Zombie
Posts: 2717
Joined: Wed Jul 25, 2007 10:10 pm

Post by LethalEncounter » Thu Aug 14, 2008 5:40 pm

Unless all 10,000 are being used at the same time I couldnt see it having a problem as the scripts are just loaded into memory and called when needed. Most scripts are going to be fairly simple and be 4 KB or less. For 10,000 scripts that is still only 40 MBs of RAM that is needed.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Thu Aug 14, 2008 5:45 pm

I hate it when you use math against me!
;)
I gotcha now, thanks.

Locked

Who is online

Users browsing this forum: No registered users and 0 guests