Try and fix mob prototypes (#19859)

Co-authored-by: DrSmugleaf <drsmugleaf@gmail.com>
This commit is contained in:
Nemanja
2023-09-14 23:10:30 -04:00
committed by GitHub
parent 372c67e160
commit c34913b227
29 changed files with 561 additions and 630 deletions

View File

@@ -1,21 +0,0 @@
using Content.Server.Clothing.Components;
using Content.Shared.Inventory;
namespace Content.Server.Temperature.Components
{
[RegisterComponent]
public sealed partial class HeatResistanceComponent : Component
{
public int GetHeatResistance()
{
// TODO: When making into system: Any animal that touches bulb that has no
// InventoryComponent but still would have default heat resistance in the future (maybe)
if (EntitySystem.Get<InventorySystem>().TryGetSlotEntity(Owner, "gloves", out var slotEntity) &&
IoCManager.Resolve<IEntityManager>().TryGetComponent<GloveHeatResistanceComponent>(slotEntity, out var gloves))
{
return gloves.HeatResistance;
}
return int.MinValue;
}
}
}