File tree Expand file tree Collapse file tree 2 files changed +16
-4
lines changed
GeneralsMD/Code/GameEngine/Source/GameClient/MessageStream
Generals/Code/GameEngine/Source/GameClient/MessageStream Expand file tree Collapse file tree 2 files changed +16
-4
lines changed Original file line number Diff line number Diff line change @@ -1024,10 +1024,13 @@ GameMessageDisposition SelectionTranslator::translateGameMessage(const GameMessa
10241024 m_lastGroupSelTime = now;
10251025 }
10261026
1027+ Bool performSelection = TRUE ;
1028+
10271029 // check for double-press to jump view
10281030 if ( now - m_lastGroupSelTime < 20 && group == m_lastGroupSelGroup )
10291031 {
10301032 DEBUG_LOG ((" META: DOUBLETAP select team %d" ,group));
1033+ performSelection = FALSE ;
10311034 Player *player = ThePlayerList->getLocalPlayer ();
10321035 if (player)
10331036 {
@@ -1039,12 +1042,15 @@ GameMessageDisposition SelectionTranslator::translateGameMessage(const GameMessa
10391042 if (numObjs > 0 )
10401043 {
10411044 // if theres someone in the group, center the camera on them.
1042- TheTacticalView->lookAt ( objlist[numObjs-1 ]->getDrawable ()->getPosition () );
1045+ Drawable* drawable = objlist[numObjs - 1 ]->getDrawable ();
1046+ TheTacticalView->lookAt ( drawable->getPosition () );
1047+ performSelection = !TheInGameUI->isDrawableSelected ( drawable->getID () );
10431048 }
10441049 }
10451050 }
10461051 }
1047- else
1052+
1053+ if ( performSelection )
10481054 {
10491055 TheInGameUI->deselectAllDrawables ( false ); // No need to post message because we're just creating a new group!
10501056
Original file line number Diff line number Diff line change @@ -1099,10 +1099,13 @@ GameMessageDisposition SelectionTranslator::translateGameMessage(const GameMessa
10991099 m_lastGroupSelTime = now;
11001100 }
11011101
1102+ Bool performSelection = TRUE ;
1103+
11021104 // check for double-press to jump view
11031105 if ( now - m_lastGroupSelTime < 20 && group == m_lastGroupSelGroup )
11041106 {
11051107 DEBUG_LOG ((" META: DOUBLETAP select team %d" ,group));
1108+ performSelection = FALSE ;
11061109 Player *player = ThePlayerList->getLocalPlayer ();
11071110 if (player)
11081111 {
@@ -1114,12 +1117,15 @@ GameMessageDisposition SelectionTranslator::translateGameMessage(const GameMessa
11141117 if (numObjs > 0 )
11151118 {
11161119 // if theres someone in the group, center the camera on them.
1117- TheTacticalView->lookAt ( objlist[numObjs-1 ]->getDrawable ()->getPosition () );
1120+ Drawable* drawable = objlist[numObjs - 1 ]->getDrawable ();
1121+ TheTacticalView->lookAt ( drawable->getPosition () );
1122+ performSelection = !TheInGameUI->isDrawableSelected ( drawable->getID () );
11181123 }
11191124 }
11201125 }
11211126 }
1122- else
1127+
1128+ if ( performSelection )
11231129 {
11241130 TheInGameUI->deselectAllDrawables ( false ); // No need to post message because we're just creating a new group!
11251131
You can’t perform that action at this time.
0 commit comments