From f4682f7255f94bab93b98bd5a009fa08be2bf6d3 Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Tue, 16 Sep 2003 00:47:52 +0000 Subject: [PATCH] Assertion to catch a div/0 a little earlier. --- stepmania/src/NoteDisplay.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/stepmania/src/NoteDisplay.cpp b/stepmania/src/NoteDisplay.cpp index e70a81918e..5d14c00240 100644 --- a/stepmania/src/NoteDisplay.cpp +++ b/stepmania/src/NoteDisplay.cpp @@ -276,6 +276,8 @@ void NoteDisplay::Load( int iColNum, PlayerNumber pn, CString NoteSkin, float fY void NoteDisplay::SetActiveFrame( float fNoteBeat, Actor &actorToSet, float fAnimationLengthInBeats, bool bVivid, bool bNoteColor ) { const int iNumFrames = actorToSet.GetNumStates(); + ASSERT( iNumFrames ); + float fSongBeat = GAMESTATE->m_fSongBeat; float fPrecentIntoAnimation = fmodf(fSongBeat,fAnimationLengthInBeats) / fAnimationLengthInBeats; float fNoteBeatFraction = fmodf( fNoteBeat, 1.0f );