Package net.minecraftforge.event
Class TickEvent.ServerTickEvent
java.lang.Object
net.minecraftforge.eventbus.api.Event
net.minecraftforge.event.TickEvent
net.minecraftforge.event.TickEvent.ServerTickEvent
- Direct Known Subclasses:
TickEvent.ServerTickEvent.Post
,TickEvent.ServerTickEvent.Pre
- Enclosing class:
TickEvent
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
static class
Nested classes/interfaces inherited from class net.minecraftforge.event.TickEvent
TickEvent.ClientTickEvent, TickEvent.LevelTickEvent, TickEvent.Phase, TickEvent.PlayerTickEvent, TickEvent.RenderTickEvent, TickEvent.ServerTickEvent, TickEvent.Type
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
-
Constructor Summary
ModifierConstructorDescriptionprotected
ServerTickEvent
(BooleanSupplier haveTime, MinecraftServer server, TickEvent.Phase phase) ServerTickEvent
(TickEvent.Phase phase, BooleanSupplier haveTime, MinecraftServer server) Deprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Methods inherited from class net.minecraftforge.eventbus.api.Event
getListenerList, getPhase, getResult, hasResult, isCancelable, isCanceled, setCanceled, setPhase, setResult
-
Field Details
-
haveTime
-
server
-
-
Constructor Details
-
ServerTickEvent
@Deprecated(forRemoval=true, since="1.20.6") public ServerTickEvent(TickEvent.Phase phase, BooleanSupplier haveTime, MinecraftServer server) Deprecated, for removal: This API element is subject to removal in a future version. -
ServerTickEvent
-
-
Method Details
-
haveTime
public boolean haveTime()- Returns:
true
whether the server has enough time to perform any additional tasks (usually IO related) during the current tick, otherwisefalse
-
getServer
Returns the server instance.- Returns:
- the server instance
-