mirror of
https://git.minetest.land/VoxeLibre/VoxeLibre.git
synced 2024-11-26 04:21:07 +01:00
Fix slime spawn crash (#3977)
Declare global variables before using them! Fixes #3975 Reviewed-on: https://git.minetest.land/MineClone2/MineClone2/pulls/3977 Reviewed-by: the-real-herowl <the-real-herowl@noreply.git.minetest.land> Co-authored-by: codiac <codiac@inbox.lv> Co-committed-by: codiac <codiac@inbox.lv>
This commit is contained in:
parent
f941817c39
commit
4fcd1ae541
1 changed files with 2 additions and 1 deletions
|
@ -161,6 +161,8 @@ local spawn_children_on_die = function(child_mob, spawn_distance, eject_speed)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local swamp_light_max = 7
|
||||||
|
|
||||||
local function slime_spawn_check(pos, environmental_light, artificial_light, sky_light)
|
local function slime_spawn_check(pos, environmental_light, artificial_light, sky_light)
|
||||||
local maxlight = swamp_light_max
|
local maxlight = swamp_light_max
|
||||||
|
|
||||||
|
@ -308,7 +310,6 @@ local cave_min = mcl_vars.mg_overworld_min
|
||||||
local cave_max = water_level - 23
|
local cave_max = water_level - 23
|
||||||
|
|
||||||
local swampy_biomes = {"Swampland", "MangroveSwamp"}
|
local swampy_biomes = {"Swampland", "MangroveSwamp"}
|
||||||
local swamp_light_max = 7
|
|
||||||
local swamp_min = water_level
|
local swamp_min = water_level
|
||||||
local swamp_max = water_level + 27
|
local swamp_max = water_level + 27
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue