misc optimization (#6436)
This commit is contained in:
@@ -29,7 +29,7 @@ namespace Content.Shared.Pulling.Components
|
||||
/// </summary>
|
||||
public DistanceJoint? PullJoint { get; set; }
|
||||
|
||||
public bool BeingPulled => Puller != default;
|
||||
public bool BeingPulled => Puller != null;
|
||||
|
||||
public EntityCoordinates? MovingTo { get; set; }
|
||||
|
||||
@@ -76,15 +76,9 @@ namespace Content.Shared.Pulling.Components
|
||||
EntitySystem.Get<SharedPullingStateManagementSystem>().ForceRelationship(comp, this);
|
||||
}
|
||||
|
||||
protected override void Shutdown()
|
||||
{
|
||||
EntitySystem.Get<SharedPullingStateManagementSystem>().ForceDisconnectPullable(this);
|
||||
base.Shutdown();
|
||||
}
|
||||
|
||||
protected override void OnRemove()
|
||||
{
|
||||
if (Puller != default)
|
||||
if (Puller != null)
|
||||
{
|
||||
// This is absolute paranoia but it's also absolutely necessary. Too many puller state bugs. - 20kdc
|
||||
Logger.ErrorS("c.go.c.pulling", "PULLING STATE CORRUPTION IMMINENT IN PULLABLE {0} - OnRemove called when Puller is set!", Owner);
|
||||
|
||||
Reference in New Issue
Block a user