Refactor Events
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
package com.alttd.essentia.api.events.player;
|
||||
|
||||
import com.alttd.essentia.api.events.EssentiaEvent;
|
||||
import org.bukkit.Location;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.HandlerList;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
public class PlayerRandomTeleportEvent extends EssentiaEvent {
|
||||
|
||||
private static final HandlerList handlerList = new HandlerList();
|
||||
|
||||
private final Player player;
|
||||
private final Location location;
|
||||
|
||||
public PlayerRandomTeleportEvent(Player player, Location location) {
|
||||
this.player = player;
|
||||
this.location = location;
|
||||
}
|
||||
|
||||
public Player getPlayer() {
|
||||
return player;
|
||||
}
|
||||
|
||||
public Location getLocation() {
|
||||
return location;
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
public HandlerList getHandlers() {
|
||||
return handlerList;
|
||||
}
|
||||
|
||||
@NotNull
|
||||
public static HandlerList getHandlerList() {
|
||||
return handlerList;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user