Dialog Login
#1

-I have a problem, basically when you register a player spawns, and then when slogga rilogga password authentication "Password Incorrect" There is, as I upload?

-Another problem is that if the player is an admin, when you login and spawn, the login dialog reappears endlessly.

Код:
if(dialogid == 2)
	   	{
			if ( !response ) return Kick ( playerid );
	   		if( response )
	        {
	        	if(udb_hash(inputtext) == PlayerInfo[playerid][pPass])
	         	{
	          		INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
	          		SetSpawnInfo(playerid, 0, PlayerInfo[playerid][pSkin], PlayerInfo[playerid][pLastX], PlayerInfo[playerid][pLastY], PlayerInfo[playerid][pLastZ], PlayerInfo[playerid][pFacingAngle], 0, 0, 0, 0, 0, 0);
                    SpawnPlayer(playerid);
	          		GivePlayerMoney(playerid, PlayerInfo[playerid][pCash]);
	          		SetPlayerSkin(playerid, PlayerInfo[playerid][pSkin]);
	          		SetPlayerScore(playerid, PlayerInfo[playerid][pLevel]);
					SetPlayerHealth(playerid, PlayerInfo[playerid][pHealth]);
					SetPlayerArmour(playerid, PlayerInfo[playerid][pArmour]);
					SetPlayerInterior(playerid, PlayerInfo[playerid][pInt]);
					SetPlayerVirtualWorld(playerid, PlayerInfo[playerid][pVW]);
	       			format(tmp2, sizeof(tmp2), "~w~Welcome ~n~~y~   %s", GetName(playerid));
					GameTextForPlayer(playerid, tmp2, 5000, 1);
					TogglePlayerSpectating(playerid, 0);
       				{
          			ShowPlayerDialog(playerid,2,DIALOG_STYLE_PASSWORD,"Login","Benvenuto su SouthCity RolePlay\n\nQuesto account и giа esistente. Inserisci la tua password per effettuare il Login.","Login","Slogga");
			   		}
					return 1;
					}
				}
			}
        }
Reply
#2

Try dis.

PHP код:
if(dialogid == 2)
{
    if ( !
response ) return Kick playerid );
    if( 
response )
    {
        if(
udb_hash(inputtext) == PlayerInfo[playerid][pPass])
        {
            
INI_ParseFile(UserPath(playerid), "LoadUser_data", .bExtra true, .extra playerid);
            
SetSpawnInfo(playerid0PlayerInfo[playerid][pSkin], PlayerInfo[playerid][pLastX], PlayerInfo[playerid][pLastY], PlayerInfo[playerid][pLastZ], PlayerInfo[playerid][pFacingAngle], 000000);
            
SpawnPlayer(playerid);
            
GivePlayerMoney(playeridPlayerInfo[playerid][pCash]);
            
SetPlayerSkin(playeridPlayerInfo[playerid][pSkin]);
            
SetPlayerScore(playeridPlayerInfo[playerid][pLevel]);
            
SetPlayerHealth(playeridPlayerInfo[playerid][pHealth]);
            
SetPlayerArmour(playeridPlayerInfo[playerid][pArmour]);
            
SetPlayerInterior(playeridPlayerInfo[playerid][pInt]);
            
SetPlayerVirtualWorld(playeridPlayerInfo[playerid][pVW]);
            
format(tmp2sizeof(tmp2), "~w~Welcome ~n~~y~   %s"GetName(playerid));
            
GameTextForPlayer(playeridtmp250001);
            
TogglePlayerSpectating(playerid0);
            
ShowPlayerDialog(playerid,2,DIALOG_STYLE_PASSWORD,"Login","Benvenuto su SouthCity RolePlay\n\nQuesto account и giа esistente. Inserisci la tua password per effettuare il Login.","Login","Slogga");
            }
          }
     }
     return 
1;

Reply
#3

and the dialog of login? insert password?
Reply
#4

Editted my previous post.

Does that work?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)