From eac356d807c51ba56b6b79254c25b364b691a164 Mon Sep 17 00:00:00 2001 From: Nassim Jahnke Date: Wed, 7 Dec 2022 20:22:28 +0100 Subject: [PATCH] Patching patched patches --- ...ile-Entities-from-a-chunk-without-sn.patch | 0 ...-replace-OfflinePlayer-getLastPlayed.patch | 0 ...ies-option-to-debug-dupe-uuid-issues.patch | 0 ...dd-Early-Warning-Feature-to-WatchDog.patch | 0 .../server/Add-Heightmap-API.patch | 0 .../Add-LivingEntity-getTargetEntity.patch | 0 .../server/Add-More-Creeper-API.patch | 0 .../server/Add-PhantomPreSpawnEvent.patch | 11 +- .../Add-PlayerConnectionCloseEvent.patch | 0 ...Add-Raw-Byte-ItemStack-Serialization.patch | 0 .../server/Add-TNTPrimeEvent.patch | 2 +- .../server/Add-ThrownEggHatchEvent.patch | 0 .../Add-debug-for-sync-chunk-loads.patch | 0 .../Add-effect-to-block-break-naturally.patch | 0 .../server/Add-more-Witch-API.patch | 0 .../server/Add-more-Zombie-API.patch | 0 ...to-allow-iron-golems-to-spawn-in-air.patch | 0 ...d-option-to-disable-pillager-patrols.patch | 0 ...n-to-nerf-pigmen-from-nether-portals.patch | 0 ...event-players-from-moving-into-unloa.patch | 0 ...-ray-tracing-methods-to-LivingEntity.patch | 0 .../server/Add-sun-related-API.patch | 0 .../Add-tick-times-API-and-mspt-command.patch | 0 .../Allow-Saving-of-Oversized-Chunks.patch | 4 +- ...ow-chests-to-be-placed-with-NBT-data.patch | 0 .../{unapplied => }/server/Anti-Xray.patch | 14 +- .../server/AnvilDamageEvent.patch | 0 .../server/Async-command-map-building.patch | 0 ...get-gravity-in-void.-Fixes-MC-167279.patch | 0 ...-remove-from-being-called-on-Players.patch | 0 .../server/BlockDestroyEvent.patch | 0 .../server/Book-Size-Limits.patch | 0 ...nd-make-tab-spam-limits-configurable.patch | 0 ...oggleEvent-when-whitelist-is-toggled.patch | 0 ...tator-target-events-and-improve-impl.patch | 10 +- ...arseException-in-Entity-and-TE-names.patch | 2 +- ...owned-for-Villager-Aggression-Config.patch | 0 ...le-Keep-Spawn-Loaded-range-per-world.patch | 0 ...-chance-of-villager-zombie-infection.patch | 8 +- ...ble-connection-throttle-kick-message.patch | 0 ...gurable-projectile-relative-velocity.patch | 0 ...le-speed-for-water-flowing-over-lava.patch | 0 ...d-Player-s-shouldn-t-be-able-to-move.patch | 0 ...low-bees-to-load-chunks-for-beehives.patch | 0 ...t-allow-digging-into-unloaded-chunks.patch | 0 ...ConvertSigns-boolean-every-sign-save.patch | 2 +- ...Chunks-from-Hoppers-and-other-things.patch | 0 ...move-existing-players-to-world-spawn.patch | 0 ...-after-profile-lookups-if-not-needed.patch | 0 .../server/Don-t-tick-dead-players.patch | 0 .../Dont-send-unnecessary-sign-update.patch | 0 .../Duplicate-UUID-Resolve-Option.patch | 0 .../server/Entity-Activation-Range-2.0.patch | 6 +- .../server/Entity-Jump-API.patch | 0 .../server/Entity-getEntitySpawnReason.patch | 0 .../Expose-MinecraftServer-isRunning.patch | 0 ...e-attack-cooldown-methods-for-Player.patch | 0 .../Expose-the-internal-current-tick.patch | 0 .../server/Fire-event-on-GS4-query.patch | 0 ...l-to-changed-postToMainThread-method.patch | 0 ...om-Shapeless-Custom-Crafting-Recipes.patch | 0 .../server/Fix-MC-158900.patch | 0 .../server/Fix-NBT-type-issues.patch | 0 .../Fix-SpongeAbsortEvent-handling.patch | 0 .../Fix-World-isChunkGenerated-calls.patch | 0 .../Fix-items-not-falling-correctly.patch | 0 ...x-items-vanishing-through-end-portal.patch | 0 ...k-in-stack-not-having-effects-when-d.patch | 0 ...n-item-frames-are-modified-MC-123450.patch | 0 .../Flat-bedrock-generator-settings.patch | 8 +- ...rializing-mismatching-chunk-coordina.patch | 0 ...e-Large-Packets-disconnecting-client.patch | 0 ...le-Oversized-Tile-Entities-in-chunks.patch | 0 .../server/Honor-EntityAgeable.ageLock.patch | 0 .../server/Hook-into-CB-plugin-rewrites.patch | 0 .../Implement-Brigadier-Mojang-API.patch | 2 +- .../Implement-CraftBlockSoundGroup.patch | 0 .../Implement-PlayerPostRespawnEvent.patch | 0 ...lement-alternative-item-despawn-rate.patch | 0 ...-for-CanPlaceOn-and-CanDestroy-NBT-v.patch | 0 ...nt-furnace-cook-speed-multiplier-API.patch | 0 ...er-Thread-Pool-and-Thread-Priorities.patch | 0 .../server/Improve-death-events.patch | 2 +- .../server/Improved-Watchdog-Support.patch | 4 +- .../server/Increase-Light-Queue-Size.patch | 0 .../server/Inventory-removeItemAnySlot.patch | 0 .../server/Lag-compensate-eating.patch | 2 +- .../Limit-Client-Sign-length-more.patch | 2 +- ...5656-Fix-Follow-Range-Initial-Target.patch | 0 ...ther-worlds-for-shooter-of-projectil.patch | 0 ...loadChunk-int-int-false-load-unconve.patch | 0 .../server/Make-the-GUI-graph-fancier.patch | 0 ...ault-permission-message-configurable.patch | 0 .../server/Mob-Pathfinding-API.patch | 0 .../server/Mob-Spawner-API-Enhancements.patch | 6 +- ...al-Spawned-mobs-towards-natural-spaw.patch | 0 .../server/Optimise-Chunk-getFluid.patch | 0 ...ptimise-EntityGetter-getPlayerByUUID.patch | 2 +- ...e-getChunkAt-calls-for-loaded-chunks.patch | 0 ...ptimize-BlockPosition-helper-methods.patch | 0 .../Optimize-Captured-TileEntity-Lookup.patch | 0 ...ptimize-Collision-to-not-load-chunks.patch | 0 .../Optimize-CraftBlockData-Creation.patch | 4 +- ...oalSelector-Goal.Flag-Set-operations.patch | 0 .../server/Optimize-Hoppers.patch | 0 .../server/Optimize-MappedRegistry.patch | 24 +-- ...-Manager-and-add-advanced-packet-sup.patch | 0 .../server/Optimize-Pathfinding.patch | 0 .../server/Optimize-World-Time-Updates.patch | 0 ...mize-call-to-getFluid-for-explosions.patch | 0 ...spawn-settings-and-per-player-option.patch | 0 .../PlayerDeathEvent-getItemsToKeep.patch | 0 ...layerDeathEvent-shouldDropExperience.patch | 0 .../server/PreSpawnerSpawnEvent.patch | 0 ...-PlayerChunkMap-adds-crashing-server.patch | 0 ...Prevent-Enderman-from-loading-chunks.patch | 0 ...ent-Mob-AI-Rules-from-Loading-Chunks.patch | 0 ...oading-chunks-checking-hive-position.patch | 2 +- ...ent-chunk-loading-from-Fluid-Flowing.patch | 0 ...revent-consuming-the-wrong-itemstack.patch | 0 ...wning-from-loading-generating-chunks.patch | 0 ...Prevent-rayTrace-from-loading-chunks.patch | 0 ...nk-loads-when-villagers-try-to-find-.patch | 0 .../Reduce-Either-Optional-allocation.patch | 0 ...e-memory-footprint-of-NBTTagCompound.patch | 0 ...nnections-shouldn-t-hold-up-shutdown.patch | 0 .../Remove-garbage-Java-version-check.patch | 0 ...Remove-unnecessary-itemmeta-handling.patch | 0 .../Reset-players-airTicks-on-respawn.patch | 0 ...store-custom-InventoryHolder-support.patch | 0 ...default-mob-spawn-range-and-water-an.patch | 0 .../server/Server-Tick-Events.patch | 0 ...erbose-world-setting-to-false-by-def.patch | 0 ...ate-location-if-we-failed-to-read-it.patch | 0 .../server/Slime-Pathfinder-Events.patch | 0 patches/server/Starlight.patch | 3 +- .../server/Tracking-Range-Improvements.patch | 0 .../{unapplied => }/server/Turtle-API.patch | 0 .../Use-ConcurrentHashMap-in-JsonList.patch | 0 .../server/Use-Vanilla-Minecart-Speeds.patch | 0 .../Use-a-Queue-for-Queueing-Commands.patch | 0 ...ripwire-hook-placement-before-update.patch | 0 ...vehicle-tracking-issue-on-disconnect.patch | 0 .../add-hand-to-BlockMultiPlaceEvent.patch | 0 ...-for-pickupDelay-breaks-picking-up-i.patch | 0 ...entity-dismount-during-teleportation.patch | 0 ...ement-optional-per-player-mob-spawns.patch | 0 .../server/offset-item-frame-ticking.patch | 0 .../server/Properly-resend-entities.patch | 147 ------------------ 149 files changed, 64 insertions(+), 203 deletions(-) rename patches/{unapplied => }/server/Ability-to-get-Tile-Entities-from-a-chunk-without-sn.patch (100%) rename patches/{unapplied => }/server/Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch (100%) rename patches/{unapplied => }/server/Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch (100%) rename patches/{unapplied => }/server/Add-Early-Warning-Feature-to-WatchDog.patch (100%) rename patches/{unapplied => }/server/Add-Heightmap-API.patch (100%) rename patches/{unapplied => }/server/Add-LivingEntity-getTargetEntity.patch (100%) rename patches/{unapplied => }/server/Add-More-Creeper-API.patch (100%) rename patches/{unapplied => }/server/Add-PhantomPreSpawnEvent.patch (86%) rename patches/{unapplied => }/server/Add-PlayerConnectionCloseEvent.patch (100%) rename patches/{unapplied => }/server/Add-Raw-Byte-ItemStack-Serialization.patch (100%) rename patches/{unapplied => }/server/Add-TNTPrimeEvent.patch (99%) 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-effect-to-block-break-naturally.patch (100%) rename patches/{unapplied => }/server/Add-more-Witch-API.patch (100%) rename patches/{unapplied => }/server/Add-more-Zombie-API.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-disable-pillager-patrols.patch (100%) rename patches/{unapplied => }/server/Add-option-to-nerf-pigmen-from-nether-portals.patch (100%) rename patches/{unapplied => }/server/Add-option-to-prevent-players-from-moving-into-unloa.patch (100%) rename patches/{unapplied => }/server/Add-ray-tracing-methods-to-LivingEntity.patch (100%) rename patches/{unapplied => }/server/Add-sun-related-API.patch (100%) rename patches/{unapplied => }/server/Add-tick-times-API-and-mspt-command.patch (100%) rename patches/{unapplied => }/server/Allow-Saving-of-Oversized-Chunks.patch (99%) rename patches/{unapplied => }/server/Allow-chests-to-be-placed-with-NBT-data.patch (100%) rename patches/{unapplied => }/server/Anti-Xray.patch (98%) rename patches/{unapplied => }/server/AnvilDamageEvent.patch (100%) rename patches/{unapplied => }/server/Async-command-map-building.patch (100%) rename patches/{unapplied => }/server/Bees-get-gravity-in-void.-Fixes-MC-167279.patch (100%) rename patches/{unapplied => }/server/Block-Entity-remove-from-being-called-on-Players.patch (100%) rename patches/{unapplied => }/server/BlockDestroyEvent.patch (100%) rename patches/{unapplied => }/server/Book-Size-Limits.patch (100%) rename patches/{unapplied => }/server/Break-up-and-make-tab-spam-limits-configurable.patch (100%) rename patches/{unapplied => }/server/Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch (100%) rename patches/{unapplied => }/server/Call-player-spectator-target-events-and-improve-impl.patch (98%) rename patches/{unapplied => }/server/Catch-JsonParseException-in-Entity-and-TE-names.patch (99%) rename patches/{unapplied => }/server/Check-Drowned-for-Villager-Aggression-Config.patch (100%) rename patches/{unapplied => }/server/Configurable-Keep-Spawn-Loaded-range-per-world.patch (100%) rename patches/{unapplied => }/server/Configurable-chance-of-villager-zombie-infection.patch (87%) rename patches/{unapplied => }/server/Configurable-connection-throttle-kick-message.patch (100%) rename patches/{unapplied => }/server/Configurable-projectile-relative-velocity.patch (100%) rename patches/{unapplied => }/server/Configurable-speed-for-water-flowing-over-lava.patch (100%) rename patches/{unapplied => }/server/Dead-Player-s-shouldn-t-be-able-to-move.patch (100%) rename patches/{unapplied => }/server/Do-not-allow-bees-to-load-chunks-for-beehives.patch (100%) rename patches/{unapplied => }/server/Don-t-allow-digging-into-unloaded-chunks.patch (100%) rename patches/{unapplied => }/server/Don-t-check-ConvertSigns-boolean-every-sign-save.patch (92%) rename patches/{unapplied => }/server/Don-t-load-Chunks-from-Hoppers-and-other-things.patch (100%) rename patches/{unapplied => }/server/Don-t-move-existing-players-to-world-spawn.patch (100%) rename patches/{unapplied => }/server/Don-t-sleep-after-profile-lookups-if-not-needed.patch (100%) rename patches/{unapplied => }/server/Don-t-tick-dead-players.patch (100%) rename patches/{unapplied => }/server/Dont-send-unnecessary-sign-update.patch (100%) rename patches/{unapplied => }/server/Duplicate-UUID-Resolve-Option.patch (100%) rename patches/{unapplied => }/server/Entity-Activation-Range-2.0.patch (99%) rename patches/{unapplied => }/server/Entity-Jump-API.patch (100%) rename patches/{unapplied => }/server/Entity-getEntitySpawnReason.patch (100%) rename patches/{unapplied => }/server/Expose-MinecraftServer-isRunning.patch (100%) rename patches/{unapplied => }/server/Expose-attack-cooldown-methods-for-Player.patch (100%) rename patches/{unapplied => }/server/Expose-the-internal-current-tick.patch (100%) rename patches/{unapplied => }/server/Fire-event-on-GS4-query.patch (100%) rename patches/{unapplied => }/server/Fix-CB-call-to-changed-postToMainThread-method.patch (100%) rename patches/{unapplied => }/server/Fix-Custom-Shapeless-Custom-Crafting-Recipes.patch (100%) rename patches/{unapplied => }/server/Fix-MC-158900.patch (100%) rename patches/{unapplied => }/server/Fix-NBT-type-issues.patch (100%) rename patches/{unapplied => }/server/Fix-SpongeAbsortEvent-handling.patch (100%) rename patches/{unapplied => }/server/Fix-World-isChunkGenerated-calls.patch (100%) rename patches/{unapplied => }/server/Fix-items-not-falling-correctly.patch (100%) rename patches/{unapplied => }/server/Fix-items-vanishing-through-end-portal.patch (100%) rename patches/{unapplied => }/server/Fix-last-firework-in-stack-not-having-effects-when-d.patch (100%) rename patches/{unapplied => }/server/Fix-sounds-when-item-frames-are-modified-MC-123450.patch (100%) rename patches/{unapplied => }/server/Flat-bedrock-generator-settings.patch (97%) rename patches/{unapplied => }/server/Guard-against-serializing-mismatching-chunk-coordina.patch (100%) rename patches/{unapplied => }/server/Handle-Large-Packets-disconnecting-client.patch (100%) rename patches/{unapplied => }/server/Handle-Oversized-Tile-Entities-in-chunks.patch (100%) rename patches/{unapplied => }/server/Honor-EntityAgeable.ageLock.patch (100%) rename patches/{unapplied => }/server/Hook-into-CB-plugin-rewrites.patch (100%) rename patches/{unapplied => }/server/Implement-Brigadier-Mojang-API.patch (99%) rename patches/{unapplied => }/server/Implement-CraftBlockSoundGroup.patch (100%) rename patches/{unapplied => }/server/Implement-PlayerPostRespawnEvent.patch (100%) rename patches/{unapplied => }/server/Implement-alternative-item-despawn-rate.patch (100%) rename patches/{unapplied => }/server/Implement-an-API-for-CanPlaceOn-and-CanDestroy-NBT-v.patch (100%) rename patches/{unapplied => }/server/Implement-furnace-cook-speed-multiplier-API.patch (100%) rename patches/{unapplied => }/server/Improve-Server-Thread-Pool-and-Thread-Priorities.patch (100%) rename patches/{unapplied => }/server/Improve-death-events.patch (99%) rename patches/{unapplied => }/server/Improved-Watchdog-Support.patch (99%) rename patches/{unapplied => }/server/Increase-Light-Queue-Size.patch (100%) rename patches/{unapplied => }/server/Inventory-removeItemAnySlot.patch (100%) rename patches/{unapplied => }/server/Lag-compensate-eating.patch (96%) rename patches/{unapplied => }/server/Limit-Client-Sign-length-more.patch (97%) rename patches/{unapplied => }/server/MC-145656-Fix-Follow-Range-Initial-Target.patch (100%) rename patches/{unapplied => }/server/MC-50319-Check-other-worlds-for-shooter-of-projectil.patch (100%) rename patches/{unapplied => }/server/Make-CraftWorld-loadChunk-int-int-false-load-unconve.patch (100%) rename patches/{unapplied => }/server/Make-the-GUI-graph-fancier.patch (100%) rename patches/{unapplied => }/server/Make-the-default-permission-message-configurable.patch (100%) rename patches/{unapplied => }/server/Mob-Pathfinding-API.patch (100%) rename patches/{unapplied => }/server/Mob-Spawner-API-Enhancements.patch (95%) rename patches/{unapplied => }/server/Only-count-Natural-Spawned-mobs-towards-natural-spaw.patch (100%) rename patches/{unapplied => }/server/Optimise-Chunk-getFluid.patch (100%) rename patches/{unapplied => }/server/Optimise-EntityGetter-getPlayerByUUID.patch (94%) rename patches/{unapplied => }/server/Optimise-getChunkAt-calls-for-loaded-chunks.patch (100%) rename patches/{unapplied => }/server/Optimize-BlockPosition-helper-methods.patch (100%) rename patches/{unapplied => }/server/Optimize-Captured-TileEntity-Lookup.patch (100%) rename patches/{unapplied => }/server/Optimize-Collision-to-not-load-chunks.patch (100%) rename patches/{unapplied => }/server/Optimize-CraftBlockData-Creation.patch (94%) rename patches/{unapplied => }/server/Optimize-GoalSelector-Goal.Flag-Set-operations.patch (100%) rename patches/{unapplied => }/server/Optimize-Hoppers.patch (100%) rename patches/{unapplied => }/server/Optimize-MappedRegistry.patch (78%) rename patches/{unapplied => }/server/Optimize-Network-Manager-and-add-advanced-packet-sup.patch (100%) rename patches/{unapplied => }/server/Optimize-Pathfinding.patch (100%) rename patches/{unapplied => }/server/Optimize-World-Time-Updates.patch (100%) rename patches/{unapplied => }/server/Optimize-call-to-getFluid-for-explosions.patch (100%) rename patches/{unapplied => }/server/Pillager-patrol-spawn-settings-and-per-player-option.patch (100%) rename patches/{unapplied => }/server/PlayerDeathEvent-getItemsToKeep.patch (100%) rename patches/{unapplied => }/server/PlayerDeathEvent-shouldDropExperience.patch (100%) rename patches/{unapplied => }/server/PreSpawnerSpawnEvent.patch (100%) rename patches/{unapplied => }/server/Prevent-Double-PlayerChunkMap-adds-crashing-server.patch (100%) rename patches/{unapplied => }/server/Prevent-Enderman-from-loading-chunks.patch (100%) rename patches/{unapplied => }/server/Prevent-Mob-AI-Rules-from-Loading-Chunks.patch (100%) rename patches/{unapplied => }/server/Prevent-bees-loading-chunks-checking-hive-position.patch (95%) rename patches/{unapplied => }/server/Prevent-chunk-loading-from-Fluid-Flowing.patch (100%) rename patches/{unapplied => }/server/Prevent-consuming-the-wrong-itemstack.patch (100%) rename patches/{unapplied => }/server/Prevent-mob-spawning-from-loading-generating-chunks.patch (100%) rename patches/{unapplied => }/server/Prevent-rayTrace-from-loading-chunks.patch (100%) rename patches/{unapplied => }/server/Prevent-sync-chunk-loads-when-villagers-try-to-find-.patch (100%) rename patches/{unapplied => }/server/Reduce-Either-Optional-allocation.patch (100%) rename patches/{unapplied => }/server/Reduce-memory-footprint-of-NBTTagCompound.patch (100%) rename patches/{unapplied => }/server/Remote-Connections-shouldn-t-hold-up-shutdown.patch (100%) rename patches/{unapplied => }/server/Remove-garbage-Java-version-check.patch (100%) rename patches/{unapplied => }/server/Remove-unnecessary-itemmeta-handling.patch (100%) rename patches/{unapplied => }/server/Reset-players-airTicks-on-respawn.patch (100%) rename patches/{unapplied => }/server/Restore-custom-InventoryHolder-support.patch (100%) rename patches/{unapplied => }/server/Restore-vanilla-default-mob-spawn-range-and-water-an.patch (100%) rename patches/{unapplied => }/server/Server-Tick-Events.patch (100%) rename patches/{unapplied => }/server/Set-spigots-verbose-world-setting-to-false-by-def.patch (100%) rename patches/{unapplied => }/server/Show-blockstate-location-if-we-failed-to-read-it.patch (100%) rename patches/{unapplied => }/server/Slime-Pathfinder-Events.patch (100%) rename patches/{unapplied => }/server/Tracking-Range-Improvements.patch (100%) rename patches/{unapplied => }/server/Turtle-API.patch (100%) rename patches/{unapplied => }/server/Use-ConcurrentHashMap-in-JsonList.patch (100%) rename patches/{unapplied => }/server/Use-Vanilla-Minecart-Speeds.patch (100%) rename patches/{unapplied => }/server/Use-a-Queue-for-Queueing-Commands.patch (100%) rename patches/{unapplied => }/server/Validate-tripwire-hook-placement-before-update.patch (100%) rename patches/{unapplied => }/server/Workaround-for-vehicle-tracking-issue-on-disconnect.patch (100%) rename patches/{unapplied => }/server/add-hand-to-BlockMultiPlaceEvent.patch (100%) rename patches/{unapplied => }/server/don-t-go-below-0-for-pickupDelay-breaks-picking-up-i.patch (100%) rename patches/{unapplied => }/server/force-entity-dismount-during-teleportation.patch (100%) rename patches/{unapplied => }/server/implement-optional-per-player-mob-spawns.patch (100%) rename patches/{unapplied => }/server/offset-item-frame-ticking.patch (100%) delete mode 100644 patches/unapplied/server/Properly-resend-entities.patch diff --git a/patches/unapplied/server/Ability-to-get-Tile-Entities-from-a-chunk-without-sn.patch b/patches/server/Ability-to-get-Tile-Entities-from-a-chunk-without-sn.patch similarity index 100% rename from patches/unapplied/server/Ability-to-get-Tile-Entities-from-a-chunk-without-sn.patch rename to patches/server/Ability-to-get-Tile-Entities-from-a-chunk-without-sn.patch diff --git a/patches/unapplied/server/Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch b/patches/server/Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch similarity index 100% rename from patches/unapplied/server/Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch rename to patches/server/Add-APIs-to-replace-OfflinePlayer-getLastPlayed.patch diff --git a/patches/unapplied/server/Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch b/patches/server/Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch similarity index 100% rename from patches/unapplied/server/Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch rename to patches/server/Add-Debug-Entities-option-to-debug-dupe-uuid-issues.patch diff --git a/patches/unapplied/server/Add-Early-Warning-Feature-to-WatchDog.patch b/patches/server/Add-Early-Warning-Feature-to-WatchDog.patch similarity index 100% rename from patches/unapplied/server/Add-Early-Warning-Feature-to-WatchDog.patch rename to patches/server/Add-Early-Warning-Feature-to-WatchDog.patch diff --git a/patches/unapplied/server/Add-Heightmap-API.patch b/patches/server/Add-Heightmap-API.patch similarity index 100% rename from patches/unapplied/server/Add-Heightmap-API.patch rename to patches/server/Add-Heightmap-API.patch diff --git a/patches/unapplied/server/Add-LivingEntity-getTargetEntity.patch b/patches/server/Add-LivingEntity-getTargetEntity.patch similarity index 100% rename from patches/unapplied/server/Add-LivingEntity-getTargetEntity.patch rename to patches/server/Add-LivingEntity-getTargetEntity.patch diff --git a/patches/unapplied/server/Add-More-Creeper-API.patch b/patches/server/Add-More-Creeper-API.patch similarity index 100% rename from patches/unapplied/server/Add-More-Creeper-API.patch rename to patches/server/Add-More-Creeper-API.patch diff --git a/patches/unapplied/server/Add-PhantomPreSpawnEvent.patch b/patches/server/Add-PhantomPreSpawnEvent.patch similarity index 86% rename from patches/unapplied/server/Add-PhantomPreSpawnEvent.patch rename to patches/server/Add-PhantomPreSpawnEvent.patch index 8e2def97c9..ca7ba15767 100644 --- a/patches/unapplied/server/Add-PhantomPreSpawnEvent.patch +++ b/patches/server/Add-PhantomPreSpawnEvent.patch @@ -73,11 +73,12 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + } + // Paper end Phantom entityphantom = (Phantom) EntityType.PHANTOM.create(world); -- -+ entityphantom.setSpawningEntity(entityhuman.getUUID()); // Paper - entityphantom.moveTo(blockposition1, 0.0F, 0.0F); - groupdataentity = entityphantom.finalizeSpawn(world, difficultydamagescaler, MobSpawnType.NATURAL, groupdataentity, (CompoundTag) null); - world.addFreshEntityWithPassengers(entityphantom, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.NATURAL); // CraftBukkit + + if (entityphantom != null) { ++ entityphantom.setSpawningEntity(entityhuman.getUUID()); // Paper + entityphantom.moveTo(blockposition1, 0.0F, 0.0F); + groupdataentity = entityphantom.finalizeSpawn(world, difficultydamagescaler, MobSpawnType.NATURAL, groupdataentity, (CompoundTag) null); + world.addFreshEntityWithPassengers(entityphantom, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.NATURAL); // CraftBukkit diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPhantom.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPhantom.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPhantom.java diff --git a/patches/unapplied/server/Add-PlayerConnectionCloseEvent.patch b/patches/server/Add-PlayerConnectionCloseEvent.patch similarity index 100% rename from patches/unapplied/server/Add-PlayerConnectionCloseEvent.patch rename to patches/server/Add-PlayerConnectionCloseEvent.patch 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-TNTPrimeEvent.patch b/patches/server/Add-TNTPrimeEvent.patch similarity index 99% rename from patches/unapplied/server/Add-TNTPrimeEvent.patch rename to patches/server/Add-TNTPrimeEvent.patch index cee2094e47..3d64dcc597 100644 --- a/patches/unapplied/server/Add-TNTPrimeEvent.patch +++ b/patches/server/Add-TNTPrimeEvent.patch @@ -83,7 +83,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + if(!new com.destroystokyo.paper.event.block.TNTPrimeEvent(tntBlock, com.destroystokyo.paper.event.block.TNTPrimeEvent.PrimeReason.EXPLOSION, source).callEvent()) + return; + // Paper end - PrimedTnt entitytntprimed = new PrimedTnt(world, (double) pos.getX() + 0.5D, (double) pos.getY(), (double) pos.getZ() + 0.5D, explosion.getSourceMob()); + PrimedTnt entitytntprimed = new PrimedTnt(world, (double) pos.getX() + 0.5D, (double) pos.getY(), (double) pos.getZ() + 0.5D, explosion.getIndirectSourceEntity()); int i = entitytntprimed.getFuse(); @@ -0,0 +0,0 @@ public class TntBlock extends Block { 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-effect-to-block-break-naturally.patch b/patches/server/Add-effect-to-block-break-naturally.patch similarity index 100% rename from patches/unapplied/server/Add-effect-to-block-break-naturally.patch rename to patches/server/Add-effect-to-block-break-naturally.patch diff --git a/patches/unapplied/server/Add-more-Witch-API.patch b/patches/server/Add-more-Witch-API.patch similarity index 100% rename from patches/unapplied/server/Add-more-Witch-API.patch rename to patches/server/Add-more-Witch-API.patch diff --git a/patches/unapplied/server/Add-more-Zombie-API.patch b/patches/server/Add-more-Zombie-API.patch similarity index 100% rename from patches/unapplied/server/Add-more-Zombie-API.patch rename to patches/server/Add-more-Zombie-API.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-disable-pillager-patrols.patch b/patches/server/Add-option-to-disable-pillager-patrols.patch similarity index 100% rename from patches/unapplied/server/Add-option-to-disable-pillager-patrols.patch rename to patches/server/Add-option-to-disable-pillager-patrols.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-option-to-prevent-players-from-moving-into-unloa.patch b/patches/server/Add-option-to-prevent-players-from-moving-into-unloa.patch similarity index 100% rename from patches/unapplied/server/Add-option-to-prevent-players-from-moving-into-unloa.patch rename to patches/server/Add-option-to-prevent-players-from-moving-into-unloa.patch diff --git a/patches/unapplied/server/Add-ray-tracing-methods-to-LivingEntity.patch b/patches/server/Add-ray-tracing-methods-to-LivingEntity.patch similarity index 100% rename from patches/unapplied/server/Add-ray-tracing-methods-to-LivingEntity.patch rename to patches/server/Add-ray-tracing-methods-to-LivingEntity.patch diff --git a/patches/unapplied/server/Add-sun-related-API.patch b/patches/server/Add-sun-related-API.patch similarity index 100% rename from patches/unapplied/server/Add-sun-related-API.patch rename to patches/server/Add-sun-related-API.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 100% 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 diff --git a/patches/unapplied/server/Allow-Saving-of-Oversized-Chunks.patch b/patches/server/Allow-Saving-of-Oversized-Chunks.patch similarity index 99% rename from patches/unapplied/server/Allow-Saving-of-Oversized-Chunks.patch rename to patches/server/Allow-Saving-of-Oversized-Chunks.patch index 941e326048..96aac53a4c 100644 --- a/patches/unapplied/server/Allow-Saving-of-Oversized-Chunks.patch +++ b/patches/server/Allow-Saving-of-Oversized-Chunks.patch @@ -145,9 +145,9 @@ diff --git a/src/main/java/net/minecraft/world/level/chunk/storage/RegionFileSto index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/net/minecraft/world/level/chunk/storage/RegionFileStorage.java +++ b/src/main/java/net/minecraft/world/level/chunk/storage/RegionFileStorage.java -@@ -0,0 +0,0 @@ import java.nio.file.Files; - import java.nio.file.Path; +@@ -0,0 +0,0 @@ import java.nio.file.Path; import javax.annotation.Nullable; + import net.minecraft.FileUtil; import net.minecraft.nbt.CompoundTag; +import net.minecraft.nbt.ListTag; import net.minecraft.nbt.NbtIo; diff --git a/patches/unapplied/server/Allow-chests-to-be-placed-with-NBT-data.patch b/patches/server/Allow-chests-to-be-placed-with-NBT-data.patch similarity index 100% rename from patches/unapplied/server/Allow-chests-to-be-placed-with-NBT-data.patch rename to patches/server/Allow-chests-to-be-placed-with-NBT-data.patch diff --git a/patches/unapplied/server/Anti-Xray.patch b/patches/server/Anti-Xray.patch similarity index 98% rename from patches/unapplied/server/Anti-Xray.patch rename to patches/server/Anti-Xray.patch index 035a79f979..3fac754875 100644 --- a/patches/unapplied/server/Anti-Xray.patch +++ b/patches/server/Anti-Xray.patch @@ -1084,10 +1084,10 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java @@ -0,0 +0,0 @@ public class ServerLevel extends Level implements WorldGenLevel { public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, PrimaryLevelData iworlddataserver, ResourceKey resourcekey, LevelStem worlddimension, ChunkProgressListener worldloadlistener, boolean flag, long i, List list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider) { - // Holder holder = worlddimension.typeHolder(); // CraftBukkit - decompile error + // Holder holder = worlddimension.type(); // CraftBukkit - decompile error // Objects.requireNonNull(minecraftserver); // CraftBukkit - decompile error -- super(iworlddataserver, resourcekey, worlddimension.typeHolder(), minecraftserver::getProfiler, false, flag, i, minecraftserver.getMaxChainedNeighborUpdates(), gen, biomeProvider, env, spigotConfig -> minecraftserver.paperConfigurations.createWorldConfig(io.papermc.paper.configuration.PaperConfigurations.createWorldContextMap(convertable_conversionsession.levelDirectory.path(), iworlddataserver.getLevelName(), resourcekey.location(), spigotConfig))); // Paper -+ super(iworlddataserver, resourcekey, worlddimension.typeHolder(), minecraftserver::getProfiler, false, flag, i, minecraftserver.getMaxChainedNeighborUpdates(), gen, biomeProvider, env, spigotConfig -> minecraftserver.paperConfigurations.createWorldConfig(io.papermc.paper.configuration.PaperConfigurations.createWorldContextMap(convertable_conversionsession.levelDirectory.path(), iworlddataserver.getLevelName(), resourcekey.location(), spigotConfig)), executor); // Paper - Async-Anti-Xray - Pass executor +- super(iworlddataserver, resourcekey, worlddimension.type(), minecraftserver::getProfiler, false, flag, i, minecraftserver.getMaxChainedNeighborUpdates(), gen, biomeProvider, env, spigotConfig -> minecraftserver.paperConfigurations.createWorldConfig(io.papermc.paper.configuration.PaperConfigurations.createWorldContextMap(convertable_conversionsession.levelDirectory.path(), iworlddataserver.getLevelName(), resourcekey.location(), spigotConfig))); // Paper ++ super(iworlddataserver, resourcekey, worlddimension.type(), minecraftserver::getProfiler, false, flag, i, minecraftserver.getMaxChainedNeighborUpdates(), gen, biomeProvider, env, spigotConfig -> minecraftserver.paperConfigurations.createWorldConfig(io.papermc.paper.configuration.PaperConfigurations.createWorldContextMap(convertable_conversionsession.levelDirectory.path(), iworlddataserver.getLevelName(), resourcekey.location(), spigotConfig)), executor); // Paper - Async-Anti-Xray - Pass executor this.pvpMode = minecraftserver.isPvpAllowed(); this.convertable = convertable_conversionsession; this.uuid = WorldUUID.getUUID(convertable_conversionsession.levelDirectory.path().toFile()); @@ -1185,8 +1185,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 } public LevelChunk(Level world, ChunkPos pos, UpgradeData upgradeData, LevelChunkTicks blockTickScheduler, LevelChunkTicks fluidTickScheduler, long inhabitedTime, @Nullable LevelChunkSection[] sectionArrayInitializer, @Nullable LevelChunk.PostLoadProcessor entityLoader, @Nullable BlendingData blendingData) { -- super(pos, upgradeData, world, world.registryAccess().registryOrThrow(Registry.BIOME_REGISTRY), inhabitedTime, sectionArrayInitializer, blendingData); -+ super(pos, upgradeData, world, net.minecraft.server.MinecraftServer.getServer().registryAccess().registryOrThrow(Registry.BIOME_REGISTRY), inhabitedTime, sectionArrayInitializer, blendingData); // Paper - Anti-Xray - The world isn't ready yet, use server singleton for registry +- super(pos, upgradeData, world, world.registryAccess().registryOrThrow(Registries.BIOME)), inhabitedTime, sectionArrayInitializer, blendingData); ++ super(pos, upgradeData, world, net.minecraft.server.MinecraftServer.getServer().registryAccess().registryOrThrow(Registries.BIOME), inhabitedTime, sectionArrayInitializer, blendingData); // Paper - Anti-Xray - The world isn't ready yet, use server singleton for registry // Paper start - rewrite light engine this.setBlockNibbles(ca.spottedleaf.starlight.common.light.StarLightEngine.getFilledEmptyLight(world)); this.setSkyNibbles(ca.spottedleaf.starlight.common.light.StarLightEngine.getFilledEmptyLight(world)); @@ -1531,8 +1531,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 public ChunkGenerator.ChunkData createChunkData(World world) { Validate.notNull(world, "World cannot be null"); ServerLevel handle = ((CraftWorld) world).getHandle(); -- return new OldCraftChunkData(world.getMinHeight(), world.getMaxHeight(), handle.registryAccess().registryOrThrow(net.minecraft.core.Registry.BIOME_REGISTRY)); -+ return new OldCraftChunkData(world.getMinHeight(), world.getMaxHeight(), handle.registryAccess().registryOrThrow(net.minecraft.core.Registry.BIOME_REGISTRY), world); // Paper - Anti-Xray - Add parameters +- return new OldCraftChunkData(world.getMinHeight(), world.getMaxHeight(), handle.registryAccess().registryOrThrow(Registries.BIOME)); ++ return new OldCraftChunkData(world.getMinHeight(), world.getMaxHeight(), handle.registryAccess().registryOrThrow(Registries.BIOME), world); // Paper - Anti-Xray - Add parameters } @Override diff --git a/patches/unapplied/server/AnvilDamageEvent.patch b/patches/server/AnvilDamageEvent.patch similarity index 100% rename from patches/unapplied/server/AnvilDamageEvent.patch rename to patches/server/AnvilDamageEvent.patch diff --git a/patches/unapplied/server/Async-command-map-building.patch b/patches/server/Async-command-map-building.patch similarity index 100% rename from patches/unapplied/server/Async-command-map-building.patch rename to patches/server/Async-command-map-building.patch diff --git a/patches/unapplied/server/Bees-get-gravity-in-void.-Fixes-MC-167279.patch b/patches/server/Bees-get-gravity-in-void.-Fixes-MC-167279.patch similarity index 100% rename from patches/unapplied/server/Bees-get-gravity-in-void.-Fixes-MC-167279.patch rename to patches/server/Bees-get-gravity-in-void.-Fixes-MC-167279.patch diff --git a/patches/unapplied/server/Block-Entity-remove-from-being-called-on-Players.patch b/patches/server/Block-Entity-remove-from-being-called-on-Players.patch similarity index 100% rename from patches/unapplied/server/Block-Entity-remove-from-being-called-on-Players.patch rename to patches/server/Block-Entity-remove-from-being-called-on-Players.patch diff --git a/patches/unapplied/server/BlockDestroyEvent.patch b/patches/server/BlockDestroyEvent.patch similarity index 100% rename from patches/unapplied/server/BlockDestroyEvent.patch rename to patches/server/BlockDestroyEvent.patch diff --git a/patches/unapplied/server/Book-Size-Limits.patch b/patches/server/Book-Size-Limits.patch similarity index 100% rename from patches/unapplied/server/Book-Size-Limits.patch rename to patches/server/Book-Size-Limits.patch diff --git a/patches/unapplied/server/Break-up-and-make-tab-spam-limits-configurable.patch b/patches/server/Break-up-and-make-tab-spam-limits-configurable.patch similarity index 100% rename from patches/unapplied/server/Break-up-and-make-tab-spam-limits-configurable.patch rename to patches/server/Break-up-and-make-tab-spam-limits-configurable.patch diff --git a/patches/unapplied/server/Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch b/patches/server/Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch similarity index 100% rename from patches/unapplied/server/Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch rename to patches/server/Call-WhitelistToggleEvent-when-whitelist-is-toggled.patch diff --git a/patches/unapplied/server/Call-player-spectator-target-events-and-improve-impl.patch b/patches/server/Call-player-spectator-target-events-and-improve-impl.patch similarity index 98% rename from patches/unapplied/server/Call-player-spectator-target-events-and-improve-impl.patch rename to patches/server/Call-player-spectator-target-events-and-improve-impl.patch index e583802005..5407982eee 100644 --- a/patches/unapplied/server/Call-player-spectator-target-events-and-improve-impl.patch +++ b/patches/server/Call-player-spectator-target-events-and-improve-impl.patch @@ -33,10 +33,11 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 - if (entity1 != this.camera) { - this.connection.send(new ClientboundSetCameraPacket(this.camera)); - this.connection.teleport(this.camera.getX(), this.camera.getY(), this.camera.getZ(), this.getYRot(), this.getXRot(), TeleportCause.SPECTATE); // CraftBukkit +- this.connection.resetPosition(); + if (entity == null) { + entity = this; -+ } -+ + } + + if (entity1 == entity) return; // new spec target is the current spec target + + if (entity == this) { @@ -63,8 +64,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + MinecraftServer.LOGGER.debug("Blocking frozen player " + this + " from spectating entity " + entity); + return; + } - } - ++ } ++ + this.camera = entity; // only set after validating state + + if (entity != this) { @@ -81,6 +82,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + this.connection.teleport(this.camera.getX(), this.camera.getY(), this.camera.getZ(), this.getYRot(), this.getXRot(), TeleportCause.SPECTATE); // CraftBukkit + } + this.connection.send(new ClientboundSetCameraPacket(entity)); ++ this.connection.resetPosition(); + // Paper end } diff --git a/patches/unapplied/server/Catch-JsonParseException-in-Entity-and-TE-names.patch b/patches/server/Catch-JsonParseException-in-Entity-and-TE-names.patch similarity index 99% rename from patches/unapplied/server/Catch-JsonParseException-in-Entity-and-TE-names.patch rename to patches/server/Catch-JsonParseException-in-Entity-and-TE-names.patch index aa7f94642b..fe929e1f73 100644 --- a/patches/unapplied/server/Catch-JsonParseException-in-Entity-and-TE-names.patch +++ b/patches/server/Catch-JsonParseException-in-Entity-and-TE-names.patch @@ -90,7 +90,7 @@ diff --git a/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEnt index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java +++ b/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java -@@ -0,0 +0,0 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider { +@@ -0,0 +0,0 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider, Name this.levels = nbt.getInt("Levels"); // SPIGOT-5053, use where available // CraftBukkit end if (nbt.contains("CustomName", 8)) { diff --git a/patches/unapplied/server/Check-Drowned-for-Villager-Aggression-Config.patch b/patches/server/Check-Drowned-for-Villager-Aggression-Config.patch similarity index 100% rename from patches/unapplied/server/Check-Drowned-for-Villager-Aggression-Config.patch rename to patches/server/Check-Drowned-for-Villager-Aggression-Config.patch diff --git a/patches/unapplied/server/Configurable-Keep-Spawn-Loaded-range-per-world.patch b/patches/server/Configurable-Keep-Spawn-Loaded-range-per-world.patch similarity index 100% rename from patches/unapplied/server/Configurable-Keep-Spawn-Loaded-range-per-world.patch rename to patches/server/Configurable-Keep-Spawn-Loaded-range-per-world.patch diff --git a/patches/unapplied/server/Configurable-chance-of-villager-zombie-infection.patch b/patches/server/Configurable-chance-of-villager-zombie-infection.patch similarity index 87% rename from patches/unapplied/server/Configurable-chance-of-villager-zombie-infection.patch rename to patches/server/Configurable-chance-of-villager-zombie-infection.patch index 06b72ca790..a015798343 100644 --- a/patches/unapplied/server/Configurable-chance-of-villager-zombie-infection.patch +++ b/patches/server/Configurable-chance-of-villager-zombie-infection.patch @@ -16,6 +16,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 boolean flag = super.wasKilled(world, other); - if ((world.getDifficulty() == Difficulty.NORMAL || world.getDifficulty() == Difficulty.HARD) && other instanceof Villager) { +- Villager entityvillager = (Villager) other; +- - if (world.getDifficulty() != Difficulty.HARD && this.random.nextBoolean()) { + // Paper start + if (level.paperConfig().entities.behavior.zombieVillagerInfectionChance != 0.0 && (level.paperConfig().entities.behavior.zombieVillagerInfectionChance != -1.0 || world.getDifficulty() == Difficulty.NORMAL || world.getDifficulty() == Difficulty.HARD) && other instanceof Villager) { @@ -25,6 +27,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + if (level.paperConfig().entities.behavior.zombieVillagerInfectionChance != -1.0 && (this.random.nextDouble() * 100.0) > level.paperConfig().entities.behavior.zombieVillagerInfectionChance) { + return flag; + } // Paper end - - Villager entityvillager = (Villager) other; ++ ++ Villager entityvillager = (Villager) other; // CraftBukkit start + flag = Zombie.zombifyVillager(world, entityvillager, this.blockPosition(), this.isSilent(), CreatureSpawnEvent.SpawnReason.INFECTION) == null; + } diff --git a/patches/unapplied/server/Configurable-connection-throttle-kick-message.patch b/patches/server/Configurable-connection-throttle-kick-message.patch similarity index 100% rename from patches/unapplied/server/Configurable-connection-throttle-kick-message.patch rename to patches/server/Configurable-connection-throttle-kick-message.patch diff --git a/patches/unapplied/server/Configurable-projectile-relative-velocity.patch b/patches/server/Configurable-projectile-relative-velocity.patch similarity index 100% rename from patches/unapplied/server/Configurable-projectile-relative-velocity.patch rename to patches/server/Configurable-projectile-relative-velocity.patch diff --git a/patches/unapplied/server/Configurable-speed-for-water-flowing-over-lava.patch b/patches/server/Configurable-speed-for-water-flowing-over-lava.patch similarity index 100% rename from patches/unapplied/server/Configurable-speed-for-water-flowing-over-lava.patch rename to patches/server/Configurable-speed-for-water-flowing-over-lava.patch diff --git a/patches/unapplied/server/Dead-Player-s-shouldn-t-be-able-to-move.patch b/patches/server/Dead-Player-s-shouldn-t-be-able-to-move.patch similarity index 100% rename from patches/unapplied/server/Dead-Player-s-shouldn-t-be-able-to-move.patch rename to patches/server/Dead-Player-s-shouldn-t-be-able-to-move.patch diff --git a/patches/unapplied/server/Do-not-allow-bees-to-load-chunks-for-beehives.patch b/patches/server/Do-not-allow-bees-to-load-chunks-for-beehives.patch similarity index 100% rename from patches/unapplied/server/Do-not-allow-bees-to-load-chunks-for-beehives.patch rename to patches/server/Do-not-allow-bees-to-load-chunks-for-beehives.patch diff --git a/patches/unapplied/server/Don-t-allow-digging-into-unloaded-chunks.patch b/patches/server/Don-t-allow-digging-into-unloaded-chunks.patch similarity index 100% rename from patches/unapplied/server/Don-t-allow-digging-into-unloaded-chunks.patch rename to patches/server/Don-t-allow-digging-into-unloaded-chunks.patch diff --git a/patches/unapplied/server/Don-t-check-ConvertSigns-boolean-every-sign-save.patch b/patches/server/Don-t-check-ConvertSigns-boolean-every-sign-save.patch similarity index 92% rename from patches/unapplied/server/Don-t-check-ConvertSigns-boolean-every-sign-save.patch rename to patches/server/Don-t-check-ConvertSigns-boolean-every-sign-save.patch index c7658cee0c..3ce8a464c4 100644 --- a/patches/unapplied/server/Don-t-check-ConvertSigns-boolean-every-sign-save.patch +++ b/patches/server/Don-t-check-ConvertSigns-boolean-every-sign-save.patch @@ -17,7 +17,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + private static final boolean CONVERT_LEGACY_SIGNS = Boolean.getBoolean("convertLegacySigns"); // Paper public static final int LINES = 4; - private static final String[] RAW_TEXT_FIELD_NAMES = new String[]{"Text1", "Text2", "Text3", "Text4"}; + private static final int MAX_TEXT_LINE_WIDTH = 90; @@ -0,0 +0,0 @@ public class SignBlockEntity extends BlockEntity implements CommandSource { // C } diff --git a/patches/unapplied/server/Don-t-load-Chunks-from-Hoppers-and-other-things.patch b/patches/server/Don-t-load-Chunks-from-Hoppers-and-other-things.patch similarity index 100% rename from patches/unapplied/server/Don-t-load-Chunks-from-Hoppers-and-other-things.patch rename to patches/server/Don-t-load-Chunks-from-Hoppers-and-other-things.patch diff --git a/patches/unapplied/server/Don-t-move-existing-players-to-world-spawn.patch b/patches/server/Don-t-move-existing-players-to-world-spawn.patch similarity index 100% rename from patches/unapplied/server/Don-t-move-existing-players-to-world-spawn.patch rename to patches/server/Don-t-move-existing-players-to-world-spawn.patch diff --git a/patches/unapplied/server/Don-t-sleep-after-profile-lookups-if-not-needed.patch b/patches/server/Don-t-sleep-after-profile-lookups-if-not-needed.patch similarity index 100% rename from patches/unapplied/server/Don-t-sleep-after-profile-lookups-if-not-needed.patch rename to patches/server/Don-t-sleep-after-profile-lookups-if-not-needed.patch diff --git a/patches/unapplied/server/Don-t-tick-dead-players.patch b/patches/server/Don-t-tick-dead-players.patch similarity index 100% rename from patches/unapplied/server/Don-t-tick-dead-players.patch rename to patches/server/Don-t-tick-dead-players.patch diff --git a/patches/unapplied/server/Dont-send-unnecessary-sign-update.patch b/patches/server/Dont-send-unnecessary-sign-update.patch similarity index 100% rename from patches/unapplied/server/Dont-send-unnecessary-sign-update.patch rename to patches/server/Dont-send-unnecessary-sign-update.patch diff --git a/patches/unapplied/server/Duplicate-UUID-Resolve-Option.patch b/patches/server/Duplicate-UUID-Resolve-Option.patch similarity index 100% rename from patches/unapplied/server/Duplicate-UUID-Resolve-Option.patch rename to patches/server/Duplicate-UUID-Resolve-Option.patch diff --git a/patches/unapplied/server/Entity-Activation-Range-2.0.patch b/patches/server/Entity-Activation-Range-2.0.patch similarity index 99% rename from patches/unapplied/server/Entity-Activation-Range-2.0.patch rename to patches/server/Entity-Activation-Range-2.0.patch index 0666cf1f17..e1fea538dc 100644 --- a/patches/unapplied/server/Entity-Activation-Range-2.0.patch +++ b/patches/server/Entity-Activation-Range-2.0.patch @@ -52,7 +52,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 // Paper end - timings entity.setOldPosAndRot(); @@ -0,0 +0,0 @@ public class ServerLevel extends Level implements WorldGenLevel { - return Registry.ENTITY_TYPE.getKey(entity.getType()).toString(); + return BuiltInRegistries.ENTITY_TYPE.getKey(entity.getType()).toString(); }); gameprofilerfiller.incrementCounter("tickNonPassenger"); + if (isActive) { // Paper - EAR 2 @@ -86,7 +86,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 ++passenger.tickCount; ProfilerFiller gameprofilerfiller = this.getProfiler(); @@ -0,0 +0,0 @@ public class ServerLevel extends Level implements WorldGenLevel { - return Registry.ENTITY_TYPE.getKey(passenger.getType()).toString(); + return BuiltInRegistries.ENTITY_TYPE.getKey(passenger.getType()).toString(); }); gameprofilerfiller.incrementCounter("tickPassenger"); + // Paper start - EAR 2 @@ -196,7 +196,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 public GoalSelector(Supplier profiler) { this.profiler = profiler; @@ -0,0 +0,0 @@ public class GoalSelector { - this.availableGoals.clear(); + }); } + // Paper start 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/Entity-getEntitySpawnReason.patch b/patches/server/Entity-getEntitySpawnReason.patch similarity index 100% rename from patches/unapplied/server/Entity-getEntitySpawnReason.patch rename to patches/server/Entity-getEntitySpawnReason.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/Expose-attack-cooldown-methods-for-Player.patch b/patches/server/Expose-attack-cooldown-methods-for-Player.patch similarity index 100% rename from patches/unapplied/server/Expose-attack-cooldown-methods-for-Player.patch rename to patches/server/Expose-attack-cooldown-methods-for-Player.patch diff --git a/patches/unapplied/server/Expose-the-internal-current-tick.patch b/patches/server/Expose-the-internal-current-tick.patch similarity index 100% rename from patches/unapplied/server/Expose-the-internal-current-tick.patch rename to patches/server/Expose-the-internal-current-tick.patch diff --git a/patches/unapplied/server/Fire-event-on-GS4-query.patch b/patches/server/Fire-event-on-GS4-query.patch similarity index 100% rename from patches/unapplied/server/Fire-event-on-GS4-query.patch rename to patches/server/Fire-event-on-GS4-query.patch diff --git a/patches/unapplied/server/Fix-CB-call-to-changed-postToMainThread-method.patch b/patches/server/Fix-CB-call-to-changed-postToMainThread-method.patch similarity index 100% rename from patches/unapplied/server/Fix-CB-call-to-changed-postToMainThread-method.patch rename to patches/server/Fix-CB-call-to-changed-postToMainThread-method.patch diff --git a/patches/unapplied/server/Fix-Custom-Shapeless-Custom-Crafting-Recipes.patch b/patches/server/Fix-Custom-Shapeless-Custom-Crafting-Recipes.patch similarity index 100% rename from patches/unapplied/server/Fix-Custom-Shapeless-Custom-Crafting-Recipes.patch rename to patches/server/Fix-Custom-Shapeless-Custom-Crafting-Recipes.patch diff --git a/patches/unapplied/server/Fix-MC-158900.patch b/patches/server/Fix-MC-158900.patch similarity index 100% rename from patches/unapplied/server/Fix-MC-158900.patch rename to patches/server/Fix-MC-158900.patch diff --git a/patches/unapplied/server/Fix-NBT-type-issues.patch b/patches/server/Fix-NBT-type-issues.patch similarity index 100% rename from patches/unapplied/server/Fix-NBT-type-issues.patch rename to patches/server/Fix-NBT-type-issues.patch diff --git a/patches/unapplied/server/Fix-SpongeAbsortEvent-handling.patch b/patches/server/Fix-SpongeAbsortEvent-handling.patch similarity index 100% rename from patches/unapplied/server/Fix-SpongeAbsortEvent-handling.patch rename to patches/server/Fix-SpongeAbsortEvent-handling.patch diff --git a/patches/unapplied/server/Fix-World-isChunkGenerated-calls.patch b/patches/server/Fix-World-isChunkGenerated-calls.patch similarity index 100% rename from patches/unapplied/server/Fix-World-isChunkGenerated-calls.patch rename to patches/server/Fix-World-isChunkGenerated-calls.patch diff --git a/patches/unapplied/server/Fix-items-not-falling-correctly.patch b/patches/server/Fix-items-not-falling-correctly.patch similarity index 100% rename from patches/unapplied/server/Fix-items-not-falling-correctly.patch rename to patches/server/Fix-items-not-falling-correctly.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/Fix-last-firework-in-stack-not-having-effects-when-d.patch b/patches/server/Fix-last-firework-in-stack-not-having-effects-when-d.patch similarity index 100% rename from patches/unapplied/server/Fix-last-firework-in-stack-not-having-effects-when-d.patch rename to patches/server/Fix-last-firework-in-stack-not-having-effects-when-d.patch diff --git a/patches/unapplied/server/Fix-sounds-when-item-frames-are-modified-MC-123450.patch b/patches/server/Fix-sounds-when-item-frames-are-modified-MC-123450.patch similarity index 100% rename from patches/unapplied/server/Fix-sounds-when-item-frames-are-modified-MC-123450.patch rename to patches/server/Fix-sounds-when-item-frames-are-modified-MC-123450.patch diff --git a/patches/unapplied/server/Flat-bedrock-generator-settings.patch b/patches/server/Flat-bedrock-generator-settings.patch similarity index 97% rename from patches/unapplied/server/Flat-bedrock-generator-settings.patch rename to patches/server/Flat-bedrock-generator-settings.patch index bf7f19826c..cc7d9eb6fb 100644 --- a/patches/unapplied/server/Flat-bedrock-generator-settings.patch +++ b/patches/server/Flat-bedrock-generator-settings.patch @@ -118,13 +118,13 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 --- a/src/main/java/net/minecraft/server/Bootstrap.java +++ b/src/main/java/net/minecraft/server/Bootstrap.java @@ -0,0 +0,0 @@ public class Bootstrap { - EntitySelectorOptions.bootStrap(); DispenseItemBehavior.bootStrap(); CauldronInteraction.bootStrap(); -+ Registry.register(net.minecraft.core.Registry.CONDITION, new net.minecraft.resources.ResourceLocation("paper", "bedrock_condition_source"), net.minecraft.data.worldgen.SurfaceRuleData.PaperBedrockConditionSource.CODEC.codec()); // Paper - register custom flat bedrock thing. TODO is this the best place to do this? - Registry.freezeBuiltins(); + BuiltInRegistries.bootStrap(); ++ net.minecraft.core.Registry.register(net.minecraft.core.registries.BuiltInRegistries.MATERIAL_CONDITION, new net.minecraft.resources.ResourceLocation("paper", "bedrock_condition_source"), net.minecraft.data.worldgen.SurfaceRuleData.PaperBedrockConditionSource.CODEC.codec()); // Paper - register custom flat bedrock thing. TODO is this the best place to do this? Bootstrap.wrapStreams(); } + // CraftBukkit start - easier than fixing the decompile diff --git a/src/main/java/net/minecraft/world/level/levelgen/NoiseBasedChunkGenerator.java b/src/main/java/net/minecraft/world/level/levelgen/NoiseBasedChunkGenerator.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/net/minecraft/world/level/levelgen/NoiseBasedChunkGenerator.java @@ -136,7 +136,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 - WorldGenerationContext worldgenerationcontext = new WorldGenerationContext(this, region); + WorldGenerationContext worldgenerationcontext = new WorldGenerationContext(this, region, region.getMinecraftWorld()); // Paper - this.buildSurface(chunk, worldgenerationcontext, noiseConfig, structures, region.getBiomeManager(), region.registryAccess().registryOrThrow(Registry.BIOME_REGISTRY), Blender.of(region)); + this.buildSurface(chunk, worldgenerationcontext, noiseConfig, structures, region.getBiomeManager(), region.registryAccess().registryOrThrow(Registries.BIOME), Blender.of(region)); } @@ -0,0 +0,0 @@ public final class NoiseBasedChunkGenerator extends ChunkGenerator { return this.createNoiseChunk(ichunkaccess1, structureAccessor, Blender.of(chunkRegion), noiseConfig); diff --git a/patches/unapplied/server/Guard-against-serializing-mismatching-chunk-coordina.patch b/patches/server/Guard-against-serializing-mismatching-chunk-coordina.patch similarity index 100% rename from patches/unapplied/server/Guard-against-serializing-mismatching-chunk-coordina.patch rename to patches/server/Guard-against-serializing-mismatching-chunk-coordina.patch diff --git a/patches/unapplied/server/Handle-Large-Packets-disconnecting-client.patch b/patches/server/Handle-Large-Packets-disconnecting-client.patch similarity index 100% rename from patches/unapplied/server/Handle-Large-Packets-disconnecting-client.patch rename to patches/server/Handle-Large-Packets-disconnecting-client.patch diff --git a/patches/unapplied/server/Handle-Oversized-Tile-Entities-in-chunks.patch b/patches/server/Handle-Oversized-Tile-Entities-in-chunks.patch similarity index 100% rename from patches/unapplied/server/Handle-Oversized-Tile-Entities-in-chunks.patch rename to patches/server/Handle-Oversized-Tile-Entities-in-chunks.patch diff --git a/patches/unapplied/server/Honor-EntityAgeable.ageLock.patch b/patches/server/Honor-EntityAgeable.ageLock.patch similarity index 100% rename from patches/unapplied/server/Honor-EntityAgeable.ageLock.patch rename to patches/server/Honor-EntityAgeable.ageLock.patch diff --git a/patches/unapplied/server/Hook-into-CB-plugin-rewrites.patch b/patches/server/Hook-into-CB-plugin-rewrites.patch similarity index 100% rename from patches/unapplied/server/Hook-into-CB-plugin-rewrites.patch rename to patches/server/Hook-into-CB-plugin-rewrites.patch diff --git a/patches/unapplied/server/Implement-Brigadier-Mojang-API.patch b/patches/server/Implement-Brigadier-Mojang-API.patch similarity index 99% rename from patches/unapplied/server/Implement-Brigadier-Mojang-API.patch rename to patches/server/Implement-Brigadier-Mojang-API.patch index 922c617314..c5a0f48711 100644 --- a/patches/unapplied/server/Implement-Brigadier-Mojang-API.patch +++ b/patches/server/Implement-Brigadier-Mojang-API.patch @@ -72,7 +72,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 public static final SimpleCommandExceptionType ERROR_NOT_PLAYER = new SimpleCommandExceptionType(Component.translatable("permissions.requires.player")); public static final SimpleCommandExceptionType ERROR_NOT_ENTITY = new SimpleCommandExceptionType(Component.translatable("permissions.requires.entity")); @@ -0,0 +0,0 @@ public class CommandSourceStack implements SharedSuggestionProvider { - return this.entity != null ? this.entity.asChatSender() : ChatSender.SYSTEM; + return this.textName; } + // Paper start diff --git a/patches/unapplied/server/Implement-CraftBlockSoundGroup.patch b/patches/server/Implement-CraftBlockSoundGroup.patch similarity index 100% rename from patches/unapplied/server/Implement-CraftBlockSoundGroup.patch rename to patches/server/Implement-CraftBlockSoundGroup.patch diff --git a/patches/unapplied/server/Implement-PlayerPostRespawnEvent.patch b/patches/server/Implement-PlayerPostRespawnEvent.patch similarity index 100% rename from patches/unapplied/server/Implement-PlayerPostRespawnEvent.patch rename to patches/server/Implement-PlayerPostRespawnEvent.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/Implement-an-API-for-CanPlaceOn-and-CanDestroy-NBT-v.patch b/patches/server/Implement-an-API-for-CanPlaceOn-and-CanDestroy-NBT-v.patch similarity index 100% rename from patches/unapplied/server/Implement-an-API-for-CanPlaceOn-and-CanDestroy-NBT-v.patch rename to patches/server/Implement-an-API-for-CanPlaceOn-and-CanDestroy-NBT-v.patch diff --git a/patches/unapplied/server/Implement-furnace-cook-speed-multiplier-API.patch b/patches/server/Implement-furnace-cook-speed-multiplier-API.patch similarity index 100% rename from patches/unapplied/server/Implement-furnace-cook-speed-multiplier-API.patch rename to patches/server/Implement-furnace-cook-speed-multiplier-API.patch diff --git a/patches/unapplied/server/Improve-Server-Thread-Pool-and-Thread-Priorities.patch b/patches/server/Improve-Server-Thread-Pool-and-Thread-Priorities.patch similarity index 100% rename from patches/unapplied/server/Improve-Server-Thread-Pool-and-Thread-Priorities.patch rename to patches/server/Improve-Server-Thread-Pool-and-Thread-Priorities.patch diff --git a/patches/unapplied/server/Improve-death-events.patch b/patches/server/Improve-death-events.patch similarity index 99% rename from patches/unapplied/server/Improve-death-events.patch rename to patches/server/Improve-death-events.patch index 536fab1f57..52b32cacff 100644 --- a/patches/unapplied/server/Improve-death-events.patch +++ b/patches/server/Improve-death-events.patch @@ -245,7 +245,7 @@ diff --git a/src/main/java/net/minecraft/world/entity/animal/Fox.java b/src/main index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/net/minecraft/world/entity/animal/Fox.java +++ b/src/main/java/net/minecraft/world/entity/animal/Fox.java -@@ -0,0 +0,0 @@ public class Fox extends Animal { +@@ -0,0 +0,0 @@ public class Fox extends Animal implements VariantHolder { } @Override diff --git a/patches/unapplied/server/Improved-Watchdog-Support.patch b/patches/server/Improved-Watchdog-Support.patch similarity index 99% rename from patches/unapplied/server/Improved-Watchdog-Support.patch rename to patches/server/Improved-Watchdog-Support.patch index 792fa9eb92..0c7af85372 100644 --- a/patches/unapplied/server/Improved-Watchdog-Support.patch +++ b/patches/server/Improved-Watchdog-Support.patch @@ -220,8 +220,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 } // Spigot End @@ -0,0 +0,0 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop WorldDataServer public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, PrimaryLevelData iworlddataserver, ResourceKey resourcekey, LevelStem worlddimension, ChunkProgressListener worldloadlistener, boolean flag, long i, List list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider) { - // Holder holder = worlddimension.typeHolder(); // CraftBukkit - decompile error + // Holder holder = worlddimension.type(); // CraftBukkit - decompile error 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/Optimize-BlockPosition-helper-methods.patch b/patches/server/Optimize-BlockPosition-helper-methods.patch similarity index 100% rename from patches/unapplied/server/Optimize-BlockPosition-helper-methods.patch rename to patches/server/Optimize-BlockPosition-helper-methods.patch diff --git a/patches/unapplied/server/Optimize-Captured-TileEntity-Lookup.patch b/patches/server/Optimize-Captured-TileEntity-Lookup.patch similarity index 100% rename from patches/unapplied/server/Optimize-Captured-TileEntity-Lookup.patch rename to patches/server/Optimize-Captured-TileEntity-Lookup.patch diff --git a/patches/unapplied/server/Optimize-Collision-to-not-load-chunks.patch b/patches/server/Optimize-Collision-to-not-load-chunks.patch similarity index 100% rename from patches/unapplied/server/Optimize-Collision-to-not-load-chunks.patch rename to patches/server/Optimize-Collision-to-not-load-chunks.patch diff --git a/patches/unapplied/server/Optimize-CraftBlockData-Creation.patch b/patches/server/Optimize-CraftBlockData-Creation.patch similarity index 94% rename from patches/unapplied/server/Optimize-CraftBlockData-Creation.patch rename to patches/server/Optimize-CraftBlockData-Creation.patch index 5345178ad4..979d5dcc49 100644 --- a/patches/unapplied/server/Optimize-CraftBlockData-Creation.patch +++ b/patches/server/Optimize-CraftBlockData-Creation.patch @@ -10,8 +10,8 @@ diff --git a/src/main/java/net/minecraft/world/level/block/state/BlockBehaviour. index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/net/minecraft/world/level/block/state/BlockBehaviour.java +++ b/src/main/java/net/minecraft/world/level/block/state/BlockBehaviour.java -@@ -0,0 +0,0 @@ public abstract class BlockBehaviour { - this.offsetType = (BlockBehaviour.OffsetType) blockbase_info.offsetType.apply(this.asState()); +@@ -0,0 +0,0 @@ public abstract class BlockBehaviour implements FeatureElement { + this.spawnParticlesOnBreak = blockbase_info.spawnParticlesOnBreak; this.conditionallyFullOpaque = this.isOpaque() & this.isTransparentOnSomeFaces(); // Paper } + // Paper start - impl cached craft block data, lazy load to fix issue with loading at the wrong time diff --git a/patches/unapplied/server/Optimize-GoalSelector-Goal.Flag-Set-operations.patch b/patches/server/Optimize-GoalSelector-Goal.Flag-Set-operations.patch similarity index 100% rename from patches/unapplied/server/Optimize-GoalSelector-Goal.Flag-Set-operations.patch rename to patches/server/Optimize-GoalSelector-Goal.Flag-Set-operations.patch diff --git a/patches/unapplied/server/Optimize-Hoppers.patch b/patches/server/Optimize-Hoppers.patch similarity index 100% rename from patches/unapplied/server/Optimize-Hoppers.patch rename to patches/server/Optimize-Hoppers.patch diff --git a/patches/unapplied/server/Optimize-MappedRegistry.patch b/patches/server/Optimize-MappedRegistry.patch similarity index 78% rename from patches/unapplied/server/Optimize-MappedRegistry.patch rename to patches/server/Optimize-MappedRegistry.patch index 2dcfce270c..6fe023fb13 100644 --- a/patches/unapplied/server/Optimize-MappedRegistry.patch +++ b/patches/server/Optimize-MappedRegistry.patch @@ -11,30 +11,32 @@ diff --git a/src/main/java/net/minecraft/core/MappedRegistry.java b/src/main/jav index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/net/minecraft/core/MappedRegistry.java +++ b/src/main/java/net/minecraft/core/MappedRegistry.java -@@ -0,0 +0,0 @@ import org.slf4j.Logger; - public class MappedRegistry extends WritableRegistry { +@@ -0,0 +0,0 @@ public class MappedRegistry implements WritableRegistry { private static final Logger LOGGER = LogUtils.getLogger(); + final ResourceKey> key; private final ObjectList> byId = new ObjectArrayList<>(256); -- private final Object2IntMap toId = Util.make(new Object2IntOpenCustomHashMap<>(Util.identityStrategy()), (object2IntOpenCustomHashMap) -> { -- object2IntOpenCustomHashMap.defaultReturnValue(-1); +- private final Object2IntMap toId = Util.make(new Object2IntOpenCustomHashMap<>(Util.identityStrategy()), (map) -> { +- map.defaultReturnValue(-1); - }); - private final Map> byLocation = new HashMap<>(); - private final Map, Holder.Reference> byKey = new HashMap<>(); - private final Map> byValue = new IdentityHashMap<>(); - private final Map lifecycles = new IdentityHashMap<>(); +- private Lifecycle registryLifecycle; + private final it.unimi.dsi.fastutil.objects.Reference2IntOpenHashMap toId = new it.unimi.dsi.fastutil.objects.Reference2IntOpenHashMap(2048);// Paper - use bigger expected size to reduce collisions and direct intent for FastUtil to be identity map + private final Map> byLocation = new HashMap<>(2048); // Paper - use bigger expected size to reduce collisions + private final Map, Holder.Reference> byKey = new HashMap<>(2048); // Paper - use bigger expected size to reduce collisions + private final Map> byValue = new IdentityHashMap<>(2048); // Paper - use bigger expected size to reduce collisions + private final Map lifecycles = new IdentityHashMap<>(2048); // Paper - use bigger expected size to reduce collisions - private Lifecycle elementsLifecycle; ++ private Lifecycle elementsLifecycle; private volatile Map, HolderSet.Named> tags = new IdentityHashMap<>(); private boolean frozen; -@@ -0,0 +0,0 @@ public class MappedRegistry extends WritableRegistry { - this.intrusiveHolderCache = new IdentityHashMap<>(); - } - -+ this.toId.defaultReturnValue(-1); // Paper + @Nullable +@@ -0,0 +0,0 @@ public class MappedRegistry implements WritableRegistry { } - private List> holdersInOrder() { + public MappedRegistry(ResourceKey> key, Lifecycle lifecycle, boolean intrusive) { ++ this.toId.defaultReturnValue(-1); // Paper + Bootstrap.checkBootstrapCalled(() -> { + return "registry " + key; + }); diff --git a/patches/unapplied/server/Optimize-Network-Manager-and-add-advanced-packet-sup.patch b/patches/server/Optimize-Network-Manager-and-add-advanced-packet-sup.patch similarity index 100% rename from patches/unapplied/server/Optimize-Network-Manager-and-add-advanced-packet-sup.patch rename to patches/server/Optimize-Network-Manager-and-add-advanced-packet-sup.patch diff --git a/patches/unapplied/server/Optimize-Pathfinding.patch b/patches/server/Optimize-Pathfinding.patch similarity index 100% rename from patches/unapplied/server/Optimize-Pathfinding.patch rename to patches/server/Optimize-Pathfinding.patch diff --git a/patches/unapplied/server/Optimize-World-Time-Updates.patch b/patches/server/Optimize-World-Time-Updates.patch similarity index 100% rename from patches/unapplied/server/Optimize-World-Time-Updates.patch rename to patches/server/Optimize-World-Time-Updates.patch diff --git a/patches/unapplied/server/Optimize-call-to-getFluid-for-explosions.patch b/patches/server/Optimize-call-to-getFluid-for-explosions.patch similarity index 100% rename from patches/unapplied/server/Optimize-call-to-getFluid-for-explosions.patch rename to patches/server/Optimize-call-to-getFluid-for-explosions.patch diff --git a/patches/unapplied/server/Pillager-patrol-spawn-settings-and-per-player-option.patch b/patches/server/Pillager-patrol-spawn-settings-and-per-player-option.patch similarity index 100% rename from patches/unapplied/server/Pillager-patrol-spawn-settings-and-per-player-option.patch rename to patches/server/Pillager-patrol-spawn-settings-and-per-player-option.patch diff --git a/patches/unapplied/server/PlayerDeathEvent-getItemsToKeep.patch b/patches/server/PlayerDeathEvent-getItemsToKeep.patch similarity index 100% rename from patches/unapplied/server/PlayerDeathEvent-getItemsToKeep.patch rename to patches/server/PlayerDeathEvent-getItemsToKeep.patch diff --git a/patches/unapplied/server/PlayerDeathEvent-shouldDropExperience.patch b/patches/server/PlayerDeathEvent-shouldDropExperience.patch similarity index 100% rename from patches/unapplied/server/PlayerDeathEvent-shouldDropExperience.patch rename to patches/server/PlayerDeathEvent-shouldDropExperience.patch diff --git a/patches/unapplied/server/PreSpawnerSpawnEvent.patch b/patches/server/PreSpawnerSpawnEvent.patch similarity index 100% rename from patches/unapplied/server/PreSpawnerSpawnEvent.patch rename to patches/server/PreSpawnerSpawnEvent.patch diff --git a/patches/unapplied/server/Prevent-Double-PlayerChunkMap-adds-crashing-server.patch b/patches/server/Prevent-Double-PlayerChunkMap-adds-crashing-server.patch similarity index 100% rename from patches/unapplied/server/Prevent-Double-PlayerChunkMap-adds-crashing-server.patch rename to patches/server/Prevent-Double-PlayerChunkMap-adds-crashing-server.patch diff --git a/patches/unapplied/server/Prevent-Enderman-from-loading-chunks.patch b/patches/server/Prevent-Enderman-from-loading-chunks.patch similarity index 100% rename from patches/unapplied/server/Prevent-Enderman-from-loading-chunks.patch rename to patches/server/Prevent-Enderman-from-loading-chunks.patch diff --git a/patches/unapplied/server/Prevent-Mob-AI-Rules-from-Loading-Chunks.patch b/patches/server/Prevent-Mob-AI-Rules-from-Loading-Chunks.patch similarity index 100% rename from patches/unapplied/server/Prevent-Mob-AI-Rules-from-Loading-Chunks.patch rename to patches/server/Prevent-Mob-AI-Rules-from-Loading-Chunks.patch diff --git a/patches/unapplied/server/Prevent-bees-loading-chunks-checking-hive-position.patch b/patches/server/Prevent-bees-loading-chunks-checking-hive-position.patch similarity index 95% rename from patches/unapplied/server/Prevent-bees-loading-chunks-checking-hive-position.patch rename to patches/server/Prevent-bees-loading-chunks-checking-hive-position.patch index 8d8fb11607..efa1dc6c55 100644 --- a/patches/unapplied/server/Prevent-bees-loading-chunks-checking-hive-position.patch +++ b/patches/server/Prevent-bees-loading-chunks-checking-hive-position.patch @@ -9,7 +9,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 --- a/src/main/java/net/minecraft/world/entity/animal/Bee.java +++ b/src/main/java/net/minecraft/world/entity/animal/Bee.java @@ -0,0 +0,0 @@ public class Bee extends Animal implements NeutralMob, FlyingAnimal { - if (!this.hasHive()) { + } else if (this.isTooFarAway(this.hivePos)) { return false; } else { + if (level.getChunkIfLoadedImmediately(hivePos.getX() >> 4, hivePos.getZ() >> 4) == null) return true; // Paper - just assume the hive is still there, no need to load the chunk(s) diff --git a/patches/unapplied/server/Prevent-chunk-loading-from-Fluid-Flowing.patch b/patches/server/Prevent-chunk-loading-from-Fluid-Flowing.patch similarity index 100% rename from patches/unapplied/server/Prevent-chunk-loading-from-Fluid-Flowing.patch rename to patches/server/Prevent-chunk-loading-from-Fluid-Flowing.patch diff --git a/patches/unapplied/server/Prevent-consuming-the-wrong-itemstack.patch b/patches/server/Prevent-consuming-the-wrong-itemstack.patch similarity index 100% rename from patches/unapplied/server/Prevent-consuming-the-wrong-itemstack.patch rename to patches/server/Prevent-consuming-the-wrong-itemstack.patch diff --git a/patches/unapplied/server/Prevent-mob-spawning-from-loading-generating-chunks.patch b/patches/server/Prevent-mob-spawning-from-loading-generating-chunks.patch similarity index 100% rename from patches/unapplied/server/Prevent-mob-spawning-from-loading-generating-chunks.patch rename to patches/server/Prevent-mob-spawning-from-loading-generating-chunks.patch diff --git a/patches/unapplied/server/Prevent-rayTrace-from-loading-chunks.patch b/patches/server/Prevent-rayTrace-from-loading-chunks.patch similarity index 100% rename from patches/unapplied/server/Prevent-rayTrace-from-loading-chunks.patch rename to patches/server/Prevent-rayTrace-from-loading-chunks.patch diff --git a/patches/unapplied/server/Prevent-sync-chunk-loads-when-villagers-try-to-find-.patch b/patches/server/Prevent-sync-chunk-loads-when-villagers-try-to-find-.patch similarity index 100% rename from patches/unapplied/server/Prevent-sync-chunk-loads-when-villagers-try-to-find-.patch rename to patches/server/Prevent-sync-chunk-loads-when-villagers-try-to-find-.patch diff --git a/patches/unapplied/server/Reduce-Either-Optional-allocation.patch b/patches/server/Reduce-Either-Optional-allocation.patch similarity index 100% rename from patches/unapplied/server/Reduce-Either-Optional-allocation.patch rename to patches/server/Reduce-Either-Optional-allocation.patch diff --git a/patches/unapplied/server/Reduce-memory-footprint-of-NBTTagCompound.patch b/patches/server/Reduce-memory-footprint-of-NBTTagCompound.patch similarity index 100% rename from patches/unapplied/server/Reduce-memory-footprint-of-NBTTagCompound.patch rename to patches/server/Reduce-memory-footprint-of-NBTTagCompound.patch diff --git a/patches/unapplied/server/Remote-Connections-shouldn-t-hold-up-shutdown.patch b/patches/server/Remote-Connections-shouldn-t-hold-up-shutdown.patch similarity index 100% rename from patches/unapplied/server/Remote-Connections-shouldn-t-hold-up-shutdown.patch rename to patches/server/Remote-Connections-shouldn-t-hold-up-shutdown.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/Remove-unnecessary-itemmeta-handling.patch b/patches/server/Remove-unnecessary-itemmeta-handling.patch similarity index 100% rename from patches/unapplied/server/Remove-unnecessary-itemmeta-handling.patch rename to patches/server/Remove-unnecessary-itemmeta-handling.patch diff --git a/patches/unapplied/server/Reset-players-airTicks-on-respawn.patch b/patches/server/Reset-players-airTicks-on-respawn.patch similarity index 100% rename from patches/unapplied/server/Reset-players-airTicks-on-respawn.patch rename to patches/server/Reset-players-airTicks-on-respawn.patch diff --git a/patches/unapplied/server/Restore-custom-InventoryHolder-support.patch b/patches/server/Restore-custom-InventoryHolder-support.patch similarity index 100% rename from patches/unapplied/server/Restore-custom-InventoryHolder-support.patch rename to patches/server/Restore-custom-InventoryHolder-support.patch diff --git a/patches/unapplied/server/Restore-vanilla-default-mob-spawn-range-and-water-an.patch b/patches/server/Restore-vanilla-default-mob-spawn-range-and-water-an.patch similarity index 100% rename from patches/unapplied/server/Restore-vanilla-default-mob-spawn-range-and-water-an.patch rename to patches/server/Restore-vanilla-default-mob-spawn-range-and-water-an.patch diff --git a/patches/unapplied/server/Server-Tick-Events.patch b/patches/server/Server-Tick-Events.patch similarity index 100% rename from patches/unapplied/server/Server-Tick-Events.patch rename to patches/server/Server-Tick-Events.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/Show-blockstate-location-if-we-failed-to-read-it.patch b/patches/server/Show-blockstate-location-if-we-failed-to-read-it.patch similarity index 100% rename from patches/unapplied/server/Show-blockstate-location-if-we-failed-to-read-it.patch rename to patches/server/Show-blockstate-location-if-we-failed-to-read-it.patch diff --git a/patches/unapplied/server/Slime-Pathfinder-Events.patch b/patches/server/Slime-Pathfinder-Events.patch similarity index 100% rename from patches/unapplied/server/Slime-Pathfinder-Events.patch rename to patches/server/Slime-Pathfinder-Events.patch diff --git a/patches/server/Starlight.patch b/patches/server/Starlight.patch index 408a46cadd..e94003e9b8 100644 --- a/patches/server/Starlight.patch +++ b/patches/server/Starlight.patch @@ -5120,8 +5120,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 LevelChunkSection[] achunksection = new LevelChunkSection[i]; boolean flag1 = world.dimensionType().hasSkyLight(); ServerChunkCache chunkproviderserver = world.getChunkSource(); -- LevelLightEngine lightengine = chunkproviderserver.getLightEngine(); -+ LevelLightEngine lightengine = chunkproviderserver.getLightEngine();; + LevelLightEngine lightengine = chunkproviderserver.getLightEngine(); + // Paper start + ca.spottedleaf.starlight.common.light.SWMRNibbleArray[] blockNibbles = ca.spottedleaf.starlight.common.light.StarLightEngine.getFilledEmptyLight(world); + ca.spottedleaf.starlight.common.light.SWMRNibbleArray[] skyNibbles = ca.spottedleaf.starlight.common.light.StarLightEngine.getFilledEmptyLight(world); 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/Turtle-API.patch b/patches/server/Turtle-API.patch similarity index 100% rename from patches/unapplied/server/Turtle-API.patch rename to patches/server/Turtle-API.patch diff --git a/patches/unapplied/server/Use-ConcurrentHashMap-in-JsonList.patch b/patches/server/Use-ConcurrentHashMap-in-JsonList.patch similarity index 100% rename from patches/unapplied/server/Use-ConcurrentHashMap-in-JsonList.patch rename to patches/server/Use-ConcurrentHashMap-in-JsonList.patch diff --git a/patches/unapplied/server/Use-Vanilla-Minecart-Speeds.patch b/patches/server/Use-Vanilla-Minecart-Speeds.patch similarity index 100% rename from patches/unapplied/server/Use-Vanilla-Minecart-Speeds.patch rename to patches/server/Use-Vanilla-Minecart-Speeds.patch diff --git a/patches/unapplied/server/Use-a-Queue-for-Queueing-Commands.patch b/patches/server/Use-a-Queue-for-Queueing-Commands.patch similarity index 100% rename from patches/unapplied/server/Use-a-Queue-for-Queueing-Commands.patch rename to patches/server/Use-a-Queue-for-Queueing-Commands.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 100% rename from patches/unapplied/server/Validate-tripwire-hook-placement-before-update.patch rename to patches/server/Validate-tripwire-hook-placement-before-update.patch diff --git a/patches/unapplied/server/Workaround-for-vehicle-tracking-issue-on-disconnect.patch b/patches/server/Workaround-for-vehicle-tracking-issue-on-disconnect.patch similarity index 100% rename from patches/unapplied/server/Workaround-for-vehicle-tracking-issue-on-disconnect.patch rename to patches/server/Workaround-for-vehicle-tracking-issue-on-disconnect.patch 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/don-t-go-below-0-for-pickupDelay-breaks-picking-up-i.patch b/patches/server/don-t-go-below-0-for-pickupDelay-breaks-picking-up-i.patch similarity index 100% rename from patches/unapplied/server/don-t-go-below-0-for-pickupDelay-breaks-picking-up-i.patch rename to patches/server/don-t-go-below-0-for-pickupDelay-breaks-picking-up-i.patch diff --git a/patches/unapplied/server/force-entity-dismount-during-teleportation.patch b/patches/server/force-entity-dismount-during-teleportation.patch similarity index 100% rename from patches/unapplied/server/force-entity-dismount-during-teleportation.patch rename to patches/server/force-entity-dismount-during-teleportation.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 100% rename from patches/unapplied/server/implement-optional-per-player-mob-spawns.patch rename to patches/server/implement-optional-per-player-mob-spawns.patch diff --git a/patches/unapplied/server/offset-item-frame-ticking.patch b/patches/server/offset-item-frame-ticking.patch similarity index 100% rename from patches/unapplied/server/offset-item-frame-ticking.patch rename to patches/server/offset-item-frame-ticking.patch diff --git a/patches/unapplied/server/Properly-resend-entities.patch b/patches/unapplied/server/Properly-resend-entities.patch deleted file mode 100644 index 0c74b1418e..0000000000 --- a/patches/unapplied/server/Properly-resend-entities.patch +++ /dev/null @@ -1,147 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: Owen1212055 <23108066+Owen1212055@users.noreply.github.com> -Date: Fri, 22 Mar 2019 22:24:03 -0700 -Subject: [PATCH] Properly resend entities - -This resolves some issues which caused entities to not be resent correctly. -Entities that are interacted with need to be resent to the client, so we resend all the entity -data to the player whilst making sure not to clear dirty entries from the tracker. This makes -sure that values will be correctly updated to other players. - -See: https://github.com/PaperMC/Paper/pull/1896 - -Co-authored-by: AgentTroll m - -diff --git a/src/main/java/net/minecraft/network/protocol/game/ClientboundSetEntityDataPacket.java b/src/main/java/net/minecraft/network/protocol/game/ClientboundSetEntityDataPacket.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/net/minecraft/network/protocol/game/ClientboundSetEntityDataPacket.java -+++ b/src/main/java/net/minecraft/network/protocol/game/ClientboundSetEntityDataPacket.java -@@ -0,0 +0,0 @@ public class ClientboundSetEntityDataPacket implements Packet> packedItems; - - public ClientboundSetEntityDataPacket(int id, SynchedEntityData tracker, boolean forceUpdateAll) { -+ // Paper start -+ this(id, tracker, forceUpdateAll, true); -+ } -+ public ClientboundSetEntityDataPacket(int id, SynchedEntityData tracker, boolean forceUpdateAll, boolean clearDirty) { -+ // Paper end - this.id = id; - if (forceUpdateAll) { - this.packedItems = tracker.getAll(); -- tracker.clearDirty(); -+ if (clearDirty) tracker.clearDirty(); // Paper - } else { - this.packedItems = tracker.packDirty(); - } -diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/net/minecraft/server/level/ChunkMap.java -+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java -@@ -0,0 +0,0 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider - } - - } -+ // Paper start -+ // This method should only be used if the data of an entity could have became desynced -+ // due to interactions on the client. -+ public void resendPossiblyDesyncedEntity(ServerPlayer player) { -+ if (player.getBukkitEntity().canSee(entity.getBukkitEntity())) { -+ // This will prevent the entity data from being cleared, so that ONLY this player -+ // will have its entity data updated and it won't dirty the datatracker for other players. -+ this.serverEntity.clearDirtyEntityData = false; -+ this.serverEntity.sendPairingData(player.connection::send, player); -+ this.serverEntity.clearDirtyEntityData = true; -+ } -+ } -+ -+ public void resendPossiblyDesyncedEntityData(ServerPlayer player) { -+ if (player.getBukkitEntity().canSee(entity.getBukkitEntity())) { -+ player.connection.send(new net.minecraft.network.protocol.game.ClientboundSetEntityDataPacket(entity.getId(), entity.getEntityData(), true, false)); -+ } -+ } -+ // Paper end - } - } -diff --git a/src/main/java/net/minecraft/server/level/ServerEntity.java b/src/main/java/net/minecraft/server/level/ServerEntity.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/net/minecraft/server/level/ServerEntity.java -+++ b/src/main/java/net/minecraft/server/level/ServerEntity.java -@@ -0,0 +0,0 @@ public class ServerEntity { - private boolean wasOnGround; - // CraftBukkit start - final Set trackedPlayers; // Paper - private -> package -+ public boolean clearDirtyEntityData = true; // Paper - - public ServerEntity(ServerLevel worldserver, Entity entity, int i, boolean flag, Consumer> consumer, Set trackedPlayers) { - this.trackedPlayers = trackedPlayers; -@@ -0,0 +0,0 @@ public class ServerEntity { - this.yHeadRotp = Mth.floor(this.entity.getYHeadRot() * 256.0F / 360.0F); - consumer.accept(packet); - if (!this.entity.getEntityData().isEmpty()) { -- consumer.accept(new ClientboundSetEntityDataPacket(this.entity.getId(), this.entity.getEntityData(), true)); -+ consumer.accept(new ClientboundSetEntityDataPacket(this.entity.getId(), this.entity.getEntityData(), true, this.clearDirtyEntityData)); // Paper - } - - boolean flag = this.trackDelta; -@@ -0,0 +0,0 @@ public class ServerEntity { - - } - -+ // Paper start - Add broadcast method -+ @Deprecated(forRemoval = true) -+ void broadcast(Packet packet) { -+ this.broadcast.accept(packet); -+ } -+ // Paper end -+ - private void broadcastAndSend(Packet packet) { - this.broadcast.accept(packet); - if (this.entity instanceof ServerPlayer) { -diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -@@ -0,0 +0,0 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic - - // Entity in bucket - SPIGOT-4048 and SPIGOT-6859 - if ((entity instanceof Bucketable && entity instanceof LivingEntity && origItem != null && origItem.asItem() == Items.WATER_BUCKET) && (event.isCancelled() || ServerGamePacketListenerImpl.this.player.getInventory().getSelected() == null || ServerGamePacketListenerImpl.this.player.getInventory().getSelected().getItem() != origItem)) { -- ServerGamePacketListenerImpl.this.send(new ClientboundAddEntityPacket(entity)); -+ // Paper start -+ if (entity.tracker != null) { -+ entity.tracker.resendPossiblyDesyncedEntity(((ServerPlayer) player)); // The entire mob gets deleted, so resend it. -+ } -+ // Paper end - player.containerMenu.sendAllDataToRemote(); - } - -@@ -0,0 +0,0 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic - - if (event.isCancelled() || ServerGamePacketListenerImpl.this.player.getInventory().getSelected() == null || ServerGamePacketListenerImpl.this.player.getInventory().getSelected().getItem() != origItem) { - // Refresh the current entity metadata -- ServerGamePacketListenerImpl.this.send(new ClientboundSetEntityDataPacket(entity.getId(), entity.getEntityData(), true)); -+ // Paper start -+ if (entity.tracker != null) { -+ entity.tracker.resendPossiblyDesyncedEntityData(((ServerPlayer) player)); -+ } -+ // Paper end - // SPIGOT-7136 - Allays - if (entity instanceof Allay) { - ServerGamePacketListenerImpl.this.send(new ClientboundSetEquipmentPacket(entity.getId(), Arrays.stream(net.minecraft.world.entity.EquipmentSlot.values()).map((slot) -> Pair.of(slot, ((LivingEntity) entity).getItemBySlot(slot).copy())).collect(Collectors.toList()))); -diff --git a/src/main/java/net/minecraft/world/entity/animal/Bucketable.java b/src/main/java/net/minecraft/world/entity/animal/Bucketable.java -index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 ---- a/src/main/java/net/minecraft/world/entity/animal/Bucketable.java -+++ b/src/main/java/net/minecraft/world/entity/animal/Bucketable.java -@@ -0,0 +0,0 @@ public interface Bucketable { - itemstack1 = CraftItemStack.asNMSCopy(playerBucketFishEvent.getEntityBucket()); - if (playerBucketFishEvent.isCancelled()) { - ((ServerPlayer) player).containerMenu.sendAllDataToRemote(); // We need to update inventory to resync client's bucket -- ((ServerPlayer) player).connection.send(new ClientboundAddEntityPacket(entity)); // We need to play out these packets as the client assumes the fish is gone -- ((ServerPlayer) player).connection.send(new ClientboundSetEntityDataPacket(entity.getId(), entity.getEntityData(), true)); // Need to send data such as the display name to client -+ // Paper start -+ if (entity.tracker != null) { -+ entity.tracker.resendPossiblyDesyncedEntity(((ServerPlayer) player)); -+ } -+ // Paper end - return Optional.of(InteractionResult.FAIL); - } - entity.playSound(((Bucketable) entity).getPickupSound(), 1.0F, 1.0F);