Snow for ice

This commit is contained in:
Joshua Barretto 2021-12-13 00:13:33 +00:00
parent 065da20812
commit 3b4fa6b328
3 changed files with 27 additions and 15 deletions

View File

@ -80,7 +80,7 @@ impl BlocksOfInterest {
},
BlockKind::Snow if rng.gen_range(0..16) == 0 => snow.push(pos),
BlockKind::Lava if rng.gen_range(0..5) == 0 => fires.push(pos + Vec3::unit_z()),
BlockKind::Snow if rng.gen_range(0..16) == 0 => snow.push(pos),
BlockKind::Snow | BlockKind::Ice if rng.gen_range(0..16) == 0 => snow.push(pos),
_ => match block.get_sprite() {
Some(SpriteKind::Ember) => {
fires.push(pos);

View File

@ -1137,10 +1137,11 @@ impl<'a> Sampler<'a> for ColumnGen<'a> {
.mul(32.0)
.clamped(0.0, 1.0);
((1.0 - Lerp::lerp(marble, Lerp::lerp(marble_mid, marble_small, 0.25), 0.5)) * 5.0
(((1.0 - Lerp::lerp(marble, Lerp::lerp(marble_mid, marble_small, 0.25), 0.5)) * 5.0
- 1.5)
.max(0.0)
+ cliff * cliff_ctrl
+ cliff * cliff_ctrl)
.min((water_level - alt).max(0.0))
} else {
0.0
};

View File

@ -145,34 +145,45 @@ pub fn spawn_manifest() -> Vec<(&'static str, DensityFn)> {
close(c.temp, CONFIG.snow_temp, 0.15) * BASE_DENSITY * 0.5
}),
// Core animals events
("world.wildlife.spawn.calendar.christmas.tundra.core", |c, _col| {
close(c.temp, CONFIG.snow_temp, 0.15) * BASE_DENSITY * 0.5
}),
(
"world.wildlife.spawn.calendar.christmas.tundra.core",
|c, _col| close(c.temp, CONFIG.snow_temp, 0.15) * BASE_DENSITY * 0.5,
),
// Snowy animals
("world.wildlife.spawn.tundra.snow", |c, col| {
close(c.temp, CONFIG.snow_temp, 0.3) * BASE_DENSITY * col.snow_cover as i32 as f32 * 1.0
}),
// Snowy animals event
("world.wildlife.spawn.calendar.christmas.tundra.snow", |c, col| {
close(c.temp, CONFIG.snow_temp, 0.3) * BASE_DENSITY * col.snow_cover as i32 as f32 * 1.0
}),
(
"world.wildlife.spawn.calendar.christmas.tundra.snow",
|c, col| {
close(c.temp, CONFIG.snow_temp, 0.3)
* BASE_DENSITY
* col.snow_cover as i32 as f32
* 1.0
},
),
// Forest animals
("world.wildlife.spawn.tundra.forest", |c, col| {
close(c.temp, CONFIG.snow_temp, 0.3) * col.tree_density * BASE_DENSITY * 1.4
}),
// Forest animals event
("world.wildlife.spawn.calendar.christmas.tundra.forest", |c, col| {
close(c.temp, CONFIG.snow_temp, 0.3) * col.tree_density * BASE_DENSITY * 1.4
}),
(
"world.wildlife.spawn.calendar.christmas.tundra.forest",
|c, col| close(c.temp, CONFIG.snow_temp, 0.3) * col.tree_density * BASE_DENSITY * 1.4,
),
// **Taiga**
// Forest core animals
("world.wildlife.spawn.taiga.core_forest", |c, col| {
close(c.temp, CONFIG.snow_temp + 0.2, 0.2) * col.tree_density * BASE_DENSITY * 0.4
}),
// Forest core animals event
("world.wildlife.spawn.calendar.christmas.taiga.core_forest", |c, col| {
close(c.temp, CONFIG.snow_temp + 0.2, 0.2) * col.tree_density * BASE_DENSITY * 0.4
}),
(
"world.wildlife.spawn.calendar.christmas.taiga.core_forest",
|c, col| {
close(c.temp, CONFIG.snow_temp + 0.2, 0.2) * col.tree_density * BASE_DENSITY * 0.4
},
),
// Core animals
("world.wildlife.spawn.taiga.core", |c, _col| {
close(c.temp, CONFIG.snow_temp + 0.2, 0.2) * BASE_DENSITY * 1.0