Class SlimefunAutoCrafter
java.lang.Object
io.github.thebusybiscuit.slimefun4.api.items.SlimefunItem
io.github.thebusybiscuit.slimefun4.implementation.items.autocrafters.AbstractAutoCrafter
io.github.thebusybiscuit.slimefun4.implementation.items.autocrafters.SlimefunAutoCrafter
- All Implemented Interfaces:
EnergyNetComponent
,ItemAttribute
,Placeable
- Direct Known Subclasses:
ArmorAutoCrafter
,EnhancedAutoCrafter
This extension of the
AbstractAutoCrafter
allows you to implement any
RecipeType
.
The concrete implementation for this can be seen in the EnhancedAutoCrafter
but
it theoretically works for any RecipeType
.- Author:
- TheBusyBiscuit
- See Also:
-
Field Summary
Fields inherited from class io.github.thebusybiscuit.slimefun4.implementation.items.autocrafters.AbstractAutoCrafter
background, recipeEnabledKey, recipeStorageKey
Fields inherited from class io.github.thebusybiscuit.slimefun4.api.items.SlimefunItem
addon, disenchantable, enchantable, hidden, recipeOutput, useableInWorkbench
-
Constructor Summary
ModifierConstructorDescriptionprotected
SlimefunAutoCrafter
(ItemGroup itemGroup, SlimefunItemStack item, RecipeType recipeType, ItemStack[] recipe, RecipeType targetRecipeType) -
Method Summary
Modifier and TypeMethodDescriptionThis method returns the currently selectedAbstractRecipe
for the givenBlock
.protected void
updateRecipe
(Block b, Player p) This method is called when aPlayer
right clicks theAbstractAutoCrafter
while holding the shift button.Methods inherited from class io.github.thebusybiscuit.slimefun4.implementation.items.autocrafters.AbstractAutoCrafter
craft, getCapacity, getEnergyComponentType, getEnergyConsumption, isValidInventory, matches, matchesAny, onRightClick, register, setCapacity, setEnergyConsumption, setSelectedRecipe, showRecipe, tick
Methods inherited from class io.github.thebusybiscuit.slimefun4.api.items.SlimefunItem
addItemHandler, addItemSetting, addOfficialWikipage, callItemHandler, canUse, equals, error, getAddon, getBlockTicker, getById, getByItem, getDrops, getDrops, getHandlers, getId, getItem, getItemGroup, getItemName, getItemSetting, getItemSettings, getOptionalById, getOptionalByItem, getRecipe, getRecipeOutput, getRecipeType, getResearch, getState, getWikipage, hashCode, hasResearch, info, isDisabled, isDisabledIn, isDisenchantable, isEnchantable, isHidden, isItem, isItemStackImmutable, isTicking, isUseableInWorkbench, load, postRegister, preRegister, sendDeprecationWarning, setHidden, setItemGroup, setRecipe, setRecipeOutput, setRecipeType, setResearch, setUseableInWorkbench, toString, warn
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface io.github.thebusybiscuit.slimefun4.core.attributes.EnergyNetComponent
addCharge, getCharge, getCharge, isChargeable, removeCharge, setCharge
Methods inherited from interface io.github.thebusybiscuit.slimefun4.core.attributes.ItemAttribute
getId
Methods inherited from interface io.github.thebusybiscuit.slimefun4.core.attributes.Placeable
useVanillaBlockBreaking
-
Constructor Details
-
SlimefunAutoCrafter
@ParametersAreNonnullByDefault protected SlimefunAutoCrafter(ItemGroup itemGroup, SlimefunItemStack item, RecipeType recipeType, ItemStack[] recipe, RecipeType targetRecipeType)
-
-
Method Details
-
getSelectedRecipe
Description copied from class:AbstractAutoCrafter
This method returns the currently selectedAbstractRecipe
for the givenBlock
.- Specified by:
getSelectedRecipe
in classAbstractAutoCrafter
- Parameters:
b
- TheBlock
- Returns:
- The currently selected
AbstractRecipe
or null
-
updateRecipe
Description copied from class:AbstractAutoCrafter
This method is called when aPlayer
right clicks theAbstractAutoCrafter
while holding the shift button. Use it to choose theAbstractRecipe
.- Specified by:
updateRecipe
in classAbstractAutoCrafter
- Parameters:
b
- TheBlock
which was clickedp
- ThePlayer
who clicked
-