mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-03 23:07:40 +01:00
Fix Anti-Xray ConcurrentModificationException
This commit is contained in:
parent
a6d057b113
commit
165dddda84
@ -1463,7 +1463,7 @@ index d16669bc..306a6b7c 100644
|
|||||||
if (flag) {
|
if (flag) {
|
||||||
packetdataserializer.writeBytes(chunksection.getSkyLightArray().asBytes());
|
packetdataserializer.writeBytes(chunksection.getSkyLightArray().asBytes());
|
||||||
diff --git a/src/main/java/net/minecraft/server/PlayerChunk.java b/src/main/java/net/minecraft/server/PlayerChunk.java
|
diff --git a/src/main/java/net/minecraft/server/PlayerChunk.java b/src/main/java/net/minecraft/server/PlayerChunk.java
|
||||||
index 48a008e0..045adbd3 100644
|
index 48a008e0..395386f2 100644
|
||||||
--- a/src/main/java/net/minecraft/server/PlayerChunk.java
|
--- a/src/main/java/net/minecraft/server/PlayerChunk.java
|
||||||
+++ b/src/main/java/net/minecraft/server/PlayerChunk.java
|
+++ b/src/main/java/net/minecraft/server/PlayerChunk.java
|
||||||
@@ -0,0 +0,0 @@ public class PlayerChunk {
|
@@ -0,0 +0,0 @@ public class PlayerChunk {
|
||||||
@ -1487,7 +1487,8 @@ index 48a008e0..045adbd3 100644
|
|||||||
this.a(this.playerChunkMap.getWorld().getTileEntity(blockposition));
|
this.a(this.playerChunkMap.getWorld().getTileEntity(blockposition));
|
||||||
}
|
}
|
||||||
} else if (this.dirtyCount == 64) {
|
} else if (this.dirtyCount == 64) {
|
||||||
+ this.chunk.world.chunkPacketBlockController.onChunkPacketCreate(this.chunk, this.h, true); // Paper - Anti-Xray - Load nearby chunks if necessary
|
+ // Paper - Anti-Xray - Loading chunks here could cause a ConcurrentModificationException #1104
|
||||||
|
+ //this.chunk.world.chunkPacketBlockController.onChunkPacketCreate(this.chunk, this.h, true); // Paper - Anti-Xray - Load nearby chunks if necessary
|
||||||
this.a((Packet) (new PacketPlayOutMapChunk(this.chunk, this.h)));
|
this.a((Packet) (new PacketPlayOutMapChunk(this.chunk, this.h)));
|
||||||
} else {
|
} else {
|
||||||
this.a((Packet) (new PacketPlayOutMultiBlockChange(this.dirtyCount, this.dirtyBlocks, this.chunk)));
|
this.a((Packet) (new PacketPlayOutMultiBlockChange(this.dirtyCount, this.dirtyBlocks, this.chunk)));
|
||||||
@ -1517,7 +1518,7 @@ index 8860a012..fa0d66d6 100644
|
|||||||
return this.a.size();
|
return this.a.size();
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
|
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
|
||||||
index 137c2555..75d5451c 100644
|
index 00513d02..592e5b3b 100644
|
||||||
--- a/src/main/java/net/minecraft/server/World.java
|
--- a/src/main/java/net/minecraft/server/World.java
|
||||||
+++ b/src/main/java/net/minecraft/server/World.java
|
+++ b/src/main/java/net/minecraft/server/World.java
|
||||||
@@ -0,0 +0,0 @@ import org.bukkit.generator.ChunkGenerator;
|
@@ -0,0 +0,0 @@ import org.bukkit.generator.ChunkGenerator;
|
||||||
|
Loading…
Reference in New Issue
Block a user