From ac0e1997ee47fff370e1329a01a96fbfa5c9c0db Mon Sep 17 00:00:00 2001 From: Spottedleaf Date: Tue, 7 Jun 2022 21:06:41 -0700 Subject: [PATCH] <3 jmp --- .../server/Add-Raw-Byte-ItemStack-Serialization.patch | 0 .../server/Add-ThrownEggHatchEvent.patch | 0 .../server/Add-debug-for-sync-chunk-loads.patch | 0 ...-option-to-allow-iron-golems-to-spawn-in-air.patch | 0 ...dd-option-to-nerf-pigmen-from-nether-portals.patch | 0 .../server/Add-tick-times-API-and-mspt-command.patch | 5 +++-- .../Avoid-hopper-searches-if-there-are-no-items.patch | 0 .../Bees-get-gravity-in-void.-Fixes-MC-167279.patch | 0 ...igurable-chance-of-villager-zombie-infection.patch | 11 ++++++----- patches/{unapplied => }/server/Entity-Jump-API.patch | 0 .../server/Expose-MinecraftServer-isRunning.patch | 0 .../Fix-items-vanishing-through-end-portal.patch | 0 .../Implement-alternative-item-despawn-rate.patch | 0 .../server/Make-the-GUI-graph-fancier.patch | 0 .../server/Optimise-Chunk-getFluid.patch | 0 .../Optimise-getChunkAt-calls-for-loaded-chunks.patch | 0 .../server/Remove-garbage-Java-version-check.patch | 0 ...pigots-verbose-world-setting-to-false-by-def.patch | 0 .../server/Tracking-Range-Improvements.patch | 0 ...lidate-tripwire-hook-placement-before-update.patch | 2 +- .../server/add-hand-to-BlockMultiPlaceEvent.patch | 0 .../implement-optional-per-player-mob-spawns.patch | 8 +++----- 22 files changed, 13 insertions(+), 13 deletions(-) rename patches/{unapplied => }/server/Add-Raw-Byte-ItemStack-Serialization.patch (100%) rename patches/{unapplied => }/server/Add-ThrownEggHatchEvent.patch (100%) rename patches/{unapplied => }/server/Add-debug-for-sync-chunk-loads.patch (100%) rename patches/{unapplied => }/server/Add-option-to-allow-iron-golems-to-spawn-in-air.patch (100%) rename patches/{unapplied => }/server/Add-option-to-nerf-pigmen-from-nether-portals.patch (100%) rename patches/{unapplied => }/server/Add-tick-times-API-and-mspt-command.patch (98%) rename patches/{unapplied => }/server/Avoid-hopper-searches-if-there-are-no-items.patch (100%) rename patches/{unapplied => }/server/Bees-get-gravity-in-void.-Fixes-MC-167279.patch (100%) rename patches/{unapplied => }/server/Configurable-chance-of-villager-zombie-infection.patch (92%) rename patches/{unapplied => }/server/Entity-Jump-API.patch (100%) rename patches/{unapplied => }/server/Expose-MinecraftServer-isRunning.patch (100%) rename patches/{unapplied => }/server/Fix-items-vanishing-through-end-portal.patch (100%) rename patches/{unapplied => }/server/Implement-alternative-item-despawn-rate.patch (100%) rename patches/{unapplied => }/server/Make-the-GUI-graph-fancier.patch (100%) rename patches/{unapplied => }/server/Optimise-Chunk-getFluid.patch (100%) rename patches/{unapplied => }/server/Optimise-getChunkAt-calls-for-loaded-chunks.patch (100%) rename patches/{unapplied => }/server/Remove-garbage-Java-version-check.patch (100%) rename patches/{unapplied => }/server/Set-spigots-verbose-world-setting-to-false-by-def.patch (100%) rename patches/{unapplied => }/server/Tracking-Range-Improvements.patch (100%) rename patches/{unapplied => }/server/Validate-tripwire-hook-placement-before-update.patch (94%) rename patches/{unapplied => }/server/add-hand-to-BlockMultiPlaceEvent.patch (100%) rename patches/{unapplied => }/server/implement-optional-per-player-mob-spawns.patch (99%) diff --git a/patches/unapplied/server/Add-Raw-Byte-ItemStack-Serialization.patch b/patches/server/Add-Raw-Byte-ItemStack-Serialization.patch similarity index 100% rename from patches/unapplied/server/Add-Raw-Byte-ItemStack-Serialization.patch rename to patches/server/Add-Raw-Byte-ItemStack-Serialization.patch diff --git a/patches/unapplied/server/Add-ThrownEggHatchEvent.patch b/patches/server/Add-ThrownEggHatchEvent.patch similarity index 100% rename from patches/unapplied/server/Add-ThrownEggHatchEvent.patch rename to patches/server/Add-ThrownEggHatchEvent.patch diff --git a/patches/unapplied/server/Add-debug-for-sync-chunk-loads.patch b/patches/server/Add-debug-for-sync-chunk-loads.patch similarity index 100% rename from patches/unapplied/server/Add-debug-for-sync-chunk-loads.patch rename to patches/server/Add-debug-for-sync-chunk-loads.patch diff --git a/patches/unapplied/server/Add-option-to-allow-iron-golems-to-spawn-in-air.patch b/patches/server/Add-option-to-allow-iron-golems-to-spawn-in-air.patch similarity index 100% rename from patches/unapplied/server/Add-option-to-allow-iron-golems-to-spawn-in-air.patch rename to patches/server/Add-option-to-allow-iron-golems-to-spawn-in-air.patch diff --git a/patches/unapplied/server/Add-option-to-nerf-pigmen-from-nether-portals.patch b/patches/server/Add-option-to-nerf-pigmen-from-nether-portals.patch similarity index 100% rename from patches/unapplied/server/Add-option-to-nerf-pigmen-from-nether-portals.patch rename to patches/server/Add-option-to-nerf-pigmen-from-nether-portals.patch diff --git a/patches/unapplied/server/Add-tick-times-API-and-mspt-command.patch b/patches/server/Add-tick-times-API-and-mspt-command.patch similarity index 98% rename from patches/unapplied/server/Add-tick-times-API-and-mspt-command.patch rename to patches/server/Add-tick-times-API-and-mspt-command.patch index 068cffed4c..8491ec021f 100644 --- a/patches/unapplied/server/Add-tick-times-API-and-mspt-command.patch +++ b/patches/server/Add-tick-times-API-and-mspt-command.patch @@ -151,9 +151,10 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 this.profiler.pop(); org.spigotmc.WatchdogThread.tick(); // Spigot @@ -0,0 +0,0 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop level.paperConfig.zombieVillagerInfectionChance) { -+ return; ++ return flag; + } // Paper end Villager entityvillager = (Villager) other; diff --git a/patches/unapplied/server/Entity-Jump-API.patch b/patches/server/Entity-Jump-API.patch similarity index 100% rename from patches/unapplied/server/Entity-Jump-API.patch rename to patches/server/Entity-Jump-API.patch diff --git a/patches/unapplied/server/Expose-MinecraftServer-isRunning.patch b/patches/server/Expose-MinecraftServer-isRunning.patch similarity index 100% rename from patches/unapplied/server/Expose-MinecraftServer-isRunning.patch rename to patches/server/Expose-MinecraftServer-isRunning.patch diff --git a/patches/unapplied/server/Fix-items-vanishing-through-end-portal.patch b/patches/server/Fix-items-vanishing-through-end-portal.patch similarity index 100% rename from patches/unapplied/server/Fix-items-vanishing-through-end-portal.patch rename to patches/server/Fix-items-vanishing-through-end-portal.patch diff --git a/patches/unapplied/server/Implement-alternative-item-despawn-rate.patch b/patches/server/Implement-alternative-item-despawn-rate.patch similarity index 100% rename from patches/unapplied/server/Implement-alternative-item-despawn-rate.patch rename to patches/server/Implement-alternative-item-despawn-rate.patch diff --git a/patches/unapplied/server/Make-the-GUI-graph-fancier.patch b/patches/server/Make-the-GUI-graph-fancier.patch similarity index 100% rename from patches/unapplied/server/Make-the-GUI-graph-fancier.patch rename to patches/server/Make-the-GUI-graph-fancier.patch diff --git a/patches/unapplied/server/Optimise-Chunk-getFluid.patch b/patches/server/Optimise-Chunk-getFluid.patch similarity index 100% rename from patches/unapplied/server/Optimise-Chunk-getFluid.patch rename to patches/server/Optimise-Chunk-getFluid.patch diff --git a/patches/unapplied/server/Optimise-getChunkAt-calls-for-loaded-chunks.patch b/patches/server/Optimise-getChunkAt-calls-for-loaded-chunks.patch similarity index 100% rename from patches/unapplied/server/Optimise-getChunkAt-calls-for-loaded-chunks.patch rename to patches/server/Optimise-getChunkAt-calls-for-loaded-chunks.patch diff --git a/patches/unapplied/server/Remove-garbage-Java-version-check.patch b/patches/server/Remove-garbage-Java-version-check.patch similarity index 100% rename from patches/unapplied/server/Remove-garbage-Java-version-check.patch rename to patches/server/Remove-garbage-Java-version-check.patch diff --git a/patches/unapplied/server/Set-spigots-verbose-world-setting-to-false-by-def.patch b/patches/server/Set-spigots-verbose-world-setting-to-false-by-def.patch similarity index 100% rename from patches/unapplied/server/Set-spigots-verbose-world-setting-to-false-by-def.patch rename to patches/server/Set-spigots-verbose-world-setting-to-false-by-def.patch diff --git a/patches/unapplied/server/Tracking-Range-Improvements.patch b/patches/server/Tracking-Range-Improvements.patch similarity index 100% rename from patches/unapplied/server/Tracking-Range-Improvements.patch rename to patches/server/Tracking-Range-Improvements.patch diff --git a/patches/unapplied/server/Validate-tripwire-hook-placement-before-update.patch b/patches/server/Validate-tripwire-hook-placement-before-update.patch similarity index 94% rename from patches/unapplied/server/Validate-tripwire-hook-placement-before-update.patch rename to patches/server/Validate-tripwire-hook-placement-before-update.patch index a8abbf7d6b..440eda08ed 100644 --- a/patches/unapplied/server/Validate-tripwire-hook-placement-before-update.patch +++ b/patches/server/Validate-tripwire-hook-placement-before-update.patch @@ -10,7 +10,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 +++ b/src/main/java/net/minecraft/world/level/block/TripWireHookBlock.java @@ -0,0 +0,0 @@ public class TripWireHookBlock extends Block { - this.playSound(world, pos, flag4, flag5, flag2, flag3); + this.emitState(world, pos, flag4, flag5, flag2, flag3); if (!beingRemoved) { + if (world.getBlockState(pos).getBlock() == Blocks.TRIPWIRE_HOOK) // Paper - validate world.setBlock(pos, (BlockState) iblockdata3.setValue(TripWireHookBlock.FACING, enumdirection), 3); diff --git a/patches/unapplied/server/add-hand-to-BlockMultiPlaceEvent.patch b/patches/server/add-hand-to-BlockMultiPlaceEvent.patch similarity index 100% rename from patches/unapplied/server/add-hand-to-BlockMultiPlaceEvent.patch rename to patches/server/add-hand-to-BlockMultiPlaceEvent.patch diff --git a/patches/unapplied/server/implement-optional-per-player-mob-spawns.patch b/patches/server/implement-optional-per-player-mob-spawns.patch similarity index 99% rename from patches/unapplied/server/implement-optional-per-player-mob-spawns.patch rename to patches/server/implement-optional-per-player-mob-spawns.patch index 9006cac549..ddc70ae7b3 100644 --- a/patches/unapplied/server/implement-optional-per-player-mob-spawns.patch +++ b/patches/server/implement-optional-per-player-mob-spawns.patch @@ -422,11 +422,10 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 --- a/src/main/java/net/minecraft/world/level/NaturalSpawner.java +++ b/src/main/java/net/minecraft/world/level/NaturalSpawner.java @@ -0,0 +0,0 @@ public final class NaturalSpawner { - private NaturalSpawner() {} -+ // Paper start - add countMobs parameter public static NaturalSpawner.SpawnState createState(int spawningChunkCount, Iterable entities, NaturalSpawner.ChunkGetter chunkSource, LocalMobCapCalculator localmobcapcalculator) { ++ // Paper start - add countMobs parameter + return createState(spawningChunkCount, entities, chunkSource, localmobcapcalculator, false); + } + @@ -494,11 +493,10 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 } @@ -0,0 +0,0 @@ public final class NaturalSpawner { - world.getProfiler().pop(); } -+ // Paper start - add parameters and int ret type public static void spawnCategoryForChunk(MobCategory group, ServerLevel world, LevelChunk chunk, NaturalSpawner.SpawnPredicate checker, NaturalSpawner.AfterSpawnCallback runner) { ++ // Paper start - add parameters and int ret type + spawnCategoryForChunk(group, world, chunk, checker, runner, Integer.MAX_VALUE, null); + } + public static int spawnCategoryForChunk(MobCategory group, ServerLevel world, LevelChunk chunk, NaturalSpawner.SpawnPredicate checker, NaturalSpawner.AfterSpawnCallback runner, int maxSpawns, Consumer trackEntity) { @@ -523,7 +521,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + } + public static int spawnCategoryForPosition(MobCategory group, ServerLevel world, ChunkAccess chunk, BlockPos pos, NaturalSpawner.SpawnPredicate checker, NaturalSpawner.AfterSpawnCallback runner, int maxSpawns, Consumer trackEntity) { + // Paper end - add maxSpawns parameter and return spawned mobs - StructureFeatureManager structuremanager = world.structureFeatureManager(); + StructureManager structuremanager = world.structureManager(); ChunkGenerator chunkgenerator = world.getChunkSource().getGenerator(); int i = pos.getY(); BlockState iblockdata = world.getBlockStateIfLoadedAndInBounds(pos); // Paper - don't load chunks for mob spawn