Doesn't ban me. - 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: Doesn't ban me. (
/showthread.php?tid=542981)
Doesn't ban me. -
Glossy42O - 23.10.2014
Well i got a rcon pass, ok?
Well my rcon is long asf..well i did /rcon login 2 (Fake pass)
To see if dialog ban works it does but if i reconnect i am not banned BUT still in samp.ban?
Lol...Anyway to fix it?
EDIT: if i do /rcon login 2421412421 (fake pass) it doesn't show dialog when i do /rcon pass 2 it shows..lol
Re: Doesn't ban me. -
Glossy42O - 24.10.2014
Bump
Re: Doesn't ban me. -
Stanford - 24.10.2014
a fast example from sa-mp wiki:
pawn Код:
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;
}
Explanation:-
this code gets the ip of the person that typed the failed password and it searches if there are other players that have the same ip and ban them all together.
any feedback would be appreciated!
Re: Doesn't ban me. -
Steel_ - 24.10.2014
-remove-
Re: Doesn't ban me. -
Glossy42O - 24.10.2014
Ah nevermind it does ban me but 1 prob
If i type /rcon login 2 it shows me the dialog banned if i do lots of numbers it doesn't like /rcon login 3412421
Re: Doesn't ban me. -
Glossy42O - 25.10.2014
Bump.
Btw am i allowed to bump after a day?
Re: Doesn't ban me. -
Stanford - 25.10.2014
I think that you are allowed to bump after 24 hours; Anyway, about your problem I don't know I have never faced something like that as I remember I was going into servers (ages ago) and start guessing the rcon before I start to code and it was banning me after several attempts or something!.
Re: Doesn't ban me. -
Glossy42O - 25.10.2014
oh okay
Re: Doesn't ban me. -
Glossy42O - 27.10.2014
Bump.
Could someone help? it bans me but now it just doesn't show the dialog ban box only if i do /rcon login 23421321
only /rcon login 2 :\ help.
Re: Doesn't ban me. -
M0HAMMAD - 27.10.2014
Don't use RCON .
pawn Код:
new AdminLevel[MAX_PLAYERS];
use adminlevel or ... and in your cmds or ...
pawn Код:
if(AdminLevel[playerid] == 1)//vip
save and load in login and register ...
this will be better.