add fix and check
This commit is contained in:
@@ -39,18 +39,22 @@ public:
|
|||||||
|
|
||||||
const TapNoteScore &GetTapNoteScore(int track, int row) const
|
const TapNoteScore &GetTapNoteScore(int track, int row) const
|
||||||
{
|
{
|
||||||
|
ASSERT(row < int(m_TapNoteScores[track].size()));
|
||||||
return m_TapNoteScores[track][row];
|
return m_TapNoteScores[track][row];
|
||||||
}
|
}
|
||||||
TapNoteScore &GetTapNoteScore(int track, int row)
|
TapNoteScore &GetTapNoteScore(int track, int row)
|
||||||
{
|
{
|
||||||
|
ASSERT(row < int(m_TapNoteScores[track].size()));
|
||||||
return m_TapNoteScores[track][row];
|
return m_TapNoteScores[track][row];
|
||||||
}
|
}
|
||||||
const HoldNoteScore &GetHoldNoteScore(int h) const
|
const HoldNoteScore &GetHoldNoteScore(int h) const
|
||||||
{
|
{
|
||||||
|
ASSERT(h < int(m_HoldNoteScores.size()));
|
||||||
return m_HoldNoteScores[h];
|
return m_HoldNoteScores[h];
|
||||||
}
|
}
|
||||||
HoldNoteScore &GetHoldNoteScore(int h)
|
HoldNoteScore &GetHoldNoteScore(int h)
|
||||||
{
|
{
|
||||||
|
ASSERT(h < int(m_HoldNoteScores.size()));
|
||||||
return m_HoldNoteScores[h];
|
return m_HoldNoteScores[h];
|
||||||
}
|
}
|
||||||
float &GetHoldNoteLife(int h)
|
float &GetHoldNoteLife(int h)
|
||||||
|
|||||||
@@ -125,7 +125,7 @@ void Player::Load( PlayerNumber pn, NoteData* pNoteData, LifeMeter* pLM, ScoreDi
|
|||||||
const StyleDef* pStyleDef = GAMESTATE->GetCurrentStyleDef();
|
const StyleDef* pStyleDef = GAMESTATE->GetCurrentStyleDef();
|
||||||
|
|
||||||
// init scoring
|
// init scoring
|
||||||
NoteDataWithScoring::Init(pNoteData->GetLastRow(), pNoteData->GetNumHoldNotes());
|
NoteDataWithScoring::Init(pNoteData->GetLastRow()+1, pNoteData->GetNumHoldNotes());
|
||||||
|
|
||||||
// copy note data
|
// copy note data
|
||||||
this->CopyAll( pNoteData );
|
this->CopyAll( pNoteData );
|
||||||
|
|||||||
Reference in New Issue
Block a user