Class IndexPanel
java.lang.Object
net.mcexpanded.fancytabsections.creativetab.IndexPanel
A collapsible jump-list along the left edge of the creative-mode inventory screen,
showing one icon per registered
Section of the currently selected tab. Clicking
an icon smooth-scrolls the grid so that section's banner lands at the top.- Since:
- 6.0
-
Method Summary
Modifier and TypeMethodDescriptionstatic booleanstatic booleanmouseClicked(net.minecraft.client.gui.screens.inventory.CreativeModeInventoryScreen screen, List<Section<?>> sections, float scrollOffs, double mouseX, double mouseY, int button) static booleanmouseScrolled(net.minecraft.client.gui.screens.inventory.CreativeModeInventoryScreen screen, List<Section<?>> sections, double mouseX, double mouseY, double scrollY) static voidrender(net.minecraft.client.gui.screens.inventory.CreativeModeInventoryScreen screen, net.minecraft.client.gui.GuiGraphics g, List<Section<?>> sections, int mouseX, int mouseY) static floattick()Progresses any in-flight jump-to-section animation.static inttitleX()
-
Method Details
-
active
-
titleX
public static int titleX()- Returns:
- the X offset (relative to guiLeft) the tab title should shift to when this panel's toggle is showing, so the two don't overlap. Applied via a mixin hook into renderLabels.
-
tick
public static float tick()Progresses any in-flight jump-to-section animation.- Returns:
- the scroll fraction (0..1) to apply this frame, or -1 if there's nothing to apply
-
render
-
mouseClicked
-
mouseScrolled
-