From a3ccd44eddc63cb7cd10971a0b8d782c446f69b7 Mon Sep 17 00:00:00 2001 From: MrHua269 Date: Fri, 7 Feb 2025 22:27:47 +0800 Subject: [PATCH] Do not store tick count for living entities --- ...store-tick-count-for-living-entities.patch | 24 +++++++++++++++++++ ...aiiju-Don-t-pathfind-outside-region.patch} | 0 ...ju-Vanilla-end-portal-teleportation.patch} | 2 +- ...iju-Entity-tick-and-removal-limiter.patch} | 0 ...I-and-display-of-chunkhot-in-tpsbar.patch} | 2 +- ...7-Purpur-Use-alternative-keep-alive.patch} | 0 ...8-Purpur-Lobotomize-stuck-villagers.patch} | 0 ...ch => 0029-Petal-Reduce-sensor-work.patch} | 0 ...Cache-climbing-check-for-activation.patch} | 0 ...erfish-Reduce-chunk-loading-lookups.patch} | 0 ...32-Gale-Use-platform-math-functions.patch} | 0 ...le-Variable-entity-wake-up-duration.patch} | 0 ...kip-entity-move-if-movement-is-zero.patch} | 2 +- ...ttributes-with-optimized-collection.patch} | 0 ...0036-Gale-Optimize-noise-generation.patch} | 0 ...SparklyPaper-Optimize-canSee-checks.patch} | 0 ...-distanceToSqr-call-in-ServerEntity.patch} | 0 ...Secure-seed-and-matter-seed-command.patch} | 0 ...-api.patch => 0040-Tick-regions-api.patch} | 0 ...issing-teleportation-apis-for-folia.patch} | 2 +- ...ves-Disable-moved-wrongly-threshold.patch} | 0 ... 0043-Raytracing-tracker-experiment.patch} | 3 +-- .../0037-Raytracing-tracker-experiment.patch | 1 - 23 files changed, 29 insertions(+), 7 deletions(-) create mode 100644 luminol-server/minecraft-patches/features/0022-Do-not-store-tick-count-for-living-entities.patch rename luminol-server/minecraft-patches/features/{0022-Kaiiju-Don-t-pathfind-outside-region.patch => 0023-Kaiiju-Don-t-pathfind-outside-region.patch} (100%) rename luminol-server/minecraft-patches/features/{0023-Kaiiju-Vanilla-end-portal-teleportation.patch => 0024-Kaiiju-Vanilla-end-portal-teleportation.patch} (97%) rename luminol-server/minecraft-patches/features/{0024-Kaiiju-Entity-tick-and-removal-limiter.patch => 0025-Kaiiju-Entity-tick-and-removal-limiter.patch} (100%) rename luminol-server/minecraft-patches/features/{0025-KioCG-Chunk-API-and-display-of-chunkhot-in-tpsbar.patch => 0026-KioCG-Chunk-API-and-display-of-chunkhot-in-tpsbar.patch} (99%) rename luminol-server/minecraft-patches/features/{0026-Purpur-Use-alternative-keep-alive.patch => 0027-Purpur-Use-alternative-keep-alive.patch} (100%) rename luminol-server/minecraft-patches/features/{0027-Purpur-Lobotomize-stuck-villagers.patch => 0028-Purpur-Lobotomize-stuck-villagers.patch} (100%) rename luminol-server/minecraft-patches/features/{0028-Petal-Reduce-sensor-work.patch => 0029-Petal-Reduce-sensor-work.patch} (100%) rename luminol-server/minecraft-patches/features/{0029-Pufferfish-Cache-climbing-check-for-activation.patch => 0030-Pufferfish-Cache-climbing-check-for-activation.patch} (100%) rename luminol-server/minecraft-patches/features/{0030-Pufferfish-Reduce-chunk-loading-lookups.patch => 0031-Pufferfish-Reduce-chunk-loading-lookups.patch} (100%) rename luminol-server/minecraft-patches/features/{0031-Gale-Use-platform-math-functions.patch => 0032-Gale-Use-platform-math-functions.patch} (100%) rename luminol-server/minecraft-patches/features/{0032-Gale-Variable-entity-wake-up-duration.patch => 0033-Gale-Variable-entity-wake-up-duration.patch} (100%) rename luminol-server/minecraft-patches/features/{0033-Gale-Skip-entity-move-if-movement-is-zero.patch => 0034-Gale-Skip-entity-move-if-movement-is-zero.patch} (94%) rename luminol-server/minecraft-patches/features/{0034-Gale-Replace-AI-attributes-with-optimized-collection.patch => 0035-Gale-Replace-AI-attributes-with-optimized-collection.patch} (100%) rename luminol-server/minecraft-patches/features/{0035-Gale-Optimize-noise-generation.patch => 0036-Gale-Optimize-noise-generation.patch} (100%) rename luminol-server/minecraft-patches/features/{0036-SparklyPaper-Optimize-canSee-checks.patch => 0037-SparklyPaper-Optimize-canSee-checks.patch} (100%) rename luminol-server/minecraft-patches/features/{0037-SparklyPaper-Skip-distanceToSqr-call-in-ServerEntity.patch => 0038-SparklyPaper-Skip-distanceToSqr-call-in-ServerEntity.patch} (100%) rename luminol-server/minecraft-patches/features/{0038-Leaf-Secure-seed-and-matter-seed-command.patch => 0039-Leaf-Secure-seed-and-matter-seed-command.patch} (100%) rename luminol-server/minecraft-patches/features/{0039-Tick-regions-api.patch => 0040-Tick-regions-api.patch} (100%) rename luminol-server/minecraft-patches/features/{0040-Add-missing-teleportation-apis-for-folia.patch => 0041-Add-missing-teleportation-apis-for-folia.patch} (99%) rename luminol-server/minecraft-patches/features/{0041-Leaves-Disable-moved-wrongly-threshold.patch => 0042-Leaves-Disable-moved-wrongly-threshold.patch} (100%) rename luminol-server/minecraft-patches/features/{0042-Raytracing-tracker-experiment.patch => 0043-Raytracing-tracker-experiment.patch} (98%) diff --git a/luminol-server/minecraft-patches/features/0022-Do-not-store-tick-count-for-living-entities.patch b/luminol-server/minecraft-patches/features/0022-Do-not-store-tick-count-for-living-entities.patch new file mode 100644 index 0000000..1e6d563 --- /dev/null +++ b/luminol-server/minecraft-patches/features/0022-Do-not-store-tick-count-for-living-entities.patch @@ -0,0 +1,24 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: MrHua269 +Date: Fri, 7 Feb 2025 22:25:08 +0800 +Subject: [PATCH] Do not store tick count for living entities + + +diff --git a/net/minecraft/world/entity/Entity.java b/net/minecraft/world/entity/Entity.java +index 61814607a6c8e4ce8d07645f005ea8d53f624c95..d6af2839f6ad51f2a29a4e4a141778a2e93145d5 100644 +--- a/net/minecraft/world/entity/Entity.java ++++ b/net/minecraft/world/entity/Entity.java +@@ -2661,10 +2661,10 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess + } + // CraftBukkit start + // Spigot start +- if (this instanceof net.minecraft.world.entity.LivingEntity) { ++ /*if (this instanceof net.minecraft.world.entity.LivingEntity) { // Luminol - Do not store tick count for living entities + this.tickCount = compound.getInt("Spigot.ticksLived"); +- } +- // Spigot end ++ }*/ ++ // Spigot end // Luminol - Do not store tick count for living entities + this.persist = !compound.contains("Bukkit.persist") || compound.getBoolean("Bukkit.persist"); + this.visibleByDefault = !compound.contains("Bukkit.visibleByDefault") || compound.getBoolean("Bukkit.visibleByDefault"); + // SPIGOT-6907: re-implement LivingEntity#setMaximumAir() diff --git a/luminol-server/minecraft-patches/features/0022-Kaiiju-Don-t-pathfind-outside-region.patch b/luminol-server/minecraft-patches/features/0023-Kaiiju-Don-t-pathfind-outside-region.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0022-Kaiiju-Don-t-pathfind-outside-region.patch rename to luminol-server/minecraft-patches/features/0023-Kaiiju-Don-t-pathfind-outside-region.patch diff --git a/luminol-server/minecraft-patches/features/0023-Kaiiju-Vanilla-end-portal-teleportation.patch b/luminol-server/minecraft-patches/features/0024-Kaiiju-Vanilla-end-portal-teleportation.patch similarity index 97% rename from luminol-server/minecraft-patches/features/0023-Kaiiju-Vanilla-end-portal-teleportation.patch rename to luminol-server/minecraft-patches/features/0024-Kaiiju-Vanilla-end-portal-teleportation.patch index c7d61a7..2a57879 100644 --- a/luminol-server/minecraft-patches/features/0023-Kaiiju-Vanilla-end-portal-teleportation.patch +++ b/luminol-server/minecraft-patches/features/0024-Kaiiju-Vanilla-end-portal-teleportation.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Kaiiju Vanilla end portal teleportation diff --git a/net/minecraft/world/entity/Entity.java b/net/minecraft/world/entity/Entity.java -index 61814607a6c8e4ce8d07645f005ea8d53f624c95..5979893976ab8c59a17e306cd91c9a4f5cd3738e 100644 +index d6af2839f6ad51f2a29a4e4a141778a2e93145d5..f259701b82caef0a64659c69737f12b2f8d4c30a 100644 --- a/net/minecraft/world/entity/Entity.java +++ b/net/minecraft/world/entity/Entity.java @@ -110,6 +110,7 @@ import net.minecraft.world.level.block.Rotation; diff --git a/luminol-server/minecraft-patches/features/0024-Kaiiju-Entity-tick-and-removal-limiter.patch b/luminol-server/minecraft-patches/features/0025-Kaiiju-Entity-tick-and-removal-limiter.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0024-Kaiiju-Entity-tick-and-removal-limiter.patch rename to luminol-server/minecraft-patches/features/0025-Kaiiju-Entity-tick-and-removal-limiter.patch diff --git a/luminol-server/minecraft-patches/features/0025-KioCG-Chunk-API-and-display-of-chunkhot-in-tpsbar.patch b/luminol-server/minecraft-patches/features/0026-KioCG-Chunk-API-and-display-of-chunkhot-in-tpsbar.patch similarity index 99% rename from luminol-server/minecraft-patches/features/0025-KioCG-Chunk-API-and-display-of-chunkhot-in-tpsbar.patch rename to luminol-server/minecraft-patches/features/0026-KioCG-Chunk-API-and-display-of-chunkhot-in-tpsbar.patch index 8c0f307..08d67bb 100644 --- a/luminol-server/minecraft-patches/features/0025-KioCG-Chunk-API-and-display-of-chunkhot-in-tpsbar.patch +++ b/luminol-server/minecraft-patches/features/0026-KioCG-Chunk-API-and-display-of-chunkhot-in-tpsbar.patch @@ -159,7 +159,7 @@ index 23b342cc31c7e72ade0e1ccad86a9ccf34380f13..249cb7326c8e4012dcffdb6bbb7bfc1f + // KioCG end } diff --git a/net/minecraft/world/entity/Entity.java b/net/minecraft/world/entity/Entity.java -index 5979893976ab8c59a17e306cd91c9a4f5cd3738e..4f0ea00cd601c62926220400c8e3597815dc4d15 100644 +index f259701b82caef0a64659c69737f12b2f8d4c30a..0cf1fb6b7be70f1aeb6f664d86d2c695a2b16d8b 100644 --- a/net/minecraft/world/entity/Entity.java +++ b/net/minecraft/world/entity/Entity.java @@ -5967,4 +5967,6 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess diff --git a/luminol-server/minecraft-patches/features/0026-Purpur-Use-alternative-keep-alive.patch b/luminol-server/minecraft-patches/features/0027-Purpur-Use-alternative-keep-alive.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0026-Purpur-Use-alternative-keep-alive.patch rename to luminol-server/minecraft-patches/features/0027-Purpur-Use-alternative-keep-alive.patch diff --git a/luminol-server/minecraft-patches/features/0027-Purpur-Lobotomize-stuck-villagers.patch b/luminol-server/minecraft-patches/features/0028-Purpur-Lobotomize-stuck-villagers.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0027-Purpur-Lobotomize-stuck-villagers.patch rename to luminol-server/minecraft-patches/features/0028-Purpur-Lobotomize-stuck-villagers.patch diff --git a/luminol-server/minecraft-patches/features/0028-Petal-Reduce-sensor-work.patch b/luminol-server/minecraft-patches/features/0029-Petal-Reduce-sensor-work.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0028-Petal-Reduce-sensor-work.patch rename to luminol-server/minecraft-patches/features/0029-Petal-Reduce-sensor-work.patch diff --git a/luminol-server/minecraft-patches/features/0029-Pufferfish-Cache-climbing-check-for-activation.patch b/luminol-server/minecraft-patches/features/0030-Pufferfish-Cache-climbing-check-for-activation.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0029-Pufferfish-Cache-climbing-check-for-activation.patch rename to luminol-server/minecraft-patches/features/0030-Pufferfish-Cache-climbing-check-for-activation.patch diff --git a/luminol-server/minecraft-patches/features/0030-Pufferfish-Reduce-chunk-loading-lookups.patch b/luminol-server/minecraft-patches/features/0031-Pufferfish-Reduce-chunk-loading-lookups.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0030-Pufferfish-Reduce-chunk-loading-lookups.patch rename to luminol-server/minecraft-patches/features/0031-Pufferfish-Reduce-chunk-loading-lookups.patch diff --git a/luminol-server/minecraft-patches/features/0031-Gale-Use-platform-math-functions.patch b/luminol-server/minecraft-patches/features/0032-Gale-Use-platform-math-functions.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0031-Gale-Use-platform-math-functions.patch rename to luminol-server/minecraft-patches/features/0032-Gale-Use-platform-math-functions.patch diff --git a/luminol-server/minecraft-patches/features/0032-Gale-Variable-entity-wake-up-duration.patch b/luminol-server/minecraft-patches/features/0033-Gale-Variable-entity-wake-up-duration.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0032-Gale-Variable-entity-wake-up-duration.patch rename to luminol-server/minecraft-patches/features/0033-Gale-Variable-entity-wake-up-duration.patch diff --git a/luminol-server/minecraft-patches/features/0033-Gale-Skip-entity-move-if-movement-is-zero.patch b/luminol-server/minecraft-patches/features/0034-Gale-Skip-entity-move-if-movement-is-zero.patch similarity index 94% rename from luminol-server/minecraft-patches/features/0033-Gale-Skip-entity-move-if-movement-is-zero.patch rename to luminol-server/minecraft-patches/features/0034-Gale-Skip-entity-move-if-movement-is-zero.patch index a220d91..812bcb2 100644 --- a/luminol-server/minecraft-patches/features/0033-Gale-Skip-entity-move-if-movement-is-zero.patch +++ b/luminol-server/minecraft-patches/features/0034-Gale-Skip-entity-move-if-movement-is-zero.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Gale Skip entity move if movement is zero diff --git a/net/minecraft/world/entity/Entity.java b/net/minecraft/world/entity/Entity.java -index 4f0ea00cd601c62926220400c8e3597815dc4d15..a826320496a7a211cc07518adedfec9bdf8728b8 100644 +index 0cf1fb6b7be70f1aeb6f664d86d2c695a2b16d8b..2b1db01621cdf0db1e524c99c9ba2af5d845cdec 100644 --- a/net/minecraft/world/entity/Entity.java +++ b/net/minecraft/world/entity/Entity.java @@ -1104,7 +1104,14 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess diff --git a/luminol-server/minecraft-patches/features/0034-Gale-Replace-AI-attributes-with-optimized-collection.patch b/luminol-server/minecraft-patches/features/0035-Gale-Replace-AI-attributes-with-optimized-collection.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0034-Gale-Replace-AI-attributes-with-optimized-collection.patch rename to luminol-server/minecraft-patches/features/0035-Gale-Replace-AI-attributes-with-optimized-collection.patch diff --git a/luminol-server/minecraft-patches/features/0035-Gale-Optimize-noise-generation.patch b/luminol-server/minecraft-patches/features/0036-Gale-Optimize-noise-generation.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0035-Gale-Optimize-noise-generation.patch rename to luminol-server/minecraft-patches/features/0036-Gale-Optimize-noise-generation.patch diff --git a/luminol-server/minecraft-patches/features/0036-SparklyPaper-Optimize-canSee-checks.patch b/luminol-server/minecraft-patches/features/0037-SparklyPaper-Optimize-canSee-checks.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0036-SparklyPaper-Optimize-canSee-checks.patch rename to luminol-server/minecraft-patches/features/0037-SparklyPaper-Optimize-canSee-checks.patch diff --git a/luminol-server/minecraft-patches/features/0037-SparklyPaper-Skip-distanceToSqr-call-in-ServerEntity.patch b/luminol-server/minecraft-patches/features/0038-SparklyPaper-Skip-distanceToSqr-call-in-ServerEntity.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0037-SparklyPaper-Skip-distanceToSqr-call-in-ServerEntity.patch rename to luminol-server/minecraft-patches/features/0038-SparklyPaper-Skip-distanceToSqr-call-in-ServerEntity.patch diff --git a/luminol-server/minecraft-patches/features/0038-Leaf-Secure-seed-and-matter-seed-command.patch b/luminol-server/minecraft-patches/features/0039-Leaf-Secure-seed-and-matter-seed-command.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0038-Leaf-Secure-seed-and-matter-seed-command.patch rename to luminol-server/minecraft-patches/features/0039-Leaf-Secure-seed-and-matter-seed-command.patch diff --git a/luminol-server/minecraft-patches/features/0039-Tick-regions-api.patch b/luminol-server/minecraft-patches/features/0040-Tick-regions-api.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0039-Tick-regions-api.patch rename to luminol-server/minecraft-patches/features/0040-Tick-regions-api.patch diff --git a/luminol-server/minecraft-patches/features/0040-Add-missing-teleportation-apis-for-folia.patch b/luminol-server/minecraft-patches/features/0041-Add-missing-teleportation-apis-for-folia.patch similarity index 99% rename from luminol-server/minecraft-patches/features/0040-Add-missing-teleportation-apis-for-folia.patch rename to luminol-server/minecraft-patches/features/0041-Add-missing-teleportation-apis-for-folia.patch index 1307d0b..23ce94b 100644 --- a/luminol-server/minecraft-patches/features/0040-Add-missing-teleportation-apis-for-folia.patch +++ b/luminol-server/minecraft-patches/features/0041-Add-missing-teleportation-apis-for-folia.patch @@ -19,7 +19,7 @@ index 9fd3fe181df2ce6dbe695f6463d3940ac4c01167..822d401150d3764004b2570da828b4f6 ); }); diff --git a/net/minecraft/world/entity/Entity.java b/net/minecraft/world/entity/Entity.java -index a826320496a7a211cc07518adedfec9bdf8728b8..6f9cfd8c72853d9cb30c9731a96e7f1e8f0644c4 100644 +index 2b1db01621cdf0db1e524c99c9ba2af5d845cdec..c14f766f1bea5c3c94d124da09d7bf9dfbfb1966 100644 --- a/net/minecraft/world/entity/Entity.java +++ b/net/minecraft/world/entity/Entity.java @@ -4166,6 +4166,31 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess diff --git a/luminol-server/minecraft-patches/features/0041-Leaves-Disable-moved-wrongly-threshold.patch b/luminol-server/minecraft-patches/features/0042-Leaves-Disable-moved-wrongly-threshold.patch similarity index 100% rename from luminol-server/minecraft-patches/features/0041-Leaves-Disable-moved-wrongly-threshold.patch rename to luminol-server/minecraft-patches/features/0042-Leaves-Disable-moved-wrongly-threshold.patch diff --git a/luminol-server/minecraft-patches/features/0042-Raytracing-tracker-experiment.patch b/luminol-server/minecraft-patches/features/0043-Raytracing-tracker-experiment.patch similarity index 98% rename from luminol-server/minecraft-patches/features/0042-Raytracing-tracker-experiment.patch rename to luminol-server/minecraft-patches/features/0043-Raytracing-tracker-experiment.patch index f11109a..c26d718 100644 --- a/luminol-server/minecraft-patches/features/0042-Raytracing-tracker-experiment.patch +++ b/luminol-server/minecraft-patches/features/0043-Raytracing-tracker-experiment.patch @@ -5,7 +5,6 @@ Subject: [PATCH] Raytracing tracker experiment Based on the framework of EntityCulling((((((( - diff --git a/net/minecraft/server/level/ChunkMap.java b/net/minecraft/server/level/ChunkMap.java index 7eff847790394aecd058e7a61905da86163b4c6e..9099457f55a2829297ac1db8a69a98ff717d9a86 100644 --- a/net/minecraft/server/level/ChunkMap.java @@ -20,7 +19,7 @@ index 7eff847790394aecd058e7a61905da86163b4c6e..9099457f55a2829297ac1db8a69a98ff double rangeY = level.paperConfig().entities.trackingRangeY.get(this.entity, -1); if (rangeY != -1) { diff --git a/net/minecraft/world/entity/Entity.java b/net/minecraft/world/entity/Entity.java -index 6f9cfd8c72853d9cb30c9731a96e7f1e8f0644c4..b1ded501047f75d2e7af775bf8866fd6a5400a91 100644 +index c14f766f1bea5c3c94d124da09d7bf9dfbfb1966..40c0bb7dbdd0e58ca9d3fb242774fd1fc3dc3a6c 100644 --- a/net/minecraft/world/entity/Entity.java +++ b/net/minecraft/world/entity/Entity.java @@ -136,7 +136,7 @@ import net.minecraft.world.scores.ScoreHolder; diff --git a/luminol-server/paper-patches/features/0037-Raytracing-tracker-experiment.patch b/luminol-server/paper-patches/features/0037-Raytracing-tracker-experiment.patch index e078f4b..851e88d 100644 --- a/luminol-server/paper-patches/features/0037-Raytracing-tracker-experiment.patch +++ b/luminol-server/paper-patches/features/0037-Raytracing-tracker-experiment.patch @@ -5,7 +5,6 @@ Subject: [PATCH] Raytracing tracker experiment Based on the framework of EntityCulling((((((( - diff --git a/src/main/java/com/logisticscraft/occlusionculling/DataProvider.java b/src/main/java/com/logisticscraft/occlusionculling/DataProvider.java new file mode 100644 index 0000000000000000000000000000000000000000..5ab4600554e8dcb2a2ddc22dd1c1015c89ba5b82