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.

63 lines
1.2 KiB

  1. //========= Copyright � 1996-2005, Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. //=============================================================================//
  6. #include "cbase.h"
  7. #include "weapon_csbase.h"
  8. #include "gamerules.h"
  9. #include "npcevent.h"
  10. #include "engine/IEngineSound.h"
  11. #include "weapon_flashbang.h"
  12. #ifdef CLIENT_DLL
  13. #else
  14. #include "cs_player.h"
  15. #include "items.h"
  16. #include "flashbang_projectile.h"
  17. #endif
  18. // NOTE: This has to be the last file included!
  19. #include "tier0/memdbgon.h"
  20. #define GRENADE_TIMER 3.0f //Seconds
  21. IMPLEMENT_NETWORKCLASS_ALIASED( Flashbang, DT_Flashbang )
  22. BEGIN_NETWORK_TABLE(CFlashbang, DT_Flashbang)
  23. END_NETWORK_TABLE()
  24. BEGIN_PREDICTION_DATA( CFlashbang )
  25. END_PREDICTION_DATA()
  26. LINK_ENTITY_TO_CLASS_ALIASED( weapon_flashbang, Flashbang );
  27. PRECACHE_REGISTER( weapon_flashbang );
  28. #ifndef CLIENT_DLL
  29. BEGIN_DATADESC( CFlashbang )
  30. END_DATADESC()
  31. void CFlashbang::EmitGrenade( Vector vecSrc, QAngle vecAngles, Vector vecVel, AngularImpulse angImpulse, CBasePlayer *pPlayer, const CCSWeaponInfo& weaponInfo )
  32. {
  33. CFlashbangProjectile::Create(
  34. vecSrc,
  35. vecAngles,
  36. vecVel,
  37. angImpulse,
  38. pPlayer,
  39. weaponInfo );
  40. }
  41. #endif