Bug 632058 Fix - Oni Modifiers specified in .CRS files not being cleared after each song.
This commit is contained in:
@@ -143,8 +143,9 @@ public:
|
||||
|
||||
// Session statistics are cleared by calling Reset()
|
||||
|
||||
|
||||
PlayerOptions m_PlayerOptions[NUM_PLAYERS];
|
||||
PlayerOptions m_PlayerOptions[NUM_PLAYERS]; // The currently active options
|
||||
PlayerOptions m_SelectedOptions[NUM_PLAYERS]; // Keep track of player-selected options for
|
||||
// courses separately from the active options.
|
||||
SongOptions m_SongOptions;
|
||||
};
|
||||
|
||||
|
||||
@@ -518,8 +518,12 @@ void ScreenGameplay::LoadNextSong( bool bFirstLoad )
|
||||
case PLAY_MODE_ENDLESS:
|
||||
{
|
||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
||||
{
|
||||
m_textCourseSongNumber[p].SetText( ssprintf("%d", GAMESTATE->m_iSongsBeforeFail[p]+1) );
|
||||
|
||||
// If it's the first song, record the options the player selected for later.
|
||||
if (GAMESTATE->m_iSongsIntoCourse == 0)
|
||||
GAMESTATE->m_SelectedOptions[p] = GAMESTATE->m_PlayerOptions[p];
|
||||
}
|
||||
Course* pCourse = GAMESTATE->m_pCurCourse;
|
||||
CArray<Song*,Song*> apSongs;
|
||||
CArray<Notes*,Notes*> apNotes;
|
||||
@@ -534,6 +538,10 @@ void ScreenGameplay::LoadNextSong( bool bFirstLoad )
|
||||
for( p=0; p<NUM_PLAYERS; p++ )
|
||||
{
|
||||
GAMESTATE->m_pCurNotes[p] = apNotes[iPlaySongIndex];
|
||||
// Wipe the options used on the last song (including course specified ones)
|
||||
GAMESTATE->m_PlayerOptions[p].Init();
|
||||
// Now restore the player's originally selected options.
|
||||
GAMESTATE->m_PlayerOptions[p] = GAMESTATE->m_SelectedOptions[p];
|
||||
if( asModifiers[iPlaySongIndex] != "" ) // some modifiers specified
|
||||
GAMESTATE->m_PlayerOptions[p].FromString( asModifiers[iPlaySongIndex] ); // put them into effect
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user