1
0
mirror of https://codeberg.org/tenplus1/mobs_monster.git synced 2025-07-21 17:40:30 +02:00

Compare commits

33 Commits

Author SHA1 Message Date
d4d8cc526a Merge remote-tracking branch 'upstream/master' 2023-11-22 23:55:26 +01:00
c632143fad Merge remote-tracking branch 'upstream/master' 2023-06-07 22:02:13 +02:00
00146154b5 Merge remote-tracking branch 'upstream/master' 2022-08-26 15:18:27 +02:00
b3e50d295c Merge remote-tracking branch 'upstream/master' 2022-01-22 20:06:05 +01:00
cab9cf25c6 Merge remote-tracking branch 'upstream/master' 2021-11-26 21:44:00 +01:00
f39fc78e4a Merge remote-tracking branch 'upstream/master' 2021-09-21 23:09:27 +02:00
70d92995bb Merge remote-tracking branch 'upstream/master' 2021-07-26 22:23:25 +02:00
69ca619580 Merge remote-tracking branch 'upstream/master' 2021-06-20 17:16:01 +02:00
7bd9080eda Merge remote-tracking branch 'upstream/master' 2021-04-08 13:29:19 +02:00
2baa1cc77d Merge remote-tracking branch 'upstream/master' 2021-03-12 12:30:34 +01:00
2129b4731f Merge remote-tracking branch 'upstream/master' 2021-02-07 13:11:50 +01:00
c8003524d6 Merge remote-tracking branch 'upstream/master' 2021-01-29 17:44:57 +01:00
4a3bf56409 Merge remote-tracking branch 'upstream/master' 2021-01-23 12:56:11 +01:00
5297dfbbdf Merge remote-tracking branch 'upstream/master' 2020-09-21 18:06:40 +02:00
1e72bfd920 Merge remote-tracking branch 'upstream/master' 2020-09-04 21:40:14 +02:00
057177203a Merge remote-tracking branch 'upstream/master' 2020-08-29 20:31:49 +02:00
6b69a3e23d Merge remote-tracking branch 'upstream/master' 2020-08-25 20:06:32 +02:00
7be2f3bd63 Merge remote-tracking branch 'upstream/master' 2020-08-19 21:24:25 +02:00
ca10e7e1f6 Merge remote-tracking branch 'upstream/master' 2020-07-17 22:40:01 +02:00
592c4aca50 Merge remote-tracking branch 'upstream/master' into nalc-1.2-dev 2020-06-20 15:39:41 +02:00
55d3d4b547 Merge remote-tracking branch 'upstream/master' into nalc-1.2-dev 2020-05-09 14:24:36 +02:00
5674b6328e Merge remote-tracking branch 'upstream/master' into nalc-1.2-dev 2020-02-29 18:08:15 +01:00
3ddd27e515 Merge branch 'master' of yunohost.local:mtcontrib/mobs_monster into nalc-1.2-dev 2019-12-22 13:58:23 +01:00
133766d0ab Merge branch 'master' into nalc-1.2 2019-05-10 00:58:32 +02:00
25a7636bb9 Merge commit 'a8df74e' into nalc 2018-12-31 16:21:06 +01:00
01a491af9c Ajout d'un alias pour compatibilité avec le mod fishing de Crabman 2018-12-15 21:23:22 +01:00
18565d6bdb Ajout de textures oubliés pour les items du dungeon master 2018-12-15 21:20:43 +01:00
d3b2074daf Renommage d'items 2018-12-15 21:18:58 +01:00
4e47e4f02c Ajout de drops d'items 2018-11-02 13:48:56 +01:00
b993f11b92 Ajoute le spawn du minotaur sur la roche du desert 2018-11-02 11:42:29 +01:00
2e99fafa82 Corrige le spawn du minotaur 2018-11-02 11:28:51 +01:00
204d00c52c Renommage des alias 2018-11-01 17:16:20 +01:00
abd7791e87 Ajout du minotaur 2018-11-01 16:30:03 +01:00
35 changed files with 4148 additions and 536 deletions

View File

