mirror of
https://github.com/songoda/EpicHoppers.git
synced 2024-11-22 18:25:59 +01:00
Cleaned up enchantment system.
This commit is contained in:
parent
60a467a201
commit
555609309a
@ -14,7 +14,7 @@ import com.songoda.epichoppers.api.utils.ProtectionPluginHook;
|
||||
import com.songoda.epichoppers.boost.BoostData;
|
||||
import com.songoda.epichoppers.boost.BoostManager;
|
||||
import com.songoda.epichoppers.command.CommandManager;
|
||||
import com.songoda.epichoppers.handlers.EnchantmentHandler;
|
||||
import com.songoda.epichoppers.enchantment.Enchantment;
|
||||
import com.songoda.epichoppers.handlers.HopHandler;
|
||||
import com.songoda.epichoppers.handlers.TeleportHandler;
|
||||
import com.songoda.epichoppers.hooks.*;
|
||||
@ -67,7 +67,7 @@ public class EpicHoppersPlugin extends JavaPlugin implements EpicHoppers {
|
||||
|
||||
private static EpicHoppersPlugin INSTANCE;
|
||||
public References references = null;
|
||||
public EnchantmentHandler enchantmentHandler;
|
||||
public Enchantment enchantmentHandler;
|
||||
private List<ProtectionPluginHook> protectionHooks = new ArrayList<>();
|
||||
private ClaimableProtectionPluginHook factionsHook, townyHook, aSkyblockHook, uSkyblockHook, skyBlockEarhHook;
|
||||
private SettingsManager settingsManager;
|
||||
@ -130,7 +130,7 @@ public class EpicHoppersPlugin extends JavaPlugin implements EpicHoppers {
|
||||
this.update();
|
||||
}
|
||||
|
||||
this.enchantmentHandler = new EnchantmentHandler();
|
||||
this.enchantmentHandler = new Enchantment();
|
||||
this.hopperManager = new EHopperManager();
|
||||
this.playerDataManager = new PlayerDataManager();
|
||||
this.boostManager = new BoostManager();
|
||||
|
@ -1,4 +1,4 @@
|
||||
package com.songoda.epichoppers.handlers;
|
||||
package com.songoda.epichoppers.enchantment;
|
||||
|
||||
import com.songoda.epichoppers.utils.Debugger;
|
||||
import com.songoda.epichoppers.utils.Methods;
|
||||
@ -12,15 +12,15 @@ import java.util.ArrayList;
|
||||
/**
|
||||
* Created by songoda on 3/22/2017.
|
||||
*/
|
||||
public class EnchantmentHandler {
|
||||
public class Enchantment {
|
||||
|
||||
public ItemStack createSyncTouch(ItemStack item, Block b) {
|
||||
public ItemStack createSyncTouch(ItemStack item, Block block) {
|
||||
try {
|
||||
ItemMeta itemmeta = item.getItemMeta();
|
||||
ArrayList<String> lore = new ArrayList<>();
|
||||
if (b != null) {
|
||||
if (block != null) {
|
||||
lore.add(Methods.formatText("&aSync Touch"));
|
||||
lore.add(Methods.convertToInvisibleString(Methods.serializeLocation(b)));
|
||||
lore.add(Methods.convertToInvisibleString(Methods.serializeLocation(block)));
|
||||
} else {
|
||||
lore.add(Methods.formatText("&7Sync Touch"));
|
||||
}
|
Loading…
Reference in New Issue
Block a user