Dini with 0.3
#4

Is this right:
Код:
	if((dialogid == 2) && (response == 1))
		{
    new tmp[128];
 		new file[256];
    new pw[256];
		pw = dini_Get(file, "password");
		new pName[24];
		GetPlayerName(playerid, pName, sizeof(pName));
		format(file, sizeof(file), "%s.ini", pName);
		new tmppass[64];
		strmid(tmppass, tmp, 0, strlen(inputtext), 255);
		if(udb_hash(inputtext) == udb_hash(pw))
		{
			OnPlayerLogin(playerid,tmppass);
		}
		else
		{
			ShowPlayerDialog(playerid, 2,1,"Wrong Password", "That Password was not correct.\nPlease try again, or change your name.","Login","cancel");
		}
		return 1;
	}
	if((dialogid == 2) && (response == 0))
	{
		SendClientMessage(playerid, COLOR_RED, "You must log in to use this server");
		Kick(playerid);
 	}
 	return 1;
}
Reply


Messages In This Thread
Dini with 0.3 - by Annihalation - 26.10.2009, 21:30
Re: Dini with 0.3 - by DiDok - 26.10.2009, 22:12
Re: Dini with 0.3 - by Annihalation - 26.10.2009, 22:14
Re: Dini with 0.3 - by jamesb93 - 26.10.2009, 23:09

Forum Jump:


Users browsing this thread: 1 Guest(s)