Class GameStopEvent

java.lang.Object
org.bukkit.event.Event

public class GameStopEvent extends GameEvent
Called after a KOTL game has been stopped and its players have been cleaned up.

Scoreboards and boss bars have been removed, inventories and player state have been restored where possible, players have been teleported to the configured end location, and the game's player set is empty.

Use getStoppedPlayers() to inspect the immutable snapshot of players who were part of the game before cleanup. This event is useful for external logging, administration integrations, and arena lifecycle tracking.

This event is informational and is not cancellable.

  • Nested Class Summary

    Nested classes/interfaces inherited from class org.bukkit.event.Event

    org.bukkit.event.Event.Result
  • Field Summary

    Fields inherited from class GameEvent

    game
  • Constructor Summary

    Constructors
    Constructor
    Description
    GameStopEvent(@NotNull Game game, @NotNull StopReason reason)
    Constructs a game stop event without a player snapshot.
    GameStopEvent(@NotNull Game game, @NotNull StopReason reason, @NotNull List<UUID> stoppedPlayers)
    Constructs a new game stop event.
  • Method Summary

    Modifier and Type
    Method
    Description
    static @NotNull org.bukkit.event.HandlerList
    Returns the static Bukkit handler list for this event type.
    @NotNull org.bukkit.event.HandlerList
    Returns the Bukkit handler list for this event type.
    @NotNull StopReason
    Returns why the game was stopped.
    @NotNull List<UUID>
    Returns the immutable UUID snapshot captured before player cleanup.
    Returns a compact debug representation of the stopped game.

    Methods inherited from class GameEvent

    getArena, getGame

    Methods inherited from class org.bukkit.event.Event

    callEvent, getEventName, isAsynchronous

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • GameStopEvent

      public GameStopEvent(@NotNull @NotNull Game game, @NotNull @NotNull StopReason reason)
      Constructs a game stop event without a player snapshot.
      Parameters:
      game - the game that was stopped
      reason - the reason for stopping the game
    • GameStopEvent

      public GameStopEvent(@NotNull @NotNull Game game, @NotNull @NotNull StopReason reason, @NotNull @NotNull List<UUID> stoppedPlayers)
      Constructs a new game stop event.
      Parameters:
      game - the game that was stopped
      reason - the reason for stopping the game
      stoppedPlayers - players that were present before cleanup
  • Method Details

    • getReason

      @NotNull public @NotNull StopReason getReason()
      Returns why the game was stopped.
      Returns:
      the stop reason
    • getStoppedPlayers

      @NotNull public @NotNull List<UUID> getStoppedPlayers()
      Returns the immutable UUID snapshot captured before player cleanup.
      Returns:
      the players present before the game stopped
    • getHandlers

      @NotNull public @NotNull org.bukkit.event.HandlerList getHandlers()
      Returns the Bukkit handler list for this event type.
      Specified by:
      getHandlers in class org.bukkit.event.Event
      Returns:
      this event's handler list
    • getHandlerList

      @NotNull public static @NotNull org.bukkit.event.HandlerList getHandlerList()
      Returns the static Bukkit handler list for this event type.
      Returns:
      this event's handler list
    • toString

      public String toString()
      Returns a compact debug representation of the stopped game.
      Overrides:
      toString in class GameEvent
      Returns:
      a string containing the arena, reason, and player snapshot