04.07.2014, 14:07
Stop the loop at end of checks? e.g
I don't know if that really helps, but what I see your problem is you didn't end the loop when the player has found the right house.
pawn Код:
for (new i; i < 1000; ++ i)
{
if (IsPlayerConnected(i))
{
if (cool[i] == true)
{
if (hax0r[i] == false)
{
DoSomething();
break; // End the loop as player is found
}
else
{
Ban(i);
continue; // Skip current "i" to continue looping to search the correct player.
}
}
else
{
cool[i] = true;
continue; // Skip current "i" to continue looping to search the correct player.
}
}
return 1;
}