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/hud_base_account.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/hud_base_account.h')
| -rw-r--r-- | mp/src/game/client/hud_base_account.h | 77 |
1 files changed, 77 insertions, 0 deletions
diff --git a/mp/src/game/client/hud_base_account.h b/mp/src/game/client/hud_base_account.h new file mode 100644 index 00000000..2fa28f4c --- /dev/null +++ b/mp/src/game/client/hud_base_account.h @@ -0,0 +1,77 @@ +//========= Copyright Valve Corporation, All rights reserved. ============//
+//
+// Purpose:
+//
+// $NoKeywords: $
+//=============================================================================//
+
+#ifndef HUD_BASE_ACCOUNT_H
+#define HUD_BASE_ACCOUNT_H
+#ifdef _WIN32
+#pragma once
+#endif
+
+#include "hudelement.h"
+#include "hud_numericdisplay.h"
+
+using namespace vgui;
+
+class CHudBaseAccount : public CHudElement, public CHudNumericDisplay
+{
+public:
+ DECLARE_CLASS_SIMPLE( CHudBaseAccount, CHudNumericDisplay );
+
+ CHudBaseAccount( const char *name );
+
+ virtual bool ShouldDraw();
+ virtual void Paint();
+ virtual void LevelInit( void );
+ virtual void Reset( void );
+
+ virtual void ApplySchemeSettings(vgui::IScheme *pScheme);
+
+ int GetNumberWidth(HFont font, int number);
+
+ // How much money does the player have
+ virtual int GetPlayerAccount( void ) { return 0; }
+
+ // Requires game-specific g_pClientMode call, push to derived class
+ virtual vgui::AnimationController *GetAnimationController( void ) { Assert( 0 ); return NULL; }
+
+private:
+ int m_iPreviousAccount;
+ int m_iPreviousDelta;
+ CHudTexture *m_pAccountIcon;
+ CHudTexture *m_pMinusIcon;
+ CHudTexture *m_pPlusIcon;
+
+ Color m_clrRed;
+ Color m_clrGreen;
+ Color m_clrDeltaColor;
+
+ CPanelAnimationVarAliasType( float, icon_xpos, "icon_xpos", "0", "proportional_float" );
+ CPanelAnimationVarAliasType( float, icon_ypos, "icon_ypos", "0", "proportional_float" );
+ CPanelAnimationVarAliasType( float, icon2_xpos, "icon2_xpos", "0", "proportional_float" );
+ CPanelAnimationVarAliasType( float, icon2_ypos, "icon2_ypos", "0", "proportional_float" );
+ CPanelAnimationVarAliasType( float, digit_xpos, "digit_xpos", "50", "proportional_float" );
+ CPanelAnimationVarAliasType( float, digit_ypos, "digit_ypos", "2", "proportional_float" );
+ CPanelAnimationVarAliasType( float, digit2_xpos, "digit2_xpos", "0", "proportional_float" );
+ CPanelAnimationVarAliasType( float, digit2_ypos, "digit2_ypos", "0", "proportional_float" );
+ CPanelAnimationVar( Color, m_Ammo2Color, "Ammo2Color", "0 0 0 0" );
+
+ CPanelAnimationVar( Color, m_TextColor, "TextColor", "FgColor" );
+ CPanelAnimationVar( vgui::HFont, m_hNumberFont, "NumberFont", "HudNumbers" );
+
+ float m_flLastAnimationEnd;
+ const char *m_pszLastAnimationName;
+ const char *m_pszQueuedAnimationName;
+
+ float icon_tall;
+ float icon_wide;
+};
+
+
+#endif // HUD_BASE_ACCOUNT_H
+
+
+
|