pawn Код:
CMD:wh(playerid, params[])
{
if(IsPlayerConnected(playerid))
{
if(!PlayerInfo[playerid][pLogged]) return SendClientMessage(playerid, COLOR_WHITE, "SERVER: You need to be logged in to excute a command.");
if(PlayerInfo[playerid][pAdmin] < 1) return SendClientMessage(playerid, COLOR_WHITE, "SERVER: You are not an admin.");
if(sscanf(params, "u", playerb)) return SendClientMessage(playerid, COLOR_WHITE, "USAGE: /wh [id]");
new message[128];
if(GetPlayerWeapon(playerb) != PlayerInfo[playerb][pWeapon1]) return SendClientMessage(playerid, COLOR_YELLOW, "Anti-WH: Weapon is not in Slot 1.");
if(GetPlayerWeapon(playerb) != PlayerInfo[playerb][pWeapon2]) return SendClientMessage(playerid, COLOR_YELLOW, "Anti-WH: Weapon is not in Slot 2.");
if(GetPlayerWeapon(playerb) != PlayerInfo[playerb][pWeapon3]) return SendClientMessage(playerid, COLOR_YELLOW, "Anti-WH: Weapon is not in Slot 3.");
format(message, sizeof(message), "Anti-WH: %s was checked for Weapon Hacks.", ReturnPlayerName(playerb));
SendClientMessageToAll(COLOR_YELLOW, message);
}
return 1;
}