About cycles.
#1

Hi,

If i do a cycle throw 500.

Код:
for(new i; i < 500; i++)
{
}
When player spawn, and then other player spawn, and for first player cycle not end all, and then will start new cycle? i have mean maybe new i; use is not safe? maybe will be better to create:

Код:
new Cycle[ MAX_PLAYERS ];

for(Cycle[ playerid ] = 0; Cycle[ playerid ] < 500; Cycle[ playerid ] ++)
?
Reply
#2

The variable will be 'forgotten' when it is called again. It won't be re-used. It's nothing to worry about.

P.S. It's called a loop, not a cycle.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)