Help needed.
#1

Hello, i got a bug in my account, however i input any password which i didnt register with i can log into my account..
And then when i open users in scriptfiles and open my accounts info there no nothing written in the Key: section.But before there was a code.
Reply
#2

did you have something like this

Quote:

public OnPlayerRegister(playerid, password[])
{
if(IsPlayerConnected(playerid))
{
new string3[32];
new playername3[MAX_PLAYER_NAME];
GetPlayerName(playerid, playername3, sizeof(playername3));
format(string3, sizeof(string3), "users/%s.ini", playername3);
new File: hFile = fopen(string3, io_write);
if (hFile)
{

Reply
#3

Yes exactly the same here is it
Код:
	public OnPlayerRegister(playerid, password[])
{
	if(IsPlayerConnected(playerid))
	{
			new string3[32];
			new playername3[MAX_PLAYER_NAME];
			GetPlayerName(playerid, playername3, sizeof(playername3));
			format(string3, sizeof(string3), "users/%s.ini", playername3);
			new File: hFile = fopen(string3, io_write);
			if (hFile)
			{
Reply
#4

try using mine reply back if not working
Reply
#5

I Didnt understand arent our codes same?
Reply
#6

yes but give it a try also do you having somthing like this in the script aswell
Quote:

if( strcmp( key , "Key" , true ) == 0 ) { val = ini_GetValue( Data ); strmid(PlayerInfo[MAX_PLAYERS][pKey], val, 0, strlen(val)-1, 255); }
if( strcmp( key , "Level" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[MAX_PLAYERS][pLevel] = strval( val ); }
if( strcmp( key , "AdminLevel" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[MAX_PLAYERS][pAdmin] = strval( val ); }

Reply
#7

Hmm have others but not the first one written key
Код:
if( strcmp( key , "Level" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[playerid][pLevel] = strval( val ); }
					if( strcmp( key , "AdminLevel" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[playerid][pAdmin] = strval( val ); }
					if( strcmp( key , "Band" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[playerid][pBanned] = strval( val ); }
Reply
#8

#define LOADUSERDATA_THREAD 1 add this to top of your script
Reply
#9

Oh sorry i have the same line as yours too
Код:
if( strcmp( key , "Key" , true ) == 0 ) { val = ini_GetValue( Data ); strmid(PlayerInfo[MAX_PLAYERS][pKey], val, 0, strlen(val)-1, 255); }
					if( strcmp( key , "Level" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[MAX_PLAYERS][pLevel] = strval( val );  }
					if( strcmp( key , "AdminLevel" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[MAX_PLAYERS][pAdmin] = strval( val ); }
					if( strcmp( key , "Band" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[MAX_PLAYERS][pBanned] = strval( val ); }
					if( strcmp( key , "PermBand" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[MAX_PLAYERS][pPermaBanned] = strval( val ); }
Reply
#10

Nope still not working sir
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)