PDA

View Full Version : YSI\y_ini Order Question?


Stefcaaaa
11/06/2018, 11:35 PM
Hi guys well i do not have any problem with scripting but i want to know, why y_ini writes data like this (see picture)? I want to make Password on the top of the list. How can i do this?

Exhibit
11/06/2018, 11:40 PM
Just make the password save before those?

Stefcaaaa
11/06/2018, 11:42 PM
I did. :)

Stefcaaaa
11/06/2018, 11:44 PM
But nothing helps? Any Solution?

Exhibit
11/06/2018, 11:49 PM
Post the code for the register dialog

PS. This should not effect anything btw.

Stefcaaaa
11/06/2018, 11:53 PM
new INI:File = INI_Open(UserPath(playerid));
INI_SetTag(File,"data");
INI_WriteInt(File,"Password",udb_hash(inputtext));
INI_WriteInt(File,"Money",0);
INI_WriteInt(File,"Admin",0);
INI_Close(File);

gPlayerLoggedIn[playerid] = 1;


This is for DIALOG_REGISTER case! :D

function SaveUser_data(playerid)
{
new INI:File = INI_Open(UserPath(playerid));
INI_SetTag(File,"data");
INI_WriteInt(File,"Money",GetPlayerMoney(playerid));
INI_WriteInt(File,"Admin",PlayerInfo[playerid][pAdmin]);
INI_Close(File);
}

This is for savinguserdata (under OnPLayerDisconnect)

Exhibit
11/06/2018, 11:56 PM
That's weird. Post the code when you save all the stuff.

Stefcaaaa
11/06/2018, 11:57 PM
I did function SaveUser_data(playerid) is for saving all the stuff when player disconnect!

Exhibit
11/06/2018, 11:58 PM
I did function SaveUser_data(playerid) is for saving all the stuff when player disconnect!

Yes post that function.

Stefcaaaa
11/06/2018, 11:59 PM
function SaveUser_data(playerid)
{
new INI:File = INI_Open(UserPath(playerid));
INI_SetTag(File,"data");
INI_WriteInt(File,"Money",GetPlayerMoney(playerid));
INI_WriteInt(File,"Admin",PlayerInfo[playerid][pAdmin]);
INI_Close(File);
}

Exhibit
12/06/2018, 12:02 AM
I don't want to spam the forum but check if the "pPass" is on top of the enum if not pm me on Discord Inferno#7135

Stefcaaaa
12/06/2018, 12:03 AM
Any solution? YSI?

Stefcaaaa
12/06/2018, 12:15 AM
Fixed! I changed the order :) Is there any explanation?