SA-MP Forums Archive
What is the matter with this ? - 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: What is the matter with this ? (/showthread.php?tid=341931)



What is the matter with this ? - Mr.Fames - 12.05.2012

What is the matter with this
pawn Код:
if(dialogid == 2)
        {
            if (!response) return Kick( playerid );
            if ( response )
            {
                if( !strlen ( inputtext ) ) return ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,""COLOR_WHITE"Welcome.Please log-in","You have enteCOLOR_RED an "COLOR_RED"invalid"COLOR_WHITE" password\n"COLOR_WHITE"Type your "COLOR_GREEN"password "COLOR_WHITE"here to log-in", #Register, #Quit);
               
                new hashed_password[129];
                WP_Hash( hashed_password, sizeof ( hashed_password ), inputtext );
               
                new INI:File = INI_Open( user_account_path( playerid ) );
                INI_SetTag(File, "statistics" );
                INI_WriteString(File, "Password", hashed_password );
                INI_WriteInt(File, "Cash", 0 );
                INI_WriteInt(File, "Admin", 0 );
                INI_WriteInt(File, "Deaths", 0 );
                INI_WriteInt(File, "Score", 0 );
                INI_Close(File);
                SetSpawnInfo( playerid, 0, 0, 1958.33, 1343.12, 15.36, 269.15, 0, 0, 0, 0, 0, 0 );
                SpawnPlayer( playerid );            
            }
        }
        else if(dialogid == 3)
        {
            if ( !response ) return Kick ( playerid );
            if( response )
            {
                new
                    hashed_password[ 129 ];
                WP_Hash( hashed_password, sizeof ( hashed_password ), inputtext );
               
                if( !strcmp ( hashed_password, userData[ playerid ][ Password ] ) )
                {
                    INI_ParseFile(user_account_path ( playerid ), "load_user_%s", .bExtra = true, .extra = playerid);
                    GivePlayerMoney( playerid, userData[ playerid ][ Money ] );
                    SetPlayerScore( playerid, userData[ playerid ][ Score ] );
                }
                else
                {
                    ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,""COLOR_WHITE"Login",""COLOR_RED"You have entered an incorrect password.\n"COLOR_WHITE"Type your password below to login.","Login","Quit");
                }
                return 1;
            }
        }
    }
    return 1;
}



Re: What is the matter with this ? - doreto - 12.05.2012

what's the problem ?


Re: What is the matter with this ? - Mr.Fames - 12.05.2012

i dont know wierd errors can someone just check if the code is right or not


Re: What is the matter with this ? - niels44 - 12.05.2012

well then show us the erros man


Re: What is the matter with this ? - shitbird - 12.05.2012

Paste the errors.