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.

94 lines
2.5 KiB

  1. //========= Copyright � 1996-2005, Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. //=============================================================================//
  6. #ifndef WEAPON_MOLOTOV_H
  7. #define WEAPON_MOLOTOV_H
  8. #ifdef _WIN32
  9. #pragma once
  10. #endif
  11. #include "weapon_basecsgrenade.h"
  12. #if defined( CLIENT_DLL )
  13. #define CMolotovGrenade C_MolotovGrenade
  14. #define CIncendiaryGrenade C_IncendiaryGrenade
  15. #endif
  16. //-----------------------------------------------------------------------------
  17. // Molotov grenades
  18. //-----------------------------------------------------------------------------
  19. class CMolotovGrenade : public CBaseCSGrenade
  20. {
  21. public:
  22. DECLARE_CLASS( CMolotovGrenade, CBaseCSGrenade );
  23. DECLARE_NETWORKCLASS();
  24. DECLARE_PREDICTABLE();
  25. CMolotovGrenade() {}
  26. virtual CSWeaponID GetCSWeaponID( void ) const { return WEAPON_MOLOTOV; }
  27. #ifdef CLIENT_DLL
  28. virtual bool Simulate( void );
  29. virtual void UpdateParticles( void );
  30. virtual void OnParticleEffectDeleted( CNewParticleEffect *pParticleEffect );
  31. #else
  32. DECLARE_DATADESC();
  33. virtual void EmitGrenade( Vector vecSrc, QAngle vecAngles, Vector vecVel, AngularImpulse angImpulse, CBasePlayer *pPlayer, const CCSWeaponInfo& weaponInfo );
  34. virtual void Precache( void );
  35. #endif
  36. virtual void Drop( const Vector& vecVelocity );
  37. private:
  38. CMolotovGrenade( const CMolotovGrenade& );
  39. private:
  40. #if defined( CLIENT_DLL )
  41. CUtlReference<CNewParticleEffect> m_molotovParticleEffect;
  42. #endif
  43. };
  44. //-----------------------------------------------------------------------------
  45. // Incendiary grenades
  46. //-----------------------------------------------------------------------------
  47. class CIncendiaryGrenade : public CMolotovGrenade
  48. {
  49. public:
  50. DECLARE_CLASS( CIncendiaryGrenade, CMolotovGrenade );
  51. DECLARE_NETWORKCLASS();
  52. //DECLARE_PREDICTABLE();
  53. CIncendiaryGrenade() {}
  54. virtual CSWeaponID GetCSWeaponID( void ) const { return WEAPON_INCGRENADE; }
  55. #ifdef CLIENT_DLL
  56. //virtual bool Simulate( void );
  57. //virtual void UpdateParticles( void );
  58. //virtual void OnParticleEffectDeleted( CNewParticleEffect *pParticleEffect );
  59. #else
  60. //DECLARE_DATADESC();
  61. virtual void EmitGrenade( Vector vecSrc, QAngle vecAngles, Vector vecVel, AngularImpulse angImpulse, CBasePlayer *pPlayer, const CCSWeaponInfo& weaponInfo );
  62. virtual void Precache( void );
  63. #endif
  64. private:
  65. CIncendiaryGrenade( const CIncendiaryGrenade& );
  66. /*
  67. private:
  68. #if defined( CLIENT_DLL )
  69. CUtlReference<CNewParticleEffect> m_molotovParticleEffect;
  70. #endif
  71. */
  72. };
  73. #endif // WEAPON_MOLOTOV_H