diff --git a/Content.Server/Light/EntitySystems/HandheldLightSystem.cs b/Content.Server/Light/EntitySystems/HandheldLightSystem.cs index ab3a64a5f07274..ff3c61bc6110cb 100644 --- a/Content.Server/Light/EntitySystems/HandheldLightSystem.cs +++ b/Content.Server/Light/EntitySystems/HandheldLightSystem.cs @@ -99,11 +99,13 @@ private void OnGetState(EntityUid uid, HandheldLightComponent component, ref Com private void OnMapInit(EntityUid uid, HandheldLightComponent component, MapInitEvent args) { _actionContainer.EnsureAction(uid, ref component.ToggleActionEntity, component.ToggleAction); + _actions.AddAction(uid, ref component.SelfToggleActionEntity, component.ToggleAction); } private void OnShutdown(EntityUid uid, HandheldLightComponent component, ComponentShutdown args) { _actions.RemoveAction(uid, component.ToggleActionEntity); + _actions.RemoveAction(uid, component.SelfToggleActionEntity); } private byte? GetLevel(EntityUid uid, HandheldLightComponent component) diff --git a/Content.Shared/Light/Components/HandheldLightComponent.cs b/Content.Shared/Light/Components/HandheldLightComponent.cs index 9e3cad7552ca3a..6c70a82f93a039 100644 --- a/Content.Shared/Light/Components/HandheldLightComponent.cs +++ b/Content.Shared/Light/Components/HandheldLightComponent.cs @@ -48,6 +48,9 @@ public sealed partial class HandheldLightComponent : Component [DataField("toggleActionEntity")] public EntityUid? ToggleActionEntity; + [DataField] + public EntityUid? SelfToggleActionEntity; + public const int StatusLevels = 6; ///