Class RecipeBookTestMenu
java.lang.Object
net.minecraft.world.inventory.AbstractContainerMenu
net.minecraft.world.inventory.RecipeBookMenu<CraftingInput,RecipeBookTestRecipe>
net.neoforged.neoforge.oldtest.recipebook.RecipeBookTestMenu
-
Field Summary
Modifier and TypeFieldDescriptionprivate final ContainerLevelAccess
private final RecipeBookExtensionTest.RecipeBookTestContainer
private static final int
private static final int
private static final int
private static final int
private static final int
private final Player
private static final int
private final ResultContainer
private final Slot
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
ConstructorDescriptionRecipeBookTestMenu
(int id, Inventory inv, FriendlyByteBuf extraData) RecipeBookTestMenu
(int id, Inventory inv, ContainerLevelAccess access) -
Method Summary
Modifier and TypeMethodDescriptionboolean
canTakeItemForPickAll
(ItemStack stack, Slot slot) void
void
fillCraftSlotsStackedContents
(StackedContents contents) int
int
int
int
getSize()
quickMoveStack
(Player player, int idx) Mostly copied fromCraftingMenu.quickMoveStack(net.minecraft.world.entity.player.Player, int)
boolean
recipeMatches
(RecipeHolder<RecipeBookTestRecipe> recipeHolder) void
boolean
shouldMoveToInventory
(int slotIdx) void
slotsChanged
(Container container) boolean
stillValid
(Player player) Methods inherited from class net.minecraft.world.inventory.RecipeBookMenu
beginPlacingRecipe, finishPlacingRecipe, 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
-
container
-
resultContainer
-
resultSlot
-
access
-
player
-
RESULT_SLOT
private static final int RESULT_SLOT- See Also:
-
CRAFTING_START
private static final int CRAFTING_START- See Also:
-
CRAFTING_STOP
private static final int CRAFTING_STOP- See Also:
-
INVENTORY_START
private static final int INVENTORY_START- See Also:
-
INVENTORY_STOP
private static final int INVENTORY_STOP- See Also:
-
HOTBAR_START
private static final int HOTBAR_START- See Also:
-
-
Constructor Details
-
RecipeBookTestMenu
-
RecipeBookTestMenu
-
-
Method Details
-
stillValid
- Specified by:
stillValid
in classAbstractContainerMenu
-
removed
- Overrides:
removed
in classAbstractContainerMenu
-
canTakeItemForPickAll
- Overrides:
canTakeItemForPickAll
in classAbstractContainerMenu
-
slotsChanged
- Overrides:
slotsChanged
in classAbstractContainerMenu
-
quickMoveStack
Mostly copied fromCraftingMenu.quickMoveStack(net.minecraft.world.entity.player.Player, int)
- Specified by:
quickMoveStack
in classAbstractContainerMenu
-
fillCraftSlotsStackedContents
- Specified by:
fillCraftSlotsStackedContents
in classRecipeBookMenu<CraftingInput,
RecipeBookTestRecipe>
-
clearCraftingContent
public void clearCraftingContent()- Specified by:
clearCraftingContent
in classRecipeBookMenu<CraftingInput,
RecipeBookTestRecipe>
-
recipeMatches
- Specified by:
recipeMatches
in classRecipeBookMenu<CraftingInput,
RecipeBookTestRecipe>
-
getResultSlotIndex
public int getResultSlotIndex()- Specified by:
getResultSlotIndex
in classRecipeBookMenu<CraftingInput,
RecipeBookTestRecipe>
-
getGridWidth
public int getGridWidth()- Specified by:
getGridWidth
in classRecipeBookMenu<CraftingInput,
RecipeBookTestRecipe>
-
getGridHeight
public int getGridHeight()- Specified by:
getGridHeight
in classRecipeBookMenu<CraftingInput,
RecipeBookTestRecipe>
-
getSize
public int getSize()- Specified by:
getSize
in classRecipeBookMenu<CraftingInput,
RecipeBookTestRecipe>
-
getRecipeBookType
- Specified by:
getRecipeBookType
in classRecipeBookMenu<CraftingInput,
RecipeBookTestRecipe>
-
shouldMoveToInventory
public boolean shouldMoveToInventory(int slotIdx) - Specified by:
shouldMoveToInventory
in classRecipeBookMenu<CraftingInput,
RecipeBookTestRecipe>
-