blob: 46bb41e5d02eca0282188e8edb1f4c6007ce188f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
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
|