SA-MP Forums Archive
Gamemode Registration Issue. - 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: Gamemode Registration Issue. (/showthread.php?tid=350282)



Gamemode Registration Issue. - Forman - 11.06.2012

My gamemode is not working, the account registration does not work correctly as all the accounts are saved empty .ini files. How can I fix this? Here is the problem;

case DIALOG_REGISTER:
{
if (!response) return Kick(playerid);
if(response)
{
if(!strlen(inputtext)) return ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_INPUT, "Server Account",""COL_RED"You have entered an invalid password.\n"COL_WHITE"Type your password below to register a new account.","Register","Quit");
new INI:File = INI_Open(UserPath(playerid));
INI_SetTag(File,"data");
INI_WriteInt(File,"Password",udb_hash(inputtext));
INI_WriteInt(File,"Cash",0);
INI_WriteInt(File,"Admin",0);
INI_WriteInt(File,"Helper",0);
INI_WriteInt(File,"Deaths",0);
INI_WriteInt(File,"PlayerLogged",0);
INI_WriteInt(File,"Muted",0);
INI_WriteInt(File,"Kicks",0);
INI_WriteInt(File,"Jails",0);
INI_WriteInt(File,"Warnings",0);
INI_WriteInt(File,"Jailed",0);
INI_WriteInt(File,"AHide",0);
INI_WriteInt(File,"AdminDuty",0);
INI_WriteInt(File,"HelperDuty",0);
INI_WriteInt(File,"Reported",0);
INI_WriteInt(File,"Weapons",0);
INI_WriteInt(File,"Spectate",0);
INI_WriteInt(File,"Registered",0);
INI_WriteInt(File,"Model",0);
INI_WriteInt(File,"Member",0);
INI_WriteInt(File,"AdmName", 0);
INI_WriteInt(File,"HelName", 0);
INI_WriteInt(File,"SkinUsed", 0);
INI_WriteInt(File,"Kills", 0);
INI_WriteInt(File,"HelpMe", 0);
INI_WriteInt(File,"DesertEagleKills", 0);
INI_WriteInt(File,"MarkX", 0);
INI_WriteInt(File,"MarkY", 0);
INI_WriteInt(File,"MarkZ", 0);
INI_WriteInt(File,"Donator", 0);
INI_WriteInt(File,"FightStyle", 0);
INI_Close(File);

SendClientMessage(playerid, COLOR_LIGHTRED, "INFO: Account coverted, you are required to relog");
Kick(playerid);
}
}


Re: Gamemode Registration Issue. - WillyP - 11.06.2012

-Nevermind, read the post wrong-


Re: Gamemode Registration Issue. - Forman - 12.06.2012

Quote:
Originally Posted by [FU]Victious
Посмотреть сообщение
-Nevermind, read the post wrong-
Spoke to you on MSN, but neither of the things you said worked.


Re: Gamemode Registration Issue. - FireCat - 14.06.2012

Show me UserPath(playerid).