mirror of
https://github.com/Auxilor/EcoEnchants.git
synced 2024-12-27 20:37:34 +01:00
Fixed various codestyle / misc issues
This commit is contained in:
parent
d5948d6cf0
commit
4b2e3ba533
@ -112,7 +112,7 @@ public class EcoEnchantsPlugin extends EcoPlugin {
|
||||
public void onReload() {
|
||||
targetYml.update();
|
||||
rarityYml.update();
|
||||
((EnchantDisplay) this.getDisplayModule()).update();
|
||||
this.getDisplayModule().update();
|
||||
EcoEnchants.values().forEach((ecoEnchant -> {
|
||||
HandlerList.unregisterAll(ecoEnchant);
|
||||
|
||||
|
@ -133,7 +133,7 @@ public class EnchantmentCache {
|
||||
|
||||
String rawName = name;
|
||||
name = color + name;
|
||||
description.replaceAll(line -> Display.PREFIX + ((EnchantDisplay) PLUGIN.getDisplayModule()).getOptions().getDescriptionOptions().getColor() + line);
|
||||
description.replaceAll(line -> Display.PREFIX + PLUGIN.getDisplayModule().getOptions().getDescriptionOptions().getColor() + line);
|
||||
CACHE.put(enchantment.getKey(), new CacheEntry(enchantment, name, rawName, description, type, rarity));
|
||||
}
|
||||
|
||||
|
@ -591,6 +591,8 @@ public class EcoEnchants {
|
||||
|
||||
/**
|
||||
* Update all {@link EcoEnchant}s.
|
||||
*
|
||||
* @param plugin Instance of EcoEnchants.
|
||||
*/
|
||||
@ConfigUpdater
|
||||
public static void update(@NotNull final EcoEnchantsPlugin plugin) {
|
||||
|
@ -92,6 +92,8 @@ public class EnchantmentRarity {
|
||||
|
||||
/**
|
||||
* Update all rarities.
|
||||
*
|
||||
* @param plugin Instance of EcoEnchants.
|
||||
*/
|
||||
@ConfigUpdater
|
||||
public static void update(@NotNull final EcoEnchantsPlugin plugin) {
|
||||
|
@ -65,6 +65,8 @@ public class EnchantmentTarget {
|
||||
|
||||
/**
|
||||
* Update all targets.
|
||||
*
|
||||
* @param plugin Instance of EcoEnchants.
|
||||
*/
|
||||
@ConfigUpdater
|
||||
public static void update(@NotNull final EcoEnchantsPlugin plugin) {
|
||||
|
@ -179,9 +179,7 @@ public class VillagerListeners extends PluginDependent<EcoPlugin> implements Lis
|
||||
anyConflicts.set(true);
|
||||
}
|
||||
|
||||
EcoEnchant ecoEnchant = enchant;
|
||||
|
||||
if (enchantment.getType().equals(ecoEnchant.getType()) && ecoEnchant.getType().isSingular()) {
|
||||
if (enchantment.getType().equals(enchant.getType()) && enchant.getType().isSingular()) {
|
||||
anyConflicts.set(true);
|
||||
}
|
||||
});
|
||||
|
@ -1,6 +1,5 @@
|
||||
package com.willfp.ecoenchants.enchantments.support.vanilla;
|
||||
|
||||
import com.willfp.eco.core.EcoPlugin;
|
||||
import com.willfp.ecoenchants.EcoEnchantsPlugin;
|
||||
import com.willfp.ecoenchants.proxy.proxies.EcoCraftEnchantmentManagerProxy;
|
||||
import com.willfp.ecoenchants.util.ProxyUtils;
|
||||
@ -33,6 +32,8 @@ public class VanillaEnchantments {
|
||||
|
||||
/**
|
||||
* Update the map.
|
||||
*
|
||||
* @param plugin Instance of EcoEnchants.
|
||||
*/
|
||||
public static void update(@NotNull final EcoEnchantsPlugin plugin) {
|
||||
Map<Enchantment, VanillaEnchantmentMetadata> map = new HashMap<>();
|
||||
|
@ -51,6 +51,8 @@ public class WatcherTriggers extends PluginDependent<EcoPlugin> implements Liste
|
||||
|
||||
/**
|
||||
* Update if allowed on npc.
|
||||
*
|
||||
* @param plugin Instance of EcoEnchants.
|
||||
*/
|
||||
@ConfigUpdater
|
||||
public static void update(@NotNull final EcoEnchantsPlugin plugin) {
|
||||
|
Loading…
Reference in New Issue
Block a user