13.03.2014, 03:41
Код:
command(vip, playerid, params[]) { new message[128], string[128]; if(sscanf(params, "z", message)) { SendClientMessage(playerid, WHITE, "SYNTAX: /(v)ip [message]"); } else { if(VipEnabled == 1) { if(Player[playerid][CanUseVip] == 1 && Player[playerid][Authenticated] >= 1) { if(Player[playerid][vMuted] >= 1) { SendClientMessage(playerid, WHITE, "You have been muted from this channel by an admin."); } else { if(Player[playerid][VipRank] >= 1) { if(strlen(message) < 1) { SendClientMessage(playerid, WHITE, "SYNTAX: /(v)ip [message]"); } else { format(string, sizeof(string), "[V] {D1C221}%s(%d): {FFFFFF}%s", GetName(playerid), Player[playerid][VipRank], message); for(new i = 0; i < MAX_PLAYERS; i++) { if(IsPlayerConnectedEx(i) && Player[i][VipRank] >= 1 && Player[i][ToggedVIP] == 0) { SendClientMessage(i, VIP_CHAT, string); } } } } } return 1; } command(v, playerid, params[]) { new message[128], string[128]; if(sscanf(params, "z", message)) { SendClientMessage(playerid, WHITE, "SYNTAX: /(v)ip [message]"); } else { if(Player[playerid][VipRank] >= 1) { if(strlen(message) < 1) { SendClientMessage(playerid, WHITE, "SYNTAX: /(v)ip [message]"); } else { format(string, sizeof(string), "[V] {D1C221}%s(%d): {FFFFFF}%s", GetName(playerid), Player[playerid][VipRank], message); for(new i = 0; i < MAX_PLAYERS; i++) { if(IsPlayerConnectedEx(i) && Player[i][VipRank] >= 1 && Player[i][ToggedVIP] == 0) { SendClientMessage(i, VIP_CHAT, string); } } } } } return 1; }