diff --git a/changelog.md b/changelog.md index 5d5f35d7bf..46927da00e 100644 --- a/changelog.md +++ b/changelog.md @@ -1,6 +1,7 @@ # 7.4.4 * Fixed missing skin color on hands +* Fixed blueprint on dedicated servers # 7.4.3 diff --git a/common/src/main/java/net/mca/client/gui/BlueprintScreen.java b/common/src/main/java/net/mca/client/gui/BlueprintScreen.java index 57dc8510b0..70c5f92a01 100644 --- a/common/src/main/java/net/mca/client/gui/BlueprintScreen.java +++ b/common/src/main/java/net/mca/client/gui/BlueprintScreen.java @@ -651,7 +651,7 @@ public void setVillage(Village village) { } } - public void setRank(Rank rank, int reputation, boolean isVillage, Set completedTasks, Map> tasks, Map buildingTypes) { + public void setVillageData(Rank rank, int reputation, boolean isVillage, Set completedTasks, Map> tasks, Map buildingTypes) { this.rank = rank; this.reputation = reputation; this.isVillage = isVillage; diff --git a/common/src/main/java/net/mca/network/ClientInteractionManagerImpl.java b/common/src/main/java/net/mca/network/ClientInteractionManagerImpl.java index c642dfdcd3..c1b4d92171 100644 --- a/common/src/main/java/net/mca/network/ClientInteractionManagerImpl.java +++ b/common/src/main/java/net/mca/network/ClientInteractionManagerImpl.java @@ -118,7 +118,7 @@ public void handleVillageDataResponse(GetVillageResponse message) { if (screen instanceof BlueprintScreen gui) { Village village = new Village(message.getData(), null); gui.setVillage(village); - gui.setRank(message.rank, message.reputation, message.isVillage, message.ids, message.tasks, message.buildingTypes); + gui.setVillageData(message.rank, message.reputation, message.isVillage, message.ids, message.tasks, message.buildingTypes); } } diff --git a/common/src/main/java/net/mca/server/world/data/Village.java b/common/src/main/java/net/mca/server/world/data/Village.java index a4ea1d64a5..f4dbcbf3de 100644 --- a/common/src/main/java/net/mca/server/world/data/Village.java +++ b/common/src/main/java/net/mca/server/world/data/Village.java @@ -104,7 +104,7 @@ public Village(NbtCompound v, @Nullable ServerWorld world) { for (int i = 0; i < b.size(); i++) { Building building = new Building(b.getCompound(i)); - if (BuildingTypes.getInstance().getBuildingTypes().containsKey(building.getType())) { + if (world == null || BuildingTypes.getInstance().getBuildingTypes().containsKey(building.getType())) { buildings.put(building.getId(), building); } }