@@ -7,7 +7,6 @@ using Robust.Server.GameObjects;
|
||||
using Robust.Shared.GameObjects;
|
||||
using Robust.Shared.IoC;
|
||||
using Robust.Shared.Localization;
|
||||
using Robust.Shared.Physics;
|
||||
using Robust.Shared.Serialization;
|
||||
using Robust.Shared.Utility;
|
||||
using Robust.Shared.ViewVariables;
|
||||
@@ -22,7 +21,7 @@ namespace Content.Server.GameObjects.Components.Power.ApcNetComponents
|
||||
{
|
||||
[Dependency] private readonly IServerEntityManager _serverEntityManager = default!;
|
||||
|
||||
[ViewVariables] [ComponentDependency] private readonly IPhysBody? _physicsComponent = null;
|
||||
[ViewVariables] [ComponentDependency] private readonly IPhysicsComponent? _physicsComponent = null;
|
||||
|
||||
public override string Name => "PowerReceiver";
|
||||
|
||||
@@ -51,7 +50,7 @@ namespace Content.Server.GameObjects.Components.Power.ApcNetComponents
|
||||
/// </summary>
|
||||
public bool Connectable => Anchored;
|
||||
|
||||
private bool Anchored => _physicsComponent == null || _physicsComponent.BodyType == BodyType.Static;
|
||||
private bool Anchored => _physicsComponent == null || _physicsComponent.Anchored;
|
||||
|
||||
[ViewVariables]
|
||||
public bool NeedsProvider { get; private set; } = true;
|
||||
@@ -99,7 +98,7 @@ namespace Content.Server.GameObjects.Components.Power.ApcNetComponents
|
||||
}
|
||||
}
|
||||
|
||||
public override void OnRemove()
|
||||
public override void OnRemove()
|
||||
{
|
||||
_provider.RemoveReceiver(this);
|
||||
base.OnRemove();
|
||||
|
||||
Reference in New Issue
Block a user