Important questions -
[JnA]DukeNukem - 02.12.2010
Ok guys.....i have some more questions...
How do i save weapons/stats/skins when player logs off and how to make him use the same again,therefore skiping the skin choosing scene at the begining?
How to check if a player has some weapons?
Re: Important questions -
LarzI - 02.12.2010
Read up on dINI, dUDB, yINI or djSon (file systems)
Re: Important questions -
[JnA]DukeNukem - 02.12.2010
Could you simplefy that please?
Re: Important questions -
Ash. - 02.12.2010
They are basic file systems used in and around SAMP -
Seeing as you are a begginer at filing (obviously) - i suggest you take a look at dini. Search these forums for Dini and DracoBlue.
Also, if you dont know how to save that sort of data, you cant really offer "Gamemodes for $5"?
Re: Important questions -
[JnA]DukeNukem - 02.12.2010
Quote:
Originally Posted by funky1234
They are basic file systems used in and around SAMP -
Seeing as you are a begginer at filing (obviously) - i suggest you take a look at dini. Search these forums for Dini and DracoBlue.
Also, if you dont know how to save that sort of data, you cant really offer "Gamemodes for $5"?
|
I know what those are,but i've never tried to use them for such purposes
Re: Important questions -
[JnA]DukeNukem - 02.12.2010
.ini files.oh yea,i forgot xS
Re: Important questions -
Ash. - 02.12.2010
Well, heres a run down...
pawn Код:
dini_Create(const file[]);
Creates Files
pawn Код:
dini_Set(const file[], key[], string[]);
//Variations for Floats and Integers!
//Float Variation:
dini_FloatSet
//Integert Variation
diniIntSet
Sets a string/float/integer using keys to identify in a file
pawn Код:
dini_Get(const file[], key[])
//Variations for Float / Integer:
dini_Float
//Integer
dini_Int
Gets saved data using keys
pawn Код:
dini_Exists(const file[])
returns whether a file exists (1) or not (0)
pawn Код:
dini_Remove(const file[]) //I think
removes a file
Re: Important questions -
[JnA]DukeNukem - 02.12.2010
Thanks!....
Re: Important questions -
Think - 02.12.2010
Quote:
Originally Posted by [JnA]DukeNukem
Ok guys.....i have some more questions...
therefore skiping the skin choosing scene at the begining?
How to check if a player has some weapons?
|
To answer those questions;
1. Check if the player has an account
2. if yes > spawn him (SpawnPlayer(playerid)) if no > create an account and let him choose a skin
and
GetPlayerWeapon // Currently holding
GetPlayerWeaponData // All in 'pocket'
these would help you to detect if the player has weapons.