Bug fix. Up-Left and Up-Right no longer crash 4 panel games.
This commit is contained in:
@@ -270,6 +270,10 @@ void Player::HandlePlayerStep( float fSongBeat, TapStep player_step, float fMaxB
|
||||
|
||||
// update gray arrows
|
||||
int iColumnNum = m_Style.TapStepToColumnNumber( player_step );
|
||||
// For single player and two player, iColumnNum will be 4/5 or 8/9/10/11 for
|
||||
// up-left and up-right hits. Seemed this was the simplest way to ignore them in game.
|
||||
if (iColumnNum >= m_Style.m_iNumColumns)
|
||||
return;
|
||||
|
||||
m_GrayArrows.Step( iColumnNum );
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
#include "Steps.h"
|
||||
|
||||
|
||||
const int MAX_NUM_COLUMNS = 8;
|
||||
const int MAX_NUM_COLUMNS = 12;
|
||||
|
||||
|
||||
struct Style
|
||||
@@ -26,7 +26,10 @@ struct Style
|
||||
|
||||
int TapStepToColumnNumber( TapStep tap_step )
|
||||
{
|
||||
for( int i=0; i<m_iNumColumns; i++ )
|
||||
//for (int i=0; i<m_iNumColumns; i++)
|
||||
for( int i=0; i<MAX_NUM_COLUMNS; i++ )
|
||||
// Switched to MAX_NUM_COLUMNS so up-left and up-right don't cause ASSERT(false)
|
||||
// Player.HandelPlayerStep will ignore up-left and up-right if it needs.
|
||||
{
|
||||
if( m_ColumnToTapStep[i] == tap_step )
|
||||
return i;
|
||||
|
||||
Reference in New Issue
Block a user