16.09.2012, 10:50
If you'd follow the code path, you'd spot the obvious error very easily:
- countn is decreased from 12 to 11.
- Reached if statement: if (11 >= -1) returns true
- KillTimer
You want point two to return false. So change the operator around from >= to <=.
pawn Код:
countn[playerid]--;//The timer decreases from 10 to 0
if(countn[playerid]>=-1)
{
KillTimer(timer[playerid]);
//code[What your timer actually does]
}
- Reached if statement: if (11 >= -1) returns true
- KillTimer
You want point two to return false. So change the operator around from >= to <=.