[Help] Making commands
#1

I am working on to create commands like /givemoney and anothers but those cmds are not working.

Код:
COMMAND:givemoney(playerid, params[])
{
    if (IsPlayerAdmin(playerid))
    {
        new
          toplayerid, // the player we want to give money to
          amount;
        // extracting player's ID and amount from params
        if (!sscanf(params, "ii", toplayerid, amount))
        {
          if (toplayerid != INVALID_PLAYER_ID)
          {
            new
              message[40];
            GivePlayerMoney(toplayerid, amount);
            format(message, sizeof(message), "You got $%d from admin!", amount);
            SendClientMessage(toplayerid, 0x00FF00FF, message);
          }
          else SendClientMessage(playerid, 0xFF0000FF, "That player is not connected");
        }
        else SendClientMessage(playerid, 0xFFFFFFFF, "Usage: /givemoney <playerid> <amount>");
    }
    else SendClientMessage(playerid, 0xFF0000FF, "Only admins can use this command!");
    return 1;
}
Error:

Код:
C:\Slymind-Projects\gamemodes\slymind.pwn(437) : warning 203: symbol is never used: "givemoney"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Warning.
Please explain me that how to fix it and how to add more commands cause I am learning pawn and I want to learn it really quickly. Thanks for your time.
Reply


Messages In This Thread
[Help] Making commands - by William_McKnight - 18.07.2014, 16:59
Re: [Help] Making commands - by LivingLikeYouDo - 18.07.2014, 17:04
Re: [Help] Making commands - by Konstantinos - 18.07.2014, 17:41
Re: [Help] Making commands - by William_McKnight - 18.07.2014, 17:42
Re: [Help] Making commands - by Konstantinos - 18.07.2014, 17:47
Re: [Help] Making commands - by Faix - 18.07.2014, 18:49
Re: [Help] Making commands - by William_McKnight - 18.07.2014, 19:24

Forum Jump:


Users browsing this thread: 1 Guest(s)