fix obscure selection glitch
This commit is contained in:
@@ -445,13 +445,17 @@ bool ScreenSelectMaster::ChangeSelection( PlayerNumber pn, int iNewChoice )
|
|||||||
|
|
||||||
for( int p=0; p<NUM_PLAYERS; p++ )
|
for( int p=0; p<NUM_PLAYERS; p++ )
|
||||||
{
|
{
|
||||||
|
/* Set the new m_iChoice even for disabled players, since a player might
|
||||||
|
* join on a SHARED_PREVIEW_AND_CURSOR after the cursor has been moved. */
|
||||||
|
const int iOldChoice = m_iChoice[p];
|
||||||
|
m_iChoice[p] = iNewChoice;
|
||||||
|
|
||||||
if( !GAMESTATE->IsHumanPlayer(p) )
|
if( !GAMESTATE->IsHumanPlayer(p) )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
|
|
||||||
if( !bMoveAll && p!=pn )
|
if( !bMoveAll && p!=pn )
|
||||||
continue; // skip
|
continue; // skip
|
||||||
|
|
||||||
const int iOldChoice = m_iChoice[p];
|
|
||||||
if( SHARED_PREVIEW_AND_CURSOR )
|
if( SHARED_PREVIEW_AND_CURSOR )
|
||||||
{
|
{
|
||||||
for( int i=0; i<NUM_PREVIEW_PARTS; i++ )
|
for( int i=0; i<NUM_PREVIEW_PARTS; i++ )
|
||||||
@@ -479,8 +483,6 @@ bool ScreenSelectMaster::ChangeSelection( PlayerNumber pn, int iNewChoice )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
m_iChoice[p] = iNewChoice;
|
|
||||||
|
|
||||||
if( SHARED_PREVIEW_AND_CURSOR )
|
if( SHARED_PREVIEW_AND_CURSOR )
|
||||||
{
|
{
|
||||||
for( int i=0; i<NUM_CURSOR_PARTS; i++ )
|
for( int i=0; i<NUM_CURSOR_PARTS; i++ )
|
||||||
|
|||||||
Reference in New Issue
Block a user