Leather gloves and an LED tube light. (#187)
Added BurnTemperature to bulbs. Added HeatResistance to clothing and species. Added HeatResistanceComponent which resolves armor vs skin. Made the hand burn on lamps only happen when heat resistance is too poor.
This commit is contained in:
committed by
Pieter-Jan Briers
parent
9f1dd9f876
commit
77753debeb
@@ -0,0 +1,21 @@
|
||||
using System;
|
||||
using SS14.Shared.GameObjects;
|
||||
using Content.Shared.GameObjects.Components.Inventory;
|
||||
|
||||
namespace Content.Server.GameObjects
|
||||
{
|
||||
public class HeatResistanceComponent : Component
|
||||
{
|
||||
public override string Name => "HeatResistance";
|
||||
|
||||
public int GetHeatResistance()
|
||||
{
|
||||
if (Owner.GetComponent<InventoryComponent>().TryGetSlotItem(EquipmentSlotDefines.Slots.GLOVES, itemComponent: out ClothingComponent gloves)
|
||||
| Owner.TryGetComponent(out SpeciesComponent speciesComponent))
|
||||
{
|
||||
return Math.Max(gloves?.HeatResistance ?? int.MinValue, speciesComponent?.HeatResistance ?? int.MinValue);
|
||||
}
|
||||
return int.MinValue;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user