Quote:
Originally Posted by PowerPC603
pawn Код:
new aMsg[35], Count = 0, i;
You forgot to define a new variable with name "i".
|
With foreach, you don't need to unless you use in the form of 'foreach(new i : Player)'. In this case, you can use 'foreach(Player, i)' and it will automatically define the variable. In the back of my mind, I remember someone calling this method outdated, but I have been too lazy to actually research it. I doubt it has any significant side effects because I have used that method in all of my codes. Others don't seem to encounter issues with it.
EDIT: By the way, the issue was the first 'if' statement was the only one being called in the loop. If he had of used 'else if' statements, this would of worked.