Exemplo n.º 1
0
        public static MazeBuilder Generate(int width, int height, MazeConfig config = null)
        {
            var mazeBuilder = new MazeBuilder(width, height, config ?? new MazeConfig());

            mazeBuilder.Build();
            return(mazeBuilder);
        }
Exemplo n.º 2
0
        static void Main(string[] args)
        {
            Console.WriteLine("Hello World!");

            MazeBuilder maze = new MazeBuilder(10, 10, 3);

            Console.WriteLine("Maze Length:" + maze.Maze.Length);
            Console.ReadKey();
        }
Exemplo n.º 3
0
        static void Main(string[] args)
        {
            var maze = new MazeBuilder().Build(seed: 50);

            new MazeDrawer().Draw(maze);


            Console.WriteLine("Hello World!");
        }
Exemplo n.º 4
0
 public Maze CreateMaze(MazeBuilder mb)
 {
     Console.WriteLine("MazeGame->CreateMaze(MazeBuilder)");
     mb.BuildMaze();
     mb.BuildRoom(1);
     mb.BuildRoom(2);
     mb.BuildDoor(1, 2);
     mb.BuildRoom(3);
     mb.BuildDoor(2, 3);
     return(mb.GetMaze());
 }