From a2b6c27442c848b53a58ab9c937609a84538de1a Mon Sep 17 00:00:00 2001 From: Yannick Lamprecht Date: Thu, 8 Jun 2023 07:42:44 +1000 Subject: [PATCH] #1200: Implement open sign by side --- src/main/java/org/bukkit/craftbukkit/block/CraftSign.java | 5 +++-- src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java b/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java index 8cc0f8c2b..d22ef80c8 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftSign.java @@ -93,14 +93,15 @@ public class CraftSign extends CraftBlockEntityState) sign).getTileEntity(); - ((CraftPlayer) player).getHandle().openTextEdit(handle, true); + ((CraftPlayer) player).getHandle().openTextEdit(handle, Side.FRONT == side); } public static IChatBaseComponent[] sanitizeLines(String[] lines) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java index 7c4ea7f68..c600da19f 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java @@ -2098,12 +2098,12 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @Override public void openSign(Sign sign) { - CraftSign.openSign(sign, this); + openSign(sign, Side.FRONT); } @Override public void openSign(@NotNull Sign sign, @NotNull Side side) { - openSign(sign); // todo implement per side + CraftSign.openSign(sign, this, side); } @Override