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.

57 lines
1.3 KiB

  1. //========= Copyright � 1996-2005, Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. //=============================================================================//
  6. #ifndef FLASHBANG_PROJECTILE_H
  7. #define FLASHBANG_PROJECTILE_H
  8. #ifdef _WIN32
  9. #pragma once
  10. #endif
  11. #include "basecsgrenade_projectile.h"
  12. class CFlashbangProjectile : public CBaseCSGrenadeProjectile
  13. {
  14. public:
  15. DECLARE_CLASS( CFlashbangProjectile, CBaseCSGrenadeProjectile );
  16. #if !defined( CLIENT_DLL )
  17. DECLARE_DATADESC();
  18. #endif
  19. // Overrides.
  20. public:
  21. CFlashbangProjectile();
  22. virtual void Spawn();
  23. virtual void Precache();
  24. virtual void BounceSound( void );
  25. virtual void Detonate();
  26. void InputSetTimer( inputdata_t &inputdata );
  27. virtual GrenadeType_t GetGrenadeType( void ) { return GRENADE_TYPE_FLASH; }
  28. // Grenade stuff.
  29. static CFlashbangProjectile* Create(
  30. const Vector &position,
  31. const QAngle &angles,
  32. const Vector &velocity,
  33. const AngularImpulse &angVelocity,
  34. CBaseCombatCharacter *pOwner,
  35. const CCSWeaponInfo& weaponInfo );
  36. public:
  37. float m_flTimeToDetonate;
  38. // Count of players effected by the flash
  39. uint8 m_numOpponentsHit; // note: opponents are considered to be anybody not on the flasher's team.
  40. uint8 m_numTeammatesHit;
  41. };
  42. #endif // FLASHBANG_PROJECTILE_H