mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-27 07:20:00 +08:00
Fix bug in last patch
This commit is contained in:
parent
0645364ee5
commit
6e2711d666
@ -1,4 +1,4 @@
|
|||||||
From 88e7c7af098c7a40518c05dbba690e037cb306d8 Mon Sep 17 00:00:00 2001
|
From ee5f7b1451005f94292b283fa1bc9e21cacb05c2 Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Thu, 16 Aug 2018 17:36:41 -0400
|
Date: Thu, 16 Aug 2018 17:36:41 -0400
|
||||||
Subject: [PATCH] Ensure chunks are always loaded on hard position sets
|
Subject: [PATCH] Ensure chunks are always loaded on hard position sets
|
||||||
@ -17,14 +17,14 @@ guaranteeing that the entity will be properly registered
|
|||||||
into its new home comfortably.
|
into its new home comfortably.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
|
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
|
||||||
index 9b5f7fcf72..3c279d3fe8 100644
|
index 9b5f7fcf72..48c9fbd9b3 100644
|
||||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||||
@@ -1309,6 +1309,7 @@ public abstract class Entity implements ICommandListener, KeyedObject { // Paper
|
@@ -1309,6 +1309,7 @@ public abstract class Entity implements ICommandListener, KeyedObject { // Paper
|
||||||
this.lastYaw -= 360.0F;
|
this.lastYaw -= 360.0F;
|
||||||
}
|
}
|
||||||
|
|
||||||
+ world.getChunkAt((int) Math.floor(this.locX), (int) Math.floor(this.locZ)); // Paper - ensure chunk is always loaded
|
+ world.getChunkAt((int) Math.floor(this.locX) >> 4, (int) Math.floor(this.locZ) >> 4); // Paper - ensure chunk is always loaded
|
||||||
this.setPosition(this.locX, this.locY, this.locZ);
|
this.setPosition(this.locX, this.locY, this.locZ);
|
||||||
this.setYawPitch(f, f1);
|
this.setYawPitch(f, f1);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user