protected override void Initialize() { graphics.PreferredBackBufferWidth = resX; // GraphicsDevice.DisplayMode.Width; graphics.PreferredBackBufferHeight = resY; // GraphicsDevice.DisplayMode.Height; graphics.IsFullScreen = fullscreen; graphics.ApplyChanges(); Window.Title = "Planets"; seed = (int)DateTime.Now.Ticks; noise = new NoiseGenerator(seed); quadrantWidth = 3000; quadrantHeight = 3000; //totalPlanets = noise.random.Next(10, 21); //totalShips = 1000; loader = new Loader(this); base.Initialize(); }
protected override void LoadContent() { device = graphics.GraphicsDevice; spriteBatch = new SpriteBatch(device); screenWidth = device.PresentationParameters.BackBufferWidth; screenHeight = device.PresentationParameters.BackBufferHeight; loading = true; loader = new Loader(this); loader.loadStuffImediatly(); loader.loadStuffInBackground(); }