Exemplo n.º 1
0
 public GameScreen(LevelFormat level, bool test = true)
 {
     loader = new LevelLoader(level);
     GameObjects = new List<object>();
     player = new Player();
     objectives = new List<Objective>();
     drawAbleItems = new List<IDrawAble>();
     levelID = -1;
     testing = test;
 }
Exemplo n.º 2
0
        /// <summary>
        /// ctor
        /// </summary>
        /// <param name="level">The level number that should be loaded</param>
        public GameScreen(int level)
        {
            levelID = level;
            GameObjects = new List<object>();
            player = new Player();
            objectives = new List<Objective>();
            drawAbleItems = new List<IDrawAble>();

            loader = new LevelLoader(levelID);
            testing = false;
        }
Exemplo n.º 3
0
        public override void LoadContent(ContentManager content)
        {
            foreach (BaseLayer bl in layers)
            {
                bl.LoadContent(content);
            }

            LevelLoader loader = new LevelLoader(levelID);
            loader.Load();

            if (loader.LevelLoaded)
            {
                foreach (BaseLayer bl in layers)
                {
                    bl.LoadLevel(loader.level);
                }
            }

            base.LoadContent(content);
        }