11.11.2014, 20:37
pawn Код:
CMD:withdraw(playerid, params[])
{
new string[128], input;
if(sscanf(params, "i", input)) return SendClientMessage(playerid, 0x46E850FF, "SERVER:{FFFFFF} /withdraw[amount]");
if(PlayerInfo[playerid][Bank] < input) return SendClientMessage(playerid, 0x46E850FF, "SERVER:{FFFFFF} You don't have that much money in bank!");
PlayerInfo[playerid][Bank] -= input, GivePlayerMoney(playerid, input);
format(string, sizeof(string), "SERVER:{FFFFFF} You have withdraw $%d into your bank account.", input);
SendClientMessage(playerid, 0x46E850FF, string);
return 1;
}