mirror of
https://github.com/celisej567/cool-source-archive.git
synced 2026-09-09 20:09:18 +03:00
40 lines
1.1 KiB
C++
40 lines
1.1 KiB
C++
#include "cbase.h"
|
|
#include "weapon_selection.h"
|
|
#include "vgui_controls/Panel.h"
|
|
#include "iclientmode.h"
|
|
|
|
class CHudWeaponSelection : public CBaseHudWeaponSelection, public vgui::Panel
|
|
{
|
|
DECLARE_CLASS_SIMPLE( CHudWeaponSelection, vgui::Panel );
|
|
|
|
CHudWeaponSelection( const char* pElementName );
|
|
|
|
void ApplySchemeSettings(vgui::IScheme* pScheme);
|
|
|
|
void CycleToNextWeapon() {}
|
|
void CycleToPrevWeapon() {}
|
|
void SelectWeaponSlot(int iSlot) {}
|
|
|
|
C_BaseCombatWeapon* GetWeaponInSlot( int iSlot, int iSlotPos ) { return null; }
|
|
C_BaseCombatWeapon* GetSelectedWeapon() { return null; }
|
|
};
|
|
|
|
DECLARE_HUDELEMENT( CHudWeaponSelection );
|
|
|
|
CHudWeaponSelection::CHudWeaponSelection( const char* pElementName ) : CBaseHudWeaponSelection(pElementName), BaseClass(NULL, "HudWeaponSelection")
|
|
{
|
|
SetParent( g_pClientMode->GetViewport() );
|
|
}
|
|
|
|
void CHudWeaponSelection::ApplySchemeSettings(vgui::IScheme* pScheme)
|
|
{
|
|
BaseClass::ApplySchemeSettings(pScheme);
|
|
SetPaintBackgroundEnabled(false);
|
|
|
|
int x, y;
|
|
GetPos(x, y);
|
|
int screenWide, screenTall;
|
|
GetHudSize(screenWide, screenTall);
|
|
|
|
SetBounds( x, y, screenWide - x, screenTall - y );
|
|
} |