示例#1
0
 public void execute()
 {
     if (!_commands.isEmpty())
     {
         Debug.Log(_commands [0]);
         var command = _commands.pop();
         if (command is MacroCommand)
         {
             var Mcommand = command as MacroCommand;
             if (Mcommand.hasNext())
             {
                 _commands.Insert(0, Mcommand);
             }
             Mcommand.execute();
         }
         else
         {
             command.execute();
         }
     }
 }