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.

48 lines
1.2 KiB

  1. //========= Copyright Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. //=============================================================================//
  6. #ifndef LIGHTS_H
  7. #define LIGHTS_H
  8. #ifdef _WIN32
  9. #pragma once
  10. #endif
  11. //-----------------------------------------------------------------------------
  12. // Purpose:
  13. //-----------------------------------------------------------------------------
  14. class CLight : public CPointEntity
  15. {
  16. public:
  17. DECLARE_CLASS( CLight, CPointEntity );
  18. bool KeyValue( const char *szKeyName, const char *szValue );
  19. void Spawn( void );
  20. void FadeThink( void );
  21. void Use( CBaseEntity *pActivator, CBaseEntity *pCaller, USE_TYPE useType, float value );
  22. void TurnOn( void );
  23. void TurnOff( void );
  24. void Toggle( void );
  25. // Input handlers
  26. void InputSetPattern( inputdata_t &inputdata );
  27. void InputFadeToPattern( inputdata_t &inputdata );
  28. void InputToggle( inputdata_t &inputdata );
  29. void InputTurnOn( inputdata_t &inputdata );
  30. void InputTurnOff( inputdata_t &inputdata );
  31. DECLARE_DATADESC();
  32. private:
  33. int m_iStyle;
  34. int m_iDefaultStyle;
  35. string_t m_iszPattern;
  36. char m_iCurrentFade;
  37. char m_iTargetFade;
  38. };
  39. #endif // LIGHTS_H