fix invisible notes near beginning of song with ProgressAlternate
This commit is contained in:
+4
-3
@@ -1339,9 +1339,10 @@ void NoteDisplay::DrawActor(const TapNote& tn, Actor* pActor, NotePart part,
|
|||||||
break;
|
break;
|
||||||
case NoteColorType_ProgressAlternate:
|
case NoteColorType_ProgressAlternate:
|
||||||
fScaledBeat = fBeat * cache->m_iNoteColorCount[part];
|
fScaledBeat = fBeat * cache->m_iNoteColorCount[part];
|
||||||
//knock it back into the last frame if it's on a boundary
|
if( fScaledBeat - int64_t(fScaledBeat) == 0.0f )
|
||||||
if (fScaledBeat - int64_t(fScaledBeat) == 0.0f)
|
//we're on a boundary, so move to the previous frame.
|
||||||
fScaledBeat -= 1.0f;
|
//doing it this way ensures that fScaledBeat is never negative so fmodf works.
|
||||||
|
fScaledBeat += cache->m_iNoteColorCount[part] - 1;
|
||||||
color = fmodf( ceilf( fScaledBeat ), (float)cache->m_iNoteColorCount[part] );
|
color = fmodf( ceilf( fScaledBeat ), (float)cache->m_iNoteColorCount[part] );
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
|||||||
Reference in New Issue
Block a user