From d855f691f706c2992f600bf649e5fcbda10435ce Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Mon, 14 May 2007 04:24:47 +0000 Subject: [PATCH] simplify and potimize --- stepmania/src/GameState.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/stepmania/src/GameState.cpp b/stepmania/src/GameState.cpp index ee3ff6fd50..f709b84e9a 100644 --- a/stepmania/src/GameState.cpp +++ b/stepmania/src/GameState.cpp @@ -911,11 +911,8 @@ Stage GameState::GetCurrentStage() const int GameState::GetCourseSongIndex() const { - int iSongIndex = 0; /* iSongsPlayed includes the current song, so it's 1-based; subtract one. */ - FOREACH_EnabledPlayer( pn ) - iSongIndex = max( iSongIndex, STATSMAN->m_CurStageStats.m_player[pn].m_iSongsPlayed-1 ); - return iSongIndex; + return STATSMAN->m_CurStageStats.m_player[m_MasterPlayerNumber].m_iSongsPlayed-1; } /* Hack: when we're loading a new course song, we want to display the new song number, even