ActionBlocker CanShiver uses EntityUid exclusively

This commit is contained in:
Vera Aguilera Puerto
2021-11-09 13:51:12 +01:00
parent a2a8a6303f
commit cc9ae191a8
3 changed files with 10 additions and 14 deletions

View File

@@ -289,19 +289,19 @@ namespace Content.Server.Body.Respiratory
// creadth: sweating does not help in airless environment
if (EntitySystem.Get<AtmosphereSystem>().GetTileMixture(Owner.Transform.Coordinates) is not {})
{
temperatureSystem.RemoveHeat(Owner.Uid, Math.Min(targetHeat, SweatHeatRegulation), temperatureComponent);
temperatureSystem.RemoveHeat(OwnerUid, Math.Min(targetHeat, SweatHeatRegulation), temperatureComponent);
}
}
else
{
if (!actionBlocker.CanShiver(Owner)) return;
if (!actionBlocker.CanShiver(OwnerUid)) return;
if (!_isShivering)
{
Owner.PopupMessage(Loc.GetString("metabolism-component-is-shivering"));
_isShivering = true;
}
temperatureSystem.ReceiveHeat(Owner.Uid, Math.Min(targetHeat, ShiveringHeatRegulation), temperatureComponent);
temperatureSystem.ReceiveHeat(OwnerUid, Math.Min(targetHeat, ShiveringHeatRegulation), temperatureComponent);
}
}