15913
|
1 |
use super::wavefront_collapse::WavefrontCollapse;
|
|
2 |
use super::tile_image::TileImage;
|
|
3 |
use crate::{LandGenerationParameters, LandGenerator};
|
|
4 |
|
|
5 |
pub struct WavefrontCollapseLandGenerator {
|
|
6 |
wfc: WavefrontCollapse,
|
|
7 |
tiles: Vec<TileImage>,
|
|
8 |
}
|
|
9 |
|
|
10 |
impl WavefrontCollapseLandGenerator {
|
|
11 |
pub fn new() -> Self {
|
|
12 |
Self {
|
|
13 |
wfc: WavefrontCollapse::default(),
|
|
14 |
tiles: Vec::new()
|
|
15 |
}
|
|
16 |
}
|
|
17 |
|
|
18 |
pub fn load_template() {
|
|
19 |
|
|
20 |
}
|
|
21 |
}
|
|
22 |
|
|
23 |
impl LandGenerator for WavefrontCollapseLandGenerator {
|
|
24 |
fn generate_land<T: Copy + PartialEq + Default, I: Iterator<Item = u32>>(
|
|
25 |
&self,
|
|
26 |
parameters: &LandGenerationParameters<T>,
|
|
27 |
random_numbers: &mut I,
|
|
28 |
) -> land2d::Land2D<T> {
|
|
29 |
todo!()
|
|
30 |
}
|
|
31 |
}
|