Raised This Month: $32 Target: $400
 8% 

[CS:GO] WarMod [BFG] <22.09.26.1915, 26-Sept-2022>


Post New Thread Reply   
 
Thread Tools Display Modes
Chesterfield
Senior Member
Join Date: Apr 2013
Old 02-15-2015 , 18:23   Re: [CS:GO] WarMod [BFG] <Beta v0.3.3.4, 12-Feb-2015>
Reply With Quote #511

Quote:
Originally Posted by Totys View Post
Change cvar
mp_autokick 1 // Kick idle/team-killing players (mm)

I modified the code to ban by quit and saves panel sourcemod, but also bans the spectadores coming out. I still have it for repair
Quote:
Originally Posted by versatile_bfg View Post
.I'll look into the code you PM'd me.
Really looking foward this! keep up the good work!
Chesterfield is offline
versatile_bfg
Veteran Member
Join Date: Feb 2012
Old 02-15-2015 , 20:16   Re: [CS:GO] WarMod [BFG] <Beta v0.3.3.4, 12-Feb-2015>
Reply With Quote #512

Quote:
Originally Posted by Chesterfield View Post
Really looking foward this! keep up the good work!
Should be out tonight or tomorrow night. I have coded it now. Just need to test it.

PHP Code:
/* BanOn Disconnect */
new bool:g_disconnect[MAXPLAYERS 1] = false;
new 
Handle:g_h_ban_on_disconnect INVALID_HANDLE;
new 
Handle:sv_kick_ban_duration;

public 
OnPluginStart()
{
    
LoadTranslations("basebans.phrases");
    
/* Ban Convars */
    
g_h_ban_on_disconnect CreateConVar("wm_ban_on_disconnect""0""Enable or disable players banned on disconnect if match is live"FCVAR_NOTIFY);
    
sv_kick_ban_duration FindConVar("sv_kick_ban_duration");

    
HookEvent("player_disconnect"Event_Player_Disc_PreEventHookMode_Pre);
}

public 
OnClientPutInServer(client)
{
    
g_disconnect[client] = false;
}

public 
OnClientDisconnect(client)
{
    if (
g_live && GetConVarBool(g_h_ban_on_disconnect) && g_disconnect[client] == true)
    {
        new 
String:reason[32] = "Disconnected from live match";
        new 
String:authid[32];
        
GetClientAuthId(clientAuthId_Steam2authidsizeof(authid));
        
        
ServerCommand("sm_addban %i %s %s"GetConVarInt(sv_kick_ban_duration), authidreason);
        
PrintToChatAll("\x01 \x09[\x04%s\x09]\x01 %t"CHAT_PREFIX"Banned player reason"authidGetConVarInt(sv_kick_ban_duration), reason);
        
g_disconnect[client] = false;
    }
}

