box-maze
v0.0.1
Published
Box maze creator and solver.
Downloads
2
Readme
box-maze
Box maze creator and solver.
Usage
Command Line
$ npm install box-maze -g
$ box-maze create
Module
var BoxMaze = require('box-maze'); // Supports [UMD](https://github.com/umdjs/umd)
// All parameters are optional
var maze = new BoxMaze(50, 50, { x: 0, y: 0 }, { x: 20, y: 23 });
// Uses [backtracking algorithm](http://en.wikipedia.org/wiki/Backtracking) internally
// Create it!
maze.create();
// Solve it!
maze.solve();
console.log(maze.toString());