Dieser Commit ist enthalten in:
Jake Potrebic 2024-06-13 18:30:23 -07:00
Ursprung 8731266275
Commit 52b49fbcc8
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: ECE0B3C133C016C5
141 geänderte Dateien mit 520 neuen und 639 gelöschten Zeilen

Datei anzeigen

@ -6,10 +6,10 @@ Subject: [PATCH] Add EntityPortalReadyEvent
diff --git a/src/main/java/io/papermc/paper/event/entity/EntityPortalReadyEvent.java b/src/main/java/io/papermc/paper/event/entity/EntityPortalReadyEvent.java
new file mode 100644
index 0000000000000000000000000000000000000000..3450735c86a8af45491c010a796262ae892f14dc
index 0000000000000000000000000000000000000000..a3242498c1c44cee3eec708cbca5b776ceb84c3e
--- /dev/null
+++ b/src/main/java/io/papermc/paper/event/entity/EntityPortalReadyEvent.java
@@ -0,0 +1,94 @@
@@ -0,0 +1,96 @@
+package io.papermc.paper.event.entity;
+
+import org.bukkit.PortalType;
@ -37,7 +37,7 @@ index 0000000000000000000000000000000000000000..3450735c86a8af45491c010a796262ae
+ private static final HandlerList HANDLER_LIST = new HandlerList();
+
+ private final PortalType portalType;
+ private World targetWorld;
+ private final World targetWorld;
+
+ private boolean cancelled;
+
@ -71,9 +71,11 @@ index 0000000000000000000000000000000000000000..3450735c86a8af45491c010a796262ae
+ * or {@link EntityPortalEvent}.
+ *
+ * @param targetWorld the world
+ * @deprecated changing the target world has no effect
+ */
+ @Deprecated(forRemoval = true, since = "1.21")
+ public void setTargetWorld(final @Nullable World targetWorld) {
+ this.targetWorld = targetWorld;
+ // this.targetWorld = targetWorld;
+ }
+
+ /**

Datei anzeigen

@ -5,10 +5,10 @@ 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 7966d45adcbc239a506ab4aa2923a6df0dc36c03..1632b2231e20901ce8498f3a0442e9ea54fcc068 100644
index 4ec6a43b7f16560de948974d60ad8ab1dcbb4696..038c22d09818c9a8310a8457d87b7e61119bb0dd 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -3284,6 +3284,13 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
@@ -3355,6 +3355,13 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
}
public void restoreFrom(Entity original) {
@ -22,18 +22,14 @@ index 7966d45adcbc239a506ab4aa2923a6df0dc36c03..1632b2231e20901ce8498f3a0442e9ea
CompoundTag nbttagcompound = original.saveWithoutId(new CompoundTag());
nbttagcompound.remove("Dimension");
@@ -3374,10 +3381,10 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
}
@@ -3441,8 +3448,8 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
entity2.restoreFrom(this);
this.removeAfterChangingDimensions();
// CraftBukkit start - Forward the CraftEntity to the new entity
- this.getBukkitEntity().setHandle(entity2);
- entity2.bukkitEntity = this.getBukkitEntity();
+ // this.getBukkitEntity().setHandle(entity2); // Paper - forward CraftEntity in teleport command; moved to Entity#restoreFrom
+ // entity2.bukkitEntity = this.getBukkitEntity();
// CraftBukkit end
}
// CraftBukkit end
- // CraftBukkit start - Forward the CraftEntity to the new entity
- this.getBukkitEntity().setHandle(entity);
- entity.bukkitEntity = this.getBukkitEntity();
- // CraftBukkit end
+ // // CraftBukkit start - Forward the CraftEntity to the new entity // Paper - Forward CraftEntity in teleport command; moved to Entity#restoreFrom
+ // this.getBukkitEntity().setHandle(entity);
+ // entity.bukkitEntity = this.getBukkitEntity();
+ // // CraftBukkit end
}
this.removeAfterChangingDimensions();

Datei anzeigen

@ -7,10 +7,10 @@ Subject: [PATCH] Entity powdered snow API
public net.minecraft.world.entity.monster.Skeleton inPowderSnowTime
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
index a61638bc8200f6aa25d9c3254aea6c0cd38bcbf1..97716f0a20fbc5f7048256ad1942e8f56e9fb72b 100644
index 6f9286e65f7ac730b808ddf9b52c344f03b4d778..d2648218d41439c4048901f2dbd59fe5eef57495 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
@@ -1080,6 +1080,13 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
@@ -1097,6 +1097,13 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
}
// Paper end - raw entity serialization API

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Validate usernames
diff --git a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
index b968026728b8b4e549eed9fa9b43919c6c19eb7a..9bcded0466f3b10fafd709edc44c60f85cb48b7f 100644
index baedae23865ea80c6546d1f6f439e1d7712258b9..e9cd90b6bb2f57d605323add43f12962bd7cb843 100644
--- a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
@@ -83,6 +83,7 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
@@ -85,6 +85,7 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
private final String serverId;
private final boolean transferred;
private ServerPlayer player; // CraftBukkit
@ -16,7 +16,7 @@ index b968026728b8b4e549eed9fa9b43919c6c19eb7a..9bcded0466f3b10fafd709edc44c60f8
public ServerLoginPacketListenerImpl(MinecraftServer server, Connection connection, boolean transferred) {
this.state = ServerLoginPacketListenerImpl.State.HELLO;
@@ -164,7 +165,13 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
@@ -166,7 +167,13 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
@Override
public void handleHello(ServerboundHelloPacket packet) {
Validate.validState(this.state == ServerLoginPacketListenerImpl.State.HELLO, "Unexpected hello packet", new Object[0]);
@ -32,10 +32,10 @@ index b968026728b8b4e549eed9fa9b43919c6c19eb7a..9bcded0466f3b10fafd709edc44c60f8
GameProfile gameprofile = this.server.getSingleplayerProfile();
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
index d7bbdcc97745246718c92c9aba56d9f926897975..7406784899ba5f3575adf1ffe5e5d85ab430a841 100644
index 1ba8fa300b95ad5709e35068e8a372b627d132f9..2944ec6fd810957e6c01cf914b48d58235a1822c 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -676,7 +676,7 @@ public abstract class PlayerList {
@@ -670,7 +670,7 @@ public abstract class PlayerList {
for (int i = 0; i < this.players.size(); ++i) {
entityplayer = (ServerPlayer) this.players.get(i);

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Make water animal spawn height configurable
diff --git a/src/main/java/net/minecraft/world/entity/animal/WaterAnimal.java b/src/main/java/net/minecraft/world/entity/animal/WaterAnimal.java
index f74cfa008886e0b74b850982d60ceb8879243c36..6f22705072fecbe91196e4966fca2eeec060f120 100644
index ad86b129ffdb9c6358f451fbcc0ae000eb81141d..c9cabb061ebc9172647304431cc3fb2593dd47ba 100644
--- a/src/main/java/net/minecraft/world/entity/animal/WaterAnimal.java
+++ b/src/main/java/net/minecraft/world/entity/animal/WaterAnimal.java
@@ -68,6 +68,10 @@ public abstract class WaterAnimal extends PathfinderMob {
@@ -67,6 +67,10 @@ public abstract class WaterAnimal extends PathfinderMob {
) {
int i = world.getSeaLevel();
int j = i - 13;

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Expose vanilla BiomeProvider from WorldInfo
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index cdbdacee826c424177096ee78427eaf80131b5fd..f295eaf2dced5bf294eb094f6d6110da826f053f 100644
index ee212ed5538357830ea8b69da650ab67d67634bb..22f8e49536658fabe6136dbeec6b77eaf4ae5ee8 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -605,7 +605,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -612,7 +612,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
List<CustomSpawner> list = ImmutableList.of(new PhantomSpawner(), new PatrolSpawner(), new CatSpawner(), new VillageSiege(), new WanderingTraderSpawner(iworlddataserver));
LevelStem worlddimension = (LevelStem) dimensions.get(dimensionKey);
@ -18,10 +18,10 @@ index cdbdacee826c424177096ee78427eaf80131b5fd..f295eaf2dced5bf294eb094f6d6110da
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 a1c108bd8a11f63c0973e2d26186e18f5c3ba69e..f61ea45fd39b2641dbab5e4a7e35c46c1639367d 100644
index ad5dc323e03dfae8670ebf9fad629e76c2106af7..7707ecca5318e35533de93d4451cb62ba9b425b0 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 {
@@ -1297,7 +1297,7 @@ public final class CraftServer implements Server {
List<CustomSpawner> list = ImmutableList.of(new PhantomSpawner(), new PatrolSpawner(), new CatSpawner(), new VillageSiege(), new WanderingTraderSpawner(worlddata));
LevelStem worlddimension = iregistry.get(actualDimension);
@ -31,7 +31,7 @@ index a1c108bd8a11f63c0973e2d26186e18f5c3ba69e..f61ea45fd39b2641dbab5e4a7e35c46c
biomeProvider = generator.getDefaultBiomeProvider(worldInfo);
}
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
index fbd5df61e5cfd67991dedb7bbba4a16ff16fa49b..a5121eb7fa8fccf7e742beea285c2f741ece513d 100644
index 6c5865c4c29e5470239dcabdfbb54057d05c80c7..8d41492cd6305331deca3748eb24d689f23e280b 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
@@ -212,6 +212,29 @@ public class CraftWorld extends CraftRegionAccessor implements World {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Add configurable height for slime spawn
diff --git a/src/main/java/net/minecraft/world/entity/monster/Slime.java b/src/main/java/net/minecraft/world/entity/monster/Slime.java
index b32213c5a3a1ecaf602cf34bed44c537521c2846..f223e78eb1204bbf5f2de38a7ce5b663800f7dc4 100644
index b54c30ba73b6ab069c0c7c1cd2b193090da79667..adebb66e550f805f444bec22e9a4dd575a642b43 100644
--- a/src/main/java/net/minecraft/world/entity/monster/Slime.java
+++ b/src/main/java/net/minecraft/world/entity/monster/Slime.java
@@ -340,7 +340,11 @@ public class Slime extends Mob implements Enemy {
@@ -348,7 +348,11 @@ public class Slime extends Mob implements Enemy {
return checkMobSpawnRules(type, world, spawnReason, pos, random);
}
@ -21,7 +21,7 @@ index b32213c5a3a1ecaf602cf34bed44c537521c2846..f223e78eb1204bbf5f2de38a7ce5b663
return checkMobSpawnRules(type, world, spawnReason, pos, random);
}
@@ -351,7 +355,10 @@ public class Slime extends Mob implements Enemy {
@@ -359,7 +363,10 @@ public class Slime extends Mob implements Enemy {
ChunkPos chunkcoordintpair = new ChunkPos(pos);
boolean flag = world.getMinecraftWorld().paperConfig().entities.spawning.allChunksAreSlimeChunks || WorldgenRandom.seedSlimeChunk(chunkcoordintpair.x, chunkcoordintpair.z, ((WorldGenLevel) world).getSeed(), world.getMinecraftWorld().spigotConfig.slimeSeed).nextInt(10) == 0; // Spigot // Paper

Datei anzeigen

@ -9,21 +9,21 @@ so this resets it after each call to
Zombie#getExperienceReward
diff --git a/src/main/java/net/minecraft/world/entity/monster/Zombie.java b/src/main/java/net/minecraft/world/entity/monster/Zombie.java
index 8f8bba0e6690443823c8e2301db82cae3eb66551..e42dfc62bb179be1ab01b0096c05c6549d38abbc 100644
index fd304e7d8305877d56de7a38b8664e5a70bf0c33..2280004638fd19ed018cb3e77d53a018b34ec516 100644
--- a/src/main/java/net/minecraft/world/entity/monster/Zombie.java
+++ b/src/main/java/net/minecraft/world/entity/monster/Zombie.java
@@ -172,11 +172,16 @@ public class Zombie extends Monster {
@@ -176,11 +176,16 @@ public class Zombie extends Monster {
@Override
public int getExperienceReward() {
protected int getBaseExperienceReward() {
+ final int previousReward = this.xpReward; // Paper - store previous value to reset after calculating XP reward
if (this.isBaby()) {
this.xpReward = (int) ((double) this.xpReward * 2.5D);
}
- return super.getExperienceReward();
- return super.getBaseExperienceReward();
+ // Paper start - store previous value to reset after calculating XP reward
+ int reward = super.getExperienceReward();
+ int reward = super.getBaseExperienceReward();
+ this.xpReward = previousReward;
+ return reward;
+ // Paper end - store previous value to reset after calculating XP reward

Datei anzeigen

@ -24,10 +24,10 @@ index 926ff9be3d9e3f5d620e4c7ccb22b9f64865ff8c..1a37654aff9a9c86c9f7af10a1cf7213
buf.writeLong(this.sectionPos.asLong());
buf.writeVarInt(this.positions.length);
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 634da85870b31a9fc09d53f5670239e18bcb3d47..6793acbbae09a9bc39f59c029f6b02182ec33a92 100644
index 9c1205b6b3cae33e735e5d64735935e8396db7d8..7716d990ee193e920fc14e52404afdeab12c62b5 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -928,6 +928,32 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@@ -930,6 +930,32 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
this.getHandle().connection.send(packet);
}

Datei anzeigen

@ -5,10 +5,10 @@ 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 1632b2231e20901ce8498f3a0442e9ea54fcc068..6025b45d1c247941d83cd9c2d516c14a70f64bfd 100644
index 038c22d09818c9a8310a8457d87b7e61119bb0dd..ad049687cd6c6c98bd08b512c6233b725c6ad9ab 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -406,6 +406,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
@@ -412,6 +412,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
private org.bukkit.util.Vector origin;
@javax.annotation.Nullable
private UUID originWorld;
@ -16,7 +16,7 @@ index 1632b2231e20901ce8498f3a0442e9ea54fcc068..6025b45d1c247941d83cd9c2d516c14a
public void setOrigin(@javax.annotation.Nonnull Location location) {
this.origin = location.toVector();
@@ -776,7 +777,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
@@ -752,7 +753,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
this.setRemainingFireTicks(this.remainingFireTicks - 1);
}
@ -25,7 +25,7 @@ index 1632b2231e20901ce8498f3a0442e9ea54fcc068..6025b45d1c247941d83cd9c2d516c14a
this.setTicksFrozen(0);
this.level().levelEvent((Player) null, 1009, this.blockPosition, 1);
}
@@ -2273,6 +2274,9 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
@@ -2314,6 +2315,9 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
if (fromNetherPortal) {
nbttagcompound.putBoolean("Paper.FromNetherPortal", true);
}
@ -35,7 +35,7 @@ index 1632b2231e20901ce8498f3a0442e9ea54fcc068..6025b45d1c247941d83cd9c2d516c14a
// Paper end
return nbttagcompound;
} catch (Throwable throwable) {
@@ -2417,6 +2421,9 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
@@ -2458,6 +2462,9 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
if (spawnReason == null) {
spawnReason = org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.DEFAULT;
}
@ -46,10 +46,10 @@ index 1632b2231e20901ce8498f3a0442e9ea54fcc068..6025b45d1c247941d83cd9c2d516c14a
} 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 0fe6b9f4376d2b852f6f23e31848cd9236577bdf..8aae4dacb85f67ea5f67e1143f2094851d40e85e 100644
index 65ab2a1e47d9f338dbb13062d25f6c9a3d5cc7ff..60394f1b0e727d6dec4af37b452a6312eb3ae375 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -3448,7 +3448,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
@@ -3468,7 +3468,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
this.level().getProfiler().pop();
this.level().getProfiler().push("freezing");
@ -59,10 +59,10 @@ index 0fe6b9f4376d2b852f6f23e31848cd9236577bdf..8aae4dacb85f67ea5f67e1143f209485
if (this.isInPowderSnow && this.canFreeze()) {
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
index 97716f0a20fbc5f7048256ad1942e8f56e9fb72b..113ca1d16cb7650d72f488cdaa9e670d51dc85f0 100644
index d2648218d41439c4048901f2dbd59fe5eef57495..47f24e390efd8eb4cb7f62b5203825f4160772b7 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
@@ -321,6 +321,17 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
@@ -323,6 +323,17 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
return this.getHandle().isFullyFrozen();
}

Datei anzeigen

@ -6,7 +6,7 @@ Subject: [PATCH] Use a CHM for StructureTemplate.Pallete cache
fixes a CME due to this collection being shared across threads
diff --git a/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java b/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java
index 05ff5d2fc689af238003a381168bf64b51f0d65e..bd401b38239fb7e510f82f458f9336b7da372da0 100644
index 02b493435509f7a84a2c26050ca0c732ecf00ca0..33564e62e3181d28b18a957e28b8ec5152d8339f 100644
--- a/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java
+++ b/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java
@@ -859,7 +859,7 @@ public class StructureTemplate {

Datei anzeigen

@ -122,10 +122,10 @@ index 0000000000000000000000000000000000000000..e3a5f1ec376319bdfda87fa27ae217bf
+ }
+}
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index f61ea45fd39b2641dbab5e4a7e35c46c1639367d..4e6a3cb16a7f42e30ee210235f686f416d4c916d 100644
index 7707ecca5318e35533de93d4451cb62ba9b425b0..2e9f17fec09e060a2029a896d5d961a93a53118a 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -2148,6 +2148,13 @@ public final class CraftServer implements Server {
@@ -2151,6 +2151,13 @@ public final class CraftServer implements Server {
return this.console.console;
}

Datei anzeigen

@ -20,10 +20,10 @@ seeds/salts to the frequency reducer which has a similar effect.
Co-authored-by: William Blake Galbreath <blake.galbreath@gmail.com>
diff --git a/src/main/java/net/minecraft/world/level/chunk/ChunkGenerator.java b/src/main/java/net/minecraft/world/level/chunk/ChunkGenerator.java
index 748caca458eb4eec6ece22d8362e36de252f07dd..c4972e5767488878f7929226258c41c1cc30a47f 100644
index c5dd3aac54aa5936da4bd9f54f0e76ecf8141d27..102de569415ef011dacdca9a6ea8134d0ef62454 100644
--- a/src/main/java/net/minecraft/world/level/chunk/ChunkGenerator.java
+++ b/src/main/java/net/minecraft/world/level/chunk/ChunkGenerator.java
@@ -574,7 +574,7 @@ public abstract class ChunkGenerator {
@@ -573,7 +573,7 @@ public abstract class ChunkGenerator {
}
}

Datei anzeigen

@ -6,7 +6,7 @@ Subject: [PATCH] Implement regenerateChunk
Co-authored-by: Jason Penilla <11360596+jpenilla@users.noreply.github.com>
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
index a5121eb7fa8fccf7e742beea285c2f741ece513d..7e9344fdafb01030061458c55ccf6836bf643da3 100644
index 8d41492cd6305331deca3748eb24d689f23e280b..365a23218c57f9685c79b520d7721e5a49b7771c 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
@@ -151,6 +151,7 @@ import org.jetbrains.annotations.Nullable;

Datei anzeigen

@ -8,10 +8,10 @@ snow bucket didn't revert grass that became snowy because of the
placement.
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
index 1b062edcc04af4c500f38c1664b5cee25e265f3c..aa0a5b392942e03123b1dbd68ec8e9e1321457e9 100644
index ebc5f2e8d59da4bec25ff156ec95fe49366be59c..823146a66de8ce13e6dc6faf2fd135480bd51c3a 100644
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
@@ -401,7 +401,7 @@ public final class ItemStack implements DataComponentHolder {
@@ -422,7 +422,7 @@ public final class ItemStack implements DataComponentHolder {
int oldCount = this.getCount();
ServerLevel world = (ServerLevel) context.getLevel();
@ -20,7 +20,7 @@ index 1b062edcc04af4c500f38c1664b5cee25e265f3c..aa0a5b392942e03123b1dbd68ec8e9e1
world.captureBlockStates = true;
// special case bonemeal
if (item == Items.BONE_MEAL) {
@@ -461,7 +461,7 @@ public final class ItemStack implements DataComponentHolder {
@@ -482,7 +482,7 @@ public final class ItemStack implements DataComponentHolder {
world.capturedBlockStates.clear();
if (blocks.size() > 1) {
placeEvent = org.bukkit.craftbukkit.event.CraftEventFactory.callBlockMultiPlaceEvent(world, entityhuman, enumhand, blocks, blockposition.getX(), blockposition.getY(), blockposition.getZ());

Datei anzeigen

@ -6,10 +6,10 @@ 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 4e6a3cb16a7f42e30ee210235f686f416d4c916d..84760f00681e5493106daeec21aeef260dc11fb2 100644
index 2e9f17fec09e060a2029a896d5d961a93a53118a..01b37bc15d525f4a5ed4f9c45997c0029c032b3b 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -2325,6 +2325,8 @@ public final class CraftServer implements Server {
@@ -2328,6 +2328,8 @@ public final class CraftServer implements Server {
@Override
public int getSpawnLimit(SpawnCategory spawnCategory) {
// Paper start - Add mobcaps commands

Datei anzeigen

@ -46,10 +46,10 @@ index 0000000000000000000000000000000000000000..e7d9fd2702a1ce96596580fff8f5ee4f
+ }
+}
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 84760f00681e5493106daeec21aeef260dc11fb2..b6281c7dfe455b19d1016ea1d60de981228fb325 100644
index 01b37bc15d525f4a5ed4f9c45997c0029c032b3b..59bbc8dc5e5eb6cb87d15324bfad0a4014e47105 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -2753,6 +2753,15 @@ public final class CraftServer implements Server {
@@ -2761,6 +2761,15 @@ public final class CraftServer implements Server {
return (org.bukkit.Tag<T>) new CraftEntityTag(BuiltInRegistries.ENTITY_TYPE, entityTagKey);
}
}
@ -65,7 +65,7 @@ index 84760f00681e5493106daeec21aeef260dc11fb2..b6281c7dfe455b19d1016ea1d60de981
default -> throw new IllegalArgumentException();
}
@@ -2785,6 +2794,13 @@ public final class CraftServer implements Server {
@@ -2793,6 +2802,13 @@ public final class CraftServer implements Server {
net.minecraft.core.Registry<EntityType<?>> entityTags = BuiltInRegistries.ENTITY_TYPE;
return entityTags.getTags().map(pair -> (org.bukkit.Tag<T>) new CraftEntityTag(entityTags, pair.getFirst())).collect(ImmutableList.toImmutableList());
}

Datei anzeigen

@ -9,10 +9,10 @@ This might result in chunks loading far slower in the nether,
for example.
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index f295eaf2dced5bf294eb094f6d6110da826f053f..9f279ba3b3ed8a6cf4f79a41a1513b30d7ea9ccc 100644
index 22f8e49536658fabe6136dbeec6b77eaf4ae5ee8..e5017b66b6b8b5f17fc49f0fbc5d342241cd9cad 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -1343,6 +1343,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -1371,6 +1371,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
if (super.pollTask()) {
return true;
} else {
@ -20,7 +20,7 @@ index f295eaf2dced5bf294eb094f6d6110da826f053f..9f279ba3b3ed8a6cf4f79a41a1513b30
if (this.tickRateManager.isSprinting() || this.haveTime()) {
Iterator iterator = this.getAllLevels().iterator();
@@ -1350,12 +1351,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -1378,12 +1379,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
ServerLevel worldserver = (ServerLevel) iterator.next();
if (worldserver.getChunkSource().pollTask()) {

Datei anzeigen

@ -32,10 +32,10 @@ index 41ccbee5fc7767a7d5e1cdca0ec7d9a17ee80a90..1d28f117965da22694b12018923a5f13
}
diff --git a/src/main/java/net/minecraft/world/level/block/entity/SculkSensorBlockEntity.java b/src/main/java/net/minecraft/world/level/block/entity/SculkSensorBlockEntity.java
index afef108d11b4ed9ad9ce6069dd0d549720f3cb27..0c25d8b107b95e36e25f48dd82321b0961e468ea 100644
index bbaffdac7c2d3bd646133b36c5d450cba9fc0c07..a943ed46a5f593dfe612c9c797dc961e3e020506 100644
--- a/src/main/java/net/minecraft/world/level/block/entity/SculkSensorBlockEntity.java
+++ b/src/main/java/net/minecraft/world/level/block/entity/SculkSensorBlockEntity.java
@@ -25,6 +25,7 @@ public class SculkSensorBlockEntity extends BlockEntity implements GameEventList
@@ -26,6 +26,7 @@ public class SculkSensorBlockEntity extends BlockEntity implements GameEventList
private final VibrationSystem.Listener vibrationListener;
private final VibrationSystem.User vibrationUser = this.createVibrationUser();
public int lastVibrationFrequency;
@ -43,8 +43,8 @@ index afef108d11b4ed9ad9ce6069dd0d549720f3cb27..0c25d8b107b95e36e25f48dd82321b09
protected SculkSensorBlockEntity(BlockEntityType<?> type, BlockPos pos, BlockState state) {
super(type, pos, state);
@@ -50,8 +51,16 @@ public class SculkSensorBlockEntity extends BlockEntity implements GameEventList
.resultOrPartial(LOGGER::error)
@@ -52,8 +53,16 @@ public class SculkSensorBlockEntity extends BlockEntity implements GameEventList
.resultOrPartial(string -> LOGGER.error("Failed to parse vibration listener for Sculk Sensor: '{}'", string))
.ifPresent(listener -> this.vibrationData = listener);
}
+ // Paper start - Configurable sculk sensor listener range
@ -60,9 +60,9 @@ index afef108d11b4ed9ad9ce6069dd0d549720f3cb27..0c25d8b107b95e36e25f48dd82321b09
@Override
protected void saveAdditional(CompoundTag nbt, HolderLookup.Provider registryLookup) {
super.saveAdditional(nbt, registryLookup);
@@ -60,7 +69,13 @@ public class SculkSensorBlockEntity extends BlockEntity implements GameEventList
.encodeStart(NbtOps.INSTANCE, this.vibrationData)
.resultOrPartial(LOGGER::error)
@@ -63,7 +72,13 @@ public class SculkSensorBlockEntity extends BlockEntity implements GameEventList
.encodeStart(registryOps, this.vibrationData)
.resultOrPartial(string -> LOGGER.error("Failed to encode vibration listener for Sculk Sensor: '{}'", string))
.ifPresent(listenerNbt -> nbt.put("listener", listenerNbt));
+ this.saveRangeOverride(nbt); // Paper - Configurable sculk sensor listener range
+ }
@ -74,7 +74,7 @@ index afef108d11b4ed9ad9ce6069dd0d549720f3cb27..0c25d8b107b95e36e25f48dd82321b09
@Override
public VibrationSystem.Data getVibrationData() {
@@ -97,6 +112,7 @@ public class SculkSensorBlockEntity extends BlockEntity implements GameEventList
@@ -100,6 +115,7 @@ public class SculkSensorBlockEntity extends BlockEntity implements GameEventList
@Override
public int getListenerRadius() {

Datei anzeigen

@ -10,10 +10,10 @@ just looking at the LevelStem key, look at the DimensionType key which
is one level below that. Defaults to off to keep vanilla behavior.
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index 9f279ba3b3ed8a6cf4f79a41a1513b30d7ea9ccc..235886ef53d259622ee920fc70d089279d933f29 100644
index e5017b66b6b8b5f17fc49f0fbc5d342241cd9cad..f979bfd78e2d19b525e973be0ffef5bda0068c4b 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -625,7 +625,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -632,7 +632,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
this.commandStorage = new CommandStorage(worldpersistentdata);
} else {
ChunkProgressListener worldloadlistener = this.progressListenerFactory.create(this.worldData.getGameRules().getInt(GameRules.RULE_SPAWN_CHUNK_RADIUS));

Datei anzeigen

@ -7,10 +7,10 @@ Some parts of legacy conversion will need the overworld
to get the legacy structure data storage
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index 235886ef53d259622ee920fc70d089279d933f29..4fcd06f188ae23d1bb6f6ee1840c0103e018f4c2 100644
index f979bfd78e2d19b525e973be0ffef5bda0068c4b..833ec409e3f79e1ae2b664418f219adb3af2957f 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -637,9 +637,10 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -644,9 +644,10 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
}
worlddata.setModdedInfo(this.getServerModName(), this.getModdedStatus().shouldReportAsModified());
@ -23,10 +23,10 @@ index 235886ef53d259622ee920fc70d089279d933f29..4fcd06f188ae23d1bb6f6ee1840c0103
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 b6281c7dfe455b19d1016ea1d60de981228fb325..4534e1398cf90ef0f697fc327e9fa010313d9cb7 100644
index 59bbc8dc5e5eb6cb87d15324bfad0a4014e47105..7d63eaff7fb788b5b5052fe24a1f14c9542bcce3 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -1320,10 +1320,11 @@ public final class CraftServer implements Server {
@@ -1323,10 +1323,11 @@ public final class CraftServer implements Server {
return null;
}

Datei anzeigen

@ -96,10 +96,10 @@ index 0000000000000000000000000000000000000000..7ea357ac2f3a93db4ebdf24b5072be7d
+ }
+}
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index 4fcd06f188ae23d1bb6f6ee1840c0103e018f4c2..0420e92207a8b106d9b70f92774b21bb1dc19b25 100644
index 833ec409e3f79e1ae2b664418f219adb3af2957f..29011d222434cbb2c71797786b8376ea37c8023a 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -2138,6 +2138,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -2166,6 +2166,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
this.worldData.setDataConfiguration(worlddataconfiguration);
this.resources.managers.updateRegistryTags();
@ -108,7 +108,7 @@ index 4fcd06f188ae23d1bb6f6ee1840c0103e018f4c2..0420e92207a8b106d9b70f92774b21bb
this.getPlayerList().reloadResources();
this.functionManager.replaceLibrary(this.resources.managers.getFunctionLibrary());
diff --git a/src/main/java/net/minecraft/world/inventory/BrewingStandMenu.java b/src/main/java/net/minecraft/world/inventory/BrewingStandMenu.java
index 8be4e04df480faaa3aac516012709e9ff852f8a5..ed3ea6d19a0f0586034574d04332be4312c601b9 100644
index a7c33675c3777cfbeeecbb3a123a0b03195e679c..93c4657f345b6d3442b1f2ab17b2703ded86b525 100644
--- a/src/main/java/net/minecraft/world/inventory/BrewingStandMenu.java
+++ b/src/main/java/net/minecraft/world/inventory/BrewingStandMenu.java
@@ -53,9 +53,11 @@ public class BrewingStandMenu extends AbstractContainerMenu {
@ -263,10 +263,10 @@ index 50e81e3babd331077eda8daa769eb2b3f99e8ca2..ca01f3344005b295c7ae98f6d5b03f79
private final List<Ingredient> containers = new ArrayList<>();
private final List<PotionBrewing.Mix<Potion>> potionMixes = new ArrayList<>();
diff --git a/src/main/java/net/minecraft/world/level/block/entity/BrewingStandBlockEntity.java b/src/main/java/net/minecraft/world/level/block/entity/BrewingStandBlockEntity.java
index 3ebfd564d4bbf00da5919e966f3d047285845640..887957ce1ddc2f32569405642f35df468c08271f 100644
index c8f9972ad1c2330908cc840d426f29c20b242ca8..a2fafef89d5354e2cb02f5672810909950a57777 100644
--- a/src/main/java/net/minecraft/world/level/block/entity/BrewingStandBlockEntity.java
+++ b/src/main/java/net/minecraft/world/level/block/entity/BrewingStandBlockEntity.java
@@ -311,12 +311,12 @@ public class BrewingStandBlockEntity extends BaseContainerBlockEntity implements
@@ -315,12 +315,12 @@ public class BrewingStandBlockEntity extends BaseContainerBlockEntity implements
@Override
public boolean canPlaceItem(int slot, ItemStack stack) {
@ -282,10 +282,10 @@ index 3ebfd564d4bbf00da5919e966f3d047285845640..887957ce1ddc2f32569405642f35df46
}
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 4534e1398cf90ef0f697fc327e9fa010313d9cb7..0990c02fb8826f47a1f12617042f71790248e7b1 100644
index 7d63eaff7fb788b5b5052fe24a1f14c9542bcce3..89163d43fcf16c39721da9925beb8a7a23daf291 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -306,6 +306,7 @@ public final class CraftServer implements Server {
@@ -308,6 +308,7 @@ public final class CraftServer implements Server {
private final io.papermc.paper.datapack.PaperDatapackManager datapackManager; // Paper
public static Exception excessiveVelEx; // Paper - Velocity warnings
private final io.papermc.paper.logging.SysoutCatcher sysoutCatcher = new io.papermc.paper.logging.SysoutCatcher(); // Paper
@ -293,7 +293,7 @@ index 4534e1398cf90ef0f697fc327e9fa010313d9cb7..0990c02fb8826f47a1f12617042f7179
static {
ConfigurationSerialization.registerClass(CraftOfflinePlayer.class);
@@ -388,6 +389,7 @@ public final class CraftServer implements Server {
@@ -391,6 +392,7 @@ public final class CraftServer implements Server {
if (this.configuration.getBoolean("settings.use-map-color-cache")) {
MapPalette.setMapColorCache(new CraftMapColorCache(this.logger));
}
@ -301,7 +301,7 @@ index 4534e1398cf90ef0f697fc327e9fa010313d9cb7..0990c02fb8826f47a1f12617042f7179
datapackManager = new io.papermc.paper.datapack.PaperDatapackManager(console.getPackRepository()); // Paper
}
@@ -3116,5 +3118,9 @@ public final class CraftServer implements Server {
@@ -3124,5 +3126,9 @@ public final class CraftServer implements Server {
return datapackManager;
}

Datei anzeigen

@ -10,11 +10,11 @@ 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 7406784899ba5f3575adf1ffe5e5d85ab430a841..9fc053e2f6f3bbd9c17fda5679322a0fb403b7fe 100644
index 2944ec6fd810957e6c01cf914b48d58235a1822c..11ac1a4e2cc276b9817014b8bb6a454e282d6258 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -400,6 +400,16 @@ public abstract class PlayerList {
}
@@ -394,6 +394,16 @@ public abstract class PlayerList {
this.sendActivePlayerEffects(player);
// Paper start - Fire PlayerJoinEvent when Player is actually ready; move vehicle into method so it can be called above - short circuit around that code
this.onPlayerJoinFinish(player, worldserver1, s1);
+ // Paper start - Send empty chunk, so players aren't stuck in the world loading screen with our chunk system not sending chunks when dead

Datei anzeigen

@ -11,7 +11,7 @@ Restores the API behavior from previous versions of the server
public net.minecraft.world.entity.item.FallingBlockEntity <init>(Lnet/minecraft/world/level/Level;DDDLnet/minecraft/world/level/block/state/BlockState;)V
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
index 7e9344fdafb01030061458c55ccf6836bf643da3..a9106f4777d05928d432e14e4998fd06df5a0786 100644
index 365a23218c57f9685c79b520d7721e5a49b7771c..339c2d844126b287adf613a5be1b90f2056dabd9 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
@@ -1450,7 +1450,12 @@ public class CraftWorld extends CraftRegionAccessor implements World {
@ -43,10 +43,10 @@ index 7e9344fdafb01030061458c55ccf6836bf643da3..a9106f4777d05928d432e14e4998fd06
}
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntityTypes.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntityTypes.java
index abcfb3accb715a5a041de4b798cf3582d1fde325..7ba6302ecb72fa6e523054e7e3223d79eedf6589 100644
index 481f0c62fcd4435d655cfe2f94f46262b24a7144..37527713b0afa6db19eefd57aaffcb2fe3544ce6 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntityTypes.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntityTypes.java
@@ -386,7 +386,7 @@ public final class CraftEntityTypes {
@@ -387,7 +387,7 @@ public final class CraftEntityTypes {
register(new EntityTypeData<>(EntityType.TNT, TNTPrimed.class, CraftTNTPrimed::new, spawnData -> new PrimedTnt(spawnData.minecraftWorld(), spawnData.x(), spawnData.y(), spawnData.z(), null)));
register(new EntityTypeData<>(EntityType.FALLING_BLOCK, FallingBlock.class, CraftFallingBlock::new, spawnData -> {
BlockPos pos = BlockPos.containing(spawnData.x(), spawnData.y(), spawnData.z());

Datei anzeigen

@ -15,10 +15,10 @@ piercing arrows to avoid duplicate damage being applied.
protected net.minecraft.world.entity.projectile.Projectile hitCancelled
diff --git a/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java b/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java
index 427e889f58c86f7649fc1b661d55277599b320c0..f1bf129aecb6840d79c537338e4057557f07790b 100644
index 92b630475ef7032c9cae6288b2a0370562e25f57..dfa44899529a7a9c32fe17fcb2091eab7d790f5a 100644
--- a/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java
+++ b/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java
@@ -305,6 +305,19 @@ public abstract class AbstractArrow extends Projectile {
@@ -322,6 +322,19 @@ public abstract class AbstractArrow extends Projectile {
}
}

Datei anzeigen

@ -24,16 +24,16 @@ Co-authored-by: Nassim Jahnke <nassim@njahnke.dev>
Co-authored-by: SoSeDiK <mrsosedik@gmail.com>
diff --git a/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java b/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java
index 7d557c7ec6fb1763395f4920a170bd4e4ba6747f..e603307871b623ce437f4b1b68ab306fbdd9919d 100644
index 5b7734020b496ade3740d92908ad2d399bfd55e6..e70ca1b2e6fbbc1f20e65429298d01b4ebd2dd29 100644
--- a/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java
+++ b/src/main/java/net/minecraft/world/entity/projectile/FishingHook.java
@@ -413,13 +413,18 @@ public class FishingHook extends Projectile {
@@ -414,13 +414,18 @@ public class FishingHook extends Projectile {
}
} else {
// CraftBukkit start - logic to modify fishing wait time
- this.timeUntilLured = Mth.nextInt(this.random, this.minWaitTime, this.maxWaitTime);
- this.timeUntilLured -= (this.applyLure) ? (this.lureSpeed * 20 * 5 >= this.maxWaitTime ? this.timeUntilLured - 1 : this.lureSpeed * 20 * 5) : 0; // Paper - Fix Lure infinite loop
+ resetTimeUntilLured(); // Paper - more projectile api - extract time until lured reset logic
- this.timeUntilLured -= (this.applyLure) ? (this.lureSpeed >= this.maxWaitTime ? this.timeUntilLured - 1 : this.lureSpeed ) : 0; // Paper - Fix Lure infinite loop
+ this.resetTimeUntilLured(); // Paper - more projectile api - extract time until lured reset logic
// CraftBukkit end
}
}
@ -42,17 +42,17 @@ index 7d557c7ec6fb1763395f4920a170bd4e4ba6747f..e603307871b623ce437f4b1b68ab306f
+ // Paper start - more projectile api - extract time until lured reset logic
+ public void resetTimeUntilLured() {
+ this.timeUntilLured = Mth.nextInt(this.random, this.minWaitTime, this.maxWaitTime);
+ this.timeUntilLured -= (this.applyLure) ? (this.lureSpeed * 20 * 5 >= this.maxWaitTime ? this.timeUntilLured - 1 : this.lureSpeed * 20 * 5) : 0; // Paper - Fix Lure infinite loop
+ this.timeUntilLured -= (this.applyLure) ? (this.lureSpeed >= this.maxWaitTime ? this.timeUntilLured - 1 : this.lureSpeed ) : 0; // Paper - Fix Lure infinite loop
+ }
+ // Paper end - more projectile api - extract time until lured reset logic
public boolean calculateOpenWater(BlockPos pos) {
FishingHook.OpenWaterType entityfishinghook_waterposition = FishingHook.OpenWaterType.INVALID;
diff --git a/src/main/java/net/minecraft/world/entity/projectile/Projectile.java b/src/main/java/net/minecraft/world/entity/projectile/Projectile.java
index 40348e45b02be9a0b397a883940a476fb6738ef4..ccb7aa341e3087255bce1f6fb953d33584147fd3 100644
index 7863625d49baa13ea87f2ee295b16706071fb960..ff6007bbf8361db7967b6bf621b27a1d23102e77 100644
--- a/src/main/java/net/minecraft/world/entity/projectile/Projectile.java
+++ b/src/main/java/net/minecraft/world/entity/projectile/Projectile.java
@@ -180,7 +180,7 @@ public abstract class Projectile extends Entity implements TraceableEntity {
@@ -187,7 +187,7 @@ public abstract class Projectile extends Entity implements TraceableEntity {
}
// CraftBukkit start - call projectile hit event
@ -62,10 +62,10 @@ index 40348e45b02be9a0b397a883940a476fb6738ef4..ccb7aa341e3087255bce1f6fb953d335
this.hitCancelled = event != null && event.isCancelled();
if (movingobjectposition.getType() == HitResult.Type.BLOCK || !this.hitCancelled) {
diff --git a/src/main/java/net/minecraft/world/entity/projectile/ThrownPotion.java b/src/main/java/net/minecraft/world/entity/projectile/ThrownPotion.java
index bf627d66310f201172d3cd3ea12f1d321cd3cd62..5adaeb59f7733809f1cf6b52031292c9611a3a86 100644
index cb34cc9443da56c0497c7a0192c8b8363c3426fe..58dc69fe319027c2b9ecfb9caf272368e81081df 100644
--- a/src/main/java/net/minecraft/world/entity/projectile/ThrownPotion.java
+++ b/src/main/java/net/minecraft/world/entity/projectile/ThrownPotion.java
@@ -100,6 +100,11 @@ public class ThrownPotion extends ThrowableItemProjectile implements ItemSupplie
@@ -102,6 +102,11 @@ public class ThrownPotion extends ThrowableItemProjectile implements ItemSupplie
@Override
protected void onHit(HitResult hitResult) {
super.onHit(hitResult);
@ -77,7 +77,7 @@ index bf627d66310f201172d3cd3ea12f1d321cd3cd62..5adaeb59f7733809f1cf6b52031292c9
if (!this.level().isClientSide) {
ItemStack itemstack = this.getItem();
PotionContents potioncontents = (PotionContents) itemstack.getOrDefault(DataComponents.POTION_CONTENTS, PotionContents.EMPTY);
@@ -111,7 +116,7 @@ public class ThrownPotion extends ThrowableItemProjectile implements ItemSupplie
@@ -113,7 +118,7 @@ public class ThrownPotion extends ThrowableItemProjectile implements ItemSupplie
if (this.isLingering()) {
showParticles = this.makeAreaOfEffectCloud(potioncontents, hitResult); // CraftBukkit - Pass MovingObjectPosition // Paper
} else {
@ -86,7 +86,7 @@ index bf627d66310f201172d3cd3ea12f1d321cd3cd62..5adaeb59f7733809f1cf6b52031292c9
}
}
@@ -173,7 +178,7 @@ public class ThrownPotion extends ThrowableItemProjectile implements ItemSupplie
@@ -175,7 +180,7 @@ public class ThrownPotion extends ThrowableItemProjectile implements ItemSupplie
}
@ -95,7 +95,7 @@ index bf627d66310f201172d3cd3ea12f1d321cd3cd62..5adaeb59f7733809f1cf6b52031292c9
AABB axisalignedbb = this.getBoundingBox().inflate(4.0D, 2.0D, 4.0D);
List<net.minecraft.world.entity.LivingEntity> list = this.level().getEntitiesOfClass(net.minecraft.world.entity.LivingEntity.class, axisalignedbb);
Map<LivingEntity, Double> affected = new HashMap<LivingEntity, Double>(); // CraftBukkit
@@ -251,7 +256,7 @@ public class ThrownPotion extends ThrowableItemProjectile implements ItemSupplie
@@ -253,7 +258,7 @@ public class ThrownPotion extends ThrowableItemProjectile implements ItemSupplie
}
@ -175,10 +175,10 @@ index 91c2d0b40d3fca86938cd454e1415a4eea3df7c7..de4fb2654c7895cfd83ad694455ee56c
+ // Paper end - More projectile API
}
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftAbstractArrow.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftAbstractArrow.java
index 98f46fadd60ea688fefa8d83dbd6fe9b61b6a96f..0cc1cdf91deb07ebb437ef5e61d149b2c109877f 100644
index 329ca9c743a7f2feeabbfb769ff9a71f60165006..b095642d0e0ed3e61590d362ce991ff2065b5b78 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftAbstractArrow.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftAbstractArrow.java
@@ -60,20 +60,7 @@ public class CraftAbstractArrow extends AbstractProjectile implements AbstractAr
@@ -58,20 +58,7 @@ public class CraftAbstractArrow extends AbstractProjectile implements AbstractAr
this.getHandle().setCritArrow(critical);
}
@ -200,7 +200,7 @@ index 98f46fadd60ea688fefa8d83dbd6fe9b61b6a96f..0cc1cdf91deb07ebb437ef5e61d149b2
@Override
public boolean isInBlock() {
@@ -140,4 +127,31 @@ public class CraftAbstractArrow extends AbstractProjectile implements AbstractAr
@@ -149,4 +136,31 @@ public class CraftAbstractArrow extends AbstractProjectile implements AbstractAr
public String toString() {
return "CraftArrow";
}
@ -307,10 +307,10 @@ index 5232fbef0d014edd32a5d18d4a1500ab215313f5..071be344c3265a0cd52b31ffbb02ff7a
}
}
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntityTypes.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntityTypes.java
index 7ba6302ecb72fa6e523054e7e3223d79eedf6589..907904da7f89e8e5e5cfab80977f04af3fdf17c7 100644
index 37527713b0afa6db19eefd57aaffcb2fe3544ce6..46a4f31e2b6eee6f8dc5f8fccd7de4c48a698b61 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntityTypes.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntityTypes.java
@@ -388,7 +388,7 @@ public final class CraftEntityTypes {
@@ -389,7 +389,7 @@ public final class CraftEntityTypes {
BlockPos pos = BlockPos.containing(spawnData.x(), spawnData.y(), spawnData.z());
return new FallingBlockEntity(spawnData.minecraftWorld(), spawnData.x(), spawnData.y(), spawnData.z(), spawnData.world().getBlockState(pos)); // Paper - create falling block entities correctly
}));
@ -320,10 +320,10 @@ index 7ba6302ecb72fa6e523054e7e3223d79eedf6589..907904da7f89e8e5e5cfab80977f04af
register(new EntityTypeData<>(EntityType.COMMAND_BLOCK_MINECART, CommandMinecart.class, CraftMinecartCommand::new, spawnData -> new MinecartCommandBlock(spawnData.minecraftWorld(), spawnData.x(), spawnData.y(), spawnData.z())));
register(new EntityTypeData<>(EntityType.MINECART, RideableMinecart.class, CraftMinecartRideable::new, spawnData -> new Minecart(spawnData.minecraftWorld(), spawnData.x(), spawnData.y(), spawnData.z())));
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftFireball.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftFireball.java
index b0a02c9ca4349ab56ceceae8b78559e20a9b0af5..297b7e592caa2a05e1fb18a3ad22a91ae7621f5d 100644
index 1b084d63bdbb24dad45d28eed1693eb6e26e24dc..43d7bea201a52cfeacf60c75caa28dfd2c4ff164 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftFireball.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftFireball.java
@@ -33,20 +33,7 @@ public class CraftFireball extends AbstractProjectile implements Fireball {
@@ -34,20 +34,7 @@ public class CraftFireball extends AbstractProjectile implements Fireball {
this.getHandle().bukkitYield = yield;
}
@ -500,10 +500,10 @@ index 6e2f91423371ead9890095cf4b1e2299c4dcba28..9d8f4b7176e60180565e3134a14ecf19
+ // Paper end
}
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
index 00cac0c83897221fd4a83dcee884db751321af2e..88cd49128a19efee6bf20dcfdcfda4b9bd5e4808 100644
index fe3304a40f2aaf84db825374f4b3d495d31f91ad..2afa23d5e98e618b7220c9203d24ca5628db2efc 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
@@ -647,7 +647,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
@@ -649,7 +649,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
} else if (Firework.class.isAssignableFrom(projectile)) {
Location location = this.getEyeLocation();
@ -682,10 +682,10 @@ index e374b9f40eddca13b30855d25a2030f8df98138f..4fc893378fb0568ddcffc7593d66df6b
// Paper end
}
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
index efc3808dde268f8325304f4bce8fb3bf399adafd..9588c191ccb5665be2ff90ae2ded5bbff12faacb 100644
index e0c1eab089fff724e029ed8109a653403e15fc77..877990d391432f144e0013679aca8c9cfebda03d 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -832,19 +832,19 @@ public class CraftEventFactory {
@@ -833,19 +833,19 @@ public class CraftEventFactory {
/**
* PotionSplashEvent
*/
@ -708,7 +708,7 @@ index efc3808dde268f8325304f4bce8fb3bf399adafd..9588c191ccb5665be2ff90ae2ded5bbf
hitEntity = ((EntityHitResult) position).getEntity().getBukkitEntity();
}
@@ -853,20 +853,20 @@ public class CraftEventFactory {
@@ -854,20 +854,20 @@ public class CraftEventFactory {
return event;
}
@ -733,7 +733,7 @@ index efc3808dde268f8325304f4bce8fb3bf399adafd..9588c191ccb5665be2ff90ae2ded5bbf
}
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
index 92faa15f79f0541048e29254dcf3560616d3c0e7..2a7996f5cfb1eacf098e73f35bafc4327b041c51 100644
index 9cf035486cedfc2e3ba522416e8fea3ad01cfec5..80423156c5582b07911561d29ec494dc03a57f07 100644
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
@@ -295,12 +295,22 @@ public final class CraftItemStack extends ItemStack {

Datei anzeigen

@ -10,10 +10,10 @@ indefinitely. Instead of using the world state, we use the already
supplied ServerLevelAccessor which will always have the chunk available.
diff --git a/src/main/java/net/minecraft/world/entity/animal/Cat.java b/src/main/java/net/minecraft/world/entity/animal/Cat.java
index 951b7f252e67b29092964019bb3463cb00e497e3..b5f13d1bf1cccb9a15d8956f68c960e25098dc98 100644
index f0e5428394f8de8f7ac05b8cbc34826d153eeaef..d44807c16712afd37efdbf434d1afb12a7c3d343 100644
--- a/src/main/java/net/minecraft/world/entity/animal/Cat.java
+++ b/src/main/java/net/minecraft/world/entity/animal/Cat.java
@@ -367,7 +367,7 @@ public class Cat extends TamableAnimal implements VariantHolder<Holder<CatVarian
@@ -357,7 +357,7 @@ public class Cat extends TamableAnimal implements VariantHolder<Holder<CatVarian
BuiltInRegistries.CAT_VARIANT.getRandomElementOf(tagkey, world.getRandom()).ifPresent(this::setVariant);
ServerLevel worldserver = world.getLevel();

Datei anzeigen

@ -7,12 +7,12 @@ 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 4ac3e9cacc3c54a67da1547a319fd501ff375354..eec6765f0885994791e6b09cd731bb275ceb286b 100644
index c616ebd8d5c2b2e580772f87174cb22827cc5e90..68571261c7095b9477d09536b69272eea7137e64 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -484,6 +484,11 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
this.disconnect(Component.translatable("multiplayer.disconnect.invalid_vehicle_movement"), org.bukkit.event.player.PlayerKickEvent.Cause.INVALID_VEHICLE_MOVEMENT); // Paper - kick event cause
} else {
this.disconnect((Component) Component.translatable("multiplayer.disconnect.invalid_vehicle_movement"), org.bukkit.event.player.PlayerKickEvent.Cause.INVALID_VEHICLE_MOVEMENT); // Paper - kick event cause
} else if (!this.updateAwaitingTeleport()) {
Entity entity = this.player.getRootVehicle();
+ // Paper start - Don't allow vehicle movement from players while teleporting
+ if (this.awaitingPositionFromClient != null || this.player.isImmobile() || entity.isRemoved()) {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Implement getComputedBiome API
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java
index 54a79d802806d5354db74d27c04458e8baedfa0c..4cacc8a8f5d04ea0e1f087194481fa749efa1797 100644
index 5d137f8c42356359701e1bea7525f82c018b502c..f6dd8665b9f6e2a8ff396deba8a021e695bedf7e 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java
@@ -76,6 +76,13 @@ public abstract class CraftRegionAccessor implements RegionAccessor {
@@ -77,6 +77,13 @@ public abstract class CraftRegionAccessor implements RegionAccessor {
return CraftBiome.minecraftHolderToBukkit(this.getHandle().getNoiseBiome(x >> 2, y >> 2, z >> 2));
}

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Implement enchantWithLevels API
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java
index be31b8a286794508a1c1bfcf3da0ac64c0383c60..b0d73a9412421d86bd244757806d58fd99687163 100644
index 31a33e329ee06860f8845d201d32ee86a274a657..e1605d97bbcdbb8903d78848c7b98b44fec34705 100644
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java
@@ -594,4 +594,26 @@ public final class CraftItemFactory implements ItemFactory {
@@ -605,4 +605,26 @@ public final class CraftItemFactory implements ItemFactory {
return eggItem == null ? null : new net.minecraft.world.item.ItemStack(eggItem).asBukkitMirror();
}
// Paper end - old getSpawnEgg API

Datei anzeigen

@ -6,10 +6,10 @@ 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 0990c02fb8826f47a1f12617042f71790248e7b1..60441fbe87fed55d76967b7e709a21f462f4f511 100644
index 89163d43fcf16c39721da9925beb8a7a23daf291..9744e466489be575ac736aaba4b6a48f40b74d62 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -1369,7 +1369,7 @@ public final class CraftServer implements Server {
@@ -1372,7 +1372,7 @@ public final class CraftServer implements Server {
try {
if (save) {

Datei anzeigen

@ -13,10 +13,10 @@ we'll also only gen a trace for the first one, I see no real pressing need
to generate more, given that that would *massively* negate this patch otherwise
diff --git a/src/main/java/net/minecraft/server/level/WorldGenRegion.java b/src/main/java/net/minecraft/server/level/WorldGenRegion.java
index 744efc6cdc99f653a1eb9d4f26af8a7c34627f5e..68a6572da2acf2ea2e6996e653a0ffe405846575 100644
index 421f146ea9c35b852251c0ddb29856c13e11aef3..13229388ddce668061a34c787ab9586d41854d8a 100644
--- a/src/main/java/net/minecraft/server/level/WorldGenRegion.java
+++ b/src/main/java/net/minecraft/server/level/WorldGenRegion.java
@@ -283,6 +283,7 @@ public class WorldGenRegion implements WorldGenLevel {
@@ -284,6 +284,7 @@ public class WorldGenRegion implements WorldGenLevel {
}
}
@ -24,13 +24,13 @@ index 744efc6cdc99f653a1eb9d4f26af8a7c34627f5e..68a6572da2acf2ea2e6996e653a0ffe4
@Override
public boolean ensureCanWrite(BlockPos pos) {
int i = SectionPos.blockToSectionCoord(pos.getX());
@@ -302,7 +303,15 @@ public class WorldGenRegion implements WorldGenLevel {
@@ -303,7 +304,15 @@ public class WorldGenRegion implements WorldGenLevel {
return true;
} else {
+ // Paper start - Buffer OOB setBlock calls
+ if (!hasSetFarWarned) {
Util.logAndPauseIfInIde("Detected setBlock in a far chunk [" + i + ", " + j + "], pos: " + String.valueOf(pos) + ", status: " + String.valueOf(this.generatingStatus) + (this.currentlyGenerating == null ? "" : ", currently generating: " + (String) this.currentlyGenerating.get()));
Util.logAndPauseIfInIde("Detected setBlock in a far chunk [" + i + ", " + j + "], pos: " + String.valueOf(pos) + ", status: " + String.valueOf(this.generatingStep.targetStatus()) + (this.currentlyGenerating == null ? "" : ", currently generating: " + (String) this.currentlyGenerating.get()));
+ hasSetFarWarned = true;
+ if (this.getServer() != null && this.getServer().isDebugging()) {
+ io.papermc.paper.util.TraceUtil.dumpTraceForThread("far setBlock call");

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Add TameableDeathMessageEvent
diff --git a/src/main/java/net/minecraft/world/entity/TamableAnimal.java b/src/main/java/net/minecraft/world/entity/TamableAnimal.java
index 8c387df4d1e0b714edb07f177e85fe2ec4706b2a..ed2514de46d0939259ca4e45a6dc96d7c1dac20d 100644
index f2d311a5450eb684603580bbf7e9e7fc73fc2f5c..07ec4837d17a9cb7db2fa310a42fc87e052b3f9b 100644
--- a/src/main/java/net/minecraft/world/entity/TamableAnimal.java
+++ b/src/main/java/net/minecraft/world/entity/TamableAnimal.java
@@ -196,7 +196,12 @@ public abstract class TamableAnimal extends Animal implements OwnableEntity {
@@ -237,7 +237,12 @@ public abstract class TamableAnimal extends Animal implements OwnableEntity {
@Override
public void die(DamageSource damageSource) {
if (!this.level().isClientSide && this.level().getGameRules().getBoolean(GameRules.RULE_SHOWDEATHMESSAGES) && this.getOwner() instanceof ServerPlayer) {

Datei anzeigen

@ -65,10 +65,10 @@ index f4bc556e245179d0a4710e5255dd289aaafdceb7..d802985f1431be4332c07f0dab88feeb
this.level.setBlock(blockposition1, Blocks.DIRT.defaultBlockState(), 2);
}
diff --git a/src/main/java/net/minecraft/world/entity/animal/Rabbit.java b/src/main/java/net/minecraft/world/entity/animal/Rabbit.java
index 8feb886acf3b60356f1cba9e09a0cdea9ea8266a..b58300e114e2e27ac68d7a9489bc52b127c9bc17 100644
index e5bd3039ef698fcea80a270b6111c2a663e5075c..0109c8ed8bf6a053674456fa4473934e028ca418 100644
--- a/src/main/java/net/minecraft/world/entity/animal/Rabbit.java
+++ b/src/main/java/net/minecraft/world/entity/animal/Rabbit.java
@@ -577,7 +577,7 @@ public class Rabbit extends Animal implements VariantHolder<Rabbit.Variant> {
@@ -581,7 +581,7 @@ public class Rabbit extends Animal implements VariantHolder<Rabbit.Variant> {
if (i == 0) {
// CraftBukkit start
@ -78,7 +78,7 @@ index 8feb886acf3b60356f1cba9e09a0cdea9ea8266a..b58300e114e2e27ac68d7a9489bc52b1
}
// CraftBukkit end
diff --git a/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java b/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java
index b5cb4e4682f66ac9423af8d1547d0f1a4f9e6c5d..aa22829c3d41118664a872540fdc8f716120c407 100644
index 3cd4a744c3e3aeba90f342de9dea67ef2f3de626..1b49090a466bc74d9e5f2815314955b6dfbb83dc 100644
--- a/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java
+++ b/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java
@@ -377,7 +377,7 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
@ -91,10 +91,10 @@ index b5cb4e4682f66ac9423af8d1547d0f1a4f9e6c5d..aa22829c3d41118664a872540fdc8f71
}
// CraftBukkit end
diff --git a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
index 57f84a0eccbdb051adddc25a1a7126f60c7c274b..260202fab3ac300552c557b44dcf251f083c6a78 100644
index 7caa5469a4daa5d0c569f446ff2d597a9f10e8ac..828c51477cd8f35d591367b30bf4feef6a250292 100644
--- a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
+++ b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
@@ -563,7 +563,7 @@ public class EnderMan extends Monster implements NeutralMob {
@@ -565,7 +565,7 @@ public class EnderMan extends Monster implements NeutralMob {
boolean flag = movingobjectpositionblock.getBlockPos().equals(blockposition);
if (iblockdata.is(BlockTags.ENDERMAN_HOLDABLE) && flag) {
@ -104,10 +104,10 @@ index 57f84a0eccbdb051adddc25a1a7126f60c7c274b..260202fab3ac300552c557b44dcf251f
world.gameEvent((Holder) GameEvent.BLOCK_DESTROY, blockposition, GameEvent.Context.of(this.enderman, iblockdata));
this.enderman.setCarriedBlock(iblockdata.getBlock().defaultBlockState());
diff --git a/src/main/java/net/minecraft/world/entity/monster/Ravager.java b/src/main/java/net/minecraft/world/entity/monster/Ravager.java
index cec801ba14bed8b043b2375f1bf9e7811a63e995..2d7b7c949faaaaae94c0043132a4a822f55df104 100644
index aa4111eef22546f8aa630228c51ef5761c9b373b..212d341425c0f93bba0376de69bea61ffcf4dbd6 100644
--- a/src/main/java/net/minecraft/world/entity/monster/Ravager.java
+++ b/src/main/java/net/minecraft/world/entity/monster/Ravager.java
@@ -150,7 +150,7 @@ public class Ravager extends Raider {
@@ -151,7 +151,7 @@ public class Ravager extends Raider {
if (block instanceof LeavesBlock) {
// CraftBukkit start
@ -131,10 +131,10 @@ index 9ff42b0ae2b82dc3092e38e1439d89b4ab554b17..860e385fc83f9787dca92efe35d21fd6
}
// CraftBukkit end
diff --git a/src/main/java/net/minecraft/world/entity/projectile/ThrownPotion.java b/src/main/java/net/minecraft/world/entity/projectile/ThrownPotion.java
index 5adaeb59f7733809f1cf6b52031292c9611a3a86..d8ac724d01d81b8c52f8e05451212ac1cd775c0b 100644
index 58dc69fe319027c2b9ecfb9caf272368e81081df..5c6cb752f61c3f3c2960a337173fb7dfe86cc1d3 100644
--- a/src/main/java/net/minecraft/world/entity/projectile/ThrownPotion.java
+++ b/src/main/java/net/minecraft/world/entity/projectile/ThrownPotion.java
@@ -290,7 +290,7 @@ public class ThrownPotion extends ThrowableItemProjectile implements ItemSupplie
@@ -292,7 +292,7 @@ public class ThrownPotion extends ThrowableItemProjectile implements ItemSupplie
if (iblockdata.is(BlockTags.FIRE)) {
// CraftBukkit start
@ -170,10 +170,10 @@ index ec9190abe3edf7c3845156bb967dddf6ae7c30ff..95cb7492ac691a8e8aa9894f701b802a
}
// CraftBukkit end
diff --git a/src/main/java/net/minecraft/world/level/block/TntBlock.java b/src/main/java/net/minecraft/world/level/block/TntBlock.java
index ff872a91effaed7394848fe5c1ab4d2bbac0b5fc..a5e1813ba4fee55f469d5c4884124fccecd908d2 100644
index 4896ddca849646135ae101236e534ab8f59bd617..a3525ae6d83591664e1456f20d9732a8de0ec326 100644
--- a/src/main/java/net/minecraft/world/level/block/TntBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/TntBlock.java
@@ -160,7 +160,7 @@ public class TntBlock extends Block {
@@ -158,7 +158,7 @@ public class TntBlock extends Block {
if (projectile.isOnFire() && projectile.mayInteract(world, blockposition)) {
// CraftBukkit start
@ -196,10 +196,10 @@ index edc20745649b0837f1371c8d29e71fc0c8e5528f..932831bb5632ead5850842fc77192c84
}
// CraftBukkit end
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
index 9588c191ccb5665be2ff90ae2ded5bbff12faacb..bb7ae2c13b8a037b631366da337d1d43985e1845 100644
index 877990d391432f144e0013679aca8c9cfebda03d..972c54fbdf7d3ab74f8f8ea62144805c9301399f 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -1358,11 +1358,11 @@ public class CraftEventFactory {
@@ -1359,11 +1359,11 @@ public class CraftEventFactory {
return event;
}

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] fix player loottables running when mob loot gamerule is false
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
index a94b43df4a6cd6f5974015bc5fc87d37347276f1..c5f3849a5ce90c985faeff04f718491373155cbc 100644
index 279c323bc2c2658fa1848d0c98f0614fbeb97e99..660dd568ba30037170db1abc470e91c9af614f4c 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -952,12 +952,14 @@ public class ServerPlayer extends Player {
@@ -961,12 +961,14 @@ public class ServerPlayer extends net.minecraft.world.entity.player.Player {
}
}
}

Datei anzeigen

@ -6,10 +6,10 @@ 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 6025b45d1c247941d83cd9c2d516c14a70f64bfd..85fd7ad12e059f88bacf2d7c27715dcbd8fa3d4e 100644
index ad049687cd6c6c98bd08b512c6233b725c6ad9ab..156fb444061be556bbb1f230b239d5d2ce59b94b 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -2610,7 +2610,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
@@ -2689,7 +2689,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
}
public boolean startRiding(Entity entity, boolean force) {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Allow changing the EnderDragon podium
diff --git a/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java b/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java
index 789823dbaaf2e23942749145dbb64071539624aa..e8be7ddbef12b27ed5c5fcfa8b726d5a85058aa9 100644
index 201ef4a3f5bc8633f7a51e151e9e87efc4004cad..45673a7630977e833df84e29e2f0b0012a3ab049 100644
--- a/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java
+++ b/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java
@@ -102,6 +102,10 @@ public class EnderDragon extends Mob implements Enemy {
@@ -103,6 +103,10 @@ public class EnderDragon extends Mob implements Enemy {
private final int[] nodeAdjacency;
private final BinaryHeap openSet;
private final Explosion explosionSource; // CraftBukkit - reusable source for CraftTNTPrimed.getSource()
@ -19,7 +19,7 @@ index 789823dbaaf2e23942749145dbb64071539624aa..e8be7ddbef12b27ed5c5fcfa8b726d5a
public EnderDragon(EntityType<? extends EnderDragon> entitytypes, Level world) {
super(EntityType.ENDER_DRAGON, world);
@@ -142,6 +146,19 @@ public class EnderDragon extends Mob implements Enemy {
@@ -143,6 +147,19 @@ public class EnderDragon extends Mob implements Enemy {
return Mob.createMobAttributes().add(Attributes.MAX_HEALTH, 200.0D);
}
@ -39,7 +39,7 @@ index 789823dbaaf2e23942749145dbb64071539624aa..e8be7ddbef12b27ed5c5fcfa8b726d5a
@Override
public boolean isFlapping() {
float f = Mth.cos(this.flapTime * 6.2831855F);
@@ -993,7 +1010,7 @@ public class EnderDragon extends Mob implements Enemy {
@@ -1010,7 +1027,7 @@ public class EnderDragon extends Mob implements Enemy {
d0 = segment2[1] - segment1[1];
}
} else {
@ -48,7 +48,7 @@ index 789823dbaaf2e23942749145dbb64071539624aa..e8be7ddbef12b27ed5c5fcfa8b726d5a
double d1 = Math.max(Math.sqrt(blockposition.distToCenterSqr(this.position())) / 4.0D, 1.0D);
d0 = (double) segmentOffset / d1;
@@ -1020,7 +1037,7 @@ public class EnderDragon extends Mob implements Enemy {
@@ -1037,7 +1054,7 @@ public class EnderDragon extends Mob implements Enemy {
vec3d = this.getViewVector(tickDelta);
}
} else {

Datei anzeigen

@ -9,7 +9,7 @@ is not a WorldGenRegion, we can bypass the deadlock entirely.
See https://bugs.mojang.com/browse/MC-246262
diff --git a/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java b/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java
index bd401b38239fb7e510f82f458f9336b7da372da0..b5365dce7882c98b5be4f5df877165eee80933dd 100644
index 33564e62e3181d28b18a957e28b8ec5152d8339f..cf8258e8d46ca7286a66c38fa24af369bd9a279f 100644
--- a/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java
+++ b/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java
@@ -279,7 +279,11 @@ public class StructureTemplate {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Prevent tile entity copies loading chunks
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index eec6765f0885994791e6b09cd731bb275ceb286b..535f6478453e61fa37c5e6f887d27f25ca82269b 100644
index 68571261c7095b9477d09536b69272eea7137e64..cd3556878990d0dca36373c5482afb83a241e102 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -3185,7 +3185,12 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
@@ -3202,7 +3202,12 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
BlockPos blockposition = BlockEntity.getPosFromTag(customdata.getUnsafe());
if (this.player.level().isLoaded(blockposition)) {

Datei anzeigen

@ -6,10 +6,10 @@ Subject: [PATCH] Use username instead of display name in
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
index 9fc053e2f6f3bbd9c17fda5679322a0fb403b7fe..c76143eadbcb434d4468b4d7c32d71d646788341 100644
index 11ac1a4e2cc276b9817014b8bb6a454e282d6258..fc96b6e2a279ce6a9fff2a4171604da9e5eeb660 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -1434,7 +1434,7 @@ public abstract class PlayerList {
@@ -1388,7 +1388,7 @@ public abstract class PlayerList {
// CraftBukkit start
public ServerStatsCounter getPlayerStats(ServerPlayer entityhuman) {
ServerStatsCounter serverstatisticmanager = entityhuman.getStats();

Datei anzeigen

@ -0,0 +1,23 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: HexedHero <6012891+HexedHero@users.noreply.github.com>
Date: Sun, 10 Apr 2022 06:26:32 +0100
Subject: [PATCH] Expand PlayerItemDamageEvent
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
index 823146a66de8ce13e6dc6faf2fd135480bd51c3a..d825c2e3808e44db9935dab4e7b528146c6d83c2 100644
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
@@ -650,10 +650,11 @@ public final class ItemStack implements DataComponentHolder {
if (this.isDamageableItem()) {
if (player == null || !player.hasInfiniteMaterials()) {
if (amount > 0) {
+ int originalDamage = amount; // Paper - Expand PlayerItemDamageEvent
amount = EnchantmentHelper.processDurabilityChange(world, this, amount);
// CraftBukkit start
if (player instanceof ServerPlayer serverPlayer) { // Paper - Add EntityDamageItemEvent
- PlayerItemDamageEvent event = new PlayerItemDamageEvent(serverPlayer.getBukkitEntity(), CraftItemStack.asCraftMirror(this), amount); // Paper - Add EntityDamageItemEvent
+ PlayerItemDamageEvent event = new PlayerItemDamageEvent(serverPlayer.getBukkitEntity(), CraftItemStack.asCraftMirror(this), amount, originalDamage); // Paper - Add EntityDamageItemEvent & Expand PlayerItemDamageEvent
event.getPlayer().getServer().getPluginManager().callEvent(event);
if (amount != event.getDamage() || event.isCancelled()) {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] WorldCreator#keepSpawnLoaded
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 60441fbe87fed55d76967b7e709a21f462f4f511..fbfc9e45e7740c0560affb2f1c135032fa5aecc9 100644
index 9744e466489be575ac736aaba4b6a48f40b74d62..35a216823738ae9634388023ff76b35fdb7f1038 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -1312,7 +1312,7 @@ public final class CraftServer implements Server {
@@ -1315,7 +1315,7 @@ public final class CraftServer implements Server {
}
// If set to not keep spawn in memory (changed from default) then adjust rule accordingly

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Trigger bee_nest_destroyed trigger in the correct place
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
index c55d944a70300bf77dbde918c91815cabe68496d..ac2bd55deeef8e14b8fa0db1f2d10e36d045f0e4 100644
index 073cf184a0e7af41048ae67a9b17b4cdfcc43c35..4d024956156aefde7df308642dfd0a40779e0633 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
@@ -424,12 +424,16 @@ public class ServerPlayerGameMode {
@@ -429,12 +429,16 @@ public class ServerPlayerGameMode {
block.destroy(this.level, pos, iblockdata1);
}
@ -25,7 +25,7 @@ index c55d944a70300bf77dbde918c91815cabe68496d..ac2bd55deeef8e14b8fa0db1f2d10e36
itemstack.mineBlock(this.level, iblockdata1, pos, this.player);
if (flag && flag1 && event.isDropItems()) { // CraftBukkit - Check if block should drop items
@@ -450,6 +454,13 @@ public class ServerPlayerGameMode {
@@ -455,6 +459,13 @@ public class ServerPlayerGameMode {
if (flag && event != null) {
iblockdata.getBlock().popExperience(this.level, pos, event.getExpToDrop(), this.player); // Paper
}
@ -40,7 +40,7 @@ index c55d944a70300bf77dbde918c91815cabe68496d..ac2bd55deeef8e14b8fa0db1f2d10e36
return true;
// CraftBukkit end
diff --git a/src/main/java/net/minecraft/world/level/block/BeehiveBlock.java b/src/main/java/net/minecraft/world/level/block/BeehiveBlock.java
index ef804067ee05870e9331237b44ca1ffeb8df99c7..21a7f9414e27c73b58fd75fbe68cf889f52a5d01 100644
index 8d6736003934c5958f600660bdee58b386c39da4..c75227b2ea165dcd65c203e60157ac7cdebd4bc6 100644
--- a/src/main/java/net/minecraft/world/level/block/BeehiveBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/BeehiveBlock.java
@@ -95,7 +95,7 @@ public class BeehiveBlock extends BaseEntityBlock {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Add EntityDyeEvent and CollarColorable interface
diff --git a/src/main/java/net/minecraft/world/entity/animal/Cat.java b/src/main/java/net/minecraft/world/entity/animal/Cat.java
index b5f13d1bf1cccb9a15d8956f68c960e25098dc98..118be62539bb0266c2e89bd68abbc4a975fcd833 100644
index d44807c16712afd37efdbf434d1afb12a7c3d343..2ed442c8d36f285420cf84a956e90b6036384ce0 100644
--- a/src/main/java/net/minecraft/world/entity/animal/Cat.java
+++ b/src/main/java/net/minecraft/world/entity/animal/Cat.java
@@ -388,6 +388,13 @@ public class Cat extends TamableAnimal implements VariantHolder<Holder<CatVarian
@@ -378,6 +378,13 @@ public class Cat extends TamableAnimal implements VariantHolder<Holder<CatVarian
DyeColor enumcolor = itemdye.getDyeColor();
if (enumcolor != this.getCollarColor()) {
@ -23,10 +23,10 @@ index b5f13d1bf1cccb9a15d8956f68c960e25098dc98..118be62539bb0266c2e89bd68abbc4a9
this.setCollarColor(enumcolor);
itemstack.consume(1, player);
diff --git a/src/main/java/net/minecraft/world/entity/animal/Wolf.java b/src/main/java/net/minecraft/world/entity/animal/Wolf.java
index 5ebf49a565af4ab3bead60a83bca2e6561e6a29c..cebbb7341f86b13dcbfc3a41cbe264e9d4b68d60 100644
index 26b050599984ae3ba3827a0cabab255374e38c1e..c382a8f95f612db881b9cdbd07316d1ca1cd9c4b 100644
--- a/src/main/java/net/minecraft/world/entity/animal/Wolf.java
+++ b/src/main/java/net/minecraft/world/entity/animal/Wolf.java
@@ -447,6 +447,14 @@ public class Wolf extends TamableAnimal implements NeutralMob, VariantHolder<Hol
@@ -451,6 +451,14 @@ public class Wolf extends TamableAnimal implements NeutralMob, VariantHolder<Hol
DyeColor enumcolor = itemdye.getDyeColor();
if (enumcolor != this.getCollarColor()) {

Datei anzeigen

@ -7,7 +7,7 @@ Also don't fire level events or game events if stalactite
drip is cancelled
diff --git a/src/main/java/net/minecraft/core/cauldron/CauldronInteraction.java b/src/main/java/net/minecraft/core/cauldron/CauldronInteraction.java
index 6de21246693afd20fce867e6c2480f912e1b639a..50e9643c88252d6afbcea1763cc3f7063f0d35b4 100644
index 9ebd5310ee358acd83123a30415d9f7eb6aa36d9..f301c20e808b77cb3fcffd9a7c8102928306456e 100644
--- a/src/main/java/net/minecraft/core/cauldron/CauldronInteraction.java
+++ b/src/main/java/net/minecraft/core/cauldron/CauldronInteraction.java
@@ -81,7 +81,7 @@ public interface CauldronInteraction {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Add PlayerStopUsingItemEvent
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index 8aae4dacb85f67ea5f67e1143f2094851d40e85e..e98ece3b5af0d1ffe6dddce4e342cd2858166ba3 100644
index 60394f1b0e727d6dec4af37b452a6312eb3ae375..81302c76a8a104a52a162caf9f6a46b31ba76819 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -4017,6 +4017,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
@@ -4044,6 +4044,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
public void releaseUsingItem() {
if (!this.useItem.isEmpty()) {

Datei anzeigen

@ -23,10 +23,10 @@ index 67fcba634f8183bb33834ac3b2c3dcfb8d87129e..777b789fdcdf297309cfb36fc7f77e3f
}
});
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
index 134df9ad4d5d5f85429f5e3ff6d879bc5f1fb13f..452dfcce367470711e12ee174518359dc916a10d 100644
index 0723e6fb396a7afa11772f460a98f68cc815bba0..d839dd47eb02ce30119c57ff2c1a46c9570fe913 100644
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
@@ -2192,6 +2192,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
@@ -2160,6 +2160,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
}
public void onTickingStart(Entity entity) {

Datei anzeigen

@ -13,18 +13,18 @@ public net.minecraft.world.entity.item.FallingBlockEntity blockState
Co-authored-by: Lukas Planz <lukas.planz@web.de>
diff --git a/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java b/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java
index cc00bf81de902cfc587bcf6f18e861fd4339c91e..d504d10fbe45dfe3f2f3d08d2473df6cd18f6dcf 100644
index 01ac7bb0ef8ab13e7c4b5b56b768b7c0a642b300..caf9273cfafbbaaf8dc95498927383e608773665 100644
--- a/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java
+++ b/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java
@@ -67,6 +67,7 @@ public class FallingBlockEntity extends Entity {
@Nullable
@@ -71,6 +71,7 @@ public class FallingBlockEntity extends Entity {
public CompoundTag blockData;
public boolean forceTickAfterTeleportToDuplicate;
protected static final EntityDataAccessor<BlockPos> DATA_START_POS = SynchedEntityData.defineId(FallingBlockEntity.class, EntityDataSerializers.BLOCK_POS);
+ public boolean autoExpire = true; // Paper - Expand FallingBlock API
public FallingBlockEntity(EntityType<? extends FallingBlockEntity> type, Level world) {
super(type, world);
@@ -171,7 +172,7 @@ public class FallingBlockEntity extends Entity {
@@ -176,7 +177,7 @@ public class FallingBlockEntity extends Entity {
}
if (!this.onGround() && !flag1) {
@ -33,7 +33,7 @@ index cc00bf81de902cfc587bcf6f18e861fd4339c91e..d504d10fbe45dfe3f2f3d08d2473df6c
if (this.dropItem && this.level().getGameRules().getBoolean(GameRules.RULE_DOENTITYDROPS)) {
this.spawnAtLocation((ItemLike) block);
}
@@ -317,6 +318,7 @@ public class FallingBlockEntity extends Entity {
@@ -322,6 +323,7 @@ public class FallingBlockEntity extends Entity {
}
nbt.putBoolean("CancelDrop", this.cancelDrop);
@ -41,7 +41,7 @@ index cc00bf81de902cfc587bcf6f18e861fd4339c91e..d504d10fbe45dfe3f2f3d08d2473df6c
}
@Override
@@ -344,6 +346,11 @@ public class FallingBlockEntity extends Entity {
@@ -349,6 +351,11 @@ public class FallingBlockEntity extends Entity {
this.blockState = Blocks.SAND.defaultBlockState();
}

Datei anzeigen

@ -5,7 +5,7 @@ Subject: [PATCH] Add support for Proxy Protocol
diff --git a/build.gradle.kts b/build.gradle.kts
index 69b5d39f57a63130c0b83f6238898bdf68fa1e9a..48b8db6d5fdf9b2f7155b9356418178f5594ddcb 100644
index 2bcb4eacd06c76f2c950b424b2a2c4d53497c538..b06f38b87765d084565bc11cf5da6076562b6be8 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -28,6 +28,7 @@ dependencies {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Prevent entity loading causing async lookups
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 85fd7ad12e059f88bacf2d7c27715dcbd8fa3d4e..608bc43bd84f10d5610133b041aff8e3a32f178a 100644
index 156fb444061be556bbb1f230b239d5d2ce59b94b..bbca8a478ab4c27c21fb6fe33fdb57fd3d29435c 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -739,6 +739,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
@@ -715,6 +715,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
public void baseTick() {
this.level().getProfiler().push("entityBaseTick");

Datei anzeigen

@ -7,10 +7,10 @@ There are no plans to support creating worlds while worlds are
being ticked themselvess.
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index 0420e92207a8b106d9b70f92774b21bb1dc19b25..91771afb413b56ff84697f4d1264e2e97ee5c132 100644
index 29011d222434cbb2c71797786b8376ea37c8023a..4b44447360b75b6dbe93d8176dcba2db02d77f1e 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -311,6 +311,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -318,6 +318,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
// Spigot end
public final io.papermc.paper.configuration.PaperConfigurations paperConfigurations; // Paper - add paper configuration files
public static long currentTickLong = 0L; // Paper - track current tick as a long
@ -18,7 +18,7 @@ index 0420e92207a8b106d9b70f92774b21bb1dc19b25..91771afb413b56ff84697f4d1264e2e9
public static <S extends MinecraftServer> S spin(Function<Thread, S> serverFactory) {
AtomicReference<S> atomicreference = new AtomicReference();
@@ -1555,7 +1556,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -1583,7 +1584,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
this.getFunctions().tick();
MinecraftTimings.commandFunctionsTimer.stopTiming(); // Spigot // Paper
this.profiler.popPush("levels");
@ -27,7 +27,7 @@ index 0420e92207a8b106d9b70f92774b21bb1dc19b25..91771afb413b56ff84697f4d1264e2e9
// CraftBukkit start
// Run tasks that are waiting on processing
@@ -1587,6 +1588,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -1615,6 +1616,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
// Paper end - Perf: Optimize time updates
MinecraftTimings.timeUpdateTimer.stopTiming(); // Spigot // Paper
@ -36,7 +36,7 @@ index 0420e92207a8b106d9b70f92774b21bb1dc19b25..91771afb413b56ff84697f4d1264e2e9
while (iterator.hasNext()) {
ServerLevel worldserver = (ServerLevel) iterator.next();
worldserver.hasPhysicsEvent = org.bukkit.event.block.BlockPhysicsEvent.getHandlerList().getRegisteredListeners().length > 0; // Paper - BlockPhysicsEvent
@@ -1627,6 +1630,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
@@ -1655,6 +1658,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
this.profiler.pop();
worldserver.explosionDensityCache.clear(); // Paper - Optimize explosions
}
@ -45,10 +45,10 @@ index 0420e92207a8b106d9b70f92774b21bb1dc19b25..91771afb413b56ff84697f4d1264e2e9
this.profiler.popPush("connection");
MinecraftTimings.connectionTimer.startTiming(); // Spigot // Paper
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index fbfc9e45e7740c0560affb2f1c135032fa5aecc9..6a4ade9e6d741fbc5ca878047df6a35cf24a8461 100644
index 35a216823738ae9634388023ff76b35fdb7f1038..c0f6b96e9aaf52d8141f31c46035f09fa2a12caa 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -904,6 +904,11 @@ public final class CraftServer implements Server {
@@ -907,6 +907,11 @@ public final class CraftServer implements Server {
return new ArrayList<World>(this.worlds.values());
}
@ -60,7 +60,7 @@ index fbfc9e45e7740c0560affb2f1c135032fa5aecc9..6a4ade9e6d741fbc5ca878047df6a35c
public DedicatedPlayerList getHandle() {
return this.playerList;
}
@@ -1166,6 +1171,7 @@ public final class CraftServer implements Server {
@@ -1169,6 +1174,7 @@ public final class CraftServer implements Server {
@Override
public World createWorld(WorldCreator creator) {
Preconditions.checkState(this.console.getAllLevels().iterator().hasNext(), "Cannot create additional worlds on STARTUP");
@ -68,7 +68,7 @@ index fbfc9e45e7740c0560affb2f1c135032fa5aecc9..6a4ade9e6d741fbc5ca878047df6a35c
Preconditions.checkArgument(creator != null, "WorldCreator cannot be null");
String name = creator.name();
@@ -1342,6 +1348,7 @@ public final class CraftServer implements Server {
@@ -1345,6 +1351,7 @@ public final class CraftServer implements Server {
@Override
public boolean unloadWorld(World world, boolean save) {

Datei anzeigen

@ -18,10 +18,10 @@ index 27e52ee93ab591e97f37705de64cb5b62c06e253..3d792957f27fd4bdfad8d76262a8e2a2
int j = this.angerByUuid.removeInt(entity.getUUID());
i += j;
diff --git a/src/main/java/net/minecraft/world/entity/monster/warden/Warden.java b/src/main/java/net/minecraft/world/entity/monster/warden/Warden.java
index e428ccc1a3e79b010cd8559879a07909c24cca47..ddd60be52dce5773c80934be5aa5705db239e3dd 100644
index aaa4b5d90e23b09f87847aa52c36548c94ddf548..38bf417a9ad4647f4af24d969f3bf4fed9c4bad7 100644
--- a/src/main/java/net/minecraft/world/entity/monster/warden/Warden.java
+++ b/src/main/java/net/minecraft/world/entity/monster/warden/Warden.java
@@ -482,6 +482,15 @@ public class Warden extends Monster implements VibrationSystem {
@@ -479,6 +479,15 @@ public class Warden extends Monster implements VibrationSystem {
@VisibleForTesting
public void increaseAngerAt(@Nullable Entity entity, int amount, boolean listening) {
if (!this.isNoAi() && this.canTargetEntity(entity)) {

Datei anzeigen

@ -11,10 +11,10 @@ distance trigger. This adds a config option to ignore that
and use the exact dimension key of the worlds involved.
diff --git a/src/main/java/net/minecraft/advancements/critereon/LocationPredicate.java b/src/main/java/net/minecraft/advancements/critereon/LocationPredicate.java
index 5be2d877162922d6f29592e723b7d5aff14e1515..37174de2319e353b2f989d8321758a081c655a3f 100644
index 01b8f7024fbc965bc6a7f97f79ba3dec964ef769..801823d003a8e28a13fe90db4604cd0938899c6d 100644
--- a/src/main/java/net/minecraft/advancements/critereon/LocationPredicate.java
+++ b/src/main/java/net/minecraft/advancements/critereon/LocationPredicate.java
@@ -42,7 +42,7 @@ public record LocationPredicate(
@@ -44,7 +44,7 @@ public record LocationPredicate(
public boolean matches(ServerLevel world, double x, double y, double z) {
if (this.position.isPresent() && !this.position.get().matches(x, y, z)) {
return false;
@ -24,10 +24,10 @@ index 5be2d877162922d6f29592e723b7d5aff14e1515..37174de2319e353b2f989d8321758a08
} else {
BlockPos blockPos = BlockPos.containing(x, y, z);
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
index c5f3849a5ce90c985faeff04f718491373155cbc..d0a7bcc0dde8b2a9543cf4c0c8d35ab042fb4e3b 100644
index 660dd568ba30037170db1abc470e91c9af614f4c..015db96646c603fb4d9b3b9ceb8853f680332944 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -1349,6 +1349,12 @@ public class ServerPlayer extends Player {
@@ -1390,6 +1390,12 @@ public class ServerPlayer extends net.minecraft.world.entity.player.Player {
ResourceKey<Level> maindimensionkey = CraftDimensionUtil.getMainDimensionKey(origin);
ResourceKey<Level> maindimensionkey1 = CraftDimensionUtil.getMainDimensionKey(this.level());

Datei anzeigen

@ -20,10 +20,10 @@ index 8c2dcc4134d96351cee75773214f3f47e71533e9..e6bfcc50cdf728216084bc00a5bb8b6b
Date date = new Date();
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 6a4ade9e6d741fbc5ca878047df6a35cf24a8461..8b629647c15721207f14081832bea6a702359b77 100644
index c0f6b96e9aaf52d8141f31c46035f09fa2a12caa..873daccd9c9521e75dcca5e5070ffcbbac00956a 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -1911,7 +1911,7 @@ public final class CraftServer implements Server {
@@ -1914,7 +1914,7 @@ public final class CraftServer implements Server {
// Paper end
Set<CommandSender> recipients = new HashSet<>();
for (Permissible permissible : this.getPluginManager().getPermissionSubscriptions(permission)) {

Datei anzeigen

@ -7,10 +7,10 @@ The previous solution caused a bunch of bandaid fixes inorder to resolve edge ca
Just simply prevent them from being added to the world instead.
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
index 452dfcce367470711e12ee174518359dc916a10d..e42dd32e277d8071a2c1b4411bc222a62023102d 100644
index d839dd47eb02ce30119c57ff2c1a46c9570fe913..e1e0cf97d2badd26a9391bf0f758edae262a14c2 100644
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
@@ -1237,6 +1237,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
@@ -1235,6 +1235,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
// WorldServer.LOGGER.warn("Tried to add entity {} but it was marked as removed already", EntityTypes.getKey(entity.getType())); // CraftBukkit
return false;
} else {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Add various missing EntityDropItemEvent calls
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 608bc43bd84f10d5610133b041aff8e3a32f178a..e7c1e235ef03bb03e2788616255f7b14fa7fc0e3 100644
index bbca8a478ab4c27c21fb6fe33fdb57fd3d29435c..d328393e62e4e49ddd56c10a9f4f5fcf0b218ddf 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -2518,6 +2518,14 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
@@ -2559,6 +2559,14 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
stack.setCount(0); // Paper - destroy this item - if this ever leaks due to game bugs, ensure it doesn't dupe
entityitem.setDefaultPickUpDelay();
@ -24,10 +24,10 @@ index 608bc43bd84f10d5610133b041aff8e3a32f178a..e7c1e235ef03bb03e2788616255f7b14
EntityDropItemEvent event = new EntityDropItemEvent(this.getBukkitEntity(), (org.bukkit.entity.Item) entityitem.getBukkitEntity());
Bukkit.getPluginManager().callEvent(event);
diff --git a/src/main/java/net/minecraft/world/entity/animal/Dolphin.java b/src/main/java/net/minecraft/world/entity/animal/Dolphin.java
index ff5d117e4740fe1762b5d1f547fc5cb89ab8515b..1b1cb0e4d54e52ebe794199e386c54c5d84b3719 100644
index 08823651b0a81b15bc33f86c96d6cc1dc72770f4..da45cc62985f8b67cdfeffc21cb33837db673555 100644
--- a/src/main/java/net/minecraft/world/entity/animal/Dolphin.java
+++ b/src/main/java/net/minecraft/world/entity/animal/Dolphin.java
@@ -583,7 +583,7 @@ public class Dolphin extends WaterAnimal {
@@ -576,7 +576,7 @@ public class Dolphin extends WaterAnimal {
float f2 = 0.02F * Dolphin.this.random.nextFloat();
entityitem.setDeltaMovement((double) (0.3F * -Mth.sin(Dolphin.this.getYRot() * 0.017453292F) * Mth.cos(Dolphin.this.getXRot() * 0.017453292F) + Mth.cos(f1) * f2), (double) (0.3F * Mth.sin(Dolphin.this.getXRot() * 0.017453292F) * 1.5F), (double) (0.3F * Mth.cos(Dolphin.this.getYRot() * 0.017453292F) * Mth.cos(Dolphin.this.getXRot() * 0.017453292F) + Mth.sin(f1) * f2));
@ -37,7 +37,7 @@ index ff5d117e4740fe1762b5d1f547fc5cb89ab8515b..1b1cb0e4d54e52ebe794199e386c54c5
}
}
diff --git a/src/main/java/net/minecraft/world/entity/animal/Fox.java b/src/main/java/net/minecraft/world/entity/animal/Fox.java
index 82ced9f42dced65322a55579bb764fb4dc7c1b66..1aa5485f2608000e4ac07350d1c537bc9bd92de4 100644
index e46c8231ee318eda0512afbb6343b426b4838643..3265b3b5aede517b6fd8bb836947795bf8881350 100644
--- a/src/main/java/net/minecraft/world/entity/animal/Fox.java
+++ b/src/main/java/net/minecraft/world/entity/animal/Fox.java
@@ -507,14 +507,14 @@ public class Fox extends Animal implements VariantHolder<Fox.Type> {
@ -72,7 +72,7 @@ index 3b2cf9ca8447321d64ffdb4fdb9569d736d63dbb..923806900ef6248576e71260d40e9caf
}
diff --git a/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java b/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java
index 11236a1c1705600c2317f0ea4e3b712327352b40..a0c52ce65d4035d135b1536c7408a6867a553447 100644
index 94df94f7acc121201966955a09fb336b0a98e599..d34d8fe70379dcad9540739ec0ae1c94f01fc46b 100644
--- a/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java
+++ b/src/main/java/net/minecraft/world/entity/animal/sniffer/Sniffer.java
@@ -350,8 +350,9 @@ public class Sniffer extends Animal {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Fix Bee flower NPE
diff --git a/src/main/java/net/minecraft/world/entity/animal/Bee.java b/src/main/java/net/minecraft/world/entity/animal/Bee.java
index d317b8500e8d2c280e52140440cf2b9cb61c3b28..0dfb8109fd8c022b079da00f6a0e3fc85b57bf7a 100644
index f933654b66f7474dc071da5f10cf1684fdac367a..1b3978f4ea7e8491e0c0cb6de23c141f44fab414 100644
--- a/src/main/java/net/minecraft/world/entity/animal/Bee.java
+++ b/src/main/java/net/minecraft/world/entity/animal/Bee.java
@@ -794,7 +794,7 @@ public class Bee extends Animal implements NeutralMob, FlyingAnimal {
@@ -805,7 +805,7 @@ public class Bee extends Animal implements NeutralMob, FlyingAnimal {
++this.pollinatingTicks;
if (this.pollinatingTicks > 600) {
Bee.this.savedFlowerPos = null;

Datei anzeigen

@ -5,15 +5,15 @@ Subject: [PATCH] Fix Spigot Config not using commands.spam-exclusions
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 535f6478453e61fa37c5e6f887d27f25ca82269b..841e9ff72bf48f9273afc14dfa636232be2c955c 100644
index cd3556878990d0dca36373c5482afb83a241e102..07126be6e292e9b5d29265817d00d651dda5fd07 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -2367,7 +2367,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
@@ -2384,7 +2384,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
}
// Spigot end
// this.chatSpamTickCount += 20;
- if (this.chatSpamTickCount.addAndGet(20) > 200 && !this.server.getPlayerList().isOp(this.player.getGameProfile())) {
+ if (counted && this.chatSpamTickCount.addAndGet(20) > 200 && !this.server.getPlayerList().isOp(this.player.getGameProfile())) { // Paper - exclude from SpigotConfig.spamExclusions
- if (this.chatSpamTickCount.addAndGet(20) > 200 && !this.server.getPlayerList().isOp(this.player.getGameProfile()) && !this.server.isSingleplayerOwner(this.player.getGameProfile())) {
+ if (counted && this.chatSpamTickCount.addAndGet(20) > 200 && !this.server.getPlayerList().isOp(this.player.getGameProfile()) && !this.server.isSingleplayerOwner(this.player.getGameProfile())) { // Paper - exclude from SpigotConfig.spamExclusions
// CraftBukkit end
this.disconnect(Component.translatable("disconnect.spam"), org.bukkit.event.player.PlayerKickEvent.Cause.SPAM); // Paper - kick event cause
this.disconnect((Component) Component.translatable("disconnect.spam"), org.bukkit.event.player.PlayerKickEvent.Cause.SPAM); // Paper - kick event cause
}

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] More Teleport API
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 841e9ff72bf48f9273afc14dfa636232be2c955c..01905f6db49ffe578998f4cf6d24311400a3d92b 100644
index 07126be6e292e9b5d29265817d00d651dda5fd07..1e39ec69c0ec26dfac6512bb04587801bbea687e 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -1553,11 +1553,17 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
@@ -1566,11 +1566,17 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
return false; // CraftBukkit - Return event status
}
@ -29,10 +29,10 @@ index 841e9ff72bf48f9273afc14dfa636232be2c955c..01905f6db49ffe578998f4cf6d243114
d0 = to.getX();
d1 = to.getY();
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
index 113ca1d16cb7650d72f488cdaa9e670d51dc85f0..b6fef2ca5b564c293cb602cb8e300d35dba89b1f 100644
index 47f24e390efd8eb4cb7f62b5203825f4160772b7..243ac4253a1541dba52126bad96682e43c6f48a1 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
@@ -219,15 +219,36 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
@@ -221,15 +221,36 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
@Override
public boolean teleport(Location location, TeleportCause cause) {
@ -71,7 +71,7 @@ index 113ca1d16cb7650d72f488cdaa9e670d51dc85f0..b6fef2ca5b564c293cb602cb8e300d35
// Let the server handle cross world teleports
if (location.getWorld() != null && !location.getWorld().equals(this.getWorld())) {
@@ -958,6 +979,39 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
@@ -975,6 +996,39 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
return CraftEntity.perm;
}
@ -112,10 +112,10 @@ index 113ca1d16cb7650d72f488cdaa9e670d51dc85f0..b6fef2ca5b564c293cb602cb8e300d35
private final org.bukkit.entity.Entity.Spigot spigot = new org.bukkit.entity.Entity.Spigot()
{
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 6793acbbae09a9bc39f59c029f6b02182ec33a92..898259c35c25ee034c859e210350efc19c559e3b 100644
index 7716d990ee193e920fc14e52404afdeab12c62b5..48c1af4bfa97d2c4e8fd695af5b9cefb5398db97 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -1273,13 +1273,101 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@@ -1286,13 +1286,101 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@Override
public void setRotation(float yaw, float pitch) {
@ -218,7 +218,7 @@ index 6793acbbae09a9bc39f59c029f6b02182ec33a92..898259c35c25ee034c859e210350efc1
location.checkFinite();
ServerPlayer entity = this.getHandle();
@@ -1292,7 +1380,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@@ -1305,7 +1393,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
return false;
}
@ -227,7 +227,7 @@ index 6793acbbae09a9bc39f59c029f6b02182ec33a92..898259c35c25ee034c859e210350efc1
return false;
}
@@ -1301,7 +1389,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@@ -1314,7 +1402,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
// To = Players new Location if Teleport is Successful
Location to = location;
// Create & Call the Teleport Event.
@ -236,7 +236,7 @@ index 6793acbbae09a9bc39f59c029f6b02182ec33a92..898259c35c25ee034c859e210350efc1
this.server.getPluginManager().callEvent(event);
// Return False to inform the Plugin that the Teleport was unsuccessful/cancelled.
@@ -1310,7 +1398,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@@ -1323,7 +1411,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
}
// If this player is riding another entity, we must dismount before teleporting.
@ -245,7 +245,7 @@ index 6793acbbae09a9bc39f59c029f6b02182ec33a92..898259c35c25ee034c859e210350efc1
// SPIGOT-5509: Wakeup, similar to riding
if (this.isSleeping()) {
@@ -1326,13 +1414,19 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@@ -1339,13 +1427,19 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
ServerLevel toWorld = ((CraftWorld) to.getWorld()).getHandle();
// Close any foreign inventory
@ -266,4 +266,4 @@ index 6793acbbae09a9bc39f59c029f6b02182ec33a92..898259c35c25ee034c859e210350efc1
+ // Paper end - Teleport API
} else {
// The respawn reason should never be used if the passed location is non null.
this.server.getHandle().respawn(entity, toWorld, true, to, !toWorld.paperConfig().environment.disableTeleportationSuffocationCheck, null); // Paper
this.server.getHandle().respawn(entity, true, Entity.RemovalReason.CHANGED_DIMENSION, null, to);

Datei anzeigen

@ -0,0 +1,28 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Jake Potrebic <jake.m.potrebic@gmail.com>
Date: Wed, 12 May 2021 04:30:42 -0700
Subject: [PATCH] Add EntityPortalReadyEvent
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index d328393e62e4e49ddd56c10a9f4f5fcf0b218ddf..6be5d68567ba7b598644a3feeaa34ae5171c3b97 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -2943,6 +2943,17 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
if (this.portalProcess != null) {
if (this.portalProcess.processPortalTeleportation(worldserver, this, this.canUsePortal(false))) {
worldserver.getProfiler().push("portal");
+ // Paper start - Add EntityPortalReadyEvent
+ ServerLevel changedTarget = worldserver.getServer().getLevel(worldserver.getTypeKey() == net.minecraft.world.level.dimension.LevelStem.NETHER ? Level.OVERWORLD : Level.NETHER);
+ if (this.portalProcess.isSamePortal(((net.minecraft.world.level.block.NetherPortalBlock) net.minecraft.world.level.block.Blocks.NETHER_PORTAL))) {
+ io.papermc.paper.event.entity.EntityPortalReadyEvent event = new io.papermc.paper.event.entity.EntityPortalReadyEvent(this.getBukkitEntity(), changedTarget == null ? null : changedTarget.getWorld(), org.bukkit.PortalType.NETHER);
+ if (!event.callEvent()) {
+ this.portalProcess = null;
+ worldserver.getProfiler().pop();
+ return;
+ }
+ }
+ // Paper end - Add EntityPortalReadyEvent
this.setPortalCooldown();
DimensionTransition dimensiontransition = this.portalProcess.getPortalDestination(worldserver, this);

Datei anzeigen

@ -9,10 +9,10 @@ should be supported. Some entities (for whatever
reason) use the level's random in some places.
diff --git a/src/main/java/net/minecraft/world/entity/item/ItemEntity.java b/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
index 1817e8876f13695578b0a5b2f75e738b3286db48..b392fda26982517cbc2c04156897184275ce69e5 100644
index 5448a0f54080ac02bc4ce8ad5645173b67841e1a..30056568a9701fcb664682f329175d3bfee79b60 100644
--- a/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
+++ b/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
@@ -71,7 +71,12 @@ public class ItemEntity extends Entity implements TraceableEntity {
@@ -72,7 +72,12 @@ public class ItemEntity extends Entity implements TraceableEntity {
}
public ItemEntity(Level world, double x, double y, double z, ItemStack stack) {
@ -27,10 +27,10 @@ index 1817e8876f13695578b0a5b2f75e738b3286db48..b392fda26982517cbc2c041568971842
public ItemEntity(Level world, double x, double y, double z, ItemStack stack, double velocityX, double velocityY, double velocityZ) {
diff --git a/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java b/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java
index 4772e7978858263702312669f400d3da9c486730..f1f352ec0e51f5db59254841a06c176c5a876fc9 100644
index 47f2a480f6a4b15e55cedbfa8a58459d33516a97..42bd2d9a1528b6210e4dfb56233062fd97c9743b 100644
--- a/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java
+++ b/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java
@@ -42,7 +42,7 @@ public class PrimedTnt extends Entity implements TraceableEntity {
@@ -62,7 +62,7 @@ public class PrimedTnt extends Entity implements TraceableEntity {
public PrimedTnt(Level world, double x, double y, double z, @Nullable LivingEntity igniter) {
this(EntityType.TNT, world);
this.setPos(x, y, z);

Datei anzeigen

@ -7,10 +7,10 @@ Minecraft's prediction system does not handle block entities, so if we are manua
block breaking we need to set it after the prediction is finished. This fixes block entities not showing when cancelling the BlockBreakEvent.
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
index ac2bd55deeef8e14b8fa0db1f2d10e36d045f0e4..7e3d7d76dfe1c2487cd05c1290b856a1a3ccef24 100644
index 4d024956156aefde7df308642dfd0a40779e0633..6abecaac8407b992d208a9108e11fd4954a4106f 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
@@ -61,6 +61,8 @@ public class ServerPlayerGameMode {
@@ -63,6 +63,8 @@ public class ServerPlayerGameMode {
private BlockPos delayedDestroyPos;
private int delayedTickStart;
private int lastSentState;
@ -19,7 +19,7 @@ index ac2bd55deeef8e14b8fa0db1f2d10e36d045f0e4..7e3d7d76dfe1c2487cd05c1290b856a1
public ServerPlayerGameMode(ServerPlayer player) {
this.gameModeForPlayer = GameType.DEFAULT_MODE;
@@ -191,10 +193,7 @@ public class ServerPlayerGameMode {
@@ -193,10 +195,7 @@ public class ServerPlayerGameMode {
this.player.connection.send(new ClientboundBlockUpdatePacket(pos, this.level.getBlockState(pos)));
this.debugLogging(pos, false, sequence, "may not interact");
// Update any tile entity data for this block
@ -31,7 +31,7 @@ index ac2bd55deeef8e14b8fa0db1f2d10e36d045f0e4..7e3d7d76dfe1c2487cd05c1290b856a1
// CraftBukkit end
return;
}
@@ -205,10 +204,7 @@ public class ServerPlayerGameMode {
@@ -207,10 +206,7 @@ public class ServerPlayerGameMode {
// Let the client know the block still exists
this.player.connection.send(new ClientboundBlockUpdatePacket(this.level, pos));
// Update any tile entity data for this block
@ -43,7 +43,7 @@ index ac2bd55deeef8e14b8fa0db1f2d10e36d045f0e4..7e3d7d76dfe1c2487cd05c1290b856a1
return;
}
// CraftBukkit end
@@ -390,10 +386,12 @@ public class ServerPlayerGameMode {
@@ -395,10 +391,12 @@ public class ServerPlayerGameMode {
}
// Update any tile entity data for this block
@ -57,10 +57,10 @@ index ac2bd55deeef8e14b8fa0db1f2d10e36d045f0e4..7e3d7d76dfe1c2487cd05c1290b856a1
}
}
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 01905f6db49ffe578998f4cf6d24311400a3d92b..e711e3ab336b879664a885c4ec9b9e46cf71331d 100644
index 1e39ec69c0ec26dfac6512bb04587801bbea687e..8564c00ff68148a657fa8ee27e9d92430d6b6389 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -1700,8 +1700,28 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
@@ -1712,8 +1712,28 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
return;
}
// Paper end - Don't allow digging into unloaded chunks

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Warn on plugins accessing faraway chunks
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
index 1408faa8754b2492879f2dbb525aba3bfc8f0421..0fb975d74b8e91617de91dacb206699ff572a38a 100644
index 481248ef82d4257ca4cc88ab28a1a7946e22aef6..b97427789d6162e16b9c3a56b89b2dd08a04297f 100644
--- a/src/main/java/net/minecraft/world/level/Level.java
+++ b/src/main/java/net/minecraft/world/level/Level.java
@@ -338,7 +338,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
@@ -339,7 +339,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
}
private static boolean isInWorldBoundsHorizontal(BlockPos pos) {
@ -18,7 +18,7 @@ index 1408faa8754b2492879f2dbb525aba3bfc8f0421..0fb975d74b8e91617de91dacb206699f
private static boolean isOutsideSpawnableHeight(int y) {
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
index a9106f4777d05928d432e14e4998fd06df5a0786..606797b07bb5eb0ce8fa9d01eaa74e0d6c10b56b 100644
index 339c2d844126b287adf613a5be1b90f2056dabd9..9391259ffbee1da5c92ad4a253d99617aa57871a 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
@@ -319,9 +319,24 @@ public class CraftWorld extends CraftRegionAccessor implements World {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Custom Chat Completion Suggestions API
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 898259c35c25ee034c859e210350efc19c559e3b..7e6ae084118e36eb1be9b5598eeb7e8885179eae 100644
index 48c1af4bfa97d2c4e8fd695af5b9cefb5398db97..fadfa40fff32b0299d642c89b2dbc3cf4082adb9 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -689,6 +689,24 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@@ -691,6 +691,24 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
}
// Paper end - Add sendOpLevel API

Datei anzeigen

@ -10,7 +10,7 @@ potentially waterlogged block states fading.
Co-authored-by: Lulu13022002 <41980282+Lulu13022002@users.noreply.github.com
diff --git a/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java b/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java
index a3339b47165814238351d307c729af14d5e5d1ff..2c076a5b23c09f634fa6807c207e5e06e1795e8a 100644
index 6e7595193275e88c69b82ebbc9f9df636879a03e..3c4949965c0fad3c6200d0fd1e31ebe844ba6e0e 100644
--- a/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/FrogspawnBlock.java
@@ -92,6 +92,11 @@ public class FrogspawnBlock extends Block {

Datei anzeigen

@ -5,10 +5,10 @@ Subject: [PATCH] Collision API
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java
index 4cacc8a8f5d04ea0e1f087194481fa749efa1797..fce1e4bc4898f10c7e8ae788630a55e42e99dd20 100644
index f6dd8665b9f6e2a8ff396deba8a021e695bedf7e..3c1937b43b6834ae0ffdd8d22ac32a776bc7fb64 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java
@@ -542,5 +542,12 @@ public abstract class CraftRegionAccessor implements RegionAccessor {
@@ -543,5 +543,12 @@ public abstract class CraftRegionAccessor implements RegionAccessor {
return this.getHandle().clip(new net.minecraft.world.level.ClipContext(start, end, net.minecraft.world.level.ClipContext.Block.COLLIDER, net.minecraft.world.level.ClipContext.Fluid.NONE, net.minecraft.world.phys.shapes.CollisionContext.empty())).getType() == net.minecraft.world.phys.HitResult.Type.MISS;
}
@ -22,10 +22,10 @@ index 4cacc8a8f5d04ea0e1f087194481fa749efa1797..fce1e4bc4898f10c7e8ae788630a55e4
// Paper end
}
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
index b6fef2ca5b564c293cb602cb8e300d35dba89b1f..92c80776273f6be43b40686c7ab7dd7371b1c06f 100644
index 243ac4253a1541dba52126bad96682e43c6f48a1..7c223042595c7cd5ccc554211657d9375833122b 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
@@ -1174,4 +1174,20 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
@@ -1191,4 +1191,20 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
return this.getHandle().noPhysics;
}
// Paper end - missing entity api

Datei anzeigen

@ -6,10 +6,10 @@ Subject: [PATCH] Fix suggest command message for brigadier syntax exceptions
This is a bug accidentally introduced in upstream CB
diff --git a/src/main/java/net/minecraft/commands/Commands.java b/src/main/java/net/minecraft/commands/Commands.java
index 779fee2f9b819124a01b9f8d2b7ed0d5f2accf6c..3d6e19c2078a87983a849e6d627cba0609a556cc 100644
index 3141e033706599aae9a89a0975afb3954424df48..ec8ea29a71e74255660e3c084c3a708cf241d0c9 100644
--- a/src/main/java/net/minecraft/commands/Commands.java
+++ b/src/main/java/net/minecraft/commands/Commands.java
@@ -388,7 +388,7 @@ public class Commands {
@@ -386,7 +386,7 @@ public class Commands {
if (commandsyntaxexception.getInput() != null && commandsyntaxexception.getCursor() >= 0) {
int i = Math.min(commandsyntaxexception.getInput().length(), commandsyntaxexception.getCursor());
MutableComponent ichatmutablecomponent = Component.empty().withStyle(ChatFormatting.GRAY).withStyle((chatmodifier) -> {

Datei anzeigen

@ -106,10 +106,10 @@ index 0000000000000000000000000000000000000000..3c31ff3330c2e925e205c0c9ff4f0b83
+ }
+}
diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
index bbbadf5284907531eef761a738c3adf5305bd08f..c58e24e0138495748564ff8a08782ffd6522fa38 100644
index 585d3e51b4af87327fc2bc64a49f09732a8c61ab..aa39bdb0a4ba8fedf5052ea9700afa7d4d2a4300 100644
--- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
+++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
@@ -287,13 +287,20 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface
@@ -291,13 +291,20 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface
this.server.enablePlugins(org.bukkit.plugin.PluginLoadOrder.STARTUP);
// CraftBukkit end
@ -134,10 +134,10 @@ index bbbadf5284907531eef761a738c3adf5305bd08f..c58e24e0138495748564ff8a08782ffd
DedicatedServer.LOGGER.warn("While this makes the game possible to play without internet access, it also opens up the ability for hackers to connect with any username they choose.");
}
diff --git a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
index 9bcded0466f3b10fafd709edc44c60f85cb48b7f..cb006ae0e5be2f1d31261bdd36964229ec44416d 100644
index e9cd90b6bb2f57d605323add43f12962bd7cb843..0fc30ce511f449d2a3ddab28c86f7e388223ece1 100644
--- a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
@@ -84,6 +84,7 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
@@ -86,6 +86,7 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
private final boolean transferred;
private ServerPlayer player; // CraftBukkit
public boolean iKnowThisMayNotBeTheBestIdeaButPleaseDisableUsernameValidation = false; // Paper - username validation overriding
@ -145,7 +145,7 @@ index 9bcded0466f3b10fafd709edc44c60f85cb48b7f..cb006ae0e5be2f1d31261bdd36964229
public ServerLoginPacketListenerImpl(MinecraftServer server, Connection connection, boolean transferred) {
this.state = ServerLoginPacketListenerImpl.State.HELLO;
@@ -182,6 +183,16 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
@@ -184,6 +185,16 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
this.state = ServerLoginPacketListenerImpl.State.KEY;
this.connection.send(new ClientboundHelloPacket("", this.server.getKeyPair().getPublic().getEncoded(), this.challenge, true));
} else {
@ -162,7 +162,7 @@ index 9bcded0466f3b10fafd709edc44c60f85cb48b7f..cb006ae0e5be2f1d31261bdd36964229
// CraftBukkit start
// Paper start - Cache authenticator threads
authenticatorPool.execute(new Runnable() {
@@ -334,6 +345,12 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
@@ -336,6 +347,12 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
// CraftBukkit start
private GameProfile callPlayerPreLoginEvents(GameProfile gameprofile) throws Exception { // Paper - Add more fields to AsyncPlayerPreLoginEvent
@ -175,7 +175,7 @@ index 9bcded0466f3b10fafd709edc44c60f85cb48b7f..cb006ae0e5be2f1d31261bdd36964229
String playerName = gameprofile.getName();
java.net.InetAddress address = ((java.net.InetSocketAddress) this.connection.getRemoteAddress()).getAddress();
java.util.UUID uniqueId = gameprofile.getId();
@@ -379,6 +396,51 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
@@ -381,6 +398,51 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
@Override
public void handleCustomQueryPacket(ServerboundCustomQueryAnswerPacket packet) {
@ -228,10 +228,10 @@ index 9bcded0466f3b10fafd709edc44c60f85cb48b7f..cb006ae0e5be2f1d31261bdd36964229
}
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 8b629647c15721207f14081832bea6a702359b77..e135d634f4336a23e90fd94b4e4c261bfc0cffe9 100644
index 873daccd9c9521e75dcca5e5070ffcbbac00956a..0aebc39477e4302c2660786011633164b6e7cc9d 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -833,7 +833,7 @@ public final class CraftServer implements Server {
@@ -836,7 +836,7 @@ public final class CraftServer implements Server {
@Override
public long getConnectionThrottle() {
// Spigot Start - Automatically set connection throttle for bungee configurations

Datei anzeigen

@ -6,7 +6,7 @@ Subject: [PATCH] Add NamespacedKey biome methods
Co-authored-by: Thonk <30448663+ExcessiveAmountsOfZombies@users.noreply.github.com>
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
index 83730eac9887bbf9bd5284676ec9a0509ec14a04..ff2c6a7b4b8ae2f7e9e1c84e1a3bd04e0484d075 100644
index 1a46245fed7a5fca532df7e3febb22f5effca764..7272f154644366c3c467b265aadc59b879a7b7bd 100644
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
@@ -595,6 +595,21 @@ public final class CraftMagicNumbers implements UnsafeValues {

Einige Dateien werden nicht angezeigt, da zu viele Dateien in diesem Diff geändert wurden Mehr anzeigen