]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Cleanup: Pass in ``IComponentFactory`` in ``EntityPrototype.TryGetComponent`` calls...
authorWinkarst <74284083+Winkarst-cpu@users.noreply.github.com>
Mon, 24 Feb 2025 17:57:39 +0000 (20:57 +0300)
committerGitHub <noreply@github.com>
Mon, 24 Feb 2025 17:57:39 +0000 (18:57 +0100)
Cleanup

Content.Server/StationEvents/Events/ImmovableRodRule.cs

index 17a92e1b3de36f850f1ce9a388c7a1d82aa61835..5e324a529b8c508ade9da6aa72d045b6e948499a 100644 (file)
@@ -26,7 +26,8 @@ public sealed class ImmovableRodRule : StationEventSystem<ImmovableRodRuleCompon
 
         var proto = _prototypeManager.Index<EntityPrototype>(protoName);
 
-        if (proto.TryGetComponent<ImmovableRodComponent>(out var rod) && proto.TryGetComponent<TimedDespawnComponent>(out var despawn))
+        if (proto.TryGetComponent<ImmovableRodComponent>(out var rod, EntityManager.ComponentFactory) &&
+            proto.TryGetComponent<TimedDespawnComponent>(out var despawn, EntityManager.ComponentFactory))
         {
             if (!TryFindRandomTile(out _, out _, out _, out var targetCoords))
                 return;