From eb681b66c042b8bacc0df121135451d910f38b87 Mon Sep 17 00:00:00 2001 From: Brianna O'Keefe Date: Fri, 28 Dec 2018 14:50:29 -0500 Subject: [PATCH] Removed setting definitions. --- .../epichoppers/utils/SettingsManager.java | 15 --------------- .../src/main/resources/SettingDefinitions.yml | 14 -------------- 2 files changed, 29 deletions(-) delete mode 100644 EpicHoppers-Plugin/src/main/resources/SettingDefinitions.yml diff --git a/EpicHoppers-Plugin/src/main/java/com/songoda/epichoppers/utils/SettingsManager.java b/EpicHoppers-Plugin/src/main/java/com/songoda/epichoppers/utils/SettingsManager.java index fb5e237..5a5f7cc 100644 --- a/EpicHoppers-Plugin/src/main/java/com/songoda/epichoppers/utils/SettingsManager.java +++ b/EpicHoppers-Plugin/src/main/java/com/songoda/epichoppers/utils/SettingsManager.java @@ -29,7 +29,6 @@ public class SettingsManager implements Listener { private static final Pattern SETTINGS_PATTERN = Pattern.compile("(.{1,28}(?:\\s|$))|(.{0,28})", Pattern.DOTALL); - private static ConfigWrapper defs; private Map cat = new HashMap<>(); @@ -37,10 +36,6 @@ public class SettingsManager implements Listener { public SettingsManager(EpicHoppersPlugin plugin) { this.instance = plugin; - - plugin.saveResource("SettingDefinitions.yml", true); - defs = new ConfigWrapper(plugin, "", "SettingDefinitions.yml"); - defs.createNewFile("Loading data file", pluginName + " SettingDefinitions file"); Bukkit.getPluginManager().registerEvents(this, plugin); } @@ -161,16 +156,6 @@ public class SettingsManager implements Listener { lore.add(TextComponent.formatText("&5" + config.getInt(fKey))); } - if (defs.getConfig().contains(fKey)) { - String text = defs.getConfig().getString(key); - - Matcher m = SETTINGS_PATTERN.matcher(text); - while (m.find()) { - if (m.end() != text.length() || m.group().length() != 0) - lore.add(TextComponent.formatText("&7" + m.group())); - } - } - meta.setLore(lore); item.setItemMeta(meta); diff --git a/EpicHoppers-Plugin/src/main/resources/SettingDefinitions.yml b/EpicHoppers-Plugin/src/main/resources/SettingDefinitions.yml deleted file mode 100644 index 41a58a9..0000000 --- a/EpicHoppers-Plugin/src/main/resources/SettingDefinitions.yml +++ /dev/null @@ -1,14 +0,0 @@ -ECO-Icon: 'This is the default icon that will be used for the Economy upgrade button.' -XP-Icon: 'This is the default icon that will be used for the Experience upgrade button.' -Upgrading-enabled: 'Setting this to true will allow users to access the upgrade window.' -Upgrade-with-eco: 'Setting this to true will allow users to use Economy to upgrade their hoppers.' -Upgrade-with-xp: 'Setting this to true will allow users to use Experience to upgrade their hoppers.' -On-upgrade-particles: 'Setting this to true will cause particles to emit when a hopper is upgraded.' -Teleport-hoppers: 'These are the default levels, the amount of levels can be expanded if you want, just add another level to the bottom of the list while keeping numeric order. Allows you to enable or disable teleporting with hoppers' -Hop-Tick: 'This is the tick speed for synced hoppers.' -Sync-Timeout: 'This is the timeout that if reached will cancel a link.' -Glass-Type: 'This is the id of the glass used for the background in the guis.' -Rainbow-Glass: 'If this is enabled the glass background will be randomized colors. ' -Limit-Hoppers-Per-Chunk: 'If enabled this will limit the amount hoppers per chunk' -Hopper-Limit: 'This is the amount of allowed hoppers per chunk.' -Upgrade-particle-type: 'This is the type of particle an upgrade will emit.'