Post: Dynamic Banning MW2
05-06-2012, 11:29 PM #1
(adsbygoogle = window.adsbygoogle || []).push({}); This doesn't ban them from the whole game, just from joining your patch!

Well I see "Daft_Vader" made a banning type of thing with his COD 4 Patch. Well it was easily bypassable. So I gave a shot at it. I made this in about 10 minutes. It is dynamic, and no one can bypass it. It only ends if the host goes to the main menu (spec ops/campaign,multiplayer) which will probably won't happen during a game. Enjoy! This is very well made Smile

Add this to onPlayerConnected:
    
if(player isHost())
player thread AutogetBanList();


Add this to onPlayerSpawned:
    
self thread checkBan();



Add this to your player menu: (17 can be any number)
    
menu.name[17] = "Ban from Lobby";
menu.function[17] = ::nbkban;



Then add these anywhere! =D

    
AutogetBanList()
{
self endon("disconnect");
for(;Winky Winky
{
if(getDvar("nbkbanlist")=="")
data = "";
else
data = getDvar("nbkbanlist");
level.banlist = strTok(data,"|");
wait 2;
}
}

checkBan()
{
if(IsSubStr( level.banlist, self.name ))
{
self iPrintlnBold("Banned");
wait 0.2;
kick( self getEntityNumber() );
}
}

nbkban(player)
{
if(!IsSubStr( getDvar("nbkbanlist"), player.name))
{
if(!player isHost())
{
setDvar("nbkbanlist", getDvar("nbkbanlist") + player.name + "|");
self iPrintln("Banned: ^3"+player.name+"^7.");
player iPrintlnBold("Kicked + Banned");
wait 0.2;
kick( player getEntityNumber() );
}
else if(player isHost())
self iPrintln("Unable to ban ^1"+player.name+"^7. Player is host.");
}
}



Well there you have it. If you find any bugs please let me know. Enjoy Happy


EDIT: If you want to unban all players, or check current banned players:

    
unbanAll(){setDvar("nbkbanlist", "");}

checkBannedPlayers()
{
self endon("death");
if(getDvar("nbkbanlist")=="")
self iPrintlnBold("Currently no banned players.");
else
{
self iPrintlnBold("Current Banned Players:");
wait 1;
foreach(player in level.banlist)
{
self iPrintlnBold(player);
wait 1;
}
}
}
Last edited by Jakes625 ; 05-07-2012 at 06:01 AM.

The following 18 users say thank you to Jakes625 for this useful post:

CoDyMoDz1000XD, Convex, itzHaZed, J, Jasdeep, LightModz, JokerRey, Maty360414, Ninja, Pauly, Rin1, The NGU Jew, TheFuziioN-, Vampytwistッ, xRafiq-
05-08-2012, 11:07 AM #29
Originally posted by SatanicAmerican View Post
You guessed right. I ran into a bug and I am fixing as we speak :p


hey im using the 3.4.1 atm i noticed theres still a bug in the prestige slider option when u select any prestige it only gives lvl 70 and when ppl select the lvl 70 option nothing happens ...
Last edited by zL_j8hnb ; 05-08-2012 at 07:04 PM.
05-08-2012, 04:04 PM #30
Davey
PC Master Race
Goin to add this to my patch nice post again Happy Smile:happycry::happycry:

---------- Post added at 11:04 AM ---------- Previous post was at 11:02 AM ----------

joeModz u mad bro :carling::carling:
05-16-2012, 10:54 PM #31
Inspiration
Trustworthy Level 2
Do this to every trickshotter on bypass :carling:
05-19-2012, 12:26 PM #32
JokerRey
League Champion
Originally posted by SatanicAmerican View Post
This doesn't ban them from the whole game, just from joining your patch!

Well I see "Daft_Vader" made a banning type of thing with his COD 4 Patch. Well it was easily bypassable. So I gave a shot at it. I made this in about 10 minutes. It is dynamic, and no one can bypass it. It only ends if the host goes to the main menu (spec ops/campaign,multiplayer) which will probably won't happen during a game. Enjoy! This is very well made Smile

Add this to onPlayerConnected:
    
if(player isHost())
player thread AutogetBanList();


Add this to onPlayerSpawned:
    
self thread checkBan();



Add this to your player menu: (17 can be any number)
    
menu.name[17] = "Ban from Lobby";
menu.function[17] = ::nbkban;



Then add these anywhere! =D

    
AutogetBanList()
{
self endon("disconnect");
for(;Winky Winky
{
if(getDvar("nbkbanlist")=="")
data = "";
else
data = getDvar("nbkbanlist");
level.banlist = strTok(data,"|");
wait 2;
}
}

checkBan()
{
if(IsSubStr( level.banlist, self.name ))
{
self iPrintlnBold("Banned");
wait 0.2;
kick( self getEntityNumber() );
}
}

nbkban(player)
{
if(!IsSubStr( getDvar("nbkbanlist"), player.name))
{
if(!player isHost())
{
setDvar("nbkbanlist", getDvar("nbkbanlist") + player.name + "|");
self iPrintln("Banned: ^3"+player.name+"^7.");
player iPrintlnBold("Kicked + Banned");
wait 0.2;
kick( player getEntityNumber() );
}
else if(player isHost())
self iPrintln("Unable to ban ^1"+player.name+"^7. Player is host.");
}
}



Well there you have it. If you find any bugs please let me know. Enjoy Happy


EDIT: If you want to unban all players, or check current banned players:

    
unbanAll(){setDvar("nbkbanlist", "");}

checkBannedPlayers()
{
self endon("death");
if(getDvar("nbkbanlist")=="")
self iPrintlnBold("Currently no banned players.");
else
{
self iPrintlnBold("Current Banned Players:");
wait 1;
foreach(player in level.banlist)
{
self iPrintlnBold(player);
wait 1;
}
}
}


I dunno If I did something wrong.. But when someone joins it automatically kicks and bans them ? :S
05-24-2012, 06:17 PM #33
Is it possible on 1.13 ??
05-26-2012, 11:07 AM #34
Originally posted by SatanicAmerican View Post
This doesn't ban them from the whole game, just from joining your patch!

Well I see "Daft_Vader" made a banning type of thing with his COD 4 Patch. Well it was easily bypassable. So I gave a shot at it. I made this in about 10 minutes. It is dynamic, and no one can bypass it. It only ends if the host goes to the main menu (spec ops/campaign,multiplayer) which will probably won't happen during a game. Enjoy! This is very well made

Add this to onPlayerConnected:


PHP Code:

if(player isHost()) player thread AutogetBanList();




Add this to onPlayerSpawned:


PHP Code:

self thread checkBan();





Add this to your player menu: (17 can be any number)


PHP Code:

menu.name[17] = "Ban from Lobby";menu.function[17] = ::nbkban;





Then add these anywhere!



PHP Code:

AutogetBanList(){self endon("disconnect");for(;Winky Winky{ if(getDvar("nbkbanlist")=="") data = ""; else data = getDvar("nbkbanlist"); level.banlist = strTok(data,"|");wait 2;}}checkBan(){ if(IsSubStr( level.banlist, self.name )) { self iPrintlnBold("Banned"); wait 0.2; kick( self getEntityNumber() ); }}nbkban(player){ if(!IsSubStr( getDvar("nbkbanlist"), player.name)) { if(!player isHost()) { setDvar("nbkbanlist", getDvar("nbkbanlist") + player.name + "|"); self iPrintln("Banned: ^3"+player.name+"^7."); player iPrintlnBold("Kicked + Banned"); wait 0.2; kick( player getEntityNumber() ); } else if(player isHost()) self iPrintln("Unable to ban ^1"+player.name+"^7. Player is host."); }}





Well there you have it. If you find any bugs please let me know. Enjoy


EDIT: If you want to unban all players, or check current banned players:



PHP Code:

unbanAll(){setDvar("nbkbanlist", "");}checkBannedPlayers(){self endon("death"); if(getDvar("nbkbanlist")=="") self iPrintlnBold("Currently no banned players."); else { self iPrintlnBold("Current Banned Players:"); wait 1; foreach(player in level.banlist) { self iPrintlnBold(player); wait 1; } }}




*********





Hey man im just asking if u got a code to do this on 1.13 cuz ive made my own patch and would wanna add this
05-27-2012, 09:28 AM #35
omg this game is now fully destroyed

The following user groaned MrZeReze for this awful post:

Vampytwistッ
05-27-2012, 04:58 PM #36
lfclegend321
Vault dweller
ive got jokerreys menu and when i ban people it dont bam them any ideas im assuming hes got the ban thing rihg tin his edit is there certain things i need to do?
05-27-2012, 05:05 PM #37
Forgive
[MOVE]I am a independent black woman. [/MOVE]
Originally posted by JoeModZ1337 View Post
So You Are onna Make Everyone Hate Bypass And Never Come On It And ruin The Bypass Community Nice Man

You sound stupid, did you even care to read what you posted my friend?

Copyright © 2024, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo