Remove 700 usages of Component.Owner (#21100)

This commit is contained in:
DrSmugleaf
2023-10-20 15:31:13 +02:00
committed by Debug
parent 1561629bc2
commit 9cc8a7fc81
261 changed files with 2291 additions and 2036 deletions
@@ -1,9 +1,7 @@
using System.Linq;
using Content.Client.Actions;
using Content.Client.Items;
using Content.Client.Message;
using Content.Client.Stylesheets;
using Content.Shared.Actions;
using Content.Shared.DeviceNetwork.Components;
using Content.Shared.DeviceNetwork.Systems;
using Content.Shared.Input;
@@ -94,9 +92,10 @@ public sealed class NetworkConfiguratorSystem : SharedNetworkConfiguratorSystem
return;
}
foreach (var tracker in EntityQuery<NetworkConfiguratorActiveLinkOverlayComponent>())
var query = EntityQueryEnumerator<NetworkConfiguratorActiveLinkOverlayComponent>();
while (query.MoveNext(out var uid, out _))
{
RemCompDeferred<NetworkConfiguratorActiveLinkOverlayComponent>(tracker.Owner);
RemCompDeferred<NetworkConfiguratorActiveLinkOverlayComponent>(uid);
}
_actions.RemoveAction(overlay.Action);