added autogeneration of Notes for missing NotesTypes
This commit is contained in:
@@ -20,7 +20,7 @@ D3DXCOLOR NoteTypeToColor( NoteType nt )
|
||||
case NOTE_TYPE_8TH: return D3DXCOLOR(0,0,1,1); // blue
|
||||
case NOTE_TYPE_12TH: return D3DXCOLOR(1,0,1,1); // purple
|
||||
case NOTE_TYPE_16TH: return D3DXCOLOR(1,1,0,1); // yellow
|
||||
default: ASSERT( 0 );return D3DXCOLOR(0.5f,0.5f,0.5f,1);
|
||||
default: ASSERT(0); return D3DXCOLOR(0.5f,0.5f,0.5f,1);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -28,11 +28,11 @@ float NoteTypeToBeat( NoteType nt )
|
||||
{
|
||||
switch( nt )
|
||||
{
|
||||
case NOTE_TYPE_4TH: return 1.0f; // quarter notes
|
||||
case NOTE_TYPE_8TH: return 1.0f/2; // eighth notes
|
||||
case NOTE_TYPE_4TH: return 1.0f; // quarter notes
|
||||
case NOTE_TYPE_8TH: return 1.0f/2; // eighth notes
|
||||
case NOTE_TYPE_12TH: return 1.0f/3; // triplets
|
||||
case NOTE_TYPE_16TH: return 1.0f/4; // sixteenth notes
|
||||
default: ASSERT( false ); return 0;
|
||||
default: ASSERT(0); return 0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -42,7 +42,7 @@ NoteType GetNoteType( int iNoteIndex )
|
||||
else if( iNoteIndex % (ROWS_PER_MEASURE/8) == 0) return NOTE_TYPE_8TH;
|
||||
else if( iNoteIndex % (ROWS_PER_MEASURE/12) == 0) return NOTE_TYPE_12TH;
|
||||
else if( iNoteIndex % (ROWS_PER_MEASURE/16) == 0) return NOTE_TYPE_16TH;
|
||||
else return NOTE_TYPE_INVALID;
|
||||
else return NOTE_TYPE_INVALID;
|
||||
};
|
||||
|
||||
bool IsNoteOfType( int iNoteIndex, NoteType t )
|
||||
|
||||
Reference in New Issue
Block a user