06.12.2009, 13:08
hello i try to edit the Givecash command from Wiki But i get those errors
And my Script look likes this:
InTopOfScript:
Under OnPlayerCommandsText
InTheBottem
Thx to anyone who help me.
Код:
C:\Users\Steven\Desktop\Server\gamemodes\Streetlife.pwn(210) : error 017: undefined symbol "amount" C:\Users\Steven\Desktop\Server\gamemodes\Streetlife.pwn(365) : error 025: function heading differs from prototype C:\Users\Steven\Desktop\Server\gamemodes\Streetlife.pwn(370) : error 029: invalid expression, assumed zero C:\Users\Steven\Desktop\Server\gamemodes\Streetlife.pwn(365) : warning 203: symbol is never used: "params" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 3 Errors.
InTopOfScript:
Код:
forward Givecash(playerid,amount);
Код:
if(strcmp(cmdtext, "/GiveCash", true, 3)) { Givecash(playerid,amount); }
Код:
Givecash(playerid, params[]) { new giveplayerid, amount; else { GivePlayerMoney(giveplayerid, amount); GivePlayerMoney(playerid, 0 - amount); SendClientMessage(playerid, 0x00FF00AA, "Money sent"); SendClientMessage(giveplayerid, 0x00FF00AA, "Money received"); } return 1; }