diff options
author | Nassim Jahnke <[email protected]> | 2024-12-05 11:18:29 +0100 |
---|---|---|
committer | Nassim Jahnke <[email protected]> | 2024-12-05 12:20:56 +0100 |
commit | e4e24f3335609b38f460ced71d18babcf11bf9cb (patch) | |
tree | 51880d664b3444ce26d6f8cdeb3b8219e5616fca /patches/server/0357-Use-seed-based-lookup-for-Treasure-Maps-Fixes-lag-fr.patch | |
parent | c54c062e6ff742445bf7749c84106ca67090172d (diff) | |
download | Paper-e4e24f3335609b38f460ced71d18babcf11bf9cb.tar.gz Paper-e4e24f3335609b38f460ced71d18babcf11bf9cb.zip |
Move around patches again
Diffstat (limited to 'patches/server/0357-Use-seed-based-lookup-for-Treasure-Maps-Fixes-lag-fr.patch')
-rw-r--r-- | patches/server/0357-Use-seed-based-lookup-for-Treasure-Maps-Fixes-lag-fr.patch | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/patches/server/0357-Use-seed-based-lookup-for-Treasure-Maps-Fixes-lag-fr.patch b/patches/server/0357-Use-seed-based-lookup-for-Treasure-Maps-Fixes-lag-fr.patch new file mode 100644 index 0000000000..a9541d0791 --- /dev/null +++ b/patches/server/0357-Use-seed-based-lookup-for-Treasure-Maps-Fixes-lag-fr.patch @@ -0,0 +1,20 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Aikar <[email protected]> +Date: Sun, 7 Jun 2020 19:25:13 -0400 +Subject: [PATCH] Use seed based lookup for Treasure Maps - Fixes lag from + carto/sunken maps + + +diff --git a/src/main/java/net/minecraft/world/item/MapItem.java b/src/main/java/net/minecraft/world/item/MapItem.java +index adec25694820189b6f77913db1bf7c581458d2ab..8ff50a4c7461bbd9f469d503f6b5ee482d2463d7 100644 +--- a/src/main/java/net/minecraft/world/item/MapItem.java ++++ b/src/main/java/net/minecraft/world/item/MapItem.java +@@ -205,7 +205,7 @@ public class MapItem extends Item { + + for (int n = 0; n < 128; n++) { + for (int o = 0; o < 128; o++) { +- Holder<Biome> holder = world.getBiome(mutableBlockPos.set((l + o) * i, 0, (m + n) * i)); ++ Holder<Biome> holder = world.getUncachedNoiseBiome((l + o) * i, 0, (m + n) * i); // Paper - Perf: Use seed based lookup for treasure maps + bls[n * 128 + o] = holder.is(BiomeTags.WATER_ON_MAP_OUTLINES); + } + } |