public 
Event_Player_Disc_Pre(Handle:event, const String:name[], bool:dontBroadcast)
{
    if (!
IsActive(0true))
    {
        return;
    }
    
    new 
client GetClientOfUserId(GetEventInt(event"userid"));
    new 
String:reason[128];
    
GetEventString(event"reason"reasonsizeof(reason));
    
    if (
g_live && StrEqual(reason"Disconnect"))
    {
        
g_disconnect[client] = true
    }
    else 
    {
        
g_disconnect[client] = false;
    }

__________________
versatile_bfg is offline
Totys
Junior Member
Join Date: Sep 2014
Old 02-16-2015 , 03:02   Re: [CS:GO] WarMod [BFG] <Beta v0.3.3.4, 12-Feb-2015>
Reply With Quote #513

Quote:
Originally Posted by versatile_bfg View Post
Should be out tonight or tomorrow night. I have coded it now. Just need to test it.

PHP Code:
/* BanOn Disconnect */
new bool:g_disconnect[MAXPLAYERS 1] = false;
new 
Handle:g_h_ban_on_disconnect INVALID_HANDLE;
new 
Handle:sv_kick_ban_duration;

public 
OnPluginStart()
{
    
LoadTranslations("basebans.phrases");
    
/* Ban Convars */
    
g_h_ban_on_disconnect CreateConVar("wm_ban_on_disconnect""0""Enable or disable players banned on disconnect if match is live"FCVAR_NOTIFY);
    
sv_kick_ban_duration FindConVar("sv_kick_ban_duration");

    
HookEvent("player_disconnect"Event_Player_Disc_PreEventHookMode_Pre);
}

public 
OnClientPutInServer(client)
{
    
g_disconnect[client] = false;
}

public 
OnClientDisconnect(client)
{
    if (
g_live && GetConVarBool(g_h_ban_on_disconnect) && g_disconnect[client] == true)
    {
        new 
String:reason[32] = "Disconnected from live match";
        new 
String:authid[32];
        
GetClientAuthId(clientAuthId_Steam2authidsizeof(authid));
        
        
ServerCommand("sm_addban %i %s %s"GetConVarInt(sv_kick_ban_duration), authidreason);
        
PrintToChatAll("\x01 \x09[\x04%s\x09]\x01 %t"CHAT_PREFIX"Banned player reason"authidGetConVarInt(sv_kick_ban_duration), reason);
        
g_disconnect[client] = false;
    }
}

public 
Event_Player_Disc_Pre(Handle:event, const String:name[], bool:dontBroadcast)
{
    if (!
IsActive(0true))
    {
        return;
    }
    
    new 
client GetClientOfUserId(GetEventInt(event"userid"));
    new 
String:reason[128];
    
GetEventString(event"reason"reasonsizeof(reason));
    
    if (
g_live && StrEqual(reason"Disconnect"))
    {
        
g_disconnect[client] = true
    }
    else 
    {
        
g_disconnect[client] = false;
    }

Even I did not try but I see that avoids ban the spect leaving the game, which is the problem of code happens to you it was working with other commands or time directly in the code.
NO ban would be good to add spect ban
and stop bans 8 or 7 players, because if not follow by banning all if the server is empty. While there are 30 or 45 minutes should not be so.

you could add?

-------------------------------------------------- -

Also would be good that when 10 players after one minute if a player yet to put .r what kickee with reason "you not ready"

Last edited by Totys; 02-16-2015 at 03:03.
Totys is offline
Send a message via Skype™ to Totys
versatile_bfg
Veteran Member
Join Date: Feb 2012
Old 02-16-2015 , 06:16   Re: [CS:GO] WarMod [BFG] <Beta v0.3.3.4, 12-Feb-2015>
Reply With Quote #514

Quote:
Originally Posted by Totys View Post
Even I did not try but I see that avoids ban the spect leaving the game, which is the problem of code happens to you it was working with other commands or time directly in the code.
NO ban would be good to add spect ban
and stop bans 8 or 7 players, because if not follow by banning all if the server is empty. While there are 30 or 45 minutes should not be so.

you could add?
Yeah adding that now. I found that when I was testing. I did the code when I was a work ;)

Going to make it wm_max_players * .75 to get the cut off. So for 10*.75= 7.5 so 8, 9 and 10 should get banned.
6*.75 = 4.5 so 5, 6 will get banned [for 3v3]

Quote:
Originally Posted by Totys View Post
Also would be good that when 10 players after one minute if a player yet to put .r what kickee with reason "you not ready"
This would be hard. When do you start the timer. Would it be when first person readies up or when you have 10 players. What if only 1 readies up and the rest don't. Do they all get kicked? Or should I just use the same method as before with 3/4's of wm_max_players?
__________________

Last edited by versatile_bfg; 02-16-2015 at 06:21.
versatile_bfg is offline
izzyftw
New Member
Join Date: Feb 2015
Old 02-16-2015 , 06:42   Re: [CS:GO] WarMod [BFG] <Beta v0.3.3.4, 12-Feb-2015>
Reply With Quote #515

my maxplayers still 10/10 . can help me on teamviewer ? im hosting next tournament soon .
izzyftw is offline
versatile_bfg
Veteran Member
Join Date: Feb 2012
Old 02-16-2015 , 06:47   Re: [CS:GO] WarMod [BFG] <Beta v0.3.3.4, 12-Feb-2015>
Reply With Quote #516

Quote:
Originally Posted by izzyftw View Post
my maxplayers still 10/10 . can help me on teamviewer ? im hosting next tournament soon .
use 'maxplayers_override' on the command line on your server. This will fix the issue.

-maxplayers_override 12

make sure its an - and not a +
__________________

Last edited by versatile_bfg; 02-16-2015 at 06:48.
versatile_bfg is offline
izzyftw
New Member
Join Date: Feb 2015
Old 02-16-2015 , 12:11   Re: [CS:GO] WarMod [BFG] <Beta v0.3.3.4, 12-Feb-2015>
Reply With Quote #517

Quote:
Originally Posted by versatile_bfg View Post
use 'maxplayers_override' on the command line on your server. This will fix the issue.

-maxplayers_override 12

make sure its an - and not a +
it works bro ! thanks alot .
izzyftw is offline
Grandmaster
Junior Member
Join Date: Jan 2015
Old 02-17-2015 , 10:27   Re: [CS:GO] WarMod [BFG] <Beta v0.3.3.4, 12-Feb-2015>
Reply With Quote #518

Versatile,

Another suggestion:

Instead of having the info of who has not done /ready, is it possible to put an "UNREADY" in front of his name on the TAB menu?
Grandmaster is offline
Send a message via ICQ to Grandmaster Send a message via MSN to Grandmaster Send a message via Skype™ to Grandmaster
versatile_bfg
Veteran Member
Join Date: Feb 2012
Old 02-17-2015 , 17:07   Re: [CS:GO] WarMod [BFG] <Beta v0.3.3.4, 12-Feb-2015>
Reply With Quote #519

Quote:
Originally Posted by Grandmaster View Post
Versatile,

Another suggestion:

Instead of having the info of who has not done /ready, is it possible to put an "UNREADY" in front of his name on the TAB menu?
that will stuff up the clan tag grab to set team names.
__________________
versatile_bfg is offline
Grandmaster
Junior Member
Join Date: Jan 2015
Old 02-17-2015 , 17:39   Re: [CS:GO] WarMod [BFG] <Beta v0.3.3.4, 12-Feb-2015>
Reply With Quote #520

yep, but most of PUG do that, and it really easier to see it.

Another question, is there a way to understand why a demo is not being saved at a folder? i tried looking the logs for dem, demo, etc and have not found. Forgot to add my server is under Linux.

I saw this:
Beta 0.2.5.6 - 18-08-2014
- Fixed small bug on linux servers not recording demos
- Hopefully fixed small bug - chat with no msg

But what I see here is that in the folder:

drwxr-xr-x. 17 steam steam 16384 Feb 17 06:55 ..
-rw-rw-r--. 1 steam steam 1265422 Feb 17 19:25 2015-02-17-1858-6989-de_dust2-qnews-vs-pal_no_cebo.log
-rw-rw-r--. 1 steam steam 2049421 Feb 17 20:17 2015-02-17-1928-6989-de_mirage-coco_na_coco-vs-cucucucu.log
-rw-rw-r--. 1 steam steam 1093245 Feb 17 20:47 2015-02-17-2020-6989-de_nuke-zegzo_nazal-vs-lixos.log
-rw-rw-r--. 1 steam steam 1768178 Feb 17 210 2015-02-17-2050-6989-de_dust2-terrorists-vs-dal_cu_la_na_mata.log
-rw-rw-r--. 1 steam steam 0 Feb 17 22:15 2015-02-17-2138-6989-de_tuscan_fixes_csgo-xereca-vs-g._up.dem.bz2
-rw-rw-r--. 1 steam steam 1600308 Feb 17 22:15 2015-02-17-2138-6989-de_tuscan_fixes_csgo-xereca-vs-g._up.log
-rw-rw-r--. 1 steam steam 1822720 Feb 17 22:59 2015-02-17-2220-6989-de_cache-nip-vs-xerecona.log
[steam@localhost warmod]$

Last edited by Grandmaster; 02-17-2015 at 17:57.
Grandmaster is offline
Send a message via ICQ to Grandmaster Send a message via MSN to Grandmaster Send a message via Skype™ to Grandmaster
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 22:10.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode