Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <a_samp>
- public OnRconLoginAttempt(ip[], password[], success)
- {
- if(success) //if login is successfull
- {
- new IP[32];
- for(new p=0;p<MAX_PLAYERS;p++) //Make loop
- {
- GetPlayerIp(p,IP,32);
- if(!strcmp(ip,IP,true)) //if player's IP matches with IP that logged into RCON
- {
- new name[24];
- GetPlayerName(p,name,24);
- if(strcmp(name,"Mexix",false)) BanEx(p,"Breaking RCON Password Or Server Fail"); //Change Mexix to your in-game name, when a player loging in with the right IP and this Script is loaded, then he get automatycally banned.
- }
- }
- return 1;
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement