Skip to content

Commit c14b5ae

Browse files
authored
[GEN][ZH] Fix beacon mouse cursor not showing while nothing is selected (#1185)
1 parent c504d4d commit c14b5ae

File tree

2 files changed

+14
-2
lines changed

2 files changed

+14
-2
lines changed

Generals/Code/GameEngine/Source/GameClient/MessageStream/CommandXlat.cpp

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1392,7 +1392,13 @@ GameMessage::Type CommandTranslator::evaluateContextCommand( Drawable *draw,
13921392

13931393
// Kris: Now that we can select non-controllable units/structures, don't allow any actions to be performed.
13941394
const CommandButton *command = TheInGameUI->getGUICommand();
1395-
if( TheInGameUI->areSelectedObjectsControllable()
1395+
1396+
if (command && command->getCommandType() == GUICOMMANDMODE_PLACE_BEACON)
1397+
{
1398+
msgType = GameMessage::MSG_VALID_GUICOMMAND_HINT;
1399+
TheMessageStream->appendMessage(msgType);
1400+
}
1401+
else if( TheInGameUI->areSelectedObjectsControllable()
13961402
|| (command && command->getCommandType() == GUI_COMMAND_SPECIAL_POWER_FROM_COMMAND_CENTER))
13971403
{
13981404
GameMessage *hintMessage;

GeneralsMD/Code/GameEngine/Source/GameClient/MessageStream/CommandXlat.cpp

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1474,7 +1474,13 @@ GameMessage::Type CommandTranslator::evaluateContextCommand( Drawable *draw,
14741474

14751475
// Kris: Now that we can select non-controllable units/structures, don't allow any actions to be performed.
14761476
const CommandButton *command = TheInGameUI->getGUICommand();
1477-
if( TheInGameUI->areSelectedObjectsControllable()
1477+
1478+
if (command && command->getCommandType() == GUICOMMANDMODE_PLACE_BEACON)
1479+
{
1480+
msgType = GameMessage::MSG_VALID_GUICOMMAND_HINT;
1481+
TheMessageStream->appendMessage(msgType);
1482+
}
1483+
else if( TheInGameUI->areSelectedObjectsControllable()
14781484
|| (command && command->getCommandType() == GUI_COMMAND_SPECIAL_POWER_FROM_SHORTCUT))
14791485
{
14801486
GameMessage *hintMessage;

0 commit comments

Comments
 (0)