Logical OR || Operator doesn't work properly
#1

I am creating sendrcon command on my server

Код:
CMD:sendrcon(playerid, params[])
{
	if(!IsPlayerAdmin(playerid) || pInfo[playerid][Admin] == 6) return SendClientMessage(playerid, 0xFFFFFFFF, "[HPRP]: You don't have enough permissions to use this command");
	{
        new rconcmd[128];
	    if(sscanf(params, "s[128]", rconcmd)) return SendClientMessage(playerid, 0xFFFFFFFF, "[HPRP] SYNTAX: /sendrcon [message]");
		{
			SendRconCommand(rconcmd);
			format(rconcmd, sizeof(rconcmd), "Command %s has been sent to RCON", rconcmd);
			SendClientMessage(playerid, 0xFFFFFFFF, rconcmd);
		}
	}
	return CMD_SUCCESS;
}
but when i got both var on my player, it says i don't have enough permission. but when i only have RCON assigned to my player, it works... so that means the error is on Logical OR Operator, cos i already check'd my stats, and i have Level 6 Admin on my player when i got denied... i've tried using both samp original pawn compiler and pawn-lang compiler

what do i need to do so when i got both var it would work?
Reply


Messages In This Thread
Logical OR || Operator doesn't work properly - by MiyuUchiha - 21.05.2018, 12:57
Re: Logical OR || Operator doesn't work properly - by DarkSkull - 21.05.2018, 13:02
Re: Logical OR || Operator doesn't work properly - by 10MIN - 21.05.2018, 13:08
Re: Logical OR || Operator doesn't work properly - by MiyuUchiha - 21.05.2018, 13:54

Forum Jump:


Users browsing this thread: 1 Guest(s)