Counter Strike : Global Offensive Source Code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

52 lines
1.6 KiB

  1. //========= Copyright � 1996-2005, Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. //=============================================================================//
  6. #ifndef ENTITYPARTICLETRAIL_H
  7. #define ENTITYPARTICLETRAIL_H
  8. #ifdef _WIN32
  9. #pragma once
  10. #endif
  11. #include "baseparticleentity.h"
  12. #include "entityparticletrail_shared.h"
  13. //-----------------------------------------------------------------------------
  14. // Spawns particles after the entity
  15. //-----------------------------------------------------------------------------
  16. class CEntityParticleTrail : public CBaseParticleEntity
  17. {
  18. DECLARE_DATADESC();
  19. DECLARE_CLASS( CEntityParticleTrail, CBaseParticleEntity );
  20. DECLARE_SERVERCLASS();
  21. public:
  22. static CEntityParticleTrail *Create( CBaseEntity *pTarget, const EntityParticleTrailInfo_t &info, CBaseEntity *pConstraint );
  23. static void Destroy( CBaseEntity *pTarget, const EntityParticleTrailInfo_t &info );
  24. void Spawn();
  25. virtual void UpdateOnRemove();
  26. // Force our constraint entity to be trasmitted
  27. virtual void SetTransmit( CCheckTransmitInfo *pInfo, bool bAlways );
  28. // Clean up when the entity goes away.
  29. virtual void NotifySystemEvent( CBaseEntity *pNotify, notify_system_event_t eventType, const notify_system_event_params_t &params );
  30. private:
  31. void AttachToEntity( CBaseEntity *pTarget );
  32. void IncrementRefCount();
  33. void DecrementRefCount();
  34. CNetworkVar( int, m_iMaterialName );
  35. CNetworkVarEmbedded( EntityParticleTrailInfo_t, m_Info );
  36. CNetworkHandle( CBaseEntity, m_hConstraintEntity );
  37. int m_nRefCount;
  38. };
  39. #endif // ENTITYPARTICLETRAIL_H