protected override void Initialize() { // TODO: Add your initialization logic here gameMap = new int[10, 10] { { 2, 1, 1, 1, 1, 1, 1, 1, 1, 2 }, { 2, 0, 0, 0, 0, 0, 0, 0, 0, 2 }, { 2, 0, 0, 0, 0, 0, 0, 0, 0, 2 }, { 2, 0, 0, 0, 0, 0, 0, 0, 0, 2 }, { 2, 0, 0, 0, 0, 0, 0, 0, 0, 2 }, { 2, 0, 0, 0, 0, 0, 0, 0, 0, 2 }, { 2, 0, 0, 0, 0, 0, 0, 0, 0, 2 }, { 2, 0, 0, 0, 0, 0, 0, 0, 0, 2 }, { 2, 0, 0, 0, 0, 0, 0, 0, 0, 2 }, { 2, 2, 2, 2, 2, 2, 2, 2, 2, 2 } }; BuildWorld.Build(gameMap); _graphics.PreferredBackBufferWidth = 1500; // set this value to the desired width of your window _graphics.PreferredBackBufferHeight = 1000; // set this value to the desired height of your window _graphics.ApplyChanges(); TargetElapsedTime = TimeSpan.FromSeconds(1 / 2.0f); base.Initialize(); }
protected override void Draw(GameTime gameTime) { GraphicsDevice.Clear(Color.CornflowerBlue); BuildWorld.Draw(_spriteBatch, gameMap, floor, shownWall, hiddenWall); // TODO: Add your drawing code here base.Draw(gameTime); }