Package org.bukkit.event.player
Class PlayerChatEvent
java.lang.Object
org.bukkit.event.Event
org.bukkit.event.player.PlayerEvent
org.bukkit.event.player.PlayerChatEvent
- All Implemented Interfaces:
- Cancellable
Deprecated.
Holds information for player chat and commands
- 
Nested Class SummaryNested classes/interfaces inherited from class org.bukkit.event.EventEvent.Result
- 
Field SummaryFields inherited from class org.bukkit.event.player.PlayerEventplayer
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionDeprecated.Gets the format to use to display this chat messagestatic HandlerListDeprecated.Deprecated.Deprecated.Gets the message that the player is attempting to sendDeprecated.Gets a set of recipients that this chat message will be displayed tobooleanDeprecated.Gets the cancellation state of this event.voidsetCancelled(boolean cancel) Deprecated.Sets the cancellation state of this event.voidDeprecated.Sets the format to use to display this chat messagevoidsetMessage(String message) Deprecated.Sets the message that the player will sendvoidDeprecated.Sets the player that this message will display as, or command will be executed asMethods inherited from class org.bukkit.event.player.PlayerEventgetPlayerMethods inherited from class org.bukkit.event.EventgetEventName, isAsynchronous
- 
Constructor Details
- 
Method Details- 
isCancelledpublic boolean isCancelled()Deprecated.Description copied from interface:CancellableGets the cancellation state of this event. A cancelled event will not be executed in the server, but will still pass to other plugins- Specified by:
- isCancelledin interface- Cancellable
- Returns:
- true if this event is cancelled
 
- 
setCancelledpublic void setCancelled(boolean cancel) Deprecated.Description copied from interface:CancellableSets the cancellation state of this event. A cancelled event will not be executed in the server, but will still pass to other plugins.- Specified by:
- setCancelledin interface- Cancellable
- Parameters:
- cancel- true if you wish to cancel this event
 
- 
getMessageDeprecated.Gets the message that the player is attempting to send- Returns:
- Message the player is attempting to send
 
- 
setMessageDeprecated.Sets the message that the player will send- Parameters:
- message- New message that the player will send
 
- 
setPlayerDeprecated.Sets the player that this message will display as, or command will be executed as- Parameters:
- player- New player which this event will execute as
 
- 
getFormatDeprecated.Gets the format to use to display this chat message- Returns:
- String.Format compatible format string
 
- 
setFormatDeprecated.Sets the format to use to display this chat message- Parameters:
- format- String.Format compatible format string
 
- 
getRecipientsDeprecated.Gets a set of recipients that this chat message will be displayed to- Returns:
- All Players who will see this chat message
 
- 
getHandlersDeprecated.- Specified by:
- getHandlersin class- Event
 
- 
getHandlerListDeprecated.
 
- 
AsyncPlayerChatEvent.Listening to this event forces chat to wait for the main thread which causes delays for chat.
AsyncPlayerChatEventis the encouraged alternative for thread safe implementations.