smaller example1

This commit is contained in:
klangner 2020-10-19 21:35:24 +02:00
parent 3334184ad8
commit 89e9bf072e

View File

@ -3,6 +3,7 @@ use mapgen::{
filter::{ filter::{
NoiseGenerator, NoiseGenerator,
CellularAutomata, CellularAutomata,
CullUnreachable,
AreaStartingPosition, AreaStartingPosition,
XStart, XStart,
YStart, YStart,
@ -11,10 +12,11 @@ use mapgen::{
fn main() { fn main() {
let map = MapBuilder::new(80, 50) let map = MapBuilder::new(20, 20)
.with(NoiseGenerator::uniform()) .with(NoiseGenerator::uniform())
.with(CellularAutomata::new()) .with(CellularAutomata::new())
.with(AreaStartingPosition::new(XStart::CENTER, YStart::CENTER)) .with(AreaStartingPosition::new(XStart::CENTER, YStart::CENTER))
.with(CullUnreachable::new())
.build(); .build();
println!("{:}", &map); println!("{:}", &map);