SA-MP Forums Archive
Help needed + Rep - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Help needed + Rep (/showthread.php?tid=310312)



Help needed + Rep - Viktor_Axelsson - 11.01.2012

What's wrong when you spawn in blueberry with $0 and CJ skin?
This happens everytime you restart while being on the server. Someone told me it's due to the fact that GetPlayerMoney doesn't work with OnPlayerDisconnect? But a friend of mine said he could fix it but only with /rcon GMX and not fix it when you restart the server from the hosting company's control panel. He said "the only problem is that when server restarts it doesn't cal neither OnPlayerDissconect, neither OnGamemodeExit
I can make so it would save everything but I guess just when you type /RCON GMX."

So is there a way to fix this or will I have to quit using the restart feature on our hosting company's control panel?
Because my friend thinks he can fix it but only related to the /RCON GMX restart and not the restarting from our hosting company. Thanks in advance.


Re: Help needed + Rep - Tigerkiller - 11.01.2012

Go under OnGameModeExit, loop thought all players and save theyr statistics like password ...


Re: Help needed + Rep - Viktor_Axelsson - 11.01.2012

Quote:
Originally Posted by Tigerkiller
Посмотреть сообщение
Go under OnGameModeExit, loop thought all players and save theyr statistics like password ...
Already done, didn't work.


Re: Help needed + Rep - sabretur - 11.01.2012

Check your server logs, should be something like run time error.


Re: Help needed + Rep - Tigerkiller - 11.01.2012

There musnt be an error. Save Player stats in OnGameModeExit and debug it. Anyway show us your OngameModeExit callback so we can solve your problem.


Re: Help needed + Rep - Viktor_Axelsson - 11.01.2012

Okay.


Re: Help needed + Rep - Jochemd - 11.01.2012

Run a 20-sec timer which saves the player stats. (use a loop + IsPlayerConnected, not 800 seperate timers!)


Re: Help needed + Rep - Viktor_Axelsson - 11.01.2012

Quote:
Originally Posted by Jochemd
Посмотреть сообщение
Run a 20-sec timer which saves the player stats. (use a loop + IsPlayerConnected, not 800 seperate timers!)
I contacted you regarding this.


Re: Help needed + Rep - Tigerkiller - 11.01.2012

lol you dont need a timer omg!!!!
post us your OngameModeExit and the save part on disconnect


Re: Help needed + Rep - Viktor_Axelsson - 11.01.2012

Quote:
Originally Posted by Tigerkiller
Посмотреть сообщение
lol you dont need a timer omg!!!!
post us your OngameModeExit and the save part on disconnect
Check your inbox please.