split out DrawGrayBar
protected:
This commit is contained in:
@@ -79,18 +79,23 @@ void WheelItemBase::Update( float fDeltaTime )
|
||||
Actor::Update( fDeltaTime );
|
||||
}
|
||||
|
||||
void WheelItemBase::DrawGrayBar( Sprite& bar )
|
||||
{
|
||||
if( m_fPercentGray == 0 )
|
||||
return;
|
||||
|
||||
bar.SetGlow( RageColor(0,0,0,m_fPercentGray) );
|
||||
bar.SetDiffuse( RageColor(0,0,0,0) );
|
||||
bar.Draw();
|
||||
bar.SetDiffuse( RageColor(0,0,0,1) );
|
||||
bar.SetGlow( RageColor(0,0,0,0) );
|
||||
}
|
||||
|
||||
void WheelItemBase::DrawPrimitives(Sprite& bar)
|
||||
{
|
||||
ActorFrame::DrawPrimitives();
|
||||
|
||||
if( m_fPercentGray > 0 )
|
||||
{
|
||||
bar.SetGlow( RageColor(0,0,0,m_fPercentGray) );
|
||||
bar.SetDiffuse( RageColor(0,0,0,0) );
|
||||
bar.Draw();
|
||||
bar.SetDiffuse( RageColor(0,0,0,1) );
|
||||
bar.SetGlow( RageColor(0,0,0,0) );
|
||||
}
|
||||
DrawGrayBar( bar );
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
@@ -35,11 +35,13 @@ public:
|
||||
virtual void DrawPrimitives() { DrawPrimitives( m_sprBar ); }
|
||||
|
||||
void Load( CString sType );
|
||||
void DrawGrayBar( Sprite& bar );
|
||||
|
||||
virtual void LoadFromWheelItemBaseData( WheelItemBaseData* pWID );
|
||||
|
||||
float m_fPercentGray;
|
||||
|
||||
protected:
|
||||
Sprite m_sprBar;
|
||||
BitmapText m_text;
|
||||
WheelItemType m_Type;
|
||||
@@ -49,7 +51,6 @@ public:
|
||||
ThemeMetric<float> TEXT_Y;
|
||||
ThemeMetric<float> TEXT_WIDTH;
|
||||
ThemeMetric<apActorCommands> TEXT_ON_COMMAND;
|
||||
|
||||
};
|
||||
|
||||
struct WheelItemBaseData
|
||||
|
||||
Reference in New Issue
Block a user