Package konquest.api.event.ruin
Class KonquestRuinCaptureEvent
java.lang.Object
org.bukkit.event.Event
konquest.api.event.KonquestEvent
konquest.api.event.ruin.KonquestRuinEvent
konquest.api.event.ruin.KonquestRuinCaptureEvent
- All Implemented Interfaces:
org.bukkit.event.Cancellable
public class KonquestRuinCaptureEvent
extends KonquestRuinEvent
implements org.bukkit.event.Cancellable
Called before a player captures a ruin, but after
KonquestRuinAttackEvent
Players capture ruins by breaking all critical blocks inside. When the final critical block is broken, all players located inside of the ruin receive a reward. Canceling this event will stop the final critical block break and prevent the ruin from being captured.
- Author:
- Rumsfield
-
Nested Class Summary
Nested classes/interfaces inherited from class org.bukkit.event.Event
org.bukkit.event.Event.Result -
Constructor Summary
ConstructorsConstructorDescriptionKonquestRuinCaptureEvent(KonquestAPI konquest, KonquestRuin ruin, KonquestPlayer player, List<? extends KonquestPlayer> rewardPlayers) Default constructor -
Method Summary
Modifier and TypeMethodDescriptionGets the player that captured this ruin.List<? extends KonquestPlayer>Gets the list of players that get a reward for capturing the ruin.booleanvoidsetCancelled(boolean val) Methods inherited from class konquest.api.event.ruin.KonquestRuinEvent
getRuinMethods inherited from class konquest.api.event.KonquestEvent
getHandlerList, getHandlers, getKonquestMethods inherited from class org.bukkit.event.Event
getEventName, isAsynchronous
-
Constructor Details
-
KonquestRuinCaptureEvent
public KonquestRuinCaptureEvent(KonquestAPI konquest, KonquestRuin ruin, KonquestPlayer player, List<? extends KonquestPlayer> rewardPlayers) Default constructor- Parameters:
konquest- The API instanceruin- The ruinplayer- The playerrewardPlayers- The players receiving reward
-
-
Method Details
-
getPlayer
Gets the player that captured this ruin. This player broke the final critical block.- Returns:
- The player
-
getRewardPlayers
Gets the list of players that get a reward for capturing the ruin.- Returns:
- The list of players
-
isCancelled
public boolean isCancelled()- Specified by:
isCancelledin interfaceorg.bukkit.event.Cancellable
-
setCancelled
public void setCancelled(boolean val) - Specified by:
setCancelledin interfaceorg.bukkit.event.Cancellable
-