Class PlayerKillEvent
java.lang.Object
org.bukkit.event.Event
com.andrei1058.bedwars.api.events.player.PlayerKillEvent
public class PlayerKillEvent
extends org.bukkit.event.Event
-
Nested Class Summary
Nested classes/interfaces inherited from class org.bukkit.event.Event
org.bukkit.event.Event.Result
-
Constructor Summary
ConstructorDescriptionPlayerKillEvent
(@NotNull IArena arena, @NotNull org.bukkit.entity.Player victim, @Nullable ITeam victimTeam, @Nullable org.bukkit.entity.Player killer, @Nullable ITeam killerTeam, @Nullable Function<org.bukkit.entity.Player, String> message, @NotNull PlayerKillEvent.PlayerKillCause cause) PlayerKillEvent
(@NotNull IArena arena, org.bukkit.entity.Player victim, org.bukkit.entity.Player killer, Function<org.bukkit.entity.Player, String> message, PlayerKillEvent.PlayerKillCause cause) Deprecated. -
Method Summary
Modifier and TypeMethodDescriptiongetArena()
getCause()
Get kill causestatic org.bukkit.event.HandlerList
org.bukkit.event.HandlerList
org.bukkit.entity.Player
Killer can be NULL (void etc.)Get kill chat message.org.bukkit.entity.Player
Get the Player who died.boolean
Checks if the killer gets the kill soundvoid
setKillerTeam
(ITeam killerTeam) void
setMessage
(@Nullable Function<org.bukkit.entity.Player, String> message) Set chat message.void
setPlaySound
(boolean playSound) Set if the killer should get the kill soundvoid
setVictimTeam
(ITeam victimTeam) Methods inherited from class org.bukkit.event.Event
getEventName, isAsynchronous
-
Constructor Details
-
PlayerKillEvent
@Deprecated public PlayerKillEvent(@NotNull @NotNull IArena arena, org.bukkit.entity.Player victim, org.bukkit.entity.Player killer, Function<org.bukkit.entity.Player, String> message, PlayerKillEvent.PlayerKillCause cause) Deprecated.Called when a Player got killed during the game.- Parameters:
killer
- can be NULL.
-
PlayerKillEvent
public PlayerKillEvent(@NotNull @NotNull IArena arena, @NotNull @NotNull org.bukkit.entity.Player victim, @Nullable @Nullable ITeam victimTeam, @Nullable @Nullable org.bukkit.entity.Player killer, @Nullable @Nullable ITeam killerTeam, @Nullable @Nullable Function<org.bukkit.entity.Player, String> message, @NotNull @NotNull PlayerKillEvent.PlayerKillCause cause)
-
-
Method Details
-
getKiller
public org.bukkit.entity.Player getKiller()Killer can be NULL (void etc.) -
getMessage
Get kill chat message. -
setMessage
Set chat message. -
getCause
Get kill cause -
getArena
-
getVictim
public org.bukkit.entity.Player getVictim()Get the Player who died. -
playSound
public boolean playSound()Checks if the killer gets the kill sound -
setPlaySound
public void setPlaySound(boolean playSound) Set if the killer should get the kill sound -
getKillerTeam
-
getVictimTeam
-
setKillerTeam
-
setVictimTeam
-
getHandlers
public org.bukkit.event.HandlerList getHandlers()- Specified by:
getHandlers
in classorg.bukkit.event.Event
-
getHandlerList
public static org.bukkit.event.HandlerList getHandlerList()
-