30.10.2015, 03:52
I've been really curious to see if this is an efficient way to see if a timer is active, or not. Because I'm using it under OnPlayerGiveDamage and it works fine for killing variables. However, when I used it for a splint system (I was detecting if the bandage timer was running, that way the player couldn't use a splint) it didn't work for detecting that.
Example:
^ This code does not work, however:
Seems to work fine.
Example:
pawn Код:
if(TIMER_BANDAGE[playerid])
{
SCM(pid,COLOR, "You can't use this with the bandage timer running");
return 1;
}
pawn Код:
if(TIMER_FISH[damagedid] || TIMER_PICKUPLOOT[damagedid] || TIMER_COOKING[damagedid] || TIMER_FIRE[damagedid]