SA-MP Forums Archive
Loading Problem. - 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: Loading Problem. (/showthread.php?tid=350830)



Loading Problem. - tiernantheman - 13.06.2012

Hey guys, I'm having a big problem with my gamemode. Well I registered and set my gender and my origin and passed the RP test. But when I log out after doing all that and join back in it says login and I do that but it just makes me re-do the Gender selection and the RP Test all over again any help would be really good thanks.

Here's my OnPlayerLogin.

http://pastebin.com/nHdg8fPw


Respuesta: Loading Problem. - CidadeNovaRP - 13.06.2012

And save system?


Re: Respuesta: Loading Problem. - tiernantheman - 13.06.2012

Quote:
Originally Posted by CidadeNovaRP
Посмотреть сообщение
And save system?
I use djson if thats what your asking.


Re: Loading Problem. - Unfriendly - 13.06.2012

Well, I didn't read your code and I don't know about djson.
But basically what's happening is it's not finding out if you've done the test or not.

You know how at the top of your script it says phealth?
Well what's it doing there is saving your player's health.

I don't know why it's saving it, perhaps to set it to that upon your next login.

But, anyway, there should be something like that but it'll be newplayer or test or something...
And when you pass the test, it should save that newplayer or test or whatever the name is to 1.
Then when you login, it'll read your file and if newplayer/test/whatever =1 it won't show the test.
If it reads your file and newplayer/test/whatever = 0 it will show the test.


Just read through your script, and check the scriptfiles.

You'll find it and figure out how to fix it in no time.


Respuesta: Re: Respuesta: Loading Problem. - CidadeNovaRP - 13.06.2012

Quote:
Originally Posted by tiernantheman
Посмотреть сообщение
I use djson if thats what your asking.
No friend, I want to save the CODE, or is it standard in the archives?


Re: Loading Problem. - JhnzRep - 14.06.2012

Not to be an asshole or anything, but you people need to move on to a new saving system. DjSon is way out dated, go to y_ini or MySql.


Re: Loading Problem. - ViruZz - 14.06.2012

If I were you I would switched over to MySQL for more advantages and features but if you aren't capable with MySQL Just yet then switch over to y_ini bro that will be the best thing to do.


Re: Loading Problem. - ReneG - 14.06.2012

DJson works like the database system in JavaScript, not technically outdated. MySQL is a hassle for new scripters. All the plugins, and things that could go wrong. Id rather choose the native SQLite if you actually want to do SQL without all the features that you probably won't need. Besides, this isnt a "tell people what to use thread".

Look up tutorials on DJson or find a slave.