Home Commands Examples Getting Started With Scripts Global Keywords
Generic JSON Recipes

DragonForgeRecipeManager

Importing the class

It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.

script.zs
import mods.iceandfire.recipe.DragonForgeRecipeManager;

Implemented Interfaces

DragonForgeRecipeManager implements the following interfaces. That means all methods defined in these interfaces are also available in DragonForgeRecipeManager

Methods

Adds a new Fire Dragon Forge recipe.

Return Type: void

script.zs
// DragonForgeRecipeManager.addFireRecipe(name as string, output as IItemStack, input as IIngredient, blood as IIngredient, cookTime as int) as void
<recipetype:iceandfire:dragonforge>.addFireRecipe("fire_test", <item:minecraft:diamond>, <item:minecraft:dirt>, <item:minecraft:apple>, 200);
ParameterTypeDescription
Parameter
name
Type
string
Description
The name of the recipe
Parameter
output
Type
IItemStack
Description
The output item
Parameter
input
Type
IIngredient
Description
The input Ingredient
Parameter
blood
Type
IIngredient
Description
The blood Ingredient
Parameter
cookTime
Type
int
Description
The cook time of the recipe

Adds a new Ice Dragon Forge recipe.

Return Type: void

script.zs
// DragonForgeRecipeManager.addIceRecipe(name as string, output as IItemStack, input as IIngredient, blood as IIngredient, cookTime as int) as void
<recipetype:iceandfire:dragonforge>.addIceRecipe("ice_test", <item:minecraft:diamond>, <item:minecraft:dirt>, <item:minecraft:apple>, 200);
ParameterTypeDescription
Parameter
name
Type
string
Description
The name of the recipe
Parameter
output
Type
IItemStack
Description
The output item
Parameter
input
Type
IIngredient
Description
The input Ingredient
Parameter
blood
Type
IIngredient
Description
The blood Ingredient
Parameter
cookTime
Type
int
Description
The cook time of the recipe

Return Type: void

script.zs
DragonForgeRecipeManager.addJsonRecipe(name as string, mapData as MapData) as void
ParameterTypeDescription
Parameter
name
Type
string
Description
No Description Provided
Parameter
mapData
Type
MapData
Description
No Description Provided

Adds a new Lightning Dragon Forge recipe.

Return Type: void

script.zs
// DragonForgeRecipeManager.addLightningRecipe(name as string, output as IItemStack, input as IIngredient, blood as IIngredient, cookTime as int) as void
<recipetype:iceandfire:dragonforge>.addLightningRecipe("lightning_test", <item:minecraft:diamond>, <item:minecraft:dirt>, <item:minecraft:apple>, 200);
ParameterTypeDescription
Parameter
name
Type
string
Description
The name of the recipe
Parameter
output
Type
IItemStack
Description
The output item
Parameter
input
Type
IIngredient
Description
The input Ingredient
Parameter
blood
Type
IIngredient
Description
The blood Ingredient
Parameter
cookTime
Type
int
Description
The cook time of the recipe

Return Type: stdlib.List<T>

script.zs
// DragonForgeRecipeManager.getAllRecipes() as stdlib.List<T>
<recipetype:iceandfire:dragonforge>.getAllRecipes();

Return Type: T

script.zs
DragonForgeRecipeManager.getRecipeByName(name as string) as T
ParameterTypeDescription
Parameter
name
Type
string
Description
No Description Provided

Return Type: T[ResourceLocation]

script.zs
// DragonForgeRecipeManager.getRecipeMap() as T[ResourceLocation]
<recipetype:iceandfire:dragonforge>.getRecipeMap();

Return Type: stdlib.List<T>

script.zs
DragonForgeRecipeManager.getRecipesByOutput(output as IIngredient) as stdlib.List<T>
ParameterTypeDescription
Parameter
output
Type
IIngredient
Description
No Description Provided

Return Type: void

script.zs
DragonForgeRecipeManager.remove(output as IIngredient) as void
ParameterTypeDescription
Parameter
output
Type
IIngredient
Description
No Description Provided

Return Type: void

script.zs
// DragonForgeRecipeManager.removeAll() as void
<recipetype:iceandfire:dragonforge>.removeAll();

Return Type: void

script.zs
DragonForgeRecipeManager.removeByInput(input as IItemStack) as void
ParameterTypeDescription
Parameter
input
Type
IItemStack
Description
No Description Provided

Return Type: void

script.zs
DragonForgeRecipeManager.removeByModid(modid as string, exclude as Predicate<string>) as void
ParameterTypeDescriptionOptionalDefaultValue
Parameter
modid
Type
string
Description
No Description Provided
Optional
false
DefaultValue
Parameter
exclude
Type
Predicate<string>
Description
No Description Provided
Optional
true
DefaultValue
(name as string) as bool => false

Return Type: void

script.zs
DragonForgeRecipeManager.removeByName(names as string[]) as void
ParameterTypeDescription
Parameter
names
Type
string[]
Description
No Description Provided

Return Type: void

script.zs
DragonForgeRecipeManager.removeByRegex(regex as string, exclude as Predicate<string>) as void
ParameterTypeDescriptionOptionalDefaultValue
Parameter
regex
Type
string
Description
No Description Provided
Optional
false
DefaultValue
Parameter
exclude
Type
Predicate<string>
Description
No Description Provided
Optional
true
DefaultValue
(name as string) as bool => false

Properties

NameTypeHas GetterHas SetterDescription
Name
allRecipes
Type
stdlib.List<T>
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
recipeMap
Type
T[ResourceLocation]
Has Getter
true
Has Setter
false
Description
No Description Provided