Class RecipeBookTestMenu
java.lang.Object
net.minecraft.world.inventory.AbstractContainerMenu
net.minecraft.world.inventory.RecipeBookMenu
net.neoforged.neoforge.oldtest.recipebook.RecipeBookTestMenu
public class RecipeBookTestMenu
extends net.minecraft.world.inventory.RecipeBookMenu
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.world.inventory.RecipeBookMenu
net.minecraft.world.inventory.RecipeBookMenu.PostPlaceAction
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final net.minecraft.world.inventory.ContainerLevelAccess
private final RecipeBookExtensionTest.RecipeBookTestContainer
(package private) static final int
(package private) static final int
private static final int
private static final int
private static final int
private boolean
private final net.minecraft.world.entity.player.Player
(package private) static final int
private final net.minecraft.world.inventory.ResultContainer
(package private) final net.minecraft.world.inventory.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, SLOT_SIZE, slots, SLOTS_PER_ROW
-
Constructor Summary
ConstructorsConstructorDescriptionRecipeBookTestMenu
(int id, net.minecraft.world.entity.player.Inventory inv, net.minecraft.network.FriendlyByteBuf extraData) RecipeBookTestMenu
(int id, net.minecraft.world.entity.player.Inventory inv, net.minecraft.world.inventory.ContainerLevelAccess access) -
Method Summary
Modifier and TypeMethodDescriptionboolean
canTakeItemForPickAll
(net.minecraft.world.item.ItemStack stack, net.minecraft.world.inventory.Slot slot) void
fillCraftSlotsStackedContents
(net.minecraft.world.entity.player.StackedItemContents contents) (package private) List
<net.minecraft.world.inventory.Slot> net.minecraft.world.inventory.RecipeBookType
net.minecraft.world.inventory.RecipeBookMenu.PostPlaceAction
handlePlacement
(boolean p_40119_, boolean p_362739_, net.minecraft.world.item.crafting.RecipeHolder<?> rawHolder, net.minecraft.server.level.ServerLevel serverLevel, net.minecraft.world.entity.player.Inventory inventory) net.minecraft.world.item.ItemStack
quickMoveStack
(net.minecraft.world.entity.player.Player player, int idx) Mostly copied fromCraftingMenu.quickMoveStack(net.minecraft.world.entity.player.Player, int)
void
removed
(net.minecraft.world.entity.player.Player player) protected static void
slotChangedCraftingGrid
(net.minecraft.world.inventory.AbstractContainerMenu p_150547_, net.minecraft.server.level.ServerLevel p_379963_, net.minecraft.world.entity.player.Player p_150549_, RecipeBookExtensionTest.RecipeBookTestContainer p_150550_, net.minecraft.world.inventory.ResultContainer p_150551_, @Nullable net.minecraft.world.item.crafting.RecipeHolder<RecipeBookTestRecipe> p_345124_) void
slotsChanged
(net.minecraft.world.Container container) boolean
stillValid
(net.minecraft.world.entity.player.Player player) Methods inherited from class net.minecraft.world.inventory.AbstractContainerMenu
addDataSlot, addDataSlots, addInventoryExtendedSlots, addInventoryHotbarSlots, addSlot, addSlotListener, addStandardInventorySlots, 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, setRemoteSlotUnsafe, setSelectedBundleItemIndex, setSynchronizer, stillValid, suppressRemoteUpdates, transferState
-
Field Details
-
container
-
resultContainer
private final net.minecraft.world.inventory.ResultContainer resultContainer -
resultSlot
final net.minecraft.world.inventory.Slot resultSlot -
access
private final net.minecraft.world.inventory.ContainerLevelAccess access -
player
private final net.minecraft.world.entity.player.Player player -
placingRecipe
private boolean placingRecipe -
RESULT_SLOT
static final int RESULT_SLOT- See Also:
-
CRAFTING_START
static final int CRAFTING_START- See Also:
-
CRAFTING_STOP
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
public RecipeBookTestMenu(int id, net.minecraft.world.entity.player.Inventory inv, net.minecraft.network.FriendlyByteBuf extraData) -
RecipeBookTestMenu
public RecipeBookTestMenu(int id, net.minecraft.world.entity.player.Inventory inv, net.minecraft.world.inventory.ContainerLevelAccess access)
-
-
Method Details
-
slotChangedCraftingGrid
protected static void slotChangedCraftingGrid(net.minecraft.world.inventory.AbstractContainerMenu p_150547_, net.minecraft.server.level.ServerLevel p_379963_, net.minecraft.world.entity.player.Player p_150549_, RecipeBookExtensionTest.RecipeBookTestContainer p_150550_, net.minecraft.world.inventory.ResultContainer p_150551_, @Nullable @Nullable net.minecraft.world.item.crafting.RecipeHolder<RecipeBookTestRecipe> p_345124_) -
stillValid
public boolean stillValid(net.minecraft.world.entity.player.Player player) - Specified by:
stillValid
in classnet.minecraft.world.inventory.AbstractContainerMenu
-
removed
public void removed(net.minecraft.world.entity.player.Player player) - Overrides:
removed
in classnet.minecraft.world.inventory.AbstractContainerMenu
-
canTakeItemForPickAll
public boolean canTakeItemForPickAll(net.minecraft.world.item.ItemStack stack, net.minecraft.world.inventory.Slot slot) - Overrides:
canTakeItemForPickAll
in classnet.minecraft.world.inventory.AbstractContainerMenu
-
slotsChanged
public void slotsChanged(net.minecraft.world.Container container) - Overrides:
slotsChanged
in classnet.minecraft.world.inventory.AbstractContainerMenu
-
quickMoveStack
public net.minecraft.world.item.ItemStack quickMoveStack(net.minecraft.world.entity.player.Player player, int idx) Mostly copied fromCraftingMenu.quickMoveStack(net.minecraft.world.entity.player.Player, int)
- Specified by:
quickMoveStack
in classnet.minecraft.world.inventory.AbstractContainerMenu
-
fillCraftSlotsStackedContents
public void fillCraftSlotsStackedContents(net.minecraft.world.entity.player.StackedItemContents contents) - Specified by:
fillCraftSlotsStackedContents
in classnet.minecraft.world.inventory.RecipeBookMenu
-
getGridSlots
List<net.minecraft.world.inventory.Slot> getGridSlots() -
handlePlacement
public net.minecraft.world.inventory.RecipeBookMenu.PostPlaceAction handlePlacement(boolean p_40119_, boolean p_362739_, net.minecraft.world.item.crafting.RecipeHolder<?> rawHolder, net.minecraft.server.level.ServerLevel serverLevel, net.minecraft.world.entity.player.Inventory inventory) - Specified by:
handlePlacement
in classnet.minecraft.world.inventory.RecipeBookMenu
-
getRecipeBookType
public net.minecraft.world.inventory.RecipeBookType getRecipeBookType()- Specified by:
getRecipeBookType
in classnet.minecraft.world.inventory.RecipeBookMenu
-