SA-MP Forums Archive
[Ajuda] OnRconLoginAttempt - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] OnRconLoginAttempt (/showthread.php?tid=481666)



OnRconLoginAttempt - kixtz - 16.12.2013

Bom galera tava vendo esse tуpico no wiki do samp sу que a mensagem do SendClientMessage nгo aparace sу aparece server closed connection, estou usando ъltima versгo do samp.
PHP код:
public OnRconLoginAttempt(ip[], password[], success)
{
    if(!
success//If the password was incorrect
    
{
        
printf("FAILED RCON LOGIN BY IP %s USING PASSWORD %s",ippassword);
        new 
pip[16];
        for(new 
i=0i<MAX_PLAYERSi++) //Loop through all players
        
{
            
GetPlayerIp(ipipsizeof(pip));
            if(!
strcmp(ippiptrue)) //If a player's IP is the IP that failed the login
            
{
                
SendClientMessage(i0xFFFFFFFF"Wrong Password. Bye!"); //Send a message
                
Ban(i); //They are now banned.
            
}
        }
    }
    return 
1;




Re: OnRconLoginAttempt - Gii - 16.12.2013

BUG Kick/Ban SA-MP 0.3x.

http://forum.sa-mp.com/showpost.php?...postcount=2486


Re: OnRconLoginAttempt - kixtz - 16.12.2013

Ok, mais poderia me explicar o que seria esse define #define Kick(%0) com porcentagem ? estou aprendendo ainda rs


Re: OnRconLoginAttempt - focaximubh - 17.12.2013

Kick(playerid);

praticamente a mesma coisa no caso й quase que um macro isso que foi criado '-'