diff --git a/src/ScoreKeeperNormal.cpp b/src/ScoreKeeperNormal.cpp index 4a6cd316a1..7a7e54df2b 100644 --- a/src/ScoreKeeperNormal.cpp +++ b/src/ScoreKeeperNormal.cpp @@ -27,7 +27,8 @@ void PercentScoreWeightInit( size_t /*ScoreEvent*/ i, RString &sNameOut, int &de sNameOut = "PercentScoreWeight" + ScoreEventToString( (ScoreEvent)i ); switch( i ) { - default: ASSERT(0); + default: + FAIL_M(ssprintf("Invalid ScoreEvent: %i", i)); case SE_W1: defaultValueOut = 3; break; case SE_W2: defaultValueOut = 2; break; case SE_W3: defaultValueOut = 1; break; @@ -47,7 +48,8 @@ void GradeWeightInit( size_t /*ScoreEvent*/ i, RString &sNameOut, int &defaultVa sNameOut = "GradeWeight" + ScoreEventToString( (ScoreEvent)i ); switch( i ) { - default: ASSERT(0); + default: + FAIL_M(ssprintf("Invalid ScoreEvent: %i", i)); case SE_W1: defaultValueOut = 2; break; case SE_W2: defaultValueOut = 2; break; case SE_W3: defaultValueOut = 1; break; @@ -101,9 +103,9 @@ void ScoreKeeperNormal::Load( for( unsigned i=0; iGetNoteData( ndTemp ); @@ -120,7 +122,7 @@ void ScoreKeeperNormal::Load( * forced and not chosen by the user. */ NoteDataUtil::TransformNoteData( nd, aa, pSteps->m_StepsType, pSong ); RadarValues rvPre; - GAMESTATE->SetProcessedTimingData(&pSteps->m_Timing); + GAMESTATE->SetProcessedTimingData(pSteps->GetTimingData()); NoteDataUtil::CalculateRadarValues( nd, pSong->m_fMusicLengthSeconds, rvPre ); /* Apply user transforms to find out how the notes will really look. @@ -418,7 +420,7 @@ void ScoreKeeperNormal::HandleTapNoteScoreInternal( TapNoteScore tns, TapNoteSco m_pPlayerStageStats->m_iActualDancePoints += TapNoteScoreToDancePoints( tns ); // update judged row totals. Respect Combo segments here. - TimingData &td = GAMESTATE->m_pCurSteps[m_pPlayerState->m_PlayerNumber]->m_Timing; + TimingData &td = *GAMESTATE->m_pCurSteps[m_pPlayerState->m_PlayerNumber]->GetTimingData(); ComboSegment *cs = td.GetComboSegmentAtRow(row); if (tns == TNS_CheckpointHit || tns >= m_MinScoreToContinueCombo) { @@ -451,7 +453,7 @@ void ScoreKeeperNormal::HandleComboInternal( int iNumHitContinueCombo, int iNumH { m_pPlayerStageStats->m_iCurMissCombo = 0; } - TimingData &td = GAMESTATE->m_pCurSteps[m_pPlayerState->m_PlayerNumber]->m_Timing; + TimingData &td = *GAMESTATE->m_pCurSteps[m_pPlayerState->m_PlayerNumber]->GetTimingData(); if( iNumBreakCombo == 0 ) { int multiplier = ( iRow == -1 ? 1 : td.GetComboSegmentAtRow( iRow )->GetCombo() ); @@ -471,7 +473,7 @@ void ScoreKeeperNormal::HandleRowComboInternal( TapNoteScore tns, int iNumTapsIn { iNumTapsInRow = min( iNumTapsInRow, 1); } - TimingData &td = GAMESTATE->m_pCurSteps[m_pPlayerState->m_PlayerNumber]->m_Timing; + TimingData &td = *GAMESTATE->m_pCurSteps[m_pPlayerState->m_PlayerNumber]->GetTimingData(); if ( tns >= m_MinScoreToContinueCombo ) { m_pPlayerStageStats->m_iCurMissCombo = 0;