Update deprecated settings API syntax
This commit is contained in:
parent
a73fa20028
commit
63b186e2af
@ -99,7 +99,7 @@ mooshroom_def.on_rightclick = function(self, clicker)
|
||||
local cow = minetest.add_entity(pos, "mobs_mc:cow")
|
||||
cow:setyaw(oldyaw)
|
||||
|
||||
if not minetest.setting_getbool("creative_mode") then
|
||||
if not minetest.settings:get_bool("creative_mode") then
|
||||
item:add_wear(mobs_mc.misc.shears_wear)
|
||||
clicker:get_inventory():set_stack("main", clicker:get_wield_index(), item)
|
||||
end
|
||||
@ -145,6 +145,6 @@ mobs:alias_mob("mobs_animal:cow", "mobs_mc:cow")
|
||||
mobs:register_egg("mobs_mc:cow", S("Cow"), "mobs_mc_spawn_icon_cow.png", 0)
|
||||
mobs:register_egg("mobs_mc:mooshroom", S("Mooshroom"), "mobs_mc_spawn_icon_mooshroom.png", 0)
|
||||
|
||||
if minetest.setting_get("log_mods") then
|
||||
if minetest.settings:get_bool("log_mods") then
|
||||
minetest.log("action", "MC Cow loaded")
|
||||
end
|
||||
|
5
init.lua
5
init.lua
@ -113,5 +113,6 @@ COLISIONBOX in minetest press f5 to see where you are looking at then put these
|
||||
--
|
||||
--
|
||||
|
||||
|
||||
print ("[MOD] Mobs Redo 'MC' loaded")
|
||||
if minetest.settings:get_bool("log_mods") then
|
||||
minetest.log("action", "[MOD] Mobs Redo 'MC' loaded")
|
||||
end
|
||||
|
5
pig.lua
5
pig.lua
@ -177,9 +177,6 @@ mobs:alias_mob("mobs:pig", "mobs_mc:pig")
|
||||
mobs:register_egg("mobs_mc:pig", S("Pig"), "mobs_mc_spawn_icon_pig.png", 0)
|
||||
|
||||
|
||||
if minetest.settings:get("log_mods") then
|
||||
|
||||
|
||||
|
||||
if minetest.settings:get_bool("log_mods") then
|
||||
minetest.log("action", "MC Pig loaded")
|
||||
end
|
||||
|
@ -169,6 +169,6 @@ mobs:register_egg("mobs_mc:killer_bunny", S("Killer Bunny"), "mobs_mc_spawn_icon
|
||||
-- compatibility
|
||||
mobs:alias_mob("mobs:bunny", "mobs_mc:rabbit")
|
||||
|
||||
if minetest.setting_get("log_mods") then
|
||||
if minetest.settings:get_bool("log_mods") then
|
||||
minetest.log("action", "MC Bunny loaded")
|
||||
end
|
||||
|
@ -49,7 +49,7 @@ mobs:register_egg("mobs_mc:silverfish", S("Silverfish"), "mobs_mc_spawn_icon_sil
|
||||
-- Monster egg blocks (Minetest Game)
|
||||
if minetest.get_modpath("default") and mobs_mc.create_monster_egg_nodes then
|
||||
local spawn_silverfish = function(pos, oldnode, oldmetadata, digger)
|
||||
if not minetest.setting_getbool("creative_mode") then
|
||||
if not minetest.settings:get_bool("creative_mode") then
|
||||
minetest.add_entity(pos, "mobs_mc:silverfish")
|
||||
end
|
||||
end
|
||||
|
@ -60,7 +60,7 @@ mobs:register_mob("mobs_mc:squid", {
|
||||
|
||||
-- Spawn near the water surface
|
||||
|
||||
local water = tonumber(minetest.setting_get("water_level")) or 0
|
||||
local water = tonumber(minetest.settings:get("water_level")) or 0
|
||||
--name, nodes, neighbours, minlight, maxlight, interval, chance, active_object_count, min_height, max_height
|
||||
mobs:spawn_specific("mobs_mc:squid", mobs_mc.spawn.water, {mobs_mc.items.water_source}, 0, minetest.LIGHT_MAX+1, 30, 5500, 3, water-16, water)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user