loop variables
#1

Hello

I have this code:

Код:
new a = 0;
while(a < 14)
{
	PlayerInfo[playerid][ContactNumber][a + 1] = PlayerInfo[playerid][ContactNumber][a];
	a++;
}
That code should do this:

ContactNumber[1] to ContactNumber[0]
ContactNumber[2] to ContactNumber[1]
ContactNumber[3] to ContactNumber[2]
etc.

But right now it`s doing like this:

ContactNumber[1] to ContactNumber[0]
ContactNumber[2] to ContactNumber[0]
ContactNumber[3] to ContactNumber[0]
Etc.


How can i resolve this problem?? (Look the bold things, there is the problem)
Reply


Messages In This Thread
loop variables - by Larry123 - 11.11.2012, 10:15
Re: loop variables - by Larry123 - 11.11.2012, 11:49
Re: loop variables - by Larry123 - 11.11.2012, 11:57
Re: loop variables - by Abhishek. - 11.11.2012, 13:49

Forum Jump:


Users browsing this thread: 1 Guest(s)