help with zcmd[need help]
#1

i have another prob

how can i make /buyitem [item name] with zcmd

i mean what is the code to know that the player typed the item name

here is a e.g

pawn Код:
COMMAND:buyitem(playerid,params[])
{
    if(!sscanf(params, "Test")
    {
        SendClientMessage(playerid, COLOR_RED, "test success :D!");
    }
    else SendClientMessage(playerid, COLOR_GREEN, "USAGE: /buyitem <item name> | use /shophelp for help.");
    return 1;
}
help pls
Reply
#2

PHP код:
CMD:buyitem(playeridparams[])
{
    new 
item[128];
    if(
sscanf(params"s[128]"item)) {
        
SendClientMessage(playeridCOLOR_GREEN"USAGE: /buyitem <item name> | use /shophelp for help.");
        return 
1;
    }
    
SendClientMessage(playeridCOLOR_RED"test success :D!");
    return 
1;

I recommend you to read this
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)