Hide Abort Unit Order button when idle or guarding

Reviewed-By: bb
Fixes #6854
This commit is contained in:
abian
2025-10-18 09:32:10 +02:00
committed by Itms
parent 2c9928e4cb
commit 95467c2327
@@ -1550,7 +1550,8 @@ var g_EntityCommands =
"stop": {
"getInfo": function(entStates)
{
if (entStates.every(entState => !entState.unitAI))
// Don't show generic option to abort if not applicable or in case of guard, which has its own abort action
if (entStates.every(entState => !entState.unitAI || entState.unitAI.isIdle || entState.unitAI.isGuarding))
return false;
return {