Fix lung test (#14325)

This commit is contained in:
Leon Friedrich
2023-03-01 15:57:48 +13:00
committed by GitHub
parent c173338471
commit e9fd16f8f6
2 changed files with 26 additions and 4 deletions

View File

@@ -97,7 +97,10 @@ public partial class AtmosphereSystem
// If we've been passed a grid, try to let it handle it.
if (gridUid.HasValue)
{
DebugTools.Assert(_mapManager.IsGrid(gridUid.Value));
RaiseLocalEvent(gridUid.Value, ref ev, false);
}
if (ev.Handled)
return ev.Mixtures;
@@ -105,7 +108,10 @@ public partial class AtmosphereSystem
// We either don't have a grid, or the event wasn't handled.
// Let the map handle it instead, and also broadcast the event.
if (mapUid.HasValue)
{
DebugTools.Assert(_mapManager.IsMap(mapUid.Value));
RaiseLocalEvent(mapUid.Value, ref ev, true);
}
else
RaiseLocalEvent(ref ev);
@@ -127,7 +133,10 @@ public partial class AtmosphereSystem
// If we've been passed a grid, try to let it handle it.
if(gridUid.HasValue)
{
DebugTools.Assert(_mapManager.IsGrid(gridUid.Value));
RaiseLocalEvent(gridUid.Value, ref ev, false);
}
if (ev.Handled)
return ev.Mixture;
@@ -135,7 +144,10 @@ public partial class AtmosphereSystem
// We either don't have a grid, or the event wasn't handled.
// Let the map handle it instead, and also broadcast the event.
if(mapUid.HasValue)
{
DebugTools.Assert(_mapManager.IsMap(mapUid.Value));
RaiseLocalEvent(mapUid.Value, ref ev, true);
}
else
RaiseLocalEvent(ref ev);