@ -1,19 +1,17 @@
local S = core.get_translator("mobs_monster")
-- custom dirt monster type
-- Translation support
local S = minetest.get_translator("mobs_monster")
local dirt_types = {
{ nodes = {"ethereal:dry_dirt"},
skins = {"mobs_dirt_monster3.png"},
drops = {
{name = "ethereal:dry_dirt", chance = 1, min = 0, max = 2},
{name = "ethereal:charcoal_lump", chance = 2, min = 0, max = 1}
{name = "ethereal:dry_dirt", chance = 1, min = 0, max = 2}
}
}
}
-- Dirt Monster by PilzAdam
mobs:register_mob("mobs_monster:dirt_monster", {
@ -35,25 +33,32 @@ mobs:register_mob("mobs_monster:dirt_monster", {
},
blood_texture = "default_dirt.png",
makes_footstep_sound = true,
sounds = {random = "mobs_dirtmonster"},
sounds = {
random = "mobs_dirtmonster"
},
view_range = 15,
walk_velocity = 1,
run_velocity = 3,
jump = true,
drops = {
{name = "default:dirt", chance = 1, min = 0, max = 2},
{name = "default:clay_lump", chance = 2, min = 0, max = 1}
{name = "maptools:silver_coin", chance = 2, min = 1, max = 1,},
},
water_damage = 1,
lava_damage = 5,
light_damage = 3,
fear_height = 4,
animation = {
speed_normal = 15, speed_run = 15,
stand_start = 0, stand_end = 14,
walk_start = 15, walk_end = 38,
run_start = 40, run_end = 63,
punch_start = 40, punch_end = 63
speed_normal = 15,
speed_run = 15,
stand_start = 0,
stand_end = 14,
walk_start = 15,
walk_end = 38,
run_start = 40,
run_end = 63,
punch_start = 40,
punch_end = 63
},
-- check surrounding nodes and spawn a specific monster
@ -66,12 +71,14 @@ mobs:register_mob("mobs_monster:dirt_monster", {
tmp = dirt_types[n]
if core.find_node_near(pos, 1, tmp.nodes) then
if minetest.find_node_near(pos, 1, tmp.nodes) then
self.base_texture = tmp.skins
self.object:set_properties({textures = tmp.skins})
if tmp.drops then self.drops = tmp.drops end
if tmp.drops then
self.drops = tmp.drops
end
return true
end
@ -81,7 +88,6 @@ mobs:register_mob("mobs_monster:dirt_monster", {
end
})
-- where to spawn
if not mobs.custom_spawn_monster then
@ -97,10 +103,8 @@ if not mobs.custom_spawn_monster then
})
end
-- spawn egg
mobs:register_egg("mobs_monster:dirt_monster", S("Dirt Monster"), "default_dirt.png", 1)
-- compatibility with older mobs mod
mobs:alias_mob("mobs:dirt_monster", "mobs_monster:dirt_monster")
mobs:alias_mob("mobs:dirt_monster", "mobs_monster:dirt_monster") -- compatibility

View File

@ -1,7 +1,5 @@
local S = core.get_translator("mobs_monster")
-- custom dungeon master types
-- Translation support
local S = minetest.get_translator("mobs_monster")
local master_types = {
@ -13,6 +11,7 @@ local master_types = {
}
}
-- Dungeon Master by PilzAdam
mobs:register_mob("mobs_monster:dungeon_master", {
@ -53,18 +52,26 @@ mobs:register_mob("mobs_monster:dungeon_master", {
{name = "mobs:leather", chance = 2, min = 0, max = 2},
{name = "default:mese_crystal", chance = 3, min = 0, max = 2},
{name = "default:diamond", chance = 4, min = 0, max = 1},
{name = "default:diamondblock", chance = 30, min = 0, max = 1}
{name = "default:diamondblock", chance = 30, min = 0, max = 1},
{name = "mobs_monster:dungeon_master_blood", chance = 2, min = 0, max = 2,},
{name = "mobs_monster:dungeon_master_diamond", chance = 6, min = 0, max = 1,},
{name = "maptools:gold_coin", chance = 20, min = 0, max = 1,},
},
water_damage = 1,
lava_damage = 1,
light_damage = 0,
fear_height = 3,
animation = {
stand_start = 0, stand_end = 19,
walk_start = 20, walk_end = 35,
punch_start = 36, punch_end = 48,
shoot_start = 36, shoot_end = 48,
speed_normal = 15, speed_run = 15
stand_start = 0,
stand_end = 19,
walk_start = 20,
walk_end = 35,
punch_start = 36,
punch_end = 48,
shoot_start = 36,
shoot_end = 48,
speed_normal = 15,
speed_run = 15
},
-- check surrounding nodes and spawn a specific monster
@ -77,12 +84,14 @@ mobs:register_mob("mobs_monster:dungeon_master", {
tmp = master_types[n]
if core.find_node_near(pos, 1, tmp.nodes) then
if minetest.find_node_near(pos, 1, tmp.nodes) then
self.base_texture = tmp.skins
self.object:set_properties({textures = tmp.skins})
if tmp.drops then self.drops = tmp.drops end
if tmp.drops then
self.drops = tmp.drops
end
return true
end
@ -92,31 +101,26 @@ mobs:register_mob("mobs_monster:dungeon_master", {
end
})
-- where to spawn
if not mobs.custom_spawn_monster then
mobs:spawn({
name = "mobs_monster:dungeon_master",
nodes = {"default:stone", "nether:rack", "nether:rack_deep"},
max_light = 5,
chance = 9000,
active_object_count = 1,
max_height = -70
name = "mobs_monster:dungeon_master",
nodes = {"default:stone", "nether:rack", "nether:rack_deep", "hell:hellrack"},
max_light = 5,
chance = 9000,
active_object_count = 1,
max_height = -70,
})
end
-- spawn egg
mobs:register_egg("mobs_monster:dungeon_master", S("Dungeon Master"),
"fire_basic_flame.png", 1, true)
mobs:register_egg("mobs_monster:dungeon_master", S("Dungeon Master"), "fire_basic_flame.png", 1, true)
-- old mobs mod compatibility
mobs:alias_mob("mobs:dungeon_master", "mobs_monster:dungeon_master")
mobs:alias_mob("mobs:dungeon_master", "mobs_monster:dungeon_master") -- compatibility
-- fireball arrow
-- fireball (weapon)
mobs:register_arrow("mobs_monster:fireball", {
visual = "sprite",
visual_size = {x = 1, y = 1},
@ -157,7 +161,6 @@ mobs:register_arrow("mobs_monster:fireball", {
-- direct hit, no fire... just plenty of pain
hit_player = function(self, player)
player:punch(self.object, 1.0, {
full_punch_interval = 1.0,
damage_groups = {fleshy = 8}
@ -165,7 +168,6 @@ mobs:register_arrow("mobs_monster:fireball", {
end,
hit_mob = function(self, player)
player:punch(self.object, 1.0, {
full_punch_interval = 1.0,
damage_groups = {fleshy = 8}
@ -178,4 +180,16 @@ mobs:register_arrow("mobs_monster:fireball", {
end
})
--core.override_item("default:obsidian", {on_blast = function() end})
minetest.register_craftitem(":mobs:dungeon_master_blood", {
description = "Dungeon Master Blood",
inventory_image = "mobs_dungeon_master_blood.png",
groups = {magic = 1},
})
minetest.register_alias("mobs_monster:dungeon_master_blood", "mobs:dungeon_master_blood")
minetest.register_craftitem(":mobs:dungeon_master_diamond", {
description = "Dungeon Master Diamond",
inventory_image = "mobs_dungeon_master_diamond.png",
groups = {magic = 1},
})
minetest.register_alias("mobs_monster:dungeon_master_diamond", "mobs:dungeon_master_diamond")

View File

@ -1,13 +1,11 @@
-- translation and drops
local S = core.get_translator("mobs_monster")
-- Translation support
local S = minetest.get_translator("mobs_monster")
local mob_drops = {
{name = "fireflies:firefly", chance = 1, min = 1, max = 1}
}
if core.get_modpath("ethereal") then
if minetest.get_modpath("ethereal") then
table.insert(mob_drops,
{name = "ethereal:fire_dust", chance = 1, min = 1, max = 1})
@ -28,12 +26,14 @@ mobs:register_mob("mobs_monster:fire_spirit", {
collisionbox = {-0.1, -0.1, -0.1, 0.1, 0.1, 0.1},
visual_scale = {x = 0.5, y = 0.5, z = 0.5},
visual = "sprite",
textures = {{"mobs_fire_spirit.png"}},
textures = {
{"mobs_fire_spirit.png"}
},
glow = 14,
blood_texture = "fire_basic_flame.png",
immune_to = {
{"bucket:bucket_water", 2},
{"bucket:bucket_river_water", 2},
{"bucket:bucket_water", 1},
{"bucket:bucket_river_water", 1},
{"all"}
},
makes_footstep_sound = false,
@ -48,7 +48,7 @@ mobs:register_mob("mobs_monster:fire_spirit", {
jump = true,
jump_height = 6,
drops = mob_drops,
water_damage = 4,
water_damage = 1,
lava_damage = 0,
fire_damage = 0,
light_damage = 0,
@ -67,7 +67,9 @@ mobs:register_mob("mobs_monster:fire_spirit", {
self.flame_timer = (self.flame_timer or 0) + dtime
if self.flame_timer < 0.1 then return end
if self.flame_timer < 0.25 then
return
end
self.flame_timer = 0
@ -78,7 +80,6 @@ mobs:register_mob("mobs_monster:fire_spirit", {
end
})
-- where to spawn
if not mobs.custom_spawn_monster then
@ -94,6 +95,5 @@ if not mobs.custom_spawn_monster then
})
end
-- spawn egg
mobs:register_egg("mobs_monster:fire_spirit", S("Fire Spirit"), "fire_basic_flame.png", 1)

View File

@ -1,11 +1,11 @@
-- translation and mod path
-- Load support for intllib.
local path = minetest.get_modpath(minetest.get_current_modname()) .. "/"
local S = core.get_translator("mobs_monster")
local path = core.get_modpath(core.get_current_modname()) .. "/"
-- Translation support
local S = minetest.get_translator("mobs_monster")
-- Check for custom mob spawn file
local input = io.open(path .. "spawn.lua", "r")
if input then
@ -14,11 +14,11 @@ if input then
input = nil
end
-- helper function
-- helper function
local function ddoo(mob)
if core.settings:get_bool("mobs_monster." .. mob) == false then
if minetest.settings:get_bool("mobs_monster." .. mob) == false then
print("[Mobs_Monster] " .. mob .. " disabled!")
return
end
@ -27,7 +27,6 @@ local function ddoo(mob)
end
-- Monsters
ddoo("dirt_monster") -- PilzAdam
ddoo("dungeon_master")
ddoo("oerkki")
@ -39,17 +38,19 @@ ddoo("mese_monster")
ddoo("spider") -- AspireMint
ddoo("land_guard")
ddoo("fire_spirit")
dofile(path .. "minotaur.lua") -- NALC(sys4 fork MFF) Kalabasa
-- Load custom spawning if found
-- Load custom spawning
if mobs.custom_spawn_monster then
dofile(path .. "spawn.lua")
end
-- Lucky Blocks
if core.get_modpath("lucky_block") then
-- Lucky Blocks
if minetest.get_modpath("lucky_block") then
dofile(path .. "lucky_block.lua")
end
print ("[MOD] Mobs Redo Monsters loaded")
print ("[MOD] Mobs Monster loaded")

View File

@ -1,7 +1,5 @@
-- translation and custom land guard types
local S = core.get_translator("mobs_monster")
-- Translation support
local S = minetest.get_translator("mobs_monster")
local guard_types = {
@ -38,7 +36,7 @@ mobs:register_mob("mobs_monster:land_guard", {
attack_type = "dogfight",
group_attack = true,
reach = 3,
damage = 12,
damage = 15,
hp_min = 30,
hp_max = 65,
armor = 50,
@ -52,7 +50,9 @@ mobs:register_mob("mobs_monster:land_guard", {
{"mobs_land_guard3.png"}
},
makes_footstep_sound = true,
sounds = {random = "mobs_dungeonmaster"},
sounds = {
random = "mobs_dungeonmaster",
},
walk_velocity = 1.5,
run_velocity = 3.4,
jump = true,
@ -69,10 +69,14 @@ mobs:register_mob("mobs_monster:land_guard", {
light_damage = 0,
fear_height = 8,
animation = {
stand_start = 0, stand_end = 19,
walk_start = 20, walk_end = 35,
punch_start = 36, punch_end = 48,
speed_normal = 15, speed_run = 20,
stand_start = 0,
stand_end = 19,
walk_start = 20,
walk_end = 35,
punch_start = 36,
punch_end = 48,
speed_normal = 15,
speed_run = 20,
},
-- check surrounding nodes and spawn a specific guard
@ -85,13 +89,15 @@ mobs:register_mob("mobs_monster:land_guard", {
tmp = guard_types[n]
if core.find_node_near(pos, 1, tmp.nodes) then
if minetest.find_node_near(pos, 1, tmp.nodes) then
self.base_texture = { tmp.skins[math.random(#tmp.skins)] }
self.object:set_properties({textures = self.base_texture})
self.docile_by_day = tmp.docile
if tmp.drops then self.drops = tmp.drops end
if tmp.drops then
self.drops = tmp.drops
end
return true
end
@ -101,23 +107,20 @@ mobs:register_mob("mobs_monster:land_guard", {
end,
})
-- where to spawn
if not mobs.custom_spawn_monster then
mobs:spawn({
name = "mobs_monster:land_guard",
nodes = {
"default:snow", "default:ice", "default:stone",
"default:dry_dirt_with_dry_grass", "ethereal:dry_dirt"
},
max_light = 7,
chance = 25000,
min_height = 0,
active_object_count = 1,
})
mobs:spawn({
name = "mobs_monster:land_guard",
nodes = {
"default:snow", "default:ice", "default:stone",
"default:dry_dirt_with_dry_grass", "ethereal:dry_dirt"
},
max_light = 7,
chance = 25000,
min_height = 0,
active_object_count = 1,
})
end
-- spawn egg
mobs:register_egg("mobs_monster:land_guard", S("Land Guard"), "default_ice.png", 1)

View File

@ -1,5 +1,5 @@
local S = core.get_translator("mobs_monster")
-- Translation support
local S = minetest.get_translator("mobs_monster")
-- Lava Flan by Zeg9 (additional textures by JurajVajda)
@ -7,14 +7,14 @@ mobs:register_mob("mobs_monster:lava_flan", {
type = "monster",
passive = false,
attack_type = "dogfight",
reach = 2.5,
reach = 2,
damage = 3,
hp_min = 20,
hp_min = 10,
hp_max = 35,
armor = 80,
collisionbox = {-0.5, -0.5, -0.5, 0.5, 1.5, 0.5},
visual = "mesh",
mesh = "zmobs_lava_flan.b3d",
mesh = "zmobs_lava_flan.x",
textures = {
{"zmobs_lava_flan.png"},
{"zmobs_lava_flan2.png"},
@ -39,12 +39,9 @@ mobs:register_mob("mobs_monster:lava_flan", {
fire_damage = 0,
light_damage = 0,
immune_to = {
{"mobs:pick_lava", -2}, -- lava pick heals 2 health
{"default:lava_source", 0}, -- so that damage per second doesnt affect mob
{"default:lava_flowing", 0},
{"nether:lava_source", 0},
{"mobs:pick_lava", -2} -- lava pick heals 2 health
},
fly_in = {"default:lava_source", "default:lava_flowing", "nether:lava_source"},
fly_in = {"default:lava_source", "default:lava_flowing"},
animation = {
speed_normal = 15,
speed_run = 15,
@ -62,7 +59,7 @@ mobs:register_mob("mobs_monster:lava_flan", {
on_die = function(self, pos)
local cod = self.cause_of_death or {}
local def = cod.node and core.registered_nodes[cod.node]
local def = cod.node and minetest.registered_nodes[cod.node]
if def and def.groups and def.groups.water then
@ -70,7 +67,7 @@ mobs:register_mob("mobs_monster:lava_flan", {
mobs:effect(pos, 40, "tnt_smoke.png", 3, 5, 2, 0.5, nil, false)
core.sound_play("fire_extinguish_flame",
minetest.sound_play("fire_extinguish_flame",
{pos = pos, max_hear_distance = 12, gain = 1.5}, true)
self.object:remove()
@ -81,16 +78,16 @@ mobs:register_mob("mobs_monster:lava_flan", {
else
mobs:effect(pos, 40, "fire_basic_flame.png", 2, 3, 2, 5, 10, nil)
local nods = core.find_nodes_in_area(
{x = pos.x, y = pos.y + 1, z = pos.z},
{x = pos.x, y = pos.y, z = pos.z}, "air")
local nods = minetest.find_nodes_in_area(
{x = pos.x, y = pos.y + 1, z = pos.z},
{x = pos.x, y = pos.y, z = pos.z}, "air")
-- place flame if position empty and flame exists
if nods and #nods > 0
and core.registered_nodes["fire:basic_flame"] then
and minetest.registered_nodes["fire:basic_flame"] then
pos = nods[math.random(#nods)]
core.set_node(pos, {name = "fire:basic_flame"})
minetest.set_node(pos, {name = "fire:basic_flame"})
end
self.object:remove()
@ -99,98 +96,93 @@ mobs:register_mob("mobs_monster:lava_flan", {
glow = 10
})
-- where to spawn
if not mobs.custom_spawn_monster then
mobs:spawn({
name = "mobs_monster:lava_flan",
nodes = {"default:lava_source"},
chance = 1500,
active_object_count = 1,
max_height = 0
})
mobs:spawn({
name = "mobs_monster:lava_flan",
nodes = {"default:lava_source"},
chance = 1500,
active_object_count = 1,
max_height = 0
})
end
-- spawn egg
-- add spawn egg
mobs:register_egg("mobs_monster:lava_flan", S("Lava Flan"), "default_lava.png", 1)
-- compatibility for old mobs mod
-- compatibility alias, only needed for servers who used the old mobs mod
mobs:alias_mob("mobs:lava_flan", "mobs_monster:lava_flan")
-- lava orb
core.register_craftitem(":mobs:lava_orb", {
-- lava orb
minetest.register_craftitem(":mobs:lava_orb", {
description = S("Lava orb"),
inventory_image = "zmobs_lava_orb.png",
light_source = 14
})
core.register_alias("zmobs:lava_orb", "mobs:lava_orb")
minetest.register_alias("zmobs:lava_orb", "mobs:lava_orb")
core.register_craft({
minetest.register_craft({
type = "fuel",
recipe = "mobs:lava_orb",
burntime = 80
})
-- backup and replace old function
local old_handle_node_drops = core.handle_node_drops
-- Lava Pick (digs and smelts at same time)
function core.handle_node_drops(pos, drops, digger)
local old_handle_node_drops = minetest.handle_node_drops
-- are we a player using the lava pick?
if digger and digger:get_wielded_item():get_name() == ("mobs:pick_lava") then
function minetest.handle_node_drops(pos, drops, digger)
local hot_drops = {}
local is_cooked
-- does player exist?
if not digger then return end
for _, drop in ipairs(drops) do
-- are we holding Lava Pick?
if digger:get_wielded_item():get_name() ~= ("mobs:pick_lava") then
return old_handle_node_drops(pos, drops, digger)
end
local stack = ItemStack(drop)
-- reset new smelted drops
local hot_drops = {}
while not stack:is_empty() do
-- loop through current node drops
for _, drop in ipairs(drops) do
local output, decremented_input = core.get_craft_result({
method = "cooking", width = 1, items = {stack}})
-- get cooked output of current drops
local stack = ItemStack(drop)
if output.item:is_empty() then
table.insert_all(hot_drops, decremented_input.items)
break
else
is_cooked = true
while not stack:is_empty() do
if not output.item:is_empty() then
table.insert(hot_drops, output.item)
end
local output, decremented_input = minetest.get_craft_result({
method = "cooking",
width = 1,
items = {stack}
})
table.insert_all(hot_drops, output.replacements)
if output.item:is_empty() then
stack = decremented_input.items[1] or ItemStack()
table.insert_all(hot_drops, decremented_input.items)
break
else
if not output.item:is_empty() then
table.insert(hot_drops, output.item)
end
table.insert_all(hot_drops, output.replacements)
stack = decremented_input.items[1] or ItemStack()
end
end
drops = hot_drops -- replace normal drops with cooked versions
if is_cooked then
mobs:effect(pos, 1, "tnt_smoke.png", 3, 5, 2, 0.5, nil, false)
core.sound_play("fire_extinguish_flame",
{pos = pos, max_hear_distance = 5, gain = 0.05}, true)
end
end
return old_handle_node_drops(pos, drops, digger)
return old_handle_node_drops(pos, hot_drops, digger)
end
-- lava pick, smelts nodes when you dig
core.register_tool(":mobs:pick_lava", {
minetest.register_tool(":mobs:pick_lava", {
description = S("Lava Pickaxe"),
inventory_image = "mobs_pick_lava.png",
tool_capabilities = {
@ -198,7 +190,9 @@ core.register_tool(":mobs:pick_lava", {
max_drop_level = 3,
groupcaps = {
cracky = {
times = {[1] = 1.80, [2] = 0.80, [3] = 0.40}, uses = 40, maxlevel = 3
times = {[1] = 1.80, [2] = 0.80, [3] = 0.40},
uses = 40,
maxlevel = 3
}
},
damage_groups = {fleshy = 6, fire = 1},
@ -207,9 +201,7 @@ core.register_tool(":mobs:pick_lava", {
light_source = 14
})
-- recipe
core.register_craft({
minetest.register_craft({
output = "mobs:pick_lava",
recipe = {
{"mobs:lava_orb", "mobs:lava_orb", "mobs:lava_orb"},
@ -218,16 +210,16 @@ core.register_craft({
}
})
-- Add [toolranks] mod support
-- Add [toolranks] mod support if found
if minetest.get_modpath("toolranks") then
if core.get_modpath("toolranks") then
core.override_item("mobs:pick_lava", {
original_description = S("Lava Pickaxe"),
description = toolranks.create_description("Lava Pickaxe", 0, 1),
after_use = toolranks.new_afteruse})
minetest.override_item("mobs:pick_lava", {
original_description = "Lava Pickaxe",
description = toolranks.create_description("Lava Pickaxe", 0, 1),
after_use = toolranks.new_afteruse})
end
-- obsidian flan
mobs:register_mob("mobs_monster:obsidian_flan", {
@ -239,17 +231,21 @@ mobs:register_mob("mobs_monster:obsidian_flan", {
arrow = "mobs_monster:obsidian_arrow",
reach = 2,
damage = 3,
hp_min = 20,
hp_min = 10,
hp_max = 35,
armor = 30,
visual_size = {x = 0.6, y = 0.6},
collisionbox = {-0.3, -0.3, -0.3, 0.3, 0.8, 0.3},
visual = "mesh",
mesh = "zmobs_lava_flan.b3d",
textures = {{"mobs_obsidian_flan.png"}},
mesh = "zmobs_lava_flan.x",
textures = {
{"mobs_obsidian_flan.png"}
},
blood_texture = "default_obsidian.png",
makes_footstep_sound = true,
sounds = {random = "mobs_lavaflan"},
sounds = {
random = "mobs_lavaflan"
},
walk_velocity = 0.1,
run_velocity = 0.5,
jump = false,
@ -264,23 +260,28 @@ mobs:register_mob("mobs_monster:obsidian_flan", {
fire_damage = 0,
light_damage = 0,
animation = {
speed_normal = 15, speed_run = 15,
stand_start = 0, stand_end = 8,
walk_start = 10, walk_end = 18,
run_start = 20, run_end = 28,
punch_start = 20, punch_end = 28
speed_normal = 15,
speed_run = 15,
stand_start = 0,
stand_end = 8,
walk_start = 10,
walk_end = 18,
run_start = 20,
run_end = 28,
punch_start = 20,
punch_end = 28
}
})
-- spawn egg
-- add spawn egg
mobs:register_egg("mobs_monster:obsidian_flan", S("Obsidian Flan"),
"default_obsidian.png", 1)
-- obsidian arrow and grief setting check
local mobs_griefing = core.settings:get_bool("mobs_griefing") ~= false
local mobs_griefing = minetest.settings:get_bool("mobs_griefing") ~= false
-- mese arrow (weapon)
mobs:register_arrow("mobs_monster:obsidian_arrow", {
visual = "sprite",
visual_size = {x = 0.5, y = 0.5},
@ -288,7 +289,6 @@ mobs:register_arrow("mobs_monster:obsidian_arrow", {
velocity = 6,
hit_player = function(self, player)
player:punch(self.object, 1.0, {
full_punch_interval = 1.0,
damage_groups = {fleshy = 8},
@ -296,7 +296,6 @@ mobs:register_arrow("mobs_monster:obsidian_arrow", {
end,
hit_mob = function(self, player)
player:punch(self.object, 1.0, {
full_punch_interval = 1.0,
damage_groups = {fleshy = 8},
@ -305,15 +304,18 @@ mobs:register_arrow("mobs_monster:obsidian_arrow", {
hit_node = function(self, pos, node)
if mobs_griefing == false or core.is_protected(pos, "") then
if mobs_griefing == false or minetest.is_protected(pos, "") then
return
end
local texture = "default_dirt.png" --fallback texture
local radius = 1
local def = node and core.registered_nodes[node.name]
if not def then return end
local radius = 1
local def = minetest.registered_nodes[node]
if def then
node = {name = node}
end
if def and def.tiles and def.tiles[1] then
texture = def.tiles[1]
@ -325,7 +327,7 @@ mobs:register_arrow("mobs_monster:obsidian_arrow", {
return
end
core.add_particlespawner({
minetest.add_particlespawner({
amount = 32,
time = 0.1,
minpos = vector.subtract(pos, radius / 2),
@ -344,10 +346,10 @@ mobs:register_arrow("mobs_monster:obsidian_arrow", {
collisiondetection = true
})
core.set_node(pos, {name = "air"})
minetest.set_node(pos, {name = "air"})
local snd = def.sounds and def.sounds.dug or "default_dig_crumbly"
core.sound_play(snd, {pos = pos, max_hear_distance = 8, gain = 1.0}, true)
minetest.sound_play(snd, {pos = pos, max_hear_distance = 12, gain = 1.0}, true)
end
})

View File

@ -35,7 +35,6 @@ Textures by AMMOnym (WTFPL)
Textures by TenPlus1 (MIT)
mobs_stone_monster3.png
mobs_fireball.png
mobs_obsidian_flan.png
Textures by Sirrobzeroone (CC0 1.0 Universal)
mobs_stone_monster4.png
@ -72,12 +71,10 @@ AspireMint (CC BY-SA 3.0)
mobs_spider_snowy.png
mobs_spider_grey.png
mobs_spider_crystal.png
zmobs_lava_flan.b3d
zmobs_lava_flan.png
zmobs_lava_flan2.png
zmobs_lava_flan3.png
Zeg9 (CC BY-SA 3.0)
zmobs_lava_flan.x
zmobs_lava_flan.png
zmobs_lava_orb.png
Sounds by Cyberpangolin (WTFPL) https://forum.minetest.net/viewtopic.php?t=10798

View File

@ -1,14 +0,0 @@
# textdomain:mobs_monster
Cobweb=Teia de Aranha
Dirt Monster=Monstro de Terra
Dungeon Master=Mestre das Dungeons
Lava Flan=Pudim de Lava
Lava Pickaxe=Picareta de Lava
Lava orb=Orb de Lava
Mese Monster=Monstro de mese
#Obsidian Flan=Pudim de Obsidian
Oerkki=Oerkki
Sand Monster=Monstro de Areia
Spider=Aranha
Stone Monster=Monstro de pedra
Tree Monster= Arvore Monstro

View File

@ -1,14 +0,0 @@
# textdomain:mobs_monster
Cobweb=Паутина
Dirt Monster=Земляной Монстр
Dungeon Master=Хозяйн Подземелья
Lava Flan=Лавовый Слизень
Lava Pickaxe=Лавовая Кирка
Lava orb=Лавовая сфера
Mese Monster=Месе Монстр
Obsidian Flan=Обсидиановый Слизень
Oerkki=Дух Ведьмы
Sand Monster=Песочный Монстр
Spider=Паук
Stone Monster=Каменный Монстр
Tree Monster=Древесный Монстр

View File

@ -1,19 +0,0 @@
# textdomain:mobs_monster
Mobs Monster=Моби Монстри
Add many different monsters into your world.=Додає багато різних монстрів у світ.
Adds many types of monster.=Додає багато різних типів монстрів.
Cobweb=Павутина
Dirt Monster=Земляний монстр
Dungeon Master=Хазяїн печер
Lava Flan=Лавовий слимак
Lava Pickaxe=Лавове кайло
Lava orb=Лавова сфера
Mese Monster=Месе монстр
Obsidian Flan=Обсидіановий слимак
Oerkki=Оерккі
Land Guard=Охоронець землі
Fire Spirit=Вогняний дух
Sand Monster=Пісочний монстр
Spider=Павук
Stone Monster=Кам'яний монстр
Tree Monster=Дерево-монстр

View File

@ -1,6 +1,3 @@
-- web trap schematic
local web = {name = "mobs:cobweb"}
local web_trap = {
size = {x = 3, y = 3, z = 3},
@ -23,8 +20,6 @@ lucky_block:add_schematics({
{"webtrap", web_trap, {x = 1, y = 0, z = 1}},
})
-- add lucky blocks
lucky_block:add_blocks({
{"sch", "webtrap", 1, true},
{"spw", "mobs:dungeon_master", 1, nil, nil, 3, "Billy"},
@ -37,7 +32,6 @@ lucky_block:add_blocks({
{"spw", "mobs:spider", 5},
{"spw", "mobs:mese_monster", 2},
{"spw", "mobs:lava_flan", 3},
{"spw", "mobs_monster:land_guard", 2},
{"nod", "default:chest", 0, {
{name = "mobs:lava_orb", max = 1}}},
})

View File

@ -1,139 +1,140 @@
-- translation and custom mese monster types
local S = core.get_translator("mobs_monster")
-- Translation support
local S = minetest.get_translator("mobs_monster")
local mese_monster_types = {
{ -- red
y_min = -20,
y_max = -1000,
damage = 2,
reach = 3,
hp_min = 15,
hp_max = 25,
armor = 80,
skins = {"mobs_mese_monster_red.png"},
immune_to = {
{"default:pick_wood", 0},
{"default:shovel_wood", 0},
{"default:axe_wood", 0},
{"default:sword_wood", 0}
},
drops = {
{name = "default:mese_crystal", chance = 15, min = 0, max = 1},
{name = "default:mese_crystal_fragment", chance = 2, min = 0, max = 1}
},
arrow_override = function(self)
self.velocity = 6
self.damage = 2
end
-- mese_monster_red
{
y_min = -20,
y_max = -1000,
damage = 2,
reach = 3,
hp_min = 15,
hp_max = 25,
armor = 80,
skins = {"mobs_mese_monster_red.png"},
immune_to = {
{"default:pick_wood", 0},
{"default:shovel_wood", 0},
{"default:axe_wood", 0},
{"default:sword_wood", 0}
},
{ -- green
y_min = -1001,
y_max = -2000,
damage = 3,
reach = 3,
hp_min = 20,
hp_max = 30,
armor = 75,
skins = {"mobs_mese_monster_green.png"},
immune_to = {
{"default:pick_wood", 0},
{"default:shovel_wood", 0},
{"default:axe_wood", 0},
{"default:sword_wood", 0},
{"default:pick_stone", 0},
{"default:shovel_stone", 0},
{"default:axe_stone", 0},
{"default:sword_stone", 0}
},
drops = {
{name = "default:mese_crystal", chance = 12, min = 0, max = 1},
{name = "default:mese_crystal_fragment", chance = 1, min = 0, max = 1}
},
arrow_override = function(self)
self.velocity = 6
self.damage = 2
end
drops = {
{name = "default:mese_crystal", chance = 15, min = 0, max = 1},
{name = "default:mese_crystal_fragment", chance = 2, min = 0, max = 1}
},
arrow_override = function(self)
self.velocity = 6
self.damage = 2
end
},
{ -- blue
y_min = -2001,
y_max = -3000,
damage = 3,
reach = 4,
hp_min = 25,
hp_max = 35,
armor = 70,
skins = {"mobs_mese_monster_blue.png"},
immune_to = {
{"default:pick_wood", 0},
{"default:shovel_wood", 0},
{"default:axe_wood", 0},
{"default:sword_wood", 0},
{"default:pick_stone", 0},
{"default:shovel_stone", 0},
{"default:axe_stone", 0},
{"default:sword_stone", 0},
{"default:pick_bronze", 0},
{"default:shovel_bronze", 0},
{"default:axe_bronze", 0},
{"default:sword_bronze", 0}
},
drops = {
{name = "default:mese", chance = 15, min = 0, max = 1},
{name = "default:mese_crystal", chance = 9, min = 0, max = 2},
{name = "default:mese_crystal_fragment", chance = 1, min = 0, max = 2}
},
arrow_override = function(self)
self.velocity = 7
self.damage = 3
end
-- mese_monster_green
{
y_min = -1001,
y_max = -2000,
damage = 3,
reach = 3,
hp_min = 20,
hp_max = 30,
armor = 75,
skins = {"mobs_mese_monster_green.png"},
immune_to = {
{"default:pick_wood", 0},
{"default:shovel_wood", 0},
{"default:axe_wood", 0},
{"default:sword_wood", 0},
{"default:pick_stone", 0},
{"default:shovel_stone", 0},
{"default:axe_stone", 0},
{"default:sword_stone", 0}
},
drops = {
{name = "default:mese_crystal", chance = 12, min = 0, max = 1},
{name = "default:mese_crystal_fragment", chance = 1, min = 0, max = 1}
},
arrow_override = function(self)
self.velocity = 6
self.damage = 2
end
},
-- mese_monster_blue
{
y_min = -2001,
y_max = -3000,
damage = 3,
reach = 4,
hp_min = 25,
hp_max = 35,
armor = 70,
skins = {"mobs_mese_monster_blue.png"},
immune_to = {
{"default:pick_wood", 0},
{"default:shovel_wood", 0},
{"default:axe_wood", 0},
{"default:sword_wood", 0},
{"default:pick_stone", 0},
{"default:shovel_stone", 0},
{"default:axe_stone", 0},
{"default:sword_stone", 0},
{"default:pick_bronze", 0},
{"default:shovel_bronze", 0},
{"default:axe_bronze", 0},
{"default:sword_bronze", 0}
},
drops = {
{name = "default:mese", chance = 15, min = 0, max = 1},
{name = "default:mese_crystal", chance = 9, min = 0, max = 2},
{name = "default:mese_crystal_fragment", chance = 1, min = 0, max = 2}
},
arrow_override = function(self)
self.velocity = 7
self.damage = 3
end
},
-- mese_monster_purple
{
y_min = -3000,
y_max = -31000,
damage = 4,
reach = 5,
hp_min = 30,
hp_max = 40,
armor = 60,
skins = {"mobs_mese_monster_purple.png"},
immune_to = {
{"default:pick_wood", 0},
{"default:shovel_wood", 0},
{"default:axe_wood", 0},
{"default:sword_wood", 0},
{"default:pick_stone", 0},
{"default:shovel_stone", 0},
{"default:axe_stone", 0},
{"default:sword_stone", 0},
{"default:pick_bronze", 0},
{"default:shovel_bronze", 0},
{"default:axe_bronze", 0},
{"default:sword_bronze", 0},
{"default:pick_steel", 0},
{"default:shovel_steel", 0},
{"default:axe_steel", 0},
{"default:sword_steel", 0}
},
drops = {
{name = "default:mese", chance = 9, min = 0, max = 1},
{name = "default:mese_crystal", chance = 6, min = 0, max = 2},
{name = "default:mese_crystal_fragment", chance = 1, min = 0, max = 3}
},
arrow_override = function(self)
self.velocity = 8
self.damage = 4
end
}}
{ -- purple
y_min = -3000,
y_max = -31000,
damage = 4,
reach = 5,
hp_min = 30,
hp_max = 40,
armor = 60,
skins = {"mobs_mese_monster_purple.png"},
immune_to = {
{"default:pick_wood", 0},
{"default:shovel_wood", 0},
{"default:axe_wood", 0},
{"default:sword_wood", 0},
{"default:pick_stone", 0},
{"default:shovel_stone", 0},
{"default:axe_stone", 0},
{"default:sword_stone", 0},
{"default:pick_bronze", 0},
{"default:shovel_bronze", 0},
{"default:axe_bronze", 0},
{"default:sword_bronze", 0},
{"default:pick_steel", 0},
{"default:shovel_steel", 0},
{"default:axe_steel", 0},
{"default:sword_steel", 0}
},
drops = {
{name = "default:mese", chance = 9, min = 0, max = 1},
{name = "default:mese_crystal", chance = 6, min = 0, max = 2},
{name = "default:mese_crystal_fragment", chance = 1, min = 0, max = 3}
},
arrow_override = function(self)
self.velocity = 8
self.damage = 4
end
}
}
-- Mese Monster by SirrobZeroone
mobs:register_mob("mobs_monster:mese_monster", {
type = "monster",
visual_size = {x = 10, y = 10}, -- Got scale wrong in blender by factor of 10 - S01
@ -154,7 +155,9 @@ mobs:register_mob("mobs_monster:mese_monster", {
collisionbox = {-0.75, -0.5, -0.75, 0.75, 2.5, 0.75},
visual = "mesh",
mesh = "mobs_mese_monster.b3d",
textures = {{"mobs_mese_monster_purple.png"}},
textures = {
{"mobs_mese_monster_purple.png"}
},
blood_texture = "default_mese_crystal_fragment.png",
makes_footstep_sound = false,
sounds = {
@ -179,26 +182,43 @@ mobs:register_mob("mobs_monster:mese_monster", {
drops = {
{name = "default:mese_crystal", chance = 9, min = 0, max = 2},
{name = "default:mese_crystal_fragment", chance = 1, min = 0, max = 2},
{name = "maptools:silver_coin", chance = 1, min = 0, max = 2},
{name = "returnmirror:mirror_inactive", chance = 50, min = 1, max = 1},
},
water_damage = 1,
lava_damage = 1,
light_damage = 0,
animation = {
speed_normal = 18, speed_run = 18,
walk_start = 10, walk_end = 41, walk_speed = 20,
run_start = 10, run_end = 41, run_speed = 30,
stand_start = 60, stand_end = 83,
shoot_start = 100, shoot_end = 113,
die_start = 125, die_end = 141, death_speed = 25, die_loop = false,
jump_start = 150 , jump_end = 168, jump_loop = false,
punch_start = 175, punch_end = 189
speed_normal = 18,
speed_run = 18,
walk_start = 10,
walk_end = 41,
walk_speed = 20,
run_start = 10,
run_end = 41,
run_speed = 30,
stand_start = 60,
stand_end = 83,
shoot_start = 100,
shoot_end = 113,
die_start = 125,
die_end = 141,
death_speed = 25,
die_loop = false,
jump_start = 150 ,
jump_end = 168,
jump_loop = false,
punch_start = 175,
punch_end = 189
},
after_activate = function(self, staticdata, def, dtime)
local tex = self and self.textures and self.textures[1]
if tex == "zmobs_mese_monster.png" then self.object:remove() end
if tex == "zmobs_mese_monster.png" then
self.object:remove()
end
end,
on_spawn = function(self)
@ -238,11 +258,11 @@ mobs:register_mob("mobs_monster:mese_monster", {
-- direction sets type N = red, E = green, S = blue, W = purple
-- Just for fun - S01
local objects = core.get_objects_inside_radius(pos, 10)
local objects = minetest.get_objects_inside_radius(pos, 10)
for i, obj in ipairs(objects) do
if core.is_player(obj)
if minetest.is_player(obj)
and obj:get_wielded_item():get_name() == "mobs_monster:mese_monster" then
local degree = (360 + math.deg(obj:get_look_horizontal())) % 360
@ -269,15 +289,14 @@ mobs:register_mob("mobs_monster:mese_monster", {
end
})
-- mese arrow item
core.register_craftitem("mobs_monster:mese_crystal_fragment_arrow", {
-- mese arrow (weapon)
minetest.register_craftitem("mobs_monster:mese_crystal_fragment_arrow", {
description = S("Mese Monster Arrow"),
inventory_image = "mobs_mese_arrow.png",
groups = {not_in_creative_inventory = 1}
})
-- mese arrow
mobs:register_arrow("mobs_monster:mese_arrow", {
visual = "wielditem",
@ -288,7 +307,6 @@ mobs:register_arrow("mobs_monster:mese_arrow", {
damage = 2,
hit_player = function(self, player)
player:punch(self.object, 1.0, {
full_punch_interval = 1.0,
damage_groups = {fleshy = self.damage}
@ -296,7 +314,6 @@ mobs:register_arrow("mobs_monster:mese_arrow", {
end,
hit_mob = function(self, player)
player:punch(self.object, 1.0, {
full_punch_interval = 1.0,
damage_groups = {fleshy = self.damage}
@ -307,33 +324,29 @@ mobs:register_arrow("mobs_monster:mese_arrow", {
end
})
-- where to spawn
if not mobs.custom_spawn_monster then
mobs:spawn({
name = "mobs_monster:mese_monster",
nodes = {"default:stone"},
max_light = 7,
chance = 5000,
active_object_count = 1,
max_height = -20
name = "mobs_monster:mese_monster",
nodes = {"default:stone", "default:sandstone"},
max_light = 7,
chance = 5000,
active_object_count = 1,
max_height = -20
})
end
-- spawn egg
mobs:register_egg("mobs_monster:mese_monster", S("Mese Monster"), "default_mese_block.png", 1)
-- compatibility with older mobs mod
mobs:alias_mob("mobs:mese_monster", "mobs_monster:mese_monster")
mobs:alias_mob("mobs:mese_monster", "mobs_monster:mese_monster") -- compatiblity
-- 9x mese crystal fragments = 1x mese crystal recipe
-- 9x mese crystal fragments = 1x mese crystal
local f = "default:mese_crystal_fragment"
core.register_craft({
minetest.register_craft({
output = "default:mese_crystal",
recipe = {{f, f, f}, {f, f, f}, {f, f, f}}
})

111
minotaur.lua Executable file
View File

@ -0,0 +1,111 @@
-- Minotaur Monster by ???
mobs:register_mob("mobs_monster:minotaur", {
-- animal, monster, npc, barbarian
type = "monster",
-- aggressive, deals 11 damage to player when hit
passive = false,
attack_type = "dogfight",
pathfinding = false,
reach = 2,
damage = 6,
-- health & armor
hp_min = 45,
hp_max = 55,
armor = 90,
-- textures and model
collisionbox = {-0.9,-0.01,-0.9, 0.9,2.5,0.9},
visual = "mesh",
mesh = "mobs_minotaur.b3d",
textures = {
{"mobs_minotaur.png"},
},
visual_size = {x=1, y=1},
blood_texture = "mobs_blood.png",
-- sounds
makes_footstep_sound = true,
-- sounds = {
-- random = "mobs_zombie",
-- damage = "mobs_zombie_hit",
-- attack = "mobs_zombie_attack",
-- death = "mobs_zombie_death",
-- },
-- speed and jump
walk_velocity = 1,
run_velocity = 3,
jump = true,
floats = 1,
view_range = 16,
knock_back = 0.05, --this is a test
-- drops desert_sand and coins when dead
drops = {
{name = "maptools:gold_coin", chance = 40, min = 1, max = 1,},
{name = "mobs_monster:minotaur_eye", chance = 2, min = 1, max = 2,},
{name = "mobs_monster:minotaur_horn", chance = 4, min = 1, max = 2,},
{name = "mobs_monster:minotaur_fur", chance = 1, min = 1, max = 3,},
},
water_damage = 0,
lava_damage = 5,
light_damage = 0,
-- model animation
animation = {
speed_normal = 15, speed_run = 15,
stand_start = 0, stand_end = 19,
walk_start = 20, walk_end = 39,
run_start = 20, run_end = 39,
punch_start = 40, punch_end = 50,
},
})
mobs:alias_mob("mobs:minotaur", "mobs_monster:minotaur")
-- spawns on desert sand between -1 and 20 light, 1 in 100000 chance, 1 Minotaur in area up to 31000 in height
--mobs:spawn_specific("mobs_monster:minotaur", {"default:dirt_with_dry_grass"}, {"air"}, -1, 20, 30, 50000, 1, -31000, 31000, false)
mobs:spawn({
name = "mobs_monster:minotaur",
nodes = {"default:dirt_with_dry_grass", "default:desert_sand", "default:desert_stone"},
min_light = 0,
max_light = default.LIGHT_MAX,
chance = 7000,
active_object_count = 1,
min_height = -31000,
max_height = 31000,
})
-- register spawn egg
mobs:register_egg("mobs_monster:minotaur", "Minotaur", "mobs_minotaur_inv.png", 1)
minetest.register_craftitem(":mobs:minotaur_eye", {
description = "Minotaur Eye",
inventory_image = "mobs_minotaur_eye.png",
groups = {magic = 1},
})
mobs:alias_mob("mobs_monster:minotaur_eye", "mobs:minotaur_eye")
minetest.register_craftitem(":mobs:minotaur_horn", {
description = "Minotaur Horn",
inventory_image = "mobs_minotaur_horn.png",
groups = {magic = 1},
})
mobs:alias_mob("mobs_monster:minotaur_horn", "mobs:minotaur_horn")
minetest.register_craftitem(":mobs:minotaur_fur", {
description = "Minotaur Fur",
inventory_image = "mobs_minotaur_fur.png",
groups = {magic = 1},
})
mobs:alias_mob("mobs_monster:minotaur_fur", "mobs:minotaur_fur")
minetest.register_craftitem(":mobs:minotaur_lots_of_fur", {
description = "Lot of Minotaur Fur",
inventory_image = "mobs_minotaur_lots_of_fur.png",
groups = {magic = 1},
})
mobs:alias_mob("mobs_monster:minotaur_lots_of_fur", "mobs:minotaur_lots_of_fur")
minetest.register_craft({
output = "mobs_monster:minotaur_lots_of_fur",
recipe = {{"mobs_monster:minotaur_fur", "mobs_monster:minotaur_fur"},
{"mobs_monster:minotaur_fur", "mobs_monster:minotaur_fur"},
},
})

BIN
models/mobs_minotaur.b3d Executable file

Binary file not shown.

Binary file not shown.

Binary file not shown.

3506
models/zmobs_lava_flan.x Normal file

File diff suppressed because it is too large Load Diff

View File

@ -1,5 +1,5 @@
local S = core.get_translator("mobs_monster")
-- Translation support
local S = minetest.get_translator("mobs_monster")
-- Oerkki by PilzAdam
@ -22,25 +22,33 @@ mobs:register_mob("mobs_monster:oerkki", {
{"mobs_oerkki3.png"}
},
makes_footstep_sound = false,
sounds = {random = "mobs_oerkki"},
sounds = {
random = "mobs_oerkki"
},
walk_velocity = 1,
run_velocity = 3,
view_range = 10,
jump = true,
drops = {
{name = "default:obsidian", chance = 3, min = 0, max = 2},
{name = "default:gold_lump", chance = 2, min = 0, max = 2}
{name = "default:gold_lump", chance = 2, min = 0, max = 2},
{name = "maptools:silver_coin", chance = 1, min = 0, max = 1},
},
water_damage = 2,
lava_damage = 4,
light_damage = 1,
fear_height = 4,
animation = {
stand_start = 0, stand_end = 23,
walk_start = 24, walk_end = 36,
run_start = 37, run_end = 49,
punch_start = 37, punch_end = 49,
speed_normal = 15, speed_run = 15
stand_start = 0,
stand_end = 23,
walk_start = 24,
walk_end = 36,
run_start = 37,
run_end = 49,
punch_start = 37,
punch_end = 49,
speed_normal = 15,
speed_run = 15
},
replace_rate = 5,
replace_what = {"default:torch"},
@ -52,7 +60,6 @@ mobs:register_mob("mobs_monster:oerkki", {
},
})
-- where to spawn
if not mobs.custom_spawn_monster then
@ -65,10 +72,8 @@ if not mobs.custom_spawn_monster then
})
end
-- spawn egg
mobs:register_egg("mobs_monster:oerkki", S("Oerkki"), "default_obsidian.png", 1)
-- compatibility with older mobs mod
mobs:alias_mob("mobs:oerkki", "mobs_monster:oerkki")
mobs:alias_mob("mobs:oerkki", "mobs_monster:oerkki") -- compatiblity

View File

@ -1,9 +1,8 @@
local S = core.get_translator("mobs_monster")
-- Translation support
local S = minetest.get_translator("mobs_monster")
-- custom particle effects
local function effect(pos, amount, texture, min_size, max_size, radius, gravity, glow)
local effect = function(pos, amount, texture, min_size, max_size, radius, gravity, glow)
radius = radius or 2
min_size = min_size or 0.5
@ -11,7 +10,7 @@ local function effect(pos, amount, texture, min_size, max_size, radius, gravity,
gravity = gravity or -10
glow = glow or 0
core.add_particlespawner({
minetest.add_particlespawner({
amount = amount,
time = 0.25,
minpos = pos,
@ -29,6 +28,7 @@ local function effect(pos, amount, texture, min_size, max_size, radius, gravity,
})
end
-- Sand Monster by PilzAdam
mobs:register_mob("mobs_monster:sand_monster", {
@ -52,28 +52,33 @@ mobs:register_mob("mobs_monster:sand_monster", {
},
blood_texture = "default_desert_sand.png",
makes_footstep_sound = true,
sounds = {random = "mobs_sandmonster"},
sounds = {
random = "mobs_sandmonster"
},
walk_velocity = 1.5,
run_velocity = 4,
view_range = 8,
jump = true,
floats = 0,
drops = {
{name = "default:silver_sand", chance = 2, min = 1, max = 2},
{name = "default:desert_sand", chance = 2, min = 1, max = 2},
{name = "default:sand", chance = 2, min = 1, max = 2},
{name = "default:clay_lump", chance = 2, min = 0, max = 1}
{name = "default:desert_sand", chance = 1, min = 3, max = 5},
{name = "maptools:silver_coin", chance = 10, min = 1, max = 1,},
},
water_damage = 3,
lava_damage = 4,
light_damage = 0,
fear_height = 4,
animation = {
speed_normal = 15, speed_run = 15,
stand_start = 0, stand_end = 39,
walk_start = 41, walk_end = 72,
run_start = 74, run_end = 105,
punch_start = 74, punch_end = 105
speed_normal = 15,
speed_run = 15,
stand_start = 0,
stand_end = 39,
walk_start = 41,
walk_end = 72,
run_start = 74,
run_end = 105,
punch_start = 74,
punch_end = 105
},
immune_to = {
{"default:shovel_wood", 3}, -- shovels deal more damage to sand monster
@ -86,7 +91,7 @@ mobs:register_mob("mobs_monster:sand_monster", {
--[[
custom_attack = function(self, p)
local pos = self.object:get_pos()
core.add_item(pos, "default:sand")
minetest.add_item(pos, "default:sand")
end,
]]
on_die = function(self, pos)
@ -112,8 +117,6 @@ mobs:register_mob("mobs_monster:sand_monster", {
]]
})
-- where to spawn
if not mobs.custom_spawn_monster then
mobs:spawn({
@ -125,11 +128,9 @@ if not mobs.custom_spawn_monster then
})
end
-- spawn egg
mobs:register_egg("mobs_monster:sand_monster", S("Sand Monster"),
"default_desert_sand.png", 1)
-- compatibility with older mobs mod
mobs:alias_mob("mobs:sand_monster", "mobs_monster:sand_monster")
mobs:alias_mob("mobs:sand_monster", "mobs_monster:sand_monster") -- compatibility

View File

@ -1,9 +1,7 @@
-- Translation support
local S = minetest.get_translator("mobs_monster")
local S = core.get_translator("mobs_monster")
-- helper function
local function get_velocity(self)
local get_velocity = function(self)
local v = self.object:get_velocity()
@ -13,9 +11,6 @@ local function get_velocity(self)
return (v.x * v.x + v.z * v.z) ^ 0.5
end
local math_cos, math_sin = math.cos, math.sin
-- custom spider types
local spider_types = {
@ -49,13 +44,14 @@ local spider_types = {
{ nodes = {"ethereal:crystal_dirt", "ethereal:crystal_spike"},
skins = {"mobs_spider_crystal.png"},
docile = true, immune_to = {{"ethereal:crystal_spike", 0}},
docile = true,
drops = {
{name = "farming:string", chance = 1, min = 0, max = 2},
{name = "ethereal:crystal_spike", chance = 15, min = 1, max = 2}}
}
}
-- Spider by AspireMint (CC-BY-SA 3.0 license)
mobs:register_mob("mobs_monster:spider", {
@ -68,8 +64,8 @@ mobs:register_mob("mobs_monster:spider", {
damage = 3,
hp_min = 10,
hp_max = 30,
armor = 100,
collisionbox = {-0.7, -0.5, -0.7, 0.7, 0, 0.7},
armor = 200,
collisionbox = {-0.8, -0.5, -0.8, 0.8, 0, 0.8},
visual_size = {x = 1, y = 1},
visual = "mesh",
mesh = "mobs_spider.b3d",
@ -91,18 +87,23 @@ mobs:register_mob("mobs_monster:spider", {
view_range = 15,
floats = 0,
drops = {
{name = "farming:string", chance = 1, min = 0, max = 2}
{name = "farming:string", chance = 1, min = 0, max = 2},
{name = "maptools:silver_coin", chance = 3, min = 0, max = 1,},
},
water_damage = 5,
lava_damage = 5,
light_damage = 0,
-- node_damage = false, -- disable damage_per_second node damage
animation = {
speed_normal = 15, speed_run = 20,
stand_start = 0, stand_end = 0,
walk_start = 1, walk_end = 21,
run_start = 1, run_end = 21,
punch_start = 25, punch_end = 45
speed_normal = 15,
speed_run = 20,
stand_start = 0,
stand_end = 0,
walk_start = 1,
walk_end = 21,
run_start = 1,
run_end = 21,
punch_start = 25,
punch_end = 45
},
-- check surrounding nodes and spawn a specific spider
@ -115,15 +116,15 @@ mobs:register_mob("mobs_monster:spider", {
tmp = spider_types[n]
if core.find_node_near(pos, 1, tmp.nodes) then
if minetest.find_node_near(pos, 1, tmp.nodes) then
self.base_texture = tmp.skins
self.object:set_properties({textures = tmp.skins})
self.docile_by_day = tmp.docile
if tmp.drops then self.drops = tmp.drops end
if tmp.immune_to then self.immune_to = tmp.immune_to end
if tmp.drops then
self.drops = tmp.drops
end
if tmp.shoot then
self.attack_type = "dogshoot"
@ -136,7 +137,6 @@ mobs:register_mob("mobs_monster:spider", {
end
if tmp.small then
self.object:set_properties({
collisionbox = {-0.2, -0.2, -0.2, 0.2, 0, 0.2},
visual_size = {x = 0.25, y = 0.25}
@ -155,7 +155,9 @@ mobs:register_mob("mobs_monster:spider", {
-- quarter second timer
self.spider_timer = (self.spider_timer or 0) + dtime
if self.spider_timer < 0.25 then return end
if self.spider_timer < 0.25 then
return
end
self.spider_timer = 0
-- need to be stopped to go onwards
@ -165,14 +167,18 @@ mobs:register_mob("mobs_monster:spider", {
end
local pos = self.object:get_pos()
local yaw = self.object:get_yaw() ; if not yaw then return end
local yaw = self.object:get_yaw()
-- sanity check
if not yaw then return end
local prop = self.object:get_properties()
pos.y = pos.y + prop.collisionbox[2] - 0.2
local dir_x = -math_sin(yaw) * (prop.collisionbox[4] + 0.5)
local dir_z = math_cos(yaw) * (prop.collisionbox[4] + 0.5)
local nod = core.get_node_or_nil({
local dir_x = -math.sin(yaw) * (prop.collisionbox[4] + 0.5)
local dir_z = math.cos(yaw) * (prop.collisionbox[4] + 0.5)
local nod = minetest.get_node_or_nil({
x = pos.x + dir_x,
y = pos.y + 0.5,
z = pos.z + dir_z
@ -182,8 +188,8 @@ mobs:register_mob("mobs_monster:spider", {
local v = self.object:get_velocity()
-- can only climb solid facings
if not nod or not core.registered_nodes[nod.name]
or not core.registered_nodes[nod.name].walkable then
if not nod or not minetest.registered_nodes[nod.name]
or not minetest.registered_nodes[nod.name].walkable then
self.disable_falling = nil
v.y = 0
self.object:set_velocity(v)
@ -198,9 +204,7 @@ mobs:register_mob("mobs_monster:spider", {
-- move up facing
v.x = 0 ; v.y = 0
v.y = self.jump_height
self:set_animation("jump")
mobs:set_animation(self, "jump")
self.object:set_velocity(v)
end,
@ -221,7 +225,6 @@ mobs:register_mob("mobs_monster:spider", {
end
})
-- where to spawn
if not mobs.custom_spawn_monster then
@ -236,7 +239,7 @@ if not mobs.custom_spawn_monster then
max_light = 8,
chance = 7000,
active_object_count = 1,
min_height = 2,
min_height = 25,
max_height = 31000
})
@ -253,18 +256,16 @@ if not mobs.custom_spawn_monster then
})
end
-- spawn egg
mobs:register_egg("mobs_monster:spider", S("Spider"), "mobs_cobweb.png", 1)
-- compatibility with older mobs mod
mobs:alias_mob("mobs_monster:spider2", "mobs_monster:spider")
mobs:alias_mob("mobs_monster:spider2", "mobs_monster:spider") -- compatibility
mobs:alias_mob("mobs:spider", "mobs_monster:spider")
-- cobweb and recipe
core.register_node(":mobs:cobweb", {
-- cobweb
minetest.register_node(":mobs:cobweb", {
description = S("Cobweb"),
drawtype = "plantlike",
visual_scale = 1.2,
@ -280,12 +281,11 @@ core.register_node(":mobs:cobweb", {
liquid_range = 0,
walkable = false,
groups = {snappy = 1, disable_jump = 1},
is_ground_content = false,
drop = "farming:string",
sounds = mobs.node_sound_leaves_defaults()
sounds = default and default.node_sound_leaves_defaults()
})
core.register_craft({
minetest.register_craft({
output = "mobs:cobweb",
recipe = {
{"farming:string", "", "farming:string"},
@ -294,21 +294,17 @@ core.register_craft({
}
})
-- cobweb place function
local web_place = function(pos)
if core.find_node_near(pos, 1, {"ignore"}) then return end
if minetest.find_node_near(pos, 1, {"ignore"}) then return end
local pos2 = core.find_node_near(pos, 1, {"air", "group:leaves"}, true)
local pos2 = minetest.find_node_near(pos, 1, {"air", "group:leaves"}, true)
if pos2 then
core.swap_node(pos2, {name = "mobs:cobweb"})
minetest.swap_node(pos2, {name = "mobs:cobweb"})
end
end
-- cobweb arrow
mobs:register_arrow("mobs_monster:cobweb", {
visual = "sprite",
visual_size = {x = 1, y = 1},
@ -343,3 +339,5 @@ mobs:register_arrow("mobs_monster:cobweb", {
}, nil)
end
})
minetest.register_alias("mobs:spider_cobweb", "mobs:cobweb")

View File

@ -1,7 +1,5 @@
-- translation and custom stone monster types
local S = core.get_translator("mobs_monster")
-- Translation support
local S = minetest.get_translator("mobs_monster")
local stone_types = {
@ -24,6 +22,7 @@ local stone_types = {
}
}
-- Stone Monster by PilzAdam
mobs:register_mob("mobs_monster:stone_monster", {
@ -44,7 +43,9 @@ mobs:register_mob("mobs_monster:stone_monster", {
{"mobs_stone_monster2.png"} -- by AMMOnym
},
makes_footstep_sound = true,
sounds = {random = "mobs_stonemonster"},
sounds = {
random = "mobs_stonemonster"
},
walk_velocity = 1,
run_velocity = 2,
jump_height = 0,
@ -54,17 +55,24 @@ mobs:register_mob("mobs_monster:stone_monster", {
drops = {
{name = "default:cobble", chance = 1, min = 0, max = 2},
{name = "default:coal_lump", chance = 3, min = 0, max = 2},
{name = "default:iron_lump", chance = 5, min = 0, max = 2}
{name = "default:iron_lump", chance = 5, min = 0, max = 2},
{name = "maptools:silver_coin", chance = 1, min = 0, max = 1},
{name = "default:torch", chance = 2, min = 3, max = 5},
},
water_damage = 0,
lava_damage = 1,
light_damage = 0,
animation = {
speed_normal = 15, speed_run = 15,
stand_start = 0, stand_end = 14,
walk_start = 15, walk_end = 38,
run_start = 40, run_end = 63,
punch_start = 40, punch_end = 63
speed_normal = 15,
speed_run = 15,
stand_start = 0,
stand_end = 14,
walk_start = 15,
walk_end = 38,
run_start = 40,
run_end = 63,
punch_start = 40,
punch_end = 63
},
immune_to = {
{"default:pick_wood", 0}, -- wooden pick doesnt hurt stone monster
@ -85,12 +93,14 @@ mobs:register_mob("mobs_monster:stone_monster", {
tmp = stone_types[n]
if core.find_node_near(pos, 1, tmp.nodes) then
if minetest.find_node_near(pos, 1, tmp.nodes) then
self.base_texture = tmp.skins
self.object:set_properties({textures = tmp.skins})
if tmp.drops then self.drops = tmp.drops end
if tmp.drops then
self.drops = tmp.drops
end
return true
end
@ -100,24 +110,20 @@ mobs:register_mob("mobs_monster:stone_monster", {
end
})
-- where to spawn
if not mobs.custom_spawn_monster then
mobs:spawn({
name = "mobs_monster:stone_monster",
nodes = {"default:stone", "default:desert_stone", "default:sandstone",
"default:permafrost_with_stones"},
nodes = {"default:stone", "default:desert_stone", "default:sandstone"},
max_light = 7,
chance = 7000,
max_height = 0
})
end
-- spawn egg
mobs:register_egg("mobs_monster:stone_monster", S("Stone Monster"), "default_stone.png", 1)
-- compatibility with older mobs mod
mobs:alias_mob("mobs:stone_monster", "mobs_monster:stone_monster")
mobs:alias_mob("mobs:stone_monster", "mobs_monster:stone_monster") -- compatibility

Binary file not shown.

After

Width:  |  Height:  |  Size: 456 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 310 B

BIN
textures/mobs_minotaur.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

BIN
textures/mobs_minotaur_eye.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 458 B

BIN
textures/mobs_minotaur_fur.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 252 B

BIN
textures/mobs_minotaur_horn.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 302 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 357 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 891 B

After

Width:  |  Height:  |  Size: 275 B

View File

Before

Width:  |  Height:  |  Size: 9.2 KiB

After

Width:  |  Height:  |  Size: 9.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

View File

@ -1,7 +1,5 @@
-- translation and custom tree monster types
local S = core.get_translator("mobs_monster")
-- Translation support
local S = minetest.get_translator("mobs_monster")
local tree_types = {
@ -22,7 +20,7 @@ local tree_types = {
{name = "ethereal:frost_leaves", chance = 1, min = 1, max = 2},
{name = "ethereal:frost_tree", chance = 2, min = 1, max = 2},
{name = "ethereal:crystal_spike", chance = 4, min = 0, max = 2}
}, glow = 1
}
},
{ nodes = {"ethereal:yellowleaves"},
@ -32,7 +30,7 @@ local tree_types = {
{name = "ethereal:yellowleaves", chance = 1, min = 1, max = 2},
{name = "ethereal:yellow_tree_sapling", chance = 2, min = 0, max = 2},
{name = "ethereal:golden_apple", chance = 3, min = 0, max = 2}
}, glow = 1
}
},
{ nodes = {"default:acacia_bush_leaves"},
@ -46,6 +44,7 @@ local tree_types = {
}
}
-- Tree Monster (or Tree Gollum) by PilzAdam
mobs:register_mob("mobs_monster:tree_monster", {
@ -68,7 +67,9 @@ mobs:register_mob("mobs_monster:tree_monster", {
},
blood_texture = "default_wood.png",
makes_footstep_sound = true,
sounds = {random = "mobs_treemonster"},
sounds = {
random = "mobs_treemonster"
},
walk_velocity = 1,
run_velocity = 3,
jump = true,
@ -77,7 +78,9 @@ mobs:register_mob("mobs_monster:tree_monster", {
{name = "default:stick", chance = 1, min = 0, max = 2},
{name = "default:sapling", chance = 2, min = 0, max = 2},
{name = "default:junglesapling", chance = 3, min = 0, max = 2},
{name = "default:apple", chance = 4, min = 1, max = 2}
{name = "default:apple", chance = 4, min = 1, max = 2},
{name = "maptools:superapple", chance = 4, min = 0, max = 1,},
{name = "maptools:silver_coin", chance = 3, min = 0, max = 1,},
},
water_damage = 0,
lava_damage = 0,
@ -95,11 +98,16 @@ mobs:register_mob("mobs_monster:tree_monster", {
-- {"all", 0}, -- only weapons on list deal damage
},
animation = {
speed_normal = 15, speed_run = 15,
stand_start = 0, stand_end = 24,
walk_start = 25, walk_end = 47,
run_start = 48, run_end = 62,
punch_start = 48, punch_end = 62
speed_normal = 15,
speed_run = 15,
stand_start = 0,
stand_end = 24,
walk_start = 25,
walk_end = 47,
run_start = 48,
run_end = 62,
punch_start = 48,
punch_end = 62
},
-- check surrounding nodes and spawn a specific tree monster
@ -114,17 +122,16 @@ mobs:register_mob("mobs_monster:tree_monster", {
if tmp.explode and math.random(2) == 1 then return true end
if core.find_node_near(pos, 1, tmp.nodes) then
if minetest.find_node_near(pos, 1, tmp.nodes) then
self.base_texture = tmp.skins
self.object:set_properties({textures = tmp.skins})
if tmp.glow then self.object:set_properties({glow = tmp.glow}) end
if tmp.drops then self.drops = tmp.drops end
if tmp.drops then
self.drops = tmp.drops
end
if tmp.explode then
self.attack_type = "explode"
self.explosion_radius = 3
self.explosion_timer = 3
@ -151,7 +158,6 @@ mobs:register_mob("mobs_monster:tree_monster", {
end
})
-- where to spawn
if not mobs.custom_spawn_monster then
@ -165,10 +171,8 @@ if not mobs.custom_spawn_monster then
})
end
-- spawn egg
mobs:register_egg("mobs_monster:tree_monster", S("Tree Monster"), "default_tree_top.png", 1)
-- compatibility with older mobs mod
mobs:alias_mob("mobs:tree_monster", "mobs_monster:tree_monster")
mobs:alias_mob("mobs:tree_monster", "mobs_monster:tree_monster") -- compatibility