mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-27 13:06:02 +01:00
974b0afca9
CraftBukkit removed their implementation that caused this issue, switching to Mojang's implementation which doesn't appear to share it. I already removed the important bit in the last upstream merge, this is just unused and unnecessary now. So we remove it.
37 lines
1.5 KiB
Diff
37 lines
1.5 KiB
Diff
From 7cb360d7aec57c15e7ce8b669d28fd9de086ffc3 Mon Sep 17 00:00:00 2001
|
|
From: Aikar <aikar@aikar.co>
|
|
Date: Sat, 19 Mar 2016 15:16:54 -0400
|
|
Subject: [PATCH] Pass world to Village creation
|
|
|
|
fixes NPE bug #95
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/PersistentVillage.java b/src/main/java/net/minecraft/server/PersistentVillage.java
|
|
index a5b79ecad..01f7cee38 100644
|
|
--- a/src/main/java/net/minecraft/server/PersistentVillage.java
|
|
+++ b/src/main/java/net/minecraft/server/PersistentVillage.java
|
|
@@ -238,7 +238,7 @@ public class PersistentVillage extends PersistentBase {
|
|
|
|
for (int i = 0; i < nbttaglist.size(); ++i) {
|
|
NBTTagCompound nbttagcompound1 = nbttaglist.get(i);
|
|
- Village village = new Village();
|
|
+ Village village = new Village(world); // Paper
|
|
|
|
village.a(nbttagcompound1);
|
|
this.villages.add(village);
|
|
diff --git a/src/main/java/net/minecraft/server/Village.java b/src/main/java/net/minecraft/server/Village.java
|
|
index 2ab381d50..817c836c3 100644
|
|
--- a/src/main/java/net/minecraft/server/Village.java
|
|
+++ b/src/main/java/net/minecraft/server/Village.java
|
|
@@ -24,7 +24,7 @@ public class Village {
|
|
private final List<Village.Aggressor> k;
|
|
private int l;
|
|
|
|
- public Village() {
|
|
+ private Village() { // Paper - Nothing should call this - world needs to be set.
|
|
this.c = BlockPosition.ZERO;
|
|
this.d = BlockPosition.ZERO;
|
|
this.j = Maps.newHashMap();
|
|
--
|
|
2.12.2.windows.2
|
|
|