From d2ec8721db6e374210a8243eaac10d78c756b569 Mon Sep 17 00:00:00 2001 From: ElectroJr Date: Sun, 12 Jan 2025 22:13:25 +1300 Subject: [PATCH] I love #if blocks --- Robust.Client/GameStates/ClientGameStateManager.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Robust.Client/GameStates/ClientGameStateManager.cs b/Robust.Client/GameStates/ClientGameStateManager.cs index c64fd34c24f..38d0ab47b12 100644 --- a/Robust.Client/GameStates/ClientGameStateManager.cs +++ b/Robust.Client/GameStates/ClientGameStateManager.cs @@ -695,15 +695,15 @@ private void MergeImplicitData() foreach (var netEntity in _created) { -#if EXCEPTION_TOLERANCE - if (!_entityManager.TryGetEntityData(netEntity, out _, out var meta)) + if (!_entities.TryGetEntityData(netEntity, out _, out var meta)) { _sawmill.Error($"Encountered deleted entity while merging implicit data! NetEntity: {netEntity}"); + +#if !EXCEPTION_TOLERANCE + throw new KeyNotFoundException(); +#endif continue; } -#else - var (_, meta) = _entities.GetEntityData(netEntity); -#endif var compData = _compDataPool.Get(); _outputData.Add(netEntity, compData);