maze_builder library

Classes

Cell

Functions

addSetExits(List<Cell> row, List<Cell> nextRow, Function random) → dynamic
internal function randomly add an exit to each set
compact(List array) List
internal function make a list based on a predicate
difference(List c, List d) List
internal function difference between two lists
generate({int width = 8, int height = 0, dynamic closed = true, dynamic seed = 1}) List<List<Cell>>
Generate a maze (List of List of Cell objects)
groupBy<S, T>(Iterable<S> values, T key(S)) Map<T, List<S>>
internal function group iterables by predicate
imul2(int a, int b) int
internal function imul2 implementation in Dart
initial(List array) List
last(List array) → dynamic
internal function get the last element of a list
mergeRandomSetsIn(List<Cell> row, Function random, {dynamic probability = 0.5}) List<Cell>
internal function merge randomized sets into a new list
mergeSetWith(List<Cell> row, double oldSet, double newSet) List<Cell>
internal function merge a list with another
mulberry32(int seed) Function
internal function randomization engine
oldgroupBy(List<Cell> list, String key) Map<int, List>
{ key: T[] }
populateMissingSets(List<Cell> row, Function random) List<Cell>
internal function add missing set to list
range(double n, {int end = 0}) Iterable
internal function make a list based on predicate
sampleSize(List? array, double? n, Function random) List
internal function return a list with random elements
uniq(List array) List
internal function return a duplicate free list