mirror of
https://github.com/WWhiteDreamProject/wwdpublic.git
synced 2026-04-17 13:37:47 +03:00
* Firestarter fixes - Actually networks the action. - Namespace fixes. * No networky for you (cherry picked from commit a6ea8b210db079d30823e7b4d8faa32aefa17582)
25 lines
754 B
C#
25 lines
754 B
C#
using Content.Shared.Actions;
|
|
using Content.Shared.Atmos.Components;
|
|
|
|
namespace Content.Shared.Atmos.EntitySystems;
|
|
|
|
public abstract class SharedFirestarterSystem : EntitySystem
|
|
{
|
|
[Dependency] private readonly SharedActionsSystem _actionsSystem = default!;
|
|
|
|
public override void Initialize()
|
|
{
|
|
base.Initialize();
|
|
SubscribeLocalEvent<FirestarterComponent, ComponentInit>(OnComponentInit);
|
|
}
|
|
|
|
/// <summary>
|
|
/// Adds the firestarter action.
|
|
/// </summary>
|
|
private void OnComponentInit(EntityUid uid, FirestarterComponent component, ComponentInit args)
|
|
{
|
|
_actionsSystem.AddAction(uid, ref component.FireStarterActionEntity, component.FireStarterAction, uid);
|
|
Dirty(uid, component);
|
|
}
|
|
}
|