Team Fortress 2 Source Code as on 22/4/2020
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.

57 lines
1.2 KiB

  1. //========= Copyright Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose: Satchel Charge
  4. //
  5. // $Workfile: $
  6. // $Date: $
  7. // $NoKeywords: $
  8. //=============================================================================//
  9. #ifndef SATCHEL_H
  10. #define SATCHEL_H
  11. #ifdef _WIN32
  12. #pragma once
  13. #endif
  14. #include "basegrenade_shared.h"
  15. #include "hl2mp/weapon_slam.h"
  16. class CSoundPatch;
  17. class CSatchelCharge : public CBaseGrenade
  18. {
  19. public:
  20. DECLARE_CLASS( CSatchelCharge, CBaseGrenade );
  21. void Spawn( void );
  22. void Precache( void );
  23. void BounceSound( void );
  24. void UpdateSlideSound( void );
  25. void KillSlideSound(void);
  26. void SatchelTouch( CBaseEntity *pOther );
  27. void SatchelThink( void );
  28. void SatchelUse( CBaseEntity *pActivator, CBaseEntity *pCaller, USE_TYPE useType, float value );
  29. CSoundPatch* m_soundSlide;
  30. float m_flSlideVolume;
  31. float m_flNextBounceSoundTime;
  32. bool m_bInAir;
  33. Vector m_vLastPosition;
  34. public:
  35. CWeapon_SLAM* m_pMyWeaponSLAM; // Who shot me..
  36. bool m_bIsAttached;
  37. void Deactivate( void );
  38. CSatchelCharge();
  39. ~CSatchelCharge();
  40. DECLARE_DATADESC();
  41. private:
  42. void InitSlideSound(void);
  43. };
  44. #endif //SATCHEL_H