Create a random dungeon or labyrinth in JavaScript (browser or Node JS)