[QUOTE=Downsider;66050]His idea works just fine, just not as good as our ideas. His would be restricted by a 230-something character cap and the syntax is ugly, while ours has much prettier syntax and a 13kb limit instead of 230 byte limit.[/QUOTE]
Definitely not my cleanest code, 'twas a proof of concept piece.
Didn’t realize that client strings have such a small cap. Are server strings that limited as well?
That limitation is only if it’s sent over the network by the conventional means. The weapon workaround bypasses that limit entirely and gives it a much greater range. Hell, the range is so large that I can’t even test if it’s greater than 65536, because that’s the maximum amount of characters on a line in the Graal editor and I’m too lazy to append strings or open it in notepad.
Thanks. I’ll have to keep this in mind when I’m working on my server. I’ve had a few passing ideas over the last month or so but they’ve all required hefty use of strings. Guess I’d better start re-thinking some stuff
Uhhh I spose tokens would be the most manageable way. To be honest I didnt really think of how It would be stored. But yer I think tokens would be the best way. But then… what defines a token bla bla bla. Downsider, help!!! Provided you could somehow bypass string caps I would say length strings and a new string for each line. Or /n. Do either tokens or strings and Ill be fine.
See, the thing is, this feature request takes some thinking. And I really don’t feel like thinking right now. Any way you look at it, it is going to be a pain in the ass. You have no clue how long it will take for the data to reach you. It could be in 0.1 seconds. Or 3 seconds. You have to think about how to notify the script that the data arrived. How to pass the data onto the script. It is more complex than I can bother devoting time to at the moment.
Fair enough, Ill just look for alternatives like appending npc code to nw files o.0 I dont know if the append trigger hack will let me but we shall see!
[QUOTE=Nalin;67326]See, the thing is, this feature request takes some thinking. And I really don’t feel like thinking right now. Any way you look at it, it is going to be a pain in the ass. You have no clue how long it will take for the data to reach you. It could be in 0.1 seconds. Or 3 seconds. You have to think about how to notify the script that the data arrived. How to pass the data onto the script. It is more complex than I can bother devoting time to at the moment.[/QUOTE]
Bumping this thread because I want it done, I would like it read line by line. So maybe you could have triggeraction 0,0,gr.getline,“file.txt”,linenumber;
and it can just scan the file and read it line by line from which its put into an array of strings. Each line is one element of the array.