diff options
| author | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
|---|---|---|
| committer | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
| commit | 3bf9df6b2785fa6d951086978a3e66f49427166a (patch) | |
| tree | 2c0f1f0c63c4832882bc93814ebd2c2b1c6224e5 /game/server/tf/func_forcefield.h | |
| download | archived-source-engine-2018-hl2-src-master.tar.xz archived-source-engine-2018-hl2-src-master.zip | |
Diffstat (limited to 'game/server/tf/func_forcefield.h')
| -rw-r--r-- | game/server/tf/func_forcefield.h | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/game/server/tf/func_forcefield.h b/game/server/tf/func_forcefield.h new file mode 100644 index 0000000..46bb41e --- /dev/null +++ b/game/server/tf/func_forcefield.h @@ -0,0 +1,41 @@ +//========= Copyright Valve Corporation, All rights reserved. ============// +// +// Purpose: +// +//============================================================================= + +#ifndef FUNC_FORCEFIELD_H +#define FUNC_FORCEFIELD_H +#ifdef _WIN32 +#pragma once +#endif + +#include "modelentities.h" + +//----------------------------------------------------------------------------- +// Purpose: Visualizes a forcefield +//----------------------------------------------------------------------------- +DECLARE_AUTO_LIST( IFuncForceFieldAutoList ); + +class CFuncForceField : public CFuncBrush, public IFuncForceFieldAutoList +{ + DECLARE_CLASS( CFuncForceField, CFuncBrush ); +public: + DECLARE_DATADESC(); + DECLARE_SERVERCLASS(); + + virtual void Spawn( void ) OVERRIDE; + + virtual int UpdateTransmitState( void ) OVERRIDE; + virtual int ShouldTransmit( const CCheckTransmitInfo *pInfo ) OVERRIDE; + virtual bool ShouldCollide( int collisionGroup, int contentsMask ) const OVERRIDE; + + virtual void TurnOff( void ) OVERRIDE; + virtual void TurnOn( void ) OVERRIDE; + +private: + void SetActive( bool bActive ); +}; + +bool PointsCrossForceField( const Vector& vecStart, const Vector &vecEnd, int nTeamToIgnore = TEAM_UNASSIGNED ); +#endif // FUNC_FORCEFIELD_H |