09.10.2018, 18:21
pawn Код:
ptask PayBankTaxes[2400000](playerid)//40 minutes
{
new str[128], taxes;
if(Player[playerid][Bank] > 25000 || Player[playerid][Bank] < 74999) //2.0125%
{
taxes = Player[playerid][Bank] / 64;
Player[playerid][Bank] = Player[playerid][Bank] - Player[playerid][Bank] / 64;
}
else if(Player[playerid][Bank] > 75000 || Player[playerid][Bank] < 149999) //3.125%
{
taxes = Player[playerid][Bank] / 32;
Player[playerid][Bank] = Player[playerid][Bank] - Player[playerid][Bank] / 32;
}
else if(Player[playerid][Bank] >= 150000) //6.25%
{
taxes = Player[playerid][Bank] / 16;
Player[playerid][Bank] = Player[playerid][Bank] - Player[playerid][Bank] / 16;
}
SCM(playerid, COLOR_WHITE, "|___ BANK STATEMENT ___|");
SCMEX(playerid, COLOR_FADE1, " Balance: %s", formatInt(Player[playerid][Bank]));
SCMEX(playerid, COLOR_FADE1, " Taxes paid: %s", formatInt(taxes));
SCM(playerid, COLOR_WHITE, "|________________________|");
format(str, sizeof(str), "~y~Taxes~n~~w~Paid~n~~g~%s", formatInt(taxes));
GameTextForPlayer(playerid, str, 3000, 1);
}
Quote:
error 047: array sizes do not match, or destination array is too small |
pawn Код:
ptask PayBankTaxes[2400000](playerid)