Package net.minecraftforge.client.event
Class GuiScreenEvent.InitGuiEvent
- java.lang.Object
-
- net.minecraftforge.eventbus.api.Event
-
- net.minecraftforge.client.event.GuiScreenEvent
-
- net.minecraftforge.client.event.GuiScreenEvent.InitGuiEvent
-
- Direct Known Subclasses:
GuiScreenEvent.InitGuiEvent.Post
,GuiScreenEvent.InitGuiEvent.Pre
- Enclosing class:
- GuiScreenEvent
public static class GuiScreenEvent.InitGuiEvent extends GuiScreenEvent
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GuiScreenEvent.InitGuiEvent.Post
This event fires right afterGuiScreen#initGui()
.static class
GuiScreenEvent.InitGuiEvent.Pre
This event fires just after initializingGuiScreen#mc
,GuiScreen#fontRenderer
,GuiScreen#width
, andGuiScreen#height
.
If canceled the following lines are skipped inGuiScreen#setWorldAndResolution(Minecraft, int, int)
:
this.buttonList.clear();
this.children.clear();
this.initGui();
-
Nested classes/interfaces inherited from class net.minecraftforge.client.event.GuiScreenEvent
GuiScreenEvent.BackgroundDrawnEvent, GuiScreenEvent.DrawScreenEvent, GuiScreenEvent.InitGuiEvent, GuiScreenEvent.KeyboardCharTypedEvent, GuiScreenEvent.KeyboardKeyEvent, GuiScreenEvent.KeyboardKeyPressedEvent, GuiScreenEvent.KeyboardKeyReleasedEvent, GuiScreenEvent.MouseClickedEvent, GuiScreenEvent.MouseDragEvent, GuiScreenEvent.MouseInputEvent, GuiScreenEvent.MouseReleasedEvent, GuiScreenEvent.MouseScrollEvent, GuiScreenEvent.PotionShiftEvent
-
-
Constructor Summary
Constructors Constructor Description InitGuiEvent(Screen gui, java.util.List<Widget> list, java.util.function.Consumer<Widget> add, java.util.function.Consumer<Widget> remove)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addWidget(Widget button)
java.util.List<Widget>
getWidgetList()
Unmodifiable reference to the list of buttons on theGuiScreenEvent.gui
.void
removeWidget(Widget button)
-
Methods inherited from class net.minecraftforge.client.event.GuiScreenEvent
getGui
-
-
-
-
Method Detail
-
getWidgetList
public java.util.List<Widget> getWidgetList()
Unmodifiable reference to the list of buttons on theGuiScreenEvent.gui
.
-
addWidget
public void addWidget(Widget button)
-
removeWidget
public void removeWidget(Widget button)
-
-