Files
tbd-station-14/Content.Server/Nutrition/EntitySystems/SmokingSystem.cs
Vera Aguilera Puerto 6cea9cb973 Refactor Flammable to be ECS. (#4671)
- Refactor IHotItem into IsHotEvent.
- Refactor IFireAct into TileFireEvent.
2021-09-22 11:05:33 +02:00

21 lines
582 B
C#

using Content.Server.Nutrition.Components;
using Content.Shared.Smoking;
using Content.Shared.Temperature;
using Robust.Shared.GameObjects;
namespace Content.Server.Nutrition.EntitySystems
{
public class SmokingSystem : EntitySystem
{
public override void Initialize()
{
SubscribeLocalEvent<SmokingComponent, IsHotEvent>(OnIsHotEvent);
}
private void OnIsHotEvent(EntityUid uid, SmokingComponent component, IsHotEvent args)
{
args.IsHot = component.CurrentState == SharedBurningStates.Lit;
}
}
}