mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 23:38:25 +01:00
parent
1ba951ee5d
commit
5ef91b3293
1 changed files with 2 additions and 16 deletions
|
@ -10,7 +10,7 @@ to the object directly on the Entity/TileEntity object we can directly grab.
|
|||
Use that local value instead to reduce lookups in many hot places.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/Chunk.java b/src/main/java/net/minecraft/server/Chunk.java
|
||||
index 71d0db3f3..a51b648c5 100644
|
||||
index 3e80825f7..4a94fd5a6 100644
|
||||
--- a/src/main/java/net/minecraft/server/Chunk.java
|
||||
+++ b/src/main/java/net/minecraft/server/Chunk.java
|
||||
@@ -0,0 +0,0 @@ public class Chunk {
|
||||
|
@ -22,7 +22,7 @@ index 71d0db3f3..a51b648c5 100644
|
|||
this.a(entity, entity.ac);
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
|
||||
index c0816b9f8..b1e7b63e0 100644
|
||||
index c0816b9f8..33ac57e6b 100644
|
||||
--- a/src/main/java/net/minecraft/server/World.java
|
||||
+++ b/src/main/java/net/minecraft/server/World.java
|
||||
@@ -0,0 +0,0 @@ public abstract class World implements IBlockAccess {
|
||||
|
@ -85,18 +85,4 @@ index c0816b9f8..b1e7b63e0 100644
|
|||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +0,0 @@ public abstract class World implements IBlockAccess {
|
||||
int k = MathHelper.floor(entity.locZ / 16.0D);
|
||||
|
||||
if (!entity.aa || entity.ab != i || entity.ac != j || entity.ad != k) {
|
||||
- if (entity.aa && this.isChunkLoaded(entity.ab, entity.ad, true)) {
|
||||
- this.getChunkAt(entity.ab, entity.ad).a(entity, entity.ac);
|
||||
+ // Paper start
|
||||
+ Chunk currentChunk = entity.getCurrentChunk();
|
||||
+ if (entity.aa && currentChunk != null) {
|
||||
+ currentChunk.removeEntity(entity);
|
||||
+ // Paper end
|
||||
}
|
||||
|
||||
if (!entity.bD() && !this.isChunkLoaded(i, k, true)) {
|
||||
--
|
Loading…
Reference in a new issue