Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-11-15 04:20:04 +01:00
Update to 1.18.1 (#7076)
Dieser Commit ist enthalten in:
Ursprung
dce79f333c
Commit
1c779c2d2e
@ -46,7 +46,7 @@ repositories {
|
|||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
paramMappings("net.fabricmc:yarn:1.18+build.1:mergedv2")
|
paramMappings("net.fabricmc:yarn:1.18.1+build.1:mergedv2")
|
||||||
remapper("net.fabricmc:tiny-remapper:0.7.0:fat")
|
remapper("net.fabricmc:tiny-remapper:0.7.0:fat")
|
||||||
decompiler("net.minecraftforge:forgeflower:1.5.498.22")
|
decompiler("net.minecraftforge:forgeflower:1.5.498.22")
|
||||||
paperclip("io.papermc:paperclip:3.0.2")
|
paperclip("io.papermc:paperclip:3.0.2")
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
group=io.papermc.paper
|
group=io.papermc.paper
|
||||||
version=1.18-R0.1-SNAPSHOT
|
version=1.18.1-R0.1-SNAPSHOT
|
||||||
|
|
||||||
mcVersion=1.18
|
mcVersion=1.18.1
|
||||||
|
|
||||||
org.gradle.caching=true
|
org.gradle.caching=true
|
||||||
org.gradle.parallel=true
|
org.gradle.parallel=true
|
||||||
|
@ -99,7 +99,7 @@ index 0000000000000000000000000000000000000000..1b16a242187079f80720fc1990ee09bb
|
|||||||
+}
|
+}
|
||||||
diff --git a/pom.xml b/pom.xml
|
diff --git a/pom.xml b/pom.xml
|
||||||
deleted file mode 100644
|
deleted file mode 100644
|
||||||
index 236c9e76bbbb6db5eafd03b1468ecf9fac3416fc..0000000000000000000000000000000000000000
|
index 0e69806e4b6fa44d1d2f8ebf1cf0dc4ef386e69e..0000000000000000000000000000000000000000
|
||||||
--- a/pom.xml
|
--- a/pom.xml
|
||||||
+++ /dev/null
|
+++ /dev/null
|
||||||
@@ -1,262 +0,0 @@
|
@@ -1,262 +0,0 @@
|
||||||
@ -110,7 +110,7 @@ index 236c9e76bbbb6db5eafd03b1468ecf9fac3416fc..00000000000000000000000000000000
|
|||||||
-
|
-
|
||||||
- <groupId>org.spigotmc</groupId>
|
- <groupId>org.spigotmc</groupId>
|
||||||
- <artifactId>spigot-api</artifactId>
|
- <artifactId>spigot-api</artifactId>
|
||||||
- <version>1.18-R0.1-SNAPSHOT</version>
|
- <version>1.18.1-R0.1-SNAPSHOT</version>
|
||||||
- <packaging>jar</packaging>
|
- <packaging>jar</packaging>
|
||||||
-
|
-
|
||||||
- <name>Spigot-API</name>
|
- <name>Spigot-API</name>
|
||||||
|
@ -175,7 +175,7 @@ index 0000000000000000000000000000000000000000..9c4382ef7373110b6e72163779316ff4
|
|||||||
+}
|
+}
|
||||||
diff --git a/pom.xml b/pom.xml
|
diff --git a/pom.xml b/pom.xml
|
||||||
deleted file mode 100644
|
deleted file mode 100644
|
||||||
index 1ab6e8bd68a3fff2ec8795da099e4f8cce8b62ca..0000000000000000000000000000000000000000
|
index 56938962e9ba6b188c2f4bc1694b911f05994436..0000000000000000000000000000000000000000
|
||||||
--- a/pom.xml
|
--- a/pom.xml
|
||||||
+++ /dev/null
|
+++ /dev/null
|
||||||
@@ -1,540 +0,0 @@
|
@@ -1,540 +0,0 @@
|
||||||
@ -185,7 +185,7 @@ index 1ab6e8bd68a3fff2ec8795da099e4f8cce8b62ca..00000000000000000000000000000000
|
|||||||
- <groupId>org.spigotmc</groupId>
|
- <groupId>org.spigotmc</groupId>
|
||||||
- <artifactId>spigot</artifactId>
|
- <artifactId>spigot</artifactId>
|
||||||
- <packaging>jar</packaging>
|
- <packaging>jar</packaging>
|
||||||
- <version>1.18-R0.1-SNAPSHOT</version>
|
- <version>1.18.1-R0.1-SNAPSHOT</version>
|
||||||
- <name>Spigot</name>
|
- <name>Spigot</name>
|
||||||
- <url>https://www.spigotmc.org/</url>
|
- <url>https://www.spigotmc.org/</url>
|
||||||
-
|
-
|
||||||
|
@ -39,10 +39,10 @@ index 9c4382ef7373110b6e72163779316ff40234a992..bba267ecca0121df22fdfa6096101786
|
|||||||
for (tld in setOf("net", "com", "org")) {
|
for (tld in setOf("net", "com", "org")) {
|
||||||
attributes("$tld/bukkit", "Sealed" to true)
|
attributes("$tld/bukkit", "Sealed" to true)
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
index dd755cbbf65614c010cc178d8945cf918b7be326..56f102a7b749a6294056d0f2db175f13970248a9 100644
|
index 21713baa2db85a49dae0fa7675776b029f8bf4c9..ec50a122331b2ceb19822273f89f32b66a9f7db0 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
@@ -192,7 +192,7 @@ public class Main {
|
@@ -190,7 +190,7 @@ public class Main {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Main.class.getPackage().getImplementationVendor() != null && System.getProperty("IReallyKnowWhatIAmDoingISwear") == null) {
|
if (Main.class.getPackage().getImplementationVendor() != null && System.getProperty("IReallyKnowWhatIAmDoingISwear") == null) {
|
||||||
|
@ -591,7 +591,7 @@ index 0000000000000000000000000000000000000000..4adf44026fc6269934dfa4513f06a7f8
|
|||||||
+ }
|
+ }
|
||||||
+}
|
+}
|
||||||
diff --git a/src/main/java/net/minecraft/server/Main.java b/src/main/java/net/minecraft/server/Main.java
|
diff --git a/src/main/java/net/minecraft/server/Main.java b/src/main/java/net/minecraft/server/Main.java
|
||||||
index dc2cb18ec926e2eed1caa8e2106e70bcb04f6c0f..a497b281d03c097587b21e9f141a6a66f36e4dad 100644
|
index 82d04f803201e39b48cd514cd8d9e2b90b28c1d4..156fa293626119caf0cf414505fdf0e96eaa08b7 100644
|
||||||
--- a/src/main/java/net/minecraft/server/Main.java
|
--- a/src/main/java/net/minecraft/server/Main.java
|
||||||
+++ b/src/main/java/net/minecraft/server/Main.java
|
+++ b/src/main/java/net/minecraft/server/Main.java
|
||||||
@@ -106,6 +106,12 @@ public class Main {
|
@@ -106,6 +106,12 @@ public class Main {
|
||||||
@ -777,10 +777,10 @@ index ae0e8dc6fd3f8323c34df83450a16fc3c44a9e5e..980e5abe159ebfdf5334332b8d8201c0
|
|||||||
+ // Paper end
|
+ // Paper end
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
index 56f102a7b749a6294056d0f2db175f13970248a9..45b0da909136989d60c47bbff2ad9962f5c7f170 100644
|
index ec50a122331b2ceb19822273f89f32b66a9f7db0..2bd2f436d5514b5e9bbc8bbd27ead4d4cb529b4f 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
@@ -131,6 +131,14 @@ public class Main {
|
@@ -129,6 +129,14 @@ public class Main {
|
||||||
.defaultsTo(new File("spigot.yml"))
|
.defaultsTo(new File("spigot.yml"))
|
||||||
.describedAs("Yml file");
|
.describedAs("Yml file");
|
||||||
// Spigot End
|
// Spigot End
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] MC Dev fixes
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/Util.java b/src/main/java/net/minecraft/Util.java
|
diff --git a/src/main/java/net/minecraft/Util.java b/src/main/java/net/minecraft/Util.java
|
||||||
index 486d01f5cb69c58878ad7d2fa06ee1154486e55d..58dbe9077fc12964477d6a6fb57d67c41865412c 100644
|
index 820ba0832fb2a7afe37f461a126e90613d775ff4..1851b36f978330651627f902f1c123337cdf9075 100644
|
||||||
--- a/src/main/java/net/minecraft/Util.java
|
--- a/src/main/java/net/minecraft/Util.java
|
||||||
+++ b/src/main/java/net/minecraft/Util.java
|
+++ b/src/main/java/net/minecraft/Util.java
|
||||||
@@ -345,7 +345,7 @@ public class Util {
|
@@ -354,7 +354,7 @@ public class Util {
|
||||||
}
|
}
|
||||||
|
|
||||||
public static <K> Strategy<K> identityStrategy() {
|
public static <K> Strategy<K> identityStrategy() {
|
||||||
|
@ -4414,10 +4414,10 @@ index 0000000000000000000000000000000000000000..4d3dc8fba51bf5c0dceb06744781d1df
|
|||||||
+ }
|
+ }
|
||||||
+}
|
+}
|
||||||
diff --git a/src/main/java/net/minecraft/Util.java b/src/main/java/net/minecraft/Util.java
|
diff --git a/src/main/java/net/minecraft/Util.java b/src/main/java/net/minecraft/Util.java
|
||||||
index 58dbe9077fc12964477d6a6fb57d67c41865412c..3ed0bf0485266c0a2b459f5cc1940f85f74e3624 100644
|
index 1851b36f978330651627f902f1c123337cdf9075..5c57a6607f1a95ac4d8770d0429d6848351f5452 100644
|
||||||
--- a/src/main/java/net/minecraft/Util.java
|
--- a/src/main/java/net/minecraft/Util.java
|
||||||
+++ b/src/main/java/net/minecraft/Util.java
|
+++ b/src/main/java/net/minecraft/Util.java
|
||||||
@@ -98,7 +98,7 @@ public class Util {
|
@@ -107,7 +107,7 @@ public class Util {
|
||||||
}
|
}
|
||||||
|
|
||||||
public static long getNanos() {
|
public static long getNanos() {
|
||||||
@ -5285,7 +5285,7 @@ index 40dd2077f26a2c1fa15f21861204faa53748140e..45de5e508540b4ba622985d530f1aada
|
|||||||
+ // Paper end
|
+ // Paper end
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index fa2ff0d8e7f6015200dded40335fe6245d9c6bcf..e4d2771e86a0de4ea8bd08ca5811ce7a2e38c7d1 100644
|
index 6628fd9cff01a3ddb736ec829566afcd08a7f95e..f3a2a5dcd18d8abe370779f75106eacab498c3b6 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -59,6 +59,7 @@ import net.minecraft.network.protocol.game.ClientboundSetChunkCacheCenterPacket;
|
@@ -59,6 +59,7 @@ import net.minecraft.network.protocol.game.ClientboundSetChunkCacheCenterPacket;
|
||||||
@ -5364,7 +5364,7 @@ index fa2ff0d8e7f6015200dded40335fe6245d9c6bcf..e4d2771e86a0de4ea8bd08ca5811ce7a
|
|||||||
}
|
}
|
||||||
|
|
||||||
protected ChunkGenerator generator() {
|
protected ChunkGenerator generator() {
|
||||||
@@ -320,6 +375,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -282,6 +337,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -5379,7 +5379,7 @@ index fa2ff0d8e7f6015200dded40335fe6245d9c6bcf..e4d2771e86a0de4ea8bd08ca5811ce7a
|
|||||||
private CompletableFuture<Either<List<ChunkAccess>, ChunkHolder.ChunkLoadingFailure>> getChunkRangeFuture(ChunkPos centerChunk, int margin, IntFunction<ChunkStatus> distanceToStatus) {
|
private CompletableFuture<Either<List<ChunkAccess>, ChunkHolder.ChunkLoadingFailure>> getChunkRangeFuture(ChunkPos centerChunk, int margin, IntFunction<ChunkStatus> distanceToStatus) {
|
||||||
List<CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>>> list = new ArrayList();
|
List<CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>>> list = new ArrayList();
|
||||||
List<ChunkHolder> list1 = new ArrayList();
|
List<ChunkHolder> list1 = new ArrayList();
|
||||||
@@ -420,6 +483,11 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -382,6 +445,11 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
holder.setTicketLevel(level);
|
holder.setTicketLevel(level);
|
||||||
} else {
|
} else {
|
||||||
holder = new ChunkHolder(new ChunkPos(pos), level, this.level, this.lightEngine, this.queueSorter, this);
|
holder = new ChunkHolder(new ChunkPos(pos), level, this.level, this.lightEngine, this.queueSorter, this);
|
||||||
@ -5391,7 +5391,7 @@ index fa2ff0d8e7f6015200dded40335fe6245d9c6bcf..e4d2771e86a0de4ea8bd08ca5811ce7a
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.updatingChunkMap.put(pos, holder);
|
this.updatingChunkMap.put(pos, holder);
|
||||||
@@ -545,7 +613,13 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -507,7 +575,13 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
if (completablefuture1 != completablefuture) {
|
if (completablefuture1 != completablefuture) {
|
||||||
this.scheduleUnload(pos, holder);
|
this.scheduleUnload(pos, holder);
|
||||||
} else {
|
} else {
|
||||||
@ -5406,7 +5406,7 @@ index fa2ff0d8e7f6015200dded40335fe6245d9c6bcf..e4d2771e86a0de4ea8bd08ca5811ce7a
|
|||||||
if (ichunkaccess instanceof LevelChunk) {
|
if (ichunkaccess instanceof LevelChunk) {
|
||||||
((LevelChunk) ichunkaccess).setLoaded(false);
|
((LevelChunk) ichunkaccess).setLoaded(false);
|
||||||
}
|
}
|
||||||
@@ -560,7 +634,11 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -522,7 +596,11 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
this.lightEngine.updateChunkStatus(ichunkaccess.getPos());
|
this.lightEngine.updateChunkStatus(ichunkaccess.getPos());
|
||||||
this.lightEngine.tryScheduleUpdate();
|
this.lightEngine.tryScheduleUpdate();
|
||||||
this.progressListener.onStatusChange(ichunkaccess.getPos(), (ChunkStatus) null);
|
this.progressListener.onStatusChange(ichunkaccess.getPos(), (ChunkStatus) null);
|
||||||
@ -5419,7 +5419,7 @@ index fa2ff0d8e7f6015200dded40335fe6245d9c6bcf..e4d2771e86a0de4ea8bd08ca5811ce7a
|
|||||||
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@@ -1094,6 +1172,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1057,6 +1135,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
if (!flag1) {
|
if (!flag1) {
|
||||||
this.distanceManager.addPlayer(SectionPos.of((Entity) player), player);
|
this.distanceManager.addPlayer(SectionPos.of((Entity) player), player);
|
||||||
}
|
}
|
||||||
@ -5427,15 +5427,15 @@ index fa2ff0d8e7f6015200dded40335fe6245d9c6bcf..e4d2771e86a0de4ea8bd08ca5811ce7a
|
|||||||
} else {
|
} else {
|
||||||
SectionPos sectionposition = player.getLastSectionPos();
|
SectionPos sectionposition = player.getLastSectionPos();
|
||||||
|
|
||||||
@@ -1101,6 +1180,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1064,6 +1143,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
if (!flag2) {
|
if (!flag2) {
|
||||||
this.distanceManager.removePlayer(sectionposition, player);
|
this.distanceManager.removePlayer(sectionposition, player);
|
||||||
}
|
}
|
||||||
+ this.removePlayerFromDistanceMaps(player); // Paper - distance maps
|
+ this.removePlayerFromDistanceMaps(player); // Paper - distance maps
|
||||||
}
|
}
|
||||||
|
|
||||||
for (int k = i - this.viewDistance; k <= i + this.viewDistance; ++k) {
|
for (int k = i - this.viewDistance - 1; k <= i + this.viewDistance + 1; ++k) {
|
||||||
@@ -1217,6 +1297,8 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1176,6 +1256,8 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -5444,7 +5444,7 @@ index fa2ff0d8e7f6015200dded40335fe6245d9c6bcf..e4d2771e86a0de4ea8bd08ca5811ce7a
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -1419,7 +1501,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1379,7 +1461,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
public class ChunkDistanceManager extends DistanceManager {
|
public class ChunkDistanceManager extends DistanceManager {
|
||||||
|
|
||||||
protected ChunkDistanceManager(Executor workerExecutor, Executor mainThreadExecutor) {
|
protected ChunkDistanceManager(Executor workerExecutor, Executor mainThreadExecutor) {
|
||||||
@ -5875,18 +5875,10 @@ index d672c467267ef4d96184e104c35d0379116880db..be11caf7c0dcdb11e24cfb053cda45ac
|
|||||||
@Override
|
@Override
|
||||||
public ChunkAccess getChunk(int x, int z, ChunkStatus leastStatus, boolean create) {
|
public ChunkAccess getChunk(int x, int z, ChunkStatus leastStatus, boolean create) {
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 9812116e2f28d01423373990ecce0e5ab6229ce2..e66b4837498a8bfefabc4dd95e91ccfba67843e4 100644
|
index 5ee375a81164bbf18b8fc8e4fec5869187438078..ce9ff034a281cd9cc76c26713b6d1eab3f6c9fe2 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -9,6 +9,7 @@ import it.unimi.dsi.fastutil.longs.LongSet;
|
@@ -159,6 +159,7 @@ import org.bukkit.event.server.MapInitializeEvent;
|
||||||
import it.unimi.dsi.fastutil.longs.LongSets;
|
|
||||||
import it.unimi.dsi.fastutil.objects.Object2IntMap.Entry;
|
|
||||||
import it.unimi.dsi.fastutil.objects.Object2IntOpenHashMap;
|
|
||||||
+import it.unimi.dsi.fastutil.objects.Object2IntMap;
|
|
||||||
import it.unimi.dsi.fastutil.objects.ObjectIterator;
|
|
||||||
import it.unimi.dsi.fastutil.objects.ObjectLinkedOpenHashSet;
|
|
||||||
import it.unimi.dsi.fastutil.objects.ObjectOpenHashSet;
|
|
||||||
@@ -157,6 +158,7 @@ import org.bukkit.event.server.MapInitializeEvent;
|
|
||||||
import org.bukkit.event.weather.LightningStrikeEvent;
|
import org.bukkit.event.weather.LightningStrikeEvent;
|
||||||
import org.bukkit.event.world.TimeSkipEvent;
|
import org.bukkit.event.world.TimeSkipEvent;
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
@ -5894,7 +5886,7 @@ index 9812116e2f28d01423373990ecce0e5ab6229ce2..e66b4837498a8bfefabc4dd95e91ccfb
|
|||||||
|
|
||||||
public class ServerLevel extends Level implements WorldGenLevel {
|
public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
|
|
||||||
@@ -212,6 +214,96 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -215,6 +216,96 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
return convertable.dimensionType;
|
return convertable.dimensionType;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -6057,7 +6049,7 @@ index d679be6c3ce0d57fa2063a45baec1b108a0a2707..de5e18a331178da8f7e82aa2419a0ee6
|
|||||||
public BlockState getBlockState(BlockPos pos) {
|
public BlockState getBlockState(BlockPos pos) {
|
||||||
return this.getChunk(SectionPos.blockToSectionCoord(pos.getX()), SectionPos.blockToSectionCoord(pos.getZ())).getBlockState(pos);
|
return this.getChunk(SectionPos.blockToSectionCoord(pos.getX()), SectionPos.blockToSectionCoord(pos.getZ())).getBlockState(pos);
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 46cc3dc2d9f51dac1b84941d7549080e24c057bc..5996549250d666405ab113403faeb422b6e38c8c 100644
|
index baabc63258872c274ea790356a373f8baf326357..92acae1b00f06d47eb2d9326ba09d73c344a81b8 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -217,9 +217,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -217,9 +217,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
@ -6120,7 +6112,7 @@ index e772ed45ba7cf366c6da0dc8b1bd3497d561473a..e9e97cf0b202c84252fb3bada9789019
|
|||||||
@Override
|
@Override
|
||||||
public float getBukkitYaw() {
|
public float getBukkitYaw() {
|
||||||
diff --git a/src/main/java/net/minecraft/world/entity/Mob.java b/src/main/java/net/minecraft/world/entity/Mob.java
|
diff --git a/src/main/java/net/minecraft/world/entity/Mob.java b/src/main/java/net/minecraft/world/entity/Mob.java
|
||||||
index 0651d4d661aa52171f617f1dd844a89cb2d05e20..f286fcc2958a02c1e480b8fcf5d049bf0de27131 100644
|
index 1dbfdf060294e8f322e45625cf981087b9fcdac7..f6c93812c30bd1637219c22c1a903e2ec93a9d72 100644
|
||||||
--- a/src/main/java/net/minecraft/world/entity/Mob.java
|
--- a/src/main/java/net/minecraft/world/entity/Mob.java
|
||||||
+++ b/src/main/java/net/minecraft/world/entity/Mob.java
|
+++ b/src/main/java/net/minecraft/world/entity/Mob.java
|
||||||
@@ -238,6 +238,7 @@ public abstract class Mob extends LivingEntity {
|
@@ -238,6 +238,7 @@ public abstract class Mob extends LivingEntity {
|
||||||
@ -6157,10 +6149,10 @@ index 6c3044b6194dfd3037389d717bbe6783f58b951d..457880c9e894a83d88505cf0b7235df9
|
|||||||
super(type, world);
|
super(type, world);
|
||||||
this.xpReward = 5;
|
this.xpReward = 5;
|
||||||
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
index 962c942c05fc02befef6c306df51c0b438dd1dab..566f1b8a0acd679b2f776db2e80458b1c532f97e 100644
|
index 770520ace95a1fbc5bdaf5d9d62c09f0f7396602..8335880dbbb31a3f5d10c259b567baa0d5f381a1 100644
|
||||||
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
@@ -728,6 +728,25 @@ public final class ItemStack {
|
@@ -727,6 +727,25 @@ public final class ItemStack {
|
||||||
return this.tag != null ? this.tag.getList("Enchantments", 10) : new ListTag();
|
return this.tag != null ? this.tag.getList("Enchantments", 10) : new ListTag();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -6186,7 +6178,7 @@ index 962c942c05fc02befef6c306df51c0b438dd1dab..566f1b8a0acd679b2f776db2e80458b1
|
|||||||
public void setTag(@Nullable CompoundTag nbt) {
|
public void setTag(@Nullable CompoundTag nbt) {
|
||||||
this.tag = nbt;
|
this.tag = nbt;
|
||||||
if (this.getItem().canBeDepleted()) {
|
if (this.getItem().canBeDepleted()) {
|
||||||
@@ -1128,6 +1147,7 @@ public final class ItemStack {
|
@@ -1127,6 +1146,7 @@ public final class ItemStack {
|
||||||
// CraftBukkit start
|
// CraftBukkit start
|
||||||
@Deprecated
|
@Deprecated
|
||||||
public void setItem(Item item) {
|
public void setItem(Item item) {
|
||||||
@ -6965,7 +6957,7 @@ index 0000000000000000000000000000000000000000..909b2c98e7a9117d2f737245e4661792
|
|||||||
+ }
|
+ }
|
||||||
+}
|
+}
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
||||||
index 9d57eda5d5c16004776c2e23837425cfe9184476..b39819d579c548318f1539702fb2df97b052b63a 100644
|
index 1befbe94f6e47caf60fbfd7719e4008805cca198..bcd17766cb0a2be11669ded7d339de1c565ab112 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
||||||
@@ -88,8 +88,17 @@ public final class CraftMagicNumbers implements UnsafeValues {
|
@@ -88,8 +88,17 @@ public final class CraftMagicNumbers implements UnsafeValues {
|
||||||
|
@ -1041,7 +1041,7 @@ index 4dd57007af218ba1c0e666117a49939c5884f2c6..a6cb949b6f048455acc50c897fdd93d3
|
|||||||
}
|
}
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index e4d2771e86a0de4ea8bd08ca5811ce7a2e38c7d1..c8ba2eec9b1c07c9aba3d69d4f4501f1010de4e2 100644
|
index f3a2a5dcd18d8abe370779f75106eacab498c3b6..67113f1bb622acde89c05d1ee0af88644f67e776 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -1,8 +1,10 @@
|
@@ -1,8 +1,10 @@
|
||||||
@ -1055,7 +1055,7 @@ index e4d2771e86a0de4ea8bd08ca5811ce7a2e38c7d1..c8ba2eec9b1c07c9aba3d69d4f4501f1
|
|||||||
import com.google.common.collect.Lists;
|
import com.google.common.collect.Lists;
|
||||||
import com.google.common.collect.Queues;
|
import com.google.common.collect.Queues;
|
||||||
import com.google.common.collect.Sets;
|
import com.google.common.collect.Sets;
|
||||||
@@ -690,11 +692,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -652,11 +654,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
|
|
||||||
private CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>> scheduleChunkLoad(ChunkPos pos) {
|
private CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>> scheduleChunkLoad(ChunkPos pos) {
|
||||||
return CompletableFuture.supplyAsync(() -> {
|
return CompletableFuture.supplyAsync(() -> {
|
||||||
@ -1073,7 +1073,7 @@ index e4d2771e86a0de4ea8bd08ca5811ce7a2e38c7d1..c8ba2eec9b1c07c9aba3d69d4f4501f1
|
|||||||
boolean flag = nbttagcompound.contains("Status", 8);
|
boolean flag = nbttagcompound.contains("Status", 8);
|
||||||
|
|
||||||
if (flag) {
|
if (flag) {
|
||||||
@@ -705,7 +710,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -667,7 +672,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
}
|
}
|
||||||
|
|
||||||
ChunkMap.LOGGER.error("Chunk file at {} is missing level data, skipping", pos);
|
ChunkMap.LOGGER.error("Chunk file at {} is missing level data, skipping", pos);
|
||||||
@ -1082,7 +1082,7 @@ index e4d2771e86a0de4ea8bd08ca5811ce7a2e38c7d1..c8ba2eec9b1c07c9aba3d69d4f4501f1
|
|||||||
} catch (ReportedException reportedexception) {
|
} catch (ReportedException reportedexception) {
|
||||||
Throwable throwable = reportedexception.getCause();
|
Throwable throwable = reportedexception.getCause();
|
||||||
|
|
||||||
@@ -822,6 +827,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -784,6 +789,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
ChunkStatus chunkstatus = ChunkHolder.getStatus(chunkHolder.getTicketLevel());
|
ChunkStatus chunkstatus = ChunkHolder.getStatus(chunkHolder.getTicketLevel());
|
||||||
|
|
||||||
return !chunkstatus.isOrAfter(ChunkStatus.FULL) ? ChunkHolder.UNLOADED_CHUNK : either.mapLeft((ichunkaccess) -> {
|
return !chunkstatus.isOrAfter(ChunkStatus.FULL) ? ChunkHolder.UNLOADED_CHUNK : either.mapLeft((ichunkaccess) -> {
|
||||||
@ -1090,7 +1090,7 @@ index e4d2771e86a0de4ea8bd08ca5811ce7a2e38c7d1..c8ba2eec9b1c07c9aba3d69d4f4501f1
|
|||||||
ChunkPos chunkcoordintpair = chunkHolder.getPos();
|
ChunkPos chunkcoordintpair = chunkHolder.getPos();
|
||||||
ProtoChunk protochunk = (ProtoChunk) ichunkaccess;
|
ProtoChunk protochunk = (ProtoChunk) ichunkaccess;
|
||||||
LevelChunk chunk;
|
LevelChunk chunk;
|
||||||
@@ -846,6 +852,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -808,6 +814,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
}
|
}
|
||||||
|
|
||||||
return chunk;
|
return chunk;
|
||||||
@ -1098,7 +1098,7 @@ index e4d2771e86a0de4ea8bd08ca5811ce7a2e38c7d1..c8ba2eec9b1c07c9aba3d69d4f4501f1
|
|||||||
});
|
});
|
||||||
}, (runnable) -> {
|
}, (runnable) -> {
|
||||||
ProcessorHandle mailbox = this.mainThreadMailbox;
|
ProcessorHandle mailbox = this.mainThreadMailbox;
|
||||||
@@ -1382,6 +1389,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1342,6 +1349,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
List<ServerPlayer> list = Lists.newArrayList();
|
List<ServerPlayer> list = Lists.newArrayList();
|
||||||
List<ServerPlayer> list1 = this.level.players();
|
List<ServerPlayer> list1 = this.level.players();
|
||||||
ObjectIterator objectiterator = this.entityMap.values().iterator();
|
ObjectIterator objectiterator = this.entityMap.values().iterator();
|
||||||
@ -1106,7 +1106,7 @@ index e4d2771e86a0de4ea8bd08ca5811ce7a2e38c7d1..c8ba2eec9b1c07c9aba3d69d4f4501f1
|
|||||||
|
|
||||||
ChunkMap.TrackedEntity playerchunkmap_entitytracker;
|
ChunkMap.TrackedEntity playerchunkmap_entitytracker;
|
||||||
|
|
||||||
@@ -1406,14 +1414,17 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1366,14 +1374,17 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
playerchunkmap_entitytracker.serverEntity.sendChanges();
|
playerchunkmap_entitytracker.serverEntity.sendChanges();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1125,7 +1125,7 @@ index e4d2771e86a0de4ea8bd08ca5811ce7a2e38c7d1..c8ba2eec9b1c07c9aba3d69d4f4501f1
|
|||||||
|
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
index 566c32a71054479257b7fba981507fa2559aa9e6..109d6638d8fe035498bd717c180c9143ff00e0ad 100644
|
index be11caf7c0dcdb11e24cfb053cda45ac1867da63..8f5e9f1bdfd2e02512e1341f91b147b16e959e5b 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
@@ -528,13 +528,15 @@ public class ServerChunkCache extends ChunkSource {
|
@@ -528,13 +528,15 @@ public class ServerChunkCache extends ChunkSource {
|
||||||
@ -1217,7 +1217,7 @@ index 566c32a71054479257b7fba981507fa2559aa9e6..109d6638d8fe035498bd717c180c9143
|
|||||||
}
|
}
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index e66b4837498a8bfefabc4dd95e91ccfba67843e4..d78aeeff0d729284e60ffb72f7485b864447d98a 100644
|
index ce9ff034a281cd9cc76c26713b6d1eab3f6c9fe2..ae090f58bec25270e55f8da37355351783e69a7f 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -1,6 +1,8 @@
|
@@ -1,6 +1,8 @@
|
||||||
@ -1229,7 +1229,7 @@ index e66b4837498a8bfefabc4dd95e91ccfba67843e4..d78aeeff0d729284e60ffb72f7485b86
|
|||||||
import com.google.common.collect.Lists;
|
import com.google.common.collect.Lists;
|
||||||
import com.mojang.datafixers.DataFixer;
|
import com.mojang.datafixers.DataFixer;
|
||||||
import it.unimi.dsi.fastutil.ints.Int2ObjectMap;
|
import it.unimi.dsi.fastutil.ints.Int2ObjectMap;
|
||||||
@@ -150,7 +152,6 @@ import org.apache.logging.log4j.LogManager;
|
@@ -151,7 +153,6 @@ import org.apache.logging.log4j.LogManager;
|
||||||
import org.apache.logging.log4j.Logger;
|
import org.apache.logging.log4j.Logger;
|
||||||
import org.bukkit.Bukkit;
|
import org.bukkit.Bukkit;
|
||||||
import org.bukkit.WeatherType;
|
import org.bukkit.WeatherType;
|
||||||
@ -1237,7 +1237,7 @@ index e66b4837498a8bfefabc4dd95e91ccfba67843e4..d78aeeff0d729284e60ffb72f7485b86
|
|||||||
import org.bukkit.craftbukkit.event.CraftEventFactory;
|
import org.bukkit.craftbukkit.event.CraftEventFactory;
|
||||||
import org.bukkit.craftbukkit.util.WorldUUID;
|
import org.bukkit.craftbukkit.util.WorldUUID;
|
||||||
import org.bukkit.event.entity.CreatureSpawnEvent;
|
import org.bukkit.event.entity.CreatureSpawnEvent;
|
||||||
@@ -422,7 +423,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -424,7 +425,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
this.updateSkyBrightness();
|
this.updateSkyBrightness();
|
||||||
this.tickTime();
|
this.tickTime();
|
||||||
gameprofilerfiller.popPush("tickPending");
|
gameprofilerfiller.popPush("tickPending");
|
||||||
@ -1246,7 +1246,7 @@ index e66b4837498a8bfefabc4dd95e91ccfba67843e4..d78aeeff0d729284e60ffb72f7485b86
|
|||||||
if (!this.isDebug()) {
|
if (!this.isDebug()) {
|
||||||
j = this.getGameTime();
|
j = this.getGameTime();
|
||||||
gameprofilerfiller.push("blockTicks");
|
gameprofilerfiller.push("blockTicks");
|
||||||
@@ -431,12 +432,16 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -433,12 +434,16 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
this.fluidTicks.tick(j, 65536, this::tickFluid);
|
this.fluidTicks.tick(j, 65536, this::tickFluid);
|
||||||
gameprofilerfiller.pop();
|
gameprofilerfiller.pop();
|
||||||
}
|
}
|
||||||
@ -1264,7 +1264,7 @@ index e66b4837498a8bfefabc4dd95e91ccfba67843e4..d78aeeff0d729284e60ffb72f7485b86
|
|||||||
gameprofilerfiller.popPush("blockEvents");
|
gameprofilerfiller.popPush("blockEvents");
|
||||||
timings.doSounds.startTiming(); // Spigot
|
timings.doSounds.startTiming(); // Spigot
|
||||||
this.runBlockEvents();
|
this.runBlockEvents();
|
||||||
@@ -601,6 +606,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -603,6 +608,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
}
|
}
|
||||||
|
|
||||||
gameprofilerfiller.popPush("tickBlocks");
|
gameprofilerfiller.popPush("tickBlocks");
|
||||||
@ -1272,7 +1272,7 @@ index e66b4837498a8bfefabc4dd95e91ccfba67843e4..d78aeeff0d729284e60ffb72f7485b86
|
|||||||
if (randomTickSpeed > 0) {
|
if (randomTickSpeed > 0) {
|
||||||
LevelChunkSection[] achunksection = chunk.getSections();
|
LevelChunkSection[] achunksection = chunk.getSections();
|
||||||
int l = achunksection.length;
|
int l = achunksection.length;
|
||||||
@@ -633,6 +639,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -635,6 +641,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1280,7 +1280,7 @@ index e66b4837498a8bfefabc4dd95e91ccfba67843e4..d78aeeff0d729284e60ffb72f7485b86
|
|||||||
gameprofilerfiller.pop();
|
gameprofilerfiller.pop();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -867,14 +874,22 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -869,14 +876,22 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void tickNonPassenger(Entity entity) {
|
public void tickNonPassenger(Entity entity) {
|
||||||
@ -1304,7 +1304,7 @@ index e66b4837498a8bfefabc4dd95e91ccfba67843e4..d78aeeff0d729284e60ffb72f7485b86
|
|||||||
entity.setOldPosAndRot();
|
entity.setOldPosAndRot();
|
||||||
ProfilerFiller gameprofilerfiller = this.getProfiler();
|
ProfilerFiller gameprofilerfiller = this.getProfiler();
|
||||||
|
|
||||||
@@ -893,7 +908,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -895,7 +910,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
|
|
||||||
this.tickPassenger(entity, entity1);
|
this.tickPassenger(entity, entity1);
|
||||||
}
|
}
|
||||||
@ -1313,7 +1313,7 @@ index e66b4837498a8bfefabc4dd95e91ccfba67843e4..d78aeeff0d729284e60ffb72f7485b86
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -935,6 +950,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -937,6 +952,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
|
|
||||||
if (!savingDisabled) {
|
if (!savingDisabled) {
|
||||||
org.bukkit.Bukkit.getPluginManager().callEvent(new org.bukkit.event.world.WorldSaveEvent(getWorld())); // CraftBukkit
|
org.bukkit.Bukkit.getPluginManager().callEvent(new org.bukkit.event.world.WorldSaveEvent(getWorld())); // CraftBukkit
|
||||||
@ -1321,7 +1321,7 @@ index e66b4837498a8bfefabc4dd95e91ccfba67843e4..d78aeeff0d729284e60ffb72f7485b86
|
|||||||
if (progressListener != null) {
|
if (progressListener != null) {
|
||||||
progressListener.progressStartNoAbort(new TranslatableComponent("menu.savingLevel"));
|
progressListener.progressStartNoAbort(new TranslatableComponent("menu.savingLevel"));
|
||||||
}
|
}
|
||||||
@@ -944,7 +960,10 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -946,7 +962,10 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
progressListener.progressStage(new TranslatableComponent("menu.savingChunks"));
|
progressListener.progressStage(new TranslatableComponent("menu.savingChunks"));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1333,7 +1333,7 @@ index e66b4837498a8bfefabc4dd95e91ccfba67843e4..d78aeeff0d729284e60ffb72f7485b86
|
|||||||
this.entityManager.saveAll();
|
this.entityManager.saveAll();
|
||||||
} else {
|
} else {
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 5996549250d666405ab113403faeb422b6e38c8c..d2d7d4f506b2eacc5672c5eace1c9b9cdf6c8167 100644
|
index 92acae1b00f06d47eb2d9326ba09d73c344a81b8..01abf5d48f63d7456a0ca5043289f6a0de9d4a9d 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -207,6 +207,7 @@ import org.bukkit.inventory.EquipmentSlot;
|
@@ -207,6 +207,7 @@ import org.bukkit.inventory.EquipmentSlot;
|
||||||
@ -1344,7 +1344,7 @@ index 5996549250d666405ab113403faeb422b6e38c8c..d2d7d4f506b2eacc5672c5eace1c9b9c
|
|||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
|
|
||||||
public class ServerGamePacketListenerImpl implements ServerPlayerConnection, ServerGamePacketListener {
|
public class ServerGamePacketListenerImpl implements ServerPlayerConnection, ServerGamePacketListener {
|
||||||
@@ -286,7 +287,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -287,7 +288,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
|
|
||||||
public void tick() {
|
public void tick() {
|
||||||
@ -1352,7 +1352,7 @@ index 5996549250d666405ab113403faeb422b6e38c8c..d2d7d4f506b2eacc5672c5eace1c9b9c
|
|||||||
this.resetPosition();
|
this.resetPosition();
|
||||||
this.player.xo = this.player.getX();
|
this.player.xo = this.player.getX();
|
||||||
this.player.yo = this.player.getY();
|
this.player.yo = this.player.getY();
|
||||||
@@ -362,7 +362,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -363,7 +363,6 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
this.player.resetLastActionTime(); // CraftBukkit - SPIGOT-854
|
this.player.resetLastActionTime(); // CraftBukkit - SPIGOT-854
|
||||||
this.disconnect(new TranslatableComponent("multiplayer.disconnect.idling"));
|
this.disconnect(new TranslatableComponent("multiplayer.disconnect.idling"));
|
||||||
}
|
}
|
||||||
@ -1360,7 +1360,7 @@ index 5996549250d666405ab113403faeb422b6e38c8c..d2d7d4f506b2eacc5672c5eace1c9b9c
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1915,7 +1914,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1916,7 +1915,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
|
|
||||||
private void handleCommand(String input) {
|
private void handleCommand(String input) {
|
||||||
@ -1369,7 +1369,7 @@ index 5996549250d666405ab113403faeb422b6e38c8c..d2d7d4f506b2eacc5672c5eace1c9b9c
|
|||||||
// CraftBukkit start - whole method
|
// CraftBukkit start - whole method
|
||||||
if ( org.spigotmc.SpigotConfig.logCommands ) // Spigot
|
if ( org.spigotmc.SpigotConfig.logCommands ) // Spigot
|
||||||
this.LOGGER.info(this.player.getScoreboardName() + " issued server command: " + input);
|
this.LOGGER.info(this.player.getScoreboardName() + " issued server command: " + input);
|
||||||
@@ -1926,7 +1925,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1927,7 +1926,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
this.cserver.getPluginManager().callEvent(event);
|
this.cserver.getPluginManager().callEvent(event);
|
||||||
|
|
||||||
if (event.isCancelled()) {
|
if (event.isCancelled()) {
|
||||||
@ -1378,7 +1378,7 @@ index 5996549250d666405ab113403faeb422b6e38c8c..d2d7d4f506b2eacc5672c5eace1c9b9c
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1939,7 +1938,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1940,7 +1939,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
java.util.logging.Logger.getLogger(ServerGamePacketListenerImpl.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
|
java.util.logging.Logger.getLogger(ServerGamePacketListenerImpl.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
|
||||||
return;
|
return;
|
||||||
} finally {
|
} finally {
|
||||||
@ -1582,7 +1582,7 @@ index e9e97cf0b202c84252fb3bada97890198fcc6bb9..2a65e7ae49f2fc1d56cdace60f72b729
|
|||||||
if (!this.level.isClientSide && this.isSensitiveToWater() && this.isInWaterRainOrBubble()) {
|
if (!this.level.isClientSide && this.isSensitiveToWater() && this.isInWaterRainOrBubble()) {
|
||||||
this.hurt(DamageSource.DROWN, 1.0F);
|
this.hurt(DamageSource.DROWN, 1.0F);
|
||||||
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
||||||
index 9e6a02a05ea20c21aed26ed4bc92488627febd4c..f4561232aa390d1c40216f2d5599ecf8720e60c2 100644
|
index 84b462d5f3c9727f8da6d254e67a7a752c4508d3..a75171ecfd23df3f626ca651febb75da28079c2d 100644
|
||||||
--- a/src/main/java/net/minecraft/world/level/Level.java
|
--- a/src/main/java/net/minecraft/world/level/Level.java
|
||||||
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
||||||
@@ -83,7 +83,6 @@ import org.bukkit.Bukkit;
|
@@ -83,7 +83,6 @@ import org.bukkit.Bukkit;
|
||||||
@ -1667,7 +1667,7 @@ index d33c2d2ec285179614d21a255cea394682e4cc2c..65aedffad9bef4ab80eb835e9c05b6d4
|
|||||||
private static final CraftPersistentDataTypeRegistry DATA_TYPE_REGISTRY = new CraftPersistentDataTypeRegistry();
|
private static final CraftPersistentDataTypeRegistry DATA_TYPE_REGISTRY = new CraftPersistentDataTypeRegistry();
|
||||||
public CraftPersistentDataContainer persistentDataContainer;
|
public CraftPersistentDataContainer persistentDataContainer;
|
||||||
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
index 3f09451a04404231f1eaac0954c0ecf01b7507ea..127727c3b4b21c42c64b8616c9fccf7783a89a9c 100644
|
index f263022e1d15e78b51cfd148cf024b9a8c761898..52eda58a085d0a7b6329dd4791e05edf2f644df3 100644
|
||||||
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
@@ -661,6 +661,7 @@ public class LevelChunk extends ChunkAccess {
|
@@ -661,6 +661,7 @@ public class LevelChunk extends ChunkAccess {
|
||||||
@ -2114,7 +2114,7 @@ index e52ef47b783785dc214746b678e7b549aea9a274..3d90b3426873a3528af14f7f1ab0adae
|
|||||||
this.value = value;
|
this.value = value;
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
||||||
index b39819d579c548318f1539702fb2df97b052b63a..a73185be22c73ffd746fe2abcfbf07796328960c 100644
|
index bcd17766cb0a2be11669ded7d339de1c565ab112..afdf4bc63dfaa469a16701541332e5380a027c22 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
||||||
@@ -173,6 +173,12 @@ public final class CraftMagicNumbers implements UnsafeValues {
|
@@ -173,6 +173,12 @@ public final class CraftMagicNumbers implements UnsafeValues {
|
||||||
|
@ -66,10 +66,10 @@ index 59e619f745f62dec5a5fe304bbea75690a0b1663..23cba4bd17742733659aef498aa39d12
|
|||||||
if (type == PluginLoadOrder.STARTUP) {
|
if (type == PluginLoadOrder.STARTUP) {
|
||||||
this.helpMap.clear();
|
this.helpMap.clear();
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
index 45b0da909136989d60c47bbff2ad9962f5c7f170..c5a9e3be2ad799752649b0d4ffeef8a3644f6d7b 100644
|
index 2bd2f436d5514b5e9bbc8bbd27ead4d4cb529b4f..dd115bd005604614e64a236ccf86a24882beb096 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
@@ -138,6 +138,12 @@ public class Main {
|
@@ -136,6 +136,12 @@ public class Main {
|
||||||
.ofType(File.class)
|
.ofType(File.class)
|
||||||
.defaultsTo(new File("paper.yml"))
|
.defaultsTo(new File("paper.yml"))
|
||||||
.describedAs("Yml file");
|
.describedAs("Yml file");
|
||||||
|
@ -1312,7 +1312,7 @@ index 925ffbddd5475be7fe00570d861b615f707434b4..a3436596d05547a60c9906c92f709bb5
|
|||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
this.chatVisibility = packet.chatVisibility();
|
this.chatVisibility = packet.chatVisibility();
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index d2d7d4f506b2eacc5672c5eace1c9b9cdf6c8167..b38431701e9dd36e8e6eddac434b3cb88e0f23c8 100644
|
index 01abf5d48f63d7456a0ca5043289f6a0de9d4a9d..8dfc214b57f77c86f3e3f52ef8b6058295bf7be9 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -160,6 +160,8 @@ import org.apache.logging.log4j.LogManager;
|
@@ -160,6 +160,8 @@ import org.apache.logging.log4j.LogManager;
|
||||||
@ -1324,7 +1324,7 @@ index d2d7d4f506b2eacc5672c5eace1c9b9cdf6c8167..b38431701e9dd36e8e6eddac434b3cb8
|
|||||||
import java.util.concurrent.ExecutionException;
|
import java.util.concurrent.ExecutionException;
|
||||||
import java.util.concurrent.atomic.AtomicInteger;
|
import java.util.concurrent.atomic.AtomicInteger;
|
||||||
import net.minecraft.world.inventory.AbstractContainerMenu;
|
import net.minecraft.world.inventory.AbstractContainerMenu;
|
||||||
@@ -383,21 +385,24 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -384,21 +386,24 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
return this.server.isSingleplayerOwner(this.player.getGameProfile());
|
return this.server.isSingleplayerOwner(this.player.getGameProfile());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1357,7 +1357,7 @@ index d2d7d4f506b2eacc5672c5eace1c9b9cdf6c8167..b38431701e9dd36e8e6eddac434b3cb8
|
|||||||
|
|
||||||
if (this.cserver.getServer().isRunning()) {
|
if (this.cserver.getServer().isRunning()) {
|
||||||
this.cserver.getPluginManager().callEvent(event);
|
this.cserver.getPluginManager().callEvent(event);
|
||||||
@@ -408,8 +413,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -409,8 +414,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// Send the possibly modified leave message
|
// Send the possibly modified leave message
|
||||||
@ -1367,7 +1367,7 @@ index d2d7d4f506b2eacc5672c5eace1c9b9cdf6c8167..b38431701e9dd36e8e6eddac434b3cb8
|
|||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
|
|
||||||
this.connection.send(new ClientboundDisconnectPacket(ichatbasecomponent), (future) -> {
|
this.connection.send(new ClientboundDisconnectPacket(ichatbasecomponent), (future) -> {
|
||||||
@@ -1665,9 +1669,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1666,9 +1670,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
*/
|
*/
|
||||||
|
|
||||||
this.player.disconnect();
|
this.player.disconnect();
|
||||||
@ -1382,7 +1382,7 @@ index d2d7d4f506b2eacc5672c5eace1c9b9cdf6c8167..b38431701e9dd36e8e6eddac434b3cb8
|
|||||||
}
|
}
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
this.player.getTextFilter().leave();
|
this.player.getTextFilter().leave();
|
||||||
@@ -1849,7 +1855,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1850,7 +1856,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
this.handleCommand(s);
|
this.handleCommand(s);
|
||||||
} else if (this.player.getChatVisibility() == ChatVisiblity.SYSTEM) {
|
} else if (this.player.getChatVisibility() == ChatVisiblity.SYSTEM) {
|
||||||
// Do nothing, this is coming from a plugin
|
// Do nothing, this is coming from a plugin
|
||||||
@ -1396,7 +1396,7 @@ index d2d7d4f506b2eacc5672c5eace1c9b9cdf6c8167..b38431701e9dd36e8e6eddac434b3cb8
|
|||||||
Player player = this.getCraftPlayer();
|
Player player = this.getCraftPlayer();
|
||||||
AsyncPlayerChatEvent event = new AsyncPlayerChatEvent(async, player, s, new LazyPlayerSet(this.server));
|
AsyncPlayerChatEvent event = new AsyncPlayerChatEvent(async, player, s, new LazyPlayerSet(this.server));
|
||||||
this.cserver.getPluginManager().callEvent(event);
|
this.cserver.getPluginManager().callEvent(event);
|
||||||
@@ -2639,30 +2650,30 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2640,30 +2651,30 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1891,13 +1891,13 @@ index b66b88475178f5a20a689f1af9a06f7f8e50ff9b..8df699de4ddde3089324f347a82d913f
|
|||||||
+ // Paper end
|
+ // Paper end
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
index c5a9e3be2ad799752649b0d4ffeef8a3644f6d7b..3a7a3709eb5e68663e7f6734d39179c3f69e17c6 100644
|
index dd115bd005604614e64a236ccf86a24882beb096..0c26dc0b060700323aca0a062b34d35e16a3ec9f 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
@@ -21,6 +21,12 @@ public class Main {
|
@@ -19,6 +19,12 @@ public class Main {
|
||||||
public static void main(String[] args) {
|
public static boolean useConsole = true;
|
||||||
System.setProperty("log4j2.formatMsgNoLookups", "true");
|
|
||||||
|
|
||||||
|
public static void main(String[] args) {
|
||||||
+ // Paper start
|
+ // Paper start
|
||||||
+ final String warnWhenLegacyFormattingDetected = String.join(".", "net", "kyori", "adventure", "text", "warnWhenLegacyFormattingDetected");
|
+ final String warnWhenLegacyFormattingDetected = String.join(".", "net", "kyori", "adventure", "text", "warnWhenLegacyFormattingDetected");
|
||||||
+ if (false && System.getProperty(warnWhenLegacyFormattingDetected) == null) {
|
+ if (false && System.getProperty(warnWhenLegacyFormattingDetected) == null) {
|
||||||
@ -3505,7 +3505,7 @@ index f9b7b8f7ccc95b73967a51420fd6ce88d80d75fe..0de5a46423ae0403dcbfca630dfd7c5a
|
|||||||
|
|
||||||
boolean hadFormat = false;
|
boolean hadFormat = false;
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
||||||
index a73185be22c73ffd746fe2abcfbf07796328960c..ec507e6ce6784441561d142dbdd145be80c66fcd 100644
|
index afdf4bc63dfaa469a16701541332e5380a027c22..4a25660971042322b1f9322b906e2775e81a6f01 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
--- a/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/util/CraftMagicNumbers.java
|
||||||
@@ -57,6 +57,33 @@ public final class CraftMagicNumbers implements UnsafeValues {
|
@@ -57,6 +57,33 @@ public final class CraftMagicNumbers implements UnsafeValues {
|
||||||
|
@ -45,10 +45,10 @@ index cf79b158c7fbbb3ccddd4472eceb27d6f238f489..cfdc78fe0820d47d8af055e844b08ea0
|
|||||||
private final String bukkitVersion = Versioning.getBukkitVersion();
|
private final String bukkitVersion = Versioning.getBukkitVersion();
|
||||||
private final Logger logger = Logger.getLogger("Minecraft");
|
private final Logger logger = Logger.getLogger("Minecraft");
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
index 3a7a3709eb5e68663e7f6734d39179c3f69e17c6..6300161cafb6efed7a262fa6b0b17d2f471fb2bb 100644
|
index 0c26dc0b060700323aca0a062b34d35e16a3ec9f..e6362865d1e7beac23e520ebd2deb8a356428045 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
@@ -218,12 +218,25 @@ public class Main {
|
@@ -216,12 +216,25 @@ public class Main {
|
||||||
deadline.add(Calendar.DAY_OF_YEAR, -14);
|
deadline.add(Calendar.DAY_OF_YEAR, -14);
|
||||||
if (buildDate.before(deadline.getTime())) {
|
if (buildDate.before(deadline.getTime())) {
|
||||||
System.err.println("*** Error, this build is outdated ***");
|
System.err.println("*** Error, this build is outdated ***");
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Entity Origin API
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 9584f09f44445d91ee259f2a50b1fecf718e18dc..f158ddd486fbd6081fef1592e916986462d01991 100644
|
index ae090f58bec25270e55f8da37355351783e69a7f..50513abfb5009c22cfd6d8fcf20243f66bf2f53e 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -1983,6 +1983,15 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -2016,6 +2016,15 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
}
|
}
|
||||||
|
|
||||||
entity.valid = true; // CraftBukkit
|
entity.valid = true; // CraftBukkit
|
||||||
|
@ -19,10 +19,10 @@ index 5cae4a5caf9aba8c0e99f1cb6badc5e8374862c8..1a9b4b08ea906adbfa25c3963a463487
|
|||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 057285ca421dc7e9a0c6449238409eaf42235ef5..0fd9ad873ed681dab1b297bf5cdf700e43be2200 100644
|
index 50513abfb5009c22cfd6d8fcf20243f66bf2f53e..afa067e314892fcb7a2b04c4f54c964f62ee2df5 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -556,7 +556,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -558,7 +558,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
gameprofilerfiller.push("thunder");
|
gameprofilerfiller.push("thunder");
|
||||||
BlockPos blockposition;
|
BlockPos blockposition;
|
||||||
|
|
||||||
|
@ -19,10 +19,10 @@ index 1a9b4b08ea906adbfa25c3963a4634871d7ca2f6..ceb1602afb90fc0a23d6cc8d22fc85fa
|
|||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 0fd9ad873ed681dab1b297bf5cdf700e43be2200..032e1e08413f2d0f601cdc32fe12145e2c1fec5f 100644
|
index afa067e314892fcb7a2b04c4f54c964f62ee2df5..c8ba29065b2e195bdb2570806763e299108725af 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -580,7 +580,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -582,7 +582,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
}
|
}
|
||||||
|
|
||||||
gameprofilerfiller.popPush("iceandsnow");
|
gameprofilerfiller.popPush("iceandsnow");
|
||||||
|
@ -14,10 +14,10 @@ big slowdown in execution but throwing an exception at same time to raise awaren
|
|||||||
that it is happening so that plugin authors can fix their code to stop executing commands async.
|
that it is happening so that plugin authors can fix their code to stop executing commands async.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index b38431701e9dd36e8e6eddac434b3cb88e0f23c8..63ba639701b703392ce2be973e2a53ba76e4fd46 100644
|
index 8dfc214b57f77c86f3e3f52ef8b6058295bf7be9..25117f4b7f6139688c1845a1dc257f7d5c268fde 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -1852,6 +1852,29 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1853,6 +1853,29 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!async && s.startsWith("/")) {
|
if (!async && s.startsWith("/")) {
|
||||||
|
@ -49,10 +49,10 @@ index 0000000000000000000000000000000000000000..f699ce18ca044f813e194ef2786b7ea8
|
|||||||
+ }
|
+ }
|
||||||
+}
|
+}
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index c8ba2eec9b1c07c9aba3d69d4f4501f1010de4e2..13038723347cdbada65611d9de542d35d94084a0 100644
|
index 67113f1bb622acde89c05d1ee0af88644f67e776..c72d19a903a5cbb48d38f493e00e8c54a8e23b9c 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -957,6 +957,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -919,6 +919,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
return true;
|
return true;
|
||||||
} catch (Exception exception) {
|
} catch (Exception exception) {
|
||||||
ChunkMap.LOGGER.error("Failed to save chunk {},{}", chunkcoordintpair.x, chunkcoordintpair.z, exception);
|
ChunkMap.LOGGER.error("Failed to save chunk {},{}", chunkcoordintpair.x, chunkcoordintpair.z, exception);
|
||||||
@ -108,7 +108,7 @@ index 4cde8d630a0951f297622af4ef781f5b3fabf9af..7044d8c71e85551e11bf2d96b767e088
|
|||||||
}
|
}
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
||||||
index 50a2fdc1f51fe6ca5a62d17e36ed88ecf7d20473..c68ababd68a8c49be6dbef275b94f3f90320e10a 100644
|
index ad4b29c96113d15b284aed78e5768588802e468c..731e1cefd2a9c829bfe82ec87038d9333ef21fb3 100644
|
||||||
--- a/src/main/java/net/minecraft/world/level/Level.java
|
--- a/src/main/java/net/minecraft/world/level/Level.java
|
||||||
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
||||||
@@ -1,5 +1,10 @@
|
@@ -1,5 +1,10 @@
|
||||||
@ -151,7 +151,7 @@ index 81b61b6cc1e99328d4d339ca32895d1268c88ca7..28a7c53d98450cc79bee953411a18f50
|
|||||||
}
|
}
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
index 9638e28077b5720745f6125805fbda702a804f74..d207e54019360f7f94bfa5301462fe3c8ac6758e 100644
|
index 949d8cc16c91390ea573dd566bec566dc95efc18..3ba9f8d7dc12709670dcd94df5d82b8d44f983fa 100644
|
||||||
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
@@ -1,6 +1,7 @@
|
@@ -1,6 +1,7 @@
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Complete resource pack API
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 63ba639701b703392ce2be973e2a53ba76e4fd46..59bf84ff2aac4f39c1027db9c32e3cf4accedcb1 100644
|
index 25117f4b7f6139688c1845a1dc257f7d5c268fde..103d0afd73de68e3b07a9a4ef6d2f5af0a0e40c5 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -1634,8 +1634,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1635,8 +1635,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
ServerGamePacketListenerImpl.LOGGER.info("Disconnecting {} due to resource pack rejection", this.player.getName());
|
ServerGamePacketListenerImpl.LOGGER.info("Disconnecting {} due to resource pack rejection", this.player.getName());
|
||||||
this.disconnect(new TranslatableComponent("multiplayer.requiredTexturePrompt.disconnect"));
|
this.disconnect(new TranslatableComponent("multiplayer.requiredTexturePrompt.disconnect"));
|
||||||
}
|
}
|
||||||
|
@ -18,10 +18,10 @@ For consistency, the old API methods now forward to use the
|
|||||||
ItemMeta API equivalents, and should deprecate the old API's.
|
ItemMeta API equivalents, and should deprecate the old API's.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
index 566f1b8a0acd679b2f776db2e80458b1c532f97e..d342ae7b4fc1f682a885f0dca7b7fc222905490d 100644
|
index 8335880dbbb31a3f5d10c259b567baa0d5f381a1..74e4990888d88f18cb3d800724d9156e9d1ae21d 100644
|
||||||
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
@@ -13,6 +13,8 @@ import java.text.DecimalFormatSymbols;
|
@@ -12,6 +12,8 @@ import java.text.DecimalFormatSymbols;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@ -30,7 +30,7 @@ index 566f1b8a0acd679b2f776db2e80458b1c532f97e..d342ae7b4fc1f682a885f0dca7b7fc22
|
|||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
import java.util.Map.Entry;
|
import java.util.Map.Entry;
|
||||||
import java.util.Optional;
|
import java.util.Optional;
|
||||||
@@ -152,6 +154,23 @@ public final class ItemStack {
|
@@ -151,6 +153,23 @@ public final class ItemStack {
|
||||||
return this.getItem().getTooltipImage(this);
|
return this.getItem().getTooltipImage(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -54,7 +54,7 @@ index 566f1b8a0acd679b2f776db2e80458b1c532f97e..d342ae7b4fc1f682a885f0dca7b7fc22
|
|||||||
public ItemStack(ItemLike item) {
|
public ItemStack(ItemLike item) {
|
||||||
this(item, 1);
|
this(item, 1);
|
||||||
}
|
}
|
||||||
@@ -195,6 +214,7 @@ public final class ItemStack {
|
@@ -194,6 +213,7 @@ public final class ItemStack {
|
||||||
// CraftBukkit start - make defensive copy as this data may be coming from the save thread
|
// CraftBukkit start - make defensive copy as this data may be coming from the save thread
|
||||||
this.tag = nbttagcompound.getCompound("tag").copy();
|
this.tag = nbttagcompound.getCompound("tag").copy();
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
@ -62,7 +62,7 @@ index 566f1b8a0acd679b2f776db2e80458b1c532f97e..d342ae7b4fc1f682a885f0dca7b7fc22
|
|||||||
this.getItem().verifyTagAfterLoad(this.tag);
|
this.getItem().verifyTagAfterLoad(this.tag);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -749,6 +769,7 @@ public final class ItemStack {
|
@@ -748,6 +768,7 @@ public final class ItemStack {
|
||||||
|
|
||||||
public void setTag(@Nullable CompoundTag nbt) {
|
public void setTag(@Nullable CompoundTag nbt) {
|
||||||
this.tag = nbt;
|
this.tag = nbt;
|
||||||
@ -70,7 +70,7 @@ index 566f1b8a0acd679b2f776db2e80458b1c532f97e..d342ae7b4fc1f682a885f0dca7b7fc22
|
|||||||
if (this.getItem().canBeDepleted()) {
|
if (this.getItem().canBeDepleted()) {
|
||||||
this.setDamageValue(this.getDamageValue());
|
this.setDamageValue(this.getDamageValue());
|
||||||
}
|
}
|
||||||
@@ -1056,6 +1077,7 @@ public final class ItemStack {
|
@@ -1055,6 +1076,7 @@ public final class ItemStack {
|
||||||
ListTag nbttaglist = this.tag.getList("Enchantments", 10);
|
ListTag nbttaglist = this.tag.getList("Enchantments", 10);
|
||||||
|
|
||||||
nbttaglist.add(EnchantmentHelper.storeEnchantment(EnchantmentHelper.getEnchantmentId(enchantment), (byte) level));
|
nbttaglist.add(EnchantmentHelper.storeEnchantment(EnchantmentHelper.getEnchantmentId(enchantment), (byte) level));
|
||||||
|
@ -6,10 +6,10 @@ Subject: [PATCH] Add World Util Methods
|
|||||||
Methods that can be used for other patches to help improve logic.
|
Methods that can be used for other patches to help improve logic.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 7bc41c8546bc665b085cad6c384d0a5fab9f0b8b..51046d9fb37eabdbf76dee23cea81b6ee3406140 100644
|
index c8ba29065b2e195bdb2570806763e299108725af..b106dfc16820d89b9c9792ad85d09fd66b7204b6 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -206,7 +206,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -208,7 +208,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
public final LevelStorageSource.LevelStorageAccess convertable;
|
public final LevelStorageSource.LevelStorageAccess convertable;
|
||||||
public final UUID uuid;
|
public final UUID uuid;
|
||||||
|
|
||||||
|
@ -22,10 +22,10 @@ index 71c672eafdce3547eaeb8e31fddcb142ad213094..aa8cd5965632626e4cbd4952acf9b349
|
|||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 19c97a14cbf23130db2de80e3f7f6e0c4ff27662..9f7bbd602c19f317d05cd8b72453c2e37d8acff5 100644
|
index b106dfc16820d89b9c9792ad85d09fd66b7204b6..4e896cdc395cfb2b976e13ee3f0228d9f475069f 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -560,7 +560,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -562,7 +562,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
blockposition = this.findLightningTargetAround(this.getBlockRandomPos(j, 0, k, 15));
|
blockposition = this.findLightningTargetAround(this.getBlockRandomPos(j, 0, k, 15));
|
||||||
if (this.isRainingAt(blockposition)) {
|
if (this.isRainingAt(blockposition)) {
|
||||||
DifficultyInstance difficultydamagescaler = this.getCurrentDifficultyAt(blockposition);
|
DifficultyInstance difficultydamagescaler = this.getCurrentDifficultyAt(blockposition);
|
||||||
|
@ -18,10 +18,10 @@ index 9d6daeba112e68c64c2b5d7d0c7717766913fd56..b8938c4118b61758874624229b698695
|
|||||||
this.profiler.push(() -> {
|
this.profiler.push(() -> {
|
||||||
return worldserver + " " + worldserver.dimension().location();
|
return worldserver + " " + worldserver.dimension().location();
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 180e04c6e5d52ed5e0f5da06c1de1b925511e51c..2f406dc2264bcaa584c56780e3f015f476102845 100644
|
index 4e896cdc395cfb2b976e13ee3f0228d9f475069f..419f539109ca0b8103475e52d0fdda40a7b99cc7 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -205,6 +205,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -207,6 +207,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
private int tickPosition;
|
private int tickPosition;
|
||||||
public final LevelStorageSource.LevelStorageAccess convertable;
|
public final LevelStorageSource.LevelStorageAccess convertable;
|
||||||
public final UUID uuid;
|
public final UUID uuid;
|
||||||
@ -30,7 +30,7 @@ index 180e04c6e5d52ed5e0f5da06c1de1b925511e51c..2f406dc2264bcaa584c56780e3f015f4
|
|||||||
@Override public LevelChunk getChunkIfLoaded(int x, int z) { // Paper - this was added in world too but keeping here for NMS ABI
|
@Override public LevelChunk getChunkIfLoaded(int x, int z) { // Paper - this was added in world too but keeping here for NMS ABI
|
||||||
return this.chunkSource.getChunk(x, z, false);
|
return this.chunkSource.getChunk(x, z, false);
|
||||||
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
||||||
index 7ee958e6a4f16780aa746ce0eb8cb8ee27df08e1..609dd263ca6ee3287492a39a74d49ec01339956c 100644
|
index 987962d1142c0ec0e28a9f2c7a62c8440bb10bd7..a0529181ab587c6675a6b6252efa12354c29316e 100644
|
||||||
--- a/src/main/java/net/minecraft/world/level/Level.java
|
--- a/src/main/java/net/minecraft/world/level/Level.java
|
||||||
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
||||||
@@ -475,7 +475,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
@@ -475,7 +475,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Entity AddTo/RemoveFrom World Events
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 4611c44a460f87df864dd88f9ae961f9c0bc0d29..6869a07e4a3cfc19b5e814c7e3162d5315ec8908 100644
|
index 419f539109ca0b8103475e52d0fdda40a7b99cc7..ce13b2b9bcf0984732b3309ec3f14731cc6aef5f 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -1993,6 +1993,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -2026,6 +2026,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
entity.setOrigin(entity.getOriginVector().toLocation(getWorld()));
|
entity.setOrigin(entity.getOriginVector().toLocation(getWorld()));
|
||||||
}
|
}
|
||||||
// Paper end
|
// Paper end
|
||||||
@ -16,7 +16,7 @@ index 4611c44a460f87df864dd88f9ae961f9c0bc0d29..6869a07e4a3cfc19b5e814c7e3162d53
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void onTrackingEnd(Entity entity) {
|
public void onTrackingEnd(Entity entity) {
|
||||||
@@ -2064,6 +2065,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -2106,6 +2107,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
|
@ -32,7 +32,7 @@ index a9fd90d5282bd013e031b9d7481e3f777d6892c6..a6f8ca71ba5d107cfbd24b8e8a225195
|
|||||||
|
|
||||||
private int getSurfaceY() {
|
private int getSurfaceY() {
|
||||||
diff --git a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
diff --git a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
||||||
index 80c172b57857a19d5f78c6f06335dc7c957ccbb6..e10d377eb7540ed54ddcb6632afc2395c021b8ab 100644
|
index 6b47e7abe63c196ab17c5816fdb4f79a89225178..4335bd9d6413d56326be573f7c07c8cd0503d352 100644
|
||||||
--- a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
--- a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
||||||
+++ b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
+++ b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
||||||
@@ -10,6 +10,7 @@ import net.minecraft.core.BlockPos;
|
@@ -10,6 +10,7 @@ import net.minecraft.core.BlockPos;
|
||||||
@ -43,7 +43,7 @@ index 80c172b57857a19d5f78c6f06335dc7c957ccbb6..e10d377eb7540ed54ddcb6632afc2395
|
|||||||
import net.minecraft.util.Mth;
|
import net.minecraft.util.Mth;
|
||||||
import net.minecraft.world.entity.Entity;
|
import net.minecraft.world.entity.Entity;
|
||||||
import net.minecraft.world.entity.Mob;
|
import net.minecraft.world.entity.Mob;
|
||||||
@@ -110,7 +111,13 @@ public abstract class PathNavigation {
|
@@ -106,7 +107,13 @@ public abstract class PathNavigation {
|
||||||
|
|
||||||
@Nullable
|
@Nullable
|
||||||
public Path createPath(BlockPos target, int distance) {
|
public Path createPath(BlockPos target, int distance) {
|
||||||
@ -58,7 +58,7 @@ index 80c172b57857a19d5f78c6f06335dc7c957ccbb6..e10d377eb7540ed54ddcb6632afc2395
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Nullable
|
@Nullable
|
||||||
@@ -120,7 +127,7 @@ public abstract class PathNavigation {
|
@@ -116,7 +123,7 @@ public abstract class PathNavigation {
|
||||||
|
|
||||||
@Nullable
|
@Nullable
|
||||||
public Path createPath(Entity entity, int distance) {
|
public Path createPath(Entity entity, int distance) {
|
||||||
@ -67,7 +67,7 @@ index 80c172b57857a19d5f78c6f06335dc7c957ccbb6..e10d377eb7540ed54ddcb6632afc2395
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Nullable
|
@Nullable
|
||||||
@@ -130,6 +137,16 @@ public abstract class PathNavigation {
|
@@ -126,6 +133,16 @@ public abstract class PathNavigation {
|
||||||
|
|
||||||
@Nullable
|
@Nullable
|
||||||
protected Path createPath(Set<BlockPos> positions, int range, boolean useHeadPos, int distance, float followRange) {
|
protected Path createPath(Set<BlockPos> positions, int range, boolean useHeadPos, int distance, float followRange) {
|
||||||
@ -84,7 +84,7 @@ index 80c172b57857a19d5f78c6f06335dc7c957ccbb6..e10d377eb7540ed54ddcb6632afc2395
|
|||||||
if (positions.isEmpty()) {
|
if (positions.isEmpty()) {
|
||||||
return null;
|
return null;
|
||||||
} else if (this.mob.getY() < (double)this.level.getMinBuildHeight()) {
|
} else if (this.mob.getY() < (double)this.level.getMinBuildHeight()) {
|
||||||
@@ -139,6 +156,23 @@ public abstract class PathNavigation {
|
@@ -135,6 +152,23 @@ public abstract class PathNavigation {
|
||||||
} else if (this.path != null && !this.path.isDone() && positions.contains(this.targetPos)) {
|
} else if (this.path != null && !this.path.isDone() && positions.contains(this.targetPos)) {
|
||||||
return this.path;
|
return this.path;
|
||||||
} else {
|
} else {
|
||||||
|
@ -20,10 +20,10 @@ index 8834ed411a7db86b4d2b88183a1315317107d719..c45b5ab6776f3ac79f856c3a6467c510
|
|||||||
static final ServerboundInteractPacket.Action ATTACK_ACTION = new ServerboundInteractPacket.Action() {
|
static final ServerboundInteractPacket.Action ATTACK_ACTION = new ServerboundInteractPacket.Action() {
|
||||||
@Override
|
@Override
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 76e34fb4bb6b3d194e155bec30d36887350f3ee3..7d6fc7b64a4cdec0f432374c5258ec99ea52889c 100644
|
index 103d0afd73de68e3b07a9a4ef6d2f5af0a0e40c5..71b424b65d55302c8d5b243f6f3bc9fae1b7b98f 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -2200,8 +2200,37 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2201,8 +2201,37 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,10 +13,10 @@ custom renderers are in use, defaulting to the much simpler Vanilla system.
|
|||||||
Additionally, numerous issues to player position tracking on maps has been fixed.
|
Additionally, numerous issues to player position tracking on maps has been fixed.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 8c5133defa9d3166cf987a6f1d02f02f0515746d..41b4cc7577b937e22512df00e3d4a3445fa7d004 100644
|
index ce13b2b9bcf0984732b3309ec3f14731cc6aef5f..92fc07fb1a9dab0d44ac439287d10ae05a4e7043 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -2013,6 +2013,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -2046,6 +2046,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
{
|
{
|
||||||
if ( iter.next().player == entity )
|
if ( iter.next().player == entity )
|
||||||
{
|
{
|
||||||
@ -25,7 +25,7 @@ index 8c5133defa9d3166cf987a6f1d02f02f0515746d..41b4cc7577b937e22512df00e3d4a344
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/world/entity/player/Player.java b/src/main/java/net/minecraft/world/entity/player/Player.java
|
diff --git a/src/main/java/net/minecraft/world/entity/player/Player.java b/src/main/java/net/minecraft/world/entity/player/Player.java
|
||||||
index 5d37c82bd5cd20aa2d452f0214f3303768e36a3d..6cf50fbfdeee38f8835ad8dd6ec6d16416174067 100644
|
index 4d9b7fbb35d0c8f4fbb43b77a2e11a919614ab56..2862e75108b3304ab186ed89eb36801500e58b85 100644
|
||||||
--- a/src/main/java/net/minecraft/world/entity/player/Player.java
|
--- a/src/main/java/net/minecraft/world/entity/player/Player.java
|
||||||
+++ b/src/main/java/net/minecraft/world/entity/player/Player.java
|
+++ b/src/main/java/net/minecraft/world/entity/player/Player.java
|
||||||
@@ -87,6 +87,7 @@ import net.minecraft.world.item.ElytraItem;
|
@@ -87,6 +87,7 @@ import net.minecraft.world.item.ElytraItem;
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Add server-name parameter
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
index 6300161cafb6efed7a262fa6b0b17d2f471fb2bb..ed842f74fbd2de066cfbf8522c638ff2942e8197 100644
|
index e6362865d1e7beac23e520ebd2deb8a356428045..60ccdf33a014f3488353045e30526bc3f16e93c5 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
@@ -151,6 +151,14 @@ public class Main {
|
@@ -149,6 +149,14 @@ public class Main {
|
||||||
.defaultsTo(new File[] {})
|
.defaultsTo(new File[] {})
|
||||||
.describedAs("Jar file");
|
.describedAs("Jar file");
|
||||||
// Paper end
|
// Paper end
|
||||||
|
@ -23,10 +23,10 @@ index 728835cddd413d778e9628360989724f65335b46..6c13fe725ca2b2a6f0f375b80f6c2cb6
|
|||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 7d6fc7b64a4cdec0f432374c5258ec99ea52889c..9b24ddf170e00e60391a240686e6767e19b04fd3 100644
|
index 71b424b65d55302c8d5b243f6f3bc9fae1b7b98f..d5ada382c2239d459338f377c9835cdcc573bd0e 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -1489,13 +1489,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1490,13 +1490,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
// Spigot start - limit place/interactions
|
// Spigot start - limit place/interactions
|
||||||
private int limitedPackets;
|
private int limitedPackets;
|
||||||
private long lastLimitedPacket = -1;
|
private long lastLimitedPacket = -1;
|
||||||
|
@ -21,10 +21,10 @@ index 6c13fe725ca2b2a6f0f375b80f6c2cb643b9913d..5e23ff0c5e44427a996281ae42fc12c2
|
|||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 9b24ddf170e00e60391a240686e6767e19b04fd3..73293dff5dac52c0737bbda65caea3a1e0cc4acd 100644
|
index d5ada382c2239d459338f377c9835cdcc573bd0e..0d947ddd19841ab4de3a2d46c6a5a8b5fd42385b 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -300,7 +300,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -301,7 +301,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
if (this.clientIsFloating && !this.player.isSleeping()) {
|
if (this.clientIsFloating && !this.player.isSleeping()) {
|
||||||
if (++this.aboveGroundTickCount > 80) {
|
if (++this.aboveGroundTickCount > 80) {
|
||||||
ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked for floating too long!", this.player.getName().getString());
|
ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked for floating too long!", this.player.getName().getString());
|
||||||
@ -33,7 +33,7 @@ index 9b24ddf170e00e60391a240686e6767e19b04fd3..73293dff5dac52c0737bbda65caea3a1
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@@ -319,7 +319,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -320,7 +320,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
if (this.clientVehicleIsFloating && this.player.getRootVehicle().getControllingPassenger() == this.player) {
|
if (this.clientVehicleIsFloating && this.player.getRootVehicle().getControllingPassenger() == this.player) {
|
||||||
if (++this.aboveGroundVehicleTickCount > 80) {
|
if (++this.aboveGroundVehicleTickCount > 80) {
|
||||||
ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked for floating a vehicle too long!", this.player.getName().getString());
|
ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked for floating a vehicle too long!", this.player.getName().getString());
|
||||||
|
@ -13,10 +13,10 @@ by adding code to all overrides in:
|
|||||||
to return BLOCKED if it is outside the world border.
|
to return BLOCKED if it is outside the world border.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
diff --git a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
||||||
index e10d377eb7540ed54ddcb6632afc2395c021b8ab..e675eca77a0a1718cdaceefa20b026dffdcc5508 100644
|
index 4335bd9d6413d56326be573f7c07c8cd0503d352..9fba89aa8b1c257cdc3a63a5bd137320d66a37ec 100644
|
||||||
--- a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
--- a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
||||||
+++ b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
+++ b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
||||||
@@ -159,7 +159,7 @@ public abstract class PathNavigation {
|
@@ -155,7 +155,7 @@ public abstract class PathNavigation {
|
||||||
// Paper start - Pathfind event
|
// Paper start - Pathfind event
|
||||||
boolean copiedSet = false;
|
boolean copiedSet = false;
|
||||||
for (BlockPos possibleTarget : positions) {
|
for (BlockPos possibleTarget : positions) {
|
||||||
|
@ -6,10 +6,10 @@ Subject: [PATCH] Optimize ItemStack.isEmpty()
|
|||||||
Remove hashMap lookup every check, simplify code to remove ternary
|
Remove hashMap lookup every check, simplify code to remove ternary
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
index d342ae7b4fc1f682a885f0dca7b7fc222905490d..de3a7542403e0b42679ac7fab623611605f280b7 100644
|
index 74e4990888d88f18cb3d800724d9156e9d1ae21d..ce082016d841e3e7ba46b722b85edae9acc3f290 100644
|
||||||
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
@@ -240,7 +240,7 @@ public final class ItemStack {
|
@@ -239,7 +239,7 @@ public final class ItemStack {
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isEmpty() {
|
public boolean isEmpty() {
|
||||||
|
@ -19,10 +19,10 @@ index 3a97690a1e65db9a1c184fa4df5899cfda3d44bc..ab73818893b00551f8137704a727e330
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 73293dff5dac52c0737bbda65caea3a1e0cc4acd..f9d5af3842696c1a0286098f2d255f44932d4a4a 100644
|
index 0d947ddd19841ab4de3a2d46c6a5a8b5fd42385b..0d473a405345d809742cb312068db8bf33ef17e7 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -2817,7 +2817,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2818,7 +2818,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
}
|
}
|
||||||
|
|
||||||
public final boolean isDisconnected() {
|
public final boolean isDisconnected() {
|
||||||
|
@ -5,7 +5,7 @@ Subject: [PATCH] Make targetSize more aggressive in the chunk unload queue
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index 13038723347cdbada65611d9de542d35d94084a0..e954365c9fe7a5f442c4ab31ab8c8db9684409e8 100644
|
index c72d19a903a5cbb48d38f493e00e8c54a8e23b9c..065ee0486ec275f9b61dc18afa86023183f0c73b 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -221,7 +221,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -221,7 +221,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
@ -17,7 +17,7 @@ index 13038723347cdbada65611d9de542d35d94084a0..e954365c9fe7a5f442c4ab31ab8c8db9
|
|||||||
this.structureManager = structureManager;
|
this.structureManager = structureManager;
|
||||||
Path path = session.getDimensionPath(world.dimension());
|
Path path = session.getDimensionPath(world.dimension());
|
||||||
|
|
||||||
@@ -567,7 +567,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -529,7 +529,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
// Spigot start
|
// Spigot start
|
||||||
org.spigotmc.SlackActivityAccountant activityAccountant = this.level.getServer().slackActivityAccountant;
|
org.spigotmc.SlackActivityAccountant activityAccountant = this.level.getServer().slackActivityAccountant;
|
||||||
activityAccountant.startActivity(0.5);
|
activityAccountant.startActivity(0.5);
|
||||||
@ -26,7 +26,7 @@ index 13038723347cdbada65611d9de542d35d94084a0..e954365c9fe7a5f442c4ab31ab8c8db9
|
|||||||
// Spigot end
|
// Spigot end
|
||||||
while (longiterator.hasNext()) { // Spigot
|
while (longiterator.hasNext()) { // Spigot
|
||||||
long j = longiterator.nextLong();
|
long j = longiterator.nextLong();
|
||||||
@@ -587,7 +587,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -549,7 +549,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
}
|
}
|
||||||
activityAccountant.endActivity(); // Spigot
|
activityAccountant.endActivity(); // Spigot
|
||||||
|
|
||||||
|
@ -26,10 +26,10 @@ index 47b717e8741bb2b8f3aa776dcdc73a3e7dbb5960..9dad1efab44b8a23f274aa89c85944d9
|
|||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index f9d5af3842696c1a0286098f2d255f44932d4a4a..1eac0962c59fffe47a33903238f7f43e5f77450e 100644
|
index 0d473a405345d809742cb312068db8bf33ef17e7..57f1d97c77350757e1686023a422d343af6d6e92 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -2050,6 +2050,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2051,6 +2051,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
switch (packet.getAction()) {
|
switch (packet.getAction()) {
|
||||||
case PRESS_SHIFT_KEY:
|
case PRESS_SHIFT_KEY:
|
||||||
this.player.setShiftKeyDown(true);
|
this.player.setShiftKeyDown(true);
|
||||||
|
@ -278,7 +278,7 @@ index 93e3d587f7d1d621e8aedb8e53f38a8df21b5587..8bad6fa590cfe47e1216a160531f4cd1
|
|||||||
@Override
|
@Override
|
||||||
public PluginCommand getPluginCommand(String name) {
|
public PluginCommand getPluginCommand(String name) {
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
index ed842f74fbd2de066cfbf8522c638ff2942e8197..8ab84e5591bbf2895f75b428f024760faa74d06d 100644
|
index 60ccdf33a014f3488353045e30526bc3f16e93c5..a19d5abb8188e2fd2382b9b42d65fa7a8c3d1799 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
@@ -12,7 +12,7 @@ import java.util.logging.Level;
|
@@ -12,7 +12,7 @@ import java.util.logging.Level;
|
||||||
@ -290,7 +290,7 @@ index ed842f74fbd2de066cfbf8522c638ff2942e8197..8ab84e5591bbf2895f75b428f024760f
|
|||||||
|
|
||||||
public class Main {
|
public class Main {
|
||||||
public static boolean useJline = true;
|
public static boolean useJline = true;
|
||||||
@@ -197,6 +197,8 @@ public class Main {
|
@@ -195,6 +195,8 @@ public class Main {
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
@ -299,7 +299,7 @@ index ed842f74fbd2de066cfbf8522c638ff2942e8197..8ab84e5591bbf2895f75b428f024760f
|
|||||||
// This trick bypasses Maven Shade's clever rewriting of our getProperty call when using String literals
|
// This trick bypasses Maven Shade's clever rewriting of our getProperty call when using String literals
|
||||||
String jline_UnsupportedTerminal = new String(new char[]{'j', 'l', 'i', 'n', 'e', '.', 'U', 'n', 's', 'u', 'p', 'p', 'o', 'r', 't', 'e', 'd', 'T', 'e', 'r', 'm', 'i', 'n', 'a', 'l'});
|
String jline_UnsupportedTerminal = new String(new char[]{'j', 'l', 'i', 'n', 'e', '.', 'U', 'n', 's', 'u', 'p', 'p', 'o', 'r', 't', 'e', 'd', 'T', 'e', 'r', 'm', 'i', 'n', 'a', 'l'});
|
||||||
String jline_terminal = new String(new char[]{'j', 'l', 'i', 'n', 'e', '.', 't', 'e', 'r', 'm', 'i', 'n', 'a', 'l'});
|
String jline_terminal = new String(new char[]{'j', 'l', 'i', 'n', 'e', '.', 't', 'e', 'r', 'm', 'i', 'n', 'a', 'l'});
|
||||||
@@ -214,9 +216,18 @@ public class Main {
|
@@ -212,9 +214,18 @@ public class Main {
|
||||||
// This ensures the terminal literal will always match the jline implementation
|
// This ensures the terminal literal will always match the jline implementation
|
||||||
System.setProperty(jline.TerminalFactory.JLINE_TERMINAL, jline.UnsupportedTerminal.class.getName());
|
System.setProperty(jline.TerminalFactory.JLINE_TERMINAL, jline.UnsupportedTerminal.class.getName());
|
||||||
}
|
}
|
||||||
@ -318,7 +318,7 @@ index ed842f74fbd2de066cfbf8522c638ff2942e8197..8ab84e5591bbf2895f75b428f024760f
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (Main.class.getPackage().getImplementationVendor() != null && System.getProperty("IReallyKnowWhatIAmDoingISwear") == null) {
|
if (Main.class.getPackage().getImplementationVendor() != null && System.getProperty("IReallyKnowWhatIAmDoingISwear") == null) {
|
||||||
@@ -244,7 +255,7 @@ public class Main {
|
@@ -242,7 +253,7 @@ public class Main {
|
||||||
System.out.println("Unable to read system info");
|
System.out.println("Unable to read system info");
|
||||||
}
|
}
|
||||||
// Paper end
|
// Paper end
|
||||||
|
@ -31,10 +31,10 @@ index bf42e5687935022fe5bcb1ed40bab09bfe189e88..b111200a8f5d3255de29c9836f70fc7f
|
|||||||
Bootstrap.isBootstrapped = true;
|
Bootstrap.isBootstrapped = true;
|
||||||
if (Registry.REGISTRY.keySet().isEmpty()) {
|
if (Registry.REGISTRY.keySet().isEmpty()) {
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
index 8ab84e5591bbf2895f75b428f024760faa74d06d..8dc72669abcaed848bb872e6eea81cae064e11b9 100644
|
index a19d5abb8188e2fd2382b9b42d65fa7a8c3d1799..a87a6583a1bd31a276a79c2cfb3c3ca4e749c3dc 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
@@ -236,10 +236,12 @@ public class Main {
|
@@ -234,10 +234,12 @@ public class Main {
|
||||||
Calendar deadline = Calendar.getInstance();
|
Calendar deadline = Calendar.getInstance();
|
||||||
deadline.add(Calendar.DAY_OF_YEAR, -14);
|
deadline.add(Calendar.DAY_OF_YEAR, -14);
|
||||||
if (buildDate.before(deadline.getTime())) {
|
if (buildDate.before(deadline.getTime())) {
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Add PlayerJumpEvent
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 1eac0962c59fffe47a33903238f7f43e5f77450e..397a6e095c5aa5674d1ef5c3bb820e864cc88d1a 100644
|
index 57f1d97c77350757e1686023a422d343af6d6e92..3a744fce441052427cb16dd99fbcefdb20761651 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -1173,7 +1173,34 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1174,7 +1174,34 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
boolean flag = d8 > 0.0D;
|
boolean flag = d8 > 0.0D;
|
||||||
|
|
||||||
if (this.player.isOnGround() && !packet.isOnGround() && flag) {
|
if (this.player.isOnGround() && !packet.isOnGround() && flag) {
|
||||||
|
@ -15,10 +15,10 @@ also adding some additional logging in order to help work out what is causing
|
|||||||
random disconnections for clients.
|
random disconnections for clients.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 397a6e095c5aa5674d1ef5c3bb820e864cc88d1a..a0cd15635635074b88841a1b43c3a08b9f32e74f 100644
|
index 3a744fce441052427cb16dd99fbcefdb20761651..77378ca56f1ec0f26fc29c2a80e27b7eddb94b93 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -2776,14 +2776,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2777,14 +2777,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void handleKeepAlive(ServerboundKeepAlivePacket packet) {
|
public void handleKeepAlive(ServerboundKeepAlivePacket packet) {
|
||||||
|
@ -17,7 +17,7 @@ from networking or during connections flood of chunk packets on slower clients,
|
|||||||
at the cost of dead connections being kept open for longer.
|
at the cost of dead connections being kept open for longer.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index a0cd15635635074b88841a1b43c3a08b9f32e74f..7e80a929bc0ddcf94f27f4febedf10ad07a531ff 100644
|
index 77378ca56f1ec0f26fc29c2a80e27b7eddb94b93..c63bb524cbcceb926fa7f0b72bfffb670e560c5a 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -220,9 +220,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -220,9 +220,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
@ -41,7 +41,7 @@ index a0cd15635635074b88841a1b43c3a08b9f32e74f..7e80a929bc0ddcf94f27f4febedf10ad
|
|||||||
|
|
||||||
public ServerGamePacketListenerImpl(MinecraftServer server, Connection connection, ServerPlayer player) {
|
public ServerGamePacketListenerImpl(MinecraftServer server, Connection connection, ServerPlayer player) {
|
||||||
this.server = server;
|
this.server = server;
|
||||||
@@ -333,18 +334,25 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -334,18 +335,25 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
}
|
}
|
||||||
|
|
||||||
this.server.getProfiler().push("keepAlive");
|
this.server.getProfiler().push("keepAlive");
|
||||||
|
@ -14,10 +14,10 @@ completion, such as offline players.
|
|||||||
Also adds isCommand and getLocation to the sync TabCompleteEvent
|
Also adds isCommand and getLocation to the sync TabCompleteEvent
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 898846546819ff71586cc1e038140047d2797e33..c795469d3221505faeabb5d06f35549c161f4f48 100644
|
index c63bb524cbcceb926fa7f0b72bfffb670e560c5a..fd7242648da5acbb6b7c5f4c182c1e0442dff77d 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -701,10 +701,10 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -702,10 +702,10 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void handleCustomCommandSuggestions(ServerboundCommandSuggestionPacket packet) {
|
public void handleCustomCommandSuggestions(ServerboundCommandSuggestionPacket packet) {
|
||||||
@ -30,7 +30,7 @@ index 898846546819ff71586cc1e038140047d2797e33..c795469d3221505faeabb5d06f35549c
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
@@ -714,12 +714,35 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -715,12 +715,35 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
stringreader.skip();
|
stringreader.skip();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -9,10 +9,10 @@ from triggering monster spawns on a server.
|
|||||||
Also a highly more effecient way to blanket block spawns in a world
|
Also a highly more effecient way to blanket block spawns in a world
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index e954365c9fe7a5f442c4ab31ab8c8db9684409e8..fb9a82b4fabdb73e9a44bcbc20b848d8116df3e9 100644
|
index 065ee0486ec275f9b61dc18afa86023183f0c73b..871c5839ec7ea39282380a42e1a45ea18897a507 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -1110,7 +1110,9 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1073,7 +1073,9 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
chunkRange = (chunkRange > level.spigotConfig.viewDistance) ? (byte) level.spigotConfig.viewDistance : chunkRange;
|
chunkRange = (chunkRange > level.spigotConfig.viewDistance) ? (byte) level.spigotConfig.viewDistance : chunkRange;
|
||||||
chunkRange = (chunkRange > 8) ? 8 : chunkRange;
|
chunkRange = (chunkRange > 8) ? 8 : chunkRange;
|
||||||
|
|
||||||
@ -23,7 +23,7 @@ index e954365c9fe7a5f442c4ab31ab8c8db9684409e8..fb9a82b4fabdb73e9a44bcbc20b848d8
|
|||||||
// Spigot end
|
// Spigot end
|
||||||
long i = chunkcoordintpair.toLong();
|
long i = chunkcoordintpair.toLong();
|
||||||
|
|
||||||
@@ -1127,6 +1129,15 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1090,6 +1092,15 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
}
|
}
|
||||||
|
|
||||||
entityplayer = (ServerPlayer) iterator.next();
|
entityplayer = (ServerPlayer) iterator.next();
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Fix exploit that allowed colored signs to be created
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index f97125ad82bc1ec850af9bdd92973942fc470bc1..77323b363573e770bbb4ae98911d5a922ad315c2 100644
|
index fd7242648da5acbb6b7c5f4c182c1e0442dff77d..222487a756ae17ffaf8b42c3b2d81873ccd103eb 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -2782,9 +2782,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2783,9 +2783,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
TextFilter.FilteredText currentLine = signText.get(i);
|
TextFilter.FilteredText currentLine = signText.get(i);
|
||||||
|
|
||||||
if (this.player.isTextFilteringEnabled()) {
|
if (this.player.isTextFilteringEnabled()) {
|
||||||
|
@ -10,10 +10,10 @@ Adds an option to control the force mode of the particle.
|
|||||||
This adds a new Builder API which is much friendlier to use.
|
This adds a new Builder API which is much friendlier to use.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 9dbb71220a966ca8d5b907d21d43f7fad138c8db..e7db1e848c1631d80e0f03d0202b20b4715d3aac 100644
|
index 92fc07fb1a9dab0d44ac439287d10ae05a4e7043..377c8a43e063522478037c1368cefd71fec701cb 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -1361,12 +1361,17 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -1383,12 +1383,17 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
}
|
}
|
||||||
|
|
||||||
public <T extends ParticleOptions> int sendParticles(ServerPlayer sender, T t0, double d0, double d1, double d2, int i, double d3, double d4, double d5, double d6, boolean force) {
|
public <T extends ParticleOptions> int sendParticles(ServerPlayer sender, T t0, double d0, double d1, double d2, int i, double d3, double d4, double d5, double d6, boolean force) {
|
||||||
|
@ -7,10 +7,10 @@ Allows you to determine why an inventory was closed, enabling plugin developers
|
|||||||
to "confirm" things based on if it was player triggered close or not.
|
to "confirm" things based on if it was player triggered close or not.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 858f2f8a55d32d232f14c0d723dd906dca38c70d..af8b594e3e5ab5d7dc9e7d86f308903120c7fd72 100644
|
index 377c8a43e063522478037c1368cefd71fec701cb..17eb43f6bb0a9bbc4e0abb991255b322a56f6160 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -1128,7 +1128,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -1130,7 +1130,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
for (net.minecraft.world.level.block.entity.BlockEntity tileentity : chunk.getBlockEntities().values()) {
|
for (net.minecraft.world.level.block.entity.BlockEntity tileentity : chunk.getBlockEntities().values()) {
|
||||||
if (tileentity instanceof net.minecraft.world.Container) {
|
if (tileentity instanceof net.minecraft.world.Container) {
|
||||||
for (org.bukkit.entity.HumanEntity h : Lists.newArrayList(((net.minecraft.world.Container) tileentity).getViewers())) {
|
for (org.bukkit.entity.HumanEntity h : Lists.newArrayList(((net.minecraft.world.Container) tileentity).getViewers())) {
|
||||||
@ -19,7 +19,7 @@ index 858f2f8a55d32d232f14c0d723dd906dca38c70d..af8b594e3e5ab5d7dc9e7d86f3089031
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -2030,7 +2030,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -2063,7 +2063,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
// Spigot Start
|
// Spigot Start
|
||||||
if (entity.getBukkitEntity() instanceof org.bukkit.inventory.InventoryHolder) {
|
if (entity.getBukkitEntity() instanceof org.bukkit.inventory.InventoryHolder) {
|
||||||
for (org.bukkit.entity.HumanEntity h : Lists.newArrayList(((org.bukkit.inventory.InventoryHolder) entity.getBukkitEntity()).getInventory().getViewers())) {
|
for (org.bukkit.entity.HumanEntity h : Lists.newArrayList(((org.bukkit.inventory.InventoryHolder) entity.getBukkitEntity()).getInventory().getViewers())) {
|
||||||
@ -75,7 +75,7 @@ index 90bff0dd400a67bcb84f8576bd8326793420919a..fd1937f49312204d38510996a5be43b7
|
|||||||
this.doCloseContainer();
|
this.doCloseContainer();
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 024c89a62749fc33f36f1394c732d4151cfb85ae..f0eb8a5b0a0f54037a7d973a0b628fb987d6492c 100644
|
index 222487a756ae17ffaf8b42c3b2d81873ccd103eb..00db9e4f46f810a4c51a0aa3d8b1a5673e2e1d67 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -186,6 +186,7 @@ import org.bukkit.event.inventory.ClickType;
|
@@ -186,6 +186,7 @@ import org.bukkit.event.inventory.ClickType;
|
||||||
@ -86,7 +86,7 @@ index 024c89a62749fc33f36f1394c732d4151cfb85ae..f0eb8a5b0a0f54037a7d973a0b628fb9
|
|||||||
import org.bukkit.event.inventory.InventoryCreativeEvent;
|
import org.bukkit.event.inventory.InventoryCreativeEvent;
|
||||||
import org.bukkit.event.inventory.InventoryType.SlotType;
|
import org.bukkit.event.inventory.InventoryType.SlotType;
|
||||||
import org.bukkit.event.inventory.SmithItemEvent;
|
import org.bukkit.event.inventory.SmithItemEvent;
|
||||||
@@ -2330,10 +2331,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2331,10 +2332,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void handleContainerClose(ServerboundContainerClosePacket packet) {
|
public void handleContainerClose(ServerboundContainerClosePacket packet) {
|
||||||
|
@ -16,10 +16,10 @@ Refresh the player inventory when PlayerInteractEntityEvent is
|
|||||||
cancelled to avoid this problem.
|
cancelled to avoid this problem.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 930f71861b1ee2fe210bd0e987a6b304b25f19dc..843e0c6bf53ccbb92efe14a3d32fed3013a6a53e 100644
|
index 00db9e4f46f810a4c51a0aa3d8b1a5673e2e1d67..1c81dff5ddd54ce9ae8e8d1ba9e986647e52ca29 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -2215,6 +2215,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2216,6 +2216,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
}
|
}
|
||||||
|
|
||||||
if (event.isCancelled()) {
|
if (event.isCancelled()) {
|
||||||
|
@ -45,7 +45,7 @@ index 8ecd1e851cc2168c538947623e1c328e463b52d9..1508afe593a1b62e3a33455707e25524
|
|||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 843e0c6bf53ccbb92efe14a3d32fed3013a6a53e..c8a5cd52689b2cd81a2206f0f71623d784c379ce 100644
|
index 1c81dff5ddd54ce9ae8e8d1ba9e986647e52ca29..3b757e6748fa2af3730ae18d1bad1d7c86a11b90 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -226,6 +226,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -226,6 +226,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
@ -56,7 +56,7 @@ index 843e0c6bf53ccbb92efe14a3d32fed3013a6a53e..c8a5cd52689b2cd81a2206f0f71623d7
|
|||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
private int dropSpamTickCount;
|
private int dropSpamTickCount;
|
||||||
private double firstGoodX;
|
private double firstGoodX;
|
||||||
@@ -358,6 +359,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -359,6 +360,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
this.server.getProfiler().pop();
|
this.server.getProfiler().pop();
|
||||||
// CraftBukkit start
|
// CraftBukkit start
|
||||||
for (int spam; (spam = this.chatSpamTickCount.get()) > 0 && !this.chatSpamTickCount.compareAndSet(spam, spam - 1); ) ;
|
for (int spam; (spam = this.chatSpamTickCount.get()) > 0 && !this.chatSpamTickCount.compareAndSet(spam, spam - 1); ) ;
|
||||||
@ -64,7 +64,7 @@ index 843e0c6bf53ccbb92efe14a3d32fed3013a6a53e..c8a5cd52689b2cd81a2206f0f71623d7
|
|||||||
/* Use thread-safe field access instead
|
/* Use thread-safe field access instead
|
||||||
if (this.chatSpamTickCount > 0) {
|
if (this.chatSpamTickCount > 0) {
|
||||||
--this.chatSpamTickCount;
|
--this.chatSpamTickCount;
|
||||||
@@ -704,7 +706,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -705,7 +707,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
public void handleCustomCommandSuggestions(ServerboundCommandSuggestionPacket packet) {
|
public void handleCustomCommandSuggestions(ServerboundCommandSuggestionPacket packet) {
|
||||||
// PlayerConnectionUtils.ensureMainThread(packetplayintabcomplete, this, this.player.getWorldServer()); // Paper - run this async
|
// PlayerConnectionUtils.ensureMainThread(packetplayintabcomplete, this, this.player.getWorldServer()); // Paper - run this async
|
||||||
// CraftBukkit start
|
// CraftBukkit start
|
||||||
|
@ -8,10 +8,10 @@ Add -Ddebug.entities=true to your JVM flags to gain more information
|
|||||||
1.17: Needs to be reworked for new entity storage system
|
1.17: Needs to be reworked for new entity storage system
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index fb9a82b4fabdb73e9a44bcbc20b848d8116df3e9..488682910779bcfbd16f7658b1fb3be5f7984627 100644
|
index 871c5839ec7ea39282380a42e1a45ea18897a507..a8c47535ec8c0cf992c40ec74a7a3a1f78da4865 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -1352,6 +1352,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1312,6 +1312,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
} else {
|
} else {
|
||||||
ChunkMap.TrackedEntity playerchunkmap_entitytracker = new ChunkMap.TrackedEntity(entity, i, j, entitytypes.trackDeltas());
|
ChunkMap.TrackedEntity playerchunkmap_entitytracker = new ChunkMap.TrackedEntity(entity, i, j, entitytypes.trackDeltas());
|
||||||
|
|
||||||
@ -19,7 +19,7 @@ index fb9a82b4fabdb73e9a44bcbc20b848d8116df3e9..488682910779bcfbd16f7658b1fb3be5
|
|||||||
this.entityMap.put(entity.getId(), playerchunkmap_entitytracker);
|
this.entityMap.put(entity.getId(), playerchunkmap_entitytracker);
|
||||||
playerchunkmap_entitytracker.updatePlayers(this.level.players());
|
playerchunkmap_entitytracker.updatePlayers(this.level.players());
|
||||||
if (entity instanceof ServerPlayer) {
|
if (entity instanceof ServerPlayer) {
|
||||||
@@ -1394,7 +1395,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1354,7 +1355,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
if (playerchunkmap_entitytracker1 != null) {
|
if (playerchunkmap_entitytracker1 != null) {
|
||||||
playerchunkmap_entitytracker1.broadcastRemoved();
|
playerchunkmap_entitytracker1.broadcastRemoved();
|
||||||
}
|
}
|
||||||
@ -29,10 +29,10 @@ index fb9a82b4fabdb73e9a44bcbc20b848d8116df3e9..488682910779bcfbd16f7658b1fb3be5
|
|||||||
|
|
||||||
protected void tick() {
|
protected void tick() {
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 9a51aa9f40ceaaa3500595bf08b2b5515704b91a..9a9ae2cac9f44e38f58bd58c279fc648ec728032 100644
|
index 17eb43f6bb0a9bbc4e0abb991255b322a56f6160..2d0e04cd2ab6403b3f5324cad130ec768a39d608 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -206,6 +206,9 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -208,6 +208,9 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
public final LevelStorageSource.LevelStorageAccess convertable;
|
public final LevelStorageSource.LevelStorageAccess convertable;
|
||||||
public final UUID uuid;
|
public final UUID uuid;
|
||||||
public boolean hasPhysicsEvent = true; // Paper
|
public boolean hasPhysicsEvent = true; // Paper
|
||||||
@ -42,7 +42,7 @@ index 9a51aa9f40ceaaa3500595bf08b2b5515704b91a..9a9ae2cac9f44e38f58bd58c279fc648
|
|||||||
|
|
||||||
@Override public LevelChunk getChunkIfLoaded(int x, int z) { // Paper - this was added in world too but keeping here for NMS ABI
|
@Override public LevelChunk getChunkIfLoaded(int x, int z) { // Paper - this was added in world too but keeping here for NMS ABI
|
||||||
return this.chunkSource.getChunk(x, z, false);
|
return this.chunkSource.getChunk(x, z, false);
|
||||||
@@ -1091,7 +1094,28 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -1093,7 +1096,28 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
// CraftBukkit start
|
// CraftBukkit start
|
||||||
private boolean addEntity(Entity entity, CreatureSpawnEvent.SpawnReason spawnReason) {
|
private boolean addEntity(Entity entity, CreatureSpawnEvent.SpawnReason spawnReason) {
|
||||||
org.spigotmc.AsyncCatcher.catchOp("entity add"); // Spigot
|
org.spigotmc.AsyncCatcher.catchOp("entity add"); // Spigot
|
||||||
@ -72,7 +72,7 @@ index 9a51aa9f40ceaaa3500595bf08b2b5515704b91a..9a9ae2cac9f44e38f58bd58c279fc648
|
|||||||
return false;
|
return false;
|
||||||
} else {
|
} else {
|
||||||
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
|
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||||
index 5df955eea09b5abd32c12abf5d13030bf9a3a9ae..d442725c1c9ae274b11f3a11ea4cf15f51d62def 100644
|
index 2a11514554b6aea819046282cfcaeeb43d1ed920..2981a29b011cb1a08a776abc5ec6a94228061f98 100644
|
||||||
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
||||||
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||||
@@ -170,6 +170,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, i
|
@@ -170,6 +170,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, i
|
||||||
@ -85,7 +85,7 @@ index 5df955eea09b5abd32c12abf5d13030bf9a3a9ae..d442725c1c9ae274b11f3a11ea4cf15f
|
|||||||
if (this.bukkitEntity == null) {
|
if (this.bukkitEntity == null) {
|
||||||
this.bukkitEntity = CraftEntity.getEntity(this.level.getCraftServer(), this);
|
this.bukkitEntity = CraftEntity.getEntity(this.level.getCraftServer(), this);
|
||||||
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
||||||
index aa8bbf6435c19013e3ccaa963118d71200b6efea..2cdf117a5041830f201d5f1e98f7cc8f9cb6dd6f 100644
|
index c239a71a9d864107c3a8e9537e4160c50b3a76c9..ee5415574dea0712f08e2467ecf93aa1ce39a2e5 100644
|
||||||
--- a/src/main/java/net/minecraft/world/level/Level.java
|
--- a/src/main/java/net/minecraft/world/level/Level.java
|
||||||
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
||||||
@@ -142,6 +142,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
@@ -142,6 +142,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||||
|
@ -2279,7 +2279,7 @@ index a5e438a834826161c52ca9db57d234d9ff80a591..b8bc1b9b8e8a33df90a963f9f9769292
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
diff --git a/src/main/java/net/minecraft/server/Main.java b/src/main/java/net/minecraft/server/Main.java
|
diff --git a/src/main/java/net/minecraft/server/Main.java b/src/main/java/net/minecraft/server/Main.java
|
||||||
index 4ab820c43ddc79f5a280e2d4b322a667b9ba725f..e0c1e4e38ff49429a587c59afb86e95c452d52a0 100644
|
index e98492adfb83c24e1baa6cab24cca55f3ec151bf..afc7606e0df5dc87767444b42bb4e4b1b2f96b2d 100644
|
||||||
--- a/src/main/java/net/minecraft/server/Main.java
|
--- a/src/main/java/net/minecraft/server/Main.java
|
||||||
+++ b/src/main/java/net/minecraft/server/Main.java
|
+++ b/src/main/java/net/minecraft/server/Main.java
|
||||||
@@ -227,6 +227,7 @@ public class Main {
|
@@ -227,6 +227,7 @@ public class Main {
|
||||||
@ -2317,10 +2317,10 @@ index 45de5e508540b4ba622985d530f1aadaa7eb4535..5b8b9dabc6673b6f0a335a42d2ec71a5
|
|||||||
ChunkHolder.FullChunkStatus playerchunk_state1 = ChunkHolder.getFullChunkStatus(this.ticketLevel);
|
ChunkHolder.FullChunkStatus playerchunk_state1 = ChunkHolder.getFullChunkStatus(this.ticketLevel);
|
||||||
// CraftBukkit start
|
// CraftBukkit start
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d75909467ba94 100644
|
index a8c47535ec8c0cf992c40ec74a7a3a1f78da4865..87f055f8338d4ce2f9ff76bdc6c0b7ffc266ce78 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -504,6 +504,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -466,6 +466,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
public void close() throws IOException {
|
public void close() throws IOException {
|
||||||
try {
|
try {
|
||||||
this.queueSorter.close();
|
this.queueSorter.close();
|
||||||
@ -2328,7 +2328,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
this.poiManager.close();
|
this.poiManager.close();
|
||||||
} finally {
|
} finally {
|
||||||
super.close();
|
super.close();
|
||||||
@@ -540,7 +541,8 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -502,7 +503,8 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
this.processUnloads(() -> {
|
this.processUnloads(() -> {
|
||||||
return true;
|
return true;
|
||||||
});
|
});
|
||||||
@ -2338,7 +2338,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
} else {
|
} else {
|
||||||
this.visibleChunkMap.values().forEach(this::saveChunkIfNeeded);
|
this.visibleChunkMap.values().forEach(this::saveChunkIfNeeded);
|
||||||
}
|
}
|
||||||
@@ -550,17 +552,21 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -512,17 +514,21 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
protected void tick(BooleanSupplier shouldKeepTicking) {
|
protected void tick(BooleanSupplier shouldKeepTicking) {
|
||||||
ProfilerFiller gameprofilerfiller = this.level.getProfiler();
|
ProfilerFiller gameprofilerfiller = this.level.getProfiler();
|
||||||
|
|
||||||
@ -2361,7 +2361,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
|
|
||||||
private void processUnloads(BooleanSupplier shouldKeepTicking) {
|
private void processUnloads(BooleanSupplier shouldKeepTicking) {
|
||||||
LongIterator longiterator = this.toDrop.iterator();
|
LongIterator longiterator = this.toDrop.iterator();
|
||||||
@@ -577,12 +583,13 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -539,12 +545,13 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
if (playerchunk != null) {
|
if (playerchunk != null) {
|
||||||
this.pendingUnloads.put(j, playerchunk);
|
this.pendingUnloads.put(j, playerchunk);
|
||||||
this.modified = true;
|
this.modified = true;
|
||||||
@ -2376,7 +2376,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
activityAccountant.endActivity(); // Spigot
|
activityAccountant.endActivity(); // Spigot
|
||||||
@@ -626,7 +633,16 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -588,7 +595,16 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
((LevelChunk) ichunkaccess).setLoaded(false);
|
((LevelChunk) ichunkaccess).setLoaded(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2394,7 +2394,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
if (this.entitiesInLevel.remove(pos) && ichunkaccess instanceof LevelChunk) {
|
if (this.entitiesInLevel.remove(pos) && ichunkaccess instanceof LevelChunk) {
|
||||||
LevelChunk chunk = (LevelChunk) ichunkaccess;
|
LevelChunk chunk = (LevelChunk) ichunkaccess;
|
||||||
|
|
||||||
@@ -691,20 +707,21 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -653,20 +669,21 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
}
|
}
|
||||||
|
|
||||||
private CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>> scheduleChunkLoad(ChunkPos pos) {
|
private CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>> scheduleChunkLoad(ChunkPos pos) {
|
||||||
@ -2427,7 +2427,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
this.markPosition(pos, protochunk.getStatus().getChunkType());
|
this.markPosition(pos, protochunk.getStatus().getChunkType());
|
||||||
return Either.left(protochunk);
|
return Either.left(protochunk);
|
||||||
}
|
}
|
||||||
@@ -726,7 +743,32 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -688,7 +705,32 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
|
|
||||||
this.markPositionReplaceable(pos);
|
this.markPositionReplaceable(pos);
|
||||||
return Either.left(new ProtoChunk(pos, UpgradeData.EMPTY, this.level, this.level.registryAccess().registryOrThrow(Registry.BIOME_REGISTRY), (BlendingData) null));
|
return Either.left(new ProtoChunk(pos, UpgradeData.EMPTY, this.level, this.level.registryAccess().registryOrThrow(Registry.BIOME_REGISTRY), (BlendingData) null));
|
||||||
@ -2461,7 +2461,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void markPositionReplaceable(ChunkPos pos) {
|
private void markPositionReplaceable(ChunkPos pos) {
|
||||||
@@ -928,7 +970,48 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -890,7 +932,48 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2510,7 +2510,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
this.poiManager.flush(chunk.getPos());
|
this.poiManager.flush(chunk.getPos());
|
||||||
if (!chunk.isUnsaved()) {
|
if (!chunk.isUnsaved()) {
|
||||||
return false;
|
return false;
|
||||||
@@ -940,7 +1023,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -902,7 +985,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
ChunkStatus chunkstatus = chunk.getStatus();
|
ChunkStatus chunkstatus = chunk.getStatus();
|
||||||
|
|
||||||
if (chunkstatus.getChunkType() != ChunkStatus.ChunkType.LEVELCHUNK) {
|
if (chunkstatus.getChunkType() != ChunkStatus.ChunkType.LEVELCHUNK) {
|
||||||
@ -2519,7 +2519,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -950,9 +1033,15 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -912,9 +995,15 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
}
|
}
|
||||||
|
|
||||||
this.level.getProfiler().incrementCounter("chunkSave");
|
this.level.getProfiler().incrementCounter("chunkSave");
|
||||||
@ -2537,7 +2537,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
this.markPosition(chunkcoordintpair, chunkstatus.getChunkType());
|
this.markPosition(chunkcoordintpair, chunkstatus.getChunkType());
|
||||||
return true;
|
return true;
|
||||||
} catch (Exception exception) {
|
} catch (Exception exception) {
|
||||||
@@ -961,6 +1050,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -923,6 +1012,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2545,7 +2545,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
}
|
}
|
||||||
|
|
||||||
private boolean isExistingChunkFull(ChunkPos pos) {
|
private boolean isExistingChunkFull(ChunkPos pos) {
|
||||||
@@ -1093,6 +1183,35 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1056,6 +1146,35 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2582,7 +2582,7 @@ index 488682910779bcfbd16f7658b1fb3be5f7984627..aea216ee07fc733e90bd1170e46d7590
|
|||||||
public CompoundTag readChunk(ChunkPos pos) throws IOException {
|
public CompoundTag readChunk(ChunkPos pos) throws IOException {
|
||||||
CompoundTag nbttagcompound = this.read(pos);
|
CompoundTag nbttagcompound = this.read(pos);
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
index 9090bc174c0ccb542616e756be66967f55f0a626..1dc1005142f822c05eb9065b4a5da456ec936ff2 100644
|
index 87c9a7ffc69206554cf37c7d2c9939eb3cbea3a9..7b391d6ab84eeaed7bdd27ea70d5e3f9690a0abf 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
@@ -502,10 +502,111 @@ public class ServerChunkCache extends ChunkSource {
|
@@ -502,10 +502,111 @@ public class ServerChunkCache extends ChunkSource {
|
||||||
@ -2744,10 +2744,10 @@ index 9090bc174c0ccb542616e756be66967f55f0a626..1dc1005142f822c05eb9065b4a5da456
|
|||||||
} finally {
|
} finally {
|
||||||
chunkMap.callbackExecutor.run();
|
chunkMap.callbackExecutor.run();
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 9a9ae2cac9f44e38f58bd58c279fc648ec728032..e1f8d771775acef29b8e4808a69d8e3a37070a28 100644
|
index 2d0e04cd2ab6403b3f5324cad130ec768a39d608..5abcae55b2dc37eea514d194803bc9a851f18c25 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -307,6 +307,78 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -309,6 +309,78 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2826,7 +2826,7 @@ index 9a9ae2cac9f44e38f58bd58c279fc648ec728032..e1f8d771775acef29b8e4808a69d8e3a
|
|||||||
// Paper end
|
// Paper end
|
||||||
|
|
||||||
// Add env and gen to constructor, WorldData -> WorldDataServer
|
// Add env and gen to constructor, WorldData -> WorldDataServer
|
||||||
@@ -374,6 +446,8 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -376,6 +448,8 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
|
|
||||||
this.sleepStatus = new SleepStatus();
|
this.sleepStatus = new SleepStatus();
|
||||||
this.getCraftServer().addWorld(this.getWorld()); // CraftBukkit
|
this.getCraftServer().addWorld(this.getWorld()); // CraftBukkit
|
||||||
@ -2848,10 +2848,10 @@ index 0d536d72ac918fbd403397ff369d10143ee9c204..be677d437d17b74c6188ce1bd5fc6fdc
|
|||||||
private final String name;
|
private final String name;
|
||||||
private final Comparator<T> comparator;
|
private final Comparator<T> comparator;
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 5706d52d89bcec1d5da44ebf24f1b94cad59d359..136b5972f4faa4f43bc49b9c282a6578d31aed55 100644
|
index 3b757e6748fa2af3730ae18d1bad1d7c86a11b90..a2783f87c560f4104216dce0c662e464f247356c 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -710,6 +710,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -711,6 +711,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
server.scheduleOnMain(() -> this.disconnect(new TranslatableComponent("disconnect.spam", new Object[0]))); // Paper
|
server.scheduleOnMain(() -> this.disconnect(new TranslatableComponent("disconnect.spam", new Object[0]))); // Paper
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Allow chests to be placed with NBT data
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
index de3a7542403e0b42679ac7fab623611605f280b7..e546f212d0228171920a0b28f918020617dfd7ca 100644
|
index ce082016d841e3e7ba46b722b85edae9acc3f290..589a9bd9d3bf3cbf88a6efad5f58970a0a4a56c0 100644
|
||||||
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
@@ -339,6 +339,7 @@ public final class ItemStack {
|
@@ -338,6 +338,7 @@ public final class ItemStack {
|
||||||
enuminteractionresult = InteractionResult.FAIL; // cancel placement
|
enuminteractionresult = InteractionResult.FAIL; // cancel placement
|
||||||
// PAIL: Remove this when MC-99075 fixed
|
// PAIL: Remove this when MC-99075 fixed
|
||||||
placeEvent.getPlayer().updateInventory();
|
placeEvent.getPlayer().updateInventory();
|
||||||
|
@ -6,7 +6,7 @@ Subject: [PATCH] Add option to prevent players from moving into unloaded
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
index 9c558fc727eb597612139820650a4226a7923cbb..92a5e0357328b5d472afd181a77a7ec7b593b88c 100644
|
index e57ab8a3e6efd78e12385042b7d91dcd27fef11d..eb44aef0aecf65f5c1b19f42bf85a3a263965a7c 100644
|
||||||
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
@@ -431,4 +431,9 @@ public class PaperWorldConfig {
|
@@ -431,4 +431,9 @@ public class PaperWorldConfig {
|
||||||
@ -20,10 +20,10 @@ index 9c558fc727eb597612139820650a4226a7923cbb..92a5e0357328b5d472afd181a77a7ec7
|
|||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 7ed73ea4a5f7383c953ee3e28ce8f234d8ff941e..26ca0db447a76c3028dacf96bf9afd3b735bda74 100644
|
index a2783f87c560f4104216dce0c662e464f247356c..886c150861c77bf26111b2ef26713e7d260f10ac 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -530,6 +530,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -531,6 +531,13 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
}
|
}
|
||||||
speed *= 2f; // TODO: Get the speed of the vehicle instead of the player
|
speed *= 2f; // TODO: Get the speed of the vehicle instead of the player
|
||||||
|
|
||||||
@ -37,7 +37,7 @@ index 7ed73ea4a5f7383c953ee3e28ce8f234d8ff941e..26ca0db447a76c3028dacf96bf9afd3b
|
|||||||
if (d10 - d9 > Math.max(100.0D, Math.pow((double) (org.spigotmc.SpigotConfig.movedTooQuicklyMultiplier * (float) i * speed), 2)) && !this.isSingleplayerOwner()) {
|
if (d10 - d9 > Math.max(100.0D, Math.pow((double) (org.spigotmc.SpigotConfig.movedTooQuicklyMultiplier * (float) i * speed), 2)) && !this.isSingleplayerOwner()) {
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
ServerGamePacketListenerImpl.LOGGER.warn("{} (vehicle of {}) moved too quickly! {},{},{}", entity.getName().getString(), this.player.getName().getString(), d6, d7, d8);
|
ServerGamePacketListenerImpl.LOGGER.warn("{} (vehicle of {}) moved too quickly! {},{},{}", entity.getName().getString(), this.player.getName().getString(), d6, d7, d8);
|
||||||
@@ -1154,9 +1161,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1155,9 +1162,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
float prevYaw = this.player.getYRot();
|
float prevYaw = this.player.getYRot();
|
||||||
float prevPitch = this.player.getXRot();
|
float prevPitch = this.player.getXRot();
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
@ -49,7 +49,7 @@ index 7ed73ea4a5f7383c953ee3e28ce8f234d8ff941e..26ca0db447a76c3028dacf96bf9afd3b
|
|||||||
double d6 = this.player.getY();
|
double d6 = this.player.getY();
|
||||||
double d7 = d0 - this.firstGoodX;
|
double d7 = d0 - this.firstGoodX;
|
||||||
double d8 = d1 - this.firstGoodY;
|
double d8 = d1 - this.firstGoodY;
|
||||||
@@ -1194,6 +1201,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1195,6 +1202,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
} else {
|
} else {
|
||||||
speed = this.player.getAbilities().walkingSpeed * 10f;
|
speed = this.player.getAbilities().walkingSpeed * 10f;
|
||||||
}
|
}
|
||||||
|
@ -12,10 +12,10 @@ server threads
|
|||||||
Allow usage of a single thread executor by not using ForkJoin so single core CPU's.
|
Allow usage of a single thread executor by not using ForkJoin so single core CPU's.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/Util.java b/src/main/java/net/minecraft/Util.java
|
diff --git a/src/main/java/net/minecraft/Util.java b/src/main/java/net/minecraft/Util.java
|
||||||
index 3ed0bf0485266c0a2b459f5cc1940f85f74e3624..b9775bc4e601fe1be8e514222e56ae782a897395 100644
|
index 5c57a6607f1a95ac4d8770d0429d6848351f5452..cc565d1f766d5a6e0fe674ee9e453dbcb890116e 100644
|
||||||
--- a/src/main/java/net/minecraft/Util.java
|
--- a/src/main/java/net/minecraft/Util.java
|
||||||
+++ b/src/main/java/net/minecraft/Util.java
|
+++ b/src/main/java/net/minecraft/Util.java
|
||||||
@@ -68,8 +68,8 @@ public class Util {
|
@@ -74,8 +74,8 @@ public class Util {
|
||||||
private static final int DEFAULT_MAX_THREADS = 255;
|
private static final int DEFAULT_MAX_THREADS = 255;
|
||||||
private static final String MAX_THREADS_SYSTEM_PROPERTY = "max.bg.threads";
|
private static final String MAX_THREADS_SYSTEM_PROPERTY = "max.bg.threads";
|
||||||
private static final AtomicInteger WORKER_COUNT = new AtomicInteger(1);
|
private static final AtomicInteger WORKER_COUNT = new AtomicInteger(1);
|
||||||
@ -26,7 +26,7 @@ index 3ed0bf0485266c0a2b459f5cc1940f85f74e3624..b9775bc4e601fe1be8e514222e56ae78
|
|||||||
private static final ExecutorService IO_POOL = makeIoExecutor();
|
private static final ExecutorService IO_POOL = makeIoExecutor();
|
||||||
public static LongSupplier timeSource = System::nanoTime;
|
public static LongSupplier timeSource = System::nanoTime;
|
||||||
public static final UUID NIL_UUID = new UUID(0L, 0L);
|
public static final UUID NIL_UUID = new UUID(0L, 0L);
|
||||||
@@ -105,14 +105,18 @@ public class Util {
|
@@ -114,14 +114,18 @@ public class Util {
|
||||||
return Instant.now().toEpochMilli();
|
return Instant.now().toEpochMilli();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -49,7 +49,7 @@ index 3ed0bf0485266c0a2b459f5cc1940f85f74e3624..b9775bc4e601fe1be8e514222e56ae78
|
|||||||
@Override
|
@Override
|
||||||
protected void onTermination(Throwable throwable) {
|
protected void onTermination(Throwable throwable) {
|
||||||
if (throwable != null) {
|
if (throwable != null) {
|
||||||
@@ -128,6 +132,7 @@ public class Util {
|
@@ -137,6 +141,7 @@ public class Util {
|
||||||
return forkJoinWorkerThread;
|
return forkJoinWorkerThread;
|
||||||
}, Util::onThreadException, true);
|
}, Util::onThreadException, true);
|
||||||
}
|
}
|
||||||
|
@ -59,10 +59,10 @@ index 1d1f355a49e2324902feee10c1717fd772e359c6..d0b54ebc05cac6535a023709c76efd80
|
|||||||
|
|
||||||
this.level.destroyBlockProgress(this.player.getId(), pos, -1);
|
this.level.destroyBlockProgress(this.player.getId(), pos, -1);
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index ab5a6bba572bc27dbf9473cf7042c4cdef6843dc..7960a57c25dc80c6ca762e65c3ef82065cce2b7a 100644
|
index 886c150861c77bf26111b2ef26713e7d260f10ac..96987ac75a2cb33e3761857f2c5074066f8c8b03 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -1550,7 +1550,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1551,7 +1551,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
case START_DESTROY_BLOCK:
|
case START_DESTROY_BLOCK:
|
||||||
case ABORT_DESTROY_BLOCK:
|
case ABORT_DESTROY_BLOCK:
|
||||||
case STOP_DESTROY_BLOCK:
|
case STOP_DESTROY_BLOCK:
|
||||||
|
@ -24,10 +24,10 @@ index 769353df1fcdaacecd80085165a1d72f99b577ee..4875e323e8ba52cf91259262b8418310
|
|||||||
private static void asyncChunks() {
|
private static void asyncChunks() {
|
||||||
ConfigurationSection section;
|
ConfigurationSection section;
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 25ec1613f4c9ecc59ec5e27717ff7de9ad9e4398..2d2b1a293a1359ffa6d33635856406a909c452ce 100644
|
index 96987ac75a2cb33e3761857f2c5074066f8c8b03..e1004d267fc62ecce8a1f98cbec40dddaa6e1485 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -1000,6 +1000,45 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1001,6 +1001,45 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void handleEditBook(ServerboundEditBookPacket packet) {
|
public void handleEditBook(ServerboundEditBookPacket packet) {
|
||||||
|
@ -10,7 +10,7 @@ Adds CommandRegisteredEvent
|
|||||||
- Allows manipulating the CommandNode to add more children/metadata for the client
|
- Allows manipulating the CommandNode to add more children/metadata for the client
|
||||||
|
|
||||||
diff --git a/build.gradle.kts b/build.gradle.kts
|
diff --git a/build.gradle.kts b/build.gradle.kts
|
||||||
index 1d62be2d0b8b35eaa7c0f7169df71ca27f8477d3..fc59f56860d02ef8c11082feae042a39e3924f45 100644
|
index f02dc8b25f406a34535e9ae4666faf6b05ad0831..6e47e915134bccb7efa9555d7f33fbe82a25c003 100644
|
||||||
--- a/build.gradle.kts
|
--- a/build.gradle.kts
|
||||||
+++ b/build.gradle.kts
|
+++ b/build.gradle.kts
|
||||||
@@ -12,6 +12,7 @@ repositories {
|
@@ -12,6 +12,7 @@ repositories {
|
||||||
@ -81,10 +81,10 @@ index ee31455158afbed8f3bbac57d2f41a59d01a0670..4049576478efed97092b7e1b3d40afda
|
|||||||
event.getPlayer().getServer().getPluginManager().callEvent(event);
|
event.getPlayer().getServer().getPluginManager().callEvent(event);
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index d4760d3cd2037ae47258d6016c6303e0a295dcbc..d0ed45db0226ebd8f60e9d84b7f41a3ca5cb3c9b 100644
|
index e1004d267fc62ecce8a1f98cbec40dddaa6e1485..3dc23e2eaa5bf9c2bdbba366767be39a8de81b5f 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -747,8 +747,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -748,8 +748,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
ParseResults<CommandSourceStack> parseresults = this.server.getCommands().getDispatcher().parse(stringreader, this.player.createCommandSourceStack());
|
ParseResults<CommandSourceStack> parseresults = this.server.getCommands().getDispatcher().parse(stringreader, this.player.createCommandSourceStack());
|
||||||
|
|
||||||
this.server.getCommands().getDispatcher().getCompletionSuggestions(parseresults).thenAccept((suggestions) -> {
|
this.server.getCommands().getDispatcher().getCompletionSuggestions(parseresults).thenAccept((suggestions) -> {
|
||||||
@ -99,7 +99,7 @@ index d4760d3cd2037ae47258d6016c6303e0a295dcbc..d0ed45db0226ebd8f60e9d84b7f41a3c
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -757,7 +761,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -758,7 +762,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
builder = builder.createOffset(builder.getInput().lastIndexOf(' ') + 1);
|
builder = builder.createOffset(builder.getInput().lastIndexOf(' ') + 1);
|
||||||
completions.forEach(builder::suggest);
|
completions.forEach(builder::suggest);
|
||||||
|
@ -22,7 +22,7 @@ it only impacts data sent from the client.
|
|||||||
Set -DPaper.maxSignLength=XX to change limit or -1 to disable
|
Set -DPaper.maxSignLength=XX to change limit or -1 to disable
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index be5f7b5e8537aa3bf4088fa8c2e9d6cce17c64ac..5d0836c8bc38e3d29f47359b273c58330805b396 100644
|
index 3dc23e2eaa5bf9c2bdbba366767be39a8de81b5f..8585cc9441674950dc8646f12698fb356cfc9e96 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -253,6 +253,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -253,6 +253,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
@ -33,7 +33,7 @@ index be5f7b5e8537aa3bf4088fa8c2e9d6cce17c64ac..5d0836c8bc38e3d29f47359b273c5833
|
|||||||
private static final long KEEPALIVE_LIMIT = Long.getLong("paper.playerconnection.keepalive", 30) * 1000; // Paper - provide property to set keepalive limit
|
private static final long KEEPALIVE_LIMIT = Long.getLong("paper.playerconnection.keepalive", 30) * 1000; // Paper - provide property to set keepalive limit
|
||||||
|
|
||||||
public ServerGamePacketListenerImpl(MinecraftServer server, Connection connection, ServerPlayer player) {
|
public ServerGamePacketListenerImpl(MinecraftServer server, Connection connection, ServerPlayer player) {
|
||||||
@@ -2861,6 +2862,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2862,6 +2863,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
for (int i = 0; i < signText.size(); ++i) {
|
for (int i = 0; i < signText.size(); ++i) {
|
||||||
TextFilter.FilteredText currentLine = signText.get(i);
|
TextFilter.FilteredText currentLine = signText.get(i);
|
||||||
|
@ -10,10 +10,10 @@ persistenting Living Entity, SPAWNER for spawners,
|
|||||||
or DEFAULT since data was not stored.
|
or DEFAULT since data was not stored.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index e1f8d771775acef29b8e4808a69d8e3a37070a28..4025baacbd278b0a30bb808895eae14bfbf706e1 100644
|
index 5abcae55b2dc37eea514d194803bc9a851f18c25..2950ad995f322570cd647d3217f340327cc3e7c8 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -1183,6 +1183,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -1185,6 +1185,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
// Paper end
|
// Paper end
|
||||||
@ -22,7 +22,7 @@ index e1f8d771775acef29b8e4808a69d8e3a37070a28..4025baacbd278b0a30bb808895eae14b
|
|||||||
// Paper start
|
// Paper start
|
||||||
if (DEBUG_ENTITIES) {
|
if (DEBUG_ENTITIES) {
|
||||||
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
index 7ac89aa6d0af25cac96ede3b085e68a803fb7229..dc5d5a498460d09de6626b8da8a7bfcbebc028e1 100644
|
index 25da9e3252154415303db662286e89e3aa7cfcd8..eea7a625fb00af13944b21e1af4bf1804c5ce6d9 100644
|
||||||
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
@@ -342,7 +342,7 @@ public abstract class PlayerList {
|
@@ -342,7 +342,7 @@ public abstract class PlayerList {
|
||||||
|
@ -22,10 +22,10 @@ index 3d27cbf5e9105def2f38525a85da5acf8ebf8fe9..ceba19ea3bb9664899b83f82f28af064
|
|||||||
this.broadcast.accept(packet);
|
this.broadcast.accept(packet);
|
||||||
if (this.entity instanceof ServerPlayer) {
|
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
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 5d0836c8bc38e3d29f47359b273c58330805b396..d27bc3d8433c0692019c0eb968c857d95a9558f0 100644
|
index 8585cc9441674950dc8646f12698fb356cfc9e96..e3d0180fc1219cfb33cfc3b55a127f86fa23618a 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -2286,7 +2286,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2287,7 +2287,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
if (event.isCancelled() || ServerGamePacketListenerImpl.this.player.getInventory().getSelected() == null || ServerGamePacketListenerImpl.this.player.getInventory().getSelected().getItem() != origItem) {
|
if (event.isCancelled() || ServerGamePacketListenerImpl.this.player.getInventory().getSelected() == null || ServerGamePacketListenerImpl.this.player.getInventory().getSelected().getItem() != origItem) {
|
||||||
// Refresh the current entity metadata
|
// Refresh the current entity metadata
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Fix CB call to changed postToMainThread method
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index d27bc3d8433c0692019c0eb968c857d95a9558f0..f4444fb23a75d0617438f6b25df7bd401ab65a26 100644
|
index e3d0180fc1219cfb33cfc3b55a127f86fa23618a..240c97682863d78d7c3621131ee1407932ec4599 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -438,7 +438,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -439,7 +439,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
Objects.requireNonNull(this.connection);
|
Objects.requireNonNull(this.connection);
|
||||||
// CraftBukkit - Don't wait
|
// CraftBukkit - Don't wait
|
||||||
|
@ -85,10 +85,10 @@ index bd8e654c1580a0ac7dd411b9f1dcad4a20d1d3e5..7576047ea9695434ca06ca8fefde0dce
|
|||||||
// CraftBukkit start
|
// CraftBukkit start
|
||||||
// this.updateMobSpawningFlags();
|
// this.updateMobSpawningFlags();
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 4025baacbd278b0a30bb808895eae14bfbf706e1..68c0f332c176030cd9adfb18a56108ce0931c332 100644
|
index 2950ad995f322570cd647d3217f340327cc3e7c8..fef3846a978dcba95c5dbe5c528ac20cb4f56178 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -59,6 +59,7 @@ import net.minecraft.network.protocol.game.ClientboundSoundEntityPacket;
|
@@ -60,6 +60,7 @@ import net.minecraft.network.protocol.game.ClientboundSoundEntityPacket;
|
||||||
import net.minecraft.network.protocol.game.ClientboundSoundPacket;
|
import net.minecraft.network.protocol.game.ClientboundSoundPacket;
|
||||||
import net.minecraft.network.protocol.game.DebugPackets;
|
import net.minecraft.network.protocol.game.DebugPackets;
|
||||||
import net.minecraft.resources.ResourceKey;
|
import net.minecraft.resources.ResourceKey;
|
||||||
@ -96,7 +96,7 @@ index 4025baacbd278b0a30bb808895eae14bfbf706e1..68c0f332c176030cd9adfb18a56108ce
|
|||||||
import net.minecraft.server.MinecraftServer;
|
import net.minecraft.server.MinecraftServer;
|
||||||
import net.minecraft.server.ServerScoreboard;
|
import net.minecraft.server.ServerScoreboard;
|
||||||
import net.minecraft.server.level.progress.ChunkProgressListener;
|
import net.minecraft.server.level.progress.ChunkProgressListener;
|
||||||
@@ -1584,12 +1585,84 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -1606,12 +1607,84 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
return ((MapIndex) this.getServer().overworld().getDataStorage().computeIfAbsent(MapIndex::load, MapIndex::new, "idcounts")).getFreeAuxValueForMap();
|
return ((MapIndex) this.getServer().overworld().getDataStorage().computeIfAbsent(MapIndex::load, MapIndex::new, "idcounts")).getFreeAuxValueForMap();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -8,7 +8,7 @@ This patch also adds a chunk status cache on region files (note that
|
|||||||
its only purpose is to cache the status on DISK)
|
its only purpose is to cache the status on DISK)
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index aea216ee07fc733e90bd1170e46d75909467ba94..9f2c9a1e32e1bfbeeda8e8f733f04d7f5347bbe9 100644
|
index 87f055f8338d4ce2f9ff76bdc6c0b7ffc266ce78..9dd2f5d7ea6a1d6744916c403bdd852bb66e45b8 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -87,6 +87,7 @@ import net.minecraft.world.level.chunk.ProtoChunk;
|
@@ -87,6 +87,7 @@ import net.minecraft.world.level.chunk.ProtoChunk;
|
||||||
@ -19,7 +19,7 @@ index aea216ee07fc733e90bd1170e46d75909467ba94..9f2c9a1e32e1bfbeeda8e8f733f04d7f
|
|||||||
import net.minecraft.world.level.entity.ChunkStatusUpdateListener;
|
import net.minecraft.world.level.entity.ChunkStatusUpdateListener;
|
||||||
import net.minecraft.world.level.levelgen.blending.BlendingData;
|
import net.minecraft.world.level.levelgen.blending.BlendingData;
|
||||||
import net.minecraft.world.level.levelgen.structure.StructureStart;
|
import net.minecraft.world.level.levelgen.structure.StructureStart;
|
||||||
@@ -1215,10 +1216,59 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1178,10 +1179,59 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
@Nullable
|
@Nullable
|
||||||
public CompoundTag readChunk(ChunkPos pos) throws IOException {
|
public CompoundTag readChunk(ChunkPos pos) throws IOException {
|
||||||
CompoundTag nbttagcompound = this.read(pos);
|
CompoundTag nbttagcompound = this.read(pos);
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Dont send unnecessary sign update
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index f4444fb23a75d0617438f6b25df7bd401ab65a26..26a15d0b49180651361f336da29a7acccca92483 100644
|
index 240c97682863d78d7c3621131ee1407932ec4599..5efac3203b98870a3f3549baddd5f773de961ee8 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -2856,6 +2856,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2857,6 +2857,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
if (!tileentitysign.isEditable() || !this.player.getUUID().equals(tileentitysign.getPlayerWhoMayEdit())) {
|
if (!tileentitysign.isEditable() || !this.player.getUUID().equals(tileentitysign.getPlayerWhoMayEdit())) {
|
||||||
ServerGamePacketListenerImpl.LOGGER.warn("Player {} just tried to change non-editable sign", this.player.getName().getString());
|
ServerGamePacketListenerImpl.LOGGER.warn("Player {} just tried to change non-editable sign", this.player.getName().getString());
|
||||||
|
@ -7,10 +7,10 @@ Fixes an AssertionError when setting the player's item in hand to null or a new
|
|||||||
Fixes GH-2718
|
Fixes GH-2718
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 26a15d0b49180651361f336da29a7acccca92483..23f06b3a4c7471bd3081c5e9ee78707c26280bfd 100644
|
index 5efac3203b98870a3f3549baddd5f773de961ee8..a0aa9be6ee16109c68c2c75b2a150982f2ab3d62 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -1734,6 +1734,10 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1735,6 +1735,10 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
this.player.getBukkitEntity().updateInventory(); // SPIGOT-2524
|
this.player.getBukkitEntity().updateInventory(); // SPIGOT-2524
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -33,7 +33,7 @@ But for those who are ok with leaving this inconsistent behavior, you may use WA
|
|||||||
It is recommended you regenerate the entities, as these were legit entities, and deserve your love.
|
It is recommended you regenerate the entities, as these were legit entities, and deserve your love.
|
||||||
|
|
||||||
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
index e55647f5fb58aeca93bbb70fa8d06c1e356fe633..0b99f20ec760692a350acd4f78dd060e30d88b50 100644
|
index e4820ece5279a0324f1e7ebf0027dcb054b7ecc3..3e3a48a636c225ec113c1c64f6ffc8a37ad9169e 100644
|
||||||
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
@@ -443,6 +443,45 @@ public class PaperWorldConfig {
|
@@ -443,6 +443,45 @@ public class PaperWorldConfig {
|
||||||
@ -83,7 +83,7 @@ index e55647f5fb58aeca93bbb70fa8d06c1e356fe633..0b99f20ec760692a350acd4f78dd060e
|
|||||||
private void countAllMobsForSpawning() {
|
private void countAllMobsForSpawning() {
|
||||||
countAllMobsForSpawning = getBoolean("count-all-mobs-for-spawning", false);
|
countAllMobsForSpawning = getBoolean("count-all-mobs-for-spawning", false);
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index 9f2c9a1e32e1bfbeeda8e8f733f04d7f5347bbe9..f0c4e98a6d5c448850a72ba90fb68c512fff8310 100644
|
index 9dd2f5d7ea6a1d6744916c403bdd852bb66e45b8..848952c9bd3d91488d964c72bdc77925f904c3fa 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -1,6 +1,7 @@
|
@@ -1,6 +1,7 @@
|
||||||
@ -112,7 +112,7 @@ index 9f2c9a1e32e1bfbeeda8e8f733f04d7f5347bbe9..f0c4e98a6d5c448850a72ba90fb68c51
|
|||||||
import java.util.concurrent.CompletableFuture;
|
import java.util.concurrent.CompletableFuture;
|
||||||
import java.util.concurrent.CompletionException;
|
import java.util.concurrent.CompletionException;
|
||||||
import java.util.concurrent.CompletionStage;
|
import java.util.concurrent.CompletionStage;
|
||||||
@@ -856,6 +861,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -818,6 +823,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
entity.discard();
|
entity.discard();
|
||||||
needsRemoval = true;
|
needsRemoval = true;
|
||||||
}
|
}
|
||||||
@ -120,7 +120,7 @@ index 9f2c9a1e32e1bfbeeda8e8f733f04d7f5347bbe9..f0c4e98a6d5c448850a72ba90fb68c51
|
|||||||
return !needsRemoval;
|
return !needsRemoval;
|
||||||
}));
|
}));
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
@@ -906,6 +912,43 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -868,6 +874,43 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -47,10 +47,10 @@ index 7576047ea9695434ca06ca8fefde0dce68980be8..f71a1401d229b32557f0444ce45cfa47
|
|||||||
this.profiler.push(() -> {
|
this.profiler.push(() -> {
|
||||||
return worldserver + " " + worldserver.dimension().location();
|
return worldserver + " " + worldserver.dimension().location();
|
||||||
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
index e546f212d0228171920a0b28f918020617dfd7ca..d612d6e737d60e10b5a1504f363db214d3589594 100644
|
index 589a9bd9d3bf3cbf88a6efad5f58970a0a4a56c0..83d872044c3db54352847e08bb333ff7e0aee0b0 100644
|
||||||
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
@@ -604,11 +604,12 @@ public final class ItemStack {
|
@@ -603,11 +603,12 @@ public final class ItemStack {
|
||||||
return this.getItem().interactLivingEntity(this, user, entity, hand);
|
return this.getItem().interactLivingEntity(this, user, entity, hand);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -6,10 +6,10 @@ Subject: [PATCH] Optimise IEntityAccess#getPlayerByUUID
|
|||||||
Use the world entity map instead of iterating over all players
|
Use the world entity map instead of iterating over all players
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 68c0f332c176030cd9adfb18a56108ce0931c332..e6408251ed836715f324b1c1e49ff2473f0963ae 100644
|
index fef3846a978dcba95c5dbe5c528ac20cb4f56178..c04402666b9219d508bfd32b4f2e3faea0c9b648 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -382,6 +382,14 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -384,6 +384,14 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
public final com.destroystokyo.paper.io.chunk.ChunkTaskManager asyncChunkTaskManager;
|
public final com.destroystokyo.paper.io.chunk.ChunkTaskManager asyncChunkTaskManager;
|
||||||
// Paper end
|
// Paper end
|
||||||
|
|
||||||
|
@ -14,7 +14,7 @@ Adds flying monsters to control ghast and phantoms
|
|||||||
Adds villagers as separate config
|
Adds villagers as separate config
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index e6408251ed836715f324b1c1e49ff2473f0963ae..db123ef36fc4cb0206349ac696572714b806454c 100644
|
index c04402666b9219d508bfd32b4f2e3faea0c9b648..daeb483b7aa0356447381aec8d92f5dfa500d5b1 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -2,7 +2,6 @@ package net.minecraft.server.level;
|
@@ -2,7 +2,6 @@ package net.minecraft.server.level;
|
||||||
@ -25,15 +25,7 @@ index e6408251ed836715f324b1c1e49ff2473f0963ae..db123ef36fc4cb0206349ac696572714
|
|||||||
import com.google.common.collect.Lists;
|
import com.google.common.collect.Lists;
|
||||||
import com.mojang.datafixers.DataFixer;
|
import com.mojang.datafixers.DataFixer;
|
||||||
import it.unimi.dsi.fastutil.ints.Int2ObjectMap;
|
import it.unimi.dsi.fastutil.ints.Int2ObjectMap;
|
||||||
@@ -11,7 +10,6 @@ import it.unimi.dsi.fastutil.longs.LongSet;
|
@@ -966,17 +965,17 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
import it.unimi.dsi.fastutil.longs.LongSets;
|
|
||||||
import it.unimi.dsi.fastutil.objects.Object2IntMap.Entry;
|
|
||||||
import it.unimi.dsi.fastutil.objects.Object2IntOpenHashMap;
|
|
||||||
-import it.unimi.dsi.fastutil.objects.Object2IntMap;
|
|
||||||
import it.unimi.dsi.fastutil.objects.ObjectIterator;
|
|
||||||
import it.unimi.dsi.fastutil.objects.ObjectLinkedOpenHashSet;
|
|
||||||
import it.unimi.dsi.fastutil.objects.ObjectOpenHashSet;
|
|
||||||
@@ -964,17 +962,17 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
|
||||||
++TimingHistory.entityTicks; // Paper - timings
|
++TimingHistory.entityTicks; // Paper - timings
|
||||||
// Spigot start
|
// Spigot start
|
||||||
co.aikar.timings.Timing timer; // Paper
|
co.aikar.timings.Timing timer; // Paper
|
||||||
@ -55,7 +47,7 @@ index e6408251ed836715f324b1c1e49ff2473f0963ae..db123ef36fc4cb0206349ac696572714
|
|||||||
try {
|
try {
|
||||||
// Paper end - timings
|
// Paper end - timings
|
||||||
entity.setOldPosAndRot();
|
entity.setOldPosAndRot();
|
||||||
@@ -985,9 +983,13 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -987,9 +986,13 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
return Registry.ENTITY_TYPE.getKey(entity.getType()).toString();
|
return Registry.ENTITY_TYPE.getKey(entity.getType()).toString();
|
||||||
});
|
});
|
||||||
gameprofilerfiller.incrementCounter("tickNonPassenger");
|
gameprofilerfiller.incrementCounter("tickNonPassenger");
|
||||||
@ -69,7 +61,7 @@ index e6408251ed836715f324b1c1e49ff2473f0963ae..db123ef36fc4cb0206349ac696572714
|
|||||||
Iterator iterator = entity.getPassengers().iterator();
|
Iterator iterator = entity.getPassengers().iterator();
|
||||||
|
|
||||||
while (iterator.hasNext()) {
|
while (iterator.hasNext()) {
|
||||||
@@ -995,13 +997,18 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -997,13 +1000,18 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
|
|
||||||
this.tickPassenger(entity, entity1);
|
this.tickPassenger(entity, entity1);
|
||||||
}
|
}
|
||||||
@ -89,7 +81,7 @@ index e6408251ed836715f324b1c1e49ff2473f0963ae..db123ef36fc4cb0206349ac696572714
|
|||||||
passenger.setOldPosAndRot();
|
passenger.setOldPosAndRot();
|
||||||
++passenger.tickCount;
|
++passenger.tickCount;
|
||||||
ProfilerFiller gameprofilerfiller = this.getProfiler();
|
ProfilerFiller gameprofilerfiller = this.getProfiler();
|
||||||
@@ -1010,8 +1017,17 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -1012,8 +1020,17 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
return Registry.ENTITY_TYPE.getKey(passenger.getType()).toString();
|
return Registry.ENTITY_TYPE.getKey(passenger.getType()).toString();
|
||||||
});
|
});
|
||||||
gameprofilerfiller.incrementCounter("tickPassenger");
|
gameprofilerfiller.incrementCounter("tickPassenger");
|
||||||
@ -107,7 +99,7 @@ index e6408251ed836715f324b1c1e49ff2473f0963ae..db123ef36fc4cb0206349ac696572714
|
|||||||
gameprofilerfiller.pop();
|
gameprofilerfiller.pop();
|
||||||
Iterator iterator = passenger.getPassengers().iterator();
|
Iterator iterator = passenger.getPassengers().iterator();
|
||||||
|
|
||||||
@@ -1021,6 +1037,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -1023,6 +1040,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
this.tickPassenger(passenger, entity2);
|
this.tickPassenger(passenger, entity2);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -152,7 +144,7 @@ index 9723109a678f9532cd7ca0034d30bc4b450fcab5..09c70c911bfa7be9883b6b83c1e8600f
|
|||||||
movement = this.maybeBackOffFromEdge(movement, movementType);
|
movement = this.maybeBackOffFromEdge(movement, movementType);
|
||||||
Vec3 vec3d1 = this.collide(movement);
|
Vec3 vec3d1 = this.collide(movement);
|
||||||
diff --git a/src/main/java/net/minecraft/world/entity/Mob.java b/src/main/java/net/minecraft/world/entity/Mob.java
|
diff --git a/src/main/java/net/minecraft/world/entity/Mob.java b/src/main/java/net/minecraft/world/entity/Mob.java
|
||||||
index ad2ef9460d85b2182f6af35733daadcedbd15e4c..63b0044a86e6830ccf9d6da8e29989de1402dff4 100644
|
index 7db99b4ad89fd5b38a4767d166caedda86a6188a..341614d0f0df4008a443d9cda400d0c0103af90a 100644
|
||||||
--- a/src/main/java/net/minecraft/world/entity/Mob.java
|
--- a/src/main/java/net/minecraft/world/entity/Mob.java
|
||||||
+++ b/src/main/java/net/minecraft/world/entity/Mob.java
|
+++ b/src/main/java/net/minecraft/world/entity/Mob.java
|
||||||
@@ -206,6 +206,19 @@ public abstract class Mob extends LivingEntity {
|
@@ -206,6 +206,19 @@ public abstract class Mob extends LivingEntity {
|
||||||
@ -311,7 +303,7 @@ index fc47ef685539addfcfc6b5defea8936fbca9f69d..55b44d0391e9b946536f070ea5bbdd19
|
|||||||
super.customServerAiStep();
|
super.customServerAiStep();
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
||||||
index 62f5d137e27b51eaf54d2f84b10bb22f3df216af..77e58257dc3fb517aeca8f8436a4279aa133b570 100644
|
index dac62bad9def39aba8fe7bebf1631eccde9cbf00..615204f7e3095fcd65099a1b752635fa08d44d25 100644
|
||||||
--- a/src/main/java/net/minecraft/world/level/Level.java
|
--- a/src/main/java/net/minecraft/world/level/Level.java
|
||||||
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
||||||
@@ -157,6 +157,12 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
@@ -157,6 +157,12 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||||
|
@ -1126,10 +1126,10 @@ index 7825d6f0fdcfda6212cff8033ec55fb7db236154..2072aa8710f6e285f7c8f76c63b7bcf8
|
|||||||
|
|
||||||
public ClientboundLevelChunkWithLightPacket(FriendlyByteBuf buf) {
|
public ClientboundLevelChunkWithLightPacket(FriendlyByteBuf buf) {
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index fee7c426876ecfc1e6a55afcd4f7c7a503d02902..a3806b29907468f690e386d9147ae18f71f688ef 100644
|
index cb050e658c5c99feb4586c1fba9a57ee3c0d6052..1112ffdaa13c6f0ca41b32127c3fed69f828d6fe 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -976,7 +976,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -938,7 +938,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
completablefuture1.thenAcceptAsync((either) -> {
|
completablefuture1.thenAcceptAsync((either) -> {
|
||||||
either.ifLeft((chunk) -> {
|
either.ifLeft((chunk) -> {
|
||||||
this.tickingGenerated.getAndIncrement();
|
this.tickingGenerated.getAndIncrement();
|
||||||
@ -1138,7 +1138,7 @@ index fee7c426876ecfc1e6a55afcd4f7c7a503d02902..a3806b29907468f690e386d9147ae18f
|
|||||||
|
|
||||||
this.getPlayers(chunkcoordintpair, false).forEach((entityplayer) -> {
|
this.getPlayers(chunkcoordintpair, false).forEach((entityplayer) -> {
|
||||||
this.playerLoadedChunk(entityplayer, mutableobject, chunk);
|
this.playerLoadedChunk(entityplayer, mutableobject, chunk);
|
||||||
@@ -1143,7 +1143,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1105,7 +1105,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
while (objectiterator.hasNext()) {
|
while (objectiterator.hasNext()) {
|
||||||
ChunkHolder playerchunk = (ChunkHolder) objectiterator.next();
|
ChunkHolder playerchunk = (ChunkHolder) objectiterator.next();
|
||||||
ChunkPos chunkcoordintpair = playerchunk.getPos();
|
ChunkPos chunkcoordintpair = playerchunk.getPos();
|
||||||
@ -1146,8 +1146,8 @@ index fee7c426876ecfc1e6a55afcd4f7c7a503d02902..a3806b29907468f690e386d9147ae18f
|
|||||||
+ MutableObject<java.util.Map<Object, ClientboundLevelChunkWithLightPacket>> mutableobject = new MutableObject<>(); // Paper - Anti-Xray - Bypass
|
+ MutableObject<java.util.Map<Object, ClientboundLevelChunkWithLightPacket>> mutableobject = new MutableObject<>(); // Paper - Anti-Xray - Bypass
|
||||||
|
|
||||||
this.getPlayers(chunkcoordintpair, false).forEach((entityplayer) -> {
|
this.getPlayers(chunkcoordintpair, false).forEach((entityplayer) -> {
|
||||||
boolean flag = ChunkMap.isChunkInEuclideanRange(chunkcoordintpair, entityplayer, true, k);
|
SectionPos sectionposition = entityplayer.getLastSectionPos();
|
||||||
@@ -1156,7 +1156,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1119,7 +1119,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1156,7 +1156,7 @@ index fee7c426876ecfc1e6a55afcd4f7c7a503d02902..a3806b29907468f690e386d9147ae18f
|
|||||||
if (player.level == this.level) {
|
if (player.level == this.level) {
|
||||||
if (newWithinViewDistance && !oldWithinViewDistance) {
|
if (newWithinViewDistance && !oldWithinViewDistance) {
|
||||||
ChunkHolder playerchunk = this.getVisibleChunkIfPresent(pos.toLong());
|
ChunkHolder playerchunk = this.getVisibleChunkIfPresent(pos.toLong());
|
||||||
@@ -1679,12 +1679,17 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1639,12 +1639,17 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1179,10 +1179,10 @@ index fee7c426876ecfc1e6a55afcd4f7c7a503d02902..a3806b29907468f690e386d9147ae18f
|
|||||||
List<Entity> list = Lists.newArrayList();
|
List<Entity> list = Lists.newArrayList();
|
||||||
List<Entity> list1 = Lists.newArrayList();
|
List<Entity> list1 = Lists.newArrayList();
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 66552855fa1d2eacc6e722428993bd5b9c07d960..f2c2f128fdb4d66616078dbae0aa85144f0825c3 100644
|
index daeb483b7aa0356447381aec8d92f5dfa500d5b1..6a0eb9313ae62549f2e9220ca00a7ef27d3b2fca 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -391,7 +391,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -394,7 +394,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
// Add env and gen to constructor, WorldData -> WorldDataServer
|
// Add env and gen to constructor, WorldData -> WorldDataServer
|
||||||
public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, ServerLevelData iworlddataserver, ResourceKey<Level> resourcekey, DimensionType dimensionmanager, ChunkProgressListener worldloadlistener, ChunkGenerator chunkgenerator, boolean flag, long i, List<CustomSpawner> list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider) {
|
public ServerLevel(MinecraftServer minecraftserver, Executor executor, LevelStorageSource.LevelStorageAccess convertable_conversionsession, ServerLevelData iworlddataserver, ResourceKey<Level> resourcekey, DimensionType dimensionmanager, ChunkProgressListener worldloadlistener, ChunkGenerator chunkgenerator, boolean flag, long i, List<CustomSpawner> list, boolean flag1, org.bukkit.World.Environment env, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider) {
|
||||||
// Objects.requireNonNull(minecraftserver); // CraftBukkit - decompile error
|
// Objects.requireNonNull(minecraftserver); // CraftBukkit - decompile error
|
||||||
|
@ -8,10 +8,10 @@ Sets tracking range of watermobs to animals instead of misc and simplifies code
|
|||||||
Also ignores Enderdragon, defaulting it to Mojang's setting
|
Also ignores Enderdragon, defaulting it to Mojang's setting
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index a3806b29907468f690e386d9147ae18f71f688ef..8de14a3078017c59b7e3a37894c6c250fa8558b0 100644
|
index 1112ffdaa13c6f0ca41b32127c3fed69f828d6fe..0c82b270c7095c7e4666a8078ecc7142503795c4 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -1867,6 +1867,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1827,6 +1827,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
while (iterator.hasNext()) {
|
while (iterator.hasNext()) {
|
||||||
Entity entity = (Entity) iterator.next();
|
Entity entity = (Entity) iterator.next();
|
||||||
int j = entity.getType().clientTrackingRange() * 16;
|
int j = entity.getType().clientTrackingRange() * 16;
|
||||||
|
@ -305,7 +305,7 @@ index 0000000000000000000000000000000000000000..0bb4aaa546939b67a5d22865190f3047
|
|||||||
+ }
|
+ }
|
||||||
+}
|
+}
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
index fa95322c02f9eee7d2cca06c48c19383d414032f..1eab367b375bb7bf6fadb602f378f6817e519371 100644
|
index 8a6d23475983560644e391607137953803824b4b..5d7ea3dc5b294c1a4f22042796ca9b6d626e866d 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
@@ -644,6 +644,7 @@ public class ServerChunkCache extends ChunkSource {
|
@@ -644,6 +644,7 @@ public class ServerChunkCache extends ChunkSource {
|
||||||
@ -317,10 +317,10 @@ index fa95322c02f9eee7d2cca06c48c19383d414032f..1eab367b375bb7bf6fadb602f378f681
|
|||||||
chunkproviderserver_b.managedBlock(completablefuture::isDone);
|
chunkproviderserver_b.managedBlock(completablefuture::isDone);
|
||||||
com.destroystokyo.paper.io.chunk.ChunkTaskManager.popChunkWait(); // Paper - async chunk debug
|
com.destroystokyo.paper.io.chunk.ChunkTaskManager.popChunkWait(); // Paper - async chunk debug
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index d26e42449a1f75898d06aba384178c0ef30d9aa7..a21300a866dc6c9f7097a894e0506515210090f5 100644
|
index 6a0eb9313ae62549f2e9220ca00a7ef27d3b2fca..c5109445e392cc9d91b2f6c4bab4bb5aea708be2 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -379,6 +379,12 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -382,6 +382,12 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
};
|
};
|
||||||
public final com.destroystokyo.paper.io.chunk.ChunkTaskManager asyncChunkTaskManager;
|
public final com.destroystokyo.paper.io.chunk.ChunkTaskManager asyncChunkTaskManager;
|
||||||
// Paper end
|
// Paper end
|
||||||
|
@ -6,10 +6,10 @@ Subject: [PATCH] Allow overriding the java version check
|
|||||||
-DPaper.IgnoreJavaVersion=true
|
-DPaper.IgnoreJavaVersion=true
|
||||||
|
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
index 8dc72669abcaed848bb872e6eea81cae064e11b9..d302ba1af03bd5921f4da02eaced3659990fc00a 100644
|
index a87a6583a1bd31a276a79c2cfb3c3ca4e749c3dc..e3b2b61e5f030080e481dc00d1086f723b8b97ee 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
@@ -193,7 +193,7 @@ public class Main {
|
@@ -191,7 +191,7 @@ public class Main {
|
||||||
}
|
}
|
||||||
if (javaVersion > 61.0) {
|
if (javaVersion > 61.0) {
|
||||||
System.err.println("Unsupported Java detected (" + javaVersion + "). Only up to Java 17 is supported.");
|
System.err.println("Unsupported Java detected (" + javaVersion + "). Only up to Java 17 is supported.");
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Prevent teleporting dead entities
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 23f06b3a4c7471bd3081c5e9ee78707c26280bfd..97c67fe091b2042a3aa98cc53d5e1ea1163a0966 100644
|
index a0aa9be6ee16109c68c2c75b2a150982f2ab3d62..52448f75d093a4880ce619036af00c8a1772ad80 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -1494,6 +1494,10 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1495,6 +1495,10 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
}
|
}
|
||||||
|
|
||||||
private void internalTeleport(double d0, double d1, double d2, float f, float f1, Set<ClientboundPlayerPositionPacket.RelativeArgument> set, boolean flag) {
|
private void internalTeleport(double d0, double d1, double d2, float f, float f1, Set<ClientboundPlayerPositionPacket.RelativeArgument> set, boolean flag) {
|
||||||
|
@ -7,10 +7,10 @@ Suspected case would be around the technique used in .stopRiding
|
|||||||
Stack will identify any causer of this and warn instead of crashing.
|
Stack will identify any causer of this and warn instead of crashing.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index 262a2182d4d98787d0ae396c5ed0fe79177a177e..4c09411a2537705df10aa314a28fad824b3fbd47 100644
|
index 0583d7ee24f694fbf5138dfae9f7b8c8e4225ab3..27c304d66ecf0bb8d7b5b4343ca207880e14711b 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -1579,6 +1579,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1539,6 +1539,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
|
|
||||||
public void addEntity(Entity entity) {
|
public void addEntity(Entity entity) {
|
||||||
org.spigotmc.AsyncCatcher.catchOp("entity track"); // Spigot
|
org.spigotmc.AsyncCatcher.catchOp("entity track"); // Spigot
|
||||||
@ -26,19 +26,19 @@ index 262a2182d4d98787d0ae396c5ed0fe79177a177e..4c09411a2537705df10aa314a28fad82
|
|||||||
EntityType<?> entitytypes = entity.getType();
|
EntityType<?> entitytypes = entity.getType();
|
||||||
int i = entitytypes.clientTrackingRange() * 16;
|
int i = entitytypes.clientTrackingRange() * 16;
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index a21300a866dc6c9f7097a894e0506515210090f5..3d4961418f3ee7e2d421738d8a8104aac09361d6 100644
|
index c5109445e392cc9d91b2f6c4bab4bb5aea708be2..fda854c603629e3b9facc8ea3577cd8b23d973d9 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -2170,7 +2170,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -2193,7 +2193,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
|
|
||||||
public void onTrackingStart(Entity entity) {
|
public void onTrackingStart(Entity entity) {
|
||||||
org.spigotmc.AsyncCatcher.catchOp("entity register"); // Spigot
|
org.spigotmc.AsyncCatcher.catchOp("entity register"); // Spigot
|
||||||
- ServerLevel.this.getChunkSource().addEntity(entity);
|
- ServerLevel.this.getChunkSource().addEntity(entity);
|
||||||
+ // ServerLevel.this.getChunkSource().addEntity(entity); // Paper - moved down below valid=true
|
+ // ServerLevel.this.getChunkSource().addEntity(entity); // Paper - moved down below valid=true
|
||||||
if (entity instanceof ServerPlayer) {
|
if (entity instanceof ServerPlayer) {
|
||||||
ServerLevel.this.players.add((ServerPlayer) entity);
|
ServerPlayer entityplayer = (ServerPlayer) entity;
|
||||||
ServerLevel.this.updateSleepingPlayerList();
|
|
||||||
@@ -2192,6 +2192,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -2226,6 +2226,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
}
|
}
|
||||||
|
|
||||||
entity.valid = true; // CraftBukkit
|
entity.valid = true; // CraftBukkit
|
||||||
|
@ -262,10 +262,10 @@ index 049eb5693dc98e1d0ec3bd88c73a41fdb2f59bff..0716aaf29f9d76240a0de4ca02daba44
|
|||||||
}
|
}
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index 4c09411a2537705df10aa314a28fad824b3fbd47..62880f8f3ec11fa26e8bdc4cf0a5bd0cf5d01b78 100644
|
index 27c304d66ecf0bb8d7b5b4343ca207880e14711b..6f851c24a67d1b3a349790b0d60f45b23ff93bc6 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -552,6 +552,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -514,6 +514,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
MutableBoolean mutableboolean = new MutableBoolean();
|
MutableBoolean mutableboolean = new MutableBoolean();
|
||||||
|
|
||||||
do {
|
do {
|
||||||
@ -336,7 +336,7 @@ index 8a0e1e7ac1c447d6e9b8807054aaa86820171e7b..264d1202d2efc6aeb89be17f74c0f142
|
|||||||
|
|
||||||
// Paper start
|
// Paper start
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
index d302ba1af03bd5921f4da02eaced3659990fc00a..8a89fdc537a97fa5f1c30a1ae298e0fef95b4543 100644
|
index e3b2b61e5f030080e481dc00d1086f723b8b97ee..a5f8554e2cd43774b1978dce659062d9c7e7dbda 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
@@ -12,6 +12,8 @@ import java.util.logging.Level;
|
@@ -12,6 +12,8 @@ import java.util.logging.Level;
|
||||||
@ -348,7 +348,7 @@ index d302ba1af03bd5921f4da02eaced3659990fc00a..8a89fdc537a97fa5f1c30a1ae298e0fe
|
|||||||
import net.minecrell.terminalconsole.TerminalConsoleAppender; // Paper
|
import net.minecrell.terminalconsole.TerminalConsoleAppender; // Paper
|
||||||
|
|
||||||
public class Main {
|
public class Main {
|
||||||
@@ -164,6 +166,36 @@ public class Main {
|
@@ -162,6 +164,36 @@ public class Main {
|
||||||
|
|
||||||
OptionSet options = null;
|
OptionSet options = null;
|
||||||
|
|
||||||
@ -385,7 +385,7 @@ index d302ba1af03bd5921f4da02eaced3659990fc00a..8a89fdc537a97fa5f1c30a1ae298e0fe
|
|||||||
try {
|
try {
|
||||||
options = parser.parse(args);
|
options = parser.parse(args);
|
||||||
} catch (joptsimple.OptionException ex) {
|
} catch (joptsimple.OptionException ex) {
|
||||||
@@ -263,8 +295,64 @@ public class Main {
|
@@ -261,8 +293,64 @@ public class Main {
|
||||||
} catch (Throwable t) {
|
} catch (Throwable t) {
|
||||||
t.printStackTrace();
|
t.printStackTrace();
|
||||||
}
|
}
|
||||||
|
@ -7,10 +7,10 @@ Prevents pathfinding from spamming failures for things such as
|
|||||||
arrow attacks.
|
arrow attacks.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
diff --git a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
||||||
index e675eca77a0a1718cdaceefa20b026dffdcc5508..5884fb42f0880585dee843b98a6ea470a1508e46 100644
|
index 9fba89aa8b1c257cdc3a63a5bd137320d66a37ec..b06789336098233b642b769b0fd60e740459874c 100644
|
||||||
--- a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
--- a/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
||||||
+++ b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
+++ b/src/main/java/net/minecraft/world/entity/ai/navigation/PathNavigation.java
|
||||||
@@ -193,9 +193,29 @@ public abstract class PathNavigation {
|
@@ -189,9 +189,29 @@ public abstract class PathNavigation {
|
||||||
return this.moveTo(this.createPath(x, y, z, 1), speed);
|
return this.moveTo(this.createPath(x, y, z, 1), speed);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ This successfully fixed a reoccurring and highly reproduceable crash
|
|||||||
for heightmaps.
|
for heightmaps.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index 62880f8f3ec11fa26e8bdc4cf0a5bd0cf5d01b78..394c64e55b3346ccd1721894bfa5899344b38367 100644
|
index 6f851c24a67d1b3a349790b0d60f45b23ff93bc6..4566af37c76cb3a2fe6441451a444a5a3c9914f9 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -174,6 +174,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -174,6 +174,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
@ -36,7 +36,7 @@ index 62880f8f3ec11fa26e8bdc4cf0a5bd0cf5d01b78..394c64e55b3346ccd1721894bfa58993
|
|||||||
// Paper start - distance maps
|
// Paper start - distance maps
|
||||||
private final com.destroystokyo.paper.util.misc.PooledLinkedHashSets<ServerPlayer> pooledLinkedPlayerHashSets = new com.destroystokyo.paper.util.misc.PooledLinkedHashSets<>();
|
private final com.destroystokyo.paper.util.misc.PooledLinkedHashSets<ServerPlayer> pooledLinkedPlayerHashSets = new com.destroystokyo.paper.util.misc.PooledLinkedHashSets<>();
|
||||||
|
|
||||||
@@ -992,7 +993,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -954,7 +955,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
return Either.left(chunk);
|
return Either.left(chunk);
|
||||||
});
|
});
|
||||||
}, (runnable) -> {
|
}, (runnable) -> {
|
||||||
@ -46,7 +46,7 @@ index 62880f8f3ec11fa26e8bdc4cf0a5bd0cf5d01b78..394c64e55b3346ccd1721894bfa58993
|
|||||||
|
|
||||||
completablefuture1.thenAcceptAsync((either) -> {
|
completablefuture1.thenAcceptAsync((either) -> {
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
index 1eab367b375bb7bf6fadb602f378f6817e519371..3c36dfa4f4c6025b02ec455d997f13226de75a64 100644
|
index 5d7ea3dc5b294c1a4f22042796ca9b6d626e866d..41d2027cd4cf8f5de7bd59283361f7f1075356cb 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
@@ -1144,6 +1144,7 @@ public class ServerChunkCache extends ChunkSource {
|
@@ -1144,6 +1144,7 @@ public class ServerChunkCache extends ChunkSource {
|
||||||
|
@ -28,10 +28,10 @@ receives a deterministic result, and should no longer require 1 tick
|
|||||||
delays anymore.
|
delays anymore.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index 394c64e55b3346ccd1721894bfa5899344b38367..fa097f426792f69bfa8376d62ce9285c6a6a7c7f 100644
|
index 4566af37c76cb3a2fe6441451a444a5a3c9914f9..49e612fc0fc4ec991d821d0aa4b41f488dd9f832 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -1588,6 +1588,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1548,6 +1548,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
.printStackTrace();
|
.printStackTrace();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -52,7 +52,7 @@ index cdb0eb8e21299ca70ed7ed5c1195d07f44e47838..6d59a813aa752b4233dbe1894cfc8273
|
|||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
public PlayerNaturallySpawnCreaturesEvent playerNaturallySpawnedEvent; // Paper
|
public PlayerNaturallySpawnCreaturesEvent playerNaturallySpawnedEvent; // Paper
|
||||||
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
index 734f74e4ef178ae4b887bccdd571d9b269b29abe..0a097f5bd7ce5aab3f4fba111d6dfb3d16c229c9 100644
|
index f32fad01c9f1b0642615be896bbf79f73f4656db..f096fbe48d8cc70e3749f48bc9972def42b0068d 100644
|
||||||
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
@@ -276,6 +276,12 @@ public abstract class PlayerList {
|
@@ -276,6 +276,12 @@ public abstract class PlayerList {
|
||||||
|
@ -37,7 +37,7 @@ index be677d437d17b74c6188ce1bd5fc6fdc228fd92f..78fbb4c3e52e900956ae0811aaf934c8
|
|||||||
public static final TicketType<ChunkPos> UNKNOWN = TicketType.create("unknown", Comparator.comparingLong(ChunkPos::toLong), 1);
|
public static final TicketType<ChunkPos> UNKNOWN = TicketType.create("unknown", Comparator.comparingLong(ChunkPos::toLong), 1);
|
||||||
public static final TicketType<Unit> PLUGIN = TicketType.create("plugin", (a, b) -> 0); // CraftBukkit
|
public static final TicketType<Unit> PLUGIN = TicketType.create("plugin", (a, b) -> 0); // CraftBukkit
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 97c67fe091b2042a3aa98cc53d5e1ea1163a0966..f2960cc42295833a788a22becfa28cca76e15930 100644
|
index 52448f75d093a4880ce619036af00c8a1772ad80..bce9986235833b6ee3b470f8d77f2d38ee017620 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -219,6 +219,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -219,6 +219,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
@ -48,7 +48,7 @@ index 97c67fe091b2042a3aa98cc53d5e1ea1163a0966..f2960cc42295833a788a22becfa28cca
|
|||||||
public ServerPlayer player;
|
public ServerPlayer player;
|
||||||
private int tickCount;
|
private int tickCount;
|
||||||
private long keepAliveTime = Util.getMillis();
|
private long keepAliveTime = Util.getMillis();
|
||||||
@@ -293,6 +294,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -294,6 +295,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
|
|
||||||
public void tick() {
|
public void tick() {
|
||||||
@ -64,7 +64,7 @@ index 97c67fe091b2042a3aa98cc53d5e1ea1163a0966..f2960cc42295833a788a22becfa28cca
|
|||||||
this.resetPosition();
|
this.resetPosition();
|
||||||
this.player.xo = this.player.getX();
|
this.player.xo = this.player.getX();
|
||||||
this.player.yo = this.player.getY();
|
this.player.yo = this.player.getY();
|
||||||
@@ -334,7 +344,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -335,7 +345,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
this.lastVehicle = null;
|
this.lastVehicle = null;
|
||||||
this.clientVehicleIsFloating = false;
|
this.clientVehicleIsFloating = false;
|
||||||
this.aboveGroundVehicleTickCount = 0;
|
this.aboveGroundVehicleTickCount = 0;
|
||||||
@ -96,7 +96,7 @@ index bb767f5b626225e70a8af273384bb74dbd21430d..301042e7a0d372a914f27ec0988dd938
|
|||||||
try {
|
try {
|
||||||
ServerPlayer entityplayer1 = this.server.getPlayerList().getPlayerForLogin(this.gameProfile, s); // CraftBukkit - add player reference
|
ServerPlayer entityplayer1 = this.server.getPlayerList().getPlayerForLogin(this.gameProfile, s); // CraftBukkit - add player reference
|
||||||
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
index 0a097f5bd7ce5aab3f4fba111d6dfb3d16c229c9..9b7fcd8be912cd211b6226386bd3340076953442 100644
|
index f096fbe48d8cc70e3749f48bc9972def42b0068d..f3926ee149e5e42d48e33759202d8297e3afd1d4 100644
|
||||||
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
@@ -39,6 +39,7 @@ import net.minecraft.network.protocol.Packet;
|
@@ -39,6 +39,7 @@ import net.minecraft.network.protocol.Packet;
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Validate PickItem Packet and kick for invalid
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index f2960cc42295833a788a22becfa28cca76e15930..bb1244d895c6e5fd668b5a01f507624fdac847f0 100644
|
index bce9986235833b6ee3b470f8d77f2d38ee017620..ed5beda4b159001de4bc8b624d0cb103e257aed3 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -875,7 +875,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -876,7 +876,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
@Override
|
@Override
|
||||||
public void handlePickItem(ServerboundPickItemPacket packet) {
|
public void handlePickItem(ServerboundPickItemPacket packet) {
|
||||||
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
||||||
|
@ -17,10 +17,10 @@ keeping long lived large direct buffers in cache.
|
|||||||
Set system properly at server startup if not set already to help protect from this.
|
Set system properly at server startup if not set already to help protect from this.
|
||||||
|
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
index 8a89fdc537a97fa5f1c30a1ae298e0fef95b4543..461c086d82514d2558d3f472b675305248619d8c 100644
|
index a5f8554e2cd43774b1978dce659062d9c7e7dbda..55bae3efbc630be6d40d415509de4c3e744a5004 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
||||||
@@ -30,6 +30,7 @@ public class Main {
|
@@ -28,6 +28,7 @@ public class Main {
|
||||||
}
|
}
|
||||||
// Paper end
|
// Paper end
|
||||||
// Todo: Installation script
|
// Todo: Installation script
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Reduce allocation of Vec3D by entity tracker
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index fa097f426792f69bfa8376d62ce9285c6a6a7c7f..ce2e8058cebc594def1d257b93d6818c004ad200 100644
|
index 49e612fc0fc4ec991d821d0aa4b41f488dd9f832..62a8482b73796f2c6b76c0e039cb21e799bc9416 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -1866,9 +1866,13 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1826,9 +1826,13 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
public void updatePlayer(ServerPlayer player) {
|
public void updatePlayer(ServerPlayer player) {
|
||||||
org.spigotmc.AsyncCatcher.catchOp("player tracker update"); // Spigot
|
org.spigotmc.AsyncCatcher.catchOp("player tracker update"); // Spigot
|
||||||
if (player != this.entity) {
|
if (player != this.entity) {
|
||||||
|
@ -37,7 +37,7 @@ index 74d674b2684b0db4aa6c183edc6091d53e9ee882..626bcbc6dd013260c3f8b38a1d14e7ba
|
|||||||
|
|
||||||
// CraftBukkit start
|
// CraftBukkit start
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index ce2e8058cebc594def1d257b93d6818c004ad200..f99ad457b9ac0676861d4dbda2ee277cd3631548 100644
|
index 62a8482b73796f2c6b76c0e039cb21e799bc9416..44dc880042dc16a4146c6d3bb35a8eb7b28fd3a4 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -177,21 +177,40 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -177,21 +177,40 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
@ -121,7 +121,7 @@ index ce2e8058cebc594def1d257b93d6818c004ad200..f99ad457b9ac0676861d4dbda2ee277c
|
|||||||
}
|
}
|
||||||
|
|
||||||
protected ChunkGenerator generator() {
|
protected ChunkGenerator generator() {
|
||||||
@@ -504,6 +555,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -466,6 +517,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
} else {
|
} else {
|
||||||
if (holder != null) {
|
if (holder != null) {
|
||||||
holder.setTicketLevel(level);
|
holder.setTicketLevel(level);
|
||||||
@ -129,7 +129,7 @@ index ce2e8058cebc594def1d257b93d6818c004ad200..f99ad457b9ac0676861d4dbda2ee277c
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (holder != null) {
|
if (holder != null) {
|
||||||
@@ -1347,43 +1399,48 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1310,43 +1362,48 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
return this.anyPlayerCloseEnoughForSpawning(pos, false);
|
return this.anyPlayerCloseEnoughForSpawning(pos, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -6,7 +6,7 @@ Subject: [PATCH] Use distance map to optimise entity tracker
|
|||||||
Use the distance map to find candidate players for tracking.
|
Use the distance map to find candidate players for tracking.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index f99ad457b9ac0676861d4dbda2ee277cd3631548..b1ae9e1aa68aaa0435ecdd50d78f82d4e36441bf 100644
|
index 44dc880042dc16a4146c6d3bb35a8eb7b28fd3a4..847c4705f88b999976c9a99519939eb2e71e7f1d 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -67,6 +67,7 @@ import net.minecraft.network.protocol.game.ClientboundSetEntityLinkPacket;
|
@@ -67,6 +67,7 @@ import net.minecraft.network.protocol.game.ClientboundSetEntityLinkPacket;
|
||||||
@ -126,7 +126,7 @@ index f99ad457b9ac0676861d4dbda2ee277cd3631548..b1ae9e1aa68aaa0435ecdd50d78f82d4
|
|||||||
// Paper start - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
|
// Paper start - optimise ChunkMap#anyPlayerCloseEnoughForSpawning
|
||||||
this.playerChunkTickRangeMap = new com.destroystokyo.paper.util.misc.PlayerAreaMap(this.pooledLinkedPlayerHashSets,
|
this.playerChunkTickRangeMap = new com.destroystokyo.paper.util.misc.PlayerAreaMap(this.pooledLinkedPlayerHashSets,
|
||||||
(ServerPlayer player, int rangeX, int rangeZ, int currPosX, int currPosZ, int prevPosX, int prevPosZ,
|
(ServerPlayer player, int rangeX, int rangeZ, int currPosX, int currPosZ, int prevPosX, int prevPosZ,
|
||||||
@@ -1522,17 +1600,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1485,17 +1563,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
}
|
}
|
||||||
|
|
||||||
public void move(ServerPlayer player) {
|
public void move(ServerPlayer player) {
|
||||||
@ -145,7 +145,7 @@ index f99ad457b9ac0676861d4dbda2ee277cd3631548..b1ae9e1aa68aaa0435ecdd50d78f82d4
|
|||||||
|
|
||||||
int i = SectionPos.blockToSectionCoord(player.getBlockX());
|
int i = SectionPos.blockToSectionCoord(player.getBlockX());
|
||||||
int j = SectionPos.blockToSectionCoord(player.getBlockZ());
|
int j = SectionPos.blockToSectionCoord(player.getBlockZ());
|
||||||
@@ -1662,7 +1730,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1622,7 +1690,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
|
|
||||||
entity.tracker = playerchunkmap_entitytracker; // Paper - Fast access to tracker
|
entity.tracker = playerchunkmap_entitytracker; // Paper - Fast access to tracker
|
||||||
this.entityMap.put(entity.getId(), playerchunkmap_entitytracker);
|
this.entityMap.put(entity.getId(), playerchunkmap_entitytracker);
|
||||||
@ -154,7 +154,7 @@ index f99ad457b9ac0676861d4dbda2ee277cd3631548..b1ae9e1aa68aaa0435ecdd50d78f82d4
|
|||||||
if (entity instanceof ServerPlayer) {
|
if (entity instanceof ServerPlayer) {
|
||||||
ServerPlayer entityplayer = (ServerPlayer) entity;
|
ServerPlayer entityplayer = (ServerPlayer) entity;
|
||||||
|
|
||||||
@@ -1706,7 +1774,37 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1666,7 +1734,37 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
entity.tracker = null; // Paper - We're no longer tracked
|
entity.tracker = null; // Paper - We're no longer tracked
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -192,7 +192,7 @@ index f99ad457b9ac0676861d4dbda2ee277cd3631548..b1ae9e1aa68aaa0435ecdd50d78f82d4
|
|||||||
List<ServerPlayer> list = Lists.newArrayList();
|
List<ServerPlayer> list = Lists.newArrayList();
|
||||||
List<ServerPlayer> list1 = this.level.players();
|
List<ServerPlayer> list1 = this.level.players();
|
||||||
ObjectIterator objectiterator = this.entityMap.values().iterator();
|
ObjectIterator objectiterator = this.entityMap.values().iterator();
|
||||||
@@ -1782,23 +1880,31 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1742,23 +1840,31 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
DebugPackets.sendPoiPacketsForChunk(this.level, chunk.getPos());
|
DebugPackets.sendPoiPacketsForChunk(this.level, chunk.getPos());
|
||||||
List<Entity> list = Lists.newArrayList();
|
List<Entity> list = Lists.newArrayList();
|
||||||
List<Entity> list1 = Lists.newArrayList();
|
List<Entity> list1 = Lists.newArrayList();
|
||||||
@ -236,7 +236,7 @@ index f99ad457b9ac0676861d4dbda2ee277cd3631548..b1ae9e1aa68aaa0435ecdd50d78f82d4
|
|||||||
|
|
||||||
Iterator iterator;
|
Iterator iterator;
|
||||||
Entity entity1;
|
Entity entity1;
|
||||||
@@ -1874,6 +1980,42 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1834,6 +1940,42 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
this.lastSectionPos = SectionPos.of(entity);
|
this.lastSectionPos = SectionPos.of(entity);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -280,7 +280,7 @@ index f99ad457b9ac0676861d4dbda2ee277cd3631548..b1ae9e1aa68aaa0435ecdd50d78f82d4
|
|||||||
return object instanceof ChunkMap.TrackedEntity ? ((ChunkMap.TrackedEntity) object).entity.getId() == this.entity.getId() : false;
|
return object instanceof ChunkMap.TrackedEntity ? ((ChunkMap.TrackedEntity) object).entity.getId() == this.entity.getId() : false;
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
|
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||||
index 95fcf31b0ea68312f6c3475c1b4a01ca2b269536..9d4dc7d8d8b6633a3e88a8fc43d3d798683ef1d9 100644
|
index f2be5a99ea4074a72858ddf8f728f5aa81aec59b..b047726aa8672d2298a0bbbcff43ada76969c809 100644
|
||||||
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
||||||
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||||
@@ -51,6 +51,7 @@ import net.minecraft.network.syncher.EntityDataSerializers;
|
@@ -51,6 +51,7 @@ import net.minecraft.network.syncher.EntityDataSerializers;
|
||||||
|
@ -8,10 +8,10 @@ so inline where possible, and avoid the abstraction of the
|
|||||||
Either class.
|
Either class.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index 3fea7315ed3caf7363dd9349f8e977282dfa4c07..00d5060e2a81a7c5fe32f8b9ed8334ff844a70f5 100644
|
index fda854c603629e3b9facc8ea3577cd8b23d973d9..083772c2f71851b5521f0ec5c1ecb872e357e8f7 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -2139,15 +2139,18 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -2162,15 +2162,18 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
}
|
}
|
||||||
|
|
||||||
private boolean isPositionTickingWithEntitiesLoaded(long chunkPos) {
|
private boolean isPositionTickingWithEntitiesLoaded(long chunkPos) {
|
||||||
|
@ -14,10 +14,10 @@ behaviour, we need to move all of this dangerous logic outside
|
|||||||
of the move call and into an appropriate place in the tick method.
|
of the move call and into an appropriate place in the tick method.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 2dcbee2e13141aff6b22e5ba1746c73592d9803c..3cd080bdf22a2fa4e9a1904a0e10325098621d7a 100644
|
index ed5beda4b159001de4bc8b624d0cb103e257aed3..ba2fef9d01d54ad590535532a4f44ab5918d7135 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -1324,6 +1324,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1325,6 +1325,11 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
this.player.move(MoverType.PLAYER, new Vec3(d7, d8, d9));
|
this.player.move(MoverType.PLAYER, new Vec3(d7, d8, d9));
|
||||||
this.player.onGround = packet.isOnGround(); // CraftBukkit - SPIGOT-5810, SPIGOT-5835, SPIGOT-6828: reset by this.player.move
|
this.player.onGround = packet.isOnGround(); // CraftBukkit - SPIGOT-5810, SPIGOT-5835, SPIGOT-6828: reset by this.player.move
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Add and implement PlayerRecipeBookClickEvent
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index fec9551ef74c17be417a326847cc20b0ad54076b..31d99592c06da5c7eb0738210128509870d44d75 100644
|
index ba2fef9d01d54ad590535532a4f44ab5918d7135..3e7d09445ed0679b962a226364b7aedba0fb2d74 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -2773,9 +2773,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2774,9 +2774,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
||||||
this.player.resetLastActionTime();
|
this.player.resetLastActionTime();
|
||||||
if (!this.player.isSpectator() && this.player.containerMenu.containerId == packet.getContainerId() && this.player.containerMenu instanceof RecipeBookMenu) {
|
if (!this.player.isSpectator() && this.player.containerMenu.containerId == packet.getContainerId() && this.player.containerMenu instanceof RecipeBookMenu) {
|
||||||
|
@ -5,7 +5,7 @@ Subject: [PATCH] Add permission for command blocks
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
||||||
index a85b89a0d525e623e154c8b1bea55470d2072dcb..4f1430c71aff4959b1db76200fe750a6c44cef68 100644
|
index d87ee258db769bc072cbdae4298ebc08588b2160..29809127da2961858142bfb5b54c6db1ad4d4f0f 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
--- a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
||||||
@@ -391,7 +391,7 @@ public class ServerPlayerGameMode {
|
@@ -391,7 +391,7 @@ public class ServerPlayerGameMode {
|
||||||
@ -18,10 +18,10 @@ index a85b89a0d525e623e154c8b1bea55470d2072dcb..4f1430c71aff4959b1db76200fe750a6
|
|||||||
return false;
|
return false;
|
||||||
} else if (this.player.blockActionRestricted(this.level, pos, this.gameModeForPlayer)) {
|
} else if (this.player.blockActionRestricted(this.level, pos, this.gameModeForPlayer)) {
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 31d99592c06da5c7eb0738210128509870d44d75..dd29bad410ff74ce3f1f94bc60560cf10b12375f 100644
|
index 3e7d09445ed0679b962a226364b7aedba0fb2d74..62deb7cc804b97528a74600b1918fc88d71e2966 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -786,7 +786,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -787,7 +787,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
||||||
if (!this.server.isCommandBlockEnabled()) {
|
if (!this.server.isCommandBlockEnabled()) {
|
||||||
this.player.sendMessage(new TranslatableComponent("advMode.notEnabled"), Util.NIL_UUID);
|
this.player.sendMessage(new TranslatableComponent("advMode.notEnabled"), Util.NIL_UUID);
|
||||||
@ -30,7 +30,7 @@ index 31d99592c06da5c7eb0738210128509870d44d75..dd29bad410ff74ce3f1f94bc60560cf1
|
|||||||
this.player.sendMessage(new TranslatableComponent("advMode.notAllowed"), Util.NIL_UUID);
|
this.player.sendMessage(new TranslatableComponent("advMode.notAllowed"), Util.NIL_UUID);
|
||||||
} else {
|
} else {
|
||||||
BaseCommandBlock commandblocklistenerabstract = null;
|
BaseCommandBlock commandblocklistenerabstract = null;
|
||||||
@@ -853,7 +853,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -854,7 +854,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
||||||
if (!this.server.isCommandBlockEnabled()) {
|
if (!this.server.isCommandBlockEnabled()) {
|
||||||
this.player.sendMessage(new TranslatableComponent("advMode.notEnabled"), Util.NIL_UUID);
|
this.player.sendMessage(new TranslatableComponent("advMode.notEnabled"), Util.NIL_UUID);
|
||||||
|
@ -94,10 +94,10 @@ index 2f13055a39c26fe12d2c1094103186635e536166..6b0cb662d9163c360035e19c5faad59f
|
|||||||
|
|
||||||
playerlist.sendPlayerPermissionLevel(this);
|
playerlist.sendPlayerPermissionLevel(this);
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 22a10327a690263a8756ffa3098b816c4be20e54..4e73fae8276be9874c61a456a2648828d39dd1cb 100644
|
index 62deb7cc804b97528a74600b1918fc88d71e2966..acffb2c8a4f864da16c65b83a320d8b181bdc2d7 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -3028,7 +3028,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -3029,7 +3029,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
public void handleChangeDifficulty(ServerboundChangeDifficultyPacket packet) {
|
public void handleChangeDifficulty(ServerboundChangeDifficultyPacket packet) {
|
||||||
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
||||||
if (this.player.hasPermissions(2) || this.isSingleplayerOwner()) {
|
if (this.player.hasPermissions(2) || this.isSingleplayerOwner()) {
|
||||||
|
@ -165,7 +165,7 @@ index 626bcbc6dd013260c3f8b38a1d14e7ba35dc1e01..9e96b0465717bfa761289c255fd8d2f1
|
|||||||
for (int i = 0; i < this.futures.length(); ++i) {
|
for (int i = 0; i < this.futures.length(); ++i) {
|
||||||
CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>> completablefuture = (CompletableFuture) this.futures.get(i);
|
CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>> completablefuture = (CompletableFuture) this.futures.get(i);
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index b1ae9e1aa68aaa0435ecdd50d78f82d4e36441bf..9a247feffce5ba08064afaa96053feb22dd52716 100644
|
index 847c4705f88b999976c9a99519939eb2e71e7f1d..1ff5ca11e3550dc730dd9d44acd666119f42898f 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -101,6 +101,7 @@ import net.minecraft.world.level.levelgen.structure.templatesystem.StructureMana
|
@@ -101,6 +101,7 @@ import net.minecraft.world.level.levelgen.structure.templatesystem.StructureMana
|
||||||
@ -176,7 +176,7 @@ index b1ae9e1aa68aaa0435ecdd50d78f82d4e36441bf..9a247feffce5ba08064afaa96053feb2
|
|||||||
import org.apache.commons.lang3.mutable.MutableBoolean;
|
import org.apache.commons.lang3.mutable.MutableBoolean;
|
||||||
import org.apache.commons.lang3.mutable.MutableObject;
|
import org.apache.commons.lang3.mutable.MutableObject;
|
||||||
import org.apache.logging.log4j.LogManager;
|
import org.apache.logging.log4j.LogManager;
|
||||||
@@ -677,6 +678,64 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -639,6 +640,64 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -241,7 +241,7 @@ index b1ae9e1aa68aaa0435ecdd50d78f82d4e36441bf..9a247feffce5ba08064afaa96053feb2
|
|||||||
protected void saveAllChunks(boolean flush) {
|
protected void saveAllChunks(boolean flush) {
|
||||||
if (flush) {
|
if (flush) {
|
||||||
List<ChunkHolder> list = (List) this.visibleChunkMap.values().stream().filter(ChunkHolder::wasAccessibleSinceLastSave).peek(ChunkHolder::refreshAccessibility).collect(Collectors.toList());
|
List<ChunkHolder> list = (List) this.visibleChunkMap.values().stream().filter(ChunkHolder::wasAccessibleSinceLastSave).peek(ChunkHolder::refreshAccessibility).collect(Collectors.toList());
|
||||||
@@ -772,7 +831,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -734,7 +793,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
int l = 0;
|
int l = 0;
|
||||||
ObjectIterator objectiterator = this.visibleChunkMap.values().iterator();
|
ObjectIterator objectiterator = this.visibleChunkMap.values().iterator();
|
||||||
|
|
||||||
@ -250,7 +250,7 @@ index b1ae9e1aa68aaa0435ecdd50d78f82d4e36441bf..9a247feffce5ba08064afaa96053feb2
|
|||||||
if (this.saveChunkIfNeeded((ChunkHolder) objectiterator.next())) {
|
if (this.saveChunkIfNeeded((ChunkHolder) objectiterator.next())) {
|
||||||
++l;
|
++l;
|
||||||
}
|
}
|
||||||
@@ -814,6 +873,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -776,6 +835,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
|
|
||||||
this.level.unload(chunk);
|
this.level.unload(chunk);
|
||||||
}
|
}
|
||||||
@ -258,7 +258,7 @@ index b1ae9e1aa68aaa0435ecdd50d78f82d4e36441bf..9a247feffce5ba08064afaa96053feb2
|
|||||||
|
|
||||||
this.lightEngine.updateChunkStatus(ichunkaccess.getPos());
|
this.lightEngine.updateChunkStatus(ichunkaccess.getPos());
|
||||||
this.lightEngine.tryScheduleUpdate();
|
this.lightEngine.tryScheduleUpdate();
|
||||||
@@ -1211,6 +1271,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1173,6 +1233,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
asyncSaveData, chunk);
|
asyncSaveData, chunk);
|
||||||
|
|
||||||
chunk.setUnsaved(false);
|
chunk.setUnsaved(false);
|
||||||
@ -266,7 +266,7 @@ index b1ae9e1aa68aaa0435ecdd50d78f82d4e36441bf..9a247feffce5ba08064afaa96053feb2
|
|||||||
}
|
}
|
||||||
// Paper end
|
// Paper end
|
||||||
|
|
||||||
@@ -1220,6 +1281,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1182,6 +1243,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
if (!chunk.isUnsaved()) {
|
if (!chunk.isUnsaved()) {
|
||||||
return false;
|
return false;
|
||||||
} else {
|
} else {
|
||||||
@ -275,7 +275,7 @@ index b1ae9e1aa68aaa0435ecdd50d78f82d4e36441bf..9a247feffce5ba08064afaa96053feb2
|
|||||||
ChunkPos chunkcoordintpair = chunk.getPos();
|
ChunkPos chunkcoordintpair = chunk.getPos();
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
index 76b56ea346d843aba482c52c4bfe877fdf0e9225..eb0c5ceb05f37bc653ea0cc91cc778866861688a 100644
|
index 24d0b02264e4cced08a60f36b5c41bb350a1dc60..013c4c428b3cf3c9ad7b9b2ed8b00b410e1804a9 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||||
@@ -825,6 +825,15 @@ public class ServerChunkCache extends ChunkSource {
|
@@ -825,6 +825,15 @@ public class ServerChunkCache extends ChunkSource {
|
||||||
@ -295,10 +295,10 @@ index 76b56ea346d843aba482c52c4bfe877fdf0e9225..eb0c5ceb05f37bc653ea0cc91cc77886
|
|||||||
public void close() throws IOException {
|
public void close() throws IOException {
|
||||||
// CraftBukkit start
|
// CraftBukkit start
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index fe572c99263a44a23e2dc5141295d98973684a88..d21a910f2cca26adedab0732d04c8613e5afcd4f 100644
|
index 083772c2f71851b5521f0ec5c1ecb872e357e8f7..be26327d31a3117cb7a5bf752c49c204738bc91e 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -1055,6 +1055,37 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -1058,6 +1058,37 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
return !this.server.isUnderSpawnProtection(this, pos, player) && this.getWorldBorder().isWithinBounds(pos);
|
return !this.server.isUnderSpawnProtection(this, pos, player) && this.getWorldBorder().isWithinBounds(pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -337,7 +337,7 @@ index fe572c99263a44a23e2dc5141295d98973684a88..d21a910f2cca26adedab0732d04c8613
|
|||||||
ServerChunkCache chunkproviderserver = this.getChunkSource();
|
ServerChunkCache chunkproviderserver = this.getChunkSource();
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
||||||
index 2f13055a39c26fe12d2c1094103186635e536166..4b83617a81db1749faaf49fc3ee77e44846dce1a 100644
|
index 6b0cb662d9163c360035e19c5faad59fc72af3c1..d2280b9e9f107dca890bc76f0c58e7070ce4b38c 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
||||||
@@ -171,6 +171,7 @@ public class ServerPlayer extends Player {
|
@@ -171,6 +171,7 @@ public class ServerPlayer extends Player {
|
||||||
@ -349,7 +349,7 @@ index 2f13055a39c26fe12d2c1094103186635e536166..4b83617a81db1749faaf49fc3ee77e44
|
|||||||
private static final int NEUTRAL_MOB_DEATH_NOTIFICATION_RADII_Y = 10;
|
private static final int NEUTRAL_MOB_DEATH_NOTIFICATION_RADII_Y = 10;
|
||||||
public ServerGamePacketListenerImpl connection;
|
public ServerGamePacketListenerImpl connection;
|
||||||
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
index 9b7fcd8be912cd211b6226386bd3340076953442..a8048e3af5bccb4cabe1ed1bc774aac6b8486bec 100644
|
index f3926ee149e5e42d48e33759202d8297e3afd1d4..8c0faa9ee28943c7750dc33947e3f096b45a2026 100644
|
||||||
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
@@ -556,6 +556,7 @@ public abstract class PlayerList {
|
@@ -556,6 +556,7 @@ public abstract class PlayerList {
|
||||||
@ -385,7 +385,7 @@ index 9b7fcd8be912cd211b6226386bd3340076953442..a8048e3af5bccb4cabe1ed1bc774aac6
|
|||||||
MinecraftTimings.savePlayers.stopTiming(); // Paper
|
MinecraftTimings.savePlayers.stopTiming(); // Paper
|
||||||
return null; }); // Paper - ensure main
|
return null; }); // Paper - ensure main
|
||||||
diff --git a/src/main/java/net/minecraft/world/level/chunk/ChunkAccess.java b/src/main/java/net/minecraft/world/level/chunk/ChunkAccess.java
|
diff --git a/src/main/java/net/minecraft/world/level/chunk/ChunkAccess.java b/src/main/java/net/minecraft/world/level/chunk/ChunkAccess.java
|
||||||
index 0a2f9e93666a5b2123f84e5cf409e4355d3cad86..e3a92021b32aa74a37287504e0e539af5ec8216f 100644
|
index a657b41263739b454617db5d7cb9e5cdd94f44ec..6d5f867989eb786683e81e2d270ed0b085c1f072 100644
|
||||||
--- a/src/main/java/net/minecraft/world/level/chunk/ChunkAccess.java
|
--- a/src/main/java/net/minecraft/world/level/chunk/ChunkAccess.java
|
||||||
+++ b/src/main/java/net/minecraft/world/level/chunk/ChunkAccess.java
|
+++ b/src/main/java/net/minecraft/world/level/chunk/ChunkAccess.java
|
||||||
@@ -457,6 +457,7 @@ public abstract class ChunkAccess implements BlockGetter, BiomeManager.NoiseBiom
|
@@ -457,6 +457,7 @@ public abstract class ChunkAccess implements BlockGetter, BiomeManager.NoiseBiom
|
||||||
@ -397,7 +397,7 @@ index 0a2f9e93666a5b2123f84e5cf409e4355d3cad86..e3a92021b32aa74a37287504e0e539af
|
|||||||
// CraftBukkit start - decompile error
|
// CraftBukkit start - decompile error
|
||||||
public static record TicksToSave(SerializableTickContainer<Block> blocks, SerializableTickContainer<Fluid> fluids) {
|
public static record TicksToSave(SerializableTickContainer<Block> blocks, SerializableTickContainer<Fluid> fluids) {
|
||||||
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
index f7388d37b467d1c153fcf8002eedd20417f93d52..ed22486dafcecae454a932c1354cf26c31e95636 100644
|
index d70bdf21dd7bdf01b34d0fd38e79f9b386ec1fcc..6eaba33b7730d66bf631b6d5c6a7080f9f019f8b 100644
|
||||||
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
@@ -87,6 +87,12 @@ public class LevelChunk extends ChunkAccess {
|
@@ -87,6 +87,12 @@ public class LevelChunk extends ChunkAccess {
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Update itemstack legacy name and lore
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
index 57a9106005413e6767f0fe291c463742ba9afb21..31439467f1730d96712e53a8e27892dfce017c70 100644
|
index 83d872044c3db54352847e08bb333ff7e0aee0b0..6dd68c17d5365fecfbd15cfaac837e0869cdce2e 100644
|
||||||
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
@@ -169,6 +169,44 @@ public final class ItemStack {
|
@@ -168,6 +168,44 @@ public final class ItemStack {
|
||||||
list.sort((Comparator<? super net.minecraft.nbt.Tag>) enchantSorter); // Paper
|
list.sort((Comparator<? super net.minecraft.nbt.Tag>) enchantSorter); // Paper
|
||||||
} catch (Exception ignored) {}
|
} catch (Exception ignored) {}
|
||||||
}
|
}
|
||||||
@ -21,7 +21,7 @@ index 57a9106005413e6767f0fe291c463742ba9afb21..31439467f1730d96712e53a8e27892df
|
|||||||
+ if (json != null && json.contains("\u00A7")) {
|
+ if (json != null && json.contains("\u00A7")) {
|
||||||
+ try {
|
+ try {
|
||||||
+ display.put("Name", convert(json));
|
+ display.put("Name", convert(json));
|
||||||
+ } catch (JsonParseException jsonparseexception) {
|
+ } catch (com.google.gson.JsonParseException jsonparseexception) {
|
||||||
+ display.remove("Name");
|
+ display.remove("Name");
|
||||||
+ }
|
+ }
|
||||||
+ }
|
+ }
|
||||||
@ -33,7 +33,7 @@ index 57a9106005413e6767f0fe291c463742ba9afb21..31439467f1730d96712e53a8e27892df
|
|||||||
+ if (json != null && json.contains("\u00A7")) { // Only try if it has legacy in the unparsed json
|
+ if (json != null && json.contains("\u00A7")) { // Only try if it has legacy in the unparsed json
|
||||||
+ try {
|
+ try {
|
||||||
+ list.set(index, convert(json));
|
+ list.set(index, convert(json));
|
||||||
+ } catch (JsonParseException e) {
|
+ } catch (com.google.gson.JsonParseException e) {
|
||||||
+ list.set(index, net.minecraft.nbt.StringTag.valueOf(org.bukkit.craftbukkit.util.CraftChatMessage.toJSON(new TextComponent(""))));
|
+ list.set(index, net.minecraft.nbt.StringTag.valueOf(org.bukkit.craftbukkit.util.CraftChatMessage.toJSON(new TextComponent(""))));
|
||||||
+ }
|
+ }
|
||||||
+ }
|
+ }
|
||||||
@ -53,7 +53,7 @@ index 57a9106005413e6767f0fe291c463742ba9afb21..31439467f1730d96712e53a8e27892df
|
|||||||
// Paper end
|
// Paper end
|
||||||
|
|
||||||
public ItemStack(ItemLike item) {
|
public ItemStack(ItemLike item) {
|
||||||
@@ -215,6 +253,7 @@ public final class ItemStack {
|
@@ -214,6 +252,7 @@ public final class ItemStack {
|
||||||
this.tag = nbttagcompound.getCompound("tag").copy();
|
this.tag = nbttagcompound.getCompound("tag").copy();
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
this.processEnchantOrder(this.tag); // Paper
|
this.processEnchantOrder(this.tag); // Paper
|
||||||
|
@ -360,7 +360,7 @@ index 9e96b0465717bfa761289c255fd8d2f1df1be3d8..87271552aa85626f22f7f8569c8fb48f
|
|||||||
return this.isEntityTickingReady;
|
return this.isEntityTickingReady;
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index 9a247feffce5ba08064afaa96053feb22dd52716..807914712faf6dc98ff138ffa31b08376afcff8e 100644
|
index 1ff5ca11e3550dc730dd9d44acd666119f42898f..0b8b813d329aa1de912057ddeb52c0442f262f13 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -128,6 +128,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -128,6 +128,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
@ -425,7 +425,7 @@ index 9a247feffce5ba08064afaa96053feb22dd52716..807914712faf6dc98ff138ffa31b0837
|
|||||||
// Paper start
|
// Paper start
|
||||||
public void updatePlayerMobTypeMap(Entity entity) {
|
public void updatePlayerMobTypeMap(Entity entity) {
|
||||||
if (!this.level.paperConfig.perPlayerMobSpawns) {
|
if (!this.level.paperConfig.perPlayerMobSpawns) {
|
||||||
@@ -555,6 +596,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -517,6 +558,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
List<ChunkHolder> list1 = new ArrayList();
|
List<ChunkHolder> list1 = new ArrayList();
|
||||||
int j = centerChunk.x;
|
int j = centerChunk.x;
|
||||||
int k = centerChunk.z;
|
int k = centerChunk.z;
|
||||||
@ -433,7 +433,7 @@ index 9a247feffce5ba08064afaa96053feb22dd52716..807914712faf6dc98ff138ffa31b0837
|
|||||||
|
|
||||||
for (int l = -margin; l <= margin; ++l) {
|
for (int l = -margin; l <= margin; ++l) {
|
||||||
for (int i1 = -margin; i1 <= margin; ++i1) {
|
for (int i1 = -margin; i1 <= margin; ++i1) {
|
||||||
@@ -573,6 +615,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -535,6 +577,14 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
|
|
||||||
ChunkStatus chunkstatus = (ChunkStatus) distanceToStatus.apply(j1);
|
ChunkStatus chunkstatus = (ChunkStatus) distanceToStatus.apply(j1);
|
||||||
CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>> completablefuture = playerchunk.getOrScheduleFuture(chunkstatus, this);
|
CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>> completablefuture = playerchunk.getOrScheduleFuture(chunkstatus, this);
|
||||||
@ -448,7 +448,7 @@ index 9a247feffce5ba08064afaa96053feb22dd52716..807914712faf6dc98ff138ffa31b0837
|
|||||||
|
|
||||||
list1.add(playerchunk);
|
list1.add(playerchunk);
|
||||||
list.add(completablefuture);
|
list.add(completablefuture);
|
||||||
@@ -913,11 +963,19 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -875,11 +925,19 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
if (requiredStatus == ChunkStatus.EMPTY) {
|
if (requiredStatus == ChunkStatus.EMPTY) {
|
||||||
return this.scheduleChunkLoad(chunkcoordintpair);
|
return this.scheduleChunkLoad(chunkcoordintpair);
|
||||||
} else {
|
} else {
|
||||||
@ -469,7 +469,7 @@ index 9a247feffce5ba08064afaa96053feb22dd52716..807914712faf6dc98ff138ffa31b0837
|
|||||||
|
|
||||||
if (optional.isPresent() && ((ChunkAccess) optional.get()).getStatus().isOrAfter(requiredStatus)) {
|
if (optional.isPresent() && ((ChunkAccess) optional.get()).getStatus().isOrAfter(requiredStatus)) {
|
||||||
CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>> completablefuture = requiredStatus.load(this.level, this.structureManager, this.lightEngine, (ichunkaccess) -> {
|
CompletableFuture<Either<ChunkAccess, ChunkHolder.ChunkLoadingFailure>> completablefuture = requiredStatus.load(this.level, this.structureManager, this.lightEngine, (ichunkaccess) -> {
|
||||||
@@ -929,6 +987,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -891,6 +949,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
} else {
|
} else {
|
||||||
return this.scheduleChunkGeneration(holder, requiredStatus);
|
return this.scheduleChunkGeneration(holder, requiredStatus);
|
||||||
}
|
}
|
||||||
@ -477,7 +477,7 @@ index 9a247feffce5ba08064afaa96053feb22dd52716..807914712faf6dc98ff138ffa31b0837
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -985,14 +1044,24 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -947,14 +1006,24 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
};
|
};
|
||||||
|
|
||||||
CompletableFuture<CompoundTag> chunkSaveFuture = this.level.asyncChunkTaskManager.getChunkSaveFuture(pos.x, pos.z);
|
CompletableFuture<CompoundTag> chunkSaveFuture = this.level.asyncChunkTaskManager.getChunkSaveFuture(pos.x, pos.z);
|
||||||
@ -507,7 +507,7 @@ index 9a247feffce5ba08064afaa96053feb22dd52716..807914712faf6dc98ff138ffa31b0837
|
|||||||
return ret;
|
return ret;
|
||||||
// Paper end
|
// Paper end
|
||||||
}
|
}
|
||||||
@@ -1044,7 +1113,10 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1006,7 +1075,10 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
this.releaseLightTicket(chunkcoordintpair);
|
this.releaseLightTicket(chunkcoordintpair);
|
||||||
return CompletableFuture.completedFuture(Either.right(playerchunk_failure));
|
return CompletableFuture.completedFuture(Either.right(playerchunk_failure));
|
||||||
});
|
});
|
||||||
@ -519,7 +519,7 @@ index 9a247feffce5ba08064afaa96053feb22dd52716..807914712faf6dc98ff138ffa31b0837
|
|||||||
}
|
}
|
||||||
|
|
||||||
protected void releaseLightTicket(ChunkPos pos) {
|
protected void releaseLightTicket(ChunkPos pos) {
|
||||||
@@ -1128,7 +1200,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1090,7 +1162,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
long i = chunkHolder.getPos().toLong();
|
long i = chunkHolder.getPos().toLong();
|
||||||
|
|
||||||
Objects.requireNonNull(chunkHolder);
|
Objects.requireNonNull(chunkHolder);
|
||||||
@ -1164,7 +1164,7 @@ index 96de46b0b1b4bd69b1afa689083ec57ffb07120e..40e8c0b36ec521a8850782f349eb29b4
|
|||||||
public float yRotO;
|
public float yRotO;
|
||||||
public float xRotO;
|
public float xRotO;
|
||||||
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
index 9cb5e608ace42acd1a5335b70d049a88f3918de5..b69ce653592575252a58cdd47052ab13fcb80f1c 100644
|
index 6eaba33b7730d66bf631b6d5c6a7080f9f019f8b..8e03e63a00dd242791ba0d5a8a17922227b16165 100644
|
||||||
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
|
||||||
@@ -141,7 +141,7 @@ public class LevelChunk extends ChunkAccess {
|
@@ -141,7 +141,7 @@ public class LevelChunk extends ChunkAccess {
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Move range check for block placing up
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 0bcafeb8008bd2556bcdc556b17d00ff936d7aa9..26bd27d3dd6e99488fd0a77257866b1eb1b191b8 100644
|
index acffb2c8a4f864da16c65b83a320d8b181bdc2d7..938e6ee89bdb398dc4e2ce1682727c0e63f28c26 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -1666,6 +1666,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1667,6 +1667,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
}
|
}
|
||||||
// Spigot end
|
// Spigot end
|
||||||
|
|
||||||
@ -23,7 +23,7 @@ index 0bcafeb8008bd2556bcdc556b17d00ff936d7aa9..26bd27d3dd6e99488fd0a77257866b1e
|
|||||||
@Override
|
@Override
|
||||||
public void handleUseItemOn(ServerboundUseItemOnPacket packet) {
|
public void handleUseItemOn(ServerboundUseItemOnPacket packet) {
|
||||||
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
||||||
@@ -1678,17 +1686,22 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1679,17 +1687,22 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
BlockPos blockposition = movingobjectpositionblock.getBlockPos();
|
BlockPos blockposition = movingobjectpositionblock.getBlockPos();
|
||||||
Direction enumdirection = movingobjectpositionblock.getDirection();
|
Direction enumdirection = movingobjectpositionblock.getDirection();
|
||||||
|
|
||||||
|
@ -5,7 +5,7 @@ Subject: [PATCH] Brand support
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 2ab8a56276997499457d8c6559b3a448e9072674..86c30ab5e690a7e12a0691fc4b5dcee8b7971cb8 100644
|
index 938e6ee89bdb398dc4e2ce1682727c0e63f28c26..4065a1cb1b4b68aa3ff9f1c3e86c270e1509f93f 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -4,6 +4,7 @@ import com.google.common.collect.Lists;
|
@@ -4,6 +4,7 @@ import com.google.common.collect.Lists;
|
||||||
@ -33,7 +33,7 @@ index 2ab8a56276997499457d8c6559b3a448e9072674..86c30ab5e690a7e12a0691fc4b5dcee8
|
|||||||
public ServerGamePacketListenerImpl(MinecraftServer server, Connection connection, ServerPlayer player) {
|
public ServerGamePacketListenerImpl(MinecraftServer server, Connection connection, ServerPlayer player) {
|
||||||
this.server = server;
|
this.server = server;
|
||||||
this.connection = connection;
|
this.connection = connection;
|
||||||
@@ -2996,6 +3000,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2997,6 +3001,8 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
private static final ResourceLocation CUSTOM_REGISTER = new ResourceLocation("register");
|
private static final ResourceLocation CUSTOM_REGISTER = new ResourceLocation("register");
|
||||||
private static final ResourceLocation CUSTOM_UNREGISTER = new ResourceLocation("unregister");
|
private static final ResourceLocation CUSTOM_UNREGISTER = new ResourceLocation("unregister");
|
||||||
|
|
||||||
@ -42,7 +42,7 @@ index 2ab8a56276997499457d8c6559b3a448e9072674..86c30ab5e690a7e12a0691fc4b5dcee8
|
|||||||
@Override
|
@Override
|
||||||
public void handleCustomPayload(ServerboundCustomPayloadPacket packet) {
|
public void handleCustomPayload(ServerboundCustomPayloadPacket packet) {
|
||||||
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
||||||
@@ -3023,6 +3029,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -3024,6 +3030,15 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
try {
|
try {
|
||||||
byte[] data = new byte[packet.data.readableBytes()];
|
byte[] data = new byte[packet.data.readableBytes()];
|
||||||
packet.data.readBytes(data);
|
packet.data.readBytes(data);
|
||||||
@ -58,7 +58,7 @@ index 2ab8a56276997499457d8c6559b3a448e9072674..86c30ab5e690a7e12a0691fc4b5dcee8
|
|||||||
this.cserver.getMessenger().dispatchIncomingMessage(this.player.getBukkitEntity(), packet.identifier.toString(), data);
|
this.cserver.getMessenger().dispatchIncomingMessage(this.player.getBukkitEntity(), packet.identifier.toString(), data);
|
||||||
} catch (Exception ex) {
|
} catch (Exception ex) {
|
||||||
ServerGamePacketListenerImpl.LOGGER.error("Couldn\'t dispatch custom payload", ex);
|
ServerGamePacketListenerImpl.LOGGER.error("Couldn\'t dispatch custom payload", ex);
|
||||||
@@ -3032,6 +3047,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -3033,6 +3048,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Fix SpawnChangeEvent not firing for all use-cases
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index d21a910f2cca26adedab0732d04c8613e5afcd4f..ad4904aff037fd916ef5481dc5516781ad078330 100644
|
index be26327d31a3117cb7a5bf752c49c204738bc91e..230ee6dd71e55921960a81d7b3aedbc804f785e5 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -1720,6 +1720,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -1743,6 +1743,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
//ChunkCoordIntPair chunkcoordintpair = new ChunkCoordIntPair(new BlockPosition(this.worldData.a(), 0, this.worldData.c()));
|
//ChunkCoordIntPair chunkcoordintpair = new ChunkCoordIntPair(new BlockPosition(this.worldData.a(), 0, this.worldData.c()));
|
||||||
|
|
||||||
this.levelData.setSpawn(pos, angle);
|
this.levelData.setSpawn(pos, angle);
|
||||||
|
@ -54,10 +54,10 @@ index 87271552aa85626f22f7f8569c8fb48fe4b30bf3..80aae4303e011dad13ce818136f0383e
|
|||||||
public ChunkHolder(ChunkPos pos, int level, LevelHeightAccessor world, LevelLightEngine lightingProvider, ChunkHolder.LevelChangeListener levelUpdateListener, ChunkHolder.PlayerProvider playersWatchingChunkProvider) {
|
public ChunkHolder(ChunkPos pos, int level, LevelHeightAccessor world, LevelLightEngine lightingProvider, ChunkHolder.LevelChangeListener levelUpdateListener, ChunkHolder.PlayerProvider playersWatchingChunkProvider) {
|
||||||
this.futures = new AtomicReferenceArray(ChunkHolder.CHUNK_STATUSES.size());
|
this.futures = new AtomicReferenceArray(ChunkHolder.CHUNK_STATUSES.size());
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
index 807914712faf6dc98ff138ffa31b08376afcff8e..a1b667084f710230d3f94ee0e5f5750de1d71e29 100644
|
index 0b8b813d329aa1de912057ddeb52c0442f262f13..a97bf06a0e8ba1cd612f7e8be2585bfdfbdfa969 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
|
||||||
@@ -674,7 +674,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -636,7 +636,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
return either.mapLeft((list) -> {
|
return either.mapLeft((list) -> {
|
||||||
return (LevelChunk) list.get(list.size() / 2);
|
return (LevelChunk) list.get(list.size() / 2);
|
||||||
});
|
});
|
||||||
@ -66,7 +66,7 @@ index 807914712faf6dc98ff138ffa31b08376afcff8e..a1b667084f710230d3f94ee0e5f5750d
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Nullable
|
@Nullable
|
||||||
@@ -1084,6 +1084,12 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
@@ -1046,6 +1046,12 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
|
||||||
return "chunkGenerate " + requiredStatus.getName();
|
return "chunkGenerate " + requiredStatus.getName();
|
||||||
});
|
});
|
||||||
Executor executor = (runnable) -> {
|
Executor executor = (runnable) -> {
|
||||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] PortalCreateEvent needs to know its entity
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
index 2fdd19ec71bdf92e317196eab5426760d9c57278..a0d1877e9b5229bc04dba72fb629e26d25e85bfb 100644
|
index 6dd68c17d5365fecfbd15cfaac837e0869cdce2e..9afecaa4cfa0466abb691977e55bcddb64b7feda 100644
|
||||||
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
--- a/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java
|
||||||
@@ -410,7 +410,7 @@ public final class ItemStack {
|
@@ -409,7 +409,7 @@ public final class ItemStack {
|
||||||
net.minecraft.world.level.block.state.BlockState block = world.getBlockState(newblockposition);
|
net.minecraft.world.level.block.state.BlockState block = world.getBlockState(newblockposition);
|
||||||
|
|
||||||
if (!(block.getBlock() instanceof BaseEntityBlock)) { // Containers get placed automatically
|
if (!(block.getBlock() instanceof BaseEntityBlock)) { // Containers get placed automatically
|
||||||
|
@ -9,10 +9,10 @@ as this is how Vanilla teleports entities.
|
|||||||
Cancel any pending motion when teleported.
|
Cancel any pending motion when teleported.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 86c30ab5e690a7e12a0691fc4b5dcee8b7971cb8..aacfc474223bbbaca2182eeb9bcffd5a941e7b06 100644
|
index 4065a1cb1b4b68aa3ff9f1c3e86c270e1509f93f..70c1f6d91d1792ef713e46b93897a94fc50e08eb 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -680,7 +680,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -681,7 +681,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
public void handleAcceptTeleportPacket(ServerboundAcceptTeleportationPacket packet) {
|
public void handleAcceptTeleportPacket(ServerboundAcceptTeleportationPacket packet) {
|
||||||
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
||||||
if (packet.getId() == this.awaitingTeleport && this.awaitingPositionFromClient != null) { // CraftBukkit
|
if (packet.getId() == this.awaitingTeleport && this.awaitingPositionFromClient != null) { // CraftBukkit
|
||||||
@ -21,7 +21,7 @@ index 86c30ab5e690a7e12a0691fc4b5dcee8b7971cb8..aacfc474223bbbaca2182eeb9bcffd5a
|
|||||||
this.lastGoodX = this.awaitingPositionFromClient.x;
|
this.lastGoodX = this.awaitingPositionFromClient.x;
|
||||||
this.lastGoodY = this.awaitingPositionFromClient.y;
|
this.lastGoodY = this.awaitingPositionFromClient.y;
|
||||||
this.lastGoodZ = this.awaitingPositionFromClient.z;
|
this.lastGoodZ = this.awaitingPositionFromClient.z;
|
||||||
@@ -1554,7 +1554,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1555,7 +1555,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
|
|
||||||
this.awaitingTeleportTime = this.tickCount;
|
this.awaitingTeleportTime = this.tickCount;
|
||||||
|
@ -6,10 +6,10 @@ Subject: [PATCH] Extend block drop capture to capture all items added to the
|
|||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
index ad4904aff037fd916ef5481dc5516781ad078330..00a64168592ad2c8cecb2fc844d81e47610601ad 100644
|
index 230ee6dd71e55921960a81d7b3aedbc804f785e5..1a79c9767dd6e207653d59532b00742a1d85f314 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||||
@@ -1257,6 +1257,13 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
@@ -1260,6 +1260,13 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||||
// WorldServer.LOGGER.warn("Tried to add entity {} but it was marked as removed already", EntityTypes.getKey(entity.getType())); // CraftBukkit
|
// WorldServer.LOGGER.warn("Tried to add entity {} but it was marked as removed already", EntityTypes.getKey(entity.getType())); // CraftBukkit
|
||||||
return false;
|
return false;
|
||||||
} else {
|
} else {
|
||||||
@ -24,7 +24,7 @@ index ad4904aff037fd916ef5481dc5516781ad078330..00a64168592ad2c8cecb2fc844d81e47
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
||||||
index 4f1430c71aff4959b1db76200fe750a6c44cef68..01b19225193ef3a3f69291f0357c096fc9e71618 100644
|
index 29809127da2961858142bfb5b54c6db1ad4d4f0f..aa065f732637b6220fd7328b4d5bc6005ee31832 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
--- a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
|
||||||
@@ -423,10 +423,12 @@ public class ServerPlayerGameMode {
|
@@ -423,10 +423,12 @@ public class ServerPlayerGameMode {
|
||||||
|
@ -6,10 +6,10 @@ Subject: [PATCH] Fix for large move vectors crashing server
|
|||||||
Check movement distance also based on current position.
|
Check movement distance also based on current position.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 2074760beee6fdc2e94bb0f5dcfbae7b5813e8c9..2dd47eab63cf9322a5844e748709e220272a8cfe 100644
|
index 70c1f6d91d1792ef713e46b93897a94fc50e08eb..5313b035870fc39af214b18383a496b2fccdc1f4 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -505,20 +505,31 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -506,20 +506,31 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
if (entity != this.player && entity.getControllingPassenger() == this.player && entity == this.lastVehicle) {
|
if (entity != this.player && entity.getControllingPassenger() == this.player && entity == this.lastVehicle) {
|
||||||
ServerLevel worldserver = this.player.getLevel();
|
ServerLevel worldserver = this.player.getLevel();
|
||||||
@ -49,7 +49,7 @@ index 2074760beee6fdc2e94bb0f5dcfbae7b5813e8c9..2dd47eab63cf9322a5844e748709e220
|
|||||||
|
|
||||||
// CraftBukkit start - handle custom speeds and skipped ticks
|
// CraftBukkit start - handle custom speeds and skipped ticks
|
||||||
this.allowedPlayerTicks += (System.currentTimeMillis() / 50) - this.lastTick;
|
this.allowedPlayerTicks += (System.currentTimeMillis() / 50) - this.lastTick;
|
||||||
@@ -561,9 +572,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -562,9 +573,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
boolean flag = worldserver.noCollision(entity, entity.getBoundingBox().deflate(0.0625D));
|
boolean flag = worldserver.noCollision(entity, entity.getBoundingBox().deflate(0.0625D));
|
||||||
|
|
||||||
@ -62,7 +62,7 @@ index 2074760beee6fdc2e94bb0f5dcfbae7b5813e8c9..2dd47eab63cf9322a5844e748709e220
|
|||||||
entity.move(MoverType.PLAYER, new Vec3(d6, d7, d8));
|
entity.move(MoverType.PLAYER, new Vec3(d6, d7, d8));
|
||||||
double d11 = d7;
|
double d11 = d7;
|
||||||
|
|
||||||
@@ -1231,14 +1242,25 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1232,14 +1243,25 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
float prevPitch = this.player.getXRot();
|
float prevPitch = this.player.getXRot();
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
double d3 = this.player.getX(); final double toX = d3; // Paper - OBFHELPER
|
double d3 = this.player.getX(); final double toX = d3; // Paper - OBFHELPER
|
||||||
@ -90,7 +90,7 @@ index 2074760beee6fdc2e94bb0f5dcfbae7b5813e8c9..2dd47eab63cf9322a5844e748709e220
|
|||||||
|
|
||||||
if (this.player.isSleeping()) {
|
if (this.player.isSleeping()) {
|
||||||
if (d11 > 1.0D) {
|
if (d11 > 1.0D) {
|
||||||
@@ -1290,9 +1312,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -1291,9 +1313,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
AABB axisalignedbb = this.player.getBoundingBox();
|
AABB axisalignedbb = this.player.getBoundingBox();
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ index d30bc3f1da336b421d9a42070184e07169dd14e4..a6eadf71957b37e2acc5d09f0ce4ee96
|
|||||||
Connection.LOGGER.debug("Failed to sent packet", throwable);
|
Connection.LOGGER.debug("Failed to sent packet", throwable);
|
||||||
ConnectionProtocol enumprotocol = this.getCurrentProtocol();
|
ConnectionProtocol enumprotocol = this.getCurrentProtocol();
|
||||||
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
||||||
index 968b8180f92066a43f06bff8dd1d49b03bd08f5b..257942084d988cac5f87ff998ea637fa263a3fe9 100644
|
index c68b95ef0d4c3e0d942e61bfccf23a00d0d8afd9..57ca53876941faf6a1cbefd6e0382ee0ce2e678f 100644
|
||||||
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
||||||
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
|
||||||
@@ -257,6 +257,7 @@ public class ServerPlayer extends Player {
|
@@ -257,6 +257,7 @@ public class ServerPlayer extends Player {
|
||||||
@ -37,10 +37,10 @@ index 968b8180f92066a43f06bff8dd1d49b03bd08f5b..257942084d988cac5f87ff998ea637fa
|
|||||||
public ServerPlayer(MinecraftServer server, ServerLevel world, GameProfile profile) {
|
public ServerPlayer(MinecraftServer server, ServerLevel world, GameProfile profile) {
|
||||||
super(world, world.getSharedSpawnPos(), world.getSharedSpawnAngle(), profile);
|
super(world, world.getSharedSpawnPos(), world.getSharedSpawnAngle(), profile);
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 2dd47eab63cf9322a5844e748709e220272a8cfe..c0a685cfe62aeda3583763ecc1e4fa127f8fb0d4 100644
|
index 5313b035870fc39af214b18383a496b2fccdc1f4..f62f2c0bf9a9d280ed68de8c1afc382b561f31ec 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -442,6 +442,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -443,6 +443,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
final Component ichatbasecomponent = PaperAdventure.asVanilla(event.reason()); // Paper - Adventure
|
final Component ichatbasecomponent = PaperAdventure.asVanilla(event.reason()); // Paper - Adventure
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
|
|
||||||
@ -49,7 +49,7 @@ index 2dd47eab63cf9322a5844e748709e220272a8cfe..c0a685cfe62aeda3583763ecc1e4fa12
|
|||||||
this.connection.disconnect(ichatbasecomponent);
|
this.connection.disconnect(ichatbasecomponent);
|
||||||
});
|
});
|
||||||
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
index a1077445ab7d416dc61db85742e447193642b919..38f0f98c2191bfe36c3547501e49680faef50403 100644
|
index ba46e9eafab188455d49f1a555e38b0ebe66fcf9..3428f3014d9b8e9422a9f586268f5e82dcf1e33f 100644
|
||||||
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||||
@@ -596,7 +596,7 @@ public abstract class PlayerList {
|
@@ -596,7 +596,7 @@ public abstract class PlayerList {
|
||||||
|
@ -23,7 +23,7 @@ index bd7926fa89621e8cdd0b5fdd8ed3b8c6dbfbc3ec..f20497eb1202e3e4c256f6cf04f8644a
|
|||||||
public static boolean velocityOnlineMode;
|
public static boolean velocityOnlineMode;
|
||||||
public static byte[] velocitySecretKey;
|
public static byte[] velocitySecretKey;
|
||||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index c0a685cfe62aeda3583763ecc1e4fa127f8fb0d4..ff36ca2dbdf4a9abb953097f1b6246a177370b02 100644
|
index f62f2c0bf9a9d280ed68de8c1afc382b561f31ec..fa4ce1c0f2d1f0204aa6db7503e8c5bd4c605d16 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -230,6 +230,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -230,6 +230,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
@ -34,7 +34,7 @@ index c0a685cfe62aeda3583763ecc1e4fa127f8fb0d4..ff36ca2dbdf4a9abb953097f1b6246a1
|
|||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
private int dropSpamTickCount;
|
private int dropSpamTickCount;
|
||||||
private double firstGoodX;
|
private double firstGoodX;
|
||||||
@@ -375,6 +376,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -376,6 +377,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
// CraftBukkit start
|
// CraftBukkit start
|
||||||
for (int spam; (spam = this.chatSpamTickCount.get()) > 0 && !this.chatSpamTickCount.compareAndSet(spam, spam - 1); ) ;
|
for (int spam; (spam = this.chatSpamTickCount.get()) > 0 && !this.chatSpamTickCount.compareAndSet(spam, spam - 1); ) ;
|
||||||
if (tabSpamLimiter.get() > 0) tabSpamLimiter.getAndDecrement(); // Paper - split to seperate variable
|
if (tabSpamLimiter.get() > 0) tabSpamLimiter.getAndDecrement(); // Paper - split to seperate variable
|
||||||
@ -42,7 +42,7 @@ index c0a685cfe62aeda3583763ecc1e4fa127f8fb0d4..ff36ca2dbdf4a9abb953097f1b6246a1
|
|||||||
/* Use thread-safe field access instead
|
/* Use thread-safe field access instead
|
||||||
if (this.chatSpamTickCount > 0) {
|
if (this.chatSpamTickCount > 0) {
|
||||||
--this.chatSpamTickCount;
|
--this.chatSpamTickCount;
|
||||||
@@ -2810,6 +2812,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
@@ -2811,6 +2813,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void handlePlaceRecipe(ServerboundPlaceRecipePacket packet) {
|
public void handlePlaceRecipe(ServerboundPlaceRecipePacket packet) {
|
||||||
|
Einige Dateien werden nicht angezeigt, da zu viele Dateien in diesem Diff geändert wurden Mehr anzeigen
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren