From: Leon Friedrich <60421075+ElectroJr@users.noreply.github.com> Date: Sat, 1 Nov 2025 23:34:19 +0000 (+1300) Subject: Fix note heisentest (#41244) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=6f253bcf04341bd1fdef5b22d964c7ae48053750;p=space-station-14.git Fix note heisentest (#41244) --- diff --git a/Content.IntegrationTests/Tests/Interaction/InteractionTest.cs b/Content.IntegrationTests/Tests/Interaction/InteractionTest.cs index 746717e785..245aeab9ee 100644 --- a/Content.IntegrationTests/Tests/Interaction/InteractionTest.cs +++ b/Content.IntegrationTests/Tests/Interaction/InteractionTest.cs @@ -228,14 +228,14 @@ public abstract partial class InteractionTest ServerSession = sPlayerMan.GetSessionById(ClientSession.UserId); // Spawn player entity & attach - EntityUid? old = default; + NetEntity? old = default; await Server.WaitPost(() => { // Fuck you mind system I want an hour of my life back // Mind system is a time vampire SEntMan.System().WipeMind(ServerSession.ContentData()?.Mind); - old = cPlayerMan.LocalEntity; + CEntMan.TryGetNetEntity(cPlayerMan.LocalEntity, out old); SPlayer = SEntMan.SpawnEntity(PlayerPrototype, SEntMan.GetCoordinates(PlayerCoords)); Player = SEntMan.GetNetEntity(SPlayer); Server.PlayerMan.SetAttachedEntity(ServerSession, SPlayer); @@ -251,8 +251,8 @@ public abstract partial class InteractionTest // Delete old player entity. await Server.WaitPost(() => { - if (old != null) - SEntMan.DeleteEntity(old.Value); + if (SEntMan.TryGetEntity(old, out var uid)) + SEntMan.DeleteEntity(uid); }); // Change UI state to in-game.