SA-MP Forums Archive
Password - 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: Password (/showthread.php?tid=624530)



Password - SpaceRP - 18.12.2016

Hey guys

I have a problem when the player throws dialogue for registration and if he does not uupise not only compresses it yarn enter the login and I put this to isnul and !Strlen or does not help. Does anyone know what the problem is

Код:
fDialog(1246)
{
    if(!response) return Kick(playerid);
	if(response)
	{
        if(isnull(inputtext))
        {
            new regstring[180];
			format(regstring, sizeof(regstring), "%s .....", GetName(playerid));
			ShowPlayerDialog(playerid, 1246, DIALOG_STYLE_PASSWORD, "Register", regstring, "Register", "Exit");
        }
        else if(strlen(inputtext) < 6 || strlen(inputtext) > 20)
       	{
			new regstring[180];
			format(regstring, sizeof(regstring), "%s .....", GetName(playerid));
			ShowPlayerDialog(playerid, 1246, DIALOG_STYLE_PASSWORD, "Register", regstring, "Register", "Exit");
		}
		else if(strfind(inputtext, "%") != -1)
    	{
	    	new regstring[180];
			format(regstring, sizeof(regstring), "%s .....", GetName(playerid));
			ShowPlayerDialog(playerid, 1246, DIALOG_STYLE_PASSWORD, "Register", regstring, "Register", "Exit");
    	}
		else
		{
	    	OnPlayerRegister(playerid, inputtext);
	    }
	}
	return 1;
}



Re: Password - SpaceRP - 18.12.2016

BUMP