diff --git a/stepmania/src/GameState.cpp b/stepmania/src/GameState.cpp index 61ea2adf7e..749ea7bc98 100644 --- a/stepmania/src/GameState.cpp +++ b/stepmania/src/GameState.cpp @@ -105,6 +105,14 @@ void GameState::ResetMusicStatistics() m_bPastHereWeGo = false; } +void GameState::UpdateSongPosition(float fPositionSeconds) +{ + ASSERT(m_pCurSong); + + m_fMusicSeconds = fPositionSeconds; + m_pCurSong->GetBeatAndBPSFromElapsedTime( m_fMusicSeconds, m_fSongBeat, m_fCurBPS, m_bFreeze ); +} + int GameState::GetStageIndex() { return m_iCurrentStageIndex; diff --git a/stepmania/src/GameState.h b/stepmania/src/GameState.h index 2baf0c97d0..193fa62a36 100644 --- a/stepmania/src/GameState.h +++ b/stepmania/src/GameState.h @@ -96,7 +96,8 @@ public: bool m_bPastHereWeGo; void ResetMusicStatistics(); // Call this when it's time to play a new song. Clears the values above. - + void UpdateSongPosition(float fPositionSeconds); + // // Stage Statistics: // Arcade: for the current stage (one song).