09.08.2011, 11:04
hey, I made an anti-spawnkill script, very small.
The problem is when I spawn the timer will just say
"spawn protection over" so the first bit doesn't work.
it just goes straight to the timer, does anyone know the problem?
I tried thinking about it last night and had a few ideas but they probably wont work and i've already tried alot of other things actually.
I thought it might be because my script is in a filterscript.
But that can't be can it ? as I have other functions under there which work perfectly.
and the timer works..
Before you ask , yes I do have the variable
AntiSK.
Any idea of the problem ?
Thanks in advance.
pawn Код:
//public OnPlayerSpawn(playerid)
GameTextForPlayer(playerid,"~G~spawn protection",1000,5);
SetPlayerHealth(playerid,INFINITE);
AntiSK[playerid] = SetTimerEx("SPOver",1,10000,"d",playerid);
return 1;
}
forward SPOver(playerid);
public SPOver(playerid)
{
GameTextForPlayer(playerid,"~R~spawn protection over",1000,5);
SetPlayerHealth(playerid,100);
KillTimer(AntiSK[playerid]);
}
"spawn protection over" so the first bit doesn't work.
it just goes straight to the timer, does anyone know the problem?
I tried thinking about it last night and had a few ideas but they probably wont work and i've already tried alot of other things actually.
I thought it might be because my script is in a filterscript.
But that can't be can it ? as I have other functions under there which work perfectly.
and the timer works..
Before you ask , yes I do have the variable
AntiSK.
Any idea of the problem ?
Thanks in advance.