blob: ebb2436aaa42088466d03cac08ea7505af595f24 (
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
|
//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose:
//
// $Workfile: $
// $Date: $
// $NoKeywords: $
//=============================================================================//
#include "cbase.h"
#include "c_basetempentity.h"
#include "c_te_legacytempents.h"
#include "tier0/vprof.h"
// memdbgon must be the last include file in a .cpp file!!!
#include "tier0/memdbgon.h"
//-----------------------------------------------------------------------------
// Purpose: Kills Player Attachments
//-----------------------------------------------------------------------------
class C_TEKillPlayerAttachments : public C_BaseTempEntity
{
public:
DECLARE_CLASS( C_TEKillPlayerAttachments, C_BaseTempEntity );
DECLARE_CLIENTCLASS();
C_TEKillPlayerAttachments( void );
virtual ~C_TEKillPlayerAttachments( void );
virtual void PostDataUpdate( DataUpdateType_t updateType );
public:
int m_nPlayer;
};
//-----------------------------------------------------------------------------
// Purpose:
//-----------------------------------------------------------------------------
C_TEKillPlayerAttachments::C_TEKillPlayerAttachments( void )
{
m_nPlayer = 0;
}
//-----------------------------------------------------------------------------
// Purpose:
//-----------------------------------------------------------------------------
C_TEKillPlayerAttachments::~C_TEKillPlayerAttachments( void )
{
}
//-----------------------------------------------------------------------------
// Purpose:
// Input : bool -
//-----------------------------------------------------------------------------
void C_TEKillPlayerAttachments::PostDataUpdate( DataUpdateType_t updateType )
{
VPROF( "C_TEKillPlayerAttachments::PostDataUpdate" );
tempents->KillAttachedTents( m_nPlayer );
}
void TE_KillPlayerAttachments( IRecipientFilter& filter, float delay,
int player )
{
tempents->KillAttachedTents( player );
}
IMPLEMENT_CLIENTCLASS_EVENT_DT(C_TEKillPlayerAttachments, DT_TEKillPlayerAttachments, CTEKillPlayerAttachments)
RecvPropInt( RECVINFO(m_nPlayer)),
END_RECV_TABLE()
|