From a0c29e7dd67abb15c74c85f07741784877edfdcd Mon Sep 17 00:00:00 2001 From: Joe Ludwig Date: Mon, 2 Sep 2013 11:39:10 -0700 Subject: General: * Fixed a variety of server browser issues with mods based on this SDK * Fixed many warnings on various platforms * Added source code for fgdlib and raytrace * Updated many source files with the latest shared source from TF2. OSX: * Added support for Xcode 4.6 * Switched OSX builds to use Xcode instead of makefiles * Moved libs from src/lib/osx32 to src/lib/public/osx32 or src/lib/common/osx32 to match windows better. Linux: * Moved libs from src/lib/linux32 to src/lib/public/linux32 or src/lib/common/linux32 to match windows better. --- mp/src/game/server/doors.cpp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'mp/src/game/server/doors.cpp') diff --git a/mp/src/game/server/doors.cpp b/mp/src/game/server/doors.cpp index 53abb829..d8f06c49 100644 --- a/mp/src/game/server/doors.cpp +++ b/mp/src/game/server/doors.cpp @@ -340,12 +340,11 @@ void CBaseDoor::Spawn() #ifdef TF_DLL if ( TFGameRules() && TFGameRules()->IsMultiplayer() ) { - if ( !m_flBlockDamage ) - { - // Never block doors in TF2 - to prevent various exploits. - m_flBlockDamage = 10.f; - } + // Never block doors in TF2 - to prevent various exploits. + m_bIgnoreNonPlayerEntsOnBlock = true; } +#else + m_bIgnoreNonPlayerEntsOnBlock = false; #endif // TF_DLL } @@ -1207,6 +1206,11 @@ void CBaseDoor::Blocked( CBaseEntity *pOther ) pOther->TakeDamage( CTakeDamageInfo( this, this, m_flBlockDamage, DMG_CRUSH ) ); } } + // If set, ignore non-player ents that block us. Mainly of use in multiplayer to prevent exploits. + else if ( pOther && !pOther->IsPlayer() && m_bIgnoreNonPlayerEntsOnBlock ) + { + return; + } // If we're set to force ourselves closed, keep going if ( m_bForceClosed ) -- cgit v1.2.3