הפונקציה בוויקי:
http://wiki.sa-mp.com/wiki/OnRconLoginAttempt
הפונקציה פועלת כשמישהו מנסה לעשות /RCON LOGIN גם אם הוא טועה וגם אם לא.
public OnRconLoginAttempt(
ip[],
password[],
success)
כתום - האייפי של השחקן
אדום - הסיסמא שהוא הקיש
ירוק - הצליח , ! אם הוא לא הצליח..
הנה דוגמא בשבילכם:
PHP Code:
public OnRconLoginAttempt(ip[], password[], success)
{
if(!success) //If the password was incorrect
{
printf("FAILED RCON LOGIN BY IP %s USING PASSWORD %s",ip, password);
new pip[16];
for(new i=0; i<MAX_PLAYERS; i++) //Loop through all players
{
GetPlayerIp(i, pip, sizeof(pip));
if(!strcmp(ip, pip, true)) //If a player's IP is the IP that failed the login
{
SendClientMessage(i, 0xFFFFFFFF, "Wrong Password. Bye!"); //Send a message
Ban(i); //They are now banned.
}
}
}
return 1;
}
הבנו?
סבבה 
כל שאלה על תכנות בכללי תוכלו לשלוח לי פרטית או לפתוח אשכול