remove BPMDisplay from gameplay; not used
add SongBPMDisplay; use it if you want that
This commit is contained in:
@@ -235,6 +235,37 @@ void BPMDisplay::SetFromGameState()
|
||||
NoBPM();
|
||||
}
|
||||
|
||||
class SongBPMDisplay: public BPMDisplay
|
||||
{
|
||||
public:
|
||||
SongBPMDisplay();
|
||||
virtual SongBPMDisplay *Copy() const;
|
||||
virtual void Update( float fDeltaTime );
|
||||
|
||||
private:
|
||||
float m_fLastGameStateBPM;
|
||||
|
||||
};
|
||||
|
||||
SongBPMDisplay::SongBPMDisplay()
|
||||
{
|
||||
m_fLastGameStateBPM = 0;
|
||||
}
|
||||
|
||||
void SongBPMDisplay::Update( float fDeltaTime )
|
||||
{
|
||||
float fGameStateBPM = GAMESTATE->m_fCurBPS * 60.0f;
|
||||
if( m_fLastGameStateBPM != fGameStateBPM )
|
||||
{
|
||||
m_fLastGameStateBPM = fGameStateBPM;
|
||||
SetConstantBpm( fGameStateBPM );
|
||||
}
|
||||
|
||||
BPMDisplay::Update( fDeltaTime );
|
||||
}
|
||||
|
||||
REGISTER_ACTOR_CLASS( SongBPMDisplay )
|
||||
|
||||
#include "LuaBinding.h"
|
||||
class LunaBPMDisplay: public Luna<BPMDisplay>
|
||||
{
|
||||
|
||||
@@ -719,14 +719,6 @@ void ScreenGameplay::Init()
|
||||
if( g_bShowLyrics )
|
||||
this->AddChild( &m_LyricDisplay );
|
||||
|
||||
m_BPMDisplay.SetName( "BPMDisplay" );
|
||||
m_BPMDisplay.LoadFromFont( THEME->GetPathF("BPMDisplay","bpm") );
|
||||
m_BPMDisplay.Load();
|
||||
ActorUtil::LoadAllCommands( m_BPMDisplay, m_sName );
|
||||
SET_XY( m_BPMDisplay );
|
||||
this->AddChild( &m_BPMDisplay );
|
||||
m_fLastBPS = 0;
|
||||
|
||||
if( !GAMESTATE->m_bDemonstrationOrJukebox ) // only load if we're going to use it
|
||||
{
|
||||
m_Ready.Load( THEME->GetPathB(m_sName,"ready") );
|
||||
@@ -1831,15 +1823,6 @@ void ScreenGameplay::Update( float fDeltaTime )
|
||||
return;
|
||||
}
|
||||
|
||||
//
|
||||
// update bpm display
|
||||
//
|
||||
if( m_fLastBPS != GAMESTATE->m_fCurBPS && !m_BPMDisplay.GetHidden() )
|
||||
{
|
||||
m_fLastBPS = GAMESTATE->m_fCurBPS;
|
||||
m_BPMDisplay.SetConstantBpm( GAMESTATE->m_fCurBPS * 60.0f );
|
||||
}
|
||||
|
||||
PlayTicks();
|
||||
|
||||
UpdateLights();
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
#include "Transition.h"
|
||||
#include "BitmapText.h"
|
||||
#include "RageSound.h"
|
||||
#include "BPMDisplay.h"
|
||||
#include "LocalizedString.h"
|
||||
#include "BeginnerHelper.h"
|
||||
#include "LyricDisplay.h"
|
||||
#include "Attack.h"
|
||||
@@ -195,9 +195,6 @@ protected:
|
||||
CombinedLifeMeter* m_pCombinedLifeMeter;
|
||||
Sprite m_sprCourseSongNumber;
|
||||
|
||||
BPMDisplay m_BPMDisplay;
|
||||
float m_fLastBPS;
|
||||
|
||||
Sprite m_sprScoreFrame;
|
||||
BitmapText m_textSongOptions;
|
||||
BitmapText m_Scoreboard[NUM_NSScoreBoardColumn]; // for NSMAN, so we can have a scoreboard
|
||||
|
||||
Reference in New Issue
Block a user