ChestShop-3/com/Acrobot/ChestShop/Events/Protection/ProtectionCheckEvent.java
Acrobot 5908eb67fa - Added API (let's start with simple things first)
- Copied utilities from ChestShop-4
- Made code really, really nicer to read
- Made every external plugin's wrapper a listener, so it listens to events instead of being hard-coded.
2012-06-08 15:28:36 +02:00

47 lines
968 B
Java

package com.Acrobot.ChestShop.Events.Protection;
import org.bukkit.block.Block;
import org.bukkit.entity.Player;
import org.bukkit.event.Event;
import org.bukkit.event.HandlerList;
/**
* @author Acrobot
*/
public class ProtectionCheckEvent extends Event {
private static final HandlerList handlers = new HandlerList();
private Result result = Result.DEFAULT;
private Block block;
private Player player;
public ProtectionCheckEvent(Block block, Player player) {
this.block = block;
this.player = player;
}
public Result getResult() {
return result;
}
public void setResult(Result result) {
this.result = result;
}
public Player getPlayer() {
return player;
}
public Block getBlock() {
return block;
}
public HandlerList getHandlers() {
return handlers;
}
public static HandlerList getHandlerList() {
return handlers;
}
}