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/shared/tf/tf_xp_source.h | |
| download | archived-source-engine-2018-hl2-src-master.tar.xz archived-source-engine-2018-hl2-src-master.zip | |
Diffstat (limited to 'game/shared/tf/tf_xp_source.h')
| -rw-r--r-- | game/shared/tf/tf_xp_source.h | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/game/shared/tf/tf_xp_source.h b/game/shared/tf/tf_xp_source.h new file mode 100644 index 0000000..2d57e84 --- /dev/null +++ b/game/shared/tf/tf_xp_source.h @@ -0,0 +1,41 @@ +//========= Copyright Valve Corporation, All rights reserved. ============// +// +// Purpose: Holds XP source data +// +// $NoKeywords: $ +//=============================================================================// + +#ifndef TF_XP_SOURCE_H +#define TF_XP_SOURCE_H +#ifdef _WIN32 +#pragma once +#endif + +#include "gcsdk/protobufsharedobject.h" +#include "tf_gcmessages.h" + +#ifdef GC + #include "tf_gc.h" +#endif + +//--------------------------------------------------------------------------------- +// Purpose: Contains a delta for a player's XP +//--------------------------------------------------------------------------------- +class CXPSource : public GCSDK::CProtoBufSharedObject< CMsgTFXPSource, k_EEconTypeXPSource > +{ +public: + CXPSource(); +#ifdef GC + CXPSource( CMsgTFXPSource msg ); + DECLARE_CLASS_MEMPOOL( CXPSource ); + + virtual bool BYieldingAddInsertToTransaction( GCSDK::CSQLAccess & sqlAccess ); + virtual bool BYieldingAddWriteToTransaction( GCSDK::CSQLAccess & sqlAccess, const CUtlVector< int > &fields ); + virtual bool BYieldingAddRemoveToTransaction( GCSDK::CSQLAccess & sqlAccess ); + + void WriteToRecord( CSchPlayerXPSources *pWarData ) const; + void ReadFromRecord( const CSchPlayerXPSources & warData ); +#endif // GC +}; + +#endif // TF_XP_SOURCE_H |