From 82da5e5a600c28cc55364fc933290109bc812ca3 Mon Sep 17 00:00:00 2001 From: KennyTV <28825609+KennyTV@users.noreply.github.com> Date: Wed, 15 May 2019 13:37:23 +0200 Subject: [PATCH] Fix MappingData reference --- .../blockconnections/ConnectionData.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionData.java index 8fc49d24f..4403a1a05 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionData.java @@ -5,6 +5,7 @@ import com.google.gson.JsonElement; import com.google.gson.JsonObject; import us.myles.ViaVersion.api.PacketWrapper; import us.myles.ViaVersion.api.Via; +import us.myles.ViaVersion.api.data.MappingDataLoader; import us.myles.ViaVersion.api.data.UserConnection; import us.myles.ViaVersion.api.minecraft.BlockChangeRecord; import us.myles.ViaVersion.api.minecraft.BlockFace; @@ -15,7 +16,6 @@ import us.myles.ViaVersion.api.type.Type; import us.myles.ViaVersion.protocols.protocol1_13to1_12_2.Protocol1_13To1_12_2; import us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections.providers.BlockConnectionProvider; import us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections.providers.PacketBlockConnectionProvider; -import us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data.MappingData; import java.util.*; import java.util.Map.Entry; @@ -198,7 +198,7 @@ public class ConnectionData { public static void init() { if (!Via.getConfig().isServersideBlockConnections()) return; Via.getPlatform().getLogger().info("Loading block connection mappings ..."); - JsonObject mapping1_13 = MappingData.loadData("mapping-1.13.json"); + JsonObject mapping1_13 = MappingDataLoader.loadData("mapping-1.13.json"); JsonObject blocks1_13 = mapping1_13.getAsJsonObject("blocks"); for (Entry blockState : blocks1_13.entrySet()) { Integer id = Integer.parseInt(blockState.getKey()); @@ -208,7 +208,7 @@ public class ConnectionData { } if (!Via.getConfig().isReduceBlockStorageMemory()) { - JsonObject mappingBlockConnections = MappingData.loadData("blockConnections.json"); + JsonObject mappingBlockConnections = MappingDataLoader.loadData("blockConnections.json"); for (Entry entry : mappingBlockConnections.entrySet()) { int id = keyToId.get(entry.getKey()); BlockData blockData = new BlockData(); @@ -231,7 +231,7 @@ public class ConnectionData { } } - JsonObject blockData = MappingData.loadData("blockData.json"); + JsonObject blockData = MappingDataLoader.loadData("blockData.json"); JsonArray occluding = blockData.getAsJsonArray("occluding"); for (JsonElement jsonElement : occluding) { occludingStates.add(keyToId.get(jsonElement.getAsString()));