2021-01-03 07:21:15 +00:00
|
|
|
package dev.plex.event;
|
2020-11-05 21:17:14 +00:00
|
|
|
|
2021-01-03 07:21:15 +00:00
|
|
|
import dev.plex.player.PlexPlayer;
|
|
|
|
import dev.plex.rank.enums.Rank;
|
2022-01-27 05:28:30 +00:00
|
|
|
import lombok.Data;
|
2022-02-25 07:09:55 +00:00
|
|
|
import lombok.EqualsAndHashCode;
|
2022-01-27 05:28:30 +00:00
|
|
|
import org.bukkit.command.CommandSender;
|
2020-11-05 21:17:14 +00:00
|
|
|
import org.bukkit.event.Event;
|
|
|
|
import org.bukkit.event.HandlerList;
|
|
|
|
|
2022-02-07 17:07:48 +00:00
|
|
|
/**
|
|
|
|
* Event that is ran when an admin's rank is set
|
|
|
|
*/
|
2022-02-25 07:15:13 +00:00
|
|
|
@EqualsAndHashCode(callSuper = false)
|
2022-01-27 05:28:30 +00:00
|
|
|
@Data
|
2020-11-05 21:17:14 +00:00
|
|
|
public class AdminSetRankEvent extends Event
|
|
|
|
{
|
2020-11-06 18:19:38 +00:00
|
|
|
private static final HandlerList handlers = new HandlerList();
|
2020-11-05 21:17:14 +00:00
|
|
|
|
2022-02-07 17:07:48 +00:00
|
|
|
/**
|
|
|
|
* The sender who added the player
|
|
|
|
*/
|
2022-01-27 05:28:30 +00:00
|
|
|
private final CommandSender sender;
|
2022-02-07 17:07:48 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* The PlexPlayer that was removed
|
|
|
|
*/
|
2022-01-27 05:28:30 +00:00
|
|
|
private final PlexPlayer plexPlayer;
|
2022-02-07 17:07:48 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* The rank the player was set to
|
|
|
|
*/
|
2022-01-27 05:28:30 +00:00
|
|
|
private final Rank rank;
|
2020-11-05 21:17:14 +00:00
|
|
|
|
2022-02-26 06:26:42 +00:00
|
|
|
public static HandlerList getHandlerList()
|
2020-11-05 21:17:14 +00:00
|
|
|
{
|
|
|
|
return handlers;
|
|
|
|
}
|
|
|
|
|
2022-02-26 06:26:42 +00:00
|
|
|
@Override
|
|
|
|
public HandlerList getHandlers()
|
2020-11-06 18:19:38 +00:00
|
|
|
{
|
|
|
|
return handlers;
|
|
|
|
}
|
2020-11-05 21:17:14 +00:00
|
|
|
}
|