integrates fire spirit from mobs_monster of tenplus1
* also added missing depends on tnt and fire cos we used some things
This commit is contained in:
parent
571de2de96
commit
7c00897d4e
@ -2,3 +2,5 @@ mobs
|
||||
default?
|
||||
lucky_block?
|
||||
intllib?
|
||||
tnt?
|
||||
fire?
|
105
fire_spirit.lua
Normal file
105
fire_spirit.lua
Normal file
@ -0,0 +1,105 @@
|
||||
|
||||
local S = mobs.intllib_animal
|
||||
|
||||
local mob_drops = {
|
||||
{name = "fireflies:firefly", chance = 1, min = 1, max = 1}
|
||||
}
|
||||
|
||||
if minetest.get_modpath("ethereal") then
|
||||
|
||||
table.insert(mob_drops,
|
||||
{name = "ethereal:fire_dust", chance = 1, min = 1, max = 1})
|
||||
end
|
||||
|
||||
-- Fire Spirit
|
||||
|
||||
mobs:register_mob(":mobs_monster:fire_spirit", {
|
||||
type = "monster",
|
||||
passive = false,
|
||||
attack_type = "dogfight",
|
||||
pathfinding = true,
|
||||
reach = 2,
|
||||
damage = 4,
|
||||
hp_min = 25,
|
||||
hp_max = 45,
|
||||
armor = 100,
|
||||
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"}
|
||||
},
|
||||
glow = 14,
|
||||
blood_texture = "fire_basic_flame.png",
|
||||
immune_to = {
|
||||
{"bucket:bucket_water", 1},
|
||||
{"bucket:bucket_river_water", 1},
|
||||
{"all"}
|
||||
},
|
||||
makes_footstep_sound = false,
|
||||
sounds = {
|
||||
random = "fire_fire",
|
||||
damage = "fire_extinguish_flame",
|
||||
death = "fire_extinguish_flame"
|
||||
},
|
||||
view_range = 14,
|
||||
walk_velocity = 2,
|
||||
run_velocity = 3,
|
||||
jump = true,
|
||||
jump_height = 6,
|
||||
drops = mob_drops,
|
||||
water_damage = 1,
|
||||
lava_damage = 0,
|
||||
fire_damage = 0,
|
||||
light_damage = 0,
|
||||
fall_damage = false,
|
||||
fear_height = 8,
|
||||
animation = {},
|
||||
|
||||
on_die = function(self, pos)
|
||||
|
||||
mobs:effect(pos, 20, "tnt_smoke.png", 3, 5, 2, 0.5, nil, false)
|
||||
|
||||
self.object:remove()
|
||||
end,
|
||||
|
||||
do_custom = function(self, dtime)
|
||||
|
||||
self.flame_timer = (self.flame_timer or 0) + dtime
|
||||
|
||||
if self.flame_timer < 0.25 then
|
||||
return
|
||||
end
|
||||
|
||||
self.flame_timer = 0
|
||||
|
||||
local pos = self.object:get_pos()
|
||||
|
||||
-- pos, amount, texture, min_size, max_size, radius, gravity, glow, fall
|
||||
mobs:effect(pos, 5, "fire_basic_flame.png", 1, 2, 0.1, 0.2, 14, nil)
|
||||
end
|
||||
})
|
||||
|
||||
|
||||
local spawnon = {"default:obsidian"}
|
||||
|
||||
if minetest.get_modpath("caverealms") then
|
||||
spawnon = {"default:obsidian", "caverealms:hot_cobble"}
|
||||
end
|
||||
|
||||
if not mobs.custom_spawn_monster then
|
||||
|
||||
mobs:spawn({
|
||||
name = ":mobs_monster:fire_spirit",
|
||||
nodes = spawnon,
|
||||
neighbors = {"group:fire"},
|
||||
min_light = 12,
|
||||
max_light = 15,
|
||||
chance = 1500,
|
||||
active_object_count = 1,
|
||||
max_height = -150
|
||||
})
|
||||
end
|
||||
|
||||
|
||||
mobs:register_egg(":mobs_monster:fire_spirit", S("Fire Spirit"), "fire_basic_flame.png", 1)
|
1
init.lua
1
init.lua
@ -52,6 +52,7 @@ dofile(path .. "fox.lua") -- D00Med
|
||||
dofile(path .. "owl.lua") -- D00Med
|
||||
dofile(path .. "tortoise.lua") -- D00Med
|
||||
|
||||
dofile(path .. "fire_spirit.lua") -- tenplus1
|
||||
|
||||
-- Load custom spawning
|
||||
if mobs.custom_spawn_animal then
|
||||
|
2
mod.conf
2
mod.conf
@ -1,4 +1,4 @@
|
||||
name = mobs_jam
|
||||
depends = mobs
|
||||
optional_depends = default, lucky_block, intllib
|
||||
optional_depends = default, lucky_block, intllib, tnt, fire
|
||||
description = MOBS mod of animals, monters and extra, reduced version from tenplush1 and others mods
|
||||
|
@ -71,4 +71,10 @@ These were extracted from dmobs mod and spawns at the leaves or trees, will rest
|
||||
### Fox
|
||||
These were extracted from dmobs mod, its aggressive and will not leave you from attack
|
||||
|
||||
### Fire Spirit
|
||||
|
||||
Fire Spirits will not tolerate players roaming around their domain and will fiercely attack until their dying puff of smoke. Th
|
||||
ey will drop their spirit and some fire dust when using ethereal.
|
||||
|
||||
|
||||
#### Lucky Blocks: 20
|
||||
|
BIN
textures/mobs_fire_spirit.png
Normal file
BIN
textures/mobs_fire_spirit.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 274 B |
Loading…
x
Reference in New Issue
Block a user