27.04.2017, 22:05
Hello there, i have a little problem with "Money" when a player is logging in.
So the player money saves but, when he/she logging in and type his/her password correctly the
dates from the database loads just the colum with his/her "Money" not. Literally it loads the money but
after 3 seconds the money resets to 0.
I updated MySQL plugin/include (r40).
Here is the part where the "Money" loads from database on "LoginAccount" function:
It's not correctly ?
Anyway before i tried like this:
And it still did not work.
Please give me a tip or something..
So the player money saves but, when he/she logging in and type his/her password correctly the
dates from the database loads just the colum with his/her "Money" not. Literally it loads the money but
after 3 seconds the money resets to 0.
I updated MySQL plugin/include (r40).
Here is the part where the "Money" loads from database on "LoginAccount" function:
PHP код:
cache_get_value_int( 0, "Money", Account[ playerid ][ pMoney ] );
GivePlayerMoney( playerid, Account[ playerid ][ pMoney ] );
Anyway before i tried like this:
PHP код:
GivePlayerMoney( playerid, cache_get_value_int( 0, "Money", Account[ playerid ][ pMoney ] ) );
Please give me a tip or something..


). To be more clear. I use variabile "pMoney" to get the money from the database. Of course i will use "GivePlayerMoney" because it is the function to set player money. I really think that you understand what i mean, but you did not help me so much 