Ejemplo n.º 1
0
 public StartScreen(ref ConsoleStyleLabel label)
 {
     outputLabel   = label;
     validCommands = new Command[] { Command.NEW, Command.CONTINUE, Command.HELP };
     parser        = new CommandParser(validCommands);
     EnterState();
 }
Ejemplo n.º 2
0
 public NewGame(ref ConsoleStyleLabel label)
 {
     outputLabel   = label;
     validCommands = new Command[] { Command.YES, Command.NO };
     parser        = new CommandParser(validCommands);
     EnterState();
 }
Ejemplo n.º 3
0
 public FiniteStateMachine(ref ConsoleStyleLabel label)
 {
     outputLabel  = label;
     defCommands  = new Command[] { Command.OPTION, Command.FONT, Command.SIZE, Command.EXIT };
     defParser    = new CommandParser(defCommands);
     currentState = new StartScreen(ref outputLabel);
 }
Ejemplo n.º 4
0
 public MainGame(ref ConsoleStyleLabel label, Player p)
 {
     outputLabel   = label;
     validCommands = new Command[] { Command.STATISTICS, Command.SHOW, Command.VIEW, Command.HELP, Command.SAVE };
     parser        = new CommandParser(validCommands);
     player        = p;
     EnterState();
 }
Ejemplo n.º 5
0
 public ChooseDiff(ref ConsoleStyleLabel label, string name)
 {
     this.name     = name;
     outputLabel   = label;
     validCommands = new Command[] { Command.EASY, Command.MEDIUM, Command.HARD };
     parser        = new CommandParser(validCommands);
     EnterState();
 }