01.04.2012, 17:08
Try this, you had an unmatched closing paranthesis.
pawn Код:
CMD:mask(playerid, params[])
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pMember] == 8 || PlayerInfo[playerid][pLeader] == 8 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2)
{
SendClientMessage(playerid, COLOR_GREY, " You are not a member of the Hitman Agency Or CIA!");
return 1;
}
if(PlayerInfo[playerid][pMask] == 0)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
ShowPlayerNameTagForPlayer(i, playerid, 0);
}
}
PlayerInfo[playerid][pMask] = 1;
// You forgot a closing paranthesis on the following line.
GetPlayerName(playerid, GetPlayerNameEx(playerid), sizeof(GetPlayerNameEx(playerid)));
format(string, sizeof(string), "* %s has put a mask on.", GetPlayerNameEx(playerid));
ProxDetector(15.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
else if(PlayerInfo[playerid][pMask] == 1)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
ShowPlayerNameTagForPlayer(i, playerid, 1);
}
}
PlayerInfo[playerid][pMask] = 0;
GetPlayerName(playerid, GetPlayerNameEx(playerid), sizeof(GetPlayerNameEx(playerid)));
format(string, sizeof(string), "* %s has put their mask away.", GetPlayerNameEx(playerid));
ProxDetector(15.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
}
return 1;
}