Enum Class PlayerKillEvent.PlayerKillCause
java.lang.Object
java.lang.Enum<PlayerKillEvent.PlayerKillCause>
com.tomkeuper.bedwars.api.events.player.PlayerKillEvent.PlayerKillCause
- All Implemented Interfaces:
Serializable
,Comparable<PlayerKillEvent.PlayerKillCause>
,Constable
- Enclosing class:
PlayerKillEvent
Enumeration representing various causes of death events.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionboolean
Checks if the victim is killed by a player's ironGolem, silverfish etc.boolean
Checks if the kill is a final kill.boolean
Checks if the kill is due to a PvP log out.void
setFinalKill
(boolean finalKill) Sets whether the kill is a final kill.Returns the enum constant of this class with the specified name.static PlayerKillEvent.PlayerKillCause[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
UNKNOWN
-
UNKNOWN_FINAL_KILL
-
EXPLOSION
-
EXPLOSION_FINAL_KILL
-
VOID
-
VOID_FINAL_KILL
-
PVP
-
PVP_FINAL_KILL
-
PLAYER_SHOOT
-
PLAYER_SHOOT_FINAL_KILL
-
SILVERFISH
-
SILVERFISH_FINAL_KILL
-
IRON_GOLEM
-
IRON_GOLEM_FINAL_KILL
-
PLAYER_PUSH
-
PLAYER_PUSH_FINAL
-
PLAYER_DISCONNECT
-
PLAYER_DISCONNECT_FINAL
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
isFinalKill
public boolean isFinalKill()Checks if the kill is a final kill.- Returns:
- true if the kill is a final kill, false otherwise.
-
setFinalKill
public void setFinalKill(boolean finalKill) Sets whether the kill is a final kill.- Parameters:
finalKill
- true if the kill is a final kill, false otherwise.
-
isDespawnable
public boolean isDespawnable()Checks if the victim is killed by a player's ironGolem, silverfish etc.- Returns:
- true if the killer is killed by a player's ironGolem, silverfish etc, false otherwise.
-
isPvpLogOut
public boolean isPvpLogOut()Checks if the kill is due to a PvP log out.- Returns:
- true if the kill is due to a PvP log out, false otherwise.
-