
02-20-2003, 01:56 AM
|
|
Cucumber NPC
|
 |
Join Date: Jan 2003
Posts: 141
|
|
|
Graal C++ will be better for datastorage, but in the mean time, I have to explain that GScript Variables cannot be strings... Strings are seperate.
Basically an array of string values is a string, delimited by commas or spaces (quotes will group strings, so you can include commas and spaces, eg string1=cat,dog,chicken,Super Cow; would be a string array of 5 strings, where as string2="cat,dog",chicken,"Super Cow"; would be 3)
other than that arrays are pretty much the same as C++, they just dont have to be declared, and they can be resized with setarray.
so
setarray array,3;
array[0] = 1;
array[1] = 2;
array[2] = 3;
and
array={1,2,3};
are both perfectly legal, although the latter is prefered (the first one resembles VB, and VB is posible the worst language X_X) |
__________________
subliminal message: 1+1=3
|
|
|
|