Spawn/Death system - When a zombie kills a human he doesnt spawn as a zombie
#6

Quote:
Originally Posted by »Julian™«
Oh sorry mate i didnt know that you didnt understand 100% perfect english.
What i ment is that code you gave me will work BUT then if a civilian kills me he'll make me spawn into zombie and i dont want that . I only want zombie to make me spawn into a zombie after hes killed me..
Ok, I think I get it now.

pawn Код:
public OnPlayerDeath(killerid,playerid,reason)
{
if(gTeam[playerid] == 5)//Zombies id
{
gTeam[playerid] = 5; //Makes your status to zombie.
        PlayerInfo[playerid][pTeam] = 5;
        SetPlayerColor(playerid,COLOR_RED);
        SetPlayerWeapons(playerid);
        format(string, sizeof(string), "%s spawned as a zombie", name);
        SendClientMessageToAll(COLOR_RED, string);
}
else if(gTeam[killerid] == 1) //Civillian team
{
gTeam[playerid] = 1;
SpawnPlayer(playerid);
}}
Not sure, but hopefully that should work...
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)