macro_rules! sqrid_create {
($xmax: expr, $ymax: expr, $diags: expr) => { ... };
($postype: ty, $diags: expr) => { ... };
}Expand description
Creates the a Sqrid type from the provided parameters: width,
height and diagonals
Example usage:
type Sqrid = sqrid::sqrid_create!(4, 4, false);
type Pos = sqrid::pos_create!(Sqrid);
for (pos, dir) in Sqrid::bf_iter(sqrid::pos_dir_add_ok, &Pos::CENTER)
.flatten() {
println!("breadth-first pos {} from {}", pos, dir);
}