2018-08-26 18:11:49 +00:00
|
|
|
From 38175f7ba6ffd4237efc7c3e570ea22bb8ec9d23 Mon Sep 17 00:00:00 2001
|
2018-07-18 23:16:19 +00:00
|
|
|
From: Aikar <aikar@aikar.co>
|
|
|
|
Date: Tue, 5 Jun 2018 00:32:22 -0400
|
|
|
|
Subject: [PATCH] Don't load chunks for villager door checks
|
|
|
|
|
|
|
|
This avoids villages spam loading chunks sync
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/Village.java b/src/main/java/net/minecraft/server/Village.java
|
2018-08-26 18:11:49 +00:00
|
|
|
index bda67faefe..955041e266 100644
|
2018-07-18 23:16:19 +00:00
|
|
|
--- a/src/main/java/net/minecraft/server/Village.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/Village.java
|
|
|
|
@@ -313,6 +313,12 @@ public class Village {
|
|
|
|
|
|
|
|
private boolean g(BlockPosition blockposition) {
|
|
|
|
IBlockData iblockdata = this.a.getType(blockposition);
|
|
|
|
+ // Paper start
|
|
|
|
+ if (!this.a.isChunkLoaded(blockposition.getX() >> 4, blockposition.getZ() >> 4, true )) {
|
|
|
|
+ return false;
|
|
|
|
+ }
|
|
|
|
+ // Paper end
|
|
|
|
+
|
|
|
|
Block block = iblockdata.getBlock();
|
|
|
|
|
|
|
|
return block instanceof BlockDoor ? iblockdata.getMaterial() == Material.WOOD : false;
|
|
|
|
--
|
|
|
|
2.18.0
|
|
|
|
|