fix: cryo pod autoinjection works once again. (#13213)

This commit is contained in:
Francesco
2022-12-30 15:34:59 +01:00
committed by GitHub
parent ae58bb1f1b
commit 21cc60bcb9

View File

@@ -89,10 +89,7 @@ public sealed partial class CryoPodSystem: SharedCryoPodSystem
continue;
cryoPod.NextInjectionTime = curTime + TimeSpan.FromSeconds(cryoPod.BeakerTransferTime);
if (
!itemSlotsQuery.TryGetComponent(cryoPod.Owner, out var itemSlotsComponent)
|| !fitsInDispenserQuery.TryGetComponent(cryoPod.Owner, out var fitsInDispenserComponent)
|| !solutionContainerManagerQuery.TryGetComponent(cryoPod.Owner, out var solutionContainerManagerComponent))
if (!itemSlotsQuery.TryGetComponent(cryoPod.Owner, out var itemSlotsComponent))
{
continue;
}
@@ -101,6 +98,9 @@ public sealed partial class CryoPodSystem: SharedCryoPodSystem
if (container != null
&& container.Value.Valid
&& patient != null
&& fitsInDispenserQuery.TryGetComponent(container, out var fitsInDispenserComponent)
&& solutionContainerManagerQuery.TryGetComponent(container,
out var solutionContainerManagerComponent)
&& _solutionContainerSystem.TryGetFitsInDispenser(container.Value, out var containerSolution, dispenserFits: fitsInDispenserComponent, solutionManager: solutionContainerManagerComponent))
{
if (!bloodStreamQuery.TryGetComponent(patient, out var bloodstream))