Class ServerTickEvents

java.lang.Object
org.quiltmc.qsl.lifecycle.api.event.ServerTickEvents

public final class ServerTickEvents extends Object
Events indicating progress through the tick loop of a Minecraft server.

Events in the class are useful for mods which may need to do processing before or after tick of a Minecraft server.

A note of warning

Callbacks registered to any of these events should ensure as little time as possible is spent executing, since the tick loop is a very hot code path.

  • Field Details

    • START

      public static final Event<ServerTickEvents.Start> START
      An event indicating an iteration of the server's tick loop will start.
    • END

      public static final Event<ServerTickEvents.End> END
      An event indicating the server has finished an iteration of the tick loop.

      Since there will be a time gap before the next tick, this is a great spot to run any asynchronous operations for the next tick.