Package net.dzikoysk.funnyguilds.event
Class FunnyEvent
java.lang.Object
org.bukkit.event.Event
net.dzikoysk.funnyguilds.event.FunnyEvent
- All Implemented Interfaces:
org.bukkit.event.Cancellable
- Direct Known Subclasses:
AbstractRankEvent,GuildEntityExplodeEvent,GuildEvent
public abstract class FunnyEvent
extends org.bukkit.event.Event
implements org.bukkit.event.Cancellable
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.bukkit.event.Event
org.bukkit.event.Event.Result -
Constructor Summary
ConstructorsConstructorDescriptionFunnyEvent(FunnyEvent.EventCause eventCause, @Nullable User doer) FunnyEvent(FunnyEvent.EventCause eventCause, @Nullable User doer, boolean isAsync) -
Method Summary
Modifier and TypeMethodDescriptionThe message that will be displayed for event doer when the event is cancelled.abstract Stringpanda.std.Option<User>getDoer()booleanvoidsetCancelled(boolean cancelled) voidsetCancelMessage(String cancelMessage) Sets the message that will be displayed for event doer when the event is cancelled.Methods inherited from class org.bukkit.event.Event
getEventName, getHandlers, isAsynchronous
-
Constructor Details
-
FunnyEvent
-
FunnyEvent
-
-
Method Details
-
getEventCause
-
getDoer
- Returns:
- the doer of the event, if doer wasn't a user the Option will be empty
-
getDefaultCancelMessage
-
getCancelMessage
The message that will be displayed for event doer when the event is cancelled.- Returns:
- the set cancel message, if null the default cancel message will be returned.
-
setCancelMessage
Sets the message that will be displayed for event doer when the event is cancelled.- Parameters:
cancelMessage- the cancel message
-
isCancelled
public boolean isCancelled()- Specified by:
isCancelledin interfaceorg.bukkit.event.Cancellable
-
setCancelled
public void setCancelled(boolean cancelled) - Specified by:
setCancelledin interfaceorg.bukkit.event.Cancellable
-