diff --git a/OpenRA.Mods.Common/Traits/Player/MissionObjectives.cs b/OpenRA.Mods.Common/Traits/Player/MissionObjectives.cs index e1c64d51ee..2b48951965 100644 --- a/OpenRA.Mods.Common/Traits/Player/MissionObjectives.cs +++ b/OpenRA.Mods.Common/Traits/Player/MissionObjectives.cs @@ -238,7 +238,10 @@ namespace OpenRA.Mods.Common.Traits public void ResolveOrder(Actor self, Order order) { if (order.OrderString == "Surrender") + { ForceDefeat(self.Owner); + self.Owner.Spectating = true; + } } } diff --git a/OpenRA.Mods.Common/Widgets/Logic/Ingame/LoadIngamePlayerOrObserverUILogic.cs b/OpenRA.Mods.Common/Widgets/Logic/Ingame/LoadIngamePlayerOrObserverUILogic.cs index 13f5568645..cd444e23d7 100644 --- a/OpenRA.Mods.Common/Widgets/Logic/Ingame/LoadIngamePlayerOrObserverUILogic.cs +++ b/OpenRA.Mods.Common/Widgets/Logic/Ingame/LoadIngamePlayerOrObserverUILogic.cs @@ -38,7 +38,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic if (world.LocalPlayer.WinState != WinState.Undefined) Game.RunAfterDelay(objectives != null ? objectives.Info.GameOverDelay : 0, () => { - world.LocalPlayer.Spectating = true; playerRoot.RemoveChildren(); Game.LoadWidget(world, "OBSERVER_WIDGETS", playerRoot, new WidgetArgs()); });