PlayerItemCooldownEvent

Called when a cooldown is set on usage of the given item for the given player.

Types

Link copied to clipboard
data class Result(val cooldown: Int) : Record

The result of a cooldown event.

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 cooldown: Int

The time, in ticks, that the cooldown will be in effect for.

Link copied to clipboard
abstract val item: ItemType

The item type that the cooldown is being applied to.

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.