add no_spawn to api
This commit is contained in:
parent
80a6f79436
commit
4564a686be
15
api.lua
15
api.lua
@ -219,12 +219,25 @@ function water_life.handle_drops(self)
|
||||
end
|
||||
end
|
||||
|
||||
function water_life.no_spawn_of(mobname)
|
||||
if not mobname then
|
||||
return
|
||||
end
|
||||
table.insert(water_life.no_spawn_table, mobname)
|
||||
end
|
||||
|
||||
function water_life.register_shark_food(name)
|
||||
if not name then
|
||||
return
|
||||
end
|
||||
table.insert(water_life.shark_food, name)
|
||||
end
|
||||
|
||||
function water_life.register_gull_bait(name)
|
||||
if name then water_life.gull_bait[name] = 1 end
|
||||
if not name then
|
||||
return
|
||||
end
|
||||
water_life.gull_bait[name] = 1
|
||||
end
|
||||
|
||||
function water_life.feed_shark(self)
|
||||
|
1
init.lua
1
init.lua
@ -10,6 +10,7 @@ water_life.version = "220710"
|
||||
water_life.shark_food = {}
|
||||
water_life.repellant = {}
|
||||
water_life.gull_bait = {}
|
||||
water_life.no_spawn_table = {}
|
||||
water_life.catchNet = "water_life:placeholder"
|
||||
water_life.petz = minetest.get_modpath("petz")
|
||||
water_life.mobsredo = minetest.get_modpath("mobs")
|
||||
|
Loading…
x
Reference in New Issue
Block a user