Code: Select all
if(strcmp(cmd, "/clear", true) == 0)
{
if(PlayerInfo[playerid][pMember] == 9 || PlayerInfo[playerid][pMember] == 10 || PlayerInfo[playerid][pMember] == 11 || PlayerInfo[playerid][pMember] == 12 || PlayerInfo[playerid][pMember] == 13)
{
new giveplayer[MAX_PLAYER_NAME],giveplayerid,sendername[MAX_PLAYER_NAME],string[256];
if(GetVehicleModel(GetPlayerVehicleID(playerid)) != 596) return SendClientMessage(playerid, COLOR_GRAD1, "Вы не в полицейской машине");
tmp = strtok(cmdtext, idx);
if(!strlen(tmp)) return SendClientMessage(playerid, COLOR_WHITE, "Введите: /clear [id]");
giveplayerid = ReturnUser(tmp);
if(IsPlayerConnected(giveplayerid))
{
if(giveplayerid != INVALID_PLAYER_ID) { } else {SendClientMessage(playerid, COLOR_GREY, "Человек не найден!");}
{
if (ProxDetectorS(5.0, playerid, giveplayerid)){} else { SendClientMessage(playerid, COLOR_GREY, "Человек далеко от вас!"); return 1; }
if(giveplayerid == playerid) { SendClientMessage(playerid, COLOR_GREY, "Вы не можете снять розыск себе!"); return 1; }
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "Вы сняли уровни розыска у %s.", giveplayer);
SendClientMessage(playerid, COLOR_YELLOW, string);
format(string, sizeof(string), "Офицер %s снял с Вас уровни розыска.", sendername);
SendClientMessage(giveplayerid, COLOR_YELLOW, string);
PlayerInfo[giveplayerid][pZvezd] = 0;
SetPlayerWantedLevel(giveplayerid, 0);
}
}
}
return 1;
}
Автор - Good_wilson