private void processEvent(BaseEvent event) {

    // Retrieve all eventlisteners that are subscribed to this eventtype.
    ArrayList<IEventListener> listeners = listenerMap.get(event.getEventType().getID());
    
    if(listeners == null) {
      return;
    }

    for(IEventListener ie : listeners) {
      // handleEvent returns true if the eventlistener wants to "swallow" the event.
      if(ie.handleEvent(event)) {
        Logger.log("EventType: " + event.getEventType().getName() + 
          " was swallowed by: " + ie.getName()
        );
        break;
      }
    }

    // Wildcard listeners get notified of everything that happens.
    ArrayList<IEventListener> wildcards = listenerMap.get(0);
    
    for(IEventListener ie : wildcards) {
      ie.handleEvent(event);
    }
  }