create many string with same var name - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: create many string with same var name (
/showthread.php?tid=512723)
create many string with same var name -
carl0o0s - 12.05.2014
hello i need 10 or more string like
i use it like this
Код:
dini_Get(FileStr, "Name0",str[0],sizeof(str[0]))
but gives errors
Код HTML:
: error 001: expected token: "]", but found "-integer value-"
: warning 215: expression has no effect
: error 001: expected token: ";", but found "]"
: error 029: invalid expression, assumed zero
: fatal error 107: too many error messages on one line
i cant do like this , i dont want like this
Код:
str0[128];
str1[128];
str2[128];
.
.
.
Re: create many string with same var name -
Tingesport - 12.05.2014
You need to show us the lines where the errors occur?
Re: create many string with same var name -
Scottas - 12.05.2014
you can use '128' instead of 'sizeof(str[0])'
Re: create many string with same var name -
Beckett - 12.05.2014
I guess what he meant from that [0] is the array not the size.