From 366cfae8b9b20bd818a5a33841690cf02914c515 Mon Sep 17 00:00:00 2001 From: "Devin J. Pohly" Date: Sat, 7 Sep 2013 17:28:19 -0400 Subject: [PATCH] Fix the LastSeen logic for autokeysounds We were never actually setting iLastSeenRow, so the if statement wasn't meaningful anyway. --- src/Player.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/Player.cpp b/src/Player.cpp index e8fd8ad661..68ce8ec4aa 100644 --- a/src/Player.cpp +++ b/src/Player.cpp @@ -2967,10 +2967,6 @@ void Player::CrossedRows( int iLastRowCrossed, const RageTimer &now ) default: break; } - if( iRow != iLastSeenRow ) - { - // crossed a not-empty row - // check to see if there's a note at the crossed row if( m_pPlayerState->m_PlayerController != PC_HUMAN ) { @@ -2989,6 +2985,14 @@ void Player::CrossedRows( int iLastRowCrossed, const RageTimer &now ) } } + // TODO: Can we remove the iLastSeenRow logic and the + // autokeysound for loop, since the iterator in this loop will + // already be iterating over all of the tracks? + if( iRow != iLastSeenRow ) + { + // crossed a new not-empty row + iLastSeenRow = iRow; + // handle autokeysounds here (if not in the editor). if (!GAMESTATE->m_bInStepEditor) {