diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..2f7896d --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +target/ diff --git a/pom.xml b/pom.xml new file mode 100644 index 0000000..61a79ea --- /dev/null +++ b/pom.xml @@ -0,0 +1,43 @@ + + 4.0.0 + + com.zivilon + ItemSalvage + 1.0 + jar + + ItemSalvage + + + UTF-8 + 1.7 + 1.7 + + + + + org.bukkit + bukkit + 1.7.10-R0.1-SNAPSHOT + provided + + + com.github.flinbein + PowerNBT + 0.8.9.2 + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.8.0 + + 1.8 + 1.8 + + + + + diff --git a/src/main/java/com/zivilon/itemsalvage/ItemSalvage.java b/src/main/java/com/zivilon/itemsalvage/ItemSalvage.java new file mode 100644 index 0000000..1602d45 --- /dev/null +++ b/src/main/java/com/zivilon/itemsalvage/ItemSalvage.java @@ -0,0 +1,34 @@ +package com.zivilon.itemsalvage; + +import com.zivilon.itemsalvage.utils.dust_handler; +import com.zivilon.itemsalvage.listeners.enchantment_table_listener; + +import org.bukkit.plugin.java.JavaPlugin; +import org.bukkit.configuration.file.YamlConfiguration; +import org.bukkit.configuration.file.FileConfiguration; + +import java.io.File; + + +public class ItemSalvage extends JavaPlugin { + private FileConfiguration item_config; + + @Override + public void onEnable() { + getServer().getPluginManager().registerEvents(new enchantment_table_listener(this), this); + this.item_config = loadConfiguration("items.yml"); + } + + private FileConfiguration loadConfiguration(String filename) { + File file = new File(getDataFolder(), filename); + if (!file.exists()) { + saveResource(filename, false); + } + + return YamlConfiguration.loadConfiguration(file); + } + + public FileConfiguration get_item_config() { + return item_config; + } +} diff --git a/src/main/java/com/zivilon/itemsalvage/listeners/enchantment_table_listener.java b/src/main/java/com/zivilon/itemsalvage/listeners/enchantment_table_listener.java new file mode 100644 index 0000000..851a372 --- /dev/null +++ b/src/main/java/com/zivilon/itemsalvage/listeners/enchantment_table_listener.java @@ -0,0 +1,371 @@ +package com.zivilon.itemsalvage.listeners; + +import com.zivilon.itemsalvage.ItemSalvage; +import com.zivilon.itemsalvage.utils.dust_handler; +import org.bukkit.ChatColor; +import org.bukkit.Material; +import org.bukkit.Bukkit; +import org.bukkit.configuration.ConfigurationSection; +import org.bukkit.configuration.file.FileConfiguration; +import org.bukkit.entity.Player; +import org.bukkit.event.EventHandler; +import org.bukkit.event.Listener; +import org.bukkit.event.player.PlayerInteractEvent; +import org.bukkit.inventory.ItemStack; +import org.bukkit.inventory.meta.ItemMeta; +import org.bukkit.enchantments.Enchantment; + +import me.dpohvar.powernbt.PowerNBT; +import me.dpohvar.powernbt.api.NBTCompound; +import me.dpohvar.powernbt.api.NBTManager; +import me.dpohvar.powernbt.api.NBTList; + +import java.util.List; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.Map; +import java.util.Collections; +import java.util.stream.Collectors; +import java.util.concurrent.ThreadLocalRandom; +import java.io.BufferedWriter; +import java.io.FileWriter; +import java.io.IOException; +import java.text.SimpleDateFormat; +import java.util.Date; + +public class enchantment_table_listener implements Listener { + + private final ItemSalvage plugin; + private static final String LOG_FILE = "plugins/ItemSalvage/salvage.log"; + + public enchantment_table_listener(ItemSalvage plugin) { + this.plugin = plugin; + } + + public Map get_config_item_data(ItemStack held_item) { + // Getting the plugin config and items section + FileConfiguration config = plugin.get_item_config(); + ConfigurationSection items_section = config.getConfigurationSection("items"); + + // Getting NBT data from held item + NBTManager nbtManager = me.dpohvar.powernbt.PowerNBT.getApi(); + NBTCompound itemNBT = nbtManager.read(held_item); + if (itemNBT == null) return null; + byte lotrRandomEnch = itemNBT.getByte("LOTRRandomEnch"); + int lotrRepairCost = itemNBT.getInt("LOTRRepairCost"); + NBTList lotrEnchNBT = itemNBT.getList("LOTREnch"); + List lotrEnch = new ArrayList<>(); + if (lotrEnchNBT != null) { + for (Object obj : lotrEnchNBT) { + lotrEnch.add(obj.toString()); + } + } + NBTList lotrEnchProgressNBT = itemNBT.getList("LOTREnchProgress"); + List> lotrEnchProgress = new ArrayList<>(); + if (lotrEnchProgressNBT != null) { + for (Object obj : lotrEnchProgressNBT) { + NBTCompound enchProgressCompound = (NBTCompound) obj; + Map enchProgressMap = new HashMap<>(); + enchProgressMap.put("Name", enchProgressCompound.getString("Name")); + enchProgressMap.put("Kills", enchProgressCompound.getInt("Kills")); + enchProgressMap.put("KillsRequired", enchProgressCompound.getInt("KillsRequired")); + lotrEnchProgress.add(enchProgressMap); + } + } + + // Iterating over items in config + for (String key : items_section.getKeys(false)) { + ConfigurationSection item_section = items_section.getConfigurationSection(key); + Material config_item_material = Material.matchMaterial(item_section.getString("id")); + String config_item_name = ChatColor.translateAlternateColorCodes('&', item_section.getString("name")); + List config_item_lore = item_section.getStringList("lore").stream() + .map(line -> ChatColor.translateAlternateColorCodes('&', line)) + .collect(Collectors.toList()); + + Map config_enchantments = new HashMap<>(); + if (item_section.contains("enchantments")) { + ConfigurationSection enchantmentSection = item_section.getConfigurationSection("enchantments"); + for (String enchantmentName : enchantmentSection.getKeys(false)) { + Enchantment enchantment = Enchantment.getByName(enchantmentName); + int level = enchantmentSection.getInt(enchantmentName + ".lvl"); + config_enchantments.put(enchantment, level); + } + } + + ItemMeta held_item_meta = held_item.getItemMeta(); + + if (held_item.getType() == config_item_material + && held_item.getEnchantments().equals(config_enchantments)) { + + // Check if the held item has a lore that matches the config + boolean lore_matches = (held_item_meta.hasLore() && held_item_meta.getLore().equals(config_item_lore)) || (!held_item_meta.hasLore() && config_item_lore.equals(Collections.emptyList())); + boolean name_matches = held_item_meta.hasDisplayName() && held_item_meta.getDisplayName().equals(config_item_name); + + // If item matches, prepare and return item properties + if (lore_matches) { + Map item_data = new HashMap<>(); + item_data.put("item_id", key); + item_data.put("original_name", held_item_meta.getDisplayName()); + item_data.put("name", config_item_name); + item_data.put("lore", config_item_lore); + item_data.put("enchantments", config_enchantments); + item_data.put("salvage_value", item_section.getInt("salvage_value", 0)); + item_data.put("upgrade_cost", item_section.getInt("upgrade_cost", 0)); + item_data.put("default_name", !name_matches); + item_data.put("LOTRRandomEnch", lotrRandomEnch); + item_data.put("LOTRRepairCost", item_section.getInt("LOTRRepairCost", lotrRepairCost)); // Override if found in config + item_data.put("LOTREnch", lotrEnch); + item_data.put("LOTREnchProgress", lotrEnchProgress); + item_data.put("upgrades_to", item_section.getString("upgrades_to", null)); + item_data.put("upgrade_mode", item_section.getString("upgrade_mode", null)); + + return item_data; + } + } + } + return null; + } + + @EventHandler + public void onInteract(PlayerInteractEvent event) { + + if (event.getClickedBlock() == null || event.getClickedBlock().getType() != Material.ENCHANTMENT_TABLE) { + return; + } + + Player player = event.getPlayer(); + ItemStack held_item = player.getInventory().getItemInHand(); + + if (player.isSneaking()) { + salvage_item(player, held_item, event); + return; + } + standard_interact(player, held_item, event); // Line 135 + } + + private void log_salvage_event(String username, String item_id) { + String timestamp = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(new Date()); + String log_entry = timestamp + " - " + username + " - " + item_id; + + try (BufferedWriter writer = new BufferedWriter(new FileWriter(LOG_FILE, true))) { + writer.write(log_entry); + writer.newLine(); + } catch (IOException e) { + e.printStackTrace(); // Handle the exception as needed + } + } + + private void salvage_item(Player player, ItemStack held_item, PlayerInteractEvent event) { + if (held_item.getType().toString().equals("LOTR_ITEMITHILDIN") && !held_item.hasItemMeta()) { + event.setCancelled(true); + int randomNum = ThreadLocalRandom.current().nextInt(0, 4); + // Remove held item first + held_item.setAmount(held_item.getAmount() - 1); + player.getInventory().setItemInHand(held_item); + if (randomNum == 1) { + dust_handler.give_dust_to_player(player, 1); + player.updateInventory(); + log_salvage_event(player.getName(), "ithildin"); + } + return; + } + if (held_item == null) return; + Map item_data = null; + if (held_item.hasItemMeta()) item_data = get_config_item_data(held_item); // Line 196 + + if (item_data != null) { + event.setCancelled(true); + + int salvage_value = (Integer) item_data.get("salvage_value"); + + if (salvage_value != 0) { + int space = dust_handler.calculate_dust_space(player); + if (salvage_value > (space + 64)) { + player.sendMessage(ChatColor.RED + "You do not have inventory space to salvage this item."); + } else { + // Remove held item first + held_item.setAmount(held_item.getAmount() - 1); + player.getInventory().setItemInHand(held_item); + + // Now add the dust + dust_handler.give_dust_to_player(player, salvage_value); + + // Force an inventory update + player.updateInventory(); + + String original_name = (String) item_data.get("original_name"); + player.sendMessage(ChatColor.GREEN + "You salvaged your " + original_name + ChatColor.GREEN + " and received " + salvage_value + ChatColor.AQUA + " Arcane Dust" + ChatColor.GREEN + "."); + log_salvage_event(player.getName(), (String) item_data.get("item_id")); + + } + } else { + player.sendMessage(ChatColor.RED + "This item cannot be salvaged."); + } + } else { + player.sendMessage(ChatColor.RED + "This item cannot be salvaged"); + } + } + + private void standard_interact(Player player, ItemStack held_item, PlayerInteractEvent event) { + if (held_item.getType().toString().equals("LOTR_ITEMITHILDIN") && !held_item.hasItemMeta()) { + event.setCancelled(true); + player.sendMessage(ChatColor.GREEN + "This item can be salvaged for 1/4 Arcane Dust."); + return; + } + if (held_item == null) return; + Map item_data = null; + if (held_item.hasItemMeta()) item_data = get_config_item_data(held_item); + if (item_data != null) { + event.setCancelled(true); + + + int salvage_value = (Integer) item_data.get("salvage_value"); + int upgrade_cost = (Integer) item_data.get("upgrade_cost"); + String upgrade_mode = (String) item_data.get("upgrade_mode"); + + if (salvage_value == 0 && upgrade_cost == 0) { + player.sendMessage(ChatColor.AQUA + "Enchantment Table"); + player.sendMessage(ChatColor.YELLOW + "To upgrade items, right-click with the item in hand."); + player.sendMessage(ChatColor.YELLOW + "To salvage items, sneak and right-click with the item in hand."); + return; + } + + if (upgrade_cost != 0 && dust_handler.count_dust_in_inventory(player) >= upgrade_cost) { + dust_handler.remove_dust_from_inventory(player, upgrade_cost); + upgrade_item(player, held_item, item_data); + String original_name = (String) item_data.get("original_name"); + player.sendMessage(ChatColor.GREEN + "Your " + original_name + ChatColor.GREEN + " has been upgraded for " + upgrade_cost + ChatColor.AQUA + " Arcane Dust" + ChatColor.GREEN + "."); + return; + } + + if (upgrade_cost != 0) { + player.sendMessage(ChatColor.GREEN + "This item can be upgraded for " + upgrade_cost + " Arcane Dust."); + } + + if (salvage_value != 0) { + player.sendMessage(ChatColor.GREEN + "This item can be salvaged for " + salvage_value + " Arcane Dust."); + } + if (upgrade_cost != 0) { + player.sendMessage(ChatColor.GREEN + "Upgrade type: " + ChatColor.GRAY + upgrade_mode); + } + + } else { + player.sendMessage(ChatColor.AQUA + "Enchantment Table"); + player.sendMessage(ChatColor.YELLOW + "To upgrade items, right-click with the item in hand."); + player.sendMessage(ChatColor.YELLOW + "To salvage items, sneak and right-click with the item in hand."); + } + } + + private void upgrade_item(Player player, ItemStack held_item, Map item_data) { + // Fetch the original item data + Map original_item_data = item_data; + + // Get the upgraded item name + String upgradeTo = (String) original_item_data.get("upgrades_to"); + + // Fetch the upgraded item data directly from the config + FileConfiguration config = plugin.get_item_config(); + ConfigurationSection item_section = config.getConfigurationSection("items." + upgradeTo); + + // Get the id, name, and lore from the upgraded item data + String id = item_section.getString("id"); + String name = item_section.getString("name"); + String original_name = (String) original_item_data.get("original_name"); + List lore = item_section.getStringList("lore"); + + // Create a new item stack for the upgraded item + ItemStack item = new ItemStack(Material.valueOf(id), held_item.getAmount()); + + boolean default_name = (boolean) original_item_data.get("default_name"); + + // Add meta to the upgraded item + ItemMeta meta = item.getItemMeta(); + if (!default_name) { + meta.setDisplayName(ChatColor.translateAlternateColorCodes('&', name)); + } else { + meta.setDisplayName(ChatColor.translateAlternateColorCodes('&', original_name)); + } + lore = lore.stream().map(s -> ChatColor.translateAlternateColorCodes('&', s)).collect(Collectors.toList()); + meta.setLore(lore); + item.setItemMeta(meta); + + // Fetch the enchantments directly from the upgraded item data and add to the item + ConfigurationSection enchantment_section = item_section.getConfigurationSection("enchantments"); + for (String key : enchantment_section.getKeys(false)) { + Enchantment ench = Enchantment.getByName(key); + int level = enchantment_section.getConfigurationSection(key).getInt("lvl"); + item.addUnsafeEnchantment(ench, level); + } + + // Remove the original item by setting its amount to 0 and set the upgraded one as the currently held item + player.getInventory().setItemInHand(item); + player.updateInventory(); // Ensure the inventory update is immediate + + + // Add NBT tags to the upgraded item + item = player.getInventory().getItemInHand(); + NBTManager nbtManager = PowerNBT.getApi(); + NBTCompound item_nbt = nbtManager.read(item); + if (item_nbt == null) { + item_nbt = new NBTCompound(); + } + + byte lotrRandomEnch = (byte) original_item_data.get("LOTRRandomEnch"); + List lotrEnch = (List) original_item_data.get("LOTREnch"); + // Add this after getting the 'lotrEnch' list + if ("modifier".equals(original_item_data.get("upgrade_mode"))) { + for (int i = 0; i < lotrEnch.size(); i++) { + String ench = lotrEnch.get(i); + String upgradedEnch = ench; // Default to original enchantment + if ("meleeSpeed1".equals(ench)) { + upgradedEnch = "meleeSpeed2"; + } else if ("meleeReach1".equals(ench)) { + upgradedEnch = "meleeReach2"; + } else if ("strong1".equals(ench)) { + upgradedEnch = "strong2"; + } else if ("strong2".equals(ench)) { + upgradedEnch = "strong3"; + } else if ("strong3".equals(ench)) { + upgradedEnch = "strong4"; + } else if ("knockback1".equals(ench)) { + upgradedEnch = "knockback2"; + } else if ("rangedKnockback1".equals(ench)) { + upgradedEnch = "rangedKnockback2"; + } else if ("rangedStrong1".equals(ench)) { + upgradedEnch = "rangedStrong2"; + } else if ("rangedStrong2".equals(ench)) { + upgradedEnch = "rangedStrong3"; + } else if ("rangedStrong3".equals(ench)) { + upgradedEnch = "rangedStrong4"; + } + lotrEnch.set(i, upgradedEnch); + } + } + + + int lotrRepairCost = (int) original_item_data.get("LOTRRepairCost"); + List> lotrEnchProgress = (List>) original_item_data.get("LOTREnchProgress"); + + item_nbt.put("LOTRRepairCost", Integer.valueOf(lotrRepairCost)); + + // Convert lotrEnchProgress to NBTList of NBTCompound + NBTList nbtListEnchProgress = new NBTList(); + for (Map enchProgress : lotrEnchProgress) { + NBTCompound compound = new NBTCompound(); + compound.put("Kills", Integer.valueOf((int) enchProgress.get("Kills"))); + compound.put("KillsRequired", Integer.valueOf((int) enchProgress.get("KillsRequired"))); + compound.put("Name", String.valueOf(enchProgress.get("Name"))); + nbtListEnchProgress.add(compound); + } + + // Add NBT tags to the upgraded item + item_nbt.put("LOTRRandomEnch", Byte.valueOf((byte) lotrRandomEnch)); + item_nbt.put("LOTREnch", new NBTList(lotrEnch)); + + item_nbt.put("LOTREnchProgress", nbtListEnchProgress); + + nbtManager.write(item, item_nbt); + player.updateInventory(); + } + +} diff --git a/src/main/java/com/zivilon/itemsalvage/utils/dust_handler.java b/src/main/java/com/zivilon/itemsalvage/utils/dust_handler.java new file mode 100644 index 0000000..5e7ef8d --- /dev/null +++ b/src/main/java/com/zivilon/itemsalvage/utils/dust_handler.java @@ -0,0 +1,203 @@ +package com.zivilon.itemsalvage.utils; + +import org.bukkit.Bukkit; +import org.bukkit.Material; +import org.bukkit.entity.Player; +import org.bukkit.inventory.ItemStack; +import org.bukkit.inventory.PlayerInventory; +import org.bukkit.inventory.meta.ItemMeta; +import org.bukkit.configuration.file.YamlConfiguration; +import org.bukkit.plugin.Plugin; + +import java.io.File; +import java.io.InputStream; +import java.io.IOException; +import java.nio.file.Files; +import java.util.List; +import java.util.stream.Collectors; + +public class dust_handler { + public static void remove_dust_from_inventory(Player player, int amount) { + Plugin plugin = Bukkit.getPluginManager().getPlugin("ItemSalvage"); + + // Create the plugin directory if it doesn't exist + if (!plugin.getDataFolder().exists()) { + plugin.getDataFolder().mkdirs(); + } + + File config_file = new File(plugin.getDataFolder(), "salvage.yml"); + + if (!config_file.exists()) { + try (InputStream in = plugin.getResource("salvage.yml")) { + Files.copy(in, config_file.toPath()); + } catch (IOException e) { + e.printStackTrace(); + } + } + + YamlConfiguration config = YamlConfiguration.loadConfiguration(config_file); + int remaining = amount; + + String dust_item_name = replace_color_codes(config.getString("salvage.name")); + + Material dust_material = Material.matchMaterial(config.getString("salvage.item")); + if (dust_material == null) { + Bukkit.getLogger().warning("Could not find material with name: " + config.getString("salvage.item")); + return; + } + + ItemStack[] inventory = player.getInventory().getContents(); + for (int i = 0; i < inventory.length; i++) { + ItemStack item = inventory[i]; + if (item != null && item.hasItemMeta()) { + ItemMeta meta = item.getItemMeta(); + if (item.getType() == dust_material + && meta.hasDisplayName() && meta.getDisplayName().equals(dust_item_name) + && meta.hasLore()) { + // Load the list of lore lines from the config + List config_lore = config.getStringList("salvage.lore").stream() + .map(dust_handler::replace_color_codes) + .collect(Collectors.toList()); + // Check if all lore lines are present on the item + boolean lore_matches = meta.getLore().equals(config_lore); + + if (lore_matches) { + int total_dust = item.getAmount(); + if (total_dust > remaining) { + item.setAmount(total_dust - remaining); + remaining = 0; + break; + } else { + remaining -= total_dust; + inventory[i] = null; + } + if (remaining == 0) break; + } + } + } + } + + player.getInventory().setContents(inventory); + } + + public static String replace_color_codes(String text) { + return text.replaceAll("&([0-9a-fA-Fk-oK-OrR])", "§$1"); + } + + public static int count_dust_in_inventory(Player player) { + File config_file = new File(Bukkit.getPluginManager().getPlugin("ItemSalvage").getDataFolder(), "salvage.yml"); + if (!config_file.exists()) { + Bukkit.getLogger().warning("Could not find salvage.yml file"); + return 0; + } + + YamlConfiguration config = YamlConfiguration.loadConfiguration(config_file); + + String dust_item_name = replace_color_codes(config.getString("salvage.name")); + + Material dust_material = Material.matchMaterial(config.getString("salvage.item")); + if (dust_material == null) { + Bukkit.getLogger().warning("Could not find material with name: " + config.getString("salvage.item")); + return 0; + } + + List config_lore = config.getStringList("salvage.lore").stream() + .map(dust_handler::replace_color_codes) + .collect(Collectors.toList()); + + int total_dust = 0; + ItemStack[] inventory = player.getInventory().getContents(); + for (int i = 0; i < inventory.length; i++) { + ItemStack item = inventory[i]; + if (item != null && item.hasItemMeta()) { + ItemMeta meta = item.getItemMeta(); + if (item.getType() == dust_material) { + if (meta.hasDisplayName() && meta.getDisplayName().equals(dust_item_name) + && meta.hasLore() && meta.getLore().equals(config_lore)) { + total_dust += item.getAmount(); + } + } + } + } + + return total_dust; + } + + public static void give_dust_to_player(Player player, int amount) { + File config_file = new File(Bukkit.getPluginManager().getPlugin("ItemSalvage").getDataFolder(), "salvage.yml"); + if (!config_file.exists()) { + Bukkit.getLogger().warning("Could not find salvage.yml file"); + return; + } + + YamlConfiguration config = YamlConfiguration.loadConfiguration(config_file); + + String dust_item_name = replace_color_codes(config.getString("salvage.name")); + + Material dust_material = Material.matchMaterial(config.getString("salvage.item")); + if (dust_material == null) { + Bukkit.getLogger().warning("Could not find material with name: " + config.getString("salvage.item")); + return; + } + + List config_lore = config.getStringList("salvage.lore").stream() + .map(dust_handler::replace_color_codes) + .collect(Collectors.toList()); + + // Give items one by one because otherwise the hidden initial stack size value prevents mixing these with other identical item stacks. + for (int i = 0; i < amount; i++) { + ItemStack dust = new ItemStack(dust_material, 1); + ItemMeta dust_meta = dust.getItemMeta(); + + dust_meta.setDisplayName(dust_item_name); + dust_meta.setLore(config_lore); + dust.setItemMeta(dust_meta); + + player.getInventory().addItem(dust); + } + } + + public static int calculate_dust_space(Player player) { + File config_file = new File(Bukkit.getPluginManager().getPlugin("ItemSalvage").getDataFolder(), "salvage.yml"); + if (!config_file.exists()) { + Bukkit.getLogger().warning("Could not find salvage.yml file"); + return 0; + } + + YamlConfiguration config = YamlConfiguration.loadConfiguration(config_file); + + String dust_item_name = replace_color_codes(config.getString("salvage.name")); + + Material dust_material = Material.matchMaterial(config.getString("salvage.item")); + if (dust_material == null) { + Bukkit.getLogger().warning("Could not find material with name: " + config.getString("salvage.item")); + return 0; + } + + List config_lore = config.getStringList("salvage.lore").stream() + .map(dust_handler::replace_color_codes) + .collect(Collectors.toList()); + + int total_space = 0; + ItemStack[] inventory = player.getInventory().getContents(); + + for (int i = 0; i < 36; i++) { // consider only the main inventory, excluding armor and off-hand slots + ItemStack item = inventory[i]; + if (item == null) { + total_space += 64; // Empty slot, can hold a full stack + } else if (item.hasItemMeta()) { + ItemMeta meta = item.getItemMeta(); + if (item.getType() == dust_material + && meta.hasDisplayName() && meta.getDisplayName().equals(dust_item_name) + && meta.hasLore() && meta.getLore().equals(config_lore)) { + total_space += (64 - item.getAmount()); // Partially filled slot + } + } + } + + return total_space; + } + + + +} diff --git a/src/main/resources/items.yml b/src/main/resources/items.yml new file mode 100644 index 0000000..d491236 --- /dev/null +++ b/src/main/resources/items.yml @@ -0,0 +1,1264 @@ +items: + magical_hammer: + id: LOTR_ITEMBLACKSMITHHAMMER + name: "&2Magical Hammer" + lore: + - "&5This is a magical hammer" + enchantments: + DAMAGE_ALL: + lvl: 1 + upgrade_cost: 96 + upgrades_to: superior_magical_hammer + salvage_value: 16 + LOTRRepairCost: 30 # Specify the repair cost here, or leave it out to keep it from the original item + upgrade_mode: "enchant" # Use "modifier", "enchant", or "label" + superior_magical_hammer: + id: LOTR_ITEMBLACKSMITHHAMMER + name: "&2Superior magical Hammer" + lore: + - "&5This is a magical hammer" + - "&5Enhanced with Arcane Dust" + enchantments: + DAMAGE_ALL: + lvl: 2 + salvage_value: 16 + LOTRRepairCost: 30 + glaechir_spear: + id: LOTR_ITEMSPEARDALE + name: "&2Glaechír's old spear" + lore: + - "&7Unrepairable I" + - "&5Spear once held by Knight Glaechír" + - "&5before he became a lord." + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 24 + upgrades_to: superior_glaechir_spear + upgrade_cost: 128 + upgrade_mode: "modifier" + superior_glaechir_spear: + id: LOTR_ITEMSPEARDALE + name: "&2Superior Glaechír's spear" + lore: + - "&7Unrepairable II" + - "&5Spear once held by Knight Glaechír" + - "&5before he became a lord." + - "&5Enhanced with &bArcane Dust" + enchantments: + DURABILITY: + lvl: 2 + salvage_value: 24 + urnoroth_club: + id: LOTR_ITEMSWORDTAUREDAIN + name: "&cClub of Úrnoroth" + lore: + - "&7Unrepairable I" + - "&5Club used by Úrnoroth to become the chieftain." + - "&5It seems a bit unwieldy when you aren't a troll." + enchantments: + DURABILITY: + lvl: 2 + salvage_value: 24 + upgrades_to: superior_urnoroth_club + upgrade_cost: 128 + upgrade_mode: "modifier" + superior_urnoroth_club: + id: LOTR_ITEMSWORDTAUREDAIN + name: "&cSuperior Club of Úrnoroth" + lore: + - "&7Unrepairable II" + - "&5Club used by Úrnoroth to become the chieftain." + - "&5It seems a bit unwieldy when you aren't a troll." + - "&5Enhanced with &bArcane Dust" + enchantments: + DURABILITY: + lvl: 4 + salvage_value: 24 + anarore_bow: + id: LOTR_ITEMRIVENDELLBOW + name: "&bAnarórë's Bow" + lore: + - "&7Unrepairable I" + - "&5Bow used by Captain Anarórë of Valar" + - "&5before rising to the rank of Captain." + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 24 + upgrades_to: superior_anarore_bow + upgrade_cost: 128 + upgrade_mode: "modifier" + superior_anarore_bow: + id: LOTR_ITEMRIVENDELLBOW + name: "&bSuperior Anarórë's Bow" + lore: + - "&7Unrepairable II" + - "&5Bow used by Captain Anarórë of Valar" + - "&5before rising to the rank of Captain." + - "&5Enhanced with &bArcane Dust" + enchantments: + DURABILITY: + lvl: 2 + salvage_value: 24 + burguul_durub_blade: + id: LOTR_ITEMMORGULBLADE + name: "&5Blade of Burguul-durub" + lore: + - "&7Unrepairable I" + - "&5Morgul blade wielded by Commander Burguul-durub" + - "&5of Sauron's forces in the Frozen Refuge." + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 24 + upgrades_to: superior_burguul_durub_blade + upgrade_cost: 128 + upgrade_mode: "modifier" + superior_burguul_durub_blade: + id: LOTR_ITEMMORGULBLADE + name: "&5Superior Blade of Burguul-durub" + lore: + - "&7Unrepairable II" + - "&5Morgul blade wielded by Commander Burguul-durub" + - "&5of Sauron's forces in the Frozen Refuge." + - "&5Enhanced with &bArcane Dust" + enchantments: + DURABILITY: + lvl: 2 + salvage_value: 24 + ashforged_axe: + id: LOTR_ITEMBATTLEAXEBLACKURUK + name: "&8Ash-Forged Axe" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A battleaxe crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5The axe doesn't seem to" + - "&5reflect any light" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 2 + DURABILITY: + lvl: 3 + salvage_value: 4 + upgrades_to: superior_ashforged_axe + upgrade_cost: 256 + upgrade_mode: "modifier" + ashforged_spear: + id: LOTR_ITEMSPEARCORSAIR + name: "&8Ash-Forged Harpoon" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A spear crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5The spear feels to aim towards" + - "&5the hearts of any living thing." + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 2 + DURABILITY: + lvl: 3 + KNOCKBACK: + lvl: 1 + salvage_value: 4 + upgrades_to: superior_ashforged_spear + upgrade_cost: 256 + upgrade_mode: "modifier" + ashforged_dagger: + id: LOTR_ITEMDAGGERBLACKURUK + name: "&8Ash-Forged Dagger" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A dagger crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5The blade is razor sharp." + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 3 + DURABILITY: + lvl: 3 + salvage_value: 4 + upgrades_to: superior_ashforged_dagger + upgrade_cost: 256 + upgrade_mode: "modifier" + ashforged_staff: + id: LOTR_ITEMPOLEARMWOODELVEN + name: "&8Ash-Forged Staff" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A staff crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5It feels very lightweight" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 2 + DURABILITY: + lvl: 3 + salvage_value: 4 + upgrades_to: superior_ashforged_staff + upgrade_cost: 256 + upgrade_mode: "modifier" + ashforged_pike: + id: LOTR_ITEMPIKEDOLGULDUR + name: "&8Ash-Forged Pike" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A pike crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5The tip seems to glow at night." + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 2 + DURABILITY: + lvl: 3 + salvage_value: 4 + upgrades_to: superior_ashforged_pike + upgrade_cost: 256 + upgrade_mode: "modifier" + ashforged_blade: + id: LOTR_ITEMSCIMITARBLACKURUK + name: "&8Ash-Forged Blade" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A blade crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5It feels warm to the touch" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 1 + DURABILITY: + lvl: 3 + salvage_value: 4 + upgrades_to: superior_ashforged_blade + upgrade_cost: 256 + upgrade_mode: "modifier" + ashforged_bow: + id: LOTR_ITEMBLACKROOTBOW + name: "&8Ash-Forged Bow" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A bow crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5The bow seems to not break" + - "&5despite how hard you pull the" + - "&5string." + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + ARROW_DAMAGE: + lvl: 1 + DURABILITY: + lvl: 3 + salvage_value: 4 + upgrades_to: superior_ashforged_bow + upgrade_cost: 256 + upgrade_mode: "modifier" + superior_ashforged_axe: + id: LOTR_ITEMBATTLEAXEBLACKURUK + name: "&8Superior Ash-Forged Axe" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A battleaxe crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5The axe doesn't seem to" + - "&5reflect any light" + - "&5Enhanced with &bArcane Dust" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 2 + DURABILITY: + lvl: 3 + salvage_value: 16 + superior_ashforged_spear: + id: LOTR_ITEMSPEARCORSAIR + name: "&8Superior Ash-Forged Harpoon" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A spear crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5The spear feels to aim towards" + - "&5the hearts of any living thing." + - "&5Enhanced with &bArcane Dust" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 2 + DURABILITY: + lvl: 3 + KNOCKBACK: + lvl: 1 + salvage_value: 16 + superior_ashforged_dagger: + id: LOTR_ITEMDAGGERBLACKURUK + name: "&8Superior Ash-Forged Dagger" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A dagger crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5The blade is razor sharp." + - "&5Enhanced with &bArcane Dust" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 3 + DURABILITY: + lvl: 3 + salvage_value: 16 + superior_ashforged_staff: + id: LOTR_ITEMPOLEARMWOODELVEN + name: "&8Superior Ash-Forged Staff" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A staff crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5It feels very lightweight" + - "&5Enhanced with &bArcane Dust" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 2 + DURABILITY: + lvl: 3 + salvage_value: 16 + superior_ashforged_pike: + id: LOTR_ITEMPIKEDOLGULDUR + name: "&8Superior Ash-Forged Pike" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A pike crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5The tip seems to glow at night." + - "&5Enhanced with &bArcane Dust" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 2 + DURABILITY: + lvl: 3 + salvage_value: 16 + superior_ashforged_blade: + id: LOTR_ITEMSCIMITARBLACKURUK + name: "&8Superior Ash-Forged Blade" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A blade crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5It feels warm to the touch" + - "&5Enhanced with &bArcane Dust" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 1 + DURABILITY: + lvl: 3 + salvage_value: 16 + superior_ashforged_bow: + id: LOTR_ITEMBLACKROOTBOW + name: "&8Superior Ash-Forged Bow" + lore: + - "&6Status: &7Ash Crate Drop" + - "&8====================" + - "&5A bow crafted at the Blackforge" + - "&5Imbued with magical power" + - "&5The bow seems to not break" + - "&5despite how hard you pull the" + - "&5string." + - "&5Enhanced with &bArcane Dust" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + ARROW_DAMAGE: + lvl: 1 + DURABILITY: + lvl: 3 + salvage_value: 16 + crypt_bow: + id: LOTR_ITEMGUNDABADURUKBOW + name: "&8Crypt Bow" + lore: + - "&8====================" + - "&5An ancient bow found in the," + - "&5Crypts under Spawn" + - "&8====================" + - "&aUsable in War" + - "&8====================" + enchantments: + ARROW_DAMAGE: + lvl: 2 + salvage_value: 2 + upgrades_to: superior_crypt_bow + upgrade_cost: 64 + upgrade_mode: "enchant" + crypt_sword: + id: LOTR_ITEMSWORDROHAN + name: "&8Crypt Sword" + lore: + - "&8====================" + - "&5A blade found deep in the," + - "&5Crypts under Spawn" + - "&8====================" + - "&aUsable in War" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 1 + salvage_value: 1 + upgrades_to: superior_crypt_sword + upgrade_cost: 64 + upgrade_mode: "enchant" + superior_crypt_bow: + id: LOTR_ITEMGUNDABADURUKBOW + name: "&8Superior Crypt Bow" + lore: + - "&8====================" + - "&5An ancient bow found in the," + - "&5Crypts under Spawn" + - "&5Enhanced with &bArcane Dust" + - "&8====================" + - "&aUsable in War" + - "&8====================" + enchantments: + ARROW_DAMAGE: + lvl: 4 + salvage_value: 4 + superior_crypt_sword: + id: LOTR_ITEMSWORDROHAN + name: "&8Superior Crypt Sword" + lore: + - "&8====================" + - "&5A blade found deep in the," + - "&5Crypts under Spawn" + - "&5Enhanced with &bArcane Dust" + - "&8====================" + - "&aUsable in War" + - "&8====================" + enchantments: + DAMAGE_ALL: + lvl: 2 + salvage_value: 4 + black_ash: + id: LOTR_ITEMDYE + name: "&8Black Ash" + lore: + - "&7Swift: x1.25 melee speed" + - "&7Swift: x1.25 melee speed" + salvage_value: 2 + ash_twine: + id: LOTR_ITEMHITHLAIN + name: "&8Ash Twine" + lore: + - "&7Strong: x1.1 launch speed" + - "&7Striking: +2 knockback" + salvage_value: 2 + ash_plate: + id: LOTR_ITEMMITHRILMAIL + name: "&8Pale-Ash plate" + lore: + - "&7Steadfast: +2 protection" + - "&8or" + - "&7Tough: +1 protection" + salvage_value: 2 + ash_steel: + id: LOTR_ITEMGALVORN + name: "&8Ash-Forged Steel" + lore: + - "&7Keen: +1.0 melee damage" + - "&7Mighty: +2.0 melee damage" + salvage_value: 2 + brimstone: + id: LOTR_ITEMAMBER + name: "&6Brimstone" + lore: + - "&7Enduring: x2.0 durability" + - "&7Enduring: x2.0 durability" + - "&8&oRequest Mod+ to apply" + salvage_value: 2 + crystalized_steel: + id: LOTR_ITEMGILDEDIRON + name: "&6Crystalized Steel" + lore: + - "&7Eölean: +3 protection vs. projectiles" + - "&7Unwithering: +3 protection vs. fire" + - "&8&oRequest Mod+ to apply" + salvage_value: 2 + brimstone_dust: + id: LOTR_ITEMSULFUR + name: "&6Brimstone Dust" + lore: + - "&7Masterful: x4.0 tool speed" + - "&7Masterful: x4.0 tool speed" + - "&8&oRequest Mod+ to apply" + salvage_value: 2 + crystalized_pickaxe_unpatched: + id: LOTR_ITEMPICKAXETAUREDAIN + name: "&eCrystalized Pickaxe" + lore: + - "&6Status: &eEmber Crate Drop" + - "&8====================" + - "&5A stonepounder burned away" + - "&5from all impurities and left in its Crystal" + - "&5and Magical form, allowing" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DIG_SPEED: + lvl: 2 + DURABILITY: + lvl: 3 + salvage_value: 4 + crystalized_shovel: + id: LOTR_ITEMSHOVELELVEN + name: "&eCrystalized Shovel" + lore: + - "&6Status: &eEmber Crate Drop" + - "&8====================" + - "&5An Obsidian Shovel infused with" + - "&5magical brimstone, making the" + - "&5shovel much more durable." + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DIG_SPEED: + lvl: 5 + DURABILITY: + lvl: 7 + salvage_value: 4 + crystalized_axe: + id: LOTR_ITEMAXEROHAN + name: "&eCrystalized Axe" + lore: + - "&6Status: &eEmber Crate Drop" + - "&8====================" + - "&5A Lumberjacks axe infused with" + - "&5magical brimstone, making the" + - "&5axe much more durable." + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DIG_SPEED: + lvl: 5 + DURABILITY: + lvl: 15 + salvage_value: 4 + ember_mattock: + id: LOTR_ITEMMATTOCKMITHRIL + name: "&eCrystalized Pickaxe" + lore: + - "&6Status: &eEmber Crate Drop" + - "&8====================" + - "&5A mattock enchanted by the" + - "&5Ember-books, imbuing it with" + - "&5magical power" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DIG_SPEED: + lvl: 3 + LOOT_BONUS_BLOCKS: + lvl: 1 + salvage_value: 4 + stone_pounder: + id: LOTR_ITEMPICKAXEMALLORN + name: "&cStone Pounder" + lore: + - "&6Status: &eEmber Crate Drop" + - "&8====================" + - "&5A bright colored pick" + - "&5strangely lightweight" + - "&5but at the moment it touches" + - "&5stone, it disintegrates it to dust" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DIG_SPEED: + lvl: 10 + DURABILITY: + lvl: 10 + salvage_value: 4 + obsidian_spade: + id: LOTR_ITEMSHOVELTAUREDAIN + name: "&8Obsidian Spade" + lore: + - "&6Status: &eEmber Crate Drop" + - "&8====================" + - "&5A dark spade with a" + - "&5a reinforced handle" + - "&5A very light and efficient" + - "&5Shovel" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DIG_SPEED: + lvl: 5 + DURABILITY: + lvl: 3 + salvage_value: 4 + lumberjacks_axe: + id: LOTR_ITEMBATTLEAXEURUK + name: "&6Lumberjacks Axe" + lore: + - "&6Status: &eEmber Crate Drop" + - "&8====================" + - "&5A massive axe that can chop trees" + - "&5with great efficiency" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DIG_SPEED: + lvl: 5 + DURABILITY: + lvl: 10 + salvage_value: 4 + ember_hoe: + id: LOTR_ITEMHOEMITHRIL + name: "&6Ember Hoe" + lore: + - "&6Status: &eEmber Crate Drop" + - "&8====================" + - "&5A hoe enchanted by the" + - "&5Ember-books, imbuing it with" + - "&5magical power" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&8====================" + enchantments: + DURABILITY: + lvl: 10 + salvage_value: 4 + hunters_jacket: + id: LOTR_ITEMBODYGEMSBOK + name: "&3Hunters Jacket" + lore: + - "&6Status: &eEmber Crate Drop" + - "&8====================" + - "&5A jacket made from the hides" + - "&5of different animals" + - "&8====================" + - "&aCan be modified?: &2&lYes" + - "&aCan be bound?: &c&lNo" + - "&c&lMuist be worn if brought to war." + - "&8====================" + - "&6Effects:" + - "&6 &9SPEED &f1" + enchantments: + DURABILITY: + lvl: 2 + salvage_value: 2 + binding_permit: + id: ENCHANTED_BOOK + name: "&cTemporary &bBinding &6Permit" + lore: + - "&aRedeem to an Admin to use" + - "&7-" + - "&cAllows you to have the weapon of choice" + - "&cTo be bound for the &nnext battle" + - "&cCan only be added to weapons with" + - "&cthe other 2 permits applied" + - "&aPermit 3/3" + - "&7-" + - "&4Consumed when used" + enchantments: + ARROW_INFINITE: + lvl: 1 + salvage_value: 2 + name_permit: + id: LOTR_ITEMTEMPLATE + name: "&bEpic &cName &6Permit" + lore: + - "&aRedeem to an Admin to use" + - "&7-" + - "&cAllows you to rename one item" + - "&cwith any color or text formatting codes" + - "&cof your choice" + - "&aPermit 1/3" + - "&7-" + - "&4Consumed when used" + enchantments: + ARROW_INFINITE: + lvl: 1 + salvage_value: 2 + lore_permit: + id: LOTR_ITEMMITHRILBOOK + name: "&bLore &6Permit" + lore: + - "&aRedeem to an Admin to use" + - "&7-" + - "&cAllows you to add lore text to one item" + - "&cWith any single color you want" + - "&aPermit 2/3" + - "&7-" + - "&4Consumed when used" + enchantments: + ARROW_INFINITE: + lvl: 1 + salvage_value: 2 + tome_lightweight: + id: LOTR_ITEMMITHRILBOOK + name: "&dTome of Lightweight" + lore: + - "&6You can request staff to add Feather Falling" + - "&6on any pair of boots, this is stackable." + - "&6&oAdds Feather Falling I upon use." + enchantments: + PROTECTION_FALL: + lvl: 1 + salvage_value: 2 + tome_infinity: + id: LOTR_ITEMMITHRILBOOK + name: "&bTome of Infinity" + lore: + - "&6You can request staff to put infinity" + - "&6on any item." + - "&6&oAdds Infinity I upon use" + enchantments: + ARROW_INFINITE: + lvl: 1 + salvage_value: 2 + tome_thorns: + id: LOTR_ITEMMITHRILBOOK + name: "&8Tome of Thorns" + lore: + - "&6You can request staff to add Thorns" + - "&6on any armor piece,." + - "&6&oAdds Thorns I upon use." + - "&8Max Level is 3" + enchantments: + THORNS: + lvl: 1 + salvage_value: 2 + tome_durability: + id: LOTR_ITEMMITHRILBOOK + name: "&aTome of Durability" + lore: + - "&6You can request staff to put a Durability Modifier" + - "&6on any item, This item maxes out on 3" + - "&6durability mods, then upgrades them." + - "&73 Hardy/, 2 Hardy 1 Lasting etc" + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 2 + guild_hammer: + id: LOTR_ITEMMITHRILBOOK + name: "&2Holy Guild Hammer" + lore: + - "&7Unrepairable I" + - "&8====================" + - "&aThe hammer used only by" + - "&athe strongest within the guild" + - "&ato bring the rightious might" + - "&aof all Archeologists upon their enemy" + - "&8====================" + enchantments: + KNOCKBACK: + lvl: 1 + salvage_value: 4 + upgrades_to: superior_guild_hammer + upgrade_cost: 64 + upgrade_mode: "modifier" + superior_guild_hammer: + id: LOTR_ITEMBLACKSMITHHAMMER + name: "&2Superior Holy Guild Hammer" + lore: + - "&7Unrepairable II" + - "&8====================" + - "&aThe hammer used only by" + - "&athe strongest within the guild" + - "&ato bring the rightious might" + - "&aof all Archeologists upon their enemy" + - "&5Enhanced with &bArcane Dust" + - "&8====================" + enchantments: + KNOCKBACK: + lvl: 1 + salvage_value: 8 + guild_shovel: + id: IRON_SHOVEL + name: "&2Guild Shovel" + lore: + - "&7Unrepairable I" + - "&8====================" + - "&aThis shovel is given to" + - "&aevery new member of the Guild" + - "&ausually to be used at digsites" + - "&aoperated by the Guild" + - "&8====================" + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 4 + guild_pickaxe: + id: IRON_PICKAXE + name: "&2Guild Pickaxe" + lore: + - "&7Unrepairable I" + - "&8====================" + - "&aThis pickaxe is given to" + - "&aevery new member of the Guild" + - "&ausually to be used at digsites" + - "&aoperated by the Guild" + - "&8====================" + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 4 + ring_of_loyalty: + id: LOTR_ITEMDWARVENRING + name: "&9Ring of Loyalty" + lore: + - "&8====================" + - "&3The ring given to the most" + - "&3profitable and loyal members of" + - "&3the Archeologist Guild, the ring" + - "&3seems to have a strange and mythical" + - "&3gem embedded within it." + - "&8====================" + - "&6Effects:" + - "&6 &9FAST_DIGGING &f1" + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 4 + bloody_axe: + id: LOTR_ITEMBATTLEAXEDALE + name: "&4Bloody Axe" + lore: + - "&7Unrepairable I" + - "&8====================" + - "&cA ceremonial axe given to" + - "&cthe members of the Bounty Guild" + - "&cfor succeeding in their first" + - "&cbounty hunt or kill" + - "&8====================" + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 4 + upgrades_to: superior_bloody_axe + upgrade_cost: 64 + upgrade_mode: "modifier" + superior_bloody_axe: + id: LOTR_ITEMBATTLEAXEDALE + name: "&4Superior Bloody Axe" + lore: + - "&7Unrepairable II" + - "&8====================" + - "&cA ceremonial axe given to" + - "&cthe members of the Bounty Guild" + - "&cfor succeeding in their first" + - "&cbounty hunt or kill" + - "&5Enhanced with &bArcane Dust" + - "&8====================" + enchantments: + DURABILITY: + lvl: 2 + salvage_value: 8 + captains_sword: + id: LOTR_ITEMCOMMANDSWORD + name: "&6Captain's Sword" + enchantments: + DAMAGE_ALL: + lvl: 4 + salvage_value: 4 + upgrades_to: superior_captains_sword + upgrade_cost: 256 + upgrade_mode: "modifier" + superior_captains_sword: + id: LOTR_ITEMCOMMANDSWORD + name: "&6Superior Captain's Sword" + enchantments: + DAMAGE_ALL: + lvl: 5 + salvage_value: 8 + key_valar: + id: LOTR_ITEMITHILDIN + name: "&bKey Piece (Valar)" + lore: + - "&5Piece of the Frozen Key" + - "&5collected from the commander of Valar's forces" + - "&5in the Frozen Refuge." + enchantments: + ARROW_DAMAGE: + lvl: 1 + salvage_value: 2 + key_mortals: + id: LOTR_ITEMUTUMNOKEY + name: "&bKey Piece (Mortals)" + lore: + - "&5Piece of the Frozen Key" + - "&5collected from the lord of the Mortals" + - "&5in the Frozen Refuge." + enchantments: + ARROW_DAMAGE: + lvl: 1 + salvage_value: 2 + key_udun: + id: LOTR_ITEMUTUMNOKEY + name: "&bKey Piece (Udûn)" + lore: + - "&5Piece of the Frozen Key" + - "&5collected from the commander of Udûn's forces" + - "&5in the Frozen Refuge." + enchantments: + ARROW_DAMAGE: + lvl: 1 + salvage_value: 2 + key_sauron: + id: LOTR_ITEMUTUMNOKEY + name: "&bKey Piece (Sauron)" + lore: + - "&5Piece of the Frozen Key" + - "&5collected from the commander of Sauron's forces" + - "&5in the Frozen Refuge." + enchantments: + ARROW_DAMAGE: + lvl: 1 + salvage_value: 2 + gem_valar: + id: LOTR_ITEMQUENDITECRYSTAL + name: "&bGem of the Valar" + lore: + - "&5This gem has been imbued" + - "&5with the magic of Valar," + - "&5to be harnessed in Nimveil." + - "&aCombine with Nimveil hilt and Godsteel" + - "&ato attune the blade to the Valar." + - "&aRequires Enchanted Hammer or Celebrimbor's Blacksmith Hammer to forge" + enchantments: + ARROW_DAMAGE: + lvl: 1 + salvage_value: 1 + gem_mortals: + id: LOTR_ITEMOBSIDIANSHARD + name: "&aStone of the Mortals" + lore: + - "&5This gem has been imbued" + - "&5with the magic of the ancient Mortal Men," + - "&5to be harnessed in Nimveil." + - "&aCombine with Nimveil hilt and Godsteel" + - "&ato attune the blade to the Mortals" + - "&aRequires Enchanted Hammer or Celebrimbor's Blacksmith Hammer to forge" + enchantments: + ARROW_DAMAGE: + lvl: 1 + salvage_value: 1 + gem_udun: + id: LOTR_ITEMDYE + name: "&cDust of Udûn" + lore: + - "&5This dust has been imbued" + - "&5with the remnants of Morgoth's magic," + - "&5to be harnessed in Nimveil." + - "&aCombine with Nimveil hilt and Godsteel" + - "&ato attune the blade to Udûn" + - "&aRequires Enchanted Hammer or Celebrimbor's Blacksmith Hammer to forge" + enchantments: + ARROW_DAMAGE: + lvl: 1 + salvage_value: 1 + gem_sauron: + id: LOTR_ITEMMITHRILMAIL + name: "&5Chain of Sauron" + lore: + - "&5This chain has been imbued" + - "&5with the sorcery of Sauron," + - "&5to be harnessed in Nimveil." + - "&aCombine with Nimveil hilt and Godsteel" + - "&ato attune the blade to Sauron" + - "&aRequires Enchanted Hammer or Celebrimbor's Blacksmith Hammer to forge" + enchantments: + ARROW_DAMAGE: + lvl: 1 + salvage_value: 1 + ice_thawer: + id: LOTR_ITEMOPAL + name: "&bIce Thawer" + lore: + - "&5You feel like if you held this" + - "&5against a frozen body, it might melt." + - "&5But why would you need such a thing?" + enchantments: + ARROW_DAMAGE: + lvl: 1 + salvage_value: 4 + nimveil_hilt: + id: LOTR_ITEMBLACKROOTSTICK + name: "&7Hilt of Nimveil" + lore: + - "&5Carefully crafted hilt," + - "&5with intricate carvings and trimming," + - "&5designed for no less than" + - "&5withstanding the power of Nimveil" + - "&aCombine with enchanted item and Godsteel to create Nimveil" + - "&aRequires Enchanted Hammer or Celebrimbor's Blacksmith Hammer to forge" + enchantments: + ARROW_DAMAGE: + lvl: 1 + salvage_value: 4 + nimveil_hammer: + id: LOTR_ITEMBLACKSMITHHAMMER + name: "&bMagical&5 &bHammer" + lore: + - "&5Carefully crafted hilt," + - "&5with intricate carvings and trimming," + - "&5designed for no less than" + - "&5withstanding the power of Nimveil" + - "&aCombine with enchanted item and Godsteel to create Nimveil" + - "&aRequires Enchanted Hammer or Celebrimbor's Blacksmith Hammer to forge" + enchantments: + ARROW_DAMAGE: + lvl: 1 + salvage_value: 4 + glaechir_spear_part_1: + id: LOTR_ITEMBLACKROOTSTICK + name: "&2Glaechír's spear shaft" + lore: + - "&5Piece of Lord Glaechír's old spear." + - "&5Assemble the spear using tip, shaft and binding." + salvage_value: 8 + glaechir_spear_part_2: + id: LOTR_ITEMANCIENTPARTS + name: "&2Glaechír's spear tip" + lore: + - "&5Piece of Lord Glaechír's old spear." + - "&5Assemble the spear using tip, shaft and binding." + salvage_value: 8 + glaechir_spear_part_3: + id: GOLD_NUGGET + name: "&2Glaechír's spear binding" + lore: + - "&5Piece of Lord Glaechír's old spear." + - "&5Assemble the spear using tip, shaft and binding." + salvage_value: 8 + morgul_sword_part_1: + id: LOTR_ITEMBLACKROOTSTICK + name: "&2Morgul Hilt" + lore: + - "&5Hilt from the shattered blade of Burguul-durub." + - "&5Forge the blade using steel, crossguard and hilt." + salvage_value: 8 + morgul_sword_part_2: + id: LOTR_ITEMUTUMNOKEY + name: "&2Morgul Crossguard" + lore: + - "&5Crossguard from the shattered blade of Burguul-durub." + - "&5Forge the blade using steel, crossguard and hilt." + salvage_value: 8 + morgul_sword_part_3: + id: LOTR_ITEMMORGULSTEEL + name: "&2Cursed Steel" + lore: + - "&5Steel to reforge the shattered blade of Burguul-durub." + - "&5Forge the blade using steel, crossguard and hilt." + salvage_value: 8 + anarore_bow_part_1: + id: LOTR_ITEMHITHLAIN + name: "&bBlessed Bowstring" + lore: + - "&5Bowstring blessed by Manwë." + - "&5Assemble the bow using bow halves and bowstring." + salvage_value: 8 + anarore_bow_part_2: + id: LOTR_ITEMMALLORNSTICK + name: "&bBottom of Anarórë's Bow" + lore: + - "&5Bottom half of Anarórë's bow." + - "&5Assemble the bow using bow halves and bowstring." + salvage_value: 8 + anarore_bow_part_3: + id: LOTR_ITEMMALLORNSTICK + name: "&bTop of Anarórë's Bow" + lore: + - "&5Top half of Anarórë's bow." + - "&5Assemble the bow using bow halves and bowstring." + salvage_value: 8 + urnoroth_club_part_1: + id: LOTR_ITEMDYE + name: "&cTroll-club wax" + lore: + - "&5Wax used to harden the troll-clubs." + - "&5Restore the club with troll-club, spike and wax." + salvage_value: 8 + urnoroth_club_part_2: + id: LOTR_TILESTALACTITEOBSIDIAN + name: "&cUdûn spike" + lore: + - "&5Special spike used in best troll-clubs." + - "&5Restore the club with troll-club, spike and wax." + salvage_value: 8 + urnoroth_club_part_3: + id: LOTR_ITEMDUNLENDINGCLUB + name: "&cTroll-club" + lore: + - "&5Club of Úrnoroth, now worn and cracked." + - "&5Restore the club with troll-club, spike and wax." + salvage_value: 8 + jewelled_boots: + id: LOTR_ITEMBOOTSGONDOLIN + name: "&aJewelled Boots" + lore: + - "&6Status: &bDungeon Loot" + - "&8&n~~~~~~~~~~~~~~~~~~~~" + - "&5Plated Boots decorated with" + - "&5glowing jewels from the" + - "&5Dungeon" + - "&8&n~~~~~~~~~~~~~~~~~~~~" + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 3 + jewelled_leggings: + id: LOTR_ITEMLEGSGONDOLIN + name: "&aJewelled Leggings" + lore: + - "&6Status: &bDungeon Loot" + - "&8&n~~~~~~~~~~~~~~~~~~~~" + - "&5Plated Leggings decorated with" + - "&5glowing jewels from the" + - "&5Dungeon" + - "&8&n~~~~~~~~~~~~~~~~~~~~" + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 3 + jewelled_chestplate: + id: LOTR_ITEMBODYGONDOLIN + name: "&aJewelled Chestplate" + lore: + - "&6Status: &bDungeon Loot" + - "&8&n~~~~~~~~~~~~~~~~~~~~" + - "&5Chestplate decorated with" + - "&5glowing jewels from the" + - "&5Dungeon" + - "&8&n~~~~~~~~~~~~~~~~~~~~" + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 3 + jewelled_helm: + id: LOTR_ITEMHELMETGONDOLIN + name: "&aJewelled Helm" + lore: + - "&6Status: &bDungeon Loot" + - "&8&n~~~~~~~~~~~~~~~~~~~~" + - "&5Helmet decorated with" + - "&5glowing jewels from the" + - "&5Dungeon" + - "&8&n~~~~~~~~~~~~~~~~~~~~" + enchantments: + DURABILITY: + lvl: 1 + salvage_value: 3 + jewelled_blade: + id: LOTR_ITEMDAGGERBARROW + name: "&aJewelled Blade" + lore: + - "&6Status: &bDungeon Loot" + - "&8&n~~~~~~~~~~~~~~~~~~~~" + - "&5A blade decorated" + - "&5with glowing jewels" + - "&5it seems to hurt the undead" + - "&5more than living things" + - "&8&n~~~~~~~~~~~~~~~~~~~~" + enchantments: + DAMAGE_UNDEAD: + lvl: 5 + salvage_value: 3 + severing_knife: + id: LOTR_ITEMDAGGERGUNDABADURUK + name: "&8Severing Knife" + lore: + - "&3This knife is able to sever the" + - "&3Immortality from a canonized character" + - "&7&oYou will have to slay the character" + - "&7&oin battle to activate this blade" + enchantments: + DAMAGE_ALL: + lvl: 1 + salvage_value: 64 + revival_dust: + id: LOTR_ITEMITHILDIN + name: "&bRevival Dust" + lore: + - "&6Use this to revive a Lore Character" + - "&6Or return it to full life" + enchantments: + ARROW_INFINITE: + lvl: 1 + salvage_value: 64 diff --git a/src/main/resources/plugin.yml b/src/main/resources/plugin.yml new file mode 100644 index 0000000..66223e7 --- /dev/null +++ b/src/main/resources/plugin.yml @@ -0,0 +1,4 @@ +main: com.zivilon.itemsalvage.ItemSalvage +name: ItemSalvage +author: Shinare +version: 1.0 diff --git a/src/main/resources/salvage.yml b/src/main/resources/salvage.yml new file mode 100644 index 0000000..75f9d4b --- /dev/null +++ b/src/main/resources/salvage.yml @@ -0,0 +1,6 @@ +salvage: + item: LOTR_ITEMITHILDIN + name: &bArcane Dust + lore: + - &5This is lore text + - &5But this time we have a second line \ No newline at end of file