diff --git a/OpenRA.Mods.RA/SupportPowers/NukePower.cs b/OpenRA.Mods.RA/SupportPowers/NukePower.cs index 55182b85fa..4bc7c90c87 100755 --- a/OpenRA.Mods.RA/SupportPowers/NukePower.cs +++ b/OpenRA.Mods.RA/SupportPowers/NukePower.cs @@ -32,6 +32,9 @@ namespace OpenRA.Mods.RA [Desc("Descend immediately on the target, with half the FlightDelay")] public readonly bool SkipAscent = false; + [Desc("Amount of time before detonation to remove the beacon")] + public readonly int BeaconRemoveAdvance = 25; + [ActorReference] [Desc("Actor to spawn before detonation")] public readonly string CameraActor = null; @@ -93,6 +96,17 @@ namespace OpenRA.Mods.RA Action addCamera = () => self.World.AddFrameEndTask(w => w.Add(camera)); self.World.AddFrameEndTask(w => w.Add(new DelayedAction(npi.FlightDelay - npi.CameraSpawnAdvance, addCamera))); } + + if (beacon != null) + { + Action removeBeacon = () => self.World.AddFrameEndTask(w => + { + w.Remove(beacon); + beacon = null; + }); + + self.World.AddFrameEndTask(w => w.Add(new DelayedAction(npi.FlightDelay - npi.BeaconRemoveAdvance, removeBeacon))); + } } } } diff --git a/mods/cnc/rules/structures.yaml b/mods/cnc/rules/structures.yaml index f3b8d39f7c..a1f07b2c2b 100644 --- a/mods/cnc/rules/structures.yaml +++ b/mods/cnc/rules/structures.yaml @@ -498,6 +498,7 @@ TMPL: IncomingSound: nuke1.aud MissileWeapon: atomic DisplayBeacon: True + BeaconDuration: -1 BeaconPoster: atomic DisplayRadarPing: True CameraActor: camera diff --git a/mods/d2k/rules/harkonnen.yaml b/mods/d2k/rules/harkonnen.yaml index 0ccdcf70dd..2fc05e8d94 100644 --- a/mods/d2k/rules/harkonnen.yaml +++ b/mods/d2k/rules/harkonnen.yaml @@ -98,6 +98,7 @@ PALACEH: SpawnOffset: -512,1c171,0 DisplayBeacon: True DisplayRadarPing: True + BeaconDuration: -1 CameraActor: camera CanPowerDown: DisabledOverlay: diff --git a/mods/ra/rules/structures.yaml b/mods/ra/rules/structures.yaml index a2be332b8f..aead769339 100644 --- a/mods/ra/rules/structures.yaml +++ b/mods/ra/rules/structures.yaml @@ -38,6 +38,7 @@ MSLO: SpawnOffset: 0,427,0 DisplayTimer: True DisplayBeacon: True + BeaconDuration: -1 DisplayRadarPing: True BeaconPoster: atomicon CameraActor: camera