From 3cd2c987cf58bc0f716ae0719212d5a20cb40427 Mon Sep 17 00:00:00 2001 From: Josh Roy Date: Tue, 23 Nov 2021 16:11:33 -0500 Subject: [PATCH] Updated Upstream (Bukkit/CraftBukkit/Spigot) Upstream has released updates that appear 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: ea30a299 Add docs in ServerListPingEvent based on changes from 1.18 CraftBukkit Changes: 03f249f0 Generate bootstrap jar separately 3b214b5a SPIGOT-6803: Fix ServerPing not using the new logic for show players in 1.18 Spigot Changes: c07753b0 Rebuild patches --- patches/api/0007-Adventure.patch | 8 ++++---- patches/server/0001-Setup-Gradle-project.patch | 4 ++-- ...0180-Implement-extended-PaperServerListPingEvent.patch | 6 +++--- work/BuildData | 2 +- work/Bukkit | 2 +- work/CraftBukkit | 2 +- work/Spigot | 2 +- 7 files changed, 13 insertions(+), 13 deletions(-) diff --git a/patches/api/0007-Adventure.patch b/patches/api/0007-Adventure.patch index 23632ce4c..ddfa86865 100644 --- a/patches/api/0007-Adventure.patch +++ b/patches/api/0007-Adventure.patch @@ -3008,10 +3008,10 @@ index 03bfca9d368bbe4b7c1353d52c883e756bf69bda..4f8c85222c7bd33217c7db0ff5f47bf3 /** diff --git a/src/main/java/org/bukkit/event/server/ServerListPingEvent.java b/src/main/java/org/bukkit/event/server/ServerListPingEvent.java -index 7a2a58bac8e721c3f0c64f69f77be07a51f76d58..ede5a41bc071a9c9cea369b227b37a50222f295d 100644 +index cc5e2fef75736e56420df4cf4f83152fa97926df..fd4db14bef92b893ddaf5424e14ee71da22dcf84 100644 --- a/src/main/java/org/bukkit/event/server/ServerListPingEvent.java +++ b/src/main/java/org/bukkit/event/server/ServerListPingEvent.java -@@ -17,15 +17,16 @@ public class ServerListPingEvent extends ServerEvent implements Iterable +@@ -21,15 +21,16 @@ public class ServerListPingEvent extends ServerEvent implements Iterable private static final int MAGIC_PLAYER_COUNT = Integer.MIN_VALUE; private static final HandlerList handlers = new HandlerList(); private final InetAddress address; @@ -3030,7 +3030,7 @@ index 7a2a58bac8e721c3f0c64f69f77be07a51f76d58..ede5a41bc071a9c9cea369b227b37a50 this.numPlayers = numPlayers; this.maxPlayers = maxPlayers; } -@@ -38,14 +39,58 @@ public class ServerListPingEvent extends ServerEvent implements Iterable +@@ -42,14 +43,58 @@ public class ServerListPingEvent extends ServerEvent implements Iterable * @param address the address of the pinger * @param motd the message of the day * @param maxPlayers the max number of players @@ -3089,7 +3089,7 @@ index 7a2a58bac8e721c3f0c64f69f77be07a51f76d58..ede5a41bc071a9c9cea369b227b37a50 /** * Get the address the ping is coming from. -@@ -61,19 +106,23 @@ public class ServerListPingEvent extends ServerEvent implements Iterable +@@ -65,19 +110,23 @@ public class ServerListPingEvent extends ServerEvent implements Iterable * Get the message of the day message. * * @return the message of the day diff --git a/patches/server/0001-Setup-Gradle-project.patch b/patches/server/0001-Setup-Gradle-project.patch index 2b6e6bc5b..a96e2dec2 100644 --- a/patches/server/0001-Setup-Gradle-project.patch +++ b/patches/server/0001-Setup-Gradle-project.patch @@ -179,7 +179,7 @@ index 0000000000000000000000000000000000000000..273746fe476a9a09ebca01c6ecd814b7 +} diff --git a/pom.xml b/pom.xml deleted file mode 100644 -index 46c1c0461ab4ddfe652fc260b7647bdfc704f36f..0000000000000000000000000000000000000000 +index 3610b0d8e10f873b8480864d6f73c20ae8c5d1f1..0000000000000000000000000000000000000000 --- a/pom.xml +++ /dev/null @@ -1,539 +0,0 @@ @@ -568,7 +568,6 @@ index 46c1c0461ab4ddfe652fc260b7647bdfc704f36f..00000000000000000000000000000000 - single - - -- false - - - false @@ -577,6 +576,7 @@ index 46c1c0461ab4ddfe652fc260b7647bdfc704f36f..00000000000000000000000000000000 - org.bukkit.craftbukkit.bootstrap.Main - - +- false - - ${project.basedir}/src/assembly/bootstrap.xml - diff --git a/patches/server/0180-Implement-extended-PaperServerListPingEvent.patch b/patches/server/0180-Implement-extended-PaperServerListPingEvent.patch index cc6eaed20..1c9d036b6 100644 --- a/patches/server/0180-Implement-extended-PaperServerListPingEvent.patch +++ b/patches/server/0180-Implement-extended-PaperServerListPingEvent.patch @@ -213,7 +213,7 @@ index 543acb52698deb890a2624112e63be275a52c008..e9333b85100d7670b2be7df6e847dfca for (int k = 0; k < agameprofile.length; ++k) { diff --git a/src/main/java/net/minecraft/server/network/ServerStatusPacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerStatusPacketListenerImpl.java -index dff7b1005f60c762ed81de5eb77e1575f07f5ce9..4edbdc7379714609053606b492942cfc768245e1 100644 +index 2b24a41587fbe1fba70a0ab42d3dc33358f2ba2e..4fa79d37ff4e70c61672cce7c55257c46232c026 100644 --- a/src/main/java/net/minecraft/server/network/ServerStatusPacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerStatusPacketListenerImpl.java @@ -47,6 +47,8 @@ public class ServerStatusPacketListenerImpl implements ServerStatusPacketListene @@ -223,9 +223,9 @@ index dff7b1005f60c762ed81de5eb77e1575f07f5ce9..4edbdc7379714609053606b492942cfc + // Paper start - Replace everything + /* // CraftBukkit start - // this.networkManager.sendPacket(new PacketStatusOutServerInfo(this.minecraftServer.getServerPing())); + // this.connection.send(new PacketStatusOutServerInfo(this.server.getStatus())); final Object[] players = this.server.getPlayerList().players.toArray(); -@@ -143,6 +145,9 @@ public class ServerStatusPacketListenerImpl implements ServerStatusPacketListene +@@ -150,6 +152,9 @@ public class ServerStatusPacketListenerImpl implements ServerStatusPacketListene this.connection.send(new ClientboundStatusResponsePacket(ping)); // CraftBukkit end diff --git a/work/BuildData b/work/BuildData index b364c062b..8581e449a 160000 --- a/work/BuildData +++ b/work/BuildData @@ -1 +1 @@ -Subproject commit b364c062bb9b9534c0dd34c7a46f3f1acbfb195d +Subproject commit 8581e449a3490934f8bfa8b36d45842393dc8a20 diff --git a/work/Bukkit b/work/Bukkit index 07a055315..ea30a299e 160000 --- a/work/Bukkit +++ b/work/Bukkit @@ -1 +1 @@ -Subproject commit 07a055315ce10d9e6134b9367443ddeeda501236 +Subproject commit ea30a299e948f5545b0ad042bd8e11716aeaa7f2 diff --git a/work/CraftBukkit b/work/CraftBukkit index dd02403be..03f249f09 160000 --- a/work/CraftBukkit +++ b/work/CraftBukkit @@ -1 +1 @@ -Subproject commit dd02403be2ea957207939f1eec83cd2753d95bbc +Subproject commit 03f249f09854e409a231d5e2024cef635d652b79 diff --git a/work/Spigot b/work/Spigot index d5de73469..c07753b05 160000 --- a/work/Spigot +++ b/work/Spigot @@ -1 +1 @@ -Subproject commit d5de734690f9745e2c8968cf5369664ff0f53af9 +Subproject commit c07753b057d92ef6c0f9ad8e8446f51bcc37604d