public MainWindow()
        {
            InitializeComponent();

            levelModel = new ModelLevel();
            levelReader = new LevelReader(levelModel);

            fillDropdown();
        }
Example #2
0
        public MainWindow()
        {
            InitializeComponent();

            levelModel = new ModelLevel();
            levelReader = new LevelReader(levelModel);
            highScore = new HighScore();

            highScoreView = new HighScoreView(levelModel, highScore);
            mainGrid.Children.Add(highScoreView);
            highScoreView.Visibility = Visibility.Collapsed;

            fillDropdown();
        }
Example #3
0
        public LevelEditor(ModelLevel levelModel, LevelReader levelReader)
        {
            InitializeComponent();

            //Fill the list with existing levels
            this.levelModel = levelModel;
            this.levelReader = levelReader;
            mapsListBox.ItemsSource = levelModel.Maps;

            //Fill the list with level tiles.
            tilesListBox.Items.Add(new Wall());
            tilesListBox.Items.Add(new Floor());
            tilesListBox.Items.Add(new Target());
            tilesListBox.Items.Add(new Box());
            tilesListBox.Items.Add(new Forklift());
            tilesListBox.SelectedIndex = 0;

            initGrid();
        }