/**
 *  The root class of all the MUDEvents.
 */

package mud.core;

import mud.core.*;
public abstract class MUDEvent extends mud.core.MUDEventObject
{
    /**
     *  Construct the new event.
     */
    public MUDEvent(GameObject goSource, int iScope, int iID)
    {
        super(goSource, iScope);
        this.iID = iID;
    }
    
    
    /**
     *  Get the event id.
     */
    public int getID()
    {
        return iID;
    }
    
    
    /**
     *  Is the event consumed?
     */
    public boolean isConsumed()
    {
        return bConsumed;
    }
       
    
    // properties
    
    /**
     *  Player events (die, attack, connect, disconnect, talk, whisper)
     */
    public final static int PLAYER_EVENT_MASK = 0x01;
    
    /**
     *  Server events (shutdown, ready)
     */
    public final static int SERVICE_EVENT_MASK = 0x02;
    
    /**
     *  Item events (move, enter, leave, open, close)
     */
    public final static int ITEM_EVENT_MASK = 0x03;
    
    // scope
    
    public final static int SELF = 0x00;
    public final static int CONTAINER = 0x01;
    public final static int ROOM = 0x02;
    public final static int GLOBAL = 0x04;
    
    /**
     *  Event ID
     */
    protected int iID;
}