02.08.2009, 18:39
Then it should be like this:
If the dead player is president and the killer is not a terrorist then the message will say he was killed by accident. Untested.
pawn Код:
public OnPlayerDeath(playerid,killerid,reason)
{
if(gTeam[playerid] == TEAM_PRES && gTeam[killerid] != TEAM_TERR)
{
new string[128];
new pname[MAX_PLAYER_NAME];
GetPlayerName(playerid,pname,sizeof(pname));
format(string, sizeof(string),"%s(%d) Is No Longer President",pname,playerid);
SendClientMessageToAll(COLOR_TEAMYELLOW, string);
GameTextForAll("~b~The President Has Been Killed In An Accident!", 8000, 5);
}
return 1;
}