20.09.2012, 13:52
Im tryng to make contract cmd but it says
at line
here :
Код:
C:\Users\Eigenaar\Desktop\Windows-Server\gamemodes\vx-rp.pwn(17331) : error 029: invalid expression, assumed zero
Код:
else
Код:
playerVariables[ID][pHitamount] = amount; playerVariables[ID][pHit] = 1; } else {
Код:
CMD:contract(playerid, params[]) { new amount; if(sscanf(params, "dd", ID, amount)) { SendClientMessage(playerid, COLOR_RED, "USAGE: /hit [ID] [amount]"); } else if(amount > 0) { if(IsPlayerConnected(ID)) { if(GetPlayerMoney(playerid) >= amount) { Hit[ID] = amount; hiter[ID] = playerid; new string[256]; format(string, sizeof(string), "You have placed a hit on %s (%i) for $%i", ReturnPlayerName(ID), ID, amount); SendClientMessage(playerid, COLOR_RED, string); format(string, sizeof(string), "%s (%i) has placed a hit on %s (%i) for $%i", ReturnPlayerName(playerid), playerid, ReturnPlayerName(ID), ID, amount); SendClientMessageToAll(COLOR_RED, string); playerVariables[ID][pHitamount] = amount; playerVariables[ID][pHit] = 1; } else { SendClientMessage(playerid, COLOR_RED, "Please wait before placing another hit!"); } } else { SendClientMessage(playerid, COLOR_RED, "You do not have enough money!"); } else { SendClientMessage(playerid, COLOR_RED, "That player is not connected!"); } } else { SendClientMessage(playerid, COLOR_RED, "Minimum amount to hit a person with is $1!"); } return 1; }