Package net.minecraft.world.inventory
Class MerchantMenu
java.lang.Object
net.minecraft.world.inventory.AbstractContainerMenu
net.minecraft.world.inventory.MerchantMenu
-
Field Summary
Modifier and TypeFieldDescriptionprivate static final int
private boolean
private static final int
private static final int
private int
protected static final int
protected static final int
protected static final int
private static final int
private static final int
private static final int
private boolean
private final MerchantContainer
private final Merchant
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
ConstructorDescriptionMerchantMenu
(int p_40033_, Inventory p_40034_) MerchantMenu
(int p_40036_, Inventory p_40037_, Merchant p_40038_) -
Method Summary
Modifier and TypeMethodDescriptionboolean
boolean
canTakeItemForPickAll
(ItemStack p_40044_, Slot p_40045_) int
int
int
private void
moveFromInventoryToPaymentSlot
(int p_40061_, ItemStack p_40062_) private void
quickMoveStack
(Player p_40053_, int p_40054_) void
void
setCanRestock
(boolean p_40059_) void
setMerchantLevel
(int p_40070_) void
setOffers
(MerchantOffers p_40047_) void
setSelectionHint
(int p_40064_) void
setShowProgressBar
(boolean p_40049_) void
setXp
(int p_40067_) boolean
void
slotsChanged
(Container p_40040_) boolean
stillValid
(Player p_40042_) void
tryMoveItems
(int p_40073_) 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
-
PAYMENT1_SLOT
protected static final int PAYMENT1_SLOT- See Also:
-
PAYMENT2_SLOT
protected static final int PAYMENT2_SLOT- See Also:
-
RESULT_SLOT
protected static final int RESULT_SLOT- 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:
-
SELLSLOT1_X
private static final int SELLSLOT1_X- See Also:
-
SELLSLOT2_X
private static final int SELLSLOT2_X- See Also:
-
BUYSLOT_X
private static final int BUYSLOT_X- See Also:
-
ROW_Y
private static final int ROW_Y- See Also:
-
trader
-
tradeContainer
-
merchantLevel
private int merchantLevel -
showProgressBar
private boolean showProgressBar -
canRestock
private boolean canRestock
-
-
Constructor Details
-
MerchantMenu
-
MerchantMenu
-
-
Method Details
-
setShowProgressBar
public void setShowProgressBar(boolean p_40049_) -
slotsChanged
- Overrides:
slotsChanged
in classAbstractContainerMenu
-
setSelectionHint
public void setSelectionHint(int p_40064_) -
stillValid
- Specified by:
stillValid
in classAbstractContainerMenu
-
getTraderXp
public int getTraderXp() -
getFutureTraderXp
public int getFutureTraderXp() -
setXp
public void setXp(int p_40067_) -
getTraderLevel
public int getTraderLevel() -
setMerchantLevel
public void setMerchantLevel(int p_40070_) -
setCanRestock
public void setCanRestock(boolean p_40059_) -
canRestock
public boolean canRestock() -
canTakeItemForPickAll
- Overrides:
canTakeItemForPickAll
in classAbstractContainerMenu
-
quickMoveStack
- Specified by:
quickMoveStack
in classAbstractContainerMenu
-
playTradeSound
private void playTradeSound() -
removed
- Overrides:
removed
in classAbstractContainerMenu
-
tryMoveItems
public void tryMoveItems(int p_40073_) -
moveFromInventoryToPaymentSlot
-
setOffers
-
getOffers
-
showProgressBar
public boolean showProgressBar()
-