Esempio n. 1
0
        public Level()
        {
            CollisionSolver.Level = this;
            Block.Graphic = Controller.Content.Load<Texture2D>("tilemap");
            Block.BorderGraphic = Controller.Content.Load<Texture2D>("level/borders_bunker");
            this.Collidable = true;

            this.InitializeBackground();
            this.Architect = new Architect();
            this.Builder = new Builder();
            this.Furnisher = new Furnisher();

            RoomType[,] plan = this.Architect.GenerateLevel();
            this.Dungeon = this.Builder.BuildLevel(plan);

            this.Furnisher.FurnishRooms(this.Dungeon.Rooms);

            this.AddChild(this.Dungeon);
        }
Esempio n. 2
0
        public Level()
        {
            CollisionSolver.Level = this;
            Block.Graphic         = Controller.Content.Load <Texture2D>("tilemap");
            Block.BorderGraphic   = Controller.Content.Load <Texture2D>("level/borders_bunker");
            this.Collidable       = true;

            this.InitializeBackground();
            this.Architect = new Architect();
            this.Builder   = new Builder();
            this.Furnisher = new Furnisher();

            RoomType[,] plan = this.Architect.GenerateLevel();
            this.Dungeon     = this.Builder.BuildLevel(plan);

            this.Furnisher.FurnishRooms(this.Dungeon.Rooms);

            this.AddChild(this.Dungeon);
        }