Hello everybody,
I have a little problem here, I wan't to save the players money into a Variable when he's disconnecting using this code :
PHP Code:
public client_disconnect(id)
{
g_iMoney[id] = cs_get_user_money(id) // Error Line
save_user_money(id)
}
But sometimes I get this in my log and players saved money gets 0 :
Quote:
L 05/05/2013 - 17:45:58: [CSTRIKE] Invalid player 5
L 05/05/2013 - 17:45:58: [AMXX] Run time error 10: native error (native "cs_get_user_money")
|
Anyone knows how to fix that? I'd say "if(is_user_connected(id))", but I think I can't check that on disconnect.
Greets,
Kia.
__________________