From 3e718e2e0be61431ae1682191ba79dd9d2ff5665 Mon Sep 17 00:00:00 2001 From: MattBDev <4009945+MattBDev@users.noreply.github.com> Date: Mon, 17 Feb 2020 17:19:14 -0500 Subject: [PATCH] Compile fixes --- .../java/com/boydti/fawe/util/BrushCache.java | 34 ------------------- 1 file changed, 34 deletions(-) diff --git a/worldedit-core/src/main/java/com/boydti/fawe/util/BrushCache.java b/worldedit-core/src/main/java/com/boydti/fawe/util/BrushCache.java index 4c35ccb5b..5aa7c6245 100644 --- a/worldedit-core/src/main/java/com/boydti/fawe/util/BrushCache.java +++ b/worldedit-core/src/main/java/com/boydti/fawe/util/BrushCache.java @@ -85,40 +85,6 @@ public final class BrushCache { brushCache.remove(getKey(item)); CompoundTag display = (CompoundTag) map.get("display"); Map displayMap; - if (tool != null) { - String json = tool.toString(gson); - map.put("weBrushJson", new StringTag(json)); - if (display == null) { - map.put("display", new CompoundTag(displayMap = new HashMap<>())); - } else { - displayMap = ReflectionUtils.getMap(display.getValue()); - } - displayMap.put("Lore", FaweCache.IMP.asTag(json.split("\\r?\\n"))); - String primary = (String) tool.getPrimary().getSettings().get(BrushSettings.SettingType.BRUSH); - String secondary = (String) tool.getSecondary().getSettings().get(BrushSettings.SettingType.BRUSH); - if (primary == null) primary = secondary; - if (secondary == null) secondary = primary; - if (primary != null) { - String name = primary == secondary ? primary.split(" ")[0] : primary.split(" ")[0] + " / " + secondary.split(" ")[0]; - displayMap.put("Name", new StringTag("{\"text\":\"" + name + "\"}")); - } - } else if (map.containsKey("weBrushJson")) { - map.remove("weBrushJson"); - if (display != null) { - displayMap = ReflectionUtils.getMap(display.getValue()); - displayMap.remove("Lore"); - displayMap.remove("Name"); - if (displayMap.isEmpty()) { - map.remove("display"); - } - } - } else { - return tool; - } - item.setNbtData(nbt); - if (tool != null) { - brushCache.put(getKey(item), tool); - } return tool; } }