Need help with control structure
#1

pawn Код:
if(strcmp(cmd, "/mask", true) == 0)
    {
        if(PlayerInfo[playerid][pMember] != 11 || PlayerInfo[playerid][pMember] != 8) return SendClientMessage(playerid, COLOR_GREY, "You are not in the HA / Cartel!");
        {
            if(PlayerInfo[playerid][pMask] == 0)
        {
            PlayerInfo[playerid][pMask] = 1;
            foreach (Player, i)
            {
                if(IsPlayerConnected(i))
                {
                    ShowPlayerNameTagForPlayer(i, playerid, 0);
                }
            }
            strmid(sendername, PlayerRPName(playerid), 0, MAX_PLAYER_NAME);
            format(string, sizeof(string), "* %s has put a mask on.", sendername);
            ProxDetector(15.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        }
        else if(PlayerInfo[playerid][pMask] == 1)
        {
            PlayerInfo[playerid][pMask] = 0;
            foreach (Player, i)
            {
                if(IsPlayerConnected(i))
                {
                    ShowPlayerNameTagForPlayer(i, playerid, 1);
                }
            }
            strmid(sendername, PlayerRPName(playerid), 0, MAX_PLAYER_NAME);
            format(string, sizeof(string), "* %s has put their mask away.", sendername);
            ProxDetector(15.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
                }
            }
    }
When i'm in faction 11, it still tells me You are not in the HA / Cartel! - any reason as to why this is happening? +rep if i can
Reply


Messages In This Thread
Need help with control structure - by Jing_Chan - 31.08.2014, 21:32
Re: Need help with control structure - by Eth - 31.08.2014, 21:44
Re: Need help with control structure - by Jing_Chan - 31.08.2014, 22:02

Forum Jump:


Users browsing this thread: 2 Guest(s)