]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Fix SpawnAndDeleteAllEntitiesInTheSameSpot heisentest (#32330)
authorslarticodefast <161409025+slarticodefast@users.noreply.github.com>
Sat, 12 Oct 2024 18:54:48 +0000 (20:54 +0200)
committerGitHub <noreply@github.com>
Sat, 12 Oct 2024 18:54:48 +0000 (11:54 -0700)
What happened was that the new tech anomaly randomly triggered a signal sink on the portable generator, which is currently broken and throws an error if the that sink is activated.

The resolve needed logMissing = false because it does not expect the ActiveGeneratorRevvingComponent to exist.

Content.Shared/Power/Generator/ActiveGeneratorRevvingComponent.cs
Content.Shared/Power/Generator/ActiveGeneratorRevvingSystem.cs

index 25f97dc15a0e73aaa9232dc4dab0f3f94eceb585..fde0319a37d6cdd5dfc964d5644dc0f7c88edb8f 100644 (file)
@@ -3,7 +3,7 @@ using Robust.Shared.GameStates;
 namespace Content.Shared.Power.Generator;
 
 [RegisterComponent, NetworkedComponent, AutoGenerateComponentState]
-public sealed partial class ActiveGeneratorRevvingComponent: Component
+public sealed partial class ActiveGeneratorRevvingComponent : Component
 {
     [DataField, ViewVariables(VVAccess.ReadOnly), AutoNetworkedField]
     public TimeSpan CurrentTime = TimeSpan.Zero;
index 9cd11ae604535277462d1af9f6504a38adefb729..459b2fd78deef0e0ec3a1c0f88bca6a2d70bd07a 100644 (file)
@@ -1,6 +1,6 @@
 namespace Content.Shared.Power.Generator;
 
-public sealed class ActiveGeneratorRevvingSystem: EntitySystem
+public sealed class ActiveGeneratorRevvingSystem : EntitySystem
 {
     public override void Initialize()
     {
@@ -25,7 +25,7 @@ public sealed class ActiveGeneratorRevvingSystem: EntitySystem
     /// <param name="component">ActiveGeneratorRevvingComponent of the generator entity.</param>
     public void StartAutoRevving(EntityUid uid, ActiveGeneratorRevvingComponent? component = null)
     {
-        if (Resolve(uid, ref component))
+        if (Resolve(uid, ref component, false))
         {
             // reset the revving
             component.CurrentTime = TimeSpan.FromSeconds(0);