SA-MP Forums Archive
Loop - 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: Loop (/showthread.php?tid=568886)



Loop - cnoopers - 26.03.2015

Hi i got
Код:
vCar[playerid][10]
and i want to loop all slots, i mean
Код:
for(new i = 0; i < vCar[playerid]; i++)
but there is problem about array vCar, second size.
How to do it?


Re: Loop! [REP] - SickAttack - 26.03.2015

pawn Код:
for(new i = 0; i < 10; i++)



Re: Loop! [REP] - CalvinC - 26.03.2015

pawn Код:
for(new i = 0; i < sizeof(vCar[][]) i ++)
https://sampwiki.blast.hk/wiki/Keywords:Operators#sizeof