Added a message when removing a recipe

This commit is contained in:
Indyuce 2020-03-27 21:35:42 +01:00
parent 63d3fb7c1e
commit 246cb2d9a1

View File

@ -13,6 +13,7 @@ import org.bukkit.inventory.ItemFlag;
import org.bukkit.inventory.ItemStack; import org.bukkit.inventory.ItemStack;
import org.bukkit.inventory.meta.ItemMeta; import org.bukkit.inventory.meta.ItemMeta;
import net.Indyuce.mmoitems.MMOItems;
import net.Indyuce.mmoitems.MMOUtils; import net.Indyuce.mmoitems.MMOUtils;
import net.Indyuce.mmoitems.api.ConfigFile; import net.Indyuce.mmoitems.api.ConfigFile;
import net.Indyuce.mmoitems.api.Type; import net.Indyuce.mmoitems.api.Type;
@ -88,6 +89,7 @@ public class CraftingEdition extends EditionInventory {
return; return;
config.getConfig().set(id + ".crafting." + corresponding.name().toLowerCase(), null); config.getConfig().set(id + ".crafting." + corresponding.name().toLowerCase(), null);
player.sendMessage(MMOItems.plugin.getPrefix() + "Successfully removed " + corresponding.getName() + " recipe.");
if (config.getConfig().getConfigurationSection(id + ".crafting") == null) if (config.getConfig().getConfigurationSection(id + ".crafting") == null)
config.getConfig().set(id + ".crafting", null); config.getConfig().set(id + ".crafting", null);