track fOverlappedTime for hold notes
This commit is contained in:
@@ -663,11 +663,18 @@ void Player::Update( float fDeltaTime )
|
||||
if( tn.type != TapNote::hold_head )
|
||||
continue;
|
||||
int iRow = begin->first;
|
||||
int iEndRow = iRow + tn.iDuration;
|
||||
|
||||
// set hold flags so NoteField can do intelligent drawing
|
||||
tn.HoldResult.bHeld = false;
|
||||
tn.HoldResult.bActive = false;
|
||||
|
||||
// If the song beat is in the range of this hold:
|
||||
if( iRow <= iSongRow && iRow <= iEndRow )
|
||||
tn.HoldResult.fOverlappedTime += fDeltaTime;
|
||||
else
|
||||
tn.HoldResult.fOverlappedTime = 0;
|
||||
|
||||
HoldNoteScore hns = tn.HoldResult.hns;
|
||||
if( hns != HNS_None ) // if this HoldNote already has a result
|
||||
continue; // we don't need to update the logic for this one
|
||||
@@ -693,8 +700,6 @@ void Player::Update( float fDeltaTime )
|
||||
bIsHoldingButton = INPUTMAPPER->IsBeingPressed( GameI, m_pPlayerState->m_mp );
|
||||
}
|
||||
|
||||
int iEndRow = iRow + tn.iDuration;
|
||||
|
||||
float fLife = tn.HoldResult.fLife;
|
||||
if( bSteppedOnTapNote && fLife != 0 )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user