How to Store a Basic Data. -
Matthew_Johnston - 10.12.2010
I Have Seen a Fair Bit about Dini Ect.
But I Havent come up with a Way to Store Info for a Single Variable.
Heres What I Want to Store:
Код:
new PassPort[MAX_PLAYERS];
This is the Code Where its Set To a Higher Number.
Код:
if (strcmp("/upgradepass", cmdtext, true) == 0)
{
SendClientMessage(playerid, 0xFFFF00AA,"Set To Passport Stage 2");
PassPort[playerid] = 2;
return 1;
}
So its Set to Stage 2, Now. When the Person Leaves and the Server can be Restarted. This Data is Restored when the person connect to my server with that Name,
I Do Not want a Register or Login command, Dont call me a Fool. But I Dont.
Anyway, is there any Methods Avaliable That could Allow me to Save This Data?
Re: How to Store a Basic Data. -
Retardedwolf - 10.12.2010
Save it like how you save your stuff in your server. Aren't you a "Pretty Nice Scripter"?
Re: How to Store a Basic Data. -
admantis - 10.12.2010
just use this:
pInfo[playerid][pPassPort] = 2;
i use pInfo..
Re: How to Store a Basic Data. -
Matthew_Johnston - 10.12.2010
Okay, That dosent make much Sense. Youre saying If I Put the Word pInfo into it It will Save Automaticly? And Retardedworld, Saving is Pretty Much my Major Flaw. Dont be a Dickhead
-Edit.
Im not using an Enumerator.
Shouldent I Be able to save data without one?
Re: How to Store a Basic Data. -
admantis - 10.12.2010
no it wont save but it will set the passport to 2, so you make when player leaves save the stuff and when player connects load the stuff too.
Or you can use a timer if you want it to save automaticly, like 1 save per 5mins.
Re: How to Store a Basic Data. -
Matthew_Johnston - 10.12.2010
I See, But the question is Simply. How To Save that Data?
I Know it could be a large tutorial. and if it is, just give me a link if Possible.
Re: How to Store a Basic Data. -
admantis - 11.12.2010
first search plz
https://sampforum.blast.hk/showthread.php?tid=191967
Re: How to Store a Basic Data. -
Matthew_Johnston - 11.12.2010
thanks mate
Re: How to Store a Basic Data. -
Matthew_Johnston - 11.12.2010
Oh Sorry, But That Tutorial Didnt explain how for that To Take Affect to All the People that Connect to my Server. Just for One Name.
And I Experimented with [MAX_PLAYERS] To Get it to Work But Nope.
So any Help to store that Single peice of Data per person would be loved
Re: How to Store a Basic Data. -
iggy1 - 11.12.2010
There are many, many tutorials that use dini look through them and adapt it to suite your needs. Search tutorial section for the word "dini" and just search thread names. Theres more info on what you need in them tutorials than people will give here. Just try learn, the info is already out there.