Class CreativeModeInventoryScreen
java.lang.Object
net.minecraft.client.gui.components.events.AbstractContainerEventHandler
net.minecraft.client.gui.screens.Screen
net.minecraft.client.gui.screens.inventory.AbstractContainerScreen<T>
net.minecraft.client.gui.screens.inventory.EffectRenderingInventoryScreen<CreativeModeInventoryScreen.ItemPickerMenu>
net.minecraft.client.gui.screens.inventory.CreativeModeInventoryScreen
- All Implemented Interfaces:
ContainerEventHandler
,GuiEventListener
,Renderable
,TabOrderedElement
,MenuAccess<CreativeModeInventoryScreen.ItemPickerMenu>
public class CreativeModeInventoryScreen
extends EffectRenderingInventoryScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
Nested Class Summary
Modifier and TypeClassDescription(package private) static class
static class
(package private) static class
Nested classes/interfaces inherited from class net.minecraft.client.gui.screens.Screen
Screen.NarratableSearchResult
-
Field Summary
Modifier and TypeFieldDescription(package private) static final SimpleContainer
private static final ResourceLocation
private CreativeTabsScreenPage
private static final String
private Slot
private final boolean
private static final String
private boolean
private boolean
private CreativeInventoryListener
private static final int
private static final int
private final List<CreativeTabsScreenPage>
private static final int
private static final int
private boolean
private float
private EditBox
private static CreativeModeTab
private static final int
private static final int
private static final int
private static final Component
Fields inherited from class net.minecraft.client.gui.screens.inventory.AbstractContainerScreen
hoveredSlot, imageHeight, imageWidth, INVENTORY_LOCATION, inventoryLabelX, inventoryLabelY, isQuickCrafting, leftPos, menu, playerInventoryTitle, quickCraftSlots, SLOT_ITEM_BLIT_OFFSET, slotColor, titleLabelX, titleLabelY, topPos
Fields inherited from class net.minecraft.client.gui.screens.Screen
BACKGROUND_LOCATION, font, height, minecraft, renderables, screenExecutor, title, width
Fields inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
DOUBLE_CLICK_THRESHOLD_MS
-
Constructor Summary
ConstructorDescriptionCreativeModeInventoryScreen
(Player p_259788_, FeatureFlagSet p_260074_, boolean p_259569_) -
Method Summary
Modifier and TypeMethodDescriptionprivate boolean
boolean
charTyped
(char p_98521_, int p_98522_) protected boolean
checkTabClicked
(CreativeModeTab p_98563_, double p_98564_, double p_98565_) protected boolean
checkTabHovering
(GuiGraphics p_282317_, CreativeModeTab p_282244_, int p_283469_, int p_283411_) void
private int
getTabX
(CreativeModeTab p_260136_) private int
getTabY
(CreativeModeTab p_260181_) getTooltipFromContainerItem
(ItemStack p_281769_) static void
handleHotbarLoadOrSave
(Minecraft p_98599_, int p_98600_, boolean p_98601_, boolean p_98602_) protected boolean
hasClickedOutside
(double p_98541_, double p_98542_, int p_98543_, int p_98544_, int p_98545_) private boolean
hasPermissions
(Player p_259959_) protected void
init()
protected boolean
insideScrollbar
(double p_98524_, double p_98525_) private boolean
isCreativeSlot
(Slot p_98554_) boolean
boolean
keyPressed
(int p_98547_, int p_98548_, int p_98549_) boolean
keyReleased
(int p_98612_, int p_98613_, int p_98614_) boolean
mouseClicked
(double p_98531_, double p_98532_, int p_98533_) boolean
mouseDragged
(double p_98535_, double p_98536_, int p_98537_, double p_98538_, double p_98539_) boolean
mouseReleased
(double p_98622_, double p_98623_, int p_98624_) boolean
mouseScrolled
(double p_98527_, double p_98528_, double p_98529_) private void
refreshCurrentTabContents
(Collection<ItemStack> p_261591_) private void
void
removed()
void
render
(GuiGraphics p_283000_, int p_281317_, int p_282770_, float p_281295_) protected void
renderBg
(GuiGraphics p_282663_, float p_282504_, int p_282089_, int p_282249_) protected void
renderLabels
(GuiGraphics p_283168_, int p_281774_, int p_281466_) protected void
renderTabButton
(GuiGraphics p_283590_, CreativeModeTab p_283489_) void
private void
selectTab
(CreativeModeTab p_98561_) void
setCurrentPage
(CreativeTabsScreenPage currentPage) protected void
slotClicked
(Slot p_98556_, int p_98557_, int p_98558_, ClickType p_98559_) private void
tryRefreshInvalidatedTabs
(FeatureFlagSet p_259501_, boolean p_259713_, HolderLookup.Provider p_270898_) private void
updateVisibleTags
(String p_98620_) Methods inherited from class net.minecraft.client.gui.screens.inventory.EffectRenderingInventoryScreen
canSeeEffects
Methods inherited from class net.minecraft.client.gui.screens.inventory.AbstractContainerScreen
checkHotbarKeyPressed, clearDraggingState, getGuiLeft, getGuiTop, getMenu, getSlotColor, getSlotUnderMouse, getXSize, getYSize, isHovering, isPauseScreen, onClose, renderSlotHighlight, renderSlotHighlight, renderTooltip, tick
Methods inherited from class net.minecraft.client.gui.screens.Screen
added, addRenderableOnly, addRenderableWidget, addWidget, afterKeyboardAction, afterMouseAction, afterMouseMove, changeFocus, children, clearWidgets, findNarratableWidget, getBackgroundMusic, getMinecraft, getNarrationMessage, getRectangle, getTitle, getTooltipFromItem, handleComponentClicked, handleDelayedNarration, hasAltDown, hasControlDown, hasShiftDown, hideWidgets, init, insertText, isCopy, isCut, isMouseOver, isPaste, isSelectAll, isValidCharacterForName, narrationEnabled, onFilesDrop, rebuildWidgets, removeWidget, renderBackground, renderDirtBackground, renderWithTooltip, repositionElements, setInitialFocus, setTooltipForNextRenderPass, setTooltipForNextRenderPass, setTooltipForNextRenderPass, setTooltipForNextRenderPass, shouldCloseOnEsc, shouldNarrateNavigation, triggerImmediateNarration, updateNarratedWidget, updateNarrationState, wrapScreenError
Methods inherited from class net.minecraft.client.gui.components.events.AbstractContainerEventHandler
getFocused, isDragging, setDragging, setFocused
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.client.gui.components.events.ContainerEventHandler
getChildAt, getCurrentFocusPath, isFocused, magicalSpecialHackyFocus, nextFocusPath, setFocused
Methods inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
mouseMoved
Methods inherited from interface net.minecraft.client.gui.components.TabOrderedElement
getTabOrderGroup
-
Field Details
-
CREATIVE_TABS_LOCATION
-
GUI_CREATIVE_TAB_PREFIX
- See Also:
-
CUSTOM_SLOT_LOCK
- See Also:
-
NUM_ROWS
private static final int NUM_ROWS- See Also:
-
NUM_COLS
private static final int NUM_COLS- See Also:
-
TAB_WIDTH
private static final int TAB_WIDTH- See Also:
-
TAB_HEIGHT
private static final int TAB_HEIGHT- See Also:
-
SCROLLER_WIDTH
private static final int SCROLLER_WIDTH- See Also:
-
SCROLLER_HEIGHT
private static final int SCROLLER_HEIGHT- See Also:
-
CONTAINER
-
TRASH_SLOT_TOOLTIP
-
TEXT_COLOR
private static final int TEXT_COLOR- See Also:
-
selectedTab
-
scrollOffs
private float scrollOffs -
scrolling
private boolean scrolling -
searchBox
-
originalSlots
-
destroyItemSlot
-
listener
-
ignoreTextInput
private boolean ignoreTextInput -
hasClickedOutside
private boolean hasClickedOutside -
visibleTags
-
displayOperatorCreativeTab
private final boolean displayOperatorCreativeTab -
pages
-
currentPage
-
-
Constructor Details
-
CreativeModeInventoryScreen
-
-
Method Details
-
hasPermissions
-
tryRefreshInvalidatedTabs
private void tryRefreshInvalidatedTabs(FeatureFlagSet p_259501_, boolean p_259713_, HolderLookup.Provider p_270898_) -
refreshCurrentTabContents
-
containerTick
public void containerTick()- Overrides:
containerTick
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
slotClicked
- Overrides:
slotClicked
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
isCreativeSlot
-
init
protected void init()- Overrides:
init
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
resize
-
removed
public void removed()- Overrides:
removed
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
charTyped
public boolean charTyped(char p_98521_, int p_98522_) -
keyPressed
public boolean keyPressed(int p_98547_, int p_98548_, int p_98549_) - Specified by:
keyPressed
in interfaceContainerEventHandler
- Specified by:
keyPressed
in interfaceGuiEventListener
- Overrides:
keyPressed
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
keyReleased
public boolean keyReleased(int p_98612_, int p_98613_, int p_98614_) -
refreshSearchResults
private void refreshSearchResults() -
updateVisibleTags
-
renderLabels
- Overrides:
renderLabels
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
mouseClicked
public boolean mouseClicked(double p_98531_, double p_98532_, int p_98533_) - Specified by:
mouseClicked
in interfaceContainerEventHandler
- Specified by:
mouseClicked
in interfaceGuiEventListener
- Overrides:
mouseClicked
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
mouseReleased
public boolean mouseReleased(double p_98622_, double p_98623_, int p_98624_) - Specified by:
mouseReleased
in interfaceContainerEventHandler
- Specified by:
mouseReleased
in interfaceGuiEventListener
- Overrides:
mouseReleased
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
canScroll
private boolean canScroll() -
selectTab
-
mouseScrolled
public boolean mouseScrolled(double p_98527_, double p_98528_, double p_98529_) -
hasClickedOutside
protected boolean hasClickedOutside(double p_98541_, double p_98542_, int p_98543_, int p_98544_, int p_98545_) - Overrides:
hasClickedOutside
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
insideScrollbar
protected boolean insideScrollbar(double p_98524_, double p_98525_) -
mouseDragged
public boolean mouseDragged(double p_98535_, double p_98536_, int p_98537_, double p_98538_, double p_98539_) - Specified by:
mouseDragged
in interfaceContainerEventHandler
- Specified by:
mouseDragged
in interfaceGuiEventListener
- Overrides:
mouseDragged
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
render
- Specified by:
render
in interfaceRenderable
- Overrides:
render
in classEffectRenderingInventoryScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
getTooltipFromContainerItem
- Overrides:
getTooltipFromContainerItem
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
renderBg
- Specified by:
renderBg
in classAbstractContainerScreen<CreativeModeInventoryScreen.ItemPickerMenu>
-
getTabX
-
getTabY
-
checkTabClicked
-
checkTabHovering
protected boolean checkTabHovering(GuiGraphics p_282317_, CreativeModeTab p_282244_, int p_283469_, int p_283411_) -
renderTabButton
-
isInventoryOpen
public boolean isInventoryOpen() -
handleHotbarLoadOrSave
public static void handleHotbarLoadOrSave(Minecraft p_98599_, int p_98600_, boolean p_98601_, boolean p_98602_) -
getCurrentPage
-
setCurrentPage
-