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

Players banned for dying?


Post New Thread Reply   
 
Thread Tools Display Modes
Dr!fter
The Salt Boss
Join Date: Mar 2007
Old 06-21-2015 , 16:21   Re: Players banned for dying?
Reply With Quote #11

I made a plugin to block this, it however requires dhooks. As far as I can tell mp_autokick works, however this disables other kicks which I feel are important (afk kicker, tk/ta kicker and a few others iirc). The plugin simply stops punishing suicides.

PHP Code:
#include <sourcemod>
#include <dhooks>

Handle hSuicidePenalty;

public 
void OnPluginStart()
{
    
Handle temp LoadGameConfigFile("suicide.games");
    
    if(
temp == INVALID_HANDLE)
    {
        
SetFailState("Failed to locate suicide.games.txt");
    }
    
    
int offset;
    
    
offset GameConfGetOffset(temp"UseSuicidePenalty");
    
hSuicidePenalty DHookCreate(offsetHookType_GameRulesReturnType_BoolThisPointer_IgnoreUseSuicidePenalty);
    
    
CloseHandle(temp);
}

public 
OnMapStart()
{
    
//Hook Gamerules function in map start
    
DHookGamerules(hSuicidePenaltytrue);
}

public 
MRESReturn UseSuicidePenalty(Handle hReturn)
{
    
DHookSetReturn(hReturnfalse);
    return 
MRES_Override;

Gamedata: suicide.games.txt

Code:
"Games"
{
	"csgo"
	{
		"Offsets"
		{
			"UseSuicidePenalty"
			{
				"windows"	"149"
				"linux"		"150"
			}
		}
	}
}

Last edited by Dr!fter; 06-21-2015 at 16:22.
Dr!fter is offline
BustedRider
Senior Member
Join Date: Dec 2008
Location: Canada/QC
Old 01-06-2016 , 15:55   Re: Players banned for dying?
Reply With Quote #12

what you mean require dhooks !?
__________________
BustedRider is offline
BustedRider
Senior Member
Join Date: Dec 2008
Location: Canada/QC
Old 01-06-2016 , 15:59   Re: Players banned for dying?
Reply With Quote #13

Cause i just downloaded a dhooks.inc from google and it doesnt work to compile
__________________
BustedRider is offline
BustedRider
Senior Member
Join Date: Dec 2008
Location: Canada/QC
Old 01-06-2016 , 16:00   Re: Players banned for dying?
Reply With Quote #14

SourcePawn Compiler 1.8.0-dev+5439
Copyright (c) 1997-2006 ITB CompuPhase
Copyright (c) 2004-2015 AlliedModders LLC

extra/dhooks.inc(187) : warning 237: coercing functions to and from primitives is unsupported and will be removed in the future
extra/dhooks.inc(19 : warning 237: coercing functions to and from primitives is unsupported and will be removed in the future
extra/dhooks.inc(210) : warning 237: coercing functions to and from primitives is unsupported and will be removed in the future
Code size: 3272 bytes
Data size: 2336 bytes
Stack/heap size: 16384 bytes
__________________
BustedRider is offline
WildCard65
Veteran Member
Join Date: Aug 2013
Location: Canada
Old 01-06-2016 , 16:49   Re: Players banned for dying?
Reply With Quote #15

Use this dhooks: https://forums.alliedmods.net/showthread.php?t=180114
WildCard65 is offline
ttz
New Member
Join Date: Jul 2015
Old 01-23-2016 , 11:09   Re: Players banned for dying?
Reply With Quote #16

Hi!

I don't have acces to my server ssh,only the ftp,
so how can I compile this plugin since there's the dhooks dependencies

(The server is linux)

thanks, best regards
ttz is offline
ddhoward
Veteran Member
Join Date: May 2012
Location: California
Old 01-23-2016 , 11:25   Re: Players banned for dying?
Reply With Quote #17

Quote:
Originally Posted by ttz View Post
Hi!

I don't have acces to my server ssh,only the ftp,
so how can I compile this plugin since there's the dhooks dependencies

(The server is linux)

thanks, best regards
Do what everyone else does and compile it on your own computer at home.
__________________
ddhoward is offline
RealEdan
Member
Join Date: Dec 2016
Location: United States
Old 07-08-2019 , 05:24   Re: Players banned for dying?
Reply With Quote #18

I don't think this plugin works any more Have DHooks installed correctly, gamedata file installed correctly, still getting kicked after 5 deaths.

3 Years Late, but this would be still really useful to me D:

Hep
__________________
RealEdan is offline
TomL.
Veteran Member
Join Date: Oct 2017
Location: Germany
Old 07-08-2019 , 22:29   Re: Players banned for dying?
Reply With Quote #19

mp_autokick 0 should do the trick
TomL. is offline
RealEdan
Member
Join Date: Dec 2016
Location: United States
Old 07-09-2019 , 02:24   Re: Players banned for dying?
Reply With Quote #20

Not when I utilize default autokick for players
__________________
RealEdan is offline
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 18:11.


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