Login is bugged like hell.
#1

Okay everytime i type /prisijungti and i enter a 1 letter or something that is not my password ex: /prisijungti 32 but my password is like 7658 and it still logins for me i tryed to fix it but i don't know how here's the code;


the login command


Код:
	if (strcmp(cmd, "/prisijungti", true) == 0)
	{
 		new tmppass[128];
		if(AccountInfo[playerid][Prisijunges] == 1) return SendClientMessage(playerid, LIGHTBLUE, "Tu jau esi prisijunges.");
		tmp = strtok(cmdtext, idx);
		if(!strlen(tmp)) return SendClientMessage(playerid, LIGHTBLUE, "Naudojimas: /prisijungti [slaptazodis]");
		new plname[MAX_PLAYER_NAME];
  		GetPlayerName(playerid, plname, sizeof(plname));
		format(string, sizeof(string), "/fAccounts/%s.ini", plname);
		if(!fexist(string)) return SendClientMessage(playerid, LIGHTBLUE, "Account'as neregistruotas! Prisiregistruok: /registruotis [slaptazodis]");
		strmid(tmppass, tmp, 0, strlen(cmdtext), 255);
		OnPlayerLogin(playerid, MD5_Hash(tmppass));
		return 1;
	}
OnPlayerLogin callback


Код:
if (!strcmp("Slaptazodis", passres))
		{
			value = GetFileValue(pass);
			strmid(AccountInfo[playerid][Slaptazodis], value, 0, strlen(value)-1, 128);
		}
		else
		{
			SendClientMessage(playerid, LIGHTBLUE, "Neteisingas slaptazodis.");
	    fclose(account);
	    return 1;
		}
sry didn't want to show my onplayerlogin all of it but these are the lines that should show not incorrect password and it should close the account but it still logins for me. Please someone help me!!!!!
Reply


Messages In This Thread
Login is bugged like hell. - by Gamer007 - 31.05.2009, 13:42
Re: Login is bugged like hell. - by shitbird - 31.05.2009, 14:17
Re: Login is bugged like hell. - by Gamer007 - 31.05.2009, 14:28
Re: Login is bugged like hell. - by Gamer007 - 01.06.2009, 10:58

Forum Jump:


Users browsing this thread: 3 Guest(s)