コード例 #1
0
    public static void Main(string[] args)
    {
        InitializeProgramLookup();

        if (args == null || args.Length == 0)
        {
            Console.WriteLine("No arguments specified.");
            return;
        }
        ProgramCommands command = ProgramCommands.Not_Recognized;

        if (!Enum.TryParse(args[0], out command))
        {
            Console.WriteLine("Not recognized command.");
            return;
        }
        programLookup[command].Invoke();
        Console.ReadLine();
    }
コード例 #2
0
    void Start()
    {
        //Instatiate Board manager and the Board MVC as a component
        boardManager = new BoardManager();
        boardManager.InstantiateBoardMVC();
        BoardLayout();

        //Instatiate Program manager and the Program MVC as a component
        programManager = new ProgramManager();
        programManager.InstantiateProgramModeMVC();

        //Program commands from program mode will be used from here,add to list, play commands etc.
        //Futute work will involve a different method of saving commands.
        //Script can be found in the Program Commands folder
        programCommands = new ProgramCommands();
        programCommands.SetModel(boardManager.boardModel);

        //Display initial board setup
        boardDisplay.text = boardManager.boardView.UpdateBoardDisplay();

        //Win condition UI and instructions
        levelWinCondition.text = WinConditionStatus();
    }
コード例 #3
0
 public ShowAllWindowRule(ProgramCommands programCommands) =>
コード例 #4
0
 public void ShowAll()
 {
     ProgramCommands.ShowAllCommands();
 }
コード例 #5
0
 public ShowAllWindowRule(ProgramCommands programCommands)
 {
     _progCommands = programCommands;
 }