PunishmentEvent Class
Introduction#
The PunishmentEvent class represents an event that is triggered when a punishment is applied to a player.
Methods#
This class extends UserCancellableEvent and adds methods related to punishments.
type#
java
PunishmentType type();Description:
Gets the type of punishment that was applied.
Returns:
The PunishmentType of the punishment.
cloudCheckTypes#
java
Set<CloudCheckType> cloudCheckTypes();Description:
Gets the cloud checks that triggered this punishment.
Returns:
The CloudCheckTypes of the punishment.
Getter reason#
java
String reason();Description:
Gets the reason for the punishment.
Returns:
The reason as a String.
Setter reason#
java
void reason(String reason);Description:
Changes the reason for the punishment before it is applied.
Parameters:
reason- The new punishment reason.
Returns:
Nothing.