This commit is contained in:
parent
ca71ffcb6f
commit
74beb9738a
7
.github/workflows/rust.yml
vendored
7
.github/workflows/rust.yml
vendored
@ -127,10 +127,11 @@ jobs:
|
|||||||
- uses: Swatinem/rust-cache@v2
|
- uses: Swatinem/rust-cache@v2
|
||||||
- name: Build Release
|
- name: Build Release
|
||||||
shell: bash
|
shell: bash
|
||||||
|
# Removed this because this it seems not worth the hussle
|
||||||
|
# if [[ "${{ runner.arch }}" == "X64" ]]; then
|
||||||
|
# export RUSTFLAGS="$RUSTFLAGS -C target-cpu=x86-64-v3"
|
||||||
|
# fi
|
||||||
run: |
|
run: |
|
||||||
if [[ "${{ runner.arch }}" == "X64" ]]; then
|
|
||||||
export RUSTFLAGS="$RUSTFLAGS -C target-cpu=x86-64-v3"
|
|
||||||
fi
|
|
||||||
cargo build --verbose --release
|
cargo build --verbose --release
|
||||||
- name: Prepare artifacts
|
- name: Prepare artifacts
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|||||||
@ -152,21 +152,22 @@ impl SlimeEntity {
|
|||||||
// For now, we assume natural spawning as that's what we are implementing.
|
// For now, we assume natural spawning as that's what we are implementing.
|
||||||
|
|
||||||
// Swamp/Surface Spawning
|
// Swamp/Surface Spawning
|
||||||
let biome = world.get_biome(pos);
|
// TOOD: fix
|
||||||
if biome.has_tag(&pumpkin_data::tag::WorldgenBiome::MINECRAFT_ALLOWS_SURFACE_SLIME_SPAWNS)
|
// let biome = world.get_biome(pos);
|
||||||
&& pos.0.y > 50
|
// if biome.has_tag(&pumpkin_data::tag::WorldgenBiome::MINECRAFT_ALLOWS_SURFACE_SLIME_SPAWNS)
|
||||||
&& pos.0.y < 70
|
// && pos.0.y > 50
|
||||||
{
|
// && pos.0.y < 70
|
||||||
let time = world.level_time.blocking_lock().time_of_day;
|
// {
|
||||||
let moon_phase = (time / 24000) % 8;
|
// let time = world.level_time.lock().await.time_of_day;
|
||||||
let surface_slime_spawn_chance = Self::get_spawn_chance(moon_phase);
|
// let moon_phase = (time / 24000) % 8;
|
||||||
let mut rng = rand::rng();
|
// let surface_slime_spawn_chance = Self::get_spawn_chance(moon_phase);
|
||||||
if rng.random::<f32>() < surface_slime_spawn_chance
|
// let mut rng = rand::rng();
|
||||||
&& world.get_max_local_raw_brightness(pos) <= rng.random_range(0..8)
|
// if rng.random::<f32>() < surface_slime_spawn_chance
|
||||||
{
|
// && world.get_max_local_raw_brightness(pos) <= rng.random_range(0..8)
|
||||||
return true;
|
// {
|
||||||
}
|
// return true;
|
||||||
}
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
// Slime Chunk Spawning
|
// Slime Chunk Spawning
|
||||||
let chunk_pos = pos.chunk_position();
|
let chunk_pos = pos.chunk_position();
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user