com.cliffblaster.game.api.event
Class Event

java.lang.Object
  extended by com.cliffblaster.game.api.event.Event
Direct Known Subclasses:
BlockChangeEvent, PlayerEvent, ServerEvent

public abstract class Event
extends java.lang.Object


Nested Class Summary
static class Event.Priority
          The order in which an EventListener will be called.
static class Event.Type
          Specify the type of event Do not ever use ordinal(), instead use valueOf, names are permanent
 
Field Summary
protected  Event.Type evtType
           
 
Constructor Summary
Event()
           
 
Method Summary
 void cancel()
          Sets the event as cancelled.
 Event.Type getType()
           
 boolean isCancelled()
          Returns cancel() was called on the event.
 void unCancel()
          Un-Cancel's the event if a previous listener called cancel().
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

evtType

protected Event.Type evtType
Constructor Detail

Event

public Event()
Method Detail

cancel

public void cancel()
Sets the event as cancelled. The event will not continue on the server and will be reverted, unless a subsequent plug-in calls unCancel() on the event.


unCancel

public void unCancel()
Un-Cancel's the event if a previous listener called cancel(). The event will continue on the server as usual, unless a subsequent plug-in calls cancel() on the event.


isCancelled

public boolean isCancelled()
Returns cancel() was called on the event.


getType

public Event.Type getType()