fix m_meterSongPosition finishing too soon
This commit is contained in:
@@ -1092,13 +1092,6 @@ void ScreenGameplay::LoadNextSong()
|
|||||||
* -Chris */
|
* -Chris */
|
||||||
m_bZeroDeltaOnNextUpdate = true;
|
m_bZeroDeltaOnNextUpdate = true;
|
||||||
|
|
||||||
|
|
||||||
// (Re)Calculate the song position meter
|
|
||||||
m_fSongPosMeterOffset = GAMESTATE->m_pCurSong->m_Timing.GetElapsedTimeFromBeat(
|
|
||||||
GAMESTATE->m_pCurSong->m_fFirstBeat );
|
|
||||||
m_fSongPosMeterEnd = ( GAMESTATE->m_pCurSong->m_Timing.GetElapsedTimeFromBeat(
|
|
||||||
GAMESTATE->m_pCurSong->m_fLastBeat ) - m_fSongPosMeterOffset );
|
|
||||||
|
|
||||||
//
|
//
|
||||||
// Load cabinet lights data
|
// Load cabinet lights data
|
||||||
//
|
//
|
||||||
@@ -1537,13 +1530,9 @@ void ScreenGameplay::Update( float fDeltaTime )
|
|||||||
//
|
//
|
||||||
// update song position meter
|
// update song position meter
|
||||||
//
|
//
|
||||||
// IMHHO, The song position bar is best used to represent where in the
|
float fSongStartSeconds = GAMESTATE->m_pCurSong->m_Timing.GetElapsedTimeFromBeat( GAMESTATE->m_pCurSong->m_fFirstBeat );
|
||||||
// step sequence the players are. It looks "better" that way, showing a
|
float fSongEndSeconds = GAMESTATE->m_pCurSong->m_Timing.GetElapsedTimeFromBeat( GAMESTATE->m_pCurSong->m_fLastBeat );
|
||||||
// song "depleting" as the players wear on. So, it starts "ticking" at
|
float fPercentPositionSong = SCALE( GAMESTATE->m_fMusicSeconds, fSongStartSeconds, fSongEndSeconds, 0.0f, 1.0f );
|
||||||
// the first arrow and winds down to the very end.
|
|
||||||
float fPercentPositionSong = SCALE( GAMESTATE->m_fMusicSeconds, m_fSongPosMeterOffset,
|
|
||||||
m_fSongPosMeterEnd, 0.0f, 1.0f );
|
|
||||||
|
|
||||||
CLAMP( fPercentPositionSong, 0, 1 );
|
CLAMP( fPercentPositionSong, 0, 1 );
|
||||||
m_meterSongPosition.SetPercent( fPercentPositionSong );
|
m_meterSongPosition.SetPercent( fPercentPositionSong );
|
||||||
|
|
||||||
|
|||||||
@@ -162,10 +162,6 @@ protected:
|
|||||||
BeginnerHelper m_BeginnerHelper;
|
BeginnerHelper m_BeginnerHelper;
|
||||||
|
|
||||||
NoteData m_CabinetLightsNoteData;
|
NoteData m_CabinetLightsNoteData;
|
||||||
|
|
||||||
private:
|
|
||||||
float m_fSongPosMeterEnd;
|
|
||||||
float m_fSongPosMeterOffset;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user