Disposals fixed under station rotation (#5067)

* Some sanity checks on disposals movement, fix the interpolator

* Technically fix disposal routing, but I'm not done here yet

* Remove disposals reliance on implicit direction sensing entirely.
This commit is contained in:
20kdc
2021-10-29 09:07:32 +01:00
committed by GitHub
parent 01d62baa64
commit 7cdb9dcf86
8 changed files with 64 additions and 55 deletions

View File

@@ -37,8 +37,8 @@ namespace Content.Server.Disposal.Tube.Components
var next = Owner.Transform.LocalRotation.GetDir();
var directions = ConnectableDirections().Skip(1).ToArray();
if (holder.PreviousTube == null ||
DirectionTo(holder.PreviousTube) == next)
if (holder.PreviousDirectionFrom == Direction.Invalid ||
holder.PreviousDirectionFrom == next)
{
return _random.Pick(directions);
}