(/command [id] [time]) how can i add another variable?
#4

You always can ofc, but that is deemed impractical by today's users. Using a command processor is much more simpler, as all you do is include a file into your gamemode, and use the macro. A /givemoney command can be made in less than 20 lines without assigning a million variables, and it's just generally easy to use.

Example:
pawn Код:
CMD:setmoney(playerid,params[])
{
    new
        target,
        money;

    if(sscanf(params,"ui",target,money))
    {
        return SendClientMessage(playerid,COLOR_LIGHTGRAY,"USAGE: /setmoney [playerid] [amount]");
    }
    else
    {
        ResetPlayerMoney(target);
        GivePlayerMoney(target,money);
    }
    return 1;
}
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)