From 1e9f5199f82b13517bf02f7b358b4e0bd5ef05db Mon Sep 17 00:00:00 2001 From: Chris Forbes Date: Sat, 10 Apr 2010 14:15:04 +1200 Subject: [PATCH] don't cancel other players' input modes in IonCannon, Airstrike, etc --- OpenRA.Mods.Cnc/AirstrikePower.cs | 5 ++++- OpenRA.Mods.Cnc/IonCannonPower.cs | 4 +++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/OpenRA.Mods.Cnc/AirstrikePower.cs b/OpenRA.Mods.Cnc/AirstrikePower.cs index ef40d63181..bc5cfdae4a 100644 --- a/OpenRA.Mods.Cnc/AirstrikePower.cs +++ b/OpenRA.Mods.Cnc/AirstrikePower.cs @@ -47,6 +47,7 @@ namespace OpenRA.Mods.Cnc if (order.OrderString == "Airstrike") { var startPos = Owner.World.ChooseRandomEdgeCell(); + Owner.World.AddFrameEndTask(w => { var a = w.CreateActor("a10", startPos, Owner); @@ -60,7 +61,9 @@ namespace OpenRA.Mods.Cnc a.QueueActivity(new RemoveSelf()); }); - Game.controller.CancelInputMode(); + if (Owner == Owner.World.LocalPlayer) + Game.controller.CancelInputMode(); + FinishActivate(); } } diff --git a/OpenRA.Mods.Cnc/IonCannonPower.cs b/OpenRA.Mods.Cnc/IonCannonPower.cs index 8d3466854f..9cb198d6ab 100644 --- a/OpenRA.Mods.Cnc/IonCannonPower.cs +++ b/OpenRA.Mods.Cnc/IonCannonPower.cs @@ -45,7 +45,9 @@ namespace OpenRA.Mods.Cnc w.Add(new IonCannon(self, w, order.TargetLocation)); }); - Game.controller.CancelInputMode(); + if (Owner == Owner.World.LocalPlayer) + Game.controller.CancelInputMode(); + FinishActivate(); } }