/// <summary> /// LoadContent will be called once per game and is the place to load /// all of your content. /// </summary> protected override void LoadContent() { // Create a new SpriteBatch, which can be used to draw textures. spriteBatch = new SpriteBatch(GraphicsDevice); explosion = Content.Load <SoundEffect>(@"Sounds\explosion"); #if ZUNE backgroundThread.IsBackground = true; backgroundThread.Start(); #endif startMenu = Content.Load <Texture2D>(@"Textures\startmenu"); centerVector = new Vector2((viewportWidth - startMenu.Width) / 2, (viewportHeight - startMenu.Height) / 2); background.Load(spriteBatch); player.Load(spriteBatch); fade.Load(spriteBatch); explosionManager.Load(spriteBatch); fps.Load(spriteBatch); fps.InSpriteBatch = true; ActivateStartMenu(); }
/// <summary> /// LoadContent will be called once per game and is the place to load /// all of your content. /// </summary> protected override void LoadContent() { // Create a new SpriteBatch, which can be used to draw textures. spriteBatch = new SpriteBatch(GraphicsDevice); startMenu = Content.Load <Texture2D>(@"Textures\startmenu"); centerVector = new Vector2((viewportWidth - startMenu.Width) / 2, (viewportHeight - startMenu.Height) / 2); background.Load(spriteBatch); player.Load(spriteBatch); fade.Load(spriteBatch); explosionManager.Load(spriteBatch); ActivateStartMenu(); }
/// <summary> /// LoadContent will be called once per game and is the place to load /// all of your content. /// </summary> protected override void LoadContent() { renderTarget = new RenderTarget2D(GraphicsDevice, GraphicsDevice.Viewport.Width, GraphicsDevice.Viewport.Height, true, GraphicsDevice.DisplayMode.Format, GraphicsDevice.PresentationParameters.DepthStencilFormat); //renderTarget = new RenderTarget2D(GraphicsDevice, GraphicsDevice.PresentationParameters.BackBufferWidth, // GraphicsDevice.PresentationParameters.BackBufferHeight, false, SurfaceFormat.Color, DepthFormat.None); //, GraphicsDevice.PresentationParameters.MultiSampleCount, GraphicsDevice.PresentationParameters.MultiSampleType, GraphicsDevice.PresentationParameters.MultiSampleQuality //effect = Content.Load<Effect>(@"Effects\Normal"); //effect = Content.Load<Effect>(@"Effects\NightTime"); //effect = Content.Load<Effect>(@"Effects\Negative"); //effect = Content.Load<Effect>(@"Effects\SwitchRGB"); //effect = Content.Load<Effect>(@"Effects\Sharpen"); //effect = Content.Load<Effect>(@"Effects\Blur"); //effect = Content.Load<Effect>(@"Effects\Embossed"); //effect = Content.Load<Effect>(@"Effects\GrayScale"); //effect = Content.Load<Effect>(@"Effects\Chalk"); //effect = Content.Load<Effect>(@"Effects\Wavy"); explosion = Content.Load <SoundEffect>(@"Sounds\explosion"); // Create a new SpriteBatch, which can be used to draw textures. spriteBatch = new SpriteBatch(GraphicsDevice); startMenu = Content.Load <Texture2D>(@"Textures\startmenu"); centerVector = new Vector2((viewportWidth - startMenu.Width) / 2, (viewportHeight - startMenu.Height) / 2); background.Load(spriteBatch); player.Load(spriteBatch); fade.Load(spriteBatch); explosionManager.Load(spriteBatch); ActivateStartMenu(); }