Exemplo n.º 1
0
 public void Start()
 {
     currentMode = new GameScreen(this);
 }
Exemplo n.º 2
0
        /// <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);

            // TODO: use this.Content to load your game content here

            // Load sound effects
            PlaySound.thud = Content.Load<SoundEffect>("thud"); // Hitting walls, failed bullet; from pdsounds.org, which claims to be public domain
            PlaySound.pew = Content.Load<SoundEffect>("pew"); // Shooting sound effect; Made it myself in sfxr
            PlaySound.aspect = Content.Load<SoundEffect>("aspect"); // Changing color aspect; Made it myself in sfxr
            PlaySound.boom = Content.Load<SoundEffect>("boom"); // Enemy defeated; Made it myself in sfxr
            PlaySound.die = Content.Load<SoundEffect>("die"); // Death chime; Made it myself in sfxr
            PlaySound.win = Content.Load<SoundEffect>("win"); // Level victory chime; Made it myself in sfxr
            PlaySound.pause = Content.Load<SoundEffect>("pause"); // Pause chime; Made it myself in sfxr
            PlaySound.Initialize();

            // Load relevant content
            texCollection.texNadine = Content.Load<Texture2D>("nadine_3col");
            texCollection.texBullet = Content.Load<Texture2D>("bullets");
            texCollection.testMap = Content.Load<Texture2D>("test_map");
            texCollection.factoryMap = Content.Load<Texture2D>("factory_map");
            texCollection.spaceMap = Content.Load<Texture2D>("space_map");
            texCollection.texMouse = Content.Load<Texture2D>("bigmouse");
            texCollection.texBaddog = Content.Load<Texture2D>("baddog");
            texCollection.texBirdie = Content.Load<Texture2D>("birdie_3col");
            texCollection.arcadeFont = Content.Load<Texture2D>("arcadefont");

            EnemyDict.build();

            currentMode = new TitleScreen(this);
        }
Exemplo n.º 3
0
 public void GameOver()
 {
     currentMode = new TitleScreen(this, "GAME OVER", texCollection.arcadeFont, new Vector2((800 / 2) - (9 * 8), 200));
 }
Exemplo n.º 4
0
 public void YouWin()
 {
     currentMode = new TitleScreen(this, "CONGRATULATION", texCollection.arcadeFont, new Vector2((800 / 2) - (14 * 8), 200));
 }