Package net.minecraftforge.client.event
Class ScreenEvent.InitScreenEvent
java.lang.Object
net.minecraftforge.eventbus.api.Event
net.minecraftforge.client.event.ScreenEvent
net.minecraftforge.client.event.ScreenEvent.InitScreenEvent
- Direct Known Subclasses:
ScreenEvent.InitScreenEvent.Post
,ScreenEvent.InitScreenEvent.Pre
- Enclosing class:
- ScreenEvent
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
This event fires right afterScreen#init()
.static class
This event fires just after initializing theMinecraft
, font renderer, width, and height fields.
If canceled the following lines are skipped inScreen.init(Minecraft, int, int)
:
this.buttonList.clear();
this.children.clear();
this.initGui();
Nested classes/interfaces inherited from class net.minecraftforge.client.event.ScreenEvent
ScreenEvent.BackgroundDrawnEvent, ScreenEvent.DrawScreenEvent, ScreenEvent.InitScreenEvent, ScreenEvent.KeyboardCharTypedEvent, ScreenEvent.KeyboardKeyEvent, ScreenEvent.KeyboardKeyPressedEvent, ScreenEvent.KeyboardKeyReleasedEvent, ScreenEvent.MouseClickedEvent, ScreenEvent.MouseDragEvent, ScreenEvent.MouseInputEvent, ScreenEvent.MouseReleasedEvent, ScreenEvent.MouseScrollEvent, ScreenEvent.PotionShiftEvent, ScreenEvent.PotionSizeEvent
Nested classes/interfaces inherited from class net.minecraftforge.eventbus.api.Event
net.minecraftforge.eventbus.api.Event.HasResult, net.minecraftforge.eventbus.api.Event.Result
-
Field Summary
Modifier and TypeFieldDescriptionprivate Consumer<GuiEventListener>
private List<GuiEventListener>
private Consumer<GuiEventListener>
-
Constructor Summary
ConstructorDescriptionInitScreenEvent
(Screen screen, List<GuiEventListener> listenerList, Consumer<GuiEventListener> add, Consumer<GuiEventListener> remove) -
Method Summary
Modifier and TypeMethodDescriptionvoid
addListener
(GuiEventListener button) Unmodifiable reference to the list of buttons on theScreenEvent.screen
.void
removeListener
(GuiEventListener button) Methods inherited from class net.minecraftforge.client.event.ScreenEvent
getScreen
Methods inherited from class net.minecraftforge.eventbus.api.Event
getListenerList, getParentListenerList, getPhase, getResult, hasResult, isCancelable, isCanceled, setCanceled, setPhase, setResult, setup
-
Field Details
-
add
-
remove
-
listenerList
-
-
Constructor Details
-
InitScreenEvent
public InitScreenEvent(Screen screen, List<GuiEventListener> listenerList, Consumer<GuiEventListener> add, Consumer<GuiEventListener> remove)
-
-
Method Details
-
getListenersList
Unmodifiable reference to the list of buttons on theScreenEvent.screen
. -
addListener
-
removeListener
-