Example #1
0
 private void InitializeLevels()
 {
     if (start.StartGame == false)
     {
         start.Draw(_spriteBatch);
     }
     else if (start.StartGame) // || end.StartGame
     {
         level1.Draw(_spriteBatch);
         hero.Draw(_spriteBatch);        // Draw if startGame is true
     }
     else if (level1.HasCrystal && hero.Position.X > level1.PosDoor.X)
     {
         level2.Draw(_spriteBatch);
         hero.Draw(_spriteBatch);        // Draw if startGame is true
     }
     else if (level2.EndLevel2 || EnemyCol)
     {
         end.Draw(_spriteBatch);
     }
 }