Author Topic: Anti-spawn kill Sux...  (Read 2260 times)

0 Members and 2 Guests are viewing this topic.

Offline [Tkiller]

  • Street Thug
  • *
  • Posts: 15
    • View Profile
Anti-spawn kill Sux...
« on: February 28, 2012, 10:54:13 am »
I make anti spawn kill but iam failed,that's why i post it here so one can help me...

[pawn]SetTimer("AntiSpawnkill",5000,0);[/pawn]



public onplayerspawn i put this
[pawn]   }
   else SetPlayerMoney( playerid, 0 );
    SetPlayerHealth(playerid, 9999);
    SendClientMessage(playerid, RED, "[INFO]:You have 5 seconds of Anti-Spawnkill protection");
    SetTimer("AntiSpawnkill",5000,0);
       return 1;
}[/pawn]

in function i put that to reset player health to 100 after time over
[pawn]public AntiSpawnkill(playerid)
{
    SetPlayerHealth(playerid, 100.0);
    SendClientMessage(playerid, RED, "[INFO]:Anti-Spawnkill protection over, you are on your own now");
    return 1;
}[/pawn]



So please check it,or i want that on spawn kill the player is drowned so what i do....

Help...

Offline Fuzzy168

  • VC:MP Veteran
  • *****
  • Posts: 729
  • Programming since 2011
    • View Profile
Re: Anti-spawn kill Sux...
« Reply #1 on: February 28, 2012, 05:09:49 pm »
You can't set timer to a player!!
I'm beginning to feel like a Lag God, Lag God