/deposit and /withdraw not doing anything
#1

So, I have my bank system:

CMDS:

Quote:

CMD:deposit(playerid,params[])
{
new string[256];
new type;
{
if(sscanf(params, "d", type)) return SendClientMessage(playerid, -1, "[USAGE]: /deposit [amount]");
if(type == 0)
if(GetPlayerMoney(playerid)< type)
{
GivePlayerMoney(playerid,-type);
BankInfo[playerid][pBankAccount] += type;
format(string, sizeof(string), "INFO: You have successfully deposited $%d to your bank account.", type);
SendClientMessage(playerid, 0xFFFFFF, string);
}
else SendClientMessage(playerid, 0xFFFFFF, "SERVER: You do not have that much amount in your hand");
}
return 1;
}
CMD:withdraw(playerid,params[])
{
new string[256];
new type;
{
if(sscanf(params, "d", type)) return SendClientMessage(playerid, -1, "[USAGE]: /withdraw [amount]");
if(type == 0)
if(BankInfo[playerid][pBankAccount] >= type)
{
BankInfo[playerid][pBankAccount] -= type;
GivePlayerMoney(playerid, type);
format(string, sizeof(string), "INFO: You have successfully withdrawn $%d from your bank account.", type);
SendClientMessage(playerid, 0xFFFFFF, string);
}
else SendClientMessage(playerid, 0xFFFFFF, "SERVER: You do not have that much amount in your account");
}
return 1;
}

When I do /deposit it says to do /deposit [amount] same for /withdraw(/withdraw [amount] - But, whenever I attempt to put money into it nothing happens, not even a client message, the bank is all setup the enum and such, no errors or warnings, I also have the money when im doing it

so any help:/
Reply


Messages In This Thread
/deposit and /withdraw not doing anything - by RLGaming - 15.09.2012, 00:25
Re: /deposit and /withdraw not doing anything - by KoczkaHUN - 15.09.2012, 00:38
Re: /deposit and /withdraw not doing anything - by RLGaming - 15.09.2012, 00:43
Re: /deposit and /withdraw not doing anything - by arvifilter - 15.09.2012, 00:50
Re: /deposit and /withdraw not doing anything - by KoczkaHUN - 15.09.2012, 00:58

Forum Jump:


Users browsing this thread: 3 Guest(s)