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.

73 lines
2.0 KiB

  1. //========= Copyright Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. //=============================================================================//
  6. #ifndef TFC_BUILDING_H
  7. #define TFC_BUILDING_H
  8. #ifdef _WIN32
  9. #pragma once
  10. #endif
  11. #include "baseanimating.h"
  12. #include "tfc_shareddefs.h"
  13. class CTFBaseBuilding : public CBaseAnimating
  14. {
  15. public:
  16. EHANDLE real_owner;
  17. };
  18. class CTFTeleporter : public CTFBaseBuilding
  19. {
  20. public:
  21. void Spawn(void);
  22. void Precache(void);
  23. void EXPORT Teleporter_Explode( void );
  24. void EXPORT TeleporterThink( void );
  25. void EXPORT TeleporterTouch( CBaseEntity *pOther );
  26. Class_T Classify(void) { return CLASS_MACHINE; };
  27. int BloodColor( void ) { return DONT_BLEED; }
  28. void Remove( void );
  29. void TeamFortress_TakeEMPBlast(CBaseEntity* pevGren);
  30. void Finished( void );
  31. static CTFTeleporter *CreateTeleporter( Vector vecOrigin, Vector vecAngles, CBaseEntity *pOwner, int type );
  32. BOOL EngineerUse( CBasePlayer *pPlayer );
  33. void Killed( CBaseEntity *pevInflictor, CBaseEntity *pevAttacker, int iGib );
  34. void TeleporterSend( CBasePlayer *pPlayer );
  35. void TeleporterReceive( CBasePlayer *pPlayer, float flDelay );
  36. void TeleporterKilled( void );
  37. BOOL TeleportersReady( void );
  38. void TeleporterFadePlayer( int direction );
  39. void TeleporterProcessFade( void );
  40. void SetTeleporterRings( int state );
  41. void SetTeleporterParticles( int state );
  42. float GetDamageMultiplier( void );
  43. CTFTeleporter* FindMatch( void );
  44. const Vector& GetTeamColor( void );
  45. bool PlayerIsStandingOnTeleporter( CBaseEntity *pOther );
  46. CBasePlayer *m_pPlayer; // player being teleported
  47. float m_flInitialUseDelay;
  48. int m_iType; // entry or exit
  49. int m_iState; // state of the teleporter (idle, ready, sending, etc.)
  50. int m_iDestroyed; // has this teleporter been destroyed
  51. int m_iShardIndex; // Metal shards
  52. float m_flMyNextThink; // used to control the pace at which the teleporters work
  53. float m_flDamageDelay; // damage multiplier that slows the teleporters when they're damaged
  54. };
  55. #endif // TFC_BUILDING_H