Anonymous user
Maze generation: Difference between revisions
m
→version 1: changed some whitespace here and there. -- ~~~~
(→version 1: changed order of subroutines, added whitespace and comments. -- ~~~~) |
m (→version 1: changed some whitespace here and there. -- ~~~~) |
||
Line 3,718:
call buildRow '┌'copies('─┬',cols-1)'─┐' /*build the top edge of maze.*/
/*(below) build the maze's grid.*/
do r=1 for rows; _=; __=; hp= '|';
do c=1 for cols; _= _||hp'1'; __=__||hj'─'; hj='┼'; hp='│'
end /*c*/
Line 3,745:
_=changestr('─',_,"───") /*──────────── the aspect ratio. */
say translate(_,'│',"|\10") /*make it presentable for screen.*/
end /*r*/
exit /*stick a fork in it, we're done.*/
/*──────────────────────────────────@ subroutine────────────────────────*/
|