Unknown Command
#5

pawn Код:
CMD:i(playerid,params[])
{
    new option[4], itemslot; // if you add more options with more characters on them, make the size of the array longer
    if (sscanf(params, "s[4]i", option, itemslot)) return SendClientMessage(playerid, -1, "USAGE: /i use (itemslot).");
    if (!strcmp(option, "use", true))
    {
        if (itemslot == 1)
        {
            if(pInfo[playerid][pInv1] == 995)
            {
                SendClientMessage(playerid, -1, "The command works");
            }
        }
    }
    else SendClientMessage(playerid, -1, "Available options: use");
    return 1;
}
Reply


Messages In This Thread
Unknown Command - by DarkLored - 11.05.2014, 02:42
Re: Unknown Command - by Jstylezzz - 11.05.2014, 08:39
Re: Unknown Command - by DaniceMcHarley - 11.05.2014, 08:44
Re: Unknown Command - by DarkLored - 11.05.2014, 13:38
Re: Unknown Command - by Konstantinos - 11.05.2014, 13:47
Re: Unknown Command - by DarkLored - 11.05.2014, 13:55

Forum Jump:


Users browsing this thread: 1 Guest(s)