mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-05 10:20:53 +01:00
b62dfa0bf9
Upstream has released updates that appears to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing Bukkit Changes: 39ce5d3a SPIGOT-4399: ItemMeta.equals broken with AttributeModifiers CraftBukkit Changes:1cf8b5dc
SPIGOT-4400: Populators running on existing chunks116cb9a1
SPIGOT-4399: Add attribute modifier equality test5ee1c18a
SPIGOT-4398: Set ASM7_EXPERIMENTAL flag
32 lines
1.3 KiB
Diff
32 lines
1.3 KiB
Diff
From 26f0befa44982506a8089658de7c06d69afdc342 Mon Sep 17 00:00:00 2001
|
|
From: Mark Vainomaa <mikroskeem@mikroskeem.eu>
|
|
Date: Sun, 1 Apr 2018 02:29:37 +0300
|
|
Subject: [PATCH] Add method to open already placed sign
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
|
index 38a886fbd5..92fe80316f 100644
|
|
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
|
@@ -518,4 +518,17 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {
|
|
entity.remove();
|
|
}
|
|
}
|
|
+
|
|
+ // Paper start - Add method to open already placed sign
|
|
+ @Override
|
|
+ public void openSign(org.bukkit.block.Sign sign) {
|
|
+ org.apache.commons.lang.Validate.isTrue(sign.getWorld().equals(this.getWorld()), "Sign must be in the same world as player is in");
|
|
+ org.bukkit.craftbukkit.block.CraftSign craftSign = (org.bukkit.craftbukkit.block.CraftSign) sign;
|
|
+ net.minecraft.server.TileEntitySign teSign = craftSign.getTileEntity();
|
|
+ // Make sign editable temporarily, will be set back to false in PlayerConnection later
|
|
+ teSign.isEditable = true;
|
|
+
|
|
+ getHandle().openSign(teSign);
|
|
+ }
|
|
+ // Paper end
|
|
}
|
|
--
|
|
2.19.0
|
|
|