error 001: expected token: "]", but found "-identifier-" - 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: error 001: expected token: "]", but found "-identifier-" (
/showthread.php?tid=606234)
error 001: expected token: "]", but found "-identifier-" -
TheSimpleGuy - 01.05.2016
Code:
for(new i = 0; i < sizeof(cInfo[][Weapon][]); i++) print(i);
I do not understand... I am accessing an array inside an array of an enum.
Re: error 001: expected token: "]", but found "-identifier-" -
Konstantinos - 01.05.2016
You can't get the size of arrays inside an enumerator using sizeof, the only way is to specify it yourself.