Package net.minecraft.world.inventory
Class CraftingMenu
java.lang.Object
net.minecraft.world.inventory.AbstractContainerMenu
net.minecraft.world.inventory.RecipeBookMenu<CraftingInput,CraftingRecipe>
net.minecraft.world.inventory.CraftingMenu
-
Field Summary
Modifier and TypeFieldDescriptionprivate final ContainerLevelAccess
private static final int
private static final int
private final CraftingContainer
private static final int
private static final int
private boolean
private final Player
static final int
private final ResultContainer
private static final int
private static final int
Fields inherited from class net.minecraft.world.inventory.AbstractContainerMenu
CARRIED_SLOT_SIZE, containerId, QUICKCRAFT_HEADER_CONTINUE, QUICKCRAFT_HEADER_END, QUICKCRAFT_HEADER_START, QUICKCRAFT_TYPE_CHARITABLE, QUICKCRAFT_TYPE_CLONE, QUICKCRAFT_TYPE_GREEDY, SLOT_CLICKED_OUTSIDE, slots
-
Constructor Summary
ConstructorDescriptionCraftingMenu
(int p_39353_, Inventory p_39354_) CraftingMenu
(int p_39356_, Inventory p_39357_, ContainerLevelAccess p_39358_) -
Method Summary
Modifier and TypeMethodDescriptionvoid
boolean
canTakeItemForPickAll
(ItemStack p_39381_, Slot p_39382_) void
void
fillCraftSlotsStackedContents
(StackedContents p_39374_) void
finishPlacingRecipe
(RecipeHolder<CraftingRecipe> p_342309_) int
int
int
int
getSize()
quickMoveStack
(Player p_39391_, int p_39392_) boolean
recipeMatches
(RecipeHolder<CraftingRecipe> p_300381_) void
boolean
shouldMoveToInventory
(int p_150553_) protected static void
slotChangedCraftingGrid
(AbstractContainerMenu p_150547_, Level p_150548_, Player p_150549_, CraftingContainer p_150550_, ResultContainer p_150551_, RecipeHolder<CraftingRecipe> p_344866_) void
slotsChanged
(Container p_39366_) boolean
stillValid
(Player p_39368_) Methods inherited from class net.minecraft.world.inventory.RecipeBookMenu
getRecipeBookCategories, handlePlacement
Methods inherited from class net.minecraft.world.inventory.AbstractContainerMenu
addDataSlot, addDataSlots, addSlot, addSlotListener, broadcastChanges, broadcastFullState, canDragTo, canItemQuickReplace, checkContainerDataCount, checkContainerSize, clearContainer, clicked, clickMenuButton, findSlot, getCarried, getItems, getQuickcraftHeader, getQuickcraftMask, getQuickCraftPlaceCount, getQuickcraftType, getRedstoneSignalFromBlockEntity, getRedstoneSignalFromContainer, getSlot, getStateId, getType, incrementStateId, initializeContents, isValidQuickcraftType, isValidSlotIndex, moveItemStackTo, removeSlotListener, resetQuickCraft, resumeRemoteUpdates, sendAllDataToRemote, setCarried, setData, setItem, setRemoteCarried, setRemoteSlot, setRemoteSlotNoCopy, setSynchronizer, stillValid, suppressRemoteUpdates, transferState
-
Field Details
-
RESULT_SLOT
public static final int RESULT_SLOT- See Also:
-
CRAFT_SLOT_START
private static final int CRAFT_SLOT_START- See Also:
-
CRAFT_SLOT_END
private static final int CRAFT_SLOT_END- See Also:
-
INV_SLOT_START
private static final int INV_SLOT_START- See Also:
-
INV_SLOT_END
private static final int INV_SLOT_END- See Also:
-
USE_ROW_SLOT_START
private static final int USE_ROW_SLOT_START- See Also:
-
USE_ROW_SLOT_END
private static final int USE_ROW_SLOT_END- See Also:
-
craftSlots
-
resultSlots
-
access
-
player
-
placingRecipe
private boolean placingRecipe
-
-
Constructor Details
-
CraftingMenu
-
CraftingMenu
-
-
Method Details
-
slotChangedCraftingGrid
protected static void slotChangedCraftingGrid(AbstractContainerMenu p_150547_, Level p_150548_, Player p_150549_, CraftingContainer p_150550_, ResultContainer p_150551_, @Nullable RecipeHolder<CraftingRecipe> p_344866_) -
slotsChanged
- Overrides:
slotsChanged
in classAbstractContainerMenu
-
beginPlacingRecipe
public void beginPlacingRecipe()- Overrides:
beginPlacingRecipe
in classRecipeBookMenu<CraftingInput,
CraftingRecipe>
-
finishPlacingRecipe
- Overrides:
finishPlacingRecipe
in classRecipeBookMenu<CraftingInput,
CraftingRecipe>
-
fillCraftSlotsStackedContents
- Specified by:
fillCraftSlotsStackedContents
in classRecipeBookMenu<CraftingInput,
CraftingRecipe>
-
clearCraftingContent
public void clearCraftingContent()- Specified by:
clearCraftingContent
in classRecipeBookMenu<CraftingInput,
CraftingRecipe>
-
recipeMatches
- Specified by:
recipeMatches
in classRecipeBookMenu<CraftingInput,
CraftingRecipe>
-
removed
- Overrides:
removed
in classAbstractContainerMenu
-
stillValid
- Specified by:
stillValid
in classAbstractContainerMenu
-
quickMoveStack
- Specified by:
quickMoveStack
in classAbstractContainerMenu
-
canTakeItemForPickAll
- Overrides:
canTakeItemForPickAll
in classAbstractContainerMenu
-
getResultSlotIndex
public int getResultSlotIndex()- Specified by:
getResultSlotIndex
in classRecipeBookMenu<CraftingInput,
CraftingRecipe>
-
getGridWidth
public int getGridWidth()- Specified by:
getGridWidth
in classRecipeBookMenu<CraftingInput,
CraftingRecipe>
-
getGridHeight
public int getGridHeight()- Specified by:
getGridHeight
in classRecipeBookMenu<CraftingInput,
CraftingRecipe>
-
getSize
public int getSize()- Specified by:
getSize
in classRecipeBookMenu<CraftingInput,
CraftingRecipe>
-
getRecipeBookType
- Specified by:
getRecipeBookType
in classRecipeBookMenu<CraftingInput,
CraftingRecipe>
-
shouldMoveToInventory
public boolean shouldMoveToInventory(int p_150553_) - Specified by:
shouldMoveToInventory
in classRecipeBookMenu<CraftingInput,
CraftingRecipe>
-