Allow entity effect changes off the main thread for worldgen (#8942)

* Allow entity effect modification off the main thread for worldgen

* squash all async catcher patches
This commit is contained in:
Jake Potrebic 2023-04-09 11:38:32 -07:00 committed by GitHub
parent f8c01122e6
commit 6a7fef0e4a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
252 changed files with 150 additions and 130 deletions

View File

@ -1,12 +1,46 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Spottedleaf <Spottedleaf@users.noreply.github.com>
Date: Sun, 31 Oct 2021 21:34:00 -0700
Subject: [PATCH] Async catch modifications to critical entity state
Date: Wed, 25 Aug 2021 20:17:12 -0700
Subject: [PATCH] Improve and expand AsyncCatcher
Log when the async catcher is tripped
The chunk system can swallow the exception given it's all
built with completablefuture, so ensure it is at least printed.
Add/move several async catchers
Async catch modifications to critical entity state
These used to be here from Spigot, but were dropped with 1.17.
Now in 1.17, this state is _even more_ critical than it was before,
so these must exist to catch stupid plugins.
Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 96897ccce68ecbff808077a07f213daccc57fa54..f2a96d282f65e405e8e396ef271ce0d5a094ac4b 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -1652,6 +1652,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
}
public void internalTeleport(double d0, double d1, double d2, float f, float f1, Set<RelativeMovement> set) { // Paper
+ org.spigotmc.AsyncCatcher.catchOp("teleport"); // Paper
// Paper start
if (player.isRemoved()) {
LOGGER.info("Attempt to teleport removed player {} restricted", player.getScoreboardName());
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index a7046e42c1935e9a4e529726072d9f88caaa703a..7d100539ffd1c52c4bf514907a0cb1d848eb0236 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -1102,7 +1102,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
}
public boolean addEffect(MobEffectInstance mobeffect, @Nullable Entity entity, EntityPotionEffectEvent.Cause cause) {
- org.spigotmc.AsyncCatcher.catchOp("effect add"); // Spigot
+ // org.spigotmc.AsyncCatcher.catchOp("effect add"); // Spigot // Paper - move to API
if (this.isTickingEffects) {
this.effectsToProcess.add(new ProcessableEffect(mobeffect, cause));
return true;
diff --git a/src/main/java/net/minecraft/world/level/entity/PersistentEntitySectionManager.java b/src/main/java/net/minecraft/world/level/entity/PersistentEntitySectionManager.java
index 038abf2ac104ceecaab11b10d466ea69ec86623e..a77985b2dd7137d8eea03909403fc08e89376d73 100644
--- a/src/main/java/net/minecraft/world/level/entity/PersistentEntitySectionManager.java
@ -131,3 +165,27 @@ index 038abf2ac104ceecaab11b10d466ea69ec86623e..a77985b2dd7137d8eea03909403fc08e
if (!this.currentSection.remove(this.entity)) {
PersistentEntitySectionManager.LOGGER.warn("Entity {} wasn't found in section {} (destroying due to {})", new Object[]{this.entity, SectionPos.of(this.currentSectionKey), reason});
}
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
index cbb6b437358823cd52518682f32dd597c9aeb85a..205101e301bb4ea552459fe4e1f028f252136720 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
@@ -455,6 +455,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
@Override
public boolean addPotionEffect(PotionEffect effect, boolean force) {
+ org.spigotmc.AsyncCatcher.catchOp("effect add"); // Paper
this.getHandle().addEffect(new MobEffectInstance(MobEffect.byId(effect.getType().getId()), effect.getDuration(), effect.getAmplifier(), effect.isAmbient(), effect.hasParticles(), effect.hasIcon()), EntityPotionEffectEvent.Cause.PLUGIN); // Paper - Don't ignore icon
return true;
}
diff --git a/src/main/java/org/spigotmc/AsyncCatcher.java b/src/main/java/org/spigotmc/AsyncCatcher.java
index 5409f230fdd53b70fc03c58177438534731ad4e6..c02a04d284734b5f545b64307ed4aea337c1465f 100644
--- a/src/main/java/org/spigotmc/AsyncCatcher.java
+++ b/src/main/java/org/spigotmc/AsyncCatcher.java
@@ -12,6 +12,7 @@ public class AsyncCatcher
{
if ( !io.papermc.paper.util.TickThread.isTickThread() ) // Paper // Paper - rewrite chunk system
{
+ MinecraftServer.LOGGER.error("Thread " + Thread.currentThread().getName() + " failed main thread check: " + reason, new Throwable()); // Paper
throw new IllegalStateException( "Asynchronous " + reason + "!" );
}
}

View File

@ -1,20 +0,0 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Spottedleaf <Spottedleaf@users.noreply.github.com>
Date: Wed, 25 Aug 2021 20:17:12 -0700
Subject: [PATCH] Log when the async catcher is tripped
The chunk system can swallow the exception given it's all
built with completablefuture, so ensure it is at least printed.
diff --git a/src/main/java/org/spigotmc/AsyncCatcher.java b/src/main/java/org/spigotmc/AsyncCatcher.java
index 5409f230fdd53b70fc03c58177438534731ad4e6..c02a04d284734b5f545b64307ed4aea337c1465f 100644
--- a/src/main/java/org/spigotmc/AsyncCatcher.java
+++ b/src/main/java/org/spigotmc/AsyncCatcher.java
@@ -12,6 +12,7 @@ public class AsyncCatcher
{
if ( !io.papermc.paper.util.TickThread.isTickThread() ) // Paper // Paper - rewrite chunk system
{
+ MinecraftServer.LOGGER.error("Thread " + Thread.currentThread().getName() + " failed main thread check: " + reason, new Throwable()); // Paper
throw new IllegalStateException( "Asynchronous " + reason + "!" );
}
}

View File

@ -6,7 +6,7 @@ Subject: [PATCH] Don't respond to ServerboundCommandSuggestionPacket when
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 96897ccce68ecbff808077a07f213daccc57fa54..bfc9fff1d9b397ea2ef5057bbb6ba897e234dc5c 100644
index f2a96d282f65e405e8e396ef271ce0d5a094ac4b..f739357b5c304c06de6bab20a0dc9cb438c33fc1 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -837,6 +837,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic

View File

@ -8,7 +8,7 @@ This is because bukkit uses a separate head rotation field for yaw.
This issue only applies to players.
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 2b3be52e421f21ed4736c9e9093c038d82ded227..47c51e8490abd10f0ff04efabea3681375589c56 100644
index d87e9e252056d9dea6748f54847434468a0111df..5e0a7aa0e9fb1350964d17e3f5904c4ec3922ff9 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -1783,6 +1783,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {

View File

@ -47,7 +47,7 @@ index 595779cfd0ee1c405d7936f00a7cae1706125e7f..ed3af916dfa875dd0a5f1e730d20d11e
@Override
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
index d84b976364b0ffc4b7356c6791d70f0e34deff48..9f73627c20d341afc57f287019e40bbbe574733e 100644
index 9848b4e62692c5044544710c93c099558fcbf1e6..db746a44c631380ff6bdf7a37d86d2e09877db88 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -245,7 +245,7 @@ public abstract class PlayerList {

View File

@ -5,7 +5,7 @@ Subject: [PATCH] don't attempt to teleport dead entities
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 47c51e8490abd10f0ff04efabea3681375589c56..73d475788e23d371c79908c792d8d4dd0ba770ab 100644
index 5e0a7aa0e9fb1350964d17e3f5904c4ec3922ff9..45eeef03ab3c885b4fbc332287089e9cc5d85afa 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -780,7 +780,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {

View File

@ -5,7 +5,7 @@ Subject: [PATCH] Prevent excessive velocity through repeated crits
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index f1cb4aa51edd1500b3ddd1f2457b905db8802900..36290f1fa97a543a45fae61a8548c95415abc900 100644
index 7d100539ffd1c52c4bf514907a0cb1d848eb0236..af9a16469df62b0ea9f1d35bcc30407f5e000646 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -2614,14 +2614,27 @@ public abstract class LivingEntity extends Entity implements Attackable {

View File

@ -34,7 +34,7 @@ index 6dddd4eb8de9a08461245e35e65d4106f4e8e729..3e8255898e8afdd1127eea79338d5cc5
}
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index 36290f1fa97a543a45fae61a8548c95415abc900..c92db10a6ee95753d71526da2d7e29045de87b85 100644
index af9a16469df62b0ea9f1d35bcc30407f5e000646..3e8d283a8312ac299bf0e260d75154ba8208d023 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -3126,7 +3126,10 @@ public abstract class LivingEntity extends Entity implements Attackable {

View File

@ -18,10 +18,10 @@ index 3e8255898e8afdd1127eea79338d5cc54502be76..fc187be6b3fb7bc9fa97d1ebcbe92294
}
}
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index bfc9fff1d9b397ea2ef5057bbb6ba897e234dc5c..5e34d42ba53d90f35e072c9f6cd6c6d714de5c21 100644
index f739357b5c304c06de6bab20a0dc9cb438c33fc1..ee5ef598250ed02dbb44eb4240cb5b2521e33520 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -2697,8 +2697,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
@@ -2698,8 +2698,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
// Refresh the current entity metadata
entity.getEntityData().refresh(player);
// SPIGOT-7136 - Allays
@ -33,7 +33,7 @@ index bfc9fff1d9b397ea2ef5057bbb6ba897e234dc5c..5e34d42ba53d90f35e072c9f6cd6c6d7
}
}
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index c92db10a6ee95753d71526da2d7e29045de87b85..15c00d3dc8cab6968703d0420600aa77b2ffbec5 100644
index 3e8d283a8312ac299bf0e260d75154ba8208d023..b167d83abee37d64f8ef5865b9407bf1d2237ea1 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -3128,7 +3128,7 @@ public abstract class LivingEntity extends Entity implements Attackable {

View File

@ -5,7 +5,7 @@ Subject: [PATCH] Allow delegation to vanilla chunk gen
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index e3aef13c8b432b46690daf3b27e95b8623ae0aca..1e54fc63253a12f2dbc248965d0027e526a3cc86 100644
index c9e643ca1a2fab8a314e5f232903b3a54bfd0a76..c997788550f03e3441fc879e281eb54f64a44f01 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -2337,6 +2337,90 @@ public final class CraftServer implements Server {

View File

@ -1202,7 +1202,7 @@ index d9719e544261b9d2dc85fa9936ae23ea8e8dd08c..5afb17ccc16e614e91ff3cad2f714b4a
}
}
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
index 9f73627c20d341afc57f287019e40bbbe574733e..85d5efe606f71d729fb1b1271d661b205a0ae324 100644
index db746a44c631380ff6bdf7a37d86d2e09877db88..8d64bd67bff3403b53c2ac98fc7be20310c847b8 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -885,7 +885,7 @@ public abstract class PlayerList {

View File

@ -6,7 +6,7 @@ Subject: [PATCH] Optimise collision checking in player move packet handling
Move collision logic to just the hasNewCollision call instead of getCubes + hasNewCollision
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 5e34d42ba53d90f35e072c9f6cd6c6d714de5c21..e18e2ef7846a49e24411adf571b25d37e068c3fe 100644
index ee5ef598250ed02dbb44eb4240cb5b2521e33520..302582a20700fbea302886115143bd25099e0d51 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -645,7 +645,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic

View File

@ -5,7 +5,7 @@ Subject: [PATCH] Forward CraftEntity in teleport command
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 182e443e4cd114edeb0c0c6be5dda76d49346da3..bd8e756bf1e74cdc75cc12d2368a6fe702a759ad 100644
index 63802f5304f23a6e1e469e383692376d1f4d8f0d..374ba7c9a088bc56ec1da96902aab3c81889c64d 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -3330,6 +3330,13 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {

View File

@ -56,7 +56,7 @@ index ed3af916dfa875dd0a5f1e730d20d11efd6419c6..cd4e76fe5b79c7d9e615b4886a568c74
if (gameprofile != null && packet.name().equalsIgnoreCase(gameprofile.getName())) {
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
index 85d5efe606f71d729fb1b1271d661b205a0ae324..7b3b5a9bd7bfdec08998f75026fe8d3b8a2a9a42 100644
index 8d64bd67bff3403b53c2ac98fc7be20310c847b8..4206caa7660611dfbeaac0d67c695fa1868c7534 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -663,7 +663,7 @@ public abstract class PlayerList {

View File

@ -18,7 +18,7 @@ index 24c88555ea85dd2a0656e1f67a4828a5137157b8..cbbb0ff40488c430d15c2ed054d1b288
biomeProvider = gen.getDefaultBiomeProvider(worldInfo);
}
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 9f172ccae28779ae28eeeceb4305298b9ceed44a..8be3aeab748b57a73522f6124f8e3aacf1f2ee0e 100644
index c997788550f03e3441fc879e281eb54f64a44f01..aa460a1c8506b6c499d45f7ee7371ebd540ec7dd 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -1217,7 +1217,7 @@ public final class CraftServer implements Server {

View File

@ -5,7 +5,7 @@ Subject: [PATCH] Added getHostname to AsyncPlayerPreLoginEvent
diff --git a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
index 5df657555439e07d5fb67db8c82246c15676850d..f45b616c4f418298c67903c141c52172b6dd51e0 100644
index cd4e76fe5b79c7d9e615b4886a568c74db757436..3fcd7bfdb8945b276c94a263e9da6b85ce470366 100644
--- a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
@@ -371,7 +371,7 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,

View File

@ -7,10 +7,10 @@ Makes the PlayerKickEvent fire on the main thread for
illegal characters or chat out-of-order errors.
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index e18e2ef7846a49e24411adf571b25d37e068c3fe..c11e1803ba16a6c380bb0a23408a04d724d92798 100644
index 302582a20700fbea302886115143bd25099e0d51..f0c93d67486d891cda90beb23bb6241d4c55ff1c 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -2160,7 +2160,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
@@ -2161,7 +2161,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
}
// CraftBukkit end
if (ServerGamePacketListenerImpl.isChatMessageIllegal(packet.message())) {
@ -20,7 +20,7 @@ index e18e2ef7846a49e24411adf571b25d37e068c3fe..c11e1803ba16a6c380bb0a23408a04d7
} else {
Optional<LastSeenMessages> optional = this.tryHandleChat(packet.message(), packet.timeStamp(), packet.lastSeenMessages());
@@ -2194,7 +2196,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
@@ -2195,7 +2197,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
@Override
public void handleChatCommand(ServerboundChatCommandPacket packet) {
if (ServerGamePacketListenerImpl.isChatMessageIllegal(packet.command())) {
@ -30,7 +30,7 @@ index e18e2ef7846a49e24411adf571b25d37e068c3fe..c11e1803ba16a6c380bb0a23408a04d7
} else {
Optional<LastSeenMessages> optional = this.tryHandleChat(packet.command(), packet.timeStamp(), packet.lastSeenMessages());
@@ -2274,7 +2278,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
@@ -2275,7 +2279,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
private Optional<LastSeenMessages> tryHandleChat(String message, Instant timestamp, LastSeenMessages.Update acknowledgment) {
if (!this.updateChatOrder(timestamp)) {
ServerGamePacketListenerImpl.LOGGER.warn("{} sent out-of-order chat: '{}'", this.player.getName().getString(), message);

View File

@ -25,7 +25,7 @@ index c96e75456c2f8564d3bc75993cc6e03ba605597d..7c6a6693760638a07b7c7c330aaeffd9
public void write(FriendlyByteBuf buf) {
buf.writeLong(this.sectionPos.asLong());
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index de5bd1107f21c8319178c2287a4a01091b4966b0..93a7d7a3b65c85b639bfa7a419ef8ea840b1d92f 100644
index d044420955a2a8e19337771ce155777a462c00fe..d6a77a8b459c4b753edf7b0ec955d76861a747ed 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -948,6 +948,32 @@ public class CraftPlayer extends CraftHumanEntity implements Player {

View File

@ -5,7 +5,7 @@ Subject: [PATCH] Freeze Tick Lock API
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index bd8e756bf1e74cdc75cc12d2368a6fe702a759ad..25610f1100d64f542506cc6b3d4469a810254dc7 100644
index 374ba7c9a088bc56ec1da96902aab3c81889c64d..dccac696c29a340c5a60fc07aaab7f0f1506b039 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -397,6 +397,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
@ -46,7 +46,7 @@ index bd8e756bf1e74cdc75cc12d2368a6fe702a759ad..25610f1100d64f542506cc6b3d4469a8
} catch (Throwable throwable) {
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index 15c00d3dc8cab6968703d0420600aa77b2ffbec5..7fed29460309e1f35ee0207b4c07990201807bd1 100644
index b167d83abee37d64f8ef5865b9407bf1d2237ea1..b30e52730a7dec78e425365975ba57aa4f371cfd 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -3375,7 +3375,7 @@ public abstract class LivingEntity extends Entity implements Attackable {

View File

@ -122,7 +122,7 @@ index 0000000000000000000000000000000000000000..e3a5f1ec376319bdfda87fa27ae217bf
+ }
+}
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 39c0300d84e44d499b26ea365fc2e038fda58196..aeb0b205a710dc6c638c512f7b5f111aefdea399 100644
index aa460a1c8506b6c499d45f7ee7371ebd540ec7dd..b3de0224b6837022c4f010f84cf51dc20742764f 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -1999,6 +1999,13 @@ public final class CraftServer implements Server {

View File

@ -6,7 +6,7 @@ Subject: [PATCH] Add missing Validate calls to CraftServer#getSpawnLimit
Copies appropriate checks from CraftWorld#getSpawnLimit
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index aeb0b205a710dc6c638c512f7b5f111aefdea399..0f45a37053a1de4ac131d74382ff6e431f3a40b7 100644
index b3de0224b6837022c4f010f84cf51dc20742764f..d55f66b98cc3fc8c8d7beff2f83a3f57cc5d7ca0 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -2173,6 +2173,8 @@ public final class CraftServer implements Server {

View File

@ -46,7 +46,7 @@ index 0000000000000000000000000000000000000000..e7d9fd2702a1ce96596580fff8f5ee4f
+ }
+}
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 0f45a37053a1de4ac131d74382ff6e431f3a40b7..70cbdf557b81f9e7e5d744c31ea6972f96de55a3 100644
index d55f66b98cc3fc8c8d7beff2f83a3f57cc5d7ca0..a4b537774069dc5b3272e1fc06292d7b3144ff5b 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -2583,6 +2583,15 @@ public final class CraftServer implements Server {

View File

@ -23,7 +23,7 @@ index 23fce58a5909c5b01a5f0ef6912f90858cd3302c..a30c61e176501d1cbd2e330f85d5d258
if (worlddata.getCustomBossEvents() != null) {
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 4e8c8d5c40f50899517de585696e5a27ce69de1d..dc460b30c46e33fb0303d5f18d2f80a93a2ca916 100644
index a4b537774069dc5b3272e1fc06292d7b3144ff5b..2e88728e57ed95c458d5cd5071a245c280d4952e 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -1246,10 +1246,11 @@ public final class CraftServer implements Server {

View File

@ -164,7 +164,7 @@ index 424406d2692856cfd82b6f3b7b6228fa3bd20c2f..c57efcb9a79337ec791e4e8f6671612f
@Override
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index dc460b30c46e33fb0303d5f18d2f80a93a2ca916..538cee6c80a405613b27b11ee7db2567ceb60400 100644
index 2e88728e57ed95c458d5cd5071a245c280d4952e..339458bea9298de78f6a3c88426dbcd1b9a67cce 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -294,6 +294,7 @@ public final class CraftServer implements Server {

View File

@ -10,7 +10,7 @@ so we do not need that. The client only needs the chunk it is currently in to
be loaded to close the loading screen, so we just send an empty one.
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
index 7b3b5a9bd7bfdec08998f75026fe8d3b8a2a9a42..024b395f7f0cb68dda32f814fc7eef2a07b57eba 100644
index 4206caa7660611dfbeaac0d67c695fa1868c7534..39858280ef089b503f154b972da32cb2c53e22d2 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -386,6 +386,16 @@ public abstract class PlayerList {

View File

@ -357,7 +357,7 @@ index 832981b07ef5c633ef00a382f56798ee87eec0df..faf071201b7c1414225a33fe9641eac9
// Paper end
}
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
index f072f5ee75890650957b1c2ca27adc1a84c2bfa1..d95d37d9dedbd9f74311b47826a74b16ba6ce3e9 100644
index 16dd2e9951cf34af0c5bd4891d013423b9fad8b9..8147b45892015be602fe14adafd84f84c9685516 100644
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
@@ -278,12 +278,20 @@ public final class CraftItemStack extends ItemStack {

View File

@ -7,7 +7,7 @@ Bring the vehicle move packet behavior in line with the
regular player move packet.
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index c11e1803ba16a6c380bb0a23408a04d724d92798..0fc619570ea1280da6f80269abdbd59704a6f9e0 100644
index f0c93d67486d891cda90beb23bb6241d4c55ff1c..e978a9a29513e5f7fb667f9f02f589605df02ac2 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -575,6 +575,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic

View File

@ -6,7 +6,7 @@ Subject: [PATCH] Fix saving in unloadWorld
Change savingDisabled to false to ensure ServerLevel's saving logic gets called when unloadWorld is called with save = true
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index bee8855e09df7230cc5ce33a8cb8ed05f0af07f3..733157fd438c31b5bd86fea1454386b66d927852 100644
index 339458bea9298de78f6a3c88426dbcd1b9a67cce..24d4150240c28741a25bdfe1fd7f3a423763bd61 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -1294,7 +1294,7 @@ public final class CraftServer implements Server {

View File

@ -6,7 +6,7 @@ Subject: [PATCH] Ensure entity passenger world matches ridden entity
Bad plugins doing this would cause some obvious problems...
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 25610f1100d64f542506cc6b3d4469a810254dc7..35a246c1b167b356e293dd785c05f59a3ebcf4d8 100644
index dccac696c29a340c5a60fc07aaab7f0f1506b039..e052694ca221508f28cbfbb93a6ec974d9ca65d8 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -2723,6 +2723,12 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {

Some files were not shown because too many files have changed in this diff Show More