10.01.2010, 19:33
I want it to withdraw the amount I type in the dialog.
But it says $0 was withdrawn from your account.
But it says $0 was withdrawn from your account.
pawn Код:
if(response)
{
if(dialogid == BANKMENU)
{
new tmp[256];
new cashdeposit = strval(tmp);
ConsumingMoney[playerid] = 1;
GivePlayerMoney(playerid,cashdeposit);
PlayerInfo[playerid][pAccount]=PlayerInfo[playerid][pAccount]-cashdeposit;
format(string, sizeof(string), " ** You Have Withdrawn $%d from your account Total: $%d ", cashdeposit,PlayerInfo[playerid][pAccount]);
SendClientMessage(playerid, COLOR_GREEN, string);
return 1;
}
}