aboutsummaryrefslogtreecommitdiffhomepage
path: root/patch-remap/mache-spigotflower/net/minecraft/world/item/SignItem.java.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patch-remap/mache-spigotflower/net/minecraft/world/item/SignItem.java.patch')
-rw-r--r--patch-remap/mache-spigotflower/net/minecraft/world/item/SignItem.java.patch55
1 files changed, 55 insertions, 0 deletions
diff --git a/patch-remap/mache-spigotflower/net/minecraft/world/item/SignItem.java.patch b/patch-remap/mache-spigotflower/net/minecraft/world/item/SignItem.java.patch
new file mode 100644
index 0000000000..a7b04b1904
--- /dev/null
+++ b/patch-remap/mache-spigotflower/net/minecraft/world/item/SignItem.java.patch
@@ -0,0 +1,55 @@
+--- a/net/minecraft/world/item/SignItem.java
++++ b/net/minecraft/world/item/SignItem.java
+@@ -9,34 +9,38 @@
+ import net.minecraft.world.level.block.SignBlock;
+ import net.minecraft.world.level.block.entity.BlockEntity;
+ import net.minecraft.world.level.block.entity.SignBlockEntity;
+-import net.minecraft.world.level.block.state.BlockState;
++import net.minecraft.world.level.block.state.IBlockData;
+
+ public class SignItem extends StandingAndWallBlockItem {
+
+- public SignItem(Item.Properties item_properties, Block block, Block block1) {
+- super(block, block1, item_properties, Direction.DOWN);
++ public static BlockPos openSign; // CraftBukkit
++
++ public SignItem(Item.Properties properties, Block standingBlock, Block wallBlock) {
++ super(standingBlock, wallBlock, properties, Direction.DOWN);
+ }
+
+- public SignItem(Item.Properties item_properties, Block block, Block block1, Direction direction) {
+- super(block, block1, item_properties, direction);
++ public SignItem(Item.Properties properties, Block standingBlock, Block wallBlock, Direction attachmentDirection) {
++ super(standingBlock, wallBlock, properties, attachmentDirection);
+ }
+
+ @Override
+- @Override
+- protected boolean updateCustomBlockEntityTag(BlockPos blockpos, Level level, @Nullable Player player, ItemStack itemstack, BlockState blockstate) {
+- boolean flag = super.updateCustomBlockEntityTag(blockpos, level, player, itemstack, blockstate);
++ protected boolean updateCustomBlockEntityTag(BlockPos pos, Level level, @Nullable Player player, ItemStack stack, IBlockData state) {
++ boolean flag = super.updateCustomBlockEntityTag(pos, level, player, stack, state);
+
+ if (!level.isClientSide && !flag && player != null) {
+- BlockEntity blockentity = level.getBlockEntity(blockpos);
++ BlockEntity tileentity = level.getBlockEntity(pos);
+
+- if (blockentity instanceof SignBlockEntity) {
+- SignBlockEntity signblockentity = (SignBlockEntity) blockentity;
+- Block block = level.getBlockState(blockpos).getBlock();
++ if (tileentity instanceof SignBlockEntity) {
++ SignBlockEntity tileentitysign = (SignBlockEntity) tileentity;
++ Block block = level.getBlockState(pos).getBlock();
+
+ if (block instanceof SignBlock) {
+- SignBlock signblock = (SignBlock) block;
++ SignBlock blocksign = (SignBlock) block;
+
+- signblock.openTextEdit(player, signblockentity, true);
++ // CraftBukkit start - SPIGOT-4678
++ // blocksign.openTextEdit(entityhuman, tileentitysign, true);
++ SignItem.openSign = pos;
++ // CraftBukkit end
+ }
+ }
+ }