Mazing.cmd - WinNT Maze Generator and Solver
__________________________________________________________
A maze program written in native WinNT batch script that
includes several maze generation and solving algorithms as
well as a small plethora of options for console display,
stack size, stack orientation, node selection/direction
bias, entrance/exit points, color selection, real-time
shifting and rhythmic pulsing random colors, and wall/box
characters, each with an automatic randomizer, and all of
it easily accessible through an animated custom menu.
Mazes are limited to a maximum practical string length of
8186 characters. The maze dimensions will be automatically
increased/decreased if minimum/maximum size is exceeded.
Mazing operates using 100% WinNT batch script, but it will
use either BG.EXE or CursorPos.exe to place the cursor at
the upper-left if they are located in the system path. It
can also use BG.EXE to animate the screen in full color.
Command Line / Mazing.ini File
__________________________________________________________
In addition to the menu, other User Variables are passed
by using either the Mazing.ini file or on the command line
by using the following syntax:
Mazing.cmd ["variable=value"] [variable:value] [...]
Several options for minimum/maximum columns/rows, lists
of characters for random walls/crumbs/colors, keys used by
the menu, output logfile and anything else not included in
the menu are accessed by command line or the .ini file.
A list of available user variables may be found in the
Mazing.ini file that is auto-generated on first run.
https://github.com/TheRealCirothUngol/Mazing.cmd
2026/07/21: Added better opening/entry options to Wilson's Algorithm so now it's one of the best maze generators. Also made a handful of corrections and display enhancements throughout.
2026/07/11: Updated Mazing.cmd to v0.3. Added Prim's, Kruskal's, and Wilson's algorithms as well as updating the menu with new solver display settings and many cosmetic improvements(?) throughout. As it now employs all of the useful generators for perfect mazes as well as the only three appropriate solvers I've found... I think Mazing.cmd is done after all these years. Who sez perseverance don't pay off? If I ever update it'll be for ANSI color console integration, and that's a maybe sometime thing.
2026/06/24: Just corrected a small but long-standing error in both the 'Wall Follow' and 'Dead Filler' where the trail was written incorrectly back to the maze if walls (or crumbs) were used to fill visited spaces. If you snagged it on or before this date please re-download.
2026/06/26: A small cosmetic update to :path_finder, it now allows for variable-length 'worms' when passed an odd number as the first parameter. Second parameter is length of worms. Makes for a really nice looking effect , too bad its selection is currently all random and there's no way to select it directly. Use Pathfinder as the solver and it should happen about 50% of the time. You may select it through the menu.
Mazing.cmd is something I tinkered with for years and poured dozens (hundreds?) of hours into several versions before I switched from Win7 to Win10 and it all stopped working. Was going through some old projects recently and it turns out the problem was mostly a 'legacy console' issue with many of the oddball characters I was using. After sifting out the poison characters, beautifying and expanding the menu, and adding a myriad of new color options (and dumping a few dozen more hours into it), I've posted Mazing.cmd v0.2 to GitHub. It seems to work well on WinXP and up, I recommend placing it in a separate folder as it creates a few files.
Lots of new stuff got added and everything I could conceive of was realized and included. I also think every bug got squashed (yea, we'll see). It's been running non-stop (and error-free?) for a couple of days now so I feel pretty good about it. The new macros I added (colorShift and BGgrabKey) are both self-limiting and time-regulated to only execute at a given frequency so that consistent intervals could be used to schedule background\foreground color changes or check for user input while the script was running without bogging down in needlessly-wasted clock cycles. I need to neither check for a keypress nor check to see if 7 seconds have expired 30 times a second, 2 will do fine. Really improved the speed of my script. Could be potentially useful for anyone wanting to execute something during a closed loop but only need it to do so every X centiseconds.
Please give Mazing.cmd a try and let me know if it works for you, I've tested it on WinXP, Win7, Win10, and it even seems to work on Win11. You're highly encouraged to try using the BG.EXE utility that removes the flickering and provides color drawing. Once in the menu use the bottom option to select 'BG Color' and hit '1' to start the script. It should produce the file and restart, but it requires CertUtil (Administration Tools) for Base64 decoding, which was available on every system I tried newer than XP. However YMMV so if that gives you trouble just snag it from Carlos' GitHub:
https://github.com/carlos-montiers/consolesoft-mirror/releases
I also use OuterTech's GetDiz to view the mazes (using either 'Terminal' or 'GetDiz' fonts). I would link to their website, but it's down and probably out. Just search and snag it from the place you trust the most. ^_^