diff --git a/Content.Server/GameObjects/Components/Buckle/BuckleComponent.cs b/Content.Server/GameObjects/Components/Buckle/BuckleComponent.cs
index 634bdefa19..d382807979 100644
--- a/Content.Server/GameObjects/Components/Buckle/BuckleComponent.cs
+++ b/Content.Server/GameObjects/Components/Buckle/BuckleComponent.cs
@@ -16,6 +16,7 @@ using Robust.Server.GameObjects.EntitySystemMessages;
using Robust.Server.GameObjects.EntitySystems;
using Robust.Shared.Containers;
using Robust.Shared.GameObjects;
+using Robust.Shared.GameObjects.Systems;
using Robust.Shared.Interfaces.GameObjects;
using Robust.Shared.Interfaces.Timing;
using Robust.Shared.IoC;
@@ -85,7 +86,8 @@ namespace Content.Server.GameObjects.Components.Buckle
private bool ContainerChanged { get; set; }
///
- /// The amount of space that this entity occupies in a .
+ /// The amount of space that this entity occupies in a
+ /// .
///
[ViewVariables]
public int Size => _size;
@@ -106,9 +108,9 @@ namespace Content.Server.GameObjects.Components.Buckle
}
///
- /// Reattaches this entity to the strap, modifying its position and rotation
+ /// Reattaches this entity to the strap, modifying its position and rotation.
///
- /// The strap to reattach to
+ /// The strap to reattach to.
private void ReAttach(StrapComponent strap)
{
var ownTransform = Owner.Transform;
@@ -131,6 +133,11 @@ namespace Content.Server.GameObjects.Components.Buckle
ownTransform.WorldRotation = Angle.South;
break;
}
+
+ if (strapTransform.WorldRotation.GetCardinalDir() == Direction.North)
+ {
+ ownTransform.WorldPosition += (0, 0.15f);
+ }
}
///
@@ -167,10 +174,16 @@ namespace Content.Server.GameObjects.Components.Buckle
return false;
}
+ var ownerPosition = Owner.Transform.MapPosition;
var strapPosition = strap.Owner.Transform.MapPosition;
+ var interaction = EntitySystem.Get();
+ bool Ignored(IEntity entity) => entity == Owner || entity == user || entity == strap.Owner;
- if (!InteractionChecks.InRangeUnobstructed(user, strapPosition, _range))
+ if (!interaction.InRangeUnobstructed(ownerPosition, strapPosition, _range, predicate: Ignored))
{
+ _notifyManager.PopupMessage(strap.Owner, user,
+ Loc.GetString("You can't reach there!"));
+
return false;
}
@@ -408,7 +421,7 @@ namespace Content.Server.GameObjects.Components.Buckle
base.ExposeData(serializer);
serializer.DataField(ref _size, "size", 100);
- serializer.DataField(ref _range, "range", SharedInteractionSystem.InteractionRange / 2);
+ serializer.DataField(ref _range, "range", SharedInteractionSystem.InteractionRange / 1.4f);
var seconds = 0.25f;
serializer.DataField(ref seconds, "cooldown", 0.25f);