#1

So i have question...

I use Ravens gamemode LA:RP and GM use dini for player "stats" player datebase...
I readed and i know dini is slow and Y_INI is way better,i don't understand MySQL or SQLite and i don't want to change it into those two.

I'm interesting from where i shall begin and what are my steps i watched some tutorials but i don't understand what exactly should i do,i watched some tut's about register systems with y_ini etc but this system is kinda different

Am I supposed to change only variables like

pawn Код:
dini_IntSet(string3, "Password",password2);
pawn Код:
dini_FloatSet(string3, "pHealth",PlayerInfo[playerid][pHealth]);
pawn Код:
dini_IntSet(string3, "Password",PlayerInfo[playerid][pKey]);
or there is more i should know?
Reply
#2

Go to newbienewb tutorial its in the sfuel tutorials
Reply
#3

You don't need a MYSQL man, I got Y_INI without MySQL.

INI_WriteInt = PlayerStat[playerid][AdminLevel]

If I'm right.

You just have to make system for it to save it in an .ini file.


EDIT: https://sampforum.blast.hk/showthread.php?tid=273088
Reply
#4

https://sampforum.blast.hk/showthread.php?tid=175565

https://sampforum.blast.hk/showthread.php?tid=376424
Reply
#5

Ok thanks i will try Guitar's tutorial
Reply
#6

Okay one more thing what is difference betwen

pawn Код:
format(var, 128, "AdminLevel=%d\n",PlayerInfo[playerid][pAdmin]);fwrite(hFile, var);
pawn Код:
INI_WriteInt(string3, "AdminLevel",PlayerInfo[playerid][pAdmin]);
and

pawn Код:
dini_IntSet(string3, "AdminLevel",PlayerInfo[playerid][pAdmin]);
Reply
#7

anyone?
Reply
#8

The only difference on those above is the system which is used to save.

All of them do the same thing - saving the admin level which is stored to PlayerInfo[playerid][pAdmin] in the file.
Reply
#9

Quote:
Originally Posted by ***Niko***
Посмотреть сообщение
Okay one more thing what is difference betwen

pawn Код:
format(var, 128, "AdminLevel=%d\n",PlayerInfo[playerid][pAdmin]);fwrite(hFile, var);
pawn Код:
INI_WriteInt(string3, "AdminLevel",PlayerInfo[playerid][pAdmin]);
and

pawn Код:
dini_IntSet(string3, "AdminLevel",PlayerInfo[playerid][pAdmin]);
1st code uses SA-MP's local natives, fwrite to write down the array AdminLevel in which the result is an integer all in a file.

2nd code writes down an integer, which is the result of AdminLevel into a file. y_ini, I presume.

3rd code also relays the same info like the 2nd code, only difference that it's dini.
Reply
#10

Ok so are any of them better or all are same?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)