diff --git a/OpenRA.Mods.Common/Traits/Air/FallsToEarth.cs b/OpenRA.Mods.Common/Traits/Air/FallsToEarth.cs index c72aabb41d..401111b681 100644 --- a/OpenRA.Mods.Common/Traits/Air/FallsToEarth.cs +++ b/OpenRA.Mods.Common/Traits/Air/FallsToEarth.cs @@ -42,18 +42,24 @@ namespace OpenRA.Mods.Common.Traits } } - public class FallsToEarth : IEffectiveOwner + public class FallsToEarth : IEffectiveOwner, INotifyCreated { + readonly FallsToEarthInfo info; readonly Player effectiveOwner; public FallsToEarth(ActorInitializer init, FallsToEarthInfo info) { - init.Self.QueueActivity(false, new FallToEarth(init.Self, info)); + this.info = info; effectiveOwner = init.Contains() ? init.Get() : init.Self.Owner; } // We return init.Self.Owner if there's no effective owner bool IEffectiveOwner.Disguised { get { return true; } } Player IEffectiveOwner.Owner { get { return effectiveOwner; } } + + void INotifyCreated.Created(Actor self) + { + self.QueueActivity(false, new FallToEarth(self, info)); + } } }