PrePauseSoundEvent
The PrePauseSoundEvent
class is a custom event in the Bukkit API. It is triggered before a sound is paused in the MelodyMine plugin. This event provides information about the sound that is about to be paused, including the sound name, whether the pause should be sent to all players, and the socket ID associated with the event.
Class Properties
soundName
String
The name of the sound that is about to be paused.
sendToAll
Boolean
Indicates whether the pause event should be sent to all players.
socketID
String?
The socket ID associated with the event. This could be null.
Class Methods
isCancelled
Boolean
Checks if the event is cancelled.
setCancelled
Void
Sets the cancellation state of this event. A cancelled event will not be executed in the server, but will still pass to other plugins.
Example Usage
Here is an example of how to listen to this event using the Bukkit event API:
Remember to register your event listener in your plugin's onEnable
method for the event to be properly handled.
Last updated