From 6df562eb7f965e97fcc2e5cffc6f8edb30c8daa4 Mon Sep 17 00:00:00 2001 From: david <89749147+davight@users.noreply.github.com> Date: Mon, 19 Jan 2026 10:01:14 +0100 Subject: [PATCH] fix --- .../denizen/utilities/entity/EntityAttachmentHelper.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/plugin/src/main/java/com/denizenscript/denizen/utilities/entity/EntityAttachmentHelper.java b/plugin/src/main/java/com/denizenscript/denizen/utilities/entity/EntityAttachmentHelper.java index e2e4c50d02..b1324770be 100644 --- a/plugin/src/main/java/com/denizenscript/denizen/utilities/entity/EntityAttachmentHelper.java +++ b/plugin/src/main/java/com/denizenscript/denizen/utilities/entity/EntityAttachmentHelper.java @@ -50,7 +50,10 @@ public Vector fixedForOffset(Vector offset, float yaw, float pitch) { public void doServerSync() { Location goal = to.getLocation(); if (positionalOffset != null) { - goal = fixedForOffset(goal.toVector(), goal.getYaw(), goal.getPitch()).toLocation(goal.getWorld()); + float yaw = goal.getYaw(); + float pitch = goal.getPitch(); + Vector vec = fixedForOffset(goal.toVector(), yaw, pitch); + goal = offsetRelative ? vec.toLocation(goal.getWorld(), yaw, pitch) : vec.toLocation(goal.getWorld()); } if (noRotate) { Location attachLoc = attached.getLocation();