"for( int p=0; p<NUM_PLAYERS; p++ )" -> "FOREACH_PlayerNumber( p )"
This commit is contained in:
@@ -422,7 +422,7 @@ void Background::LoadFromSong( const Song* pSong )
|
|||||||
m_DangerAll.SetZoomX( fXZoom );
|
m_DangerAll.SetZoomX( fXZoom );
|
||||||
m_DangerAll.SetZoomY( fYZoom );
|
m_DangerAll.SetZoomY( fYZoom );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_DangerPlayer[p].SetXY( (float)LEFT_EDGE, (float)TOP_EDGE );
|
m_DangerPlayer[p].SetXY( (float)LEFT_EDGE, (float)TOP_EDGE );
|
||||||
m_DangerPlayer[p].SetZoomX( fXZoom );
|
m_DangerPlayer[p].SetZoomX( fXZoom );
|
||||||
@@ -540,7 +540,7 @@ void Background::Update( float fDeltaTime )
|
|||||||
m_DangerAll.Update( fDeltaTime );
|
m_DangerAll.Update( fDeltaTime );
|
||||||
}
|
}
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( IsDangerPlayerVisible((PlayerNumber)p) )
|
if( IsDangerPlayerVisible((PlayerNumber)p) )
|
||||||
m_DangerPlayer[p].Update( fDeltaTime );
|
m_DangerPlayer[p].Update( fDeltaTime );
|
||||||
@@ -591,7 +591,7 @@ void Background::DrawPrimitives()
|
|||||||
if( m_pFadingBGA )
|
if( m_pFadingBGA )
|
||||||
m_pFadingBGA->Draw();
|
m_pFadingBGA->Draw();
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( IsDangerPlayerVisible((PlayerNumber)p) )
|
if( IsDangerPlayerVisible((PlayerNumber)p) )
|
||||||
m_DangerPlayer[p].Draw();
|
m_DangerPlayer[p].Draw();
|
||||||
|
|||||||
@@ -253,7 +253,7 @@ void BeginnerHelper::DrawPrimitives()
|
|||||||
for( int scd=0; scd<NUM_PLAYERS*2; scd++ )
|
for( int scd=0; scd<NUM_PLAYERS*2; scd++ )
|
||||||
m_sStepCircle[scd].Draw(); // Should be drawn before the dancer, but after the pad, so it is drawn over the pad and under the dancer.
|
m_sStepCircle[scd].Draw(); // Should be drawn before the dancer, but after the pad, so it is drawn over the pad and under the dancer.
|
||||||
|
|
||||||
for( int pn=0; pn<NUM_PLAYERS; pn++ ) // Draw each dancer
|
FOREACH_PlayerNumber( pn ) // Draw each dancer
|
||||||
if( GAMESTATE->IsHumanPlayer(pn) )
|
if( GAMESTATE->IsHumanPlayer(pn) )
|
||||||
m_mDancer[pn].Draw();
|
m_mDancer[pn].Draw();
|
||||||
|
|
||||||
|
|||||||
@@ -145,7 +145,7 @@ void CombinedLifeMeterEnemy::Update( float fDelta )
|
|||||||
a.fSecsRemaining = 10;
|
a.fSecsRemaining = 10;
|
||||||
a.level = ATTACK_LEVEL_1;
|
a.level = ATTACK_LEVEL_1;
|
||||||
a.sModifier = sPossibleModifiers[a.level][rand()%3];
|
a.sModifier = sPossibleModifiers[a.level][rand()%3];
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
GAMESTATE->LaunchAttack( (PlayerNumber)p, a );
|
GAMESTATE->LaunchAttack( (PlayerNumber)p, a );
|
||||||
SCREENMAN->SendMessageToTopScreen( SM_BattleTrickLevel1 );
|
SCREENMAN->SendMessageToTopScreen( SM_BattleTrickLevel1 );
|
||||||
@@ -157,7 +157,7 @@ void CombinedLifeMeterEnemy::Update( float fDelta )
|
|||||||
a.fSecsRemaining = 10;
|
a.fSecsRemaining = 10;
|
||||||
a.level = ATTACK_LEVEL_2;
|
a.level = ATTACK_LEVEL_2;
|
||||||
a.sModifier = sPossibleModifiers[a.level][rand()%3];
|
a.sModifier = sPossibleModifiers[a.level][rand()%3];
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
GAMESTATE->LaunchAttack( (PlayerNumber)p, a );
|
GAMESTATE->LaunchAttack( (PlayerNumber)p, a );
|
||||||
SCREENMAN->SendMessageToTopScreen( SM_BattleTrickLevel2 );
|
SCREENMAN->SendMessageToTopScreen( SM_BattleTrickLevel2 );
|
||||||
@@ -169,7 +169,7 @@ void CombinedLifeMeterEnemy::Update( float fDelta )
|
|||||||
a.fSecsRemaining = 10;
|
a.fSecsRemaining = 10;
|
||||||
a.level = ATTACK_LEVEL_3;
|
a.level = ATTACK_LEVEL_3;
|
||||||
a.sModifier = sPossibleModifiers[a.level][rand()%3];
|
a.sModifier = sPossibleModifiers[a.level][rand()%3];
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
GAMESTATE->LaunchAttack( (PlayerNumber)p, a );
|
GAMESTATE->LaunchAttack( (PlayerNumber)p, a );
|
||||||
SCREENMAN->SendMessageToTopScreen( SM_BattleTrickLevel3 );
|
SCREENMAN->SendMessageToTopScreen( SM_BattleTrickLevel3 );
|
||||||
|
|||||||
@@ -56,7 +56,7 @@ DancingCharacters::DancingCharacters()
|
|||||||
memset( m_bHasWinAnim, 0, sizeof(m_bHasWinAnim) );
|
memset( m_bHasWinAnim, 0, sizeof(m_bHasWinAnim) );
|
||||||
memset( m_bHasFailAnim, 0, sizeof(m_bHasFailAnim) );
|
memset( m_bHasFailAnim, 0, sizeof(m_bHasFailAnim) );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_2DIdleTimer[p].SetZero();
|
m_2DIdleTimer[p].SetZero();
|
||||||
m_i2DAnimState[p] = AS2D_IDLE; // start on idle state
|
m_i2DAnimState[p] = AS2D_IDLE; // start on idle state
|
||||||
@@ -174,7 +174,7 @@ void DancingCharacters::LoadNextSong()
|
|||||||
ASSERT( GAMESTATE->m_pCurSong );
|
ASSERT( GAMESTATE->m_pCurSong );
|
||||||
m_fThisCameraEndBeat = GAMESTATE->m_pCurSong->m_fFirstBeat;
|
m_fThisCameraEndBeat = GAMESTATE->m_pCurSong->m_fFirstBeat;
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
m_Character[p].PlayAnimation( "rest" );
|
m_Character[p].PlayAnimation( "rest" );
|
||||||
}
|
}
|
||||||
@@ -201,7 +201,7 @@ void DancingCharacters::Update( float fDelta )
|
|||||||
* at a very low music rate. */
|
* at a very low music rate. */
|
||||||
fUpdateScale *= GAMESTATE->m_SongOptions.m_fMusicRate;
|
fUpdateScale *= GAMESTATE->m_SongOptions.m_fMusicRate;
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
m_Character[p].Update( fDelta*fUpdateScale );
|
m_Character[p].Update( fDelta*fUpdateScale );
|
||||||
@@ -212,7 +212,7 @@ void DancingCharacters::Update( float fDelta )
|
|||||||
bool bIsHereWeGo = GAMESTATE->m_bPastHereWeGo;
|
bool bIsHereWeGo = GAMESTATE->m_bPastHereWeGo;
|
||||||
if( !bWasHereWeGo && bIsHereWeGo )
|
if( !bWasHereWeGo && bIsHereWeGo )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
m_Character[p].PlayAnimation( "warmup" );
|
m_Character[p].PlayAnimation( "warmup" );
|
||||||
}
|
}
|
||||||
@@ -224,7 +224,7 @@ void DancingCharacters::Update( float fDelta )
|
|||||||
if( fLastBeat < GAMESTATE->m_pCurSong->m_fFirstBeat &&
|
if( fLastBeat < GAMESTATE->m_pCurSong->m_fFirstBeat &&
|
||||||
fThisBeat >= GAMESTATE->m_pCurSong->m_fFirstBeat )
|
fThisBeat >= GAMESTATE->m_pCurSong->m_fFirstBeat )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
m_Character[p].PlayAnimation( "dance" );
|
m_Character[p].PlayAnimation( "dance" );
|
||||||
}
|
}
|
||||||
fLastBeat = fThisBeat;
|
fLastBeat = fThisBeat;
|
||||||
@@ -267,7 +267,7 @@ void DancingCharacters::Update( float fDelta )
|
|||||||
}
|
}
|
||||||
|
|
||||||
// update any 2D stuff
|
// update any 2D stuff
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if(m_bHasIdleAnim[p])
|
if(m_bHasIdleAnim[p])
|
||||||
{
|
{
|
||||||
|
|||||||
+17
-17
@@ -409,7 +409,7 @@ void GameState::SaveCurrentSettingsToProfile( PlayerNumber pn )
|
|||||||
|
|
||||||
void GameState::Update( float fDelta )
|
void GameState::Update( float fDelta )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_CurrentPlayerOptions[p].Approach( m_PlayerOptions[p], fDelta );
|
m_CurrentPlayerOptions[p].Approach( m_PlayerOptions[p], fDelta );
|
||||||
|
|
||||||
@@ -463,7 +463,7 @@ void GameState::ReloadCharacters()
|
|||||||
delete m_pCharacters[i];
|
delete m_pCharacters[i];
|
||||||
m_pCharacters.clear();
|
m_pCharacters.clear();
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
m_pCurCharacters[p] = NULL;
|
m_pCurCharacters[p] = NULL;
|
||||||
|
|
||||||
CStringArray as;
|
CStringArray as;
|
||||||
@@ -515,7 +515,7 @@ void GameState::ResetStageStatistics()
|
|||||||
{
|
{
|
||||||
if( GetStageIndex() == 0 )
|
if( GetStageIndex() == 0 )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
Profile* pProfile = PROFILEMAN->GetProfile((PlayerNumber)p);
|
Profile* pProfile = PROFILEMAN->GetProfile((PlayerNumber)p);
|
||||||
if( pProfile )
|
if( pProfile )
|
||||||
@@ -532,7 +532,7 @@ void GameState::ResetStageStatistics()
|
|||||||
RemoveAllInventory();
|
RemoveAllInventory();
|
||||||
m_fOpponentHealthPercent = 1;
|
m_fOpponentHealthPercent = 1;
|
||||||
m_fTugLifePercentP1 = 0.5f;
|
m_fTugLifePercentP1 = 0.5f;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_fSuperMeter[p] = 0;
|
m_fSuperMeter[p] = 0;
|
||||||
m_HealthState[p] = ALIVE;
|
m_HealthState[p] = ALIVE;
|
||||||
@@ -543,7 +543,7 @@ void GameState::ResetStageStatistics()
|
|||||||
|
|
||||||
|
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_vLastPerDifficultyAwards[p].clear();
|
m_vLastPerDifficultyAwards[p].clear();
|
||||||
m_vLastPeakComboAwards[p].clear();
|
m_vLastPeakComboAwards[p].clear();
|
||||||
@@ -722,7 +722,7 @@ int GameState::GetCourseSongIndex() const
|
|||||||
{
|
{
|
||||||
int iSongIndex = 0;
|
int iSongIndex = 0;
|
||||||
/* iSongsPlayed includes the current song, so it's 1-based; subtract one. */
|
/* iSongsPlayed includes the current song, so it's 1-based; subtract one. */
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( IsPlayerEnabled(p) )
|
if( IsPlayerEnabled(p) )
|
||||||
iSongIndex = max( iSongIndex, g_CurStageStats.iSongsPlayed[p]-1 );
|
iSongIndex = max( iSongIndex, g_CurStageStats.iSongsPlayed[p]-1 );
|
||||||
return iSongIndex;
|
return iSongIndex;
|
||||||
@@ -803,7 +803,7 @@ bool GameState::IsPlayerEnabled( PlayerNumber pn ) const
|
|||||||
int GameState::GetNumPlayersEnabled() const
|
int GameState::GetNumPlayersEnabled() const
|
||||||
{
|
{
|
||||||
int count = 0;
|
int count = 0;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( IsPlayerEnabled(p) )
|
if( IsPlayerEnabled(p) )
|
||||||
count++;
|
count++;
|
||||||
return count;
|
return count;
|
||||||
@@ -838,7 +838,7 @@ bool GameState::IsHumanPlayer( PlayerNumber pn ) const
|
|||||||
int GameState::GetNumHumanPlayers() const
|
int GameState::GetNumHumanPlayers() const
|
||||||
{
|
{
|
||||||
int count = 0;
|
int count = 0;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( IsHumanPlayer(p) )
|
if( IsHumanPlayer(p) )
|
||||||
count++;
|
count++;
|
||||||
return count;
|
return count;
|
||||||
@@ -846,7 +846,7 @@ int GameState::GetNumHumanPlayers() const
|
|||||||
|
|
||||||
PlayerNumber GameState::GetFirstHumanPlayer() const
|
PlayerNumber GameState::GetFirstHumanPlayer() const
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( IsHumanPlayer(p) )
|
if( IsHumanPlayer(p) )
|
||||||
return (PlayerNumber)p;
|
return (PlayerNumber)p;
|
||||||
ASSERT(0); // there must be at least 1 human player
|
ASSERT(0); // there must be at least 1 human player
|
||||||
@@ -860,7 +860,7 @@ bool GameState::IsCpuPlayer( PlayerNumber pn ) const
|
|||||||
|
|
||||||
bool GameState::AnyPlayersAreCpu() const
|
bool GameState::AnyPlayersAreCpu() const
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( IsCpuPlayer(p) )
|
if( IsCpuPlayer(p) )
|
||||||
return true;
|
return true;
|
||||||
return false;
|
return false;
|
||||||
@@ -904,7 +904,7 @@ bool GameState::HasEarnedExtraStage() const
|
|||||||
|
|
||||||
if( (this->IsFinalStage() || this->IsExtraStage()) )
|
if( (this->IsFinalStage() || this->IsExtraStage()) )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !this->IsPlayerEnabled(p) )
|
if( !this->IsPlayerEnabled(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -1033,7 +1033,7 @@ void GameState::StoreSelectedOptions()
|
|||||||
* at the end of gameplay to restore options. */
|
* at the end of gameplay to restore options. */
|
||||||
void GameState::RestoreSelectedOptions()
|
void GameState::RestoreSelectedOptions()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
this->m_PlayerOptions[p] = this->m_StoredPlayerOptions[p];
|
this->m_PlayerOptions[p] = this->m_StoredPlayerOptions[p];
|
||||||
m_SongOptions = m_StoredSongOptions;
|
m_SongOptions = m_StoredSongOptions;
|
||||||
}
|
}
|
||||||
@@ -1178,7 +1178,7 @@ void GameState::RemoveActiveAttacksForPlayer( PlayerNumber pn, AttackLevel al )
|
|||||||
|
|
||||||
void GameState::RemoveAllInventory()
|
void GameState::RemoveAllInventory()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
for( int s=0; s<NUM_INVENTORY_SLOTS; s++ )
|
for( int s=0; s<NUM_INVENTORY_SLOTS; s++ )
|
||||||
{
|
{
|
||||||
m_Inventory[p][s].fSecsRemaining = 0;
|
m_Inventory[p][s].fSecsRemaining = 0;
|
||||||
@@ -1214,7 +1214,7 @@ void GameState::RebuildPlayerOptionsFromActiveAttacks( PlayerNumber pn )
|
|||||||
|
|
||||||
void GameState::RemoveAllActiveAttacks() // called on end of song
|
void GameState::RemoveAllActiveAttacks() // called on end of song
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
RemoveActiveAttacksForPlayer( (PlayerNumber)p );
|
RemoveActiveAttacksForPlayer( (PlayerNumber)p );
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1591,7 +1591,7 @@ void GameState::StoreRankingName( PlayerNumber pn, CString name )
|
|||||||
|
|
||||||
bool GameState::AllAreInDangerOrWorse() const
|
bool GameState::AllAreInDangerOrWorse() const
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( this->IsPlayerEnabled(p) )
|
if( this->IsPlayerEnabled(p) )
|
||||||
if( m_HealthState[p] < DANGER )
|
if( m_HealthState[p] < DANGER )
|
||||||
return false;
|
return false;
|
||||||
@@ -1600,7 +1600,7 @@ bool GameState::AllAreInDangerOrWorse() const
|
|||||||
|
|
||||||
bool GameState::AllAreDead() const
|
bool GameState::AllAreDead() const
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( this->IsPlayerEnabled(p) )
|
if( this->IsPlayerEnabled(p) )
|
||||||
if( m_HealthState[p] < DEAD )
|
if( m_HealthState[p] < DEAD )
|
||||||
return false;
|
return false;
|
||||||
@@ -1609,7 +1609,7 @@ bool GameState::AllAreDead() const
|
|||||||
|
|
||||||
bool GameState::OneIsHot() const
|
bool GameState::OneIsHot() const
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( this->IsPlayerEnabled(PlayerNumber(p)) )
|
if( this->IsPlayerEnabled(PlayerNumber(p)) )
|
||||||
if( m_HealthState[p] == HOT )
|
if( m_HealthState[p] == HOT )
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
@@ -78,7 +78,7 @@ GrooveRadar::GrooveRadarValueMap::GrooveRadarValueMap()
|
|||||||
m_sprRadarBase.Load( THEME->GetPathToG("GrooveRadar base") );
|
m_sprRadarBase.Load( THEME->GetPathToG("GrooveRadar base") );
|
||||||
this->AddChild( &m_sprRadarBase );
|
this->AddChild( &m_sprRadarBase );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_bValuesVisible[p] = false;
|
m_bValuesVisible[p] = false;
|
||||||
m_PercentTowardNew[p] = 0;
|
m_PercentTowardNew[p] = 0;
|
||||||
@@ -123,7 +123,7 @@ void GrooveRadar::GrooveRadarValueMap::Update( float fDeltaTime )
|
|||||||
|
|
||||||
if(DISABLE_RADAR != 1)
|
if(DISABLE_RADAR != 1)
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_PercentTowardNew[p] = min( m_PercentTowardNew[p]+4.0f*fDeltaTime, 1 );
|
m_PercentTowardNew[p] = min( m_PercentTowardNew[p]+4.0f*fDeltaTime, 1 );
|
||||||
}
|
}
|
||||||
@@ -143,7 +143,7 @@ void GrooveRadar::GrooveRadarValueMap::DrawPrimitives()
|
|||||||
DISPLAY->SetTextureModeModulate();
|
DISPLAY->SetTextureModeModulate();
|
||||||
RageSpriteVertex v[12]; // needed to draw 5 fan primitives and 10 strip primitives
|
RageSpriteVertex v[12]; // needed to draw 5 fan primitives and 10 strip primitives
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !m_bValuesVisible[p] )
|
if( !m_bValuesVisible[p] )
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ InputQueue* INPUTQUEUE = NULL; // global and accessable from anywhere in our pro
|
|||||||
|
|
||||||
InputQueue::InputQueue()
|
InputQueue::InputQueue()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
m_aQueue[p].insert(m_aQueue[p].begin(), MAX_INPUT_QUEUE_LENGTH, GameButtonAndTime() );
|
m_aQueue[p].insert(m_aQueue[p].begin(), MAX_INPUT_QUEUE_LENGTH, GameButtonAndTime() );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ MemoryCardManager::MemoryCardManager()
|
|||||||
{
|
{
|
||||||
m_pDriver = MakeMemoryCardDriver();
|
m_pDriver = MakeMemoryCardDriver();
|
||||||
m_bCardsLocked = false;
|
m_bCardsLocked = false;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_bTooLate[p] = false;
|
m_bTooLate[p] = false;
|
||||||
m_bWriteError[p] = false;
|
m_bWriteError[p] = false;
|
||||||
@@ -89,7 +89,7 @@ void MemoryCardManager::Update( float fDelta )
|
|||||||
|
|
||||||
// unassign cards that were disconnected
|
// unassign cards that were disconnected
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( m_Device[p].IsBlank() ) // not assigned a card
|
if( m_Device[p].IsBlank() ) // not assigned a card
|
||||||
continue;
|
continue;
|
||||||
@@ -158,7 +158,7 @@ void MemoryCardManager::LockCards( bool bLock )
|
|||||||
if( !bLock )
|
if( !bLock )
|
||||||
{
|
{
|
||||||
// clear too late flag
|
// clear too late flag
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
m_bTooLate[p] = false;
|
m_bTooLate[p] = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -172,7 +172,7 @@ void MemoryCardManager::AssignUnassignedCards()
|
|||||||
|
|
||||||
// remove cards that are already assigned
|
// remove cards that are already assigned
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( m_Device[p].IsBlank() ) // no card assigned to this player
|
if( m_Device[p].IsBlank() ) // no card assigned to this player
|
||||||
continue;
|
continue;
|
||||||
@@ -185,7 +185,7 @@ void MemoryCardManager::AssignUnassignedCards()
|
|||||||
|
|
||||||
// try to assign each device to a player
|
// try to assign each device to a player
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
LOG->Trace( "Looking for a card for Player %d", p+1 );
|
LOG->Trace( "Looking for a card for Player %d", p+1 );
|
||||||
|
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ bool CompareSongOptions( const SongOptions &so1, const SongOptions &so2 );
|
|||||||
|
|
||||||
bool ModeChoice::DescribesCurrentModeForAllPlayers() const
|
bool ModeChoice::DescribesCurrentModeForAllPlayers() const
|
||||||
{
|
{
|
||||||
for( int pn=0; pn<NUM_PLAYERS; pn++ )
|
FOREACH_PlayerNumber( pn )
|
||||||
if( !DescribesCurrentMode( (PlayerNumber) pn) )
|
if( !DescribesCurrentMode( (PlayerNumber) pn) )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
@@ -59,7 +59,7 @@ bool ModeChoice::DescribesCurrentMode( PlayerNumber pn ) const
|
|||||||
if( m_pSteps == NULL && m_dc != DIFFICULTY_INVALID )
|
if( m_pSteps == NULL && m_dc != DIFFICULTY_INVALID )
|
||||||
{
|
{
|
||||||
// Why is this checking for all players?
|
// Why is this checking for all players?
|
||||||
for( int pn=0; pn<NUM_PLAYERS; pn++ )
|
FOREACH_PlayerNumber( pn )
|
||||||
if( GAMESTATE->IsHumanPlayer(pn) && GAMESTATE->m_PreferredDifficulty[pn] != m_dc )
|
if( GAMESTATE->IsHumanPlayer(pn) && GAMESTATE->m_PreferredDifficulty[pn] != m_dc )
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -360,7 +360,7 @@ bool ModeChoice::IsPlayable( CString *why ) const
|
|||||||
|
|
||||||
void ModeChoice::ApplyToAllPlayers() const
|
void ModeChoice::ApplyToAllPlayers() const
|
||||||
{
|
{
|
||||||
for( int pn=0; pn<NUM_PLAYERS; pn++ )
|
FOREACH_PlayerNumber( pn )
|
||||||
if( GAMESTATE->IsHumanPlayer(pn) )
|
if( GAMESTATE->IsHumanPlayer(pn) )
|
||||||
Apply((PlayerNumber) pn);
|
Apply((PlayerNumber) pn);
|
||||||
|
|
||||||
|
|||||||
@@ -161,7 +161,7 @@ void MusicWheel::Load()
|
|||||||
po,
|
po,
|
||||||
so );
|
so );
|
||||||
GAMESTATE->m_pCurSong = pSong;
|
GAMESTATE->m_pCurSong = pSong;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
{
|
{
|
||||||
@@ -947,7 +947,7 @@ void MusicWheel::Update( float fDeltaTime )
|
|||||||
}
|
}
|
||||||
if( dc != DIFFICULTY_INVALID )
|
if( dc != DIFFICULTY_INVALID )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
GAMESTATE->m_PreferredDifficulty[p] = dc;
|
GAMESTATE->m_PreferredDifficulty[p] = dc;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ MusicWheelItem::MusicWheelItem()
|
|||||||
m_textRoulette.SetXY( ROULETTE_X, 0 );
|
m_textRoulette.SetXY( ROULETTE_X, 0 );
|
||||||
m_All.AddChild( &m_textRoulette );
|
m_All.AddChild( &m_textRoulette );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_GradeDisplay[p].Load( THEME->GetPathToG("MusicWheelItem grades") );
|
m_GradeDisplay[p].Load( THEME->GetPathToG("MusicWheelItem grades") );
|
||||||
m_GradeDisplay[p].SetZoom( 1.0f );
|
m_GradeDisplay[p].SetZoom( 1.0f );
|
||||||
@@ -193,7 +193,7 @@ void MusicWheelItem::LoadFromWheelItemData( WheelItemData* pWID )
|
|||||||
void MusicWheelItem::RefreshGrades()
|
void MusicWheelItem::RefreshGrades()
|
||||||
{
|
{
|
||||||
// Refresh Grades
|
// Refresh Grades
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !data->m_pSong || // this isn't a song display
|
if( !data->m_pSong || // this isn't a song display
|
||||||
!GAMESTATE->IsHumanPlayer(p) )
|
!GAMESTATE->IsHumanPlayer(p) )
|
||||||
@@ -240,7 +240,7 @@ void MusicWheelItem::Update( float fDeltaTime )
|
|||||||
m_sprSongBar.Update( fDeltaTime );
|
m_sprSongBar.Update( fDeltaTime );
|
||||||
m_WheelNotifyIcon.Update( fDeltaTime );
|
m_WheelNotifyIcon.Update( fDeltaTime );
|
||||||
m_TextBanner.Update( fDeltaTime );
|
m_TextBanner.Update( fDeltaTime );
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
m_GradeDisplay[p].Update( fDeltaTime );
|
m_GradeDisplay[p].Update( fDeltaTime );
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -290,7 +290,7 @@ void PrefsManager::Init()
|
|||||||
m_bLogCheckpoints = false;
|
m_bLogCheckpoints = false;
|
||||||
m_bShowLoadingWindow = true;
|
m_bShowLoadingWindow = true;
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_iMemoryCardUsbBus[p] = -1;
|
m_iMemoryCardUsbBus[p] = -1;
|
||||||
m_iMemoryCardUsbPort[p] = -1;
|
m_iMemoryCardUsbPort[p] = -1;
|
||||||
@@ -507,7 +507,7 @@ void PrefsManager::ReadPrefsFromFile( CString sIni )
|
|||||||
ini.GetValue( "Options", "DisableScreenSaver", m_bDisableScreenSaver );
|
ini.GetValue( "Options", "DisableScreenSaver", m_bDisableScreenSaver );
|
||||||
|
|
||||||
ini.GetValue( "Options", "MemoryCardProfileSubdir", m_sMemoryCardProfileSubdir );
|
ini.GetValue( "Options", "MemoryCardProfileSubdir", m_sMemoryCardProfileSubdir );
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
ini.GetValue( "Options", ssprintf("DefaultLocalProfileIDP%d",p+1), m_sDefaultLocalProfileID[p] );
|
ini.GetValue( "Options", ssprintf("DefaultLocalProfileIDP%d",p+1), m_sDefaultLocalProfileID[p] );
|
||||||
ini.GetValue( "Options", ssprintf("MemoryCardOsMountPointP%d",p+1), m_sMemoryCardOsMountPoint[p] );
|
ini.GetValue( "Options", ssprintf("MemoryCardOsMountPointP%d",p+1), m_sMemoryCardOsMountPoint[p] );
|
||||||
@@ -733,7 +733,7 @@ void PrefsManager::SaveGlobalPrefsToDisk() const
|
|||||||
ini.SetValue( "Options", "DisableScreenSaver", m_bDisableScreenSaver );
|
ini.SetValue( "Options", "DisableScreenSaver", m_bDisableScreenSaver );
|
||||||
|
|
||||||
ini.SetValue( "Options", "MemoryCardProfileSubdir", m_sMemoryCardProfileSubdir );
|
ini.SetValue( "Options", "MemoryCardProfileSubdir", m_sMemoryCardProfileSubdir );
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
ini.SetValue( "Options", ssprintf("DefaultLocalProfileIDP%d",p+1), m_sDefaultLocalProfileID[p] );
|
ini.SetValue( "Options", ssprintf("DefaultLocalProfileIDP%d",p+1), m_sDefaultLocalProfileID[p] );
|
||||||
ini.SetValue( "Options", ssprintf("MemoryCardOsMountPointP%d",p+1), m_sMemoryCardOsMountPoint[p] );
|
ini.SetValue( "Options", ssprintf("MemoryCardOsMountPointP%d",p+1), m_sMemoryCardOsMountPoint[p] );
|
||||||
|
|||||||
@@ -46,7 +46,7 @@ ProfileManager::ProfileManager()
|
|||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
m_bWasLoadedFromMemoryCard[p] = false;
|
m_bWasLoadedFromMemoryCard[p] = false;
|
||||||
|
|
||||||
LoadMachineProfile();
|
LoadMachineProfile();
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ ScreenAward::ScreenAward( CString sName ) : ScreenWithMenuElements( sName )
|
|||||||
bool bEitherPlayerHasAward = false;
|
bool bEitherPlayerHasAward = false;
|
||||||
ZERO( m_bSavedScreenshot );
|
ZERO( m_bSavedScreenshot );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue;
|
continue;
|
||||||
@@ -145,7 +145,7 @@ void ScreenAward::HandleScreenMessage( const ScreenMessage SM )
|
|||||||
case SM_GoToNextScreen:
|
case SM_GoToNextScreen:
|
||||||
// TRICKY: Keep looping on this screen until all awards are shown
|
// TRICKY: Keep looping on this screen until all awards are shown
|
||||||
bool bMoreAwardsLeft = false;
|
bool bMoreAwardsLeft = false;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue;
|
continue;
|
||||||
@@ -166,7 +166,7 @@ void ScreenAward::HandleScreenMessage( const ScreenMessage SM )
|
|||||||
|
|
||||||
void ScreenAward::MenuStart( PlayerNumber pn )
|
void ScreenAward::MenuStart( PlayerNumber pn )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
@@ -274,7 +274,7 @@ ScreenEdit::ScreenEdit( CString sName ) : Screen( sName )
|
|||||||
TICK_EARLY_SECONDS.Refresh();
|
TICK_EARLY_SECONDS.Refresh();
|
||||||
|
|
||||||
// set both players to joined so the credit message doesn't show
|
// set both players to joined so the credit message doesn't show
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
GAMESTATE->m_bSideIsJoined[p] = true;
|
GAMESTATE->m_bSideIsJoined[p] = true;
|
||||||
SCREENMAN->RefreshCreditsMessages();
|
SCREENMAN->RefreshCreditsMessages();
|
||||||
|
|
||||||
@@ -1251,7 +1251,7 @@ void ScreenEdit::InputPlay( const DeviceInput& DeviceI, const InputEventType typ
|
|||||||
case SDLK_F8:
|
case SDLK_F8:
|
||||||
{
|
{
|
||||||
PREFSMAN->m_bAutoPlay = !PREFSMAN->m_bAutoPlay;
|
PREFSMAN->m_bAutoPlay = !PREFSMAN->m_bAutoPlay;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
GAMESTATE->m_PlayerController[p] = PREFSMAN->m_bAutoPlay?PC_AUTOPLAY:PC_HUMAN;
|
GAMESTATE->m_PlayerController[p] = PREFSMAN->m_bAutoPlay?PC_AUTOPLAY:PC_HUMAN;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -204,7 +204,7 @@ void ScreenEvaluation::Init()
|
|||||||
// Debugging
|
// Debugging
|
||||||
//
|
//
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ ) // foreach line
|
FOREACH_PlayerNumber( p ) // foreach line
|
||||||
for( int r=0; r<NUM_RADAR_CATEGORIES; r++ ) // foreach line
|
for( int r=0; r<NUM_RADAR_CATEGORIES; r++ ) // foreach line
|
||||||
{
|
{
|
||||||
stageStats.fRadarPossible[p][r] = 0.5f + r/10.0f;
|
stageStats.fRadarPossible[p][r] = 0.5f + r/10.0f;
|
||||||
@@ -1483,7 +1483,7 @@ void ScreenEvaluation::EndScreen()
|
|||||||
{
|
{
|
||||||
TweenOffScreen();
|
TweenOffScreen();
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
m_Grades[p].SettleImmediately();
|
m_Grades[p].SettleImmediately();
|
||||||
|
|
||||||
GAMESTATE->m_iRoundSeed = rand();
|
GAMESTATE->m_iRoundSeed = rand();
|
||||||
|
|||||||
@@ -219,7 +219,7 @@ void ScreenEz2SelectPlayer::MenuStart( PlayerNumber pn )
|
|||||||
}
|
}
|
||||||
|
|
||||||
bool bBothSidesJoined = true;
|
bool bBothSidesJoined = true;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( !GAMESTATE->m_bSideIsJoined[p] )
|
if( !GAMESTATE->m_bSideIsJoined[p] )
|
||||||
bBothSidesJoined = false;
|
bBothSidesJoined = false;
|
||||||
|
|
||||||
@@ -239,7 +239,7 @@ void ScreenEz2SelectPlayer::MenuStart( PlayerNumber pn )
|
|||||||
|
|
||||||
void ScreenEz2SelectPlayer::TweenOnScreen()
|
void ScreenEz2SelectPlayer::TweenOnScreen()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
float fOffScreenOffset = float( (p==PLAYER_1) ? -SCREEN_WIDTH/2 : +SCREEN_WIDTH/2 );
|
float fOffScreenOffset = float( (p==PLAYER_1) ? -SCREEN_WIDTH/2 : +SCREEN_WIDTH/2 );
|
||||||
|
|
||||||
@@ -259,7 +259,7 @@ void ScreenEz2SelectPlayer::TweenOnScreen()
|
|||||||
|
|
||||||
void ScreenEz2SelectPlayer::TweenOffScreen()
|
void ScreenEz2SelectPlayer::TweenOffScreen()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
float fOffScreenOffset = float( (p==PLAYER_1) ? -SCREEN_WIDTH : +SCREEN_WIDTH );
|
float fOffScreenOffset = float( (p==PLAYER_1) ? -SCREEN_WIDTH : +SCREEN_WIDTH );
|
||||||
|
|
||||||
|
|||||||
@@ -95,7 +95,7 @@ bool ScreenJukebox::SetSong( bool bDemonstration )
|
|||||||
|
|
||||||
// Found something we can use!
|
// Found something we can use!
|
||||||
GAMESTATE->m_pCurSong = pSong;
|
GAMESTATE->m_pCurSong = pSong;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
GAMESTATE->m_pCurNotes[p] = pSteps;
|
GAMESTATE->m_pCurNotes[p] = pSteps;
|
||||||
|
|
||||||
return true; // done looking
|
return true; // done looking
|
||||||
@@ -122,7 +122,7 @@ bool ScreenJukebox::PrepareForJukebox( bool bDemonstration ) // always return t
|
|||||||
{
|
{
|
||||||
/* Note that you also need to make sure you benchmark with the
|
/* Note that you also need to make sure you benchmark with the
|
||||||
* same notes. I use a copy of MaxU with only heavy notes included. */
|
* same notes. I use a copy of MaxU with only heavy notes included. */
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsPlayerEnabled(p) )
|
if( !GAMESTATE->IsPlayerEnabled(p) )
|
||||||
continue;
|
continue;
|
||||||
@@ -138,7 +138,7 @@ bool ScreenJukebox::PrepareForJukebox( bool bDemonstration ) // always return t
|
|||||||
GAMESTATE->m_SongOptions.m_FailType = SongOptions::FAIL_OFF;
|
GAMESTATE->m_SongOptions.m_FailType = SongOptions::FAIL_OFF;
|
||||||
}
|
}
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsPlayerEnabled(p) )
|
if( !GAMESTATE->IsPlayerEnabled(p) )
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ ScreenJukeboxMenu::ScreenJukeboxMenu( CString sClassName ) : ScreenWithMenuEleme
|
|||||||
|
|
||||||
GAMESTATE->m_CurStyle = STYLE_INVALID;
|
GAMESTATE->m_CurStyle = STYLE_INVALID;
|
||||||
|
|
||||||
for( int pn=0; pn<NUM_PLAYERS; pn++ )
|
FOREACH_PlayerNumber( pn )
|
||||||
GAMESTATE->m_bSideIsJoined[pn] = true;
|
GAMESTATE->m_bSideIsJoined[pn] = true;
|
||||||
|
|
||||||
m_Selector.SetXY( 0, 0 );
|
m_Selector.SetXY( 0, 0 );
|
||||||
@@ -122,7 +122,7 @@ void ScreenJukeboxMenu::MenuStart( PlayerNumber pn )
|
|||||||
|
|
||||||
GAMESTATE->m_CurStyle = style;
|
GAMESTATE->m_CurStyle = style;
|
||||||
GAMESTATE->m_sPreferredGroup = (sGroup=="ALL MUSIC") ? GROUP_ALL_MUSIC : sGroup;
|
GAMESTATE->m_sPreferredGroup = (sGroup=="ALL MUSIC") ? GROUP_ALL_MUSIC : sGroup;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
GAMESTATE->m_PreferredDifficulty[p] = dc;
|
GAMESTATE->m_PreferredDifficulty[p] = dc;
|
||||||
GAMESTATE->m_bJukeboxUsesModifiers = bModifiers;
|
GAMESTATE->m_bJukeboxUsesModifiers = bModifiers;
|
||||||
|
|
||||||
|
|||||||
@@ -97,7 +97,7 @@ ScreenSystemLayer::ScreenSystemLayer() : Screen("ScreenSystemLayer")
|
|||||||
this->AddChild(&m_textMessage);
|
this->AddChild(&m_textMessage);
|
||||||
this->AddChild(&m_textStats);
|
this->AddChild(&m_textStats);
|
||||||
this->AddChild(&m_textTime);
|
this->AddChild(&m_textTime);
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
this->AddChild(&m_textCredits[p]);
|
this->AddChild(&m_textCredits[p]);
|
||||||
|
|
||||||
|
|
||||||
@@ -150,7 +150,7 @@ void ScreenSystemLayer::ReloadCreditsText()
|
|||||||
m_textTime.SetName( "Time" );
|
m_textTime.SetName( "Time" );
|
||||||
SET_XY_AND_ON_COMMAND( m_textTime );
|
SET_XY_AND_ON_COMMAND( m_textTime );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_textCredits[p].LoadFromFont( THEME->GetPathToF("ScreenManager credits") );
|
m_textCredits[p].LoadFromFont( THEME->GetPathToF("ScreenManager credits") );
|
||||||
m_textCredits[p].SetName( ssprintf("CreditsP%d",p+1) );
|
m_textCredits[p].SetName( ssprintf("CreditsP%d",p+1) );
|
||||||
@@ -185,7 +185,7 @@ void ScreenSystemLayer::SystemMessageNoAnimate( CString sMessage )
|
|||||||
void ScreenSystemLayer::RefreshCreditsMessages()
|
void ScreenSystemLayer::RefreshCreditsMessages()
|
||||||
{
|
{
|
||||||
// update joined
|
// update joined
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
CString sCredits;
|
CString sCredits;
|
||||||
|
|
||||||
|
|||||||
@@ -129,7 +129,7 @@ ScreenNameEntry::ScreenNameEntry( CString sClassName ) : Screen( sClassName )
|
|||||||
|
|
||||||
// reset Player and Song Options
|
// reset Player and Song Options
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
GAMESTATE->m_PlayerOptions[p] = PlayerOptions();
|
GAMESTATE->m_PlayerOptions[p] = PlayerOptions();
|
||||||
GAMESTATE->m_SongOptions = SongOptions();
|
GAMESTATE->m_SongOptions = SongOptions();
|
||||||
}
|
}
|
||||||
@@ -274,7 +274,7 @@ ScreenNameEntry::ScreenNameEntry( CString sClassName ) : Screen( sClassName )
|
|||||||
|
|
||||||
bool ScreenNameEntry::AnyStillEntering() const
|
bool ScreenNameEntry::AnyStillEntering() const
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( m_bStillEnteringName[p] )
|
if( m_bStillEnteringName[p] )
|
||||||
return true;
|
return true;
|
||||||
return false;
|
return false;
|
||||||
@@ -308,7 +308,7 @@ void ScreenNameEntry::DrawPrimitives()
|
|||||||
|
|
||||||
const StyleDef* pStyleDef = GAMESTATE->GetCurrentStyleDef();
|
const StyleDef* pStyleDef = GAMESTATE->GetCurrentStyleDef();
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !m_bStillEnteringName[p] )
|
if( !m_bStillEnteringName[p] )
|
||||||
continue; // don't draw scrolling arrows
|
continue; // don't draw scrolling arrows
|
||||||
@@ -387,7 +387,7 @@ void ScreenNameEntry::HandleScreenMessage( const ScreenMessage SM )
|
|||||||
case SM_MenuTimer:
|
case SM_MenuTimer:
|
||||||
if( !m_Out.IsTransitioning() )
|
if( !m_Out.IsTransitioning() )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
this->MenuStart( (PlayerNumber)p );
|
this->MenuStart( (PlayerNumber)p );
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -463,7 +463,7 @@ void ScreenNameEntryTraditional::PositionCharsAndCursor( int pn )
|
|||||||
|
|
||||||
bool ScreenNameEntryTraditional::AnyStillEntering() const
|
bool ScreenNameEntryTraditional::AnyStillEntering() const
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( m_bStillEnteringName[p] )
|
if( m_bStillEnteringName[p] )
|
||||||
return true;
|
return true;
|
||||||
return false;
|
return false;
|
||||||
@@ -548,7 +548,7 @@ void ScreenNameEntryTraditional::HandleScreenMessage( const ScreenMessage SM )
|
|||||||
case SM_MenuTimer:
|
case SM_MenuTimer:
|
||||||
if( !m_Out.IsTransitioning() )
|
if( !m_Out.IsTransitioning() )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
Finish( (PlayerNumber)p );
|
Finish( (PlayerNumber)p );
|
||||||
MenuStart( PLAYER_INVALID, IET_FIRST_PRESS );
|
MenuStart( PLAYER_INVALID, IET_FIRST_PRESS );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -109,7 +109,7 @@ ScreenOptions::ScreenOptions( CString sClassName ) : ScreenWithMenuElements(sCla
|
|||||||
this->AddChild( &m_framePage );
|
this->AddChild( &m_framePage );
|
||||||
|
|
||||||
m_bMoreShown = false;
|
m_bMoreShown = false;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_iCurrentRow[p] = 0;
|
m_iCurrentRow[p] = 0;
|
||||||
m_bWasOnExit[p] = false;
|
m_bWasOnExit[p] = false;
|
||||||
@@ -141,7 +141,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
RageException::Throw( "Screen %s menu entry \"%s\" has no choices",
|
RageException::Throw( "Screen %s menu entry \"%s\" has no choices",
|
||||||
m_sName.c_str(), OptionRows[r].name.c_str() );
|
m_sName.c_str(), OptionRows[r].name.c_str() );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
vector<bool> &vbSelected = Row.m_vbSelected[p];
|
vector<bool> &vbSelected = Row.m_vbSelected[p];
|
||||||
vbSelected.resize( Row.m_RowDef.choices.size() );
|
vbSelected.resize( Row.m_RowDef.choices.size() );
|
||||||
@@ -168,7 +168,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
Row.m_vbSelected[p] = m_Rows[r]->m_vbSelected[0];
|
Row.m_vbSelected[p] = m_Rows[r]->m_vbSelected[0];
|
||||||
|
|
||||||
CHECKPOINT_M( ssprintf("row %i: %s", r, Row.m_RowDef.name.c_str()) );
|
CHECKPOINT_M( ssprintf("row %i: %s", r, Row.m_RowDef.name.c_str()) );
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( m_OptionsNavigation==NAV_FIRST_CHOICE_GOES_DOWN )
|
if( m_OptionsNavigation==NAV_FIRST_CHOICE_GOES_DOWN )
|
||||||
Row.m_iChoiceWithFocus[p] = 0; // focus on the first row, which is "go down"
|
Row.m_iChoiceWithFocus[p] = 0; // focus on the first row, which is "go down"
|
||||||
else
|
else
|
||||||
@@ -197,7 +197,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
|
|
||||||
// init line highlights
|
// init line highlights
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -212,7 +212,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
|
|
||||||
// init highlights
|
// init highlights
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -224,7 +224,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
|
|
||||||
// init row icons
|
// init row icons
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -271,7 +271,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
bt->SetX( fX );
|
bt->SetX( fX );
|
||||||
|
|
||||||
// init underlines
|
// init underlines
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue;
|
continue;
|
||||||
@@ -292,7 +292,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
for( unsigned j=0; j<textItems.size(); j++ ) // for each option on this row
|
for( unsigned j=0; j<textItems.size(); j++ ) // for each option on this row
|
||||||
delete textItems[j];
|
delete textItems[j];
|
||||||
textItems.clear();
|
textItems.clear();
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
for( unsigned j=0; j<row.m_Underline[p].size(); j++ ) // for each option on this row
|
for( unsigned j=0; j<row.m_Underline[p].size(); j++ ) // for each option on this row
|
||||||
delete row.m_Underline[p][j];
|
delete row.m_Underline[p][j];
|
||||||
@@ -354,7 +354,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
{
|
{
|
||||||
for( unsigned c=0; c<textItems.size(); c++ )
|
for( unsigned c=0; c<textItems.size(); c++ )
|
||||||
m_framePage.AddChild( textItems[c] );
|
m_framePage.AddChild( textItems[c] );
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
for( unsigned c=0; c<row.m_Underline[p].size(); c++ )
|
for( unsigned c=0; c<row.m_Underline[p].size(); c++ )
|
||||||
m_framePage.AddChild( row.m_Underline[p][c] );
|
m_framePage.AddChild( row.m_Underline[p][c] );
|
||||||
}
|
}
|
||||||
@@ -383,7 +383,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
|
|
||||||
// add explanation here so it appears on top
|
// add explanation here so it appears on top
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_textExplanation[p].LoadFromFont( THEME->GetPathToF("ScreenOptions explanation") );
|
m_textExplanation[p].LoadFromFont( THEME->GetPathToF("ScreenOptions explanation") );
|
||||||
m_textExplanation[p].SetZoom( EXPLANATION_ZOOM );
|
m_textExplanation[p].SetZoom( EXPLANATION_ZOOM );
|
||||||
@@ -396,7 +396,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
* the player name is meaningful. Otherwise, we're probably in the system menu. */
|
* the player name is meaningful. Otherwise, we're probably in the system menu. */
|
||||||
if( GAMESTATE->m_CurStyle != STYLE_INVALID )
|
if( GAMESTATE->m_CurStyle != STYLE_INVALID )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_textPlayerName[p].LoadFromFont( THEME->GetPathToF( "ScreenOptions player") );
|
m_textPlayerName[p].LoadFromFont( THEME->GetPathToF( "ScreenOptions player") );
|
||||||
m_textPlayerName[p].SetName( ssprintf("PlayerNameP%i",p+1) );
|
m_textPlayerName[p].SetName( ssprintf("PlayerNameP%i",p+1) );
|
||||||
@@ -411,7 +411,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
m_ScrollBar.SetName( "DualScrollBar", "ScrollBar" );
|
m_ScrollBar.SetName( "DualScrollBar", "ScrollBar" );
|
||||||
m_ScrollBar.SetBarHeight( SCROLL_BAR_HEIGHT );
|
m_ScrollBar.SetBarHeight( SCROLL_BAR_HEIGHT );
|
||||||
m_ScrollBar.SetBarTime( SCROLL_BAR_TIME );
|
m_ScrollBar.SetBarTime( SCROLL_BAR_TIME );
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
m_ScrollBar.EnablePlayer( (PlayerNumber)p, GAMESTATE->IsHumanPlayer(p) );
|
m_ScrollBar.EnablePlayer( (PlayerNumber)p, GAMESTATE->IsHumanPlayer(p) );
|
||||||
m_ScrollBar.Load();
|
m_ScrollBar.Load();
|
||||||
UtilSetXY( m_ScrollBar, "ScreenOptions" );
|
UtilSetXY( m_ScrollBar, "ScreenOptions" );
|
||||||
@@ -428,7 +428,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
{
|
{
|
||||||
case INPUTMODE_INDIVIDUAL:
|
case INPUTMODE_INDIVIDUAL:
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
m_textExplanation[p].SetXY( EXPLANATION_X(p), EXPLANATION_Y(p) );
|
m_textExplanation[p].SetXY( EXPLANATION_X(p), EXPLANATION_Y(p) );
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -439,7 +439,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
ASSERT(0);
|
ASSERT(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_sprDisqualify[p].Load( THEME->GetPathToG( "ScreenOptions disqualify") );
|
m_sprDisqualify[p].Load( THEME->GetPathToG( "ScreenOptions disqualify") );
|
||||||
m_sprDisqualify[p]->SetName( "ScreenOptions", ssprintf("DisqualifyP%i",p+1) );
|
m_sprDisqualify[p]->SetName( "ScreenOptions", ssprintf("DisqualifyP%i",p+1) );
|
||||||
@@ -470,7 +470,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
PositionCursors();
|
PositionCursors();
|
||||||
UpdateEnabledDisabled();
|
UpdateEnabledDisabled();
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
OnChange( (PlayerNumber)p );
|
OnChange( (PlayerNumber)p );
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -487,7 +487,7 @@ void ScreenOptions::Init( InputMode im, OptionRowData OptionRows[], int iNumOpti
|
|||||||
|
|
||||||
for( unsigned c=0; c<row.m_textItems.size(); c++ )
|
for( unsigned c=0; c<row.m_textItems.size(); c++ )
|
||||||
row.m_textItems[c]->FinishTweening();
|
row.m_textItems[c]->FinishTweening();
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
for( unsigned c=0; c<row.m_Underline[p].size(); c++ )
|
for( unsigned c=0; c<row.m_Underline[p].size(); c++ )
|
||||||
row.m_Underline[p][c]->FinishTweening();
|
row.m_Underline[p][c]->FinishTweening();
|
||||||
@@ -642,7 +642,7 @@ void ScreenOptions::PositionUnderlines()
|
|||||||
if( row.Type == Row::ROW_EXIT )
|
if( row.Type == Row::ROW_EXIT )
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -686,7 +686,7 @@ void ScreenOptions::PositionUnderlines()
|
|||||||
|
|
||||||
void ScreenOptions::PositionIcons()
|
void ScreenOptions::PositionIcons()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ ) // foreach player
|
FOREACH_PlayerNumber( p ) // foreach player
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue;
|
continue;
|
||||||
@@ -728,7 +728,7 @@ void ScreenOptions::PositionCursors()
|
|||||||
{
|
{
|
||||||
// Set the position of the highlight showing the current option the user is changing.
|
// Set the position of the highlight showing the current option the user is changing.
|
||||||
// Set the position of the underscores showing the current choice for each option line.
|
// Set the position of the underscores showing the current choice for each option line.
|
||||||
for( int pn=0; pn<NUM_PLAYERS; pn++ ) // foreach player
|
FOREACH_PlayerNumber( pn ) // foreach player
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(pn) )
|
if( !GAMESTATE->IsHumanPlayer(pn) )
|
||||||
continue;
|
continue;
|
||||||
@@ -811,7 +811,7 @@ void ScreenOptions::UpdateEnabledDisabled()
|
|||||||
Row &row = *m_Rows[i];
|
Row &row = *m_Rows[i];
|
||||||
|
|
||||||
bool bThisRowIsSelected = false;
|
bool bThisRowIsSelected = false;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) && m_iCurrentRow[p] == (int) i )
|
if( GAMESTATE->IsHumanPlayer(p) && m_iCurrentRow[p] == (int) i )
|
||||||
bThisRowIsSelected = true;
|
bThisRowIsSelected = true;
|
||||||
|
|
||||||
@@ -843,7 +843,7 @@ void ScreenOptions::UpdateEnabledDisabled()
|
|||||||
if( row.Type == Row::ROW_EXIT )
|
if( row.Type == Row::ROW_EXIT )
|
||||||
{
|
{
|
||||||
bool bExitRowIsSelectedByBoth = true;
|
bool bExitRowIsSelectedByBoth = true;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) && m_iCurrentRow[p] != (int) i )
|
if( GAMESTATE->IsHumanPlayer(p) && m_iCurrentRow[p] != (int) i )
|
||||||
bExitRowIsSelectedByBoth = false;
|
bExitRowIsSelectedByBoth = false;
|
||||||
|
|
||||||
@@ -1078,7 +1078,7 @@ void ScreenOptions::OnChange( PlayerNumber pn )
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Update all players, since changing one player can move both cursors. */
|
/* Update all players, since changing one player can move both cursors. */
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
TweenCursor( (PlayerNumber) p );
|
TweenCursor( (PlayerNumber) p );
|
||||||
@@ -1180,7 +1180,7 @@ void ScreenOptions::MenuStart( PlayerNumber pn, const InputEventType type )
|
|||||||
if( row.Type == Row::ROW_EXIT )
|
if( row.Type == Row::ROW_EXIT )
|
||||||
{
|
{
|
||||||
bool bAllOnExit = true;
|
bool bAllOnExit = true;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) && m_Rows[m_iCurrentRow[p]]->Type != Row::ROW_EXIT )
|
if( GAMESTATE->IsHumanPlayer(p) && m_Rows[m_iCurrentRow[p]]->Type != Row::ROW_EXIT )
|
||||||
bAllOnExit = false;
|
bAllOnExit = false;
|
||||||
|
|
||||||
@@ -1308,7 +1308,7 @@ void ScreenOptions::ChangeValueInRow( PlayerNumber pn, int iDelta, bool Repeat )
|
|||||||
row.m_iChoiceWithFocus[p] = iNewChoiceWithFocus;
|
row.m_iChoiceWithFocus[p] = iNewChoiceWithFocus;
|
||||||
}
|
}
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( m_OptionsNavigation==NAV_FIRST_CHOICE_GOES_DOWN )
|
if( m_OptionsNavigation==NAV_FIRST_CHOICE_GOES_DOWN )
|
||||||
{
|
{
|
||||||
@@ -1363,7 +1363,7 @@ void ScreenOptions::MoveRow( PlayerNumber pn, int dir, bool Repeat )
|
|||||||
|
|
||||||
LOG->Trace("move pn %i, dir %i, rep %i", pn, dir, Repeat);
|
LOG->Trace("move pn %i, dir %i, rep %i", pn, dir, Repeat);
|
||||||
bool changed = false;
|
bool changed = false;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( m_InputMode == INPUTMODE_INDIVIDUAL && p != pn )
|
if( m_InputMode == INPUTMODE_INDIVIDUAL && p != pn )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -1404,7 +1404,7 @@ ScreenOptions::Row::~Row()
|
|||||||
{
|
{
|
||||||
for( unsigned i = 0; i < m_textItems.size(); ++i )
|
for( unsigned i = 0; i < m_textItems.size(); ++i )
|
||||||
delete m_textItems[i];
|
delete m_textItems[i];
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
for( unsigned i = 0; i < m_Underline[p].size(); ++i )
|
for( unsigned i = 0; i < m_Underline[p].size(); ++i )
|
||||||
delete m_Underline[p][i];
|
delete m_Underline[p][i];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -229,7 +229,7 @@ ScreenOptionsMaster::ScreenOptionsMaster( CString sClassName ):
|
|||||||
Explanations = true;
|
Explanations = true;
|
||||||
if( Flags[i] == "forceallplayers" )
|
if( Flags[i] == "forceallplayers" )
|
||||||
{
|
{
|
||||||
for( int pn=0; pn<NUM_PLAYERS; pn++ )
|
FOREACH_PlayerNumber( pn )
|
||||||
GAMESTATE->m_bSideIsJoined[pn] = true;
|
GAMESTATE->m_bSideIsJoined[pn] = true;
|
||||||
GAMESTATE->m_MasterPlayerNumber = PlayerNumber(0);
|
GAMESTATE->m_MasterPlayerNumber = PlayerNumber(0);
|
||||||
}
|
}
|
||||||
@@ -410,7 +410,7 @@ void ScreenOptionsMaster::ImportOptions()
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -506,7 +506,7 @@ void ScreenOptionsMaster::ExportOptions()
|
|||||||
const OptionRowData &data = m_OptionRowAlloc[i];
|
const OptionRowData &data = m_OptionRowAlloc[i];
|
||||||
Row &row = *m_Rows[i];
|
Row &row = *m_Rows[i];
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue;
|
continue;
|
||||||
@@ -587,7 +587,7 @@ void ScreenOptionsMaster::GoToPrevState()
|
|||||||
|
|
||||||
void ScreenOptionsMaster::RefreshIcons()
|
void ScreenOptionsMaster::RefreshIcons()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ ) // foreach player
|
FOREACH_PlayerNumber( p ) // foreach player
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
@@ -176,7 +176,7 @@ void ScreenPlayerOptions::UpdateDisqualified()
|
|||||||
// save current player options
|
// save current player options
|
||||||
PlayerOptions po[2];
|
PlayerOptions po[2];
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
po[p] = GAMESTATE->m_PlayerOptions[p];
|
po[p] = GAMESTATE->m_PlayerOptions[p];
|
||||||
}
|
}
|
||||||
@@ -186,7 +186,7 @@ void ScreenPlayerOptions::UpdateDisqualified()
|
|||||||
ScreenOptionsMaster::ExportOptions();
|
ScreenOptionsMaster::ExportOptions();
|
||||||
|
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
bool bIsHandicap = GAMESTATE->IsDisqualified((PlayerNumber)p);
|
bool bIsHandicap = GAMESTATE->IsDisqualified((PlayerNumber)p);
|
||||||
|
|
||||||
|
|||||||
@@ -186,7 +186,7 @@ void ScreenSelect::FinalizeChoices()
|
|||||||
* invalidate the choice we've already made. Hack: apply the style.
|
* invalidate the choice we've already made. Hack: apply the style.
|
||||||
* (Applying the style may have other side-effects, so it'll be re-applied
|
* (Applying the style may have other side-effects, so it'll be re-applied
|
||||||
* in SM_GoToNextScreen.) */
|
* in SM_GoToNextScreen.) */
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
{
|
{
|
||||||
const int sel = GetSelectionIndex( (PlayerNumber)p );
|
const int sel = GetSelectionIndex( (PlayerNumber)p );
|
||||||
@@ -217,7 +217,7 @@ void ScreenSelect::HandleScreenMessage( const ScreenMessage SM )
|
|||||||
/* Apply here, not in SM_AllDoneChoosing, because applying can take a very
|
/* Apply here, not in SM_AllDoneChoosing, because applying can take a very
|
||||||
* long time (200+ms), and at SM_AllDoneChoosing, we're still tweening stuff
|
* long time (200+ms), and at SM_AllDoneChoosing, we're still tweening stuff
|
||||||
* off-screen. */
|
* off-screen. */
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
m_aModeChoices[this->GetSelectionIndex((PlayerNumber)p)].Apply( (PlayerNumber)p );
|
m_aModeChoices[this->GetSelectionIndex((PlayerNumber)p)].Apply( (PlayerNumber)p );
|
||||||
|
|
||||||
|
|||||||
@@ -364,7 +364,7 @@ void ScreenSelectCharacter::MenuStart( PlayerNumber pn )
|
|||||||
|
|
||||||
if( AllAreFinishedChoosing() )
|
if( AllAreFinishedChoosing() )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
vector<Character*> apCharacters;
|
vector<Character*> apCharacters;
|
||||||
GAMESTATE->GetCharacters( apCharacters );
|
GAMESTATE->GetCharacters( apCharacters );
|
||||||
@@ -385,7 +385,7 @@ void ScreenSelectCharacter::MenuBack( PlayerNumber pn )
|
|||||||
|
|
||||||
void ScreenSelectCharacter::TweenOffScreen()
|
void ScreenSelectCharacter::TweenOffScreen()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_sprCard[p].Command( CARD_OFF_COMMAND(p) );
|
m_sprCard[p].Command( CARD_OFF_COMMAND(p) );
|
||||||
m_sprTitle[p].Command( TITLE_OFF_COMMAND(p) );
|
m_sprTitle[p].Command( TITLE_OFF_COMMAND(p) );
|
||||||
|
|||||||
@@ -101,7 +101,7 @@ ScreenSelectCourse::ScreenSelectCourse( CString sClassName ) : ScreenWithMenuEle
|
|||||||
m_MusicWheel.SetXY( WHEEL_X, WHEEL_Y );
|
m_MusicWheel.SetXY( WHEEL_X, WHEEL_Y );
|
||||||
this->AddChild( &m_MusicWheel );
|
this->AddChild( &m_MusicWheel );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer((PlayerNumber)p) )
|
if( !GAMESTATE->IsHumanPlayer((PlayerNumber)p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -173,7 +173,7 @@ void ScreenSelectCourse::TweenOnScreen()
|
|||||||
m_textNumSongs.Command( "AddX,-640;BounceEnd,0.5;AddX,640" );
|
m_textNumSongs.Command( "AddX,-640;BounceEnd,0.5;AddX,640" );
|
||||||
m_textTime.Command( "AddX,-640;BounceEnd,0.5;AddX,640" );
|
m_textTime.Command( "AddX,-640;BounceEnd,0.5;AddX,640" );
|
||||||
m_CourseContentsFrame.Command( "ZoomY,0;BounceEnd,0.5;ZoomY,1" );
|
m_CourseContentsFrame.Command( "ZoomY,0;BounceEnd,0.5;ZoomY,1" );
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_sprHighScoreFrame[p].Command( "AddX,640;BounceEnd,0.5;AddX,-640" );
|
m_sprHighScoreFrame[p].Command( "AddX,640;BounceEnd,0.5;AddX,-640" );
|
||||||
m_HighScore[p].Command( "AddX,640;BounceEnd,0.5;AddX,-640" );
|
m_HighScore[p].Command( "AddX,640;BounceEnd,0.5;AddX,-640" );
|
||||||
@@ -189,7 +189,7 @@ void ScreenSelectCourse::TweenOffScreen()
|
|||||||
m_textNumSongs.Command( "BounceBegin,0.5;AddX,-640" );
|
m_textNumSongs.Command( "BounceBegin,0.5;AddX,-640" );
|
||||||
m_textTime.Command( "BounceBegin,0.5;AddX,-640" );
|
m_textTime.Command( "BounceBegin,0.5;AddX,-640" );
|
||||||
m_CourseContentsFrame.Command( "Linear,0.5;ZoomY,0" );
|
m_CourseContentsFrame.Command( "Linear,0.5;ZoomY,0" );
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_sprHighScoreFrame[p].Command( "BounceBegin,0.5;AddX,640" );
|
m_sprHighScoreFrame[p].Command( "BounceBegin,0.5;AddX,640" );
|
||||||
m_HighScore[p].Command( "BounceBegin,0.5;AddX,640" );
|
m_HighScore[p].Command( "BounceBegin,0.5;AddX,640" );
|
||||||
@@ -400,7 +400,7 @@ void ScreenSelectCourse::AfterCourseChange()
|
|||||||
m_CourseContentsFrame.TweenInAfterChangedCourse();
|
m_CourseContentsFrame.TweenInAfterChangedCourse();
|
||||||
|
|
||||||
ASSERT(pCourse);
|
ASSERT(pCourse);
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
CourseDifficulty cd = GAMESTATE->m_PreferredCourseDifficulty[p];
|
CourseDifficulty cd = GAMESTATE->m_PreferredCourseDifficulty[p];
|
||||||
|
|
||||||
@@ -461,7 +461,7 @@ void ScreenSelectCourse::AfterCourseChange()
|
|||||||
|
|
||||||
void ScreenSelectCourse::UpdateOptionsDisplays()
|
void ScreenSelectCourse::UpdateOptionsDisplays()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -182,7 +182,7 @@ void ScreenSelectDifficulty::UpdateSelectableChoices()
|
|||||||
// I'm not sure why this was here -- but there seem no ill effects
|
// I'm not sure why this was here -- but there seem no ill effects
|
||||||
// of it's removal.
|
// of it's removal.
|
||||||
//
|
//
|
||||||
//for( int p=0; p<NUM_PLAYERS; p++ )
|
//FOREACH_PlayerNumber( p )
|
||||||
// if( GAMESTATE->IsHumanPlayer(p) )
|
// if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
// {
|
// {
|
||||||
// MenuRight( (PlayerNumber)p );
|
// MenuRight( (PlayerNumber)p );
|
||||||
@@ -212,7 +212,7 @@ void ScreenSelectDifficulty::MenuLeft( PlayerNumber pn )
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
bool AnotherPlayerSelected = false;
|
bool AnotherPlayerSelected = false;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( p != pn && m_bChosen[p] )
|
if( p != pn && m_bChosen[p] )
|
||||||
AnotherPlayerSelected = true;
|
AnotherPlayerSelected = true;
|
||||||
|
|
||||||
@@ -248,7 +248,7 @@ void ScreenSelectDifficulty::MenuRight( PlayerNumber pn )
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
bool AnotherPlayerSelected = false;
|
bool AnotherPlayerSelected = false;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( p != pn && m_bChosen[p] )
|
if( p != pn && m_bChosen[p] )
|
||||||
AnotherPlayerSelected = true;
|
AnotherPlayerSelected = true;
|
||||||
|
|
||||||
@@ -335,7 +335,7 @@ void ScreenSelectDifficulty::ChangePage( Page newPage )
|
|||||||
bool ScreenSelectDifficulty::ChangeWithinPage( PlayerNumber pn, int iNewChoice, bool bChangingPages )
|
bool ScreenSelectDifficulty::ChangeWithinPage( PlayerNumber pn, int iNewChoice, bool bChangingPages )
|
||||||
{
|
{
|
||||||
bool bAnyChanged = false;
|
bool bAnyChanged = false;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -536,7 +536,7 @@ void ScreenSelectDifficulty::TweenOffScreen()
|
|||||||
OFF_COMMAND( m_sprExplanation[page] );
|
OFF_COMMAND( m_sprExplanation[page] );
|
||||||
OFF_COMMAND( m_sprMore[page] );
|
OFF_COMMAND( m_sprMore[page] );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
@@ -189,7 +189,7 @@ int ScreenSelectDifficultyEX::GetSelectionIndex( PlayerNumber pn )
|
|||||||
|
|
||||||
void ScreenSelectDifficultyEX::UpdateSelectableChoices()
|
void ScreenSelectDifficultyEX::UpdateSelectableChoices()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
/* XXX: If a player joins during the tween-in, this diffuse change
|
/* XXX: If a player joins during the tween-in, this diffuse change
|
||||||
* will be undone by the tween. Hmm. */
|
* will be undone by the tween. Hmm. */
|
||||||
@@ -243,7 +243,7 @@ bool ScreenSelectDifficultyEX::IsACourse( int mIndex )
|
|||||||
|
|
||||||
void ScreenSelectDifficultyEX::SetAllPlayersSelection( int iChoice, bool bSwitchingModes )
|
void ScreenSelectDifficultyEX::SetAllPlayersSelection( int iChoice, bool bSwitchingModes )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_iChoice[p] = iChoice;
|
m_iChoice[p] = iChoice;
|
||||||
if( bSwitchingModes && ANIMATE_MODE_SWITCH )
|
if( bSwitchingModes && ANIMATE_MODE_SWITCH )
|
||||||
@@ -279,7 +279,7 @@ void ScreenSelectDifficultyEX::SetAllPlayersSelection( int iChoice, bool bSwitch
|
|||||||
|
|
||||||
void ScreenSelectDifficultyEX::Change( PlayerNumber pn, int iNewChoice )
|
void ScreenSelectDifficultyEX::Change( PlayerNumber pn, int iNewChoice )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsPlayerEnabled(p) ) { continue; }
|
if( !GAMESTATE->IsPlayerEnabled(p) ) { continue; }
|
||||||
if( p!=pn && m_CurrentPage==PAGE_1 ) { continue; }
|
if( p!=pn && m_CurrentPage==PAGE_1 ) { continue; }
|
||||||
@@ -454,7 +454,7 @@ void ScreenSelectDifficultyEX::TweenOnScreen()
|
|||||||
|
|
||||||
void ScreenSelectDifficultyEX::TweenOffScreen()
|
void ScreenSelectDifficultyEX::TweenOffScreen()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsPlayerEnabled((PlayerNumber)p) ) { continue; }
|
if( !GAMESTATE->IsPlayerEnabled((PlayerNumber)p) ) { continue; }
|
||||||
|
|
||||||
|
|||||||
@@ -290,7 +290,7 @@ void ScreenSelectMaster::HandleScreenMessage( const ScreenMessage SM )
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
for( int i=0; i<NUM_CURSOR_PARTS; i++ )
|
for( int i=0; i<NUM_CURSOR_PARTS; i++ )
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
{
|
{
|
||||||
m_sprCursor[i][p].SetXY( GetCursorX((PlayerNumber)p,i), GetCursorY((PlayerNumber)p,i) );
|
m_sprCursor[i][p].SetXY( GetCursorX((PlayerNumber)p,i), GetCursorY((PlayerNumber)p,i) );
|
||||||
@@ -306,7 +306,7 @@ void ScreenSelectMaster::HandleScreenMessage( const ScreenMessage SM )
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
for( int i=0; i<NUM_PREVIEW_PARTS; i++ )
|
for( int i=0; i<NUM_PREVIEW_PARTS; i++ )
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
COMMAND( m_sprPreview[i][m_iChoice[p]][p], "PostSwitchPage" );
|
COMMAND( m_sprPreview[i][m_iChoice[p]][p], "PostSwitchPage" );
|
||||||
}
|
}
|
||||||
@@ -340,7 +340,7 @@ void ScreenSelectMaster::UpdateSelectableChoices()
|
|||||||
for( int i=0; i<NUM_ICON_PARTS; i++ )
|
for( int i=0; i<NUM_ICON_PARTS; i++ )
|
||||||
COMMAND( m_sprIcon[i][c], m_aModeChoices[c].IsPlayable()? "Enabled":"Disabled" );
|
COMMAND( m_sprIcon[i][c], m_aModeChoices[c].IsPlayable()? "Enabled":"Disabled" );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue;
|
continue;
|
||||||
@@ -419,7 +419,7 @@ bool ScreenSelectMaster::ChangePage( int iNewChoice )
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
for( int i=0; i<NUM_CURSOR_PARTS; i++ )
|
for( int i=0; i<NUM_CURSOR_PARTS; i++ )
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
COMMAND( m_sprCursor[i][p], "PreSwitchPage" );
|
COMMAND( m_sprCursor[i][p], "PreSwitchPage" );
|
||||||
}
|
}
|
||||||
@@ -438,7 +438,7 @@ bool ScreenSelectMaster::ChangePage( int iNewChoice )
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
for( int i=0; i<NUM_PREVIEW_PARTS; i++ )
|
for( int i=0; i<NUM_PREVIEW_PARTS; i++ )
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
COMMAND( m_sprPreview[i][m_iChoice[p]][p], "PreSwitchPage" );
|
COMMAND( m_sprPreview[i][m_iChoice[p]][p], "PreSwitchPage" );
|
||||||
}
|
}
|
||||||
@@ -480,7 +480,7 @@ bool ScreenSelectMaster::ChangeSelection( PlayerNumber pn, int iNewChoice )
|
|||||||
|
|
||||||
bool bMoveAll = SHARED_PREVIEW_AND_CURSOR || GetCurrentPage()!=PAGE_1;
|
bool bMoveAll = SHARED_PREVIEW_AND_CURSOR || GetCurrentPage()!=PAGE_1;
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
const int iOldChoice = m_iChoice[p];
|
const int iOldChoice = m_iChoice[p];
|
||||||
|
|
||||||
@@ -609,7 +609,7 @@ void ScreenSelectMaster::MenuStart( PlayerNumber pn )
|
|||||||
if( SHARED_PREVIEW_AND_CURSOR || GetCurrentPage() == PAGE_2 )
|
if( SHARED_PREVIEW_AND_CURSOR || GetCurrentPage() == PAGE_2 )
|
||||||
{
|
{
|
||||||
/* Only one player has to pick. Choose this for all the other players, too. */
|
/* Only one player has to pick. Choose this for all the other players, too. */
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
{
|
{
|
||||||
ASSERT( !m_bChosen[p] );
|
ASSERT( !m_bChosen[p] );
|
||||||
@@ -620,7 +620,7 @@ void ScreenSelectMaster::MenuStart( PlayerNumber pn )
|
|||||||
{
|
{
|
||||||
fSecs = max( fSecs, DoMenuStart(pn) );
|
fSecs = max( fSecs, DoMenuStart(pn) );
|
||||||
// check to see if everyone has chosen
|
// check to see if everyone has chosen
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer((PlayerNumber)p) )
|
if( GAMESTATE->IsHumanPlayer((PlayerNumber)p) )
|
||||||
bAllDone &= m_bChosen[p];
|
bAllDone &= m_bChosen[p];
|
||||||
}
|
}
|
||||||
@@ -664,7 +664,7 @@ void ScreenSelectMaster::TweenOnScreen()
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
for( int i=0; i<NUM_PREVIEW_PARTS; i++ )
|
for( int i=0; i<NUM_PREVIEW_PARTS; i++ )
|
||||||
{
|
{
|
||||||
@@ -687,7 +687,7 @@ void ScreenSelectMaster::TweenOnScreen()
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
for( int i=0; i<NUM_CURSOR_PARTS; i++ )
|
for( int i=0; i<NUM_CURSOR_PARTS; i++ )
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
{
|
{
|
||||||
m_sprCursor[i][p].SetXY( GetCursorX((PlayerNumber)p,i), GetCursorY((PlayerNumber)p,i) );
|
m_sprCursor[i][p].SetXY( GetCursorX((PlayerNumber)p,i), GetCursorY((PlayerNumber)p,i) );
|
||||||
@@ -705,7 +705,7 @@ void ScreenSelectMaster::TweenOnScreen()
|
|||||||
COMMAND( *m_sprScroll[c][0], int(c) == m_iChoice[0]? "GainFocus":"LoseFocus" );
|
COMMAND( *m_sprScroll[c][0], int(c) == m_iChoice[0]? "GainFocus":"LoseFocus" );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
{
|
{
|
||||||
m_Scroller[p].SetCurrentAndDestinationItem( m_iChoice[p] );
|
m_Scroller[p].SetCurrentAndDestinationItem( m_iChoice[p] );
|
||||||
@@ -731,7 +731,7 @@ void ScreenSelectMaster::TweenOffScreen()
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
for( int i=0; i<NUM_CURSOR_PARTS; i++ )
|
for( int i=0; i<NUM_CURSOR_PARTS; i++ )
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
OFF_COMMAND( m_sprCursor[i][p] );
|
OFF_COMMAND( m_sprCursor[i][p] );
|
||||||
}
|
}
|
||||||
@@ -748,7 +748,7 @@ void ScreenSelectMaster::TweenOffScreen()
|
|||||||
SelectedByEitherPlayer = true;
|
SelectedByEitherPlayer = true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) && m_iChoice[p] == (int)c )
|
if( GAMESTATE->IsPlayerEnabled(p) && m_iChoice[p] == (int)c )
|
||||||
SelectedByEitherPlayer = true;
|
SelectedByEitherPlayer = true;
|
||||||
|
|
||||||
@@ -770,7 +770,7 @@ void ScreenSelectMaster::TweenOffScreen()
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
for( int i=0; i<NUM_PREVIEW_PARTS; i++ )
|
for( int i=0; i<NUM_PREVIEW_PARTS; i++ )
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) )
|
if( GAMESTATE->IsPlayerEnabled(p) )
|
||||||
{
|
{
|
||||||
OFF_COMMAND( m_sprPreview[i][c][p] );
|
OFF_COMMAND( m_sprPreview[i][c][p] );
|
||||||
@@ -784,7 +784,7 @@ void ScreenSelectMaster::TweenOffScreen()
|
|||||||
if( SHARED_PREVIEW_AND_CURSOR )
|
if( SHARED_PREVIEW_AND_CURSOR )
|
||||||
OFF_COMMAND( m_Scroller[0] );
|
OFF_COMMAND( m_Scroller[0] );
|
||||||
else
|
else
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
OFF_COMMAND( m_Scroller[p] );
|
OFF_COMMAND( m_Scroller[p] );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -478,7 +478,7 @@ void ScreenSelectMusic::SkipSongPartTweens()
|
|||||||
if( SHOW_DIFFICULTY_LIST )
|
if( SHOW_DIFFICULTY_LIST )
|
||||||
m_DifficultyList.FinishTweening();
|
m_DifficultyList.FinishTweening();
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -537,7 +537,7 @@ void ScreenSelectMusic::TweenOnScreen()
|
|||||||
ON_COMMAND( m_MachineRank );
|
ON_COMMAND( m_MachineRank );
|
||||||
ON_COMMAND( m_Overlay );
|
ON_COMMAND( m_Overlay );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -594,7 +594,7 @@ void ScreenSelectMusic::TweenOffScreen()
|
|||||||
OFF_COMMAND( m_MachineRank );
|
OFF_COMMAND( m_MachineRank );
|
||||||
OFF_COMMAND( m_Overlay );
|
OFF_COMMAND( m_Overlay );
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -647,7 +647,7 @@ void ScreenSelectMusic::SwitchDisplayMode( DisplayMode dm )
|
|||||||
|
|
||||||
void ScreenSelectMusic::TweenScoreOnAndOffAfterChangeSort()
|
void ScreenSelectMusic::TweenScoreOnAndOffAfterChangeSort()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -1068,7 +1068,7 @@ void ScreenSelectMusic::MenuStart( PlayerNumber pn )
|
|||||||
case TYPE_SONG: {
|
case TYPE_SONG: {
|
||||||
const bool bIsNew = PROFILEMAN->IsSongNew( m_MusicWheel.GetSelectedSong() );
|
const bool bIsNew = PROFILEMAN->IsSongNew( m_MusicWheel.GetSelectedSong() );
|
||||||
bool bIsHard = false;
|
bool bIsHard = false;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer( (PlayerNumber)p ) )
|
if( !GAMESTATE->IsHumanPlayer( (PlayerNumber)p ) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
@@ -1231,7 +1231,7 @@ void ScreenSelectMusic::AfterNotesChange( PlayerNumber pn )
|
|||||||
|
|
||||||
void ScreenSelectMusic::SwitchToPreferredDifficulty()
|
void ScreenSelectMusic::SwitchToPreferredDifficulty()
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer( PlayerNumber(p) ) )
|
if( !GAMESTATE->IsHumanPlayer( PlayerNumber(p) ) )
|
||||||
continue;
|
continue;
|
||||||
@@ -1318,7 +1318,7 @@ void ScreenSelectMusic::AfterMusicChange()
|
|||||||
case TYPE_SORT:
|
case TYPE_SORT:
|
||||||
{
|
{
|
||||||
CString sGroup = m_MusicWheel.GetSelectedSection();
|
CString sGroup = m_MusicWheel.GetSelectedSection();
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
m_iSelection[p] = -1;
|
m_iSelection[p] = -1;
|
||||||
|
|
||||||
m_BPMDisplay.NoBPM();
|
m_BPMDisplay.NoBPM();
|
||||||
@@ -1573,7 +1573,7 @@ void ScreenSelectMusic::UpdateOptionsDisplays()
|
|||||||
|
|
||||||
// m_PlayerOptionIcons.Refresh();
|
// m_PlayerOptionIcons.Refresh();
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -349,7 +349,7 @@ void ScreenTitleMenu::HandleScreenMessage( const ScreenMessage SM )
|
|||||||
if( m_Choice == 0 )
|
if( m_Choice == 0 )
|
||||||
{
|
{
|
||||||
// apply default options
|
// apply default options
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
GAMESTATE->m_PlayerOptions[p].FromString( PREFSMAN->m_sDefaultModifiers );
|
GAMESTATE->m_PlayerOptions[p].FromString( PREFSMAN->m_sDefaultModifiers );
|
||||||
GAMESTATE->m_SongOptions.FromString( PREFSMAN->m_sDefaultModifiers );
|
GAMESTATE->m_SongOptions.FromString( PREFSMAN->m_sDefaultModifiers );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -60,7 +60,7 @@ ScreenWithMenuElements::ScreenWithMenuElements( CString sClassName ) : Screen( s
|
|||||||
|
|
||||||
if( MEMORY_CARD_ICONS )
|
if( MEMORY_CARD_ICONS )
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
m_MemoryCardDisplay[p].Load( (PlayerNumber)p );
|
m_MemoryCardDisplay[p].Load( (PlayerNumber)p );
|
||||||
m_MemoryCardDisplay[p].SetName( ssprintf("MemoryCardDisplayP%d",p+1) );
|
m_MemoryCardDisplay[p].SetName( ssprintf("MemoryCardDisplayP%d",p+1) );
|
||||||
@@ -139,7 +139,7 @@ void ScreenWithMenuElements::StartTransitioning( ScreenMessage smSendWhenDone )
|
|||||||
|
|
||||||
UtilOffCommand( m_autoHeader, m_sName );
|
UtilOffCommand( m_autoHeader, m_sName );
|
||||||
UtilOffCommand( m_sprStyleIcon, m_sName );
|
UtilOffCommand( m_sprStyleIcon, m_sName );
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
UtilOffCommand( m_MemoryCardDisplay[p], m_sName );
|
UtilOffCommand( m_MemoryCardDisplay[p], m_sName );
|
||||||
UtilOffCommand( m_autoFooter, m_sName );
|
UtilOffCommand( m_autoFooter, m_sName );
|
||||||
UtilOffCommand( m_textHelp, m_sName );
|
UtilOffCommand( m_textHelp, m_sName );
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ SongCreditDisplay::SongCreditDisplay()
|
|||||||
|
|
||||||
// use a vector and not a set so that ordering is maintained
|
// use a vector and not a set so that ordering is maintained
|
||||||
vector<Steps*> vpStepsToShow;
|
vector<Steps*> vpStepsToShow;
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ StageStats::StageStats()
|
|||||||
StageType = STAGE_INVALID;
|
StageType = STAGE_INVALID;
|
||||||
fGameplaySeconds = 0;
|
fGameplaySeconds = 0;
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
pSteps[p] = NULL;
|
pSteps[p] = NULL;
|
||||||
iMeter[p] = 0;
|
iMeter[p] = 0;
|
||||||
@@ -64,7 +64,7 @@ void StageStats::AddStats( const StageStats& other )
|
|||||||
|
|
||||||
fGameplaySeconds += other.fGameplaySeconds;
|
fGameplaySeconds += other.fGameplaySeconds;
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
pSteps[p] = NULL;
|
pSteps[p] = NULL;
|
||||||
iMeter[p] += other.iMeter[p] * iLengthMultiplier;
|
iMeter[p] += other.iMeter[p] * iLengthMultiplier;
|
||||||
@@ -224,7 +224,7 @@ Grade StageStats::GetGrade( PlayerNumber pn ) const
|
|||||||
|
|
||||||
bool StageStats::OnePassed() const
|
bool StageStats::OnePassed() const
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) && !bFailed[p] )
|
if( GAMESTATE->IsHumanPlayer(p) && !bFailed[p] )
|
||||||
return true;
|
return true;
|
||||||
return false;
|
return false;
|
||||||
@@ -232,7 +232,7 @@ bool StageStats::OnePassed() const
|
|||||||
|
|
||||||
bool StageStats::AllFailed() const
|
bool StageStats::AllFailed() const
|
||||||
{
|
{
|
||||||
for( int pn=0; pn<NUM_PLAYERS; pn++ )
|
FOREACH_PlayerNumber( pn )
|
||||||
if( GAMESTATE->IsPlayerEnabled(PlayerNumber(pn)) )
|
if( GAMESTATE->IsPlayerEnabled(PlayerNumber(pn)) )
|
||||||
if( !bFailed[pn] )
|
if( !bFailed[pn] )
|
||||||
return false;
|
return false;
|
||||||
@@ -241,7 +241,7 @@ bool StageStats::AllFailed() const
|
|||||||
|
|
||||||
bool StageStats::AllFailedEarlier() const
|
bool StageStats::AllFailedEarlier() const
|
||||||
{
|
{
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsPlayerEnabled(p) && !bFailedEarlier[p] )
|
if( GAMESTATE->IsPlayerEnabled(p) && !bFailedEarlier[p] )
|
||||||
return false;
|
return false;
|
||||||
return true;
|
return true;
|
||||||
@@ -525,7 +525,7 @@ Grade GetBestFinalGrade()
|
|||||||
vector<Song*> vSongs;
|
vector<Song*> vSongs;
|
||||||
StageStats stats;
|
StageStats stats;
|
||||||
GAMESTATE->GetFinalEvalStatsAndSongs( stats, vSongs );
|
GAMESTATE->GetFinalEvalStatsAndSongs( stats, vSongs );
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( GAMESTATE->IsHumanPlayer(p) )
|
if( GAMESTATE->IsHumanPlayer(p) )
|
||||||
top_grade = min( top_grade, stats.GetGrade((PlayerNumber)p) );
|
top_grade = min( top_grade, stats.GetGrade((PlayerNumber)p) );
|
||||||
return top_grade;
|
return top_grade;
|
||||||
|
|||||||
@@ -201,7 +201,7 @@ void ResetGame( bool ReturnToFirstScreen )
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
GameState::Reset() will switch the NoteSkin
|
GameState::Reset() will switch the NoteSkin
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
PlayerNumber pn = (PlayerNumber)p;
|
PlayerNumber pn = (PlayerNumber)p;
|
||||||
if( !NOTESKIN->DoesNoteSkinExist( NOTESKIN->GetCurNoteSkinName(pn) ) )
|
if( !NOTESKIN->DoesNoteSkinExist( NOTESKIN->GetCurNoteSkinName(pn) ) )
|
||||||
@@ -1300,7 +1300,7 @@ bool HandleGlobalInputs( DeviceInput DeviceI, InputEventType type, GameInput Gam
|
|||||||
// so we don't have to play through a whole song to get new output.
|
// so we don't have to play through a whole song to get new output.
|
||||||
BOOKKEEPER->WriteToDisk();
|
BOOKKEEPER->WriteToDisk();
|
||||||
PROFILEMAN->SaveMachineProfile();
|
PROFILEMAN->SaveMachineProfile();
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
if( PROFILEMAN->IsUsingProfile((PlayerNumber)p) )
|
if( PROFILEMAN->IsUsingProfile((PlayerNumber)p) )
|
||||||
PROFILEMAN->SaveProfile( (PlayerNumber)p );
|
PROFILEMAN->SaveProfile( (PlayerNumber)p );
|
||||||
SCREENMAN->SystemMessage( "Stats saved" );
|
SCREENMAN->SystemMessage( "Stats saved" );
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ StyleInput StyleDef::GameInputToStyleInput( const GameInput &GameI ) const
|
|||||||
{
|
{
|
||||||
StyleInput SI;
|
StyleInput SI;
|
||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
FOREACH_PlayerNumber( p )
|
||||||
{
|
{
|
||||||
for( int t=0; t<m_iColsPerPlayer; t++ )
|
for( int t=0; t<m_iColsPerPlayer; t++ )
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user