10.11.2014, 14:22
Try this one,
PS: You have created a local variable to hold the amount as an integer var and you're using it as float, that won't gonna work at all.
pawn Код:
CMD:givemoney(playerid, params[])
{
new
pid,
money
;
if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, 0xFF0000FF, "You Are Not Admin But You Allowed To Use /pay");
if(sscanf(params, "ui", pid, money)) return SendClientMessage(playerid, 0xFFFF00FF, "Usage : /{FF0000}GiveMoney {FFFF00}[ID] [Value]!");
if(!IsPlayerConnected(pid)) return SendClientMessage(playerid, 0xFFFF00FF, "Player Doesn't Exist!");
new pName[MAX_PLAYER_NAME], Str[128];
GetPlayerName(playerid, pName, sizeof(pName));
format(Str, sizeof(Str), "Admin : %s Gave You $%i Cash!", pName, money);
SendClientMessage(pid, 0x00FF00FF, Str);
GivePlayerMoney(pid, money);
return 1;
}

