fix aborted attacks continue to show in the active attack list
This commit is contained in:
@@ -1213,6 +1213,12 @@ void GameState::RemoveActiveAttacksForPlayer( PlayerNumber pn, AttackLevel al )
|
|||||||
RebuildPlayerOptionsFromActiveAttacks( pn );
|
RebuildPlayerOptionsFromActiveAttacks( pn );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void GameState::EndActiveAttacksForPlayer( PlayerNumber pn )
|
||||||
|
{
|
||||||
|
FOREACH( Attack, m_pPlayerState[pn]->m_ActiveAttacks, a )
|
||||||
|
a->fSecsRemaining = 0;
|
||||||
|
}
|
||||||
|
|
||||||
void GameState::RemoveAllInventory()
|
void GameState::RemoveAllInventory()
|
||||||
{
|
{
|
||||||
FOREACH_PlayerNumber( p )
|
FOREACH_PlayerNumber( p )
|
||||||
|
|||||||
@@ -192,6 +192,7 @@ public:
|
|||||||
void RebuildPlayerOptionsFromActiveAttacks( PlayerNumber pn );
|
void RebuildPlayerOptionsFromActiveAttacks( PlayerNumber pn );
|
||||||
void RemoveAllActiveAttacks(); // called on end of song
|
void RemoveAllActiveAttacks(); // called on end of song
|
||||||
void RemoveActiveAttacksForPlayer( PlayerNumber pn, AttackLevel al=NUM_ATTACK_LEVELS /*all*/ );
|
void RemoveActiveAttacksForPlayer( PlayerNumber pn, AttackLevel al=NUM_ATTACK_LEVELS /*all*/ );
|
||||||
|
void EndActiveAttacksForPlayer( PlayerNumber pn );
|
||||||
void RemoveAllInventory();
|
void RemoveAllInventory();
|
||||||
int GetSumOfActiveAttackLevels( PlayerNumber pn ) const;
|
int GetSumOfActiveAttackLevels( PlayerNumber pn ) const;
|
||||||
PlayerNumber GetBestPlayer() const;
|
PlayerNumber GetBestPlayer() const;
|
||||||
|
|||||||
@@ -118,7 +118,7 @@ void ScoreKeeperRave::AddSuperMeterDelta( float fUnscaledPercentChange )
|
|||||||
default: ASSERT(0);
|
default: ASSERT(0);
|
||||||
}
|
}
|
||||||
if( !bWinning )
|
if( !bWinning )
|
||||||
GAMESTATE->RemoveActiveAttacksForPlayer( m_pPlayerState->m_PlayerNumber );
|
GAMESTATE->EndActiveAttacksForPlayer( m_pPlayerState->m_PlayerNumber );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user