Adding business payout at payday. [MySQL]
#1

I recently noticed that I simply forgot to add the business payout when a player signs their check and for some reason I am now having some difficulty figuring out how to add the business payout to the payday from the MySQL database. Any help would be appreciated!

Код:
stock PayDayCheck(playerid)
{
	if(IsPlayerConnected(playerid))
	{
	    SendClientMessage(playerid, ORANGE, "-----------------------------------------------");
		new string[256], rand = 1 + random(599);
		new rand1 = 1 + random(199);
		format(string, sizeof(string), "Payout: $%d", rand);
		SendClientMessage(playerid, WHITE, string);
		format(string, sizeof(string), "Tax deduction: $%d", rand1);
		SendClientMessage(playerid, WHITE, string);
		Player[playerid][ExperiencePoints] += 1;
		format(string, sizeof(string), "Experience points: 1 added - Total: %d", Player[playerid][ExperiencePoints]);
		SendClientMessage(playerid, WHITE, string);
		Player[playerid][Money] -= rand1;
		Player[playerid][Money] += rand;
		SendClientMessage(playerid, ORANGE, "-----------------------------------------------");
		SaveStats(playerid);
	}
	return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)