From: slarticodefast <161409025+slarticodefast@users.noreply.github.com> Date: Sat, 12 Oct 2024 18:54:48 +0000 (+0200) Subject: Fix SpawnAndDeleteAllEntitiesInTheSameSpot heisentest (#32330) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=4704309b4e7673e18019cb06701f66beaba9b1a2;p=space-station-14.git Fix SpawnAndDeleteAllEntitiesInTheSameSpot heisentest (#32330) 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. --- diff --git a/Content.Shared/Power/Generator/ActiveGeneratorRevvingComponent.cs b/Content.Shared/Power/Generator/ActiveGeneratorRevvingComponent.cs index 25f97dc15a..fde0319a37 100644 --- a/Content.Shared/Power/Generator/ActiveGeneratorRevvingComponent.cs +++ b/Content.Shared/Power/Generator/ActiveGeneratorRevvingComponent.cs @@ -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; diff --git a/Content.Shared/Power/Generator/ActiveGeneratorRevvingSystem.cs b/Content.Shared/Power/Generator/ActiveGeneratorRevvingSystem.cs index 9cd11ae604..459b2fd78d 100644 --- a/Content.Shared/Power/Generator/ActiveGeneratorRevvingSystem.cs +++ b/Content.Shared/Power/Generator/ActiveGeneratorRevvingSystem.cs @@ -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 /// ActiveGeneratorRevvingComponent of the generator entity. 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);