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