07.08.2011, 13:50
I was editing a GF script. i want make Wanted player death , The system will Send some messages
to player.
case1:Player kill by Cop
case2:Player death(no-one kill),and Other player near by death player
case3:Player death
This is my code, case1 is work but other case is not work. How to fix?
to player.
case1:Player kill by Cop
case2:Player death(no-one kill),and Other player near by death player
case3:Player death
This is my code, case1 is work but other case is not work. How to fix?
Код:
public OnPlayerDeath(playerid, killerid, reason) { if (WantedLevel[playerid] >= 1) {//工作區域 if(PlayerInfo[killerid][pMember] == 1||PlayerInfo[killerid][pMember] == 2) { SendClientMessage(playerid, COLOR_LIGHTRED, " You are kill by cop'"); } else if(killerid == INVALID_PLAYER_ID) //else { for(new i = 0; i < MAX_PLAYERS; i++) { if(IsPlayerConnected(i)) { if(CrimInRange(30.0, playerid,i)) { SendClientMessage(playerid, COLOR_LIGHTRED, " you are die, Some player near you'"); } else { SendClientMessage(playerid, COLOR_LIGHTRED, " you are die"); } } } }