Example #1
0
        public PlayGroundWithChars(int numberOfPlayers)
        {
            _game = new Game(numberOfPlayers);
            _totalPlayers = numberOfPlayers;
            InitializeComponent();
            if (numberOfPlayers < 2)
                groupBox3.Visible = false;

            for (var i = 0; i <Map.XSize; i++)
            {
                dataGridView1.Columns.Add(i.ToString(), i.ToString());
            }
            dataGridView1.Rows.Add(Map.YSize);
            PrintMap(_game.Map);
        }
Example #2
0
        public PlayGroundWithImages(int numberOfPlayers)
        {
            _game = new Game(numberOfPlayers);
            _totalPlayers = numberOfPlayers;
            InitializeComponent();
            if (numberOfPlayers < 2)
                groupBox3.Visible = false;

            for (var i = 0; i < Map.XSize; i++)
            {
                var clmn = new DataGridViewImageColumn();
                dataGridView1.Columns.Add(clmn);
            }
            dataGridView1.Rows.Add(Map.YSize);
            PrintMap(_game.Map);
        }