24.12.2012, 23:20
Dose anyone know how to remove a auto refund i cant find it anywhere!
add me on skype jason.smith5180
add me on skype jason.smith5180
public OnPlayerDeath(playerid, killerid, reason)
{
//======[TAX]======//
new string[128],
wantedlevel = GetPlayerWantedLevel(playerid),
moneyamount = GetPlayerMoney(playerid);
if(moneyamount < 0) { moneyamount = moneyamount*-1; }
if(-50000 < moneyamount < -1) { moneyamount = 0; }
new tax; tax = 250+(moneyamount*wantedlevel)/20+random(1000);
format(string, sizeof(string), "Your total tax was %d$.", tax);
SendClientMessage(playerid, COLOR_LIGHTGREEN, string);
GivePlayerMoney(playerid, -tax);
if(wantedlevel == 0 && gTeam[killerid] == TEAM_POLICE || gTeam[killerid] == TEAM_CIA)
{
tax = 0;
}
//=[SETPLAYERWANTEDLEVEL]=//
SetPlayerWantedLevel(playerid, 0);
return 1;
}
SetPlayerHealth(killerid, 0);