diff --git a/mobs/elephant.lua b/mobs/elephant.lua index 0250c31..e692974 100644 --- a/mobs/elephant.lua +++ b/mobs/elephant.lua @@ -1,3 +1,11 @@ +local followf = {} + +-- detect common minetest famous mobs +if minetest.get_modpath("farming") then + table.insert(followf, "farming:wheat") + table.insert(followf, "farming:seed_cotton") +end + mobs:register_mob("dmobs:elephant", { type = "animal", passive = false, @@ -29,10 +37,10 @@ mobs:register_mob("dmobs:elephant", { replace_rate = 10, replace_what = {"default:grass_3", "default:grass_4", "default:grass_5", "ethereal:bamboo"}, replace_with = "air", - follow = {"farming:wheat"}, + follow = followf, view_range = 14, drops = { - {name = "mobs:meat_raw", chance = 1, min = 1, max = 1}, + {name = "mobs:meat_raw", chance = 2, min = 1, max = 3}, }, animation = { speed_normal = 5, diff --git a/mobs/fox.lua b/mobs/fox.lua index 78a505b..200cddd 100644 --- a/mobs/fox.lua +++ b/mobs/fox.lua @@ -1,3 +1,11 @@ +local followf = {} + +table.insert(followf, "mobs:meat_raw") + +if minetest.get_modpath("mobs_animal") then + table.insert(followf, "mobs_animal:muttom_raw") +end + -- Fox mobs:register_mob("dmobs:fox", { type = "monster", @@ -39,7 +47,7 @@ mobs:register_mob("dmobs:fox", { replace_rate = 10, replace_what = {"farming:wheat_5", "default:fence_wood", "default:grass_5", "default:dirt_with_grass"}, replace_with = "air", - follow = {"mobs:meat_raw"}, + follow = followf, view_range = 14, animation = { speed_normal = 6, diff --git a/mobs/gnorm.lua b/mobs/gnorm.lua index f6d5f26..fcfe9fd 100644 --- a/mobs/gnorm.lua +++ b/mobs/gnorm.lua @@ -28,6 +28,10 @@ mobs:register_mob("dmobs:gnorm", { fall_damage = 1, fall_speed = -6, fear_height = 4, + drops = { + {name = "default:wood", chance = 1, min = 1, max = 1}, + {name = "default:apple", chance = 1, min = 1, max = 1}, + }, replace_rate = 10, replace_what = {"default:apple", "default:stone", "default:stone_with_coal", "default:fence_wood"}, replace_with = "air", diff --git a/mobs/golem.lua b/mobs/golem.lua index 9d5c3ff..2275ed8 100644 --- a/mobs/golem.lua +++ b/mobs/golem.lua @@ -22,6 +22,7 @@ mobs:register_mob("dmobs:golem", { run_velocity = 2.5, jump = true, drops = { + {name = "default:stone", chance = 1, min = 1, max = 5}, {name = "dmobs:golemstone", chance = 30, min = 1, max = 1}, }, water_damage = 0, diff --git a/mobs/golem_friendly.lua b/mobs/golem_friendly.lua index ca94792..6fd494e 100644 --- a/mobs/golem_friendly.lua +++ b/mobs/golem_friendly.lua @@ -15,6 +15,9 @@ mobs:register_mob("dmobs:golem_friendly", { {"dmobs_golem.png"}, }, follow = "default:cobble", + drops = { + {name = "default:cobble", chance = 1, min = 1, max = 3}, + }, blood_texture = "default_stone.png", visual_size = {x=1, y=1}, makes_footstep_sound = true, diff --git a/mobs/hedgehog.lua b/mobs/hedgehog.lua index c9dc87d..84193ea 100644 --- a/mobs/hedgehog.lua +++ b/mobs/hedgehog.lua @@ -1,3 +1,12 @@ + +local followf = {} + +-- detect common minetest famous mobs +if minetest.get_modpath("farming") then + table.insert(followf, "farming:wheat") + table.insert(followf, "farming:seed_cotton") +end + mobs:register_mob("dmobs:hedgehog", { type = "animal", passive = true, @@ -25,7 +34,10 @@ mobs:register_mob("dmobs:hedgehog", { fall_speed = -6, fear_height = 4, view_range = 14, - follow = {"farming:bread"}, + follow = followf, + drops = { + {name = "mobs:meat_raw", chance = 2, min = 1, max = 3}, + }, animation = { speed_normal = 5, speed_run = 10, diff --git a/mobs/nyan.lua b/mobs/nyan.lua index 92b5aef..f29a7b9 100644 --- a/mobs/nyan.lua +++ b/mobs/nyan.lua @@ -12,7 +12,7 @@ mobs:register_mob("dmobs:nyan", { textures = { {"dmobs_nyancat.png"}, }, - jump = true, + jump = true, fly = true, fall_speed = 0, stepheight = 1.5, @@ -25,7 +25,7 @@ mobs:register_mob("dmobs:nyan", { run_chance = 20, jump = true, drops = { - {name = "default:nyan_cat", chance = 2, min = 1, max = 1}, + {name = "mobs:meat_raw", chance = 2, min = 1, max = 1}, }, water_damage = 0, lava_damage = 2, diff --git a/mobs/panda.lua b/mobs/panda.lua index 07bc8b5..7d4bf01 100644 --- a/mobs/panda.lua +++ b/mobs/panda.lua @@ -35,7 +35,10 @@ mobs:register_mob("dmobs:panda", { replace_rate = 10, replace_what = {"default:grass_3", "default:grass_4", "default:grass_5", "ethereal:bamboo"}, replace_with = "air", - follow = {"default:papyrus"}, + follow = { + {"default:papyrus"}, + {"default:apple"} + } view_range = 14, animation = { speed_normal = 6, diff --git a/mobs/pig.lua b/mobs/pig.lua index c851ee7..4e2596a 100644 --- a/mobs/pig.lua +++ b/mobs/pig.lua @@ -43,7 +43,11 @@ mobs:register_mob("dmobs:pig", { lava_damage = 2, fire_damage = 2, light_damage = 0, - follow = {"default:apple"}, + follow = { + {"default:apple"}, + {"default:leaves"}, + {"mobs:meat_raw"}, + } view_range = 14, animation = { speed_normal = 10, diff --git a/mobs/pig_evil.lua b/mobs/pig_evil.lua index 8e12da2..fda16d1 100644 --- a/mobs/pig_evil.lua +++ b/mobs/pig_evil.lua @@ -42,7 +42,10 @@ local pigdef = { lava_damage = 2, fire_damage = 2, light_damage = 0, - follow = {"default:apple"}, + follow = { + {"default:apple"}, + {"default:leaves"}, + } view_range = 14, animation = { speed_normal = 10, diff --git a/mobs/rat.lua b/mobs/rat.lua index b603784..306f269 100644 --- a/mobs/rat.lua +++ b/mobs/rat.lua @@ -1,5 +1,15 @@ --Rat +local followf = {} + +-- detect common minetest famous mobs +if minetest.get_modpath("farming") then + table.insert(followf, "farming:wheat") +end +if minetest.get_modpath("mobs_animal") then + table.insert(followf, "mobs_animal:cheese") +end + mobs:register_mob("dmobs:rat", { type = "monster", reach = 2, @@ -33,7 +43,7 @@ mobs:register_mob("dmobs:rat", { replace_rate = 10, replace_what = {"farming:wheat_5", "farming:wheat_4", "farming:wheat_2", "farming:wheat_3"}, replace_with = "air", - follow = {"mobs_animal:cheese"}, + follow = followf, view_range = 14, animation = { speed_normal = 10, diff --git a/mobs/tortoise.lua b/mobs/tortoise.lua index 89ad538..d56d22a 100644 --- a/mobs/tortoise.lua +++ b/mobs/tortoise.lua @@ -1,4 +1,15 @@ +local dropstor + +dropstor = {{name = "default:stick", chance = 1, min = 1, max = 1},} + +if minetest.get_modpath("farming") then + dropstor = { + {name = "default:stick", chance = 1, min = 1, max = 1}, + {name = "farming:string", chance = 2, min = 0, max = 1}, + } +end + mobs:register_mob("dmobs:tortoise", { type = "animal", passive = false, @@ -22,9 +33,7 @@ mobs:register_mob("dmobs:tortoise", { jump = false, jump_height = 0.5, floats = true, - drops = { - {name = "default:stick", chance = 1, min = 1, max = 1}, - }, + drops = dropstor, water_damage = 0, lava_damage = 2, fire_damage = 2, @@ -32,7 +41,9 @@ mobs:register_mob("dmobs:tortoise", { fall_damage = 1, fall_speed = -10, fear_height = 4, - follow = {"default:papyrus"}, + follow = { + {"default:papyrus"}, + {"default:leaves"} view_range = 14, animation = { speed_normal = 6,