PlayerChangeGameModeEvent

Called when the given player changes game mode.

Types

Link copied to clipboard
data class Result(val newGameMode: GameMode) : Record

The result of an attempt to change a player's game mode.

Functions

Link copied to clipboard
abstract fun allow()

Allows this event to occur.

Link copied to clipboard

Allows this event to occur, and sets the result to the given result.

Link copied to clipboard
abstract fun deny()

Denies an event from occurring.

Link copied to clipboard

Denies this event from occur, and sets the result to the given result.

Link copied to clipboard
abstract fun isAllowed(): Boolean

Checks if this event is allowed to happen.

Properties

Link copied to clipboard
abstract val newGameMode: GameMode

The game mode that the player will be in after the change.

Link copied to clipboard
abstract val oldGameMode: GameMode

The game mode that the player was in before the change.

Link copied to clipboard
abstract val player: Player

The player involved in this event.

Link copied to clipboard

The result that is returned by this event.