/// <summary>
        /// Load graphics content for the game.
        /// </summary>
        public override void LoadContent()
        {
            // Developers Comment or uncomment the bloomComponent to run with effects or not
            // ***************************
            // Comment or uncomment from here
            // ***************************
            // create and add the bloom effect
#if !BLOOM
            bloomComponent          = new BloomComponent(ScreenManager.Game);
            bloomComponent.Settings = BloomSettings.PresetSettings[0];
            ScreenManager.Game.Components.Add(bloomComponent);
            bloomComponent.Initialize();
            bloomComponent.Visible = false; // we want to control when bloom component is drawn
#endif
            // ***************************
            // Comment or uncomment to here
            // ***************************
            // create the starfield
            starfield = new Starfield(Vector2.Zero, ScreenManager.GraphicsDevice,
                                      ScreenManager.Content);
            starfield.LoadContent();

            // start the background soundtrack
            AudioManager.PlaySoundTrack();

            base.LoadContent();
        }
예제 #2
0
        /// <summary>
        /// Loads graphics content for this screen. The background texture is quite
        /// big, so we use our own local ContentManager to load it. This allows us
        /// to unload before going from the menus into the game itself, wheras if we
        /// used the shared ContentManager provided by the ScreenManager, the content
        /// would remain loaded forever.
        /// </summary>
        public override void LoadContent()
        {
            // load the title texture
            titleTexture = ScreenManager.Content.Load <Texture2D>("Textures/title");
            movement     = 0f;

            starfield = new Starfield(
                Vector2.Multiply(new Vector2(
                                     (float)Math.Cos(movement / starsParallaxPeriod),
                                     (float)Math.Sin(movement / starsParallaxPeriod)),
                                 starsParallaxAmplitude),
                ScreenManager.GraphicsDevice, ScreenManager.Content);
            starfield.LoadContent();

            base.LoadContent();
        }
예제 #3
0
        /// <summary>
        /// Loads graphics content for this screen. The background texture is quite
        /// big, so we use our own local ContentManager to load it. This allows us
        /// to unload before going from the menus into the game itself, wheras if we
        /// used the shared ContentManager provided by the ScreenManager, the content
        /// would remain loaded forever.
        /// </summary>
        public override void LoadContent()
        {
            // load the title texture
            titleTexture = ScreenManager.Content.Load<Texture2D>("Textures/title");
            movement = 0f;

            starfield = new Starfield(
                Vector2.Multiply(new Vector2(
                    (float)Math.Cos(movement / starsParallaxPeriod),
                    (float)Math.Sin(movement / starsParallaxPeriod)),
                    starsParallaxAmplitude), 
                ScreenManager.GraphicsDevice, ScreenManager.Content);
            starfield.LoadContent();

            base.LoadContent();
        }
예제 #4
0
        /// <summary>
        /// Load graphics content for the game.
        /// </summary>
        public override void LoadContent()
        {
			
			
		// Developers Comment or uncomment the bloomComponent to run with effects or not
		// ***************************	
		// Comment or uncomment from here
		// ***************************	
            // create and add the bloom effect
#if BLOOM
            bloomComponent = new BloomComponent(ScreenManager.Game);
            bloomComponent.Settings = BloomSettings.PresetSettings[0];
            ScreenManager.Game.Components.Add(bloomComponent);
            bloomComponent.Initialize();
            bloomComponent.Visible = false; // we want to control when bloom component is drawn
#endif
		// ***************************
		// Comment or uncomment to here
		// ***************************	
            // create the starfield
            starfield = new Starfield(Vector2.Zero, ScreenManager.GraphicsDevice, 
                ScreenManager.Content);
            starfield.LoadContent();

            // start the background soundtrack
            AudioManager.PlaySoundTrack();

            base.LoadContent();
        }