I'm not sure there is, though I remember Onasha reported making a several thousand word script and was so long that it either caused her browser to crash when trying to upload it to the NPC, or just froze when she tried talking to it, not sure which.
Yes, I remember Onasha telling me she wrote a script 20-MS Word-page long and not working.
Now, the problem with turning a long script into smaller segments is that one has to rework from scratch for each segment (i.e. each custom NPC) and check all the references, etc.
By knowing the character limit, one could plan ahead and organize each segment at best.
However, even if sometimes it is easy to cut a script in segments because the whole subject is divided in sections, there could be cases where it is more difficult to divide the same subject among two or more custom NPCs (segments).
I suppose the text of the script is saved in a database field. Those who have access to the SWC database could easily check the parameters of the SQL field (http://help.scibit.com/mascon/masconMySQL_Field_Types.html).
Of course, I could find out myself by experimenting and coding a fake script of different lengths, but I don't want the SWC server to crash to get the info. :-)
Of course writing shorter scripts would work, but to try to make things clean, can one knows what is the character limit, and what "shorter than" means in practice when dealing with scripts?
A "shorter script" implies also the addition of another custom NPC (to get the same result with a long script, I need two NPCs instead of one) which costs CPs, and therefore a planning beforehand is necessary.
I think knowing the character limit does not pose any security issues, just add useful information for those (a few, I know) interested in writing scripts.
For the benefit of all those who are curious and searched the forums for an answer to my same question, I can tell that I have written a fake script that - according to MS Word word count (unreliable) is long as follows:
* 937,710 characters including spaces
* 787,978 characters without spaces
* 165,708 words
* 484 pages
*16,646 paragraphs
* 24,602 rows.
The script was saved successfully. I stopped testing because I don't want to crash anything, just knowing if quite long scripts can be written. Yes, it is possible. Well over the 65,535 limit.
Yes, I run it and I had all differently named blocks, but of course I didn't set the references to go through all the blocks, and the run was limited to a few blocks.
I think that anyone can be sure to have plenty of space to write and feel relieved. :-)
EDIT: Wait, do you mean that the problems could be during the running? I don't think there would be, when saving it parses the script and points out possible errors. Therefore if he can parse the whole script before saving, it should be able to manage the script while running afterwards.
Edited By: Ruben Wan on Year 13 Day 198 15:02 ____________
No, the issue was that when Onasha went to run the script, because it was so big it caused the window to freeze up or otherwise not load the script. She managed to save it just fine I believe.