Ejemplo n.º 1
0
 protected virtual void HandleActions(GameEngine engine, IEnumerable<StateAction> actions)
 {
     if (actions == null || actions.Count() == 0)
         return;
     foreach (StateAction action in actions)
     {
         if(action != null)
             action.Execute(engine);
     }
 }
Ejemplo n.º 2
0
 public abstract void Execute(GameEngine engine);
Ejemplo n.º 3
0
 public override void Execute(GameEngine engine)
 {
     engine.IsRunning = false;
 }
Ejemplo n.º 4
0
 protected abstract void Redraw(GameEngine engine);
Ejemplo n.º 5
0
 public virtual void Update(GameEngine engine)
 {
     HandleActions(engine, RetrieveEvents());
     Redraw(engine);
 }
Ejemplo n.º 6
0
 public override void Execute(GameEngine engine)
 {
     _notifiable_manager.Notify("haxxit.map.command", this, new CommandEventArgs(Destination, Source, Command));
 }
Ejemplo n.º 7
0
 public override void Execute(GameEngine engine)
 {
     _notifiable_manager.Notify("haxxit.map.move", this, new MoveEventArgs(Source, Source - Destination));
 }