14.12.2014, 01:20
PHP код:
CMD:vipcolor(playerid, params[]) {
if(PlayerInfo[playerid][pDonator] >= 1)
{
if(GetPVarInt(playerid, "EventToken") == 1)
{
SendClientMessage(playerid, COLOR_WHITE, "You can't use this command while in an event.");
}
if(IsACop(playerid) || PlayerInfo[playerid][pFaction] == 3 || PlayerInfo[playerid][pLeader] == 3 || PlayerInfo[playerid][pFaction] == 9 || PlayerInfo[playerid][pLeader] == 9 || PlayerInfo[playerid][pFaction] == 6 || PlayerInfo[playerid][pLeader] == 6)
{
SendClientMessage(playerid, COLOR_WHITE, "You can't use this command while in a Faction.");
return 1;
}
if(PlayerInfo[playerid][pVIPDuty])
{
PlayerInfo[playerid][pVIPDuty] = 0;
SetPlayerColor(playerid, 0xFFFFFF00);//00=Fully Transparent. AKA Level 0 Visibility
SendClientMessage(playerid, COLOR_WHITE, "You have hidden your VIP color.");
}
else
{
PlayerInfo[playerid][pVIPDuty] = 1;
SetPlayerColor(playerid, 0xA2E3E8AA);//AA=Level 10 Visibility.
SendClientMessage(playerid, COLOR_WHITE, "You have shown your VIP color.");
}
}
return 1;
}