mirror of
https://codeberg.org/tenplus1/mobs_redo.git
synced 2025-01-23 16:00:16 +01:00
make sure def.gain has a value
This commit is contained in:
parent
faf511ff8c
commit
e59fd53ee9
3
api.lua
3
api.lua
@ -18,7 +18,7 @@ end
|
|||||||
|
|
||||||
mobs = {
|
mobs = {
|
||||||
mod = "redo",
|
mod = "redo",
|
||||||
version = "20241010",
|
version = "20241011",
|
||||||
spawning_mobs = {},
|
spawning_mobs = {},
|
||||||
translate = S,
|
translate = S,
|
||||||
invis = minetest.global_exists("invisibility") and invisibility or {},
|
invis = minetest.global_exists("invisibility") and invisibility or {},
|
||||||
@ -4774,6 +4774,7 @@ if settings:get_bool("mobs_can_hear") ~= false then
|
|||||||
|
|
||||||
--print("==", def.sound)
|
--print("==", def.sound)
|
||||||
|
|
||||||
|
def.gain = def.gain or 1.0
|
||||||
def.max_hear_distance = param.max_hear_distance or 32
|
def.max_hear_distance = param.max_hear_distance or 32
|
||||||
|
|
||||||
-- find mobs within sounds hearing range
|
-- find mobs within sounds hearing range
|
||||||
|
Loading…
Reference in New Issue
Block a user