Class ChatChannelResetEvent

java.lang.Object
org.bukkit.event.Event
dev.itsharshxd.zentrix.api.events.ZentrixEvent
dev.itsharshxd.zentrix.api.events.chat.ChatChannelResetEvent

public final class ChatChannelResetEvent extends ZentrixEvent
Called after Zentrix put a player back into ChatChannel.GLOBAL on its own: when they became a spectator, joined or rejoined a match, were revived, or could no longer use the channel they had selected, as well as through ChatChannelService#resetChannel.

These resets are not requests and cannot be cancelled, which is why they do not fire ChatChannelSwitchEvent. Only fired when the player was actually in another channel.

Main thread; only fired while a listener is registered.

Since:
1.8.0
  • Nested Class Summary

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

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

    Constructors
    Constructor
    Description
    ChatChannelResetEvent(@NotNull org.bukkit.entity.Player player, @NotNull ChatChannel previousChannel)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static @NotNull org.bukkit.event.HandlerList
     
    @NotNull org.bukkit.event.HandlerList
    Gets the handler list for this event.
    @NotNull org.bukkit.entity.Player
    The player whose channel was reset.
    @NotNull ChatChannel
    The channel they were in before.

    Methods inherited from class org.bukkit.event.Event

    callEvent, getEventName, isAsynchronous

    Methods inherited from class java.lang.Object

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

    • ChatChannelResetEvent

      public ChatChannelResetEvent(@NotNull @NotNull org.bukkit.entity.Player player, @NotNull @NotNull ChatChannel previousChannel)
  • Method Details

    • getPlayer

      @NotNull public @NotNull org.bukkit.entity.Player getPlayer()
      The player whose channel was reset.
    • getPreviousChannel

      @NotNull public @NotNull ChatChannel getPreviousChannel()
      The channel they were in before.
    • getHandlers

      @NotNull public @NotNull org.bukkit.event.HandlerList getHandlers()
      Description copied from class: ZentrixEvent
      Gets the handler list for this event.
      Overrides:
      getHandlers in class ZentrixEvent
      Returns:
      The handler list
    • getHandlerList

      @NotNull public static @NotNull org.bukkit.event.HandlerList getHandlerList()