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: Projectile shot from the MP5
  4. //
  5. // $Workfile: $
  6. // $Date: $
  7. //
  8. //-----------------------------------------------------------------------------
  9. // $Log: $
  10. //
  11. // $NoKeywords: $
  12. //=============================================================================//
  13. #ifndef NPC_SNARK_H
  14. #define NPC_SNARK_H
  15. #include "hl1_ai_basenpc.h"
  16. class CSnark : public CHL1BaseNPC
  17. {
  18. DECLARE_CLASS( CSnark, CHL1BaseNPC );
  19. public:
  20. DECLARE_DATADESC();
  21. void Precache( void );
  22. void Spawn( void );
  23. Class_T Classify( void );
  24. void Event_Killed( const CTakeDamageInfo &info );
  25. bool Event_Gibbed( const CTakeDamageInfo &info );
  26. void HuntThink( void );
  27. void SuperBounceTouch( CBaseEntity *pOther );
  28. virtual void ResolveFlyCollisionCustom( trace_t &trace, Vector &vecVelocity );
  29. virtual unsigned int PhysicsSolidMaskForEntity( void ) const;
  30. virtual bool ShouldGib( const CTakeDamageInfo &info ) { return false; }
  31. static float m_flNextBounceSoundTime;
  32. virtual bool IsValidEnemy( CBaseEntity *pEnemy );
  33. private:
  34. Class_T m_iMyClass;
  35. float m_flDie;
  36. Vector m_vecTarget;
  37. float m_flNextHunt;
  38. float m_flNextHit;
  39. Vector m_posPrev;
  40. EHANDLE m_hOwner;
  41. };
  42. #endif // NPC_SNARK_H