
12-22-2005, 07:49 AM
|
|
Former Classic Staff
|
 |
Join Date: Dec 2002
Location: Northwest Vermont
Posts: 1,452
|
|
Adding to String List Implicitly
|
When you try to save a client or server flag as an array, it removes all values of 0.
Let's say you wanted to save an array: clientr.quest_dungeon = {1,0,0,0,0};
It would save as clientr.quest_dungeon=1.
clientr.quest_dungeon[2] would still return 0 as it doesn't exist.
However, you can't say clientr.quest_dungeon[2] = 1;
The flag saved removing the false values implicitly, but you can't add a flag value at an index implicitly, and that presents quite an obstacle in some cases.
You can plan on how many spaces in an array your quest would use, but if they're deleted for being 0, it's no use. Probably would have been better to use separate flags while cluttering the flag list.
I guess I can avoid this by doing string = "1,0,0,0,0" |
Last edited by jake13jake; 12-22-2005 at 10:34 AM..
|
|
|