The disposals pushing and pulling update (#1875)

* Add collision to disposal unit and pipes
Make disposal unit and pipes pullable
Implement proper handling of collisions in disposals

* Implement IsExiting
Move DisposalSystem to shared

* Change SharedDisosalUnitComponent to call manager.ContainsEntity directly

* Update saltern.yml

Co-authored-by: Julian Giebel <j.giebel@netrocks.info>
This commit is contained in:
Julian Giebel
2020-08-24 20:41:15 +02:00
committed by GitHub
parent 9019079d79
commit d9f02a6a0a
8 changed files with 374 additions and 554 deletions

View File

@@ -24,7 +24,6 @@ using Robust.Shared.ViewVariables;
namespace Content.Server.GameObjects.Components.Disposal
{
// TODO: Make unanchored pipes pullable
public abstract class DisposalTubeComponent : Component, IDisposalTubeComponent, IBreakAct
{
[Dependency] private readonly IGameTiming _gameTiming = default!;
@@ -182,6 +181,8 @@ namespace Content.Server.GameObjects.Components.Disposal
return;
}
collidable.CanCollide = !collidable.Anchored;
if (collidable.Anchored)
{
OnAnchor();
@@ -220,6 +221,8 @@ namespace Content.Server.GameObjects.Components.Disposal
var collidable = Owner.EnsureComponent<CollidableComponent>();
collidable.AnchoredChanged += AnchoredChanged;
collidable.CanCollide = !collidable.Anchored;
}
protected override void Startup()