mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-30 16:19:03 +01:00
Fix EditBook Event
By: mrapple <tony@oc.tc>
This commit is contained in:
parent
aff3d19f1e
commit
6e5b0c8d67
1 changed files with 22 additions and 0 deletions
22
CraftBukkit-Patches/0139-Fix-EditBookEvent.patch
Normal file
22
CraftBukkit-Patches/0139-Fix-EditBookEvent.patch
Normal file
|
@ -0,0 +1,22 @@
|
|||
From 3bc1834be633fb5334fe3ae092e918fc42a6845d Mon Sep 17 00:00:00 2001
|
||||
From: mrapple <tony@oc.tc>
|
||||
Date: Tue, 15 Apr 2014 12:17:27 +1000
|
||||
Subject: [PATCH] Fix EditBookEvent
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
index fd6e057..be8d72d 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
@@ -1708,7 +1708,7 @@ public class PlayerConnection implements PacketPlayInListener {
|
||||
itemstack1 = this.player.inventory.getItemInHand();
|
||||
if (itemstack1 != null) {
|
||||
if (itemstack.getItem() == Items.BOOK_AND_QUILL && itemstack.getItem() == itemstack1.getItem()) {
|
||||
- itemstack1.a("pages", (NBTBase) itemstack.getTag().getList("pages", 8));
|
||||
+ CraftEventFactory.handleEditBookEvent(player, itemstack); // Spigot
|
||||
}
|
||||
|
||||
return;
|
||||
--
|
||||
1.8.3.2
|
||||
|
Loading…
Reference in a new issue