Timer problem
#1

helo all
my problem is that i've make a timer but it doesn't work
can some one help me for that pls
Код:
forward infectedtimer(playerid);


public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
    if((newkeys & KEY_FIRE) && (team[playerid] == 2))
	{
		if(GetDistanceBetweenPlayers(playerid,target) <= 1)
		{
		    SetTimer("infectedtimer", 5000, 1);
                 }
         }
}


public infectedtimer(playerid)
{
    new Float:hp;
    if(team[playerid] == 2)
		{
		    GetPlayerHealth(playerid,hp);
	            SetPlayerHealth(playerid, hp-7);
	            SendClientMessage(playerid,GREEN,"you turn to a zombie.");
 		}
    return 1;
}
Reply


Messages In This Thread
Timer problem - by Amine_Mejrhirrou - 12.01.2011, 07:20
Re: Timer problem - by Kyosaur - 12.01.2011, 07:23
Re : Timer problem - by Amine_Mejrhirrou - 12.01.2011, 10:40
Re: Timer problem - by xxmitsu - 12.01.2011, 10:42
Re : Timer problem - by Amine_Mejrhirrou - 12.01.2011, 21:42
Re: Re : Timer problem - by Kyosaur - 12.01.2011, 21:46
Re: Timer problem - by ikkentim - 12.01.2011, 21:59
Re : Timer problem - by Amine_Mejrhirrou - 13.01.2011, 06:33
Re : Timer problem - by Amine_Mejrhirrou - 13.01.2011, 21:00
Re : Timer problem - by Amine_Mejrhirrou - 13.01.2011, 22:34

Forum Jump:


Users browsing this thread: 2 Guest(s)