ellerjs
v0.0.2
Published
JavaScript implementation of Eller's maze generation algorithm.
Downloads
2
Readme
ellerjs
A JavaScript implementation of Eller's maze generation algoritm. this algorithm creates mazes that have a path between any two cells.
Rendered example
Installation
npm i ellerjs
Usage
const eller = require('ellerjs');
const maze = eller(15, 15);
Maze is two-dimensional array representing rows and cells. Cell structure:
interface Cell {
top: boolean; // true if cell has a wall in this direction, false if not
bottom: boolean;
left: boolean;
right: boolean;
}