removes componentdependencies (#6160)
This commit is contained in:
@@ -6,6 +6,7 @@ using Content.Shared.Interaction;
|
||||
using Content.Shared.Item;
|
||||
using Content.Shared.Smoking;
|
||||
using Content.Shared.Temperature;
|
||||
using Robust.Server.GameObjects;
|
||||
using Robust.Shared.Audio;
|
||||
using Robust.Shared.GameObjects;
|
||||
using Robust.Shared.IoC;
|
||||
@@ -85,9 +86,9 @@ namespace Content.Server.Light.EntitySystems
|
||||
{
|
||||
component.CurrentState = value;
|
||||
|
||||
if (component.PointLightComponent != null)
|
||||
if (TryComp<PointLightComponent>(component.Owner, out var pointLightComponent))
|
||||
{
|
||||
component.PointLightComponent.Enabled = component.CurrentState == SmokableState.Lit;
|
||||
pointLightComponent.Enabled = component.CurrentState == SmokableState.Lit;
|
||||
}
|
||||
|
||||
if (EntityManager.TryGetComponent(component.Owner, out SharedItemComponent? item))
|
||||
|
||||
Reference in New Issue
Block a user