Ejemplo n.º 1
0
 public virtual void OnXMLEvent( XMLEventType eventType, object obj )
 {
     try
     {
         if( XMLEventsDatabase.ContainsKey( eventType ) )
         {
             foreach( string code in XMLEventsDatabase[eventType] )
             {
                 if( obj != null ) //If there is an object, let's invoke the code on it
                     XmlSpawner.ExecuteAction( obj, this, code );
                 else //Or else let's invoke it on the creature
                     XmlSpawner.ExecuteAction( this, this, code );
             }
         }
     }
     catch( Exception e )
     {
         Console.WriteLine( e.Message );
     }
 }
Ejemplo n.º 2
0
 public virtual void OnXMLEvent( XMLEventType eventType )
 {
     OnXMLEvent( eventType, null );
 }