41 lines
958 B
Java
41 lines
958 B
Java
package net.knarcraft.blacksmith.event;
|
|
|
|
import net.citizensnpcs.api.npc.NPC;
|
|
import org.bukkit.entity.Player;
|
|
import org.bukkit.event.Event;
|
|
import org.jetbrains.annotations.NotNull;
|
|
|
|
/**
|
|
* The base class for all blacksmith plugin events
|
|
*/
|
|
@SuppressWarnings("unused")
|
|
public abstract class AbstractBlacksmithPluginEvent extends Event implements BlacksmithPluginEvent {
|
|
|
|
protected final NPC npc;
|
|
protected final Player player;
|
|
|
|
/**
|
|
* Instantiates a new blacksmith plugin event
|
|
*
|
|
* @param npc <p>The NPC involved in the event</p>
|
|
* @param player <p>The player involved in the event</p>
|
|
*/
|
|
public AbstractBlacksmithPluginEvent(@NotNull NPC npc, @NotNull Player player) {
|
|
this.npc = npc;
|
|
this.player = player;
|
|
}
|
|
|
|
@Override
|
|
@NotNull
|
|
public NPC getNpc() {
|
|
return this.npc;
|
|
}
|
|
|
|
@Override
|
|
@NotNull
|
|
public Player getPlayer() {
|
|
return this.player;
|
|
}
|
|
|
|
}
|