Exemplo n.º 1
0
        internal void Reset(Actor[][] actor, string levelName)
        {
            LevelLoder loader = new LevelLoder(new GameBoard(), actor);

            loader.Load(levelName);
            level = loader.GetBoard();
            UpdateView();
            UpdateMoveCount();
        }
Exemplo n.º 2
0
        private void btn_startGame_Click(object sender, EventArgs e)
        {
            Actor[][] level    = null;
            View      gameView = null;

            if (levels.Text == "Level One ( 8 X 8 )")
            {
                level    = Level.LevelOne();
                gameView = new LevelOne();
            }
            else if (levels.Text == "Level Two ( 8 X 6 )")
            {
                level    = Level.LevelTwo();
                gameView = new LevelTwo();
            }
            if (level != null)
            {
                LevelLoder loader = new LevelLoder(new GameBoard(), level);
                loader.Load(levels.Text);
                new GameController(loader.GetBoard(), gameView);
            }

            levelSelector.Hide();
        }