10.02.2017, 21:32
A simple solution to this is to always update your player's money on OnPlayerUpdate.
This way everytime the player does anything (or just stands still for that matter) their money gets updated if the displayed amount of cash is not the same as the server-sided money is.
Edit: Just to add, the problem itself can never be removed as above respondants have answered but this way is what I found to be the least "not noticeable" way, I never noticed the money change with this at least.
Код:
public OnPlayerUpdate(playerid) { if (GetPlayerMoney(playerid) != PlayerInfo[playerid][Money]) { ResetPlayerMoney(playerid); GivePlayerMoney(playerid, PlayerInfo[playerid][Money]); } return 1; }
Edit: Just to add, the problem itself can never be removed as above respondants have answered but this way is what I found to be the least "not noticeable" way, I never noticed the money change with this at least.