diff --git a/src/main/java/minevalley/core/api/crafting/CraftSystemManager.java b/src/main/java/minevalley/core/api/crafting/CraftSystemManager.java deleted file mode 100644 index 3a71e7bd..00000000 --- a/src/main/java/minevalley/core/api/crafting/CraftSystemManager.java +++ /dev/null @@ -1,38 +0,0 @@ -package minevalley.core.api.crafting; - -import minevalley.core.api.crafting.recipe.Recipe; -import minevalley.core.api.crafting.recipe.builder.RecipeBuilder; -import minevalley.core.api.crafting.recipe.builder.RecipeItemBuilder; - -@SuppressWarnings("unused") -public interface CraftSystemManager { - - /** - * Register a recipe - * - * @param recipe to be registered - */ - void registerRecipe(Recipe recipe); - - /** - * Unregister a recipe - * - * @param recipe to be unregistered - */ - void unregisterRecipe(Recipe recipe); - - /** - * Create a new {@link RecipeBuilder} with the {@link RecipeBuilder} Builder - * - * @return {@link RecipeBuilder} - */ - RecipeBuilder createRecipe(); - - /** - * Create a new {@link RecipeItemBuilder} with the {@link RecipeItemBuilder} Builder - * - * @return {@link RecipeItemBuilder} - */ - RecipeItemBuilder createRecipeItem(); - -} diff --git a/src/main/java/minevalley/core/api/crafting/IndustrialWorkbench.java b/src/main/java/minevalley/core/api/crafting/IndustrialWorkbench.java deleted file mode 100644 index 96c30ae2..00000000 --- a/src/main/java/minevalley/core/api/crafting/IndustrialWorkbench.java +++ /dev/null @@ -1,68 +0,0 @@ -package minevalley.core.api.crafting; - -import minevalley.core.api.users.OnlineUser; -import org.bukkit.inventory.Inventory; -import org.bukkit.inventory.ItemStack; - -import java.util.List; - -@SuppressWarnings("unused") -public interface IndustrialWorkbench { - - /** - * Gets the current workbench content - * (Only contains the contents of the free slots) - * - * @return Workbench Content - */ - List getWorkbenchContent(); - - /** - * Destroy the workbench and drop all items - */ - void destroy(); - - /** - * Update the workbench to check if new recipes are available - */ - void update(); - - /** - * Perform the craft in the workbench - */ - void craft(); - - /** - * Closes the Workbench and stores the items into the shulker - */ - void close(); - - /** - * Open the workbench with the stored items - * - * @param user The user to open a workbench - */ - void open(OnlineUser user); - - /** - * Gets the inventory of the workbench - * - * @return Inventory Instance of the workbench - */ - Inventory getInventory(); - - /** - * Sets the workbench power level - * - * @param level Power level of the workbench - */ - void setPowerLevel(int level); - - /** - * Gets the workbench power level - * - * @return Power level of the workbench - */ - int getPowerLevel(); - -} diff --git a/src/main/java/minevalley/core/api/crafting/recipe/Recipe.java b/src/main/java/minevalley/core/api/crafting/recipe/Recipe.java deleted file mode 100644 index df76b1a4..00000000 --- a/src/main/java/minevalley/core/api/crafting/recipe/Recipe.java +++ /dev/null @@ -1,46 +0,0 @@ -package minevalley.core.api.crafting.recipe; - -import org.bukkit.inventory.ItemStack; - -import java.util.Map; - -@SuppressWarnings("unused") -public interface Recipe { - - /** - * Gets the recipe name - * - * @return Recipe name - */ - String getRecipeName(); - - /** - * Get the output Item - * - * @return Output ItemStack - */ - ItemStack getOutputItem(); - - /** - * Get the needed recipe ingredients - * If the recipe is marked as "setShapeless(true)" this list is used for <Slot, Item> detection - * - * @return Map with ingredients and slots - */ - Map getRecipeIngredients(); - - /** - * Checks if the recipe is shapeless - * - * @return if recipe is shapeless or shaped - */ - boolean isShapeless(); - - /** - * Checks how many power levels the craft process needs - * - * @return Craft costs level - */ - int getCraftPowerConsumption(); - -} diff --git a/src/main/java/minevalley/core/api/crafting/recipe/RecipeItem.java b/src/main/java/minevalley/core/api/crafting/recipe/RecipeItem.java deleted file mode 100644 index 1a5b48ff..00000000 --- a/src/main/java/minevalley/core/api/crafting/recipe/RecipeItem.java +++ /dev/null @@ -1,39 +0,0 @@ -package minevalley.core.api.crafting.recipe; - -import minevalley.core.api.crafting.recipe.requirements.Requirement; -import org.bukkit.inventory.ItemStack; - -import java.util.List; - -@SuppressWarnings("unused") -public interface RecipeItem { - - /** - * Gets the item - * - * @return ItemStack of the RecipeItem - */ - ItemStack getItem(); - - /** - * Check if the items needs to match the ItemMeta or ignore it - * - * @return boolean - */ - boolean isIgnoringMetadata(); - - /** - * Get the amount of the craft component - * - * @return Amount of craft components needed - */ - int getAmount(); - - /** - * Get the Requirements of the Item which are needed to "allow" the crafting - * - * @return List with the Requirements - */ - List getRequirements(); - -} diff --git a/src/main/java/minevalley/core/api/crafting/recipe/builder/RecipeBuilder.java b/src/main/java/minevalley/core/api/crafting/recipe/builder/RecipeBuilder.java deleted file mode 100644 index a4ffa81e..00000000 --- a/src/main/java/minevalley/core/api/crafting/recipe/builder/RecipeBuilder.java +++ /dev/null @@ -1,70 +0,0 @@ -package minevalley.core.api.crafting.recipe.builder; - -import minevalley.core.api.crafting.recipe.Recipe; -import minevalley.core.api.crafting.recipe.RecipeItem; -import org.bukkit.inventory.ItemStack; - -import java.util.Map; - -@SuppressWarnings("unused") -public interface RecipeBuilder { - - /** - * Set the recipe name - * - * @param name as string - * @return this - */ - RecipeBuilder setRecipeName(String name); - - /** - * Set the item that's gonna crafted - * - * @param output resulting item stack - * @return this - */ - RecipeBuilder setOutputItem(ItemStack output); - - /** - * Set the ingredients which are needed for the recipe - * If the recipe is marked as "setShapeless(true)" this list is used for detection - * - * @param ingredients List of ingredients - * @return this - */ - RecipeBuilder setIngredients(Map ingredients); - - /** - * Add a new ingredient which is needed for the recipe - * If the recipe is marked as "setShapeless(true)" this list is used for <Slot, Item> detection - * When you are using a shapeless recipe just count the slot+1 everytime you add a new ingredient - * - * @param slot Slot of the item - * @param item RecipeItem Object - * @return this - */ - RecipeBuilder addIngredient(int slot, RecipeItem item); - - /** - * Defines if the recipe is a shapeless or shaped recipe - * - * @param shapeless If the recipe is shapeless or not - * @return this - */ - RecipeBuilder setShapeless(boolean shapeless); - - /** - * Set the recipe power craft costs - * - * @param powerConsumption as integer. - * @return this - */ - RecipeBuilder setPowerConsumption(int powerConsumption); - - /** - * Creates the new instance out of the builder components - * - * @return The recipe instance object - */ - Recipe build(); -} diff --git a/src/main/java/minevalley/core/api/crafting/recipe/builder/RecipeItemBuilder.java b/src/main/java/minevalley/core/api/crafting/recipe/builder/RecipeItemBuilder.java deleted file mode 100644 index eab3657e..00000000 --- a/src/main/java/minevalley/core/api/crafting/recipe/builder/RecipeItemBuilder.java +++ /dev/null @@ -1,51 +0,0 @@ -package minevalley.core.api.crafting.recipe.builder; - -import minevalley.core.api.crafting.recipe.RecipeItem; -import minevalley.core.api.crafting.recipe.requirements.Requirement; -import org.bukkit.inventory.ItemStack; - -@SuppressWarnings("unused") -public interface RecipeItemBuilder { - - /** - * Sets the Item - * - * @param item the craft component - * @return this - */ - RecipeItemBuilder setItem(ItemStack item); - - /** - * Set if the craft component needs to match with the metadata from the inserted item (displayname, amount, meta) - * Notice: If there is a specific amount of items needed: Please get the amount from the item above! - * - * @param ignoreMetadata boolean if meta is important - * @return this - */ - RecipeItemBuilder setIgnoreMetadata(boolean ignoreMetadata); - - - /** - * Add a new Requirement to the current item - * - * @param requirement requirement which data the item needs to match - * @return this - */ - RecipeItemBuilder addRequirement(Requirement requirement); - - /** - * Replace the item after the craft-process - * - * @param item the replaced item - * @return this - */ - RecipeItemBuilder replaceItemAfterCrafting(ItemStack item); - - /** - * Creates the new instance out of the builder components - * - * @return The RecipeItem instance object - */ - RecipeItem build(); - -} diff --git a/src/main/java/minevalley/core/api/crafting/recipe/requirements/Requirement.java b/src/main/java/minevalley/core/api/crafting/recipe/requirements/Requirement.java deleted file mode 100644 index 842c1986..00000000 --- a/src/main/java/minevalley/core/api/crafting/recipe/requirements/Requirement.java +++ /dev/null @@ -1,20 +0,0 @@ -package minevalley.core.api.crafting.recipe.requirements; - -public enum Requirement { - - /** - * If the displayname is case-sensitive - */ - NAME_SENSITIVE, - - /** - * If the lore is case-sensitive - */ - LORE_SENSITIVE, - - /** - * If the amount matches with the given item - */ - MATCH_COUNT - -}