blob: a75fa450d3a351193b9789fb442000faec3b059f (
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
|
//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose:
//
// $NoKeywords: $
//
//=============================================================================//
#include "cbase.h"
#include "../EventLog.h"
#include "KeyValues.h"
class CTFCEventLog : public CEventLog
{
private:
typedef CEventLog BaseClass;
public:
virtual ~CTFCEventLog() {};
public:
bool PrintEvent( KeyValues * event ) // override virtual function
{
if ( BaseClass::PrintEvent( event ) )
{
return true;
}
if ( Q_strcmp(event->GetName(), "cstrike_") == 0 )
{
return PrintCStrikeEvent( event );
}
return false;
}
protected:
bool PrintCStrikeEvent( KeyValues * event ) // print Mod specific logs
{
// const char * name = event->GetName() + Q_strlen("cstrike_"); // remove prefix
return false;
}
};
CTFCEventLog g_TFCEventLog;
//-----------------------------------------------------------------------------
// Singleton access
//-----------------------------------------------------------------------------
IGameSystem* GameLogSystem()
{
return &g_TFCEventLog;
}
|