From 436c6f2449abf289d2b04c008551a17c77ef23db Mon Sep 17 00:00:00 2001 From: Zach Brown <1254957+zachbr@users.noreply.github.com> Date: Sun, 4 Jan 2015 20:30:07 -0600 Subject: [PATCH] Rebuild our patches for upstream changes --- Spigot-Server-Patches/Fix-kick-messages.patch | 41 --------- Spigot-Server-Patches/RIP-metrics.patch | 5 +- Spigot-Server-Patches/mc-dev-imports.patch | 85 ------------------- 3 files changed, 3 insertions(+), 128 deletions(-) delete mode 100644 Spigot-Server-Patches/Fix-kick-messages.patch diff --git a/Spigot-Server-Patches/Fix-kick-messages.patch b/Spigot-Server-Patches/Fix-kick-messages.patch deleted file mode 100644 index eef3237e79..0000000000 --- a/Spigot-Server-Patches/Fix-kick-messages.patch +++ /dev/null @@ -1,41 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: Howaner -Date: Sat, 3 Jan 2015 18:25:24 -0600 -Subject: [PATCH] Fix kick messages - - -diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/net/minecraft/server/PlayerConnection.java -+++ b/src/main/java/net/minecraft/server/PlayerConnection.java -@@ -0,0 +0,0 @@ public class PlayerConnection implements PacketListenerPlayIn, IUpdatePlayerList - // CraftBukkit end - ChatComponentText chatcomponenttext = new ChatComponentText(s); - -- this.a(chatcomponenttext); // CraftBukkit - fire quit instantly - this.networkManager.a(new PacketPlayOutKickDisconnect(chatcomponenttext), new PlayerConnectionFuture(this, chatcomponenttext), new GenericFutureListener[0]); -+ this.a(chatcomponenttext); // CraftBukkit - fire quit instantly // PaperSpigot - Moved down - this.networkManager.k(); - this.minecraftServer.postToMainThread(new PlayerConnectionDisconnector(this)); // CraftBukkit - Don't wait - } -diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/net/minecraft/server/PlayerList.java -+++ b/src/main/java/net/minecraft/server/PlayerList.java -@@ -0,0 +0,0 @@ public abstract class PlayerList { - } - - public void v() { -- for (int i = 0; i < this.players.size(); ++i) { -- ((EntityPlayer) this.players.get(i)).playerConnection.disconnect(this.server.server.getShutdownMessage()); // CraftBukkit - add custom shutdown message -+ // PaperSpigot start - for -> while -+ while (!this.players.isEmpty()) { -+ ((EntityPlayer) this.players.get(0)).playerConnection.disconnect(this.server.server.getShutdownMessage()); // CraftBukkit - add custom shutdown message - } -+ // PaperSpigot end - } - - // CraftBukkit start --- -1.9.5.msysgit.0 - diff --git a/Spigot-Server-Patches/RIP-metrics.patch b/Spigot-Server-Patches/RIP-metrics.patch index 7adf32234b..7ba2ff7d39 100644 --- a/Spigot-Server-Patches/RIP-metrics.patch +++ b/Spigot-Server-Patches/RIP-metrics.patch @@ -655,7 +655,6 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 - } - } -} -\ No newline at end of file diff --git a/src/main/java/org/spigotmc/SpigotConfig.java b/src/main/java/org/spigotmc/SpigotConfig.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/org/spigotmc/SpigotConfig.java @@ -687,4 +686,6 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 } static void readConfig(Class clazz, Object instance) --- \ No newline at end of file +-- +1.9.5.msysgit.0 + diff --git a/Spigot-Server-Patches/mc-dev-imports.patch b/Spigot-Server-Patches/mc-dev-imports.patch index 6f45b458a4..c22401a441 100644 --- a/Spigot-Server-Patches/mc-dev-imports.patch +++ b/Spigot-Server-Patches/mc-dev-imports.patch @@ -400,89 +400,4 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + + } +} -diff --git a/src/main/java/net/minecraft/server/Slot.java b/src/main/java/net/minecraft/server/Slot.java -new file mode 100644 -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 ---- /dev/null -+++ b/src/main/java/net/minecraft/server/Slot.java -@@ -0,0 +0,0 @@ -+package net.minecraft.server; -+ -+public class Slot { -+ -+ public final int index; -+ public final IInventory inventory; -+ public int rawSlotIndex; -+ public int f; -+ public int g; -+ -+ public Slot(IInventory iinventory, int i, int j, int k) { -+ this.inventory = iinventory; -+ this.index = i; -+ this.f = j; -+ this.g = k; -+ } -+ -+ public void a(ItemStack itemstack, ItemStack itemstack1) { -+ if (itemstack != null && itemstack1 != null) { -+ if (itemstack.getItem() == itemstack1.getItem()) { -+ int i = itemstack1.count - itemstack.count; -+ -+ if (i > 0) { -+ this.a(itemstack, i); -+ } -+ -+ } -+ } -+ } -+ -+ protected void a(ItemStack itemstack, int i) {} -+ -+ protected void c(ItemStack itemstack) {} -+ -+ public void a(EntityHuman entityhuman, ItemStack itemstack) { -+ this.f(); -+ } -+ -+ public boolean isAllowed(ItemStack itemstack) { -+ return true; -+ } -+ -+ public ItemStack getItem() { -+ return this.inventory.getItem(this.index); -+ } -+ -+ public boolean hasItem() { -+ return this.getItem() != null; -+ } -+ -+ public void set(ItemStack itemstack) { -+ this.inventory.setItem(this.index, itemstack); -+ this.f(); -+ } -+ -+ public void f() { -+ this.inventory.update(); -+ } -+ -+ public int getMaxStackSize() { -+ return this.inventory.getMaxStackSize(); -+ } -+ -+ public int getMaxStackSize(ItemStack itemstack) { -+ return this.getMaxStackSize(); -+ } -+ -+ public ItemStack a(int i) { -+ return this.inventory.splitStack(this.index, i); -+ } -+ -+ public boolean a(IInventory iinventory, int i) { -+ return iinventory == this.inventory && i == this.index; -+ } -+ -+ public boolean isAllowed(EntityHuman entityhuman) { -+ return true; -+ } -+} -- \ No newline at end of file