From bfecb3d0fe5f15d5429d5d3eeeeba8dbe9606ccf Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Sun, 26 Jan 2003 04:23:01 +0000 Subject: [PATCH] temporary fallback for note skins --- stepmania/src/GrayArrow.cpp | 12 +++++++++--- stepmania/src/GrayArrowRow.cpp | 6 ++++-- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/stepmania/src/GrayArrow.cpp b/stepmania/src/GrayArrow.cpp index c2f7ffee82..de62813fd2 100644 --- a/stepmania/src/GrayArrow.cpp +++ b/stepmania/src/GrayArrow.cpp @@ -39,14 +39,20 @@ void GrayArrow::Update( float fDeltaTime ) Sprite::Update( fDeltaTime ); + /* XXX: get rid of this once we update the note skins */ + int IdleState = (GetNumStates() == 3)? 0: 1; + int OffState = (GetNumStates() == 3)? 1: 0; + int OnState = (GetNumStates() == 3)? 2: 1; + if( !GAMESTATE->m_bPastHereWeGo ) { + SetState( IdleState ); SetState( 0 ); return; } /* These could be metrics or configurable. I'd prefer the flash to - * start on the beat, I think ... -glenn */ + * start on the beat, I think ... -glenn */ /* Start flashing 10% of a beat before the beat starts. */ const float flash_offset = -0.1f; @@ -57,12 +63,12 @@ void GrayArrow::Update( float fDeltaTime ) float cur_beat = GAMESTATE->m_fSongBeat; /* Beats can start in very negative territory (many BMR songs, Drop Out - * -Remix-). */ + * -Remix-). */ cur_beat += 100.0f; cur_beat -= flash_offset; float fPercentIntoBeat = fmodf(cur_beat, 1); - SetState( (fPercentIntoBeatGetPathTo(c, "receptor"); m_GrayArrow[c].Load( sPath ); - if( m_GrayArrow[c].GetNumStates() != 3 ) - RageException::Throw( "'%s' must have 3 frames", sPath.GetString() ); + // XXX + if( m_GrayArrow[c].GetNumStates() != 2 && + m_GrayArrow[c].GetNumStates() != 3 ) + RageException::Throw( "'%s' must have 2 or 3 frames", sPath.GetString() ); m_GrayArrow[c].SetX( pStyleDef->m_ColumnInfo[pn][c].fXOffset ); } }