mirror of
https://codeberg.org/tenplus1/mobs_redo.git
synced 2025-01-27 09:30:19 +01:00
mobs:add_mob() returns object spawned or false if not
This commit is contained in:
parent
e63b1b478e
commit
dfdd55848d
4
api.lua
4
api.lua
@ -6,7 +6,7 @@ local use_cmi = minetest.global_exists("cmi")
|
|||||||
|
|
||||||
mobs = {
|
mobs = {
|
||||||
mod = "redo",
|
mod = "redo",
|
||||||
version = "20200622",
|
version = "20200625",
|
||||||
intllib = S,
|
intllib = S,
|
||||||
invis = minetest.global_exists("invisibility") and invisibility or {}
|
invis = minetest.global_exists("invisibility") and invisibility or {}
|
||||||
}
|
}
|
||||||
@ -3707,7 +3707,7 @@ function mobs:add_mob(pos, def)
|
|||||||
ent:update_tag()
|
ent:update_tag()
|
||||||
end
|
end
|
||||||
|
|
||||||
return true
|
return ent
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
2
api.txt
2
api.txt
@ -339,6 +339,8 @@ Adding Mobs in World
|
|||||||
ignore_count = true -- ignores mob count per map area
|
ignore_count = true -- ignores mob count per map area
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Returns false if mob could not be added, returns mob object if spawned ok.
|
||||||
|
|
||||||
|
|
||||||
Spawning Mobs in World
|
Spawning Mobs in World
|
||||||
----------------------
|
----------------------
|
||||||
|
Loading…
Reference in New Issue
Block a user