12.06.2011, 11:38
Hey guys,
I have a bug on my server. SOMETIMES (very rare) it happens that if you connect to the server your money is on MINUS although you had some money before disconnecting. I cant find absolutely nothing suspicious on the script. I have an own antimoneycheat system by a serversided money variable pMoney[MAX_PLAYERS].
For this I dont use GivePlayerMoney but my own function ac_GivePlayerMoney which is this:
stock ac_GivePlayerMoney(playerid, money)
{
pMoney[playerid] += money;
GivePlayerMoney(playerid, money);
}
same with SetPlayerMoney:
stock ac_SetPlayerMoney(playerid, money)
{
pMoney[playerid] = money;
ResetPlayerMoney(playerid);
GivePlayerMoney(playerid, money);
}
do you have any ideas ? Maybe a known problem ?
thx for reading
I have a bug on my server. SOMETIMES (very rare) it happens that if you connect to the server your money is on MINUS although you had some money before disconnecting. I cant find absolutely nothing suspicious on the script. I have an own antimoneycheat system by a serversided money variable pMoney[MAX_PLAYERS].
For this I dont use GivePlayerMoney but my own function ac_GivePlayerMoney which is this:
stock ac_GivePlayerMoney(playerid, money)
{
pMoney[playerid] += money;
GivePlayerMoney(playerid, money);
}
same with SetPlayerMoney:
stock ac_SetPlayerMoney(playerid, money)
{
pMoney[playerid] = money;
ResetPlayerMoney(playerid);
GivePlayerMoney(playerid, money);
}
do you have any ideas ? Maybe a known problem ?
thx for reading