diff options
| author | Joe Ludwig <[email protected]> | 2013-06-26 15:22:04 -0700 |
|---|---|---|
| committer | Joe Ludwig <[email protected]> | 2013-06-26 15:22:04 -0700 |
| commit | 39ed87570bdb2f86969d4be821c94b722dc71179 (patch) | |
| tree | abc53757f75f40c80278e87650ea92808274aa59 /mp/src/game/client/hl2/hud_suitpower.h | |
| download | source-sdk-2013-39ed87570bdb2f86969d4be821c94b722dc71179.tar.xz source-sdk-2013-39ed87570bdb2f86969d4be821c94b722dc71179.zip | |
First version of the SOurce SDK 2013
Diffstat (limited to 'mp/src/game/client/hl2/hud_suitpower.h')
| -rw-r--r-- | mp/src/game/client/hl2/hud_suitpower.h | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/mp/src/game/client/hl2/hud_suitpower.h b/mp/src/game/client/hl2/hud_suitpower.h new file mode 100644 index 00000000..a7ea69cc --- /dev/null +++ b/mp/src/game/client/hl2/hud_suitpower.h @@ -0,0 +1,57 @@ +//========= Copyright Valve Corporation, All rights reserved. ============//
+//
+// Purpose:
+//
+// $NoKeywords: $
+//=============================================================================//
+#if !defined( HUD_SUITPOWER_H )
+#define HUD_SUITPOWER_H
+#ifdef _WIN32
+#pragma once
+#endif
+
+#include "hudelement.h"
+#include "hud_numericdisplay.h"
+#include <vgui_controls/Panel.h>
+
+//-----------------------------------------------------------------------------
+// Purpose: Shows the sprint power bar
+//-----------------------------------------------------------------------------
+class CHudSuitPower : public CHudElement, public vgui::Panel
+{
+ DECLARE_CLASS_SIMPLE( CHudSuitPower, vgui::Panel );
+
+public:
+ CHudSuitPower( const char *pElementName );
+ virtual void Init( void );
+ virtual void Reset( void );
+ virtual void OnThink( void );
+ bool ShouldDraw( void );
+
+protected:
+ virtual void Paint();
+
+private:
+ CPanelAnimationVar( Color, m_AuxPowerColor, "AuxPowerColor", "255 0 0 255" );
+ CPanelAnimationVar( int, m_iAuxPowerDisabledAlpha, "AuxPowerDisabledAlpha", "70" );
+
+ CPanelAnimationVarAliasType( float, m_flBarInsetX, "BarInsetX", "8", "proportional_float" );
+ CPanelAnimationVarAliasType( float, m_flBarInsetY, "BarInsetY", "8", "proportional_float" );
+ CPanelAnimationVarAliasType( float, m_flBarWidth, "BarWidth", "80", "proportional_float" );
+ CPanelAnimationVarAliasType( float, m_flBarHeight, "BarHeight", "10", "proportional_float" );
+ CPanelAnimationVarAliasType( float, m_flBarChunkWidth, "BarChunkWidth", "10", "proportional_float" );
+ CPanelAnimationVarAliasType( float, m_flBarChunkGap, "BarChunkGap", "2", "proportional_float" );
+
+ CPanelAnimationVar( vgui::HFont, m_hTextFont, "TextFont", "Default" );
+ CPanelAnimationVarAliasType( float, text_xpos, "text_xpos", "8", "proportional_float" );
+ CPanelAnimationVarAliasType( float, text_ypos, "text_ypos", "20", "proportional_float" );
+ CPanelAnimationVarAliasType( float, text2_xpos, "text2_xpos", "8", "proportional_float" );
+ CPanelAnimationVarAliasType( float, text2_ypos, "text2_ypos", "40", "proportional_float" );
+ CPanelAnimationVarAliasType( float, text2_gap, "text2_gap", "10", "proportional_float" );
+
+ float m_flSuitPower;
+ int m_nSuitPowerLow;
+ int m_iActiveSuitDevices;
+};
+
+#endif // HUD_SUITPOWER_H
|