Problem regarding changepass cmd.
#1

Hello. I made a command to change the password of a certain acc.
Код:
dcmd_changepass(playerid,params[])
{
	if(!strcmp(params,"666",true))
	{
	    ShowPlayerDialog(playerid, 3, DIALOG_STYLE_PASSWORD, "> Password", "Please enter your new password.", "Change", "Cancel");
	 	return 1;
	}
    if (strlen(params) < 3)
	{
		SendClientMessage(playerid,COLOR_SYSTEM_GM,"Error, the password is too short");
		ShowPlayerDialog(playerid, 3, DIALOG_STYLE_PASSWORD, "> Password", "Please enter your new password.", "Change", "Cancel");
	 	return 1;
	}
	if(strlen(params)>14)
	{
	    SendClientMessage(playerid,COLOR_SYSTEM_GM,"Error, the password is too long");
	    ShowPlayerDialog(playerid, 3, DIALOG_STYLE_PASSWORD, "> Password", "Please enter your new password.", "Change", "Cancel");
	 	return 1;
	}
	new newpass;
	new mess[MAX_STRING];
	newpass=udb_hash(params);
	dUserSetINT(PlayerName(playerid)).("password_hash",newpass);
	format(mess,sizeof(mess),"..: SUCCESS: Your password has been changed. :..",newpass);
	SendClientMessage(playerid,COLOR_SYSTEM_GM,mess);
	return 1;
}
Unfortunately, all other commands are made in ZCMD and I need help to see why it does not work..
Reply


Messages In This Thread
Problem regarding changepass cmd. - by Somalez - 12.11.2014, 17:35
Re: Problem regarding changepass cmd. - by AdHaM612 - 12.11.2014, 18:15
Re: Problem regarding changepass cmd. - by Somalez - 13.11.2014, 12:37
Re: Problem regarding changepass cmd. - by Riddick94 - 13.11.2014, 12:53
Re: Problem regarding changepass cmd. - by Somalez - 13.11.2014, 14:08
Re: Problem regarding changepass cmd. - by Riddick94 - 13.11.2014, 14:25
Re: Problem regarding changepass cmd. - by Somalez - 13.11.2014, 14:31
Re: Problem regarding changepass cmd. - by biker122 - 13.11.2014, 16:45
Re: Problem regarding changepass cmd. - by Somalez - 13.11.2014, 16:54
Re: Problem regarding changepass cmd. - by Kwarde - 13.11.2014, 17:07

Forum Jump:


Users browsing this thread: 2 Guest(s)