Merge branch 'treeco/improve-mapgen-ux' into 'master'

Improve water.rs usability

See merge request veloren/veloren!3355
This commit is contained in:
Marcel 2022-05-06 12:51:59 +00:00
commit e5a840534b
2 changed files with 7 additions and 2 deletions

View File

@ -47,8 +47,9 @@ fn main() {
WorldOpts {
seed_elements: false,
world_file: sim::FileOpts::LoadAsset(veloren_world::sim::DEFAULT_WORLD_MAP.into()),
/* world_file: sim::FileOpts::Load(_map_file),
* world_file: sim::FileOpts::Save(sim::SizeOpts::default()), */
// world_file: sim::FileOpts::Load(_map_file),
// world_file: sim::FileOpts::Save(sim::SizeOpts::default()),
// world_file: sim::FileOpts::Save(sim::SizeOpts::new(12, 12, 4.0)),
calendar: None,
},
&threadpool,

View File

@ -143,6 +143,10 @@ pub struct SizeOpts {
scale: f64,
}
impl SizeOpts {
pub fn new(x_lg: u32, y_lg: u32, scale: f64) -> Self { Self { x_lg, y_lg, scale } }
}
impl Default for SizeOpts {
fn default() -> Self {
Self {