code tidy (part 2)

This commit is contained in:
tenplus1 2022-09-28 10:41:38 +01:00
parent c728e35050
commit 8086043b13
52 changed files with 485 additions and 415 deletions

View File

@ -18,7 +18,7 @@ mobs:register_mob("nssm:ant_queen", {
rotate = 270, rotate = 270,
sounds = { sounds = {
random = "ant", random = "ant",
attack = "ant", attack = "ant"
}, },
damage = 4, damage = 4,
jump = true, jump = true,
@ -51,7 +51,7 @@ mobs:register_mob("nssm:ant_queen", {
run_start = 120, run_start = 120,
run_end = 160, run_end = 160,
punch_start = 170, punch_start = 170,
punch_end = 190, punch_end = 190
}, },
custom_attack = function(self) custom_attack = function(self)
@ -76,7 +76,7 @@ mobs:register_mob("nssm:ant_queen", {
minetest.sound_play(self.sounds.attack, { minetest.sound_play(self.sounds.attack, {
object = self.object, object = self.object,
max_hear_distance = self.sounds.distance max_hear_distance = self.sounds.distance
}) }, true)
end end
local pos1 = { local pos1 = {
@ -95,7 +95,7 @@ mobs:register_mob("nssm:ant_queen", {
end end
end end
if ((pos1.x~=s.x) and (pos1.z~=s.z)) if ((pos1.x ~= s.x) and (pos1.z ~= s.z))
and (minetest.get_node(pos1).name == "air") and (minetest.get_node(pos1).name == "air")
and (counter < 4) then and (counter < 4) then

View File

@ -16,7 +16,7 @@ mobs:register_mob("nssm:ant_soldier", {
run_velocity = 3, run_velocity = 3,
rotate = 270, rotate = 270,
sounds = { sounds = {
random = "ant", random = "ant"
}, },
damage = 6, damage = 6,
jump = true, jump = true,
@ -24,7 +24,7 @@ mobs:register_mob("nssm:ant_soldier", {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:ant_leg", chance = 2, min = 1, max = 6}, {name = "nssm:ant_leg", chance = 2, min = 1, max = 6},
{name = "nssm:ant_mandible", chance = 3, min = 1, max = 2}, {name = "nssm:ant_mandible", chance = 3, min = 1, max = 2},
{name = "nssm:ant_hard_skin", chance = 3, min = 1, max = 2}, {name = "nssm:ant_hard_skin", chance = 3, min = 1, max = 2}
}, },
reach = 2, reach = 2,
armor = 70, armor = 70,
@ -49,6 +49,6 @@ mobs:register_mob("nssm:ant_soldier", {
run_start = 90, run_start = 90,
run_end = 130, run_end = 130,
punch_start = 60, punch_start = 60,
punch_end = 80, punch_end = 80
} }
}) })

View File

@ -17,7 +17,7 @@ mobs:register_mob("nssm:ant_worker", {
run_velocity = 2, run_velocity = 2,
rotate = 270, rotate = 270,
sounds = { sounds = {
random = "ant", random = "ant"
}, },
damage = 2, damage = 2,
reach = 2, reach = 2,
@ -26,7 +26,7 @@ mobs:register_mob("nssm:ant_worker", {
{name = "nssm:life_energy", chance = 2, min = 1, max = 1}, {name = "nssm:life_energy", chance = 2, min = 1, max = 1},
{name = "nssm:ant_leg", chance = 2, min = 1, max = 6}, {name = "nssm:ant_leg", chance = 2, min = 1, max = 6},
{name = "nssm:ant_mandible", chance = 3, min = 1, max = 2}, {name = "nssm:ant_mandible", chance = 3, min = 1, max = 2},
{name = "nssm:ant_hard_skin", chance = 3, min = 1, max = 2}, {name = "nssm:ant_hard_skin", chance = 3, min = 1, max = 2}
}, },
armor = 70, armor = 70,
drawtype = "front", drawtype = "front",
@ -49,6 +49,6 @@ mobs:register_mob("nssm:ant_worker", {
run_start = 120, run_start = 120,
run_end = 160, run_end = 160,
punch_start = 50, punch_start = 50,
punch_end = 70, punch_end = 70
} }
}) })

View File

@ -16,7 +16,7 @@ mobs:register_mob("nssm:black_widow", {
run_velocity = 2.5, run_velocity = 2.5,
rotate = 270, rotate = 270,
sounds = { sounds = {
random = "black_widow", random = "black_widow"
}, },
damage = 4, damage = 4,
reach = 2, reach = 2,
@ -25,7 +25,7 @@ mobs:register_mob("nssm:black_widow", {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:spider_leg", chance = 3, min = 1, max = 8}, {name = "nssm:spider_leg", chance = 3, min = 1, max = 8},
{name = "nssm:silk_gland", chance = 4, min = 1, max = 3}, {name = "nssm:silk_gland", chance = 4, min = 1, max = 3},
{name = "nssm:spider_meat", chance = 4, min = 1, max = 2}, {name = "nssm:spider_meat", chance = 4, min = 1, max = 2}
}, },
armor = 70, armor = 70,
drawtype = "front", drawtype = "front",
@ -49,9 +49,10 @@ mobs:register_mob("nssm:black_widow", {
run_start = 120, run_start = 120,
run_end = 140, run_end = 140,
punch_start = 150, punch_start = 150,
punch_end = 160, punch_end = 160
}, },
do_custom = function(self) do_custom = function(self)
webber_ability(self, "nssm:web", 2) webber_ability(self, "nssm:web", 2)
end, end
}) })

View File

@ -16,7 +16,7 @@ mobs:register_mob("nssm:bloco", {
run_velocity = 2.5, run_velocity = 2.5,
rotate = 270, rotate = 270,
sounds = { sounds = {
random = "bloco", random = "bloco"
}, },
damage = 4, damage = 4,
reach = 2, reach = 2,
@ -24,7 +24,7 @@ mobs:register_mob("nssm:bloco", {
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 1}, {name = "nssm:life_energy", chance = 1, min = 1, max = 1},
{name = "default:stone", chance = 1, min = 2, max = 3}, {name = "default:stone", chance = 1, min = 2, max = 3},
{name = "nssm:bloco_skin", chance = 3, min = 1, max = 2}, {name = "nssm:bloco_skin", chance = 3, min = 1, max = 2}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -37,12 +37,12 @@ mobs:register_mob("nssm:bloco", {
knock_back = 0, knock_back = 0,
blood_texture = "stone_blood.png", blood_texture = "stone_blood.png",
immune_to = { immune_to = {
{'default:sword_stone', -2}, {"default:sword_stone", -2},
{'default:stone', -2}, {"default:stone", -2},
{'default:cobble', -2}, {"default:cobble", -2},
{'default:axe_stone', -2}, {"default:axe_stone", -2},
{'default:shovel_stone', -2}, {"default:shovel_stone", -2},
{'default:pick_stone', -2} {"default:pick_stone", -2}
}, },
stepheight = 1.1, stepheight = 1.1,
attack_type = "dogfight", attack_type = "dogfight",
@ -56,6 +56,6 @@ mobs:register_mob("nssm:bloco", {
run_start = 120, run_start = 120,
run_end = 160, run_end = 160,
punch_start = 170, punch_start = 170,
punch_end = 190, punch_end = 190
} }
}) })

View File

@ -10,7 +10,7 @@ mobs:register_mob("nssm:crab", {
{"crab2.png"} {"crab2.png"}
}, },
sounds = { sounds = {
random = "crab", random = "crab"
}, },
visual_size = {x = 3, y = 3}, visual_size = {x = 3, y = 3},
makes_footstep_sound = true, makes_footstep_sound = true,
@ -27,7 +27,7 @@ mobs:register_mob("nssm:crab", {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:surimi", chance = 1, min = 1, max = 2}, {name = "nssm:surimi", chance = 1, min = 1, max = 2},
{name = "nssm:crab_chela", chance = 4, min = 1, max = 2}, {name = "nssm:crab_chela", chance = 4, min = 1, max = 2},
{name = "nssm:crab_carapace_fragment", chance = 4, min = 1, max = 1}, {name = "nssm:crab_carapace_fragment", chance = 4, min = 1, max = 1}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -51,6 +51,6 @@ mobs:register_mob("nssm:crab", {
run_start = 120, run_start = 120,
run_end = 140, run_end = 140,
punch_start = 90, punch_start = 90,
punch_end = 110, punch_end = 110
} }
}) })

View File

@ -22,7 +22,7 @@ mobs:register_mob("nssm:crocodile", {
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:crocodile_tail", chance = 2, min = 1, max = 1}, {name = "nssm:crocodile_tail", chance = 2, min = 1, max = 1},
{name = "nssm:crocodile_skin", chance = 3, min = 1, max = 1}, {name = "nssm:crocodile_skin", chance = 3, min = 1, max = 1}
}, },
armor = 60, armor = 60,
drawtype = "front", drawtype = "front",

View File

@ -16,14 +16,14 @@ mobs:register_mob("nssm:daddy_long_legs", {
run_velocity = 3.3, run_velocity = 3.3,
rotate = 90, rotate = 90,
sounds = { sounds = {
random = "daddy", random = "daddy"
}, },
damage = 3, damage = 3,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:spider_leg", chance = 3, min = 1, max = 8}, {name = "nssm:spider_leg", chance = 3, min = 1, max = 8},
{name = "nssm:spider_meat", chance = 4, min = 1, max = 2}, {name = "nssm:spider_meat", chance = 4, min = 1, max = 2}
}, },
armor = 70, armor = 70,
drawtype = "front", drawtype = "front",
@ -47,6 +47,6 @@ mobs:register_mob("nssm:daddy_long_legs", {
run_start = 80, run_start = 80,
run_end = 120, run_end = 120,
punch_start = 140, punch_start = 140,
punch_end = 165, punch_end = 165
} }
}) })

View File

@ -26,11 +26,11 @@ mobs:register_mob("nssm:dolidrosaurus", {
jump_chance = 0, jump_chance = 0,
jump_height = 0, jump_height = 0,
sounds = { sounds = {
random = "crocod", random = "crocod"
}, },
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 3}, {name = "nssm:life_energy", chance = 1, min = 1, max = 3},
{name = "nssm:dolidrosaurus_fin", chance = 2, min = 1, max = 3}, {name = "nssm:dolidrosaurus_fin", chance = 2, min = 1, max = 3}
}, },
armor = 60, armor = 60,
drawtype = "front", drawtype = "front",
@ -54,6 +54,6 @@ mobs:register_mob("nssm:dolidrosaurus", {
run_start = 140, run_start = 140,
run_end = 180, run_end = 180,
punch_start = 190, punch_start = 190,
punch_end = 220, punch_end = 220
} }
}) })

View File

@ -17,13 +17,13 @@ mobs:register_mob("nssm:duck", {
damage = 2, damage = 2,
jump = true, jump = true,
sounds = { sounds = {
random = "duck", random = "duck"
}, },
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 1}, {name = "nssm:life_energy", chance = 1, min = 1, max = 1},
{name = "nssm:duck_legs", chance = 1, min = 1, max = 2}, {name = "nssm:duck_legs", chance = 1, min = 1, max = 2},
{name = "nssm:duck_beak", chance = 5, min = 1, max = 1}, {name = "nssm:duck_beak", chance = 5, min = 1, max = 1},
{name = "nssm:duck_feather", chance = 3, min = 2, max = 4}, {name = "nssm:duck_feather", chance = 3, min = 2, max = 4}
}, },
armor = 100, armor = 100,
drawtype = "front", drawtype = "front",
@ -48,6 +48,6 @@ mobs:register_mob("nssm:duck", {
run_start = 20, run_start = 20,
run_end = 40, run_end = 40,
punch_start = 40, punch_start = 40,
punch_end = 60, punch_end = 60
} }
}) })

View File

@ -21,14 +21,14 @@ mobs:register_mob("nssm:duckking", {
jump = true, jump = true,
sounds = { sounds = {
random = "duckking", random = "duckking",
attack = "duckking", attack = "duckking"
}, },
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 7, max = 8}, {name = "nssm:life_energy", chance = 1, min = 7, max = 8},
{name = "nssm:duck_legs", chance = 1, min = 40, max = 50}, {name = "nssm:duck_legs", chance = 1, min = 40, max = 50},
{name = "nssm:helmet_crown", chance = 1, min = 1, max = 1}, {name = "nssm:helmet_crown", chance = 1, min = 1, max = 1},
{name = "nssm:duck_beak", chance = 4, min = 10, max = 20}, {name = "nssm:duck_beak", chance = 4, min = 10, max = 20},
{name = "nssm:duck_feather", chance = 3, min = 20, max = 40}, {name = "nssm:duck_feather", chance = 3, min = 20, max = 40}
}, },
armor = 50, armor = 50,
drawtype = "front", drawtype = "front",
@ -60,6 +60,6 @@ mobs:register_mob("nssm:duckking", {
punch_start = 190, punch_start = 190,
punch_end = 220, punch_end = 220,
shoot_start = 160, shoot_start = 160,
shoot_end = 180, shoot_end = 180
} }
}) })

View File

@ -19,11 +19,11 @@ mobs:register_mob("nssm:echidna", {
damage = 12, damage = 12,
jump = true, jump = true,
sounds = { sounds = {
random = "echidna", random = "echidna"
}, },
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 6, max = 7}, {name = "nssm:life_energy", chance = 1, min = 6, max = 7},
{name = "nssm:snake_scute", chance = 1, min = 1, max = 1}, {name = "nssm:snake_scute", chance = 1, min = 1, max = 1}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -39,7 +39,7 @@ mobs:register_mob("nssm:echidna", {
jump_height = 8, jump_height = 8,
attack_type = "dogshoot", attack_type = "dogshoot",
dogshoot_switch = true, dogshoot_switch = true,
arrow = "nssm:super_gas"; arrow = "nssm:super_gas",
reach = 5, reach = 5,
shoot_interval = 3, shoot_interval = 3,
animation = { animation = {
@ -54,6 +54,6 @@ mobs:register_mob("nssm:echidna", {
punch_start = 160, punch_start = 160,
punch_end = 190, punch_end = 190,
shoot_start = 200, shoot_start = 200,
shoot_end = 240, shoot_end = 240
} }
}) })

View File

@ -16,7 +16,7 @@ mobs:register_mob("nssm:enderduck", {
run_velocity = 3.9, run_velocity = 3.9,
rotate = 270, rotate = 270,
sounds = { sounds = {
random = "duck", random = "duck"
}, },
damage = 5, damage = 5,
reach = 2, reach = 2,
@ -25,7 +25,7 @@ mobs:register_mob("nssm:enderduck", {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:duck_legs", chance = 1, min = 1, max = 2}, {name = "nssm:duck_legs", chance = 1, min = 1, max = 2},
{name = "nssm:black_duck_feather", chance = 3, min = 1, max = 4}, {name = "nssm:black_duck_feather", chance = 3, min = 1, max = 4},
{name = "nssm:duck_beak", chance = 5, min = 1, max = 1}, {name = "nssm:duck_beak", chance = 5, min = 1, max = 1}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -51,6 +51,6 @@ mobs:register_mob("nssm:enderduck", {
run_start = 100, run_start = 100,
run_end = 130, run_end = 130,
punch_start = 60, punch_start = 60,
punch_end = 90, punch_end = 90
} }
}) })

View File

@ -15,7 +15,7 @@ mobs:register_mob("nssm:felucco", {
fear_height = 4, fear_height = 4,
run_velocity = 5, run_velocity = 5,
sounds = { sounds = {
random = "felucco", random = "felucco"
}, },
damage = 5, damage = 5,
jump = true, jump = true,
@ -23,7 +23,7 @@ mobs:register_mob("nssm:felucco", {
{name = "nssm:life_energy", chance = 1, min = 3, max = 4}, {name = "nssm:life_energy", chance = 1, min = 3, max = 4},
{name = "nssm:felucco_steak", chance = 2, min = 1, max = 2}, {name = "nssm:felucco_steak", chance = 2, min = 1, max = 2},
{name = "nssm:felucco_fur", chance = 2, min = 1, max = 1}, {name = "nssm:felucco_fur", chance = 2, min = 1, max = 1},
{name = "nssm:felucco_horn", chance = 3, min = 1, max = 2}, {name = "nssm:felucco_horn", chance = 3, min = 1, max = 2}
}, },
armor = 70, armor = 70,
drawtype = "front", drawtype = "front",
@ -47,6 +47,6 @@ mobs:register_mob("nssm:felucco", {
run_start = 140, run_start = 140,
run_end = 160, run_end = 160,
punch_start = 200, punch_start = 200,
punch_end = 240, punch_end = 240
} }
}) })

View File

@ -15,7 +15,7 @@ mobs:register_mob("nssm:flying_duck", {
fall_speed = 0, fall_speed = 0,
stepheight = 3, stepheight = 3,
sounds = { sounds = {
random = "duck", random = "duck"
}, },
damage = 3, damage = 3,
reach = 2, reach = 2,
@ -24,7 +24,7 @@ mobs:register_mob("nssm:flying_duck", {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:duck_legs", chance = 2, min = 1, max = 2}, {name = "nssm:duck_legs", chance = 2, min = 1, max = 2},
{name = "nssm:duck_beak", chance = 5, min = 1, max = 1}, {name = "nssm:duck_beak", chance = 5, min = 1, max = 1},
{name = "nssm:duck_feather", chance = 2, min = 4, max = 8}, {name = "nssm:duck_feather", chance = 2, min = 4, max = 8}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -48,6 +48,6 @@ mobs:register_mob("nssm:flying_duck", {
run_start = 160, run_start = 160,
run_end = 220, run_end = 220,
punch_start = 110, punch_start = 110,
punch_end = 140, punch_end = 140
} }
}) })

View File

@ -21,7 +21,7 @@ mobs:register_mob("nssm:giant_sandworm", {
{name = "nssm:worm_flesh", chance = 1, min = 20, max = 30}, {name = "nssm:worm_flesh", chance = 1, min = 20, max = 30},
{name = "nssm:sandworm_skin", chance = 2, min = 3, max = 12}, {name = "nssm:sandworm_skin", chance = 2, min = 3, max = 12},
{name = "nssm:life_energy", chance = 1, min = 7, max = 8}, {name = "nssm:life_energy", chance = 1, min = 7, max = 8},
{name = "nssm:digested_sand", chance = 1, min = 1, max = 1}, {name = "nssm:digested_sand", chance = 1, min = 1, max = 1}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -44,6 +44,6 @@ mobs:register_mob("nssm:giant_sandworm", {
run_start = 110, run_start = 110,
run_end = 140, run_end = 140,
punch_start = 150, punch_start = 150,
punch_end = 180, punch_end = 180
}, }
}) })

View File

@ -16,7 +16,7 @@ mobs:register_mob("nssm:icelamander", {
walk_velocity = 2, walk_velocity = 2,
run_velocity = 4, run_velocity = 4,
sounds = { sounds = {
random = "icelamander", random = "icelamander"
}, },
damage = 12, damage = 12,
jump = true, jump = true,
@ -25,7 +25,7 @@ mobs:register_mob("nssm:icelamander", {
{name = "nssm:frosted_amphibian_heart", chance = 1, min = 1, max = 1}, {name = "nssm:frosted_amphibian_heart", chance = 1, min = 1, max = 1},
{name = "nssm:ice_tooth", chance = 1, min = 1, max = 1}, {name = "nssm:ice_tooth", chance = 1, min = 1, max = 1},
{name = "nssm:little_ice_tooth", chance = 1, min = 0, max = 20}, {name = "nssm:little_ice_tooth", chance = 1, min = 0, max = 20},
{name = "nssm:amphibian_ribs", chance = 2, min = 1, max = 1}, {name = "nssm:amphibian_ribs", chance = 2, min = 1, max = 1}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -55,9 +55,10 @@ mobs:register_mob("nssm:icelamander", {
punch_start = 160, punch_start = 160,
punch_end = 190, punch_end = 190,
shoot_start = 190, shoot_start = 190,
shoot_end = 210, shoot_end = 210
}, },
do_custom = function(self) do_custom = function(self)
midas_ability(self, "default:ice", self.run_velocity, 1, 3) midas_ability(self, "default:ice", self.run_velocity, 1, 3)
end, end
}) })

View File

@ -16,7 +16,7 @@ mobs:register_mob("nssm:icesnake", {
walk_velocity = 1.2, walk_velocity = 1.2,
run_velocity = 3, run_velocity = 3,
sounds = { sounds = {
random = "icesnake", random = "icesnake"
}, },
damage = 4, damage = 4,
reach = 2, reach = 2,
@ -25,7 +25,7 @@ mobs:register_mob("nssm:icesnake", {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:frosted_amphibian_heart", chance = 2, min = 1, max = 1}, {name = "nssm:frosted_amphibian_heart", chance = 2, min = 1, max = 1},
{name = "nssm:little_ice_tooth", chance = 2, min = 0, max = 4}, {name = "nssm:little_ice_tooth", chance = 2, min = 0, max = 4},
{name = "nssm:amphibian_ribs", chance = 2, min = 1, max = 3}, {name = "nssm:amphibian_ribs", chance = 2, min = 1, max = 3}
}, },
armor = 70, armor = 70,
drawtype = "front", drawtype = "front",
@ -49,9 +49,10 @@ mobs:register_mob("nssm:icesnake", {
run_start = 80, run_start = 80,
run_end = 120, run_end = 120,
punch_start = 130, punch_start = 130,
punch_end = 160, punch_end = 160
}, },
do_custom = function(self) do_custom = function(self)
putting_ability(self, "default:ice", self.run_velocity) putting_ability(self, "default:ice", self.run_velocity)
end, end
}) })

View File

@ -24,12 +24,12 @@ mobs:register_mob("nssm:kraken", {
jump_chance = 0, jump_chance = 0,
jump_height = 0, jump_height = 0,
sounds = { sounds = {
random = "kraken", random = "kraken"
}, },
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 6, max = 7}, {name = "nssm:life_energy", chance = 1, min = 6, max = 7},
{name = "nssm:tentacle", chance = 1, min = 30, max = 40}, {name = "nssm:tentacle", chance = 1, min = 30, max = 40},
{name = "nssm:tentacle_curly", chance = 1, min = 1, max = 1}, {name = "nssm:tentacle_curly", chance = 1, min = 1, max = 1}
}, },
armor = 50, armor = 50,
drawtype = "front", drawtype = "front",
@ -52,6 +52,6 @@ mobs:register_mob("nssm:kraken", {
run_start = 60, run_start = 60,
run_end = 100, run_end = 100,
punch_start = 120, punch_start = 120,
punch_end = 150, punch_end = 150
} }
}) })

View File

@ -18,13 +18,13 @@ mobs:register_mob("nssm:larva", {
walk_velocity = 0.4, walk_velocity = 0.4,
run_velocity = 0.4, run_velocity = 0.4,
sounds = { sounds = {
random = "sand", random = "sand"
}, },
damage = 1, damage = 1,
reach = 1, reach = 1,
drops = { drops = {
{name = "nssm:life_energy", chance = 3, min = 1, max = 1}, {name = "nssm:life_energy", chance = 3, min = 1, max = 1},
{name = "nssm:larva_meat", chance = 2, min = 1, max = 2}, {name = "nssm:larva_meat", chance = 2, min = 1, max = 2}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -47,7 +47,7 @@ mobs:register_mob("nssm:larva", {
run_start = 100, run_start = 100,
run_end = 160, run_end = 160,
punch_start = 180, punch_start = 180,
punch_end = 230, punch_end = 230
}, },
do_custom = function (self) do_custom = function (self)
@ -56,8 +56,7 @@ mobs:register_mob("nssm:larva", {
if os.time() - self.metatimer > 20 then if os.time() - self.metatimer > 20 then
minetest.log("action", minetest.log("action", "metatimer expired, metamorphosis!")
"metatimer expired, metamorphosis! ")
local pos = self.object:get_pos() local pos = self.object:get_pos()

View File

@ -17,7 +17,7 @@ mobs:register_mob("nssm:lava_titan", {
run_velocity = 1.3, run_velocity = 1.3,
floats = 1, floats = 1,
sounds = { sounds = {
random = "lava_titan", random = "lava_titan"
}, },
damage = 8, damage = 8,
jump = false, jump = false,
@ -25,7 +25,7 @@ mobs:register_mob("nssm:lava_titan", {
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 7, max = 9}, {name = "nssm:life_energy", chance = 1, min = 7, max = 9},
{name = "nssm:lava_titan_eye", chance = 1, min = 1, max = 1}, {name = "nssm:lava_titan_eye", chance = 1, min = 1, max = 1},
{name = "bucket:bucket_lava", chance = 2, min = 1, max = 3}, {name = "bucket:bucket_lava", chance = 2, min = 1, max = 3}
}, },
armor = 20, armor = 20,
drawtype = "front", drawtype = "front",
@ -70,9 +70,10 @@ mobs:register_mob("nssm:lava_titan", {
run_end = 110, run_end = 110,
punch_start = 301, punch_start = 301,
punch_end = 340, punch_end = 340,
shoot_start =340, shoot_start = 340,
shoot_end=400, shoot_end = 400
}, },
do_custom = function (self) do_custom = function (self)
digging_attack(self, nil, self.run_velocity, {x = 0, y = 4, z = 0}) digging_attack(self, nil, self.run_velocity, {x = 0, y = 4, z = 0})
--digging_ability(self, nil, self.run_velocity, {x=0, y=5, z=0}) --digging_ability(self, nil, self.run_velocity, {x=0, y=5, z=0})

View File

@ -15,14 +15,14 @@ mobs:register_mob("nssm:manticore", {
walk_velocity = 2, walk_velocity = 2,
run_velocity = 4, run_velocity = 4,
sounds = { sounds = {
random = "manticore", random = "manticore"
}, },
damage = 6, damage = 6,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 3, max = 4}, {name = "nssm:life_energy", chance = 1, min = 3, max = 4},
{name = "nssm:manticore_spine", chance = 3, min = 2, max = 5}, {name = "nssm:manticore_spine", chance = 3, min = 2, max = 5},
{name = "nssm:manticore_fur", chance = 3, min = 1, max = 2}, {name = "nssm:manticore_fur", chance = 3, min = 1, max = 2}
}, },
armor = 60, armor = 60,
drawtype = "front", drawtype = "front",
@ -53,6 +53,6 @@ mobs:register_mob("nssm:manticore", {
punch_start = 110, punch_start = 110,
punch_end = 143, punch_end = 143,
shoot_start = 180, shoot_start = 180,
shoot_end=230, shoot_end = 230
} }
}) })

View File

@ -16,7 +16,7 @@ mobs:register_mob("nssm:mantis", {
walk_velocity = 2, walk_velocity = 2,
run_velocity = 2.5, run_velocity = 2.5,
sounds = { sounds = {
random = "manti", random = "manti"
}, },
damage = 4, damage = 4,
jump = true, jump = true,
@ -24,7 +24,7 @@ mobs:register_mob("nssm:mantis", {
{name = "nssm:mantis_claw", chance = 2, min = 1, max = 4}, {name = "nssm:mantis_claw", chance = 2, min = 1, max = 4},
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:mantis_skin", chance = 3, min = 1, max = 2}, {name = "nssm:mantis_skin", chance = 3, min = 1, max = 2},
{name = "nssm:mantis_meat", chance = 2, min = 1, max = 2}, {name = "nssm:mantis_meat", chance = 2, min = 1, max = 2}
}, },
armor = 70, armor = 70,
drawtype = "front", drawtype = "front",
@ -51,6 +51,6 @@ mobs:register_mob("nssm:mantis", {
punch_start = 120, punch_start = 120,
punch_end = 140, punch_end = 140,
punch2_start = 145, punch2_start = 145,
punch2_end = 165, punch2_end = 165
} }
}) })

View File

@ -16,7 +16,7 @@ mobs:register_mob("nssm:mantis_beast", {
walk_velocity = 2.5, walk_velocity = 2.5,
run_velocity = 3.5, run_velocity = 3.5,
sounds = { sounds = {
random = "manti", random = "manti"
}, },
damage = 5, damage = 5,
reach = 2, reach = 2,
@ -25,7 +25,7 @@ mobs:register_mob("nssm:mantis_beast", {
{name = "nssm:mantis_claw", chance = 2, min = 1, max = 6}, {name = "nssm:mantis_claw", chance = 2, min = 1, max = 6},
{name = "nssm:life_energy", chance = 1, min = 2, max = 3}, {name = "nssm:life_energy", chance = 1, min = 2, max = 3},
{name = "nssm:mantis_skin", chance = 3, min = 1, max = 2}, {name = "nssm:mantis_skin", chance = 3, min = 1, max = 2},
{name = "nssm:mantis_meat", chance = 2, min = 1, max = 2}, {name = "nssm:mantis_meat", chance = 2, min = 1, max = 2}
}, },
armor = 70, armor = 70,
drawtype = "front", drawtype = "front",
@ -49,6 +49,6 @@ mobs:register_mob("nssm:mantis_beast", {
run_start = 70, run_start = 70,
run_end = 110, run_end = 110,
punch_start = 140, punch_start = 140,
punch_end = 165, punch_end = 165
} }
}) })

View File

@ -17,14 +17,14 @@ mobs:register_mob("nssm:masticone", {
walk_velocity = 1.5, walk_velocity = 1.5,
run_velocity = 2.5, run_velocity = 2.5,
sounds = { sounds = {
random = "masticone", random = "masticone"
}, },
damage = 5, damage = 5,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 7, max = 8}, {name = "nssm:life_energy", chance = 1, min = 7, max = 8},
{name = "nssm:masticone_fang", chance = 1, min = 1, max = 2}, {name = "nssm:masticone_fang", chance = 1, min = 1, max = 2},
{name = "nssm:masticone_skull_fragments", chance = 2, min = 1, max = 2}, {name = "nssm:masticone_skull_fragments", chance = 2, min = 1, max = 2}
}, },
armor = 60, armor = 60,
drawtype = "front", drawtype = "front",
@ -50,8 +50,9 @@ mobs:register_mob("nssm:masticone", {
run_start = 20, run_start = 20,
run_end = 40, run_end = 40,
punch_start = 150, punch_start = 150,
punch_end = 180, punch_end = 180
}, },
on_die = function(self, pos) on_die = function(self, pos)
self.object:remove() self.object:remove()
@ -90,5 +91,5 @@ mobs:register_mob("nssm:masticone", {
end end
end end
end) end)
end, end
}) })

View File

@ -18,14 +18,14 @@ mobs:register_mob("nssm:mese_dragon", {
sounds = { sounds = {
shoot_attack = "mesed", shoot_attack = "mesed",
attack = "mese_dragon", attack = "mese_dragon",
distance = 60, distance = 60
}, },
damage = 18, damage = 18,
jump = true, jump = true,
jump_height = 10, jump_height = 10,
drops = { drops = {
{name = "nssm:rainbow_staff", chance = 1, min = 1, max = 1}, {name = "nssm:rainbow_staff", chance = 1, min = 1, max = 1},
{name = "nssm:energy_globe", chance = 1, min = 99, max = 99}, {name = "nssm:energy_globe", chance = 1, min = 99, max = 99}
}, },
armor = 30, armor = 30,
drawtype = "front", drawtype = "front",
@ -60,7 +60,7 @@ mobs:register_mob("nssm:mese_dragon", {
punch2_start = 330, punch2_start = 330,
punch2_end = 370, punch2_end = 370,
dattack_start = 120, dattack_start = 120,
dattack_end = 160, dattack_end = 160
}, },
do_custom = function(self) do_custom = function(self)
@ -93,7 +93,7 @@ mobs:register_mob("nssm:mese_dragon", {
minetest.sound_play(self.sounds.attack, { minetest.sound_play(self.sounds.attack, {
object = self.object, object = self.object,
max_hear_distance = self.sounds.distance max_hear_distance = self.sounds.distance
}) }, true)
end end
-- punch player -- punch player
@ -115,7 +115,7 @@ mobs:register_mob("nssm:mese_dragon", {
local k = {x = s.x + dx, y = s.y + 20, z = s.z + dz} local k = {x = s.x + dx, y = s.y + 20, z = s.z + dz}
local n = minetest.get_node(k).name local n = minetest.get_node(k).name
if n == "air" and math.random(1, 23) == 1 then if n == "air" and math.random(23) == 1 then
minetest.set_node(k, {name="nssm:mese_meteor"}) minetest.set_node(k, {name="nssm:mese_meteor"})
minetest.check_single_for_falling(k) minetest.check_single_for_falling(k)
end end

View File

@ -17,13 +17,13 @@ mobs:register_mob("nssm:moonheron", {
stepheight = 3, stepheight = 3,
sounds = { sounds = {
random = "moonheron", random = "moonheron",
distance =40, distance = 40
}, },
damage = 5, damage = 5,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 2, max = 3}, {name = "nssm:life_energy", chance = 1, min = 2, max = 3},
{name = "nssm:heron_leg", chance = 1, min = 1, max = 1}, {name = "nssm:heron_leg", chance = 1, min = 1, max = 1}
}, },
armor = 70, armor = 70,
floats = 1, floats = 1,
@ -47,6 +47,6 @@ mobs:register_mob("nssm:moonheron", {
run_start = 20, run_start = 20,
run_end = 60, run_end = 60,
punch_start = 80, punch_start = 80,
punch_end = 120, punch_end = 120
} }
}) })

View File

@ -16,13 +16,13 @@ mobs:register_mob("nssm:mordain", {
run_velocity = 3.5, run_velocity = 3.5,
rotate = 270, rotate = 270,
sounds = { sounds = {
random = "mordain", random = "mordain"
}, },
damage = 6, damage = 6,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 1}, {name = "nssm:life_energy", chance = 1, min = 1, max = 1},
{name = "nssm:slothful_soul_fragment", chance = 3, min = 1, max = 1}, {name = "nssm:slothful_soul_fragment", chance = 3, min = 1, max = 1}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -46,7 +46,7 @@ mobs:register_mob("nssm:mordain", {
run_start = 170, run_start = 170,
run_end = 200, run_end = 200,
punch_start = 210, punch_start = 210,
punch_end = 225, punch_end = 225
}, },
custom_attack = function(self) custom_attack = function(self)
@ -71,7 +71,7 @@ mobs:register_mob("nssm:mordain", {
minetest.sound_play(self.sounds.attack, { minetest.sound_play(self.sounds.attack, {
object = self.object, object = self.object,
max_hear_distance = self.sounds.distance max_hear_distance = self.sounds.distance
}) }, true)
end end
-- punch player -- punch player
@ -115,7 +115,7 @@ mobs:register_mob("nssm:mordain", {
if up == "air" and current ~= "air" then if up == "air" and current ~= "air" then
d.y = d.y + j+1.5 d.y = d.y + j + 1.5
flag = 1 flag = 1
@ -133,7 +133,7 @@ mobs:register_mob("nssm:mordain", {
if dist >= 2 then if dist >= 2 then
for j = -3,3 do for j = -3, 3 do
ty = d.y + j ty = d.y + j
@ -149,7 +149,7 @@ mobs:register_mob("nssm:mordain", {
if up == "air" and current ~= "air" then if up == "air" and current ~= "air" then
d.y = d.y + j+1.5 d.y = d.y + j + 1.5
flag = 1 flag = 1

View File

@ -18,11 +18,11 @@ mobs:register_mob("nssm:morde", {
damage = 6, damage = 6,
jump = true, jump = true,
sounds = { sounds = {
random = "morde", random = "morde"
}, },
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 2, max = 4}, {name = "nssm:life_energy", chance = 1, min = 2, max = 4},
{name = "nssm:proud_soul_fragment", chance = 3, min = 1, max = 1}, {name = "nssm:proud_soul_fragment", chance = 3, min = 1, max = 1}
}, },
armor = 60, armor = 60,
drawtype = "front", drawtype = "front",
@ -48,7 +48,7 @@ mobs:register_mob("nssm:morde", {
run_start = 100, run_start = 100,
run_end = 120, run_end = 120,
punch_start = 130, punch_start = 130,
punch_end = 160, punch_end = 160
}, },
custom_attack = function (self) custom_attack = function (self)
@ -77,7 +77,7 @@ mobs:register_mob("nssm:morde", {
minetest.sound_play(self.sounds.attack, { minetest.sound_play(self.sounds.attack, {
object = self.object, object = self.object,
max_hear_distance = self.sounds.distance max_hear_distance = self.sounds.distance
}) }, true)
end end
-- punch player -- punch player
@ -89,12 +89,20 @@ mobs:register_mob("nssm:morde", {
minetest.add_particlespawner({ minetest.add_particlespawner({
amount = 6, amount = 6,
time = 1, time = 1,
minpos = {x=p.x-0.5, y=p.y-0.5, z=p.z-0.5}, minpos = {x = p.x - 0.5, y = p.y - 0.5, z = p.z - 0.5},
maxpos = {x=p.x+0.5, y=p.y+0.5, z=p.z+0.5}, maxpos = {x = p.x + 0.5, y = p.y + 0.5, z = p.z + 0.5},
minvel = {x=(s.x-p.x)*m, y=(s.y-p.y+1)*m, z=(s.z-p.z)*m}, minvel = {
maxvel = {x=(s.x-p.x)*m, y=(s.y-p.y+1)*m, z=(s.z-p.z)*m}, x = (s.x - p.x) * m,
minacc = {x=s.x-p.x, y=s.y-p.y+1, z=s.z-p.z}, y = (s.y - p.y + 1) * m,
maxacc = {x=s.x-p.x, y=s.y-p.y+1, z=s.z-p.z}, z = (s.z - p.z) * m
},
maxvel = {
x = (s.x - p.x) * m,
y = (s.y - p.y + 1) * m,
z = (s.z - p.z) * m
},
minacc = {x = s.x - p.x, y = s.y - p.y + 1, z = s.z - p.z},
maxacc = {x = s.x - p.x, y = s.y - p.y + 1, z = s.z - p.z},
minexptime = 0.2, minexptime = 0.2,
maxexptime = 0.3, maxexptime = 0.3,
minsize = 2, minsize = 2,
@ -113,7 +121,7 @@ mobs:register_mob("nssm:morde", {
self.object:remove() self.object:remove()
minetest.add_entity(pos, "nssm:mortick") minetest.add_entity(pos, "nssm:mortick")
end, end
}) })
minetest.register_entity("nssm:mortick", { minetest.register_entity("nssm:mortick", {
@ -134,7 +142,7 @@ minetest.register_entity("nssm:mortick", {
self.timer = self.timer + dtime self.timer = self.timer + dtime
local s = self.object:get_pos() local s = self.object:get_pos()
local s1 = {x=s.x, y = s.y-1, z = s.z} local s1 = {x=s.x, y = s.y - 1, z = s.z}
--[[ --[[
if (os.time()-self.mortick_timer > self.lifetime) then if (os.time()-self.mortick_timer > self.lifetime) then

View File

@ -18,13 +18,13 @@ mobs:register_mob("nssm:morgre", {
run_velocity = 3.5, run_velocity = 3.5,
sounds = { sounds = {
explode = "tnt_explode", explode = "tnt_explode",
random = "morgre1", random = "morgre1"
}, },
damage = 1, damage = 1,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:greedy_soul_fragment", chance = 5, min = 1, max = 1}, {name = "nssm:greedy_soul_fragment", chance = 5, min = 1, max = 1}
}, },
armor = 60, armor = 60,
drawtype = "front", drawtype = "front",
@ -48,6 +48,6 @@ mobs:register_mob("nssm:morgre", {
run_start = 120, run_start = 120,
run_end = 140, run_end = 140,
punch_start = 100, punch_start = 100,
punch_end = 110, punch_end = 110
} }
}) })

View File

@ -19,11 +19,11 @@ mobs:register_mob("nssm:morgut", {
runaway = true, runaway = true,
jump = true, jump = true,
sounds = { sounds = {
random = "morgut", random = "morgut"
}, },
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 3}, {name = "nssm:life_energy", chance = 1, min = 1, max = 3},
{name = "nssm:gluttonous_soul_fragment", chance = 3, min = 1, max = 1}, {name = "nssm:gluttonous_soul_fragment", chance = 3, min = 1, max = 1}
}, },
armor = 70, armor = 70,
drawtype = "front", drawtype = "front",
@ -49,7 +49,7 @@ mobs:register_mob("nssm:morgut", {
run_start = 100, run_start = 100,
run_end = 120, run_end = 120,
punch_start = 130, punch_start = 130,
punch_end = 160, punch_end = 160
}, },
do_custom = function (self) do_custom = function (self)
@ -61,7 +61,7 @@ mobs:register_mob("nssm:morgut", {
self.inventory = {} self.inventory = {}
for i = 1, 32 do for i = 1, 32 do
self.inventory[i] = {name = '', num = 0} self.inventory[i] = {name = "", num = 0}
end end
end end
@ -106,12 +106,20 @@ mobs:register_mob("nssm:morgut", {
minetest.add_particlespawner({ minetest.add_particlespawner({
amount = 6, amount = 6,
time = 1, time = 1,
minpos = {x=p.x-0.5, y=p.y-0.5, z=p.z-0.5}, minpos = {x = p.x - 0.5, y = p.y - 0.5, z = p.z - 0.5},
maxpos = {x=p.x+0.5, y=p.y+0.5, z=p.z+0.5}, maxpos = {x = p.x + 0.5, y = p.y + 0.5, z = p.z + 0.5},
minvel = {x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, minvel = {
maxvel = {x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, x = (s.x - p.x) * m,
minacc = {x=s.x-p.x, y=s.y-p.y, z=s.z-p.z}, y = (s.y - p.y) * m,
maxacc = {x=s.x-p.x, y=s.y-p.y, z=s.z-p.z}, z = (s.z - p.z) * m
},
maxvel = {
x = (s.x - p.x) * m,
y = (s.y - p.y) * m,
z = (s.z - p.z) * m
},
minacc = {x = s.x - p.x, y = s.y - p.y, z = s.z - p.z},
maxacc = {x = s.x - p.x, y = s.y - p.y, z = s.z - p.z},
minexptime = 0.2, minexptime = 0.2,
maxexptime = 0.3, maxexptime = 0.3,
minsize = 2, minsize = 2,
@ -126,22 +134,22 @@ mobs:register_mob("nssm:morgut", {
local pname = self.attack:get_player_name() local pname = self.attack:get_player_name()
local player_inv = minetest.get_inventory( local player_inv = minetest.get_inventory(
{type = 'player', name = pname}) {type = "player", name = pname})
if player_inv:is_empty('main') then if player_inv:is_empty("main") then
--minetest.chat_send_all("Inventory empty") --minetest.chat_send_all("Inventory empty")
else else
for i = 1, 32 do for i = 1, 32 do
--minetest.chat_send_all("Inventory is not empty") --minetest.chat_send_all("Inventory is not empty")
local items = player_inv:get_stack('main', i) local items = player_inv:get_stack("main", i)
local n = items:get_name() local n = items:get_name()
if minetest.get_item_group(n, "eatable")==1 then if minetest.get_item_group(n, "eatable") == 1 then
local index local index
local found = 0 local found = 0
for j = 1,32 do for j = 1, 32 do
if found == 0 then if found == 0 then
@ -153,7 +161,7 @@ mobs:register_mob("nssm:morgut", {
--found a corrsponding itemstack --found a corrsponding itemstack
if self.inventory[j].name == n then if self.inventory[j].name == n then
self.inventory[j].num = self.inventory[j].num +1 self.inventory[j].num = self.inventory[j].num + 1
found = 1 found = 1
end end
@ -168,7 +176,7 @@ mobs:register_mob("nssm:morgut", {
items:take_item() items:take_item()
player_inv:set_stack('main', i, items) player_inv:set_stack("main", i, items)
end end
end end
end end
@ -202,7 +210,7 @@ mobs:register_mob("nssm:morgut", {
local elem local elem
for i = 1,32 do for i = 1, 32 do
if self.inventory[i].num ~= 0 then if self.inventory[i].num ~= 0 then
@ -221,5 +229,5 @@ mobs:register_mob("nssm:morgut", {
end end
self.object:remove() self.object:remove()
end, end
}) })

View File

@ -24,7 +24,7 @@ mobs:register_mob("nssm:morlu", {
}, },
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 3, max = 4}, {name = "nssm:life_energy", chance = 1, min = 3, max = 4},
{name = "nssm:lustful_soul_fragment", chance = 3, min = 1, max = 1}, {name = "nssm:lustful_soul_fragment", chance = 3, min = 1, max = 1}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -50,7 +50,7 @@ mobs:register_mob("nssm:morlu", {
run_start = 50, run_start = 50,
run_end = 90, run_end = 90,
punch_start = 100, punch_start = 100,
punch_end = 130, punch_end = 130
}, },
do_custom = function (self) do_custom = function (self)
@ -63,7 +63,7 @@ mobs:register_mob("nssm:morlu", {
self.invnum = 0 self.invnum = 0
for i = 1, 6 do for i = 1, 6 do
self.inventory[i] = {name = ''} self.inventory[i] = {name = ""}
end end
end end
@ -111,9 +111,9 @@ mobs:register_mob("nssm:morlu", {
self.attack, "[set_player_armor]") self.attack, "[set_player_armor]")
local pname = self.attack:get_player_name() local pname = self.attack:get_player_name()
local player_inv = minetest.get_inventory({type='player', name = pname}) local player_inv = minetest.get_inventory({type="player", name = pname})
if player_inv:is_empty('armor') then if player_inv:is_empty("armor") then
-- punch player if he doesn't own an armor -- punch player if he doesn't own an armor
self.attack:punch(self.object, 1.0, { self.attack:punch(self.object, 1.0, {
@ -140,37 +140,38 @@ mobs:register_mob("nssm:morlu", {
steal_pos = math.random(armor_num) steal_pos = math.random(armor_num)
steal_pos = steal_pos - 1 steal_pos = steal_pos - 1
--[[for i=0,armor_num-1 do
minetest.chat_send_all("Posizione: "..armor_elements[i].pos.." Oggetto: "..armor_elements[i].name)
end
]]
--minetest.chat_send_all("Selezionato: pos: "..armor_elements[steal_pos].pos.." nome: "..armor_elements[steal_pos].name)
local cpos = string.find(armor_elements[steal_pos].name, ":") local cpos = string.find(armor_elements[steal_pos].name, ":")
--minetest.chat_send_all("Posizione dei due punti: "..cpos) local mod_name = string.sub(
armor_elements[steal_pos].name, 0, cpos - 1)
local mod_name = string.sub(armor_elements[steal_pos].name, 0, cpos-1) local nname = string.sub(
local nname = string.sub(armor_elements[steal_pos].name, cpos+1) armor_elements[steal_pos].name, cpos + 1)
--minetest.chat_send_all("Armor Mod name: "..mod_name)
if mod_name == "3d_armor" then if mod_name == "3d_armor" then
nname = "3d_armor_inv_"..nname..".png" nname = "3d_armor_inv_" .. nname .. ".png"
elseif mod_name == "nssm" then elseif mod_name == "nssm" then
nname = "inv_"..nname..".png" nname = "inv_" .. nname .. ".png"
else else
nname = "3d_armor_inv_chestplate_diamond.png" nname = "3d_armor_inv_chestplate_diamond.png"
end end
--minetest.chat_send_all("Nome della texture: "..nname)
minetest.add_particlespawner({ minetest.add_particlespawner({
amount = 1, amount = 1,
time = 1, time = 1,
minpos = {x=p.x, y=p.y+1, z=p.z}, minpos = {x = p.x, y = p.y + 1, z = p.z},
maxpos = {x=p.x, y=p.y+1, z=p.z}, maxpos = {x = p.x, y = p.y + 1, z = p.z},
minvel = {x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, minvel = {
maxvel = {x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, x = (s.x - p.x) * m,
minacc = {x=s.x-p.x, y=s.y-p.y-1, z=s.z-p.z}, y = (s.y - p.y) * m,
maxacc = {x=s.x-p.x, y=s.y-p.y-1, z=s.z-p.z}, z = (s.z - p.z) * m
},
maxvel = {
x = (s.x - p.x) * m,
y = (s.y - p.y) * m,
z = (s.z - p.z) * m
},
minacc = {x = s.x - p.x, y = s.y - p.y - 1, z = s.z - p.z},
maxacc = {x = s.x - p.x, y = s.y - p.y - 1, z = s.z - p.z},
minexptime = 0.5, minexptime = 0.5,
maxexptime = 0.5, maxexptime = 0.5,
minsize = 10, minsize = 10,
@ -183,12 +184,16 @@ mobs:register_mob("nssm:morlu", {
if self then if self then
local armor_stack = player_inv:get_stack("armor", armor_elements[steal_pos].pos) local armor_stack = player_inv:get_stack("armor",
armor_elements[steal_pos].pos)
armor_stack:take_item() armor_stack:take_item()
player_inv:set_stack('armor', armor_elements[steal_pos].pos, armor_stack) player_inv:set_stack("armor",
armor_stack = armor_inv:get_stack("armor", armor_elements[steal_pos].pos) armor_elements[steal_pos].pos, armor_stack)
armor_stack = armor_inv:get_stack("armor",
armor_elements[steal_pos].pos)
armor_stack:take_item() armor_stack:take_item()
armor_inv:set_stack('armor', armor_elements[steal_pos].pos, armor_stack) armor_inv:set_stack("armor",
armor_elements[steal_pos].pos, armor_stack)
armor:set_player_armor(self.attack, self.attack) armor:set_player_armor(self.attack, self.attack)
--armor:update_armor(self.attack) --armor:update_armor(self.attack)
@ -197,10 +202,9 @@ mobs:register_mob("nssm:morlu", {
--Update personal inventory of armors: --Update personal inventory of armors:
if (self.invnum ~= nil) and (self.invnum <= 5) then if (self.invnum ~= nil) and (self.invnum <= 5) then
--minetest.chat_send_all("Invnum: "..self.invnum)
--minetest.chat_send_all("Salvo: "..armor_elements[steal_pos].name)
self.invnum = self.invnum + 1 self.invnum = self.invnum + 1
self.inventory[self.invnum].name = armor_elements[steal_pos].name self.inventory[self.invnum].name =
armor_elements[steal_pos].name
end end
mobs:set_animation(self, "run") mobs:set_animation(self, "run")
@ -208,14 +212,15 @@ mobs:register_mob("nssm:morlu", {
self.morlu_timer = os.time() self.morlu_timer = os.time()
self.curr_attack = self.attack self.curr_attack = self.attack
self.state = "" self.state = ""
local pyaw = self.curr_attack: get_look_horizontal() + math.pi / 2 local pyaw = self.curr_attack:get_look_horizontal() +
math.pi / 2
self.dir = pyaw self.dir = pyaw
self.object:set_yaw(pyaw) self.object:set_yaw(pyaw)
if self then if self then
set_velocity(self, 4) set_velocity(self, 4)
end end
end end
end,self) end, self)
end end
end end
else else
@ -233,7 +238,7 @@ mobs:register_mob("nssm:morlu", {
minetest.sound_play(self.sounds.attack, { minetest.sound_play(self.sounds.attack, {
object = self.object, object = self.object,
max_hear_distance = self.sounds.distance max_hear_distance = self.sounds.distance
}) }, true)
end end
-- punch player -- punch player
@ -257,7 +262,7 @@ mobs:register_mob("nssm:morlu", {
for i = 1, self.invnum do for i = 1, self.invnum do
local items = ItemStack(self.inventory[i].name.." 1") local items = ItemStack(self.inventory[i].name .. " 1")
local obj = minetest.add_item(pos, items) local obj = minetest.add_item(pos, items)
obj:set_velocity({ obj:set_velocity({
@ -270,5 +275,5 @@ mobs:register_mob("nssm:morlu", {
end end
self.object:remove() self.object:remove()
end, end
}) })

View File

@ -1,5 +1,5 @@
local time_limit = 120 local time_limit = 120
local posmorvalarblock = {x=827, y=-30094, z=-817} local posmorvalarblock = {x = 827, y = -30094, z = -817}
function respawn_block(self) function respawn_block(self)
--start a timer if it doesn't exist --start a timer if it doesn't exist
@ -43,7 +43,7 @@ mobs:register_mob("nssm:morvalar", {
runaway = true, runaway = true,
jump = true, jump = true,
sounds = { sounds = {
random = "morvalar7", random = "morvalar7"
}, },
armor = 50, armor = 50,
drawtype = "front", drawtype = "front",
@ -67,7 +67,7 @@ mobs:register_mob("nssm:morvalar", {
run_start = 10, run_start = 10,
run_end = 50, run_end = 50,
punch_start = 55, punch_start = 55,
punch_end = 80, punch_end = 80
}, },
do_custom = function(self) do_custom = function(self)
@ -97,7 +97,7 @@ mobs:register_mob("nssm:morvalar", {
local pname, player_inv, armor_inv, ppos = armor:get_valid_player( local pname, player_inv, armor_inv, ppos = armor:get_valid_player(
self.attack, "[set_player_armor]") self.attack, "[set_player_armor]")
local pname = self.attack:get_player_name() local pname = self.attack:get_player_name()
local player_inv = minetest.get_inventory({type='player', name = pname}) local player_inv = minetest.get_inventory({type = "player", name = pname})
if player_inv:is_empty('armor') then if player_inv:is_empty('armor') then
-- punch player if he doesn't own an armor -- punch player if he doesn't own an armor
@ -127,13 +127,15 @@ mobs:register_mob("nssm:morvalar", {
steal_pos = steal_pos-1 steal_pos = steal_pos-1
local cpos = string.find(armor_elements[steal_pos].name, ":") local cpos = string.find(armor_elements[steal_pos].name, ":")
local mod_name = string.sub(armor_elements[steal_pos].name, 0, cpos - 1) local mod_name = string.sub(
local nname = string.sub(armor_elements[steal_pos].name, cpos + 1) armor_elements[steal_pos].name, 0, cpos - 1)
local nname = string.sub(
armor_elements[steal_pos].name, cpos + 1)
if mod_name == "3d_armor" then if mod_name == "3d_armor" then
nname = "3d_armor_inv_"..nname..".png" nname = "3d_armor_inv_" .. nname .. ".png"
elseif mod_name == "nssm" then elseif mod_name == "nssm" then
nname = "inv_"..nname..".png" nname = "inv_" .. nname .. ".png"
else else
nname = "3d_armor_inv_chestplate_diamond.png" nname = "3d_armor_inv_chestplate_diamond.png"
end end
@ -141,12 +143,20 @@ mobs:register_mob("nssm:morvalar", {
minetest.add_particlespawner({ minetest.add_particlespawner({
amount = 1, amount = 1,
time = 1, time = 1,
minpos = {x=p.x, y=p.y+1, z=p.z}, minpos = {x = p.x, y = p.y + 1, z = p.z},
maxpos = {x=p.x, y=p.y+1, z=p.z}, maxpos = {x = p.x, y = p.y + 1, z = p.z},
minvel = {x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, minvel = {
maxvel = {x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, x = (s.x - p.x) * m,
minacc = {x=s.x-p.x, y=s.y-p.y-1, z=s.z-p.z}, y = (s.y - p.y) * m,
maxacc = {x=s.x-p.x, y=s.y-p.y-1, z=s.z-p.z}, z = (s.z - p.z) * m
},
maxvel = {
x = (s.x - p.x) * m,
y = (s.y - p.y) * m,
z = (s.z - p.z) * m
},
minacc = {x = s.x - p.x, y = s.y - p.y - 1, z = s.z - p.z},
maxacc = {x = s.x - p.x, y = s.y - p.y - 1, z = s.z - p.z},
minexptime = 0.5, minexptime = 0.5,
maxexptime = 0.5, maxexptime = 0.5,
minsize = 10, minsize = 10,
@ -157,13 +167,17 @@ mobs:register_mob("nssm:morvalar", {
minetest.after(1, function (self) minetest.after(1, function (self)
local armor_stack = player_inv:get_stack("armor", armor_elements[steal_pos].pos) local armor_stack = player_inv:get_stack("armor",
armor_elements[steal_pos].pos)
armor_stack:take_item() armor_stack:take_item()
player_inv:set_stack('armor', armor_elements[steal_pos].pos, armor_stack) player_inv:set_stack("armor",
armor_elements[steal_pos].pos, armor_stack)
armor_stack = armor_inv:get_stack("armor", armor_elements[steal_pos].pos) armor_stack = armor_inv:get_stack("armor",
armor_elements[steal_pos].pos)
armor_stack:take_item() armor_stack:take_item()
armor_inv:set_stack('armor', armor_elements[steal_pos].pos, armor_stack) armor_inv:set_stack("armor",
armor_elements[steal_pos].pos, armor_stack)
armor:set_player_armor(self.attack, self.attack) armor:set_player_armor(self.attack, self.attack)
armor:update_inventory(self.attack) armor:update_inventory(self.attack)
@ -185,7 +199,7 @@ mobs:register_mob("nssm:morvalar", {
minetest.sound_play(self.sounds.attack, { minetest.sound_play(self.sounds.attack, {
object = self.object, object = self.object,
max_hear_distance = self.sounds.distance max_hear_distance = self.sounds.distance
}) }, true)
end end
-- punch player -- punch player
self.attack:punch(self.object, 1.0, { self.attack:punch(self.object, 1.0, {
@ -205,7 +219,7 @@ mobs:register_mob("nssm:morvalar", {
self.object:remove() self.object:remove()
add_entity_and_particles("nssm:morvalar6", pos, "morparticle.png", 10) add_entity_and_particles("nssm:morvalar6", pos, "morparticle.png", 10)
end, end
}) })
mobs:register_mob("nssm:morvalar6", { mobs:register_mob("nssm:morvalar6", {
@ -229,7 +243,7 @@ mobs:register_mob("nssm:morvalar6", {
runaway = true, runaway = true,
jump = true, jump = true,
sounds = { sounds = {
random = "morvalar6", random = "morvalar6"
}, },
armor = 50, armor = 50,
drawtype = "front", drawtype = "front",
@ -253,7 +267,7 @@ mobs:register_mob("nssm:morvalar6", {
run_start = 90, run_start = 90,
run_end = 130, run_end = 130,
punch_start = 132, punch_start = 132,
punch_end = 162, punch_end = 162
}, },
do_custom = function(self) do_custom = function(self)
@ -273,30 +287,29 @@ mobs:register_mob("nssm:morvalar6", {
mobs:set_animation(self, "punch") mobs:set_animation(self, "punch")
local m = 2 local m = 2
minetest.after(1, function (self) minetest.after(1, function (self)
if self.attack:is_player() then if self.attack:is_player() then
local pname = self.attack:get_player_name() local pname = self.attack:get_player_name()
local player_inv = minetest.get_inventory({type='player', name = pname}) local player_inv = minetest.get_inventory({
type = "player", name = pname})
if player_inv:is_empty('main') then if player_inv:is_empty("main") then
--minetest.chat_send_all("Inventory empty") --minetest.chat_send_all("Inventory empty")
else else
local imhungry = 0 local imhungry = 0
for i = 1, 32 do for i = 1, 32 do
--minetest.chat_send_all("Inventory is not empty") --minetest.chat_send_all("Inventory is not empty")
local items = player_inv:get_stack('main', i) local items = player_inv:get_stack("main", i)
local n = items:get_name() local n = items:get_name()
if minetest.get_item_group(n, "eatable")==1 then if minetest.get_item_group(n, "eatable")==1 then
imhungry = 1 imhungry = 1
for t = 0,2 do for t = 0, 2 do
items:take_item() items:take_item()
end end
player_inv:set_stack('main', i, items) player_inv:set_stack("main", i, items)
end end
end end
if imhungry == 0 then if imhungry == 0 then
@ -305,16 +318,24 @@ mobs:register_mob("nssm:morvalar6", {
damage_groups = {fleshy = self.damage} damage_groups = {fleshy = self.damage}
}, nil) }, nil)
else else
s.y = s.y+1.8 s.y = s.y + 1.8
minetest.add_particlespawner({ minetest.add_particlespawner({
amount = 1, amount = 1,
time = 1, time = 1,
minpos = {x=p.x, y=p.y+1, z=p.z}, minpos = {x = p.x, y = p.y + 1, z = p.z},
maxpos = {x=p.x, y=p.y+1, z=p.z}, maxpos = {x = p.x, y = p.y + 1, z = p.z},
minvel = {x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, minvel = {
maxvel = {x=(s.x-p.x)*m, y=(s.y-p.y)*m, z=(s.z-p.z)*m}, x = (s.x - p.x) * m,
minacc = {x=s.x-p.x, y=s.y-p.y-1, z=s.z-p.z}, y = (s.y - p.y) * m,
maxacc = {x=s.x-p.x, y=s.y-p.y-1, z=s.z-p.z}, z = (s.z - p.z) * m
},
maxvel = {
x = (s.x - p.x) * m,
y = (s.y - p.y) * m,
z = (s.z - p.z) * m
},
minacc = {x = s.x - p.x, y = s.y - p.y - 1, z = s.z - p.z},
maxacc = {x = s.x - p.x, y = s.y - p.y - 1, z = s.z - p.z},
minexptime = 0.5, minexptime = 0.5,
maxexptime = 0.5, maxexptime = 0.5,
minsize = 10, minsize = 10,
@ -327,14 +348,14 @@ mobs:register_mob("nssm:morvalar6", {
end end
end end
end,self) end, self)
end end
end, end,
on_die = function(self) on_die = function(self)
local pos = self.object:get_pos() local pos = self.object:get_pos()
self.object:remove() self.object:remove()
add_entity_and_particles("nssm:morvalar5", pos, "morparticle.png", 10) add_entity_and_particles("nssm:morvalar5", pos, "morparticle.png", 10)
end, end
}) })
@ -347,7 +368,7 @@ mobs:register_mob("nssm:morvalar5", {
--rotate= 270, --rotate= 270,
mesh = "morvalar.x", mesh = "morvalar.x",
textures = {{"morvalar.png"}}, textures = {{"morvalar.png"}},
visual_size = {x=5, y=5}, visual_size = {x = 5, y = 5},
makes_footstep_sound = true, makes_footstep_sound = true,
view_range = 50, view_range = 50,
walk_velocity = 1.6, walk_velocity = 1.6,
@ -357,7 +378,7 @@ mobs:register_mob("nssm:morvalar5", {
runaway = true, runaway = true,
jump = true, jump = true,
sounds = { sounds = {
random = "morvalar5", random = "morvalar5"
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -368,8 +389,8 @@ mobs:register_mob("nssm:morvalar5", {
fire_damage = 0, fire_damage = 0,
light_damage = 0, light_damage = 0,
blood_texture="morparticle.png", blood_texture="morparticle.png",
blood_amount=10, blood_amount = 10,
knock_back=0, knock_back = 0,
on_rightclick = nil, on_rightclick = nil,
attack_type = "dogfight", attack_type = "dogfight",
animation = { animation = {
@ -382,7 +403,7 @@ mobs:register_mob("nssm:morvalar5", {
run_start = 170, run_start = 170,
run_end = 210, run_end = 210,
punch_start = 215, punch_start = 215,
punch_end = 245, punch_end = 245
}, },
do_custom = function(self) do_custom = function(self)
respawn_block(self) respawn_block(self)
@ -397,16 +418,16 @@ mobs:register_mob("nssm:morvalar5", {
local p = self.attack:get_pos() local p = self.attack:get_pos()
minetest.after(2, function(self) minetest.after(2, function(self)
mobs:set_animation(self, "punch") mobs:set_animation(self, "punch")
tnt_boom_nssm(p, {damage_radius=6,radius=5,ignore_protection=false}) tnt_boom_nssm(p, {damage_radius = 6, radius = 5, ignore_protection = false})
self.morvalar5_timer = os.time() self.morvalar5_timer = os.time()
end,self) end, self)
end end
end, end,
on_die = function(self) on_die = function(self)
local pos = self.object:get_pos() local pos = self.object:get_pos()
self.object:remove() self.object:remove()
add_entity_and_particles("nssm:morvalar4", pos, "morparticle.png", 10) add_entity_and_particles("nssm:morvalar4", pos, "morparticle.png", 10)
end, end
}) })
@ -419,7 +440,7 @@ mobs:register_mob("nssm:morvalar4", {
--rotate= 270, --rotate= 270,
mesh = "morvalar.x", mesh = "morvalar.x",
textures = {{"morvalar.png"}}, textures = {{"morvalar.png"}},
visual_size = {x=5, y=5}, visual_size = {x = 5, y = 5},
makes_footstep_sound = true, makes_footstep_sound = true,
view_range = 50, view_range = 50,
walk_velocity = 1.6, walk_velocity = 1.6,
@ -429,7 +450,7 @@ mobs:register_mob("nssm:morvalar4", {
runaway = true, runaway = true,
jump = true, jump = true,
sounds = { sounds = {
random = "morvalar4", random = "morvalar4"
}, },
armor = 30, armor = 30,
drawtype = "front", drawtype = "front",
@ -454,11 +475,13 @@ mobs:register_mob("nssm:morvalar4", {
run_start = 255, run_start = 255,
run_end = 295, run_end = 295,
punch_start = 300, punch_start = 300,
punch_end = 320, punch_end = 320
}, },
do_custom = function(self) do_custom = function(self)
respawn_block(self) respawn_block(self)
end, end,
custom_attack = function(self) custom_attack = function(self)
self.morvalar4_timer = (self.morvalar4_timer or os.time()) self.morvalar4_timer = (self.morvalar4_timer or os.time())
if (os.time() - self.morvalar4_timer) > 1 then if (os.time() - self.morvalar4_timer) > 1 then
@ -468,18 +491,19 @@ mobs:register_mob("nssm:morvalar4", {
mobs:set_animation(self, "punch") mobs:set_animation(self, "punch")
if minetest.line_of_sight({x = p.x, y = p.y +1.5, z = p.z}, {x = s.x, y = s.y +1.5, z = s.z}) == true then if minetest.line_of_sight({x = p.x, y = p.y + 1.5, z = p.z},
{x = s.x, y = s.y + 1.5, z = s.z}) == true then
-- play attack sound -- play attack sound
if self.sounds.attack then if self.sounds.attack then
minetest.sound_play(self.sounds.attack, { minetest.sound_play(self.sounds.attack, {
object = self.object, object = self.object,
max_hear_distance = self.sounds.distance max_hear_distance = self.sounds.distance
}) }, true)
end end
-- punch player -- punch player
self.attack:punch(self.object, 1.0, { self.attack:punch(self.object, 1.0, {
full_punch_interval=1.0, full_punch_interval = 1.0,
damage_groups = {fleshy=self.damage} damage_groups = {fleshy = self.damage}
}, nil) }, nil)
end end
@ -488,34 +512,34 @@ mobs:register_mob("nssm:morvalar4", {
local flag = 0 local flag = 0
local m = 3 local m = 3
local v = {x=(p.x-s.x)*m, y = ty, z = (p.z-s.z)*m} local v = {x = (p.x - s.x) * m, y = ty, z = (p.z - s.z) * m}
local d = {x=s.x+v.x, y = ty, z = s.z+v.z} local d = {x = s.x + v.x, y = ty, z = s.z + v.z}
d.y = ty d.y = ty
for j = -3,3 do for j = -3, 3 do
ty = d.y + j ty = d.y + j
local current = minetest.get_node({x = d.x, y = ty, z = d.z}).name local current = minetest.get_node({x = d.x, y = ty, z = d.z}).name
local up = minetest.get_node({x = d.x, y = ty+1, z = d.z}).name local up = minetest.get_node({x = d.x, y = ty + 1, z = d.z}).name
if up == "air" and current ~= "air" then if up == "air" and current ~= "air" then
d.y = d.y + j+1.5 d.y = d.y + j + 1.5
flag = 1 flag = 1
break break
end end
end end
while flag ~= 1 do while flag ~= 1 do
d.x = p.x + math.random(-m,m) d.x = p.x + math.random(-m, m)
d.z = p.z + math.random(-m,m) d.z = p.z + math.random(-m, m)
d.y = p.y d.y = p.y
local dist = dist_pos(d, p) local dist = dist_pos(d, p)
if dist>=2 then if dist >= 2 then
for j = -3,3 do for j = -3, 3 do
ty = d.y + j ty = d.y + j
local current = minetest.get_node({x = d.x, y = ty, z = d.z}).name local current = minetest.get_node({x = d.x, y = ty, z = d.z}).name
local up = minetest.get_node({x = d.x, y = ty+1, z = d.z}).name local up = minetest.get_node({x = d.x, y = ty + 1, z = d.z}).name
if up == "air" and current ~= "air" then if up == "air" and current ~= "air" then
d.y = d.y + j+1.5 d.y = d.y + j + 1.5
flag = 1 flag = 1
break break
end end
@ -530,7 +554,7 @@ mobs:register_mob("nssm:morvalar4", {
local pos = self.object:get_pos() local pos = self.object:get_pos()
self.object:remove() self.object:remove()
add_entity_and_particles("nssm:morvalar3", pos, "morparticle.png", 10) add_entity_and_particles("nssm:morvalar3", pos, "morparticle.png", 10)
end, end
}) })
mobs:register_mob("nssm:morvalar3", { mobs:register_mob("nssm:morvalar3", {
@ -542,7 +566,7 @@ mobs:register_mob("nssm:morvalar3", {
--rotate= 270, --rotate= 270,
mesh = "morvalar.x", mesh = "morvalar.x",
textures = {{"morvalar.png"}}, textures = {{"morvalar.png"}},
visual_size = {x=5, y=5}, visual_size = {x = 5, y = 5},
makes_footstep_sound = true, makes_footstep_sound = true,
view_range = 50, view_range = 50,
walk_velocity = 1.6, walk_velocity = 1.6,
@ -552,7 +576,7 @@ mobs:register_mob("nssm:morvalar3", {
runaway = true, runaway = true,
jump = true, jump = true,
sounds = { sounds = {
random = "morvalar3", random = "morvalar3"
}, },
armor = 30, armor = 30,
drawtype = "front", drawtype = "front",
@ -583,16 +607,18 @@ mobs:register_mob("nssm:morvalar3", {
punch_start = 375, punch_start = 375,
punch_end = 395, punch_end = 395,
shoot_start = 400, shoot_start = 400,
shoot_end = 450, shoot_end = 450
}, },
do_custom = function(self) do_custom = function(self)
respawn_block(self) respawn_block(self)
end, end,
on_die = function(self) on_die = function(self)
local pos = self.object:get_pos() local pos = self.object:get_pos()
self.object:remove() self.object:remove()
add_entity_and_particles("nssm:morvalar2", pos, "morparticle.png", 10) add_entity_and_particles("nssm:morvalar2", pos, "morparticle.png", 10)
end, end
}) })
mobs:register_mob("nssm:morvalar2", { mobs:register_mob("nssm:morvalar2", {
@ -604,7 +630,7 @@ mobs:register_mob("nssm:morvalar2", {
--rotate= 270, --rotate= 270,
mesh = "morvalar.x", mesh = "morvalar.x",
textures = {{"morvalar.png"}}, textures = {{"morvalar.png"}},
visual_size = {x=5, y=5}, visual_size = {x = 5, y = 5},
makes_footstep_sound = true, makes_footstep_sound = true,
view_range = 50, view_range = 50,
walk_velocity = 1.6, walk_velocity = 1.6,
@ -614,7 +640,7 @@ mobs:register_mob("nssm:morvalar2", {
runaway = true, runaway = true,
jump = true, jump = true,
sounds = { sounds = {
random = "morvalar2", random = "morvalar2"
}, },
armor = 50, armor = 50,
drawtype = "front", drawtype = "front",
@ -624,9 +650,9 @@ mobs:register_mob("nssm:morvalar2", {
lava_damage = 0, lava_damage = 0,
fire_damage = 0, fire_damage = 0,
light_damage = 0, light_damage = 0,
blood_texture="morparticle.png", blood_texture = "morparticle.png",
blood_amount=10, blood_amount = 10,
knock_back=0, knock_back = 0,
on_rightclick = nil, on_rightclick = nil,
attack_type = "dogfight", attack_type = "dogfight",
animation = { animation = {
@ -639,11 +665,13 @@ mobs:register_mob("nssm:morvalar2", {
run_start = 460, run_start = 460,
run_end = 500, run_end = 500,
punch_start = 505, punch_start = 505,
punch_end = 545, punch_end = 545
}, },
do_custom = function(self) do_custom = function(self)
respawn_block(self) respawn_block(self)
end, end,
custom_attack = function(self) custom_attack = function(self)
self.morvalar2_timer = (self.morvalar2_timer or os.time()) self.morvalar2_timer = (self.morvalar2_timer or os.time())
if (os.time() - self.morvalar2_timer) > 1 then if (os.time() - self.morvalar2_timer) > 1 then
@ -656,7 +684,13 @@ mobs:register_mob("nssm:morvalar2", {
for _,obj in ipairs(objects) do for _,obj in ipairs(objects) do
if obj:get_luaentity() then if obj:get_luaentity() then
local name = obj:get_luaentity().name local name = obj:get_luaentity().name
if (name == "nssm:mordain" or name == "nssm:morde" or name == "nssm:morgut" or name == "nssm:morgre" or name == "nssm:morlu" or name == "nssm:morwa" or name == "nssm:morvy") then if (name == "nssm:mordain"
or name == "nssm:morde"
or name == "nssm:morgut"
or name == "nssm:morgre"
or name == "nssm:morlu"
or name == "nssm:morwa"
or name == "nssm:morvy") then
counter = counter + 1 counter = counter + 1
end end
end end
@ -669,8 +703,8 @@ mobs:register_mob("nssm:morvalar2", {
--local v = {x = s.x-p.x, y = s.y-p.y , z= s.z-p.z} --local v = {x = s.x-p.x, y = s.y-p.y , z= s.z-p.z}
v = vector.normalize(v) v = vector.normalize(v)
local per = perpendicular_vector(v) local per = perpendicular_vector(v)
local p1 = vector.add(s,v) local p1 = vector.add(s, v)
p1 = vector.subtract(p1,vector.multiply(per,4)) p1 = vector.subtract(p1, vector.multiply(per, 4))
add_entity_and_particles("nssm:morwa", p1, "morparticle.png", 1) add_entity_and_particles("nssm:morwa", p1, "morparticle.png", 1)
p1 = vector.add(p1,per) p1 = vector.add(p1,per)
@ -693,7 +727,7 @@ mobs:register_mob("nssm:morvalar2", {
local pos = self.object:get_pos() local pos = self.object:get_pos()
self.object:remove() self.object:remove()
add_entity_and_particles("nssm:morvalar1", pos, "morparticle.png", 10) add_entity_and_particles("nssm:morvalar1", pos, "morparticle.png", 10)
end, end
}) })
mobs:register_mob("nssm:morvalar1", { mobs:register_mob("nssm:morvalar1", {
@ -705,7 +739,7 @@ mobs:register_mob("nssm:morvalar1", {
--rotate= 270, --rotate= 270,
mesh = "morvalar.x", mesh = "morvalar.x",
textures = {{"morvalar.png"}}, textures = {{"morvalar.png"}},
visual_size = {x=5, y=5}, visual_size = {x = 5, y = 5},
makes_footstep_sound = true, makes_footstep_sound = true,
view_range = 50, view_range = 50,
walk_velocity = 1.6, walk_velocity = 1.6,
@ -715,7 +749,7 @@ mobs:register_mob("nssm:morvalar1", {
runaway = true, runaway = true,
jump = true, jump = true,
sounds = { sounds = {
random = "morvalar1", random = "morvalar1"
}, },
armor = 20, armor = 20,
drawtype = "front", drawtype = "front",
@ -740,11 +774,13 @@ mobs:register_mob("nssm:morvalar1", {
run_start = 560, run_start = 560,
run_end = 600, run_end = 600,
punch_start = 610, punch_start = 610,
punch_end = 640, punch_end = 640
}, },
do_custom = function(self) do_custom = function(self)
respawn_block(self) respawn_block(self)
end, end,
custom_attack = function (self) custom_attack = function (self)
self.morvalar1_timer = (self.morvalar1_timer or os.time()) self.morvalar1_timer = (self.morvalar1_timer or os.time())
if (os.time() - self.morvalar1_timer) > 3 then if (os.time() - self.morvalar1_timer) > 3 then
@ -757,28 +793,30 @@ mobs:register_mob("nssm:morvalar1", {
local m = 3 local m = 3
if minetest.line_of_sight({x = p.x, y = p.y +1.5, z = p.z}, {x = s.x, y = s.y +1.5, z = s.z}) == true then if minetest.line_of_sight({x = p.x, y = p.y +1.5, z = p.z},
{x = s.x, y = s.y +1.5, z = s.z}) == true then
-- play attack sound -- play attack sound
if self.sounds.attack then if self.sounds.attack then
minetest.sound_play(self.sounds.attack, { minetest.sound_play(self.sounds.attack, {
object = self.object, object = self.object,
max_hear_distance = self.sounds.distance max_hear_distance = self.sounds.distance
}) }, true)
end end
-- punch player -- punch player
self.health = self.health + (self.damage*3) self.health = self.health + (self.damage * 3)
self.attack:punch(self.object, 1.0, { self.attack:punch(self.object, 1.0, {
full_punch_interval=1.0, full_punch_interval = 1.0,
damage_groups = {fleshy=self.damage} damage_groups = {fleshy = self.damage}
}, nil) }, nil)
end end
end end
end, end,
on_die = function(self) on_die = function(self)
local pos = self.object:get_pos() local pos = self.object:get_pos()
self.object:remove() self.object:remove()
add_entity_and_particles("nssm:morvalar0", pos, "morparticle.png", 10) add_entity_and_particles("nssm:morvalar0", pos, "morparticle.png", 10)
end, end
}) })
mobs:register_mob("nssm:morvalar0", { mobs:register_mob("nssm:morvalar0", {
@ -790,7 +828,7 @@ mobs:register_mob("nssm:morvalar0", {
--rotate= 270, --rotate= 270,
mesh = "morvalar.x", mesh = "morvalar.x",
textures = {{"morvalar.png"}}, textures = {{"morvalar.png"}},
visual_size = {x=5, y=5}, visual_size = {x = 5, y = 5},
makes_footstep_sound = true, makes_footstep_sound = true,
view_range = 50, view_range = 50,
walk_velocity = 1.6, walk_velocity = 1.6,
@ -800,13 +838,10 @@ mobs:register_mob("nssm:morvalar0", {
runaway = true, runaway = true,
jump = true, jump = true,
sounds = { sounds = {
random = "kamehameha", random = "kamehameha"
}, },
drops = { drops = {
{name = "nssm:death_scythe", {name = "nssm:death_scythe", chance = 1, min = 1, max = 1}
chance = 1,
min = 1,
max = 1,},
}, },
armor = 30, armor = 30,
drawtype = "front", drawtype = "front",
@ -831,11 +866,13 @@ mobs:register_mob("nssm:morvalar0", {
run_start = 650, run_start = 650,
run_end = 690, run_end = 690,
punch_start = 700, punch_start = 700,
punch_end = 750, punch_end = 750
}, },
do_custom = function(self) do_custom = function(self)
respawn_block(self) respawn_block(self)
end, end,
custom_attack = function (self) custom_attack = function (self)
self.morvalar1_timer = (self.morvalar1_timer or os.time()) self.morvalar1_timer = (self.morvalar1_timer or os.time())
if (os.time() - self.morvalar1_timer) > 1 then if (os.time() - self.morvalar1_timer) > 1 then
@ -851,41 +888,43 @@ mobs:register_mob("nssm:morvalar0", {
s.y = s.y+0.5 s.y = s.y+0.5
p.y = p.y+0.9 p.y = p.y+0.9
local dir = {x=(p.x-s.x)*m, y=(p.y-s.y)*m, z=(p.z-s.z)*m} --direction of the kamehameha --direction of the kamehameha
local dir = {x = (p.x - s.x) * m, y = (p.y - s.y) * m, z = (p.z - s.z) * m}
obj:set_velocity(dir) obj:set_velocity(dir)
end end
end, end,
on_die = function(self) on_die = function(self)
local pos = self.object:get_pos() local pos = self.object:get_pos()
self.object:remove() self.object:remove()
minetest.add_particlespawner({ minetest.add_particlespawner({
amount = 500, amount = 500,
time = 2, time = 2,
minpos = {x=pos.x-2, y=pos.y-1, z=pos.z-2}, minpos = {x = pos.x - 2, y = pos.y - 1, z = pos.z - 2},
maxpos = {x=pos.x+2, y=pos.y+4, z=pos.z+2}, maxpos = {x = pos.x + 2, y = pos.y + 4, z = pos.z + 2},
minvel = {x=0, y=0, z=0}, minvel = {x = 0, y = 0, z = 0},
maxvel = {x=1, y=2, z=1}, maxvel = {x = 1, y = 2, z = 1},
minacc = {x=-0.5,y=0.6,z=-0.5}, minacc = {x = -0.5, y = 0.6, z = -0.5},
maxacc = {x=0.5,y=0.7,z=0.5}, maxacc = {x = 0.5, y = 0.7, z = 0.5},
minexptime = 2, minexptime = 2,
maxexptime = 3, maxexptime = 3,
minsize = 3, minsize = 3,
maxsize = 5, maxsize = 5,
collisiondetection = false, collisiondetection = false,
vertical = false, vertical = false,
texture = "morparticle.png", texture = "morparticle.png"
}) })
if minetest.get_modpath("nssb") then if minetest.get_modpath("nssb") then
minetest.set_node(posmorvalarblock, {name="nssb:dis_morvalar_block"}) minetest.set_node(posmorvalarblock, {name="nssb:dis_morvalar_block"})
end end
--minetest.add_entity(pos, "nssm:morvalar3") --minetest.add_entity(pos, "nssm:morvalar3")
end, end
}) })
minetest.register_entity("nssm:kamehameha_bad", { minetest.register_entity("nssm:kamehameha_bad", {
textures = {"kamehameha.png"}, textures = {"kamehameha.png"},
on_step = function(self, dtime) on_step = function(self, dtime)
local pos = self.object:get_pos(); local pos = self.object:get_pos()
if self.timer == 0 then if self.timer == 0 then
self.timer = os.time() self.timer = os.time()
end end
@ -903,7 +942,7 @@ minetest.register_entity("nssm:kamehameha_bad", {
if obj:get_luaentity() then if obj:get_luaentity() then
local name = obj:get_luaentity().name local name = obj:get_luaentity().name
if name ~= "nssm:morvalar0" and name ~="nssm:kamehameha_bad" then if name ~= "nssm:morvalar0" and name ~="nssm:kamehameha_bad" then
obj:set_hp(obj:get_hp()-5) obj:set_hp(obj:get_hp() - 5)
if (obj:get_hp() <= 0) then if (obj:get_hp() <= 0) then
if (not obj:is_player()) then if (not obj:is_player()) then
obj:remove() obj:remove()
@ -915,14 +954,14 @@ minetest.register_entity("nssm:kamehameha_bad", {
local objects = minetest.get_objects_inside_radius(pos, 1) local objects = minetest.get_objects_inside_radius(pos, 1)
for _,obj in ipairs(objects) do for _,obj in ipairs(objects) do
if obj:is_player() then if obj:is_player() then
tnt_boom_nssm(pos, {damage_radius=6,radius=5,ignore_protection=false}) tnt_boom_nssm(pos, {damage_radius = 6, radius = 5, ignore_protection = false})
self.object:remove() self.object:remove()
minetest.chat_send_all("Dentro il raggio piccolo") minetest.chat_send_all("Dentro il raggio piccolo")
end end
if obj:get_luaentity() then if obj:get_luaentity() then
local name = obj:get_luaentity().name local name = obj:get_luaentity().name
if name ~= "nssm:morvalar0" and name ~="nssm:kamehameha_bad" then if name ~= "nssm:morvalar0" and name ~="nssm:kamehameha_bad" then
tnt_boom_nssm(pos, {damage_radius=6,radius=5,ignore_protection=false}) tnt_boom_nssm(pos, {damage_radius = 6, radius = 5, ignore_protection = false})
self.object:remove() self.object:remove()
end end
end end
@ -936,7 +975,7 @@ minetest.register_entity("nssm:kamehameha_bad", {
end, end,
life_time = 40, life_time = 40,
timer = 0, timer = 0,
custom_timer = 0, custom_timer = 0
}) })

View File

@ -17,12 +17,12 @@ mobs:register_mob("nssm:morvy", {
rotate = 270, rotate = 270,
damage = 4, damage = 4,
sounds = { sounds = {
random = "morvy", random = "morvy"
}, },
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 5, max = 7}, {name = "nssm:life_energy", chance = 1, min = 5, max = 7},
{name = "nssm:envious_soul_fragment", chance = 3, min = 1, max = 1}, {name = "nssm:envious_soul_fragment", chance = 3, min = 1, max = 1}
}, },
reach = 8, reach = 8,
armor = 60, armor = 60,
@ -47,7 +47,7 @@ mobs:register_mob("nssm:morvy", {
run_start = 50, run_start = 50,
run_end = 90, run_end = 90,
punch_start = 100, punch_start = 100,
punch_end = 130, punch_end = 130
}, },
custom_attack = function(self) custom_attack = function(self)
@ -100,7 +100,7 @@ mobs:register_mob("nssm:morvy", {
and counter < 5 then and counter < 5 then
local bat local bat
local which = math.random(1,3) local which = math.random(1, 3)
if which == 1 then if which == 1 then
bat = "nssm:morbat1" bat = "nssm:morbat1"
@ -119,12 +119,12 @@ mobs:register_mob("nssm:morvy", {
minetest.add_particlespawner({ minetest.add_particlespawner({
amount = 20, amount = 20,
time = 0.1, time = 0.1,
minpos = {x=pos1.x-0.2, y=pos1.y-0.2, z=pos1.z-0.2}, minpos = {x = pos1.x - 0.2, y = pos1.y - 0.2, z = pos1.z - 0.2},
maxpos = {x=pos1.x+0.2, y=pos1.y+0.2, z=pos1.z+0.2}, maxpos = {x = pos1.x + 0.2, y = pos1.y + 0.2, z = pos1.z + 0.2},
minvel = {x=0, y=0, z=0}, minvel = {x = 0, y = 0, z = 0},
maxvel = {x=0.1, y=0.3, z=0.1}, maxvel = {x = 0.1, y = 0.3, z = 0.1},
minacc = {x=-0.5,y=1,z=-0.5}, minacc = {x = -0.5, y = 1, z = -0.5},
maxacc = {x=0.5,y=1,z=0.5}, maxacc = {x = 0.5, y = 1, z = 0.5},
minexptime = 0.1, minexptime = 0.1,
maxexptime = 4, maxexptime = 4,
minsize = 2, minsize = 2,
@ -138,7 +138,6 @@ mobs:register_mob("nssm:morvy", {
end end
}) })
--Morbats --Morbats
mobs:register_mob("nssm:morbat1", { mobs:register_mob("nssm:morbat1", {
@ -165,7 +164,7 @@ mobs:register_mob("nssm:morbat1", {
jump = true, jump = true,
rotate = 270, rotate = 270,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -186,7 +185,7 @@ mobs:register_mob("nssm:morbat1", {
run_start = 10, run_start = 10,
run_end = 50, run_end = 50,
punch_start = 100, punch_start = 100,
punch_end = 115, punch_end = 115
} }
}) })
@ -214,7 +213,7 @@ mobs:register_mob("nssm:morbat2", {
jump = true, jump = true,
rotate = 270, rotate = 270,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2}
}, },
armor = 100, armor = 100,
drawtype = "front", drawtype = "front",
@ -236,7 +235,7 @@ mobs:register_mob("nssm:morbat2", {
run_start = 10, run_start = 10,
run_end = 50, run_end = 50,
punch_start = 100, punch_start = 100,
punch_end = 115, punch_end = 115
} }
}) })
@ -265,7 +264,7 @@ mobs:register_mob("nssm:morbat3", {
jump = true, jump = true,
rotate = 270, rotate = 270,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2}
}, },
armor = 100, armor = 100,
drawtype = "front", drawtype = "front",
@ -288,6 +287,6 @@ mobs:register_mob("nssm:morbat3", {
run_start = 10, run_start = 10,
run_end = 50, run_end = 50,
punch_start = 100, punch_start = 100,
punch_end = 115, punch_end = 115
} }
}) })

View File

@ -15,13 +15,13 @@ mobs:register_mob("nssm:morwa", {
walk_velocity = 0.5, walk_velocity = 0.5,
run_velocity = 4, run_velocity = 4,
sounds = { sounds = {
random = "morwa", random = "morwa"
}, },
damage = 8, damage = 8,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 3, max = 4}, {name = "nssm:life_energy", chance = 1, min = 3, max = 4},
{name = "nssm:wrathful_soul_fragment", chance = 3, min = 1, max = 1}, {name = "nssm:wrathful_soul_fragment", chance = 3, min = 1, max = 1}
}, },
armor = 50, armor = 50,
drawtype = "front", drawtype = "front",
@ -53,7 +53,7 @@ mobs:register_mob("nssm:morwa", {
punch_start = 130, punch_start = 130,
punch_end = 160, punch_end = 160,
shoot_start =176, shoot_start =176,
shoot_end=226, shoot_end=226
}, },
do_custom = function (self) do_custom = function (self)
@ -66,5 +66,5 @@ mobs:register_mob("nssm:morwa", {
self.object:remove() self.object:remove()
minetest.set_node(pos, {name = "nssm:morwa_statue"}) minetest.set_node(pos, {name = "nssm:morwa_statue"})
end end
end, end
}) })

View File

@ -19,7 +19,7 @@ mobs:register_mob("nssm:night_master", {
stepheight = 3, stepheight = 3,
sounds = { sounds = {
random = "night_master", random = "night_master",
distance = 45, distance = 45
}, },
damage = 10, damage = 10,
jump = false, jump = false,
@ -43,7 +43,7 @@ mobs:register_mob("nssm:night_master", {
run_start = 20, run_start = 20,
run_end = 50, run_end = 50,
punch_start = 130, punch_start = 130,
punch_end = 160, punch_end = 160
}, },
on_die = function(self, pos) on_die = function(self, pos)
@ -51,12 +51,12 @@ mobs:register_mob("nssm:night_master", {
minetest.add_particlespawner({ minetest.add_particlespawner({
amount = 200, amount = 200,
time = 0.1, time = 0.1,
minpos = {x=pos.x-1, y=pos.y-1, z=pos.z-1}, minpos = {x = pos.x - 1, y = pos.y - 1, z = pos.z - 1},
maxpos = {x=pos.x+1, y=pos.y+1, z=pos.z+1}, maxpos = {x = pos.x + 1, y = pos.y + 1, z = pos.z + 1},
minvel = {x=-0, y=-0, z=-0}, minvel = {x = -0, y = -0, z = -0},
maxvel = {x=1, y=1, z=1}, maxvel = {x = 1, y = 1, z = 1},
minacc = {x=-0.5,y=5,z=-0.5}, minacc = {x = -0.5, y = 5, z = -0.5},
maxacc = {x=0.5,y=5,z=0.5}, maxacc = {x = 0.5, y = 5, z = 0.5},
minexptime = 0.1, minexptime = 0.1,
maxexptime = 1, maxexptime = 1,
minsize = 3, minsize = 3,
@ -68,7 +68,7 @@ mobs:register_mob("nssm:night_master", {
self.object:remove() self.object:remove()
minetest.add_entity(pos, "nssm:night_master_2") minetest.add_entity(pos, "nssm:night_master_2")
end, end
}) })
mobs:register_mob("nssm:night_master_2", { mobs:register_mob("nssm:night_master_2", {
@ -92,7 +92,7 @@ mobs:register_mob("nssm:night_master_2", {
stepheight = 3, stepheight = 3,
sounds = { sounds = {
random = "night_master", random = "night_master",
distance = 45, distance = 45
}, },
damage = 10, damage = 10,
jump = false, jump = false,
@ -114,7 +114,7 @@ mobs:register_mob("nssm:night_master_2", {
run_start = 20, run_start = 20,
run_end = 50, run_end = 50,
punch_start = 130, punch_start = 130,
punch_end = 160, punch_end = 160
}, },
on_die = function(self, pos) on_die = function(self, pos)
@ -122,12 +122,12 @@ mobs:register_mob("nssm:night_master_2", {
minetest.add_particlespawner({ minetest.add_particlespawner({
amount = 200, amount = 200,
time = 0.1, time = 0.1,
minpos = {x=pos.x-1, y=pos.y-1, z=pos.z-1}, minpos = {x = pos.x - 1, y = pos.y - 1, z = pos.z - 1},
maxpos = {x=pos.x+1, y=pos.y+1, z=pos.z+1}, maxpos = {x = pos.x + 1, y = pos.y + 1, z = pos.z + 1},
minvel = {x=-0, y=-0, z=-0}, minvel = {x = -0, y = -0, z = -0},
maxvel = {x=1, y=1, z=1}, maxvel = {x = 1, y = 1, z = 1},
minacc = {x=-0.5,y=5,z=-0.5}, minacc = {x = -0.5, y = 5, z = -0.5},
maxacc = {x=0.5,y=5,z=0.5}, maxacc = {x = 0.5, y = 5, z = 0.5},
minexptime = 0.1, minexptime = 0.1,
maxexptime = 1, maxexptime = 1,
minsize = 3, minsize = 3,
@ -139,7 +139,7 @@ mobs:register_mob("nssm:night_master_2", {
self.object:remove() self.object:remove()
minetest.add_entity(pos, "nssm:night_master_1") minetest.add_entity(pos, "nssm:night_master_1")
end, end
}) })
mobs:register_mob("nssm:night_master_1", { mobs:register_mob("nssm:night_master_1", {
@ -163,14 +163,14 @@ mobs:register_mob("nssm:night_master_1", {
stepheight = 3, stepheight = 3,
sounds = { sounds = {
random = "night_master", random = "night_master",
distance = 45, distance = 45
}, },
damage = 12, damage = 12,
jump = false, jump = false,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 6, max = 7}, {name = "nssm:life_energy", chance = 1, min = 6, max = 7},
{name = "nssm:heron_leg", chance = 1, min = 1, max = 1}, {name = "nssm:heron_leg", chance = 1, min = 1, max = 1},
{name = "nssm:night_feather", chance = 1, min = 1, max = 1}, {name = "nssm:night_feather", chance = 1, min = 1, max = 1}
}, },
armor = 50, armor = 50,
drawtype = "front", drawtype = "front",
@ -190,6 +190,6 @@ mobs:register_mob("nssm:night_master_1", {
run_start = 20, run_start = 20,
run_end = 50, run_end = 50,
punch_start = 130, punch_start = 130,
punch_end = 160, punch_end = 160
} }
}) })

View File

@ -26,7 +26,7 @@ mobs:register_mob("nssm:octopus", {
}, },
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 2, max = 3}, {name = "nssm:life_energy", chance = 1, min = 2, max = 3},
{name = "nssm:tentacle", chance = 1, min = 1, max = 8}, {name = "nssm:tentacle", chance = 1, min = 1, max = 8}
}, },
armor = 70, armor = 70,
drawtype = "front", drawtype = "front",
@ -49,7 +49,7 @@ mobs:register_mob("nssm:octopus", {
run_start = 60, run_start = 60,
run_end = 100, run_end = 100,
punch_start = 120, punch_start = 120,
punch_end = 160, punch_end = 160
} }
}) })
@ -77,11 +77,11 @@ mobs:register_mob("nssm:xgaloctopus", {
jump_chance = 0, jump_chance = 0,
jump_height = 0, jump_height = 0,
sounds = { sounds = {
random = "octopus", random = "octopus"
}, },
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 2, max = 3}, {name = "nssm:life_energy", chance = 1, min = 2, max = 3},
{name = "nssm:tentacle", chance = 1, min = 1, max = 8}, {name = "nssm:tentacle", chance = 1, min = 1, max = 8}
}, },
armor = 60, armor = 60,
drawtype = "front", drawtype = "front",
@ -104,10 +104,10 @@ mobs:register_mob("nssm:xgaloctopus", {
run_start = 60, run_start = 60,
run_end = 100, run_end = 100,
punch_start = 120, punch_start = 120,
punch_end = 160, punch_end = 160
}, },
replace_rate = 1, replace_rate = 1,
replace_what = {"default:torch"}, replace_what = {"default:torch"},
replace_with = "default:water_source", replace_with = "default:water_source",
replace_offset = 0, replace_offset = 0
}) })

View File

@ -19,7 +19,7 @@ mobs:register_mob("nssm:phoenix", {
stepheight = 3, stepheight = 3,
sounds = { sounds = {
random = "phoenix", random = "phoenix",
distance = 45, distance = 45
}, },
damage = 2, damage = 2,
jump = false, jump = false,
@ -27,7 +27,7 @@ mobs:register_mob("nssm:phoenix", {
{name = "nssm:life_energy", chance = 1, min = 7, max = 8}, {name = "nssm:life_energy", chance = 1, min = 7, max = 8},
{name = "nssm:sun_feather", chance = 1, min = 1, max = 1}, {name = "nssm:sun_feather", chance = 1, min = 1, max = 1},
{name = "nssm:phoenix_tear", chance = 1, min = 5, max = 6}, {name = "nssm:phoenix_tear", chance = 1, min = 5, max = 6},
{name = "nssm:phoenix_nuggets", chance = 6, min = 10, max = 20}, {name = "nssm:phoenix_nuggets", chance = 6, min = 10, max = 20}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -54,6 +54,6 @@ mobs:register_mob("nssm:phoenix", {
punch_start = 80, punch_start = 80,
punch_end = 110, punch_end = 110,
shoot_start = 80, shoot_start = 80,
shoot_end = 110, shoot_end = 110
} }
}) })

View File

@ -23,7 +23,7 @@ mobs:register_mob("nssm:pumpboom_small", {
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:black_powder", chance = 2, min = 1, max = 2}, {name = "nssm:black_powder", chance = 2, min = 1, max = 2}
}, },
armor = 100, armor = 100,
drawtype = "front", drawtype = "front",
@ -47,7 +47,7 @@ mobs:register_mob("nssm:pumpboom_small", {
run_start = 81, run_start = 81,
run_end = 97, run_end = 97,
punch_start = 70, punch_start = 70,
punch_end = 80, punch_end = 80
} }
}) })
@ -75,7 +75,7 @@ mobs:register_mob("nssm:pumpboom_medium", {
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 2, max = 3}, {name = "nssm:life_energy", chance = 1, min = 2, max = 3},
{name = "nssm:black_powder", chance = 2, min = 1, max = 3}, {name = "nssm:black_powder", chance = 2, min = 1, max = 3}
}, },
armor = 100, armor = 100,
drawtype = "front", drawtype = "front",
@ -99,7 +99,7 @@ mobs:register_mob("nssm:pumpboom_medium", {
run_start = 81, run_start = 81,
run_end = 97, run_end = 97,
punch_start = 70, punch_start = 70,
punch_end = 80, punch_end = 80
} }
}) })
@ -127,7 +127,7 @@ mobs:register_mob("nssm:pumpboom_large", {
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 3, max = 4}, {name = "nssm:life_energy", chance = 1, min = 3, max = 4},
{name = "nssm:black_powder", chance = 2, min = 2, max = 4}, {name = "nssm:black_powder", chance = 2, min = 2, max = 4}
}, },
armor = 100, armor = 100,
drawtype = "front", drawtype = "front",
@ -151,6 +151,6 @@ mobs:register_mob("nssm:pumpboom_large", {
run_start = 81, run_start = 81,
run_end = 97, run_end = 97,
punch_start = 70, punch_start = 70,
punch_end = 80, punch_end = 80
} }
}) })

View File

@ -18,14 +18,14 @@ mobs:register_mob("nssm:pumpking", {
run_velocity = 4, run_velocity = 4,
sounds = { sounds = {
random = "king", random = "king",
explode = "tnt_explode", explode = "tnt_explode"
}, },
damage = 13, damage = 13,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 7, max = 9}, {name = "nssm:life_energy", chance = 1, min = 7, max = 9},
{name = "nssm:cursed_pumpkin_seed", chance = 1, min = 1, max = 1}, {name = "nssm:cursed_pumpkin_seed", chance = 1, min = 1, max = 1},
{name = "nssm:black_powder", chance = 1, min = 9, max = 12}, {name = "nssm:black_powder", chance = 1, min = 9, max = 12}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -40,11 +40,16 @@ mobs:register_mob("nssm:pumpking", {
jump_height = 12, jump_height = 12,
attack_type = "dogfight", attack_type = "dogfight",
animation = { animation = {
stand_start = 165, stand_end = 210, stand_start = 165,
walk_start = 220, walk_end = 260, stand_end = 210,
run_start = 220, run_end = 260, walk_start = 220,
punch_start = 300, punch_end = 330, walk_end = 260,
speed_normal = 15, speed_run = 15, run_start = 220,
run_end = 260,
punch_start = 300,
punch_end = 330,
speed_normal = 15,
speed_run = 15
}, },
on_die=function(self,pos) on_die=function(self,pos)

View File

@ -16,7 +16,7 @@ mobs:register_mob("nssm:sand_bloco", {
run_velocity = 2, run_velocity = 2,
rotate = 270, rotate = 270,
sounds = { sounds = {
random = "bloco", random = "bloco"
}, },
damage = 4, damage = 4,
reach = 1.5, reach = 1.5,
@ -24,7 +24,7 @@ mobs:register_mob("nssm:sand_bloco", {
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 1}, {name = "nssm:life_energy", chance = 1, min = 1, max = 1},
{name = "default:sandstone", chance = 1, min = 2, max = 3}, {name = "default:sandstone", chance = 1, min = 2, max = 3},
{name = "nssm:sand_bloco_skin", chance = 2, min = 1, max = 3}, {name = "nssm:sand_bloco_skin", chance = 2, min = 1, max = 3}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -47,6 +47,6 @@ mobs:register_mob("nssm:sand_bloco", {
run_start = 190, run_start = 190,
run_end = 200, run_end = 200,
punch_start = 100, punch_start = 100,
punch_end = 130, punch_end = 130
} }
}) })

View File

@ -19,13 +19,13 @@ mobs:register_mob("nssm:sandworm", {
damage = 6, damage = 6,
sounds = { sounds = {
random = "sandworm", random = "sandworm",
distance = 40, distance = 40
}, },
jump = false, jump = false,
drops = { drops = {
{name = "nssm:worm_flesh", chance = 2, min = 1, max = 3}, {name = "nssm:worm_flesh", chance = 2, min = 1, max = 3},
{name = "nssm:sandworm_skin", chance = 2, min = 1, max = 3}, {name = "nssm:sandworm_skin", chance = 2, min = 1, max = 3},
{name = "nssm:life_energy", chance = 1, min = 2, max = 3}, {name = "nssm:life_energy", chance = 1, min = 2, max = 3}
}, },
armor = 60, armor = 60,
drawtype = "front", drawtype = "front",
@ -49,9 +49,9 @@ mobs:register_mob("nssm:sandworm", {
run_start = 110, run_start = 110,
run_end = 140, run_end = 140,
punch_start = 150, punch_start = 150,
punch_end = 180, punch_end = 180
}, },
do_custom = function(self) do_custom = function(self)
digging_attack(self, "sand", self.run_velocity, {x = 0, y = 3, z = 0}) digging_attack(self, "sand", self.run_velocity, {x = 0, y = 3, z = 0})
end, end
}) })

View File

@ -18,13 +18,13 @@ mobs:register_mob("nssm:scrausics", {
floats=1, floats=1,
sounds = { sounds = {
random = "scrausics", random = "scrausics",
distance = 40, distance = 40
}, },
damage = 4, damage = 4,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 3, max = 4}, {name = "nssm:life_energy", chance = 1, min = 3, max = 4},
{name = "nssm:raw_scrausics_wing", chance = 1, min = 1, max = 2}, {name = "nssm:raw_scrausics_wing", chance = 1, min = 1, max = 2}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -48,6 +48,6 @@ mobs:register_mob("nssm:scrausics", {
run_start = 190, run_start = 190,
run_end = 210, run_end = 210,
punch_start = 20, punch_start = 20,
punch_end = 50, punch_end = 50
} }
}) })

View File

@ -21,7 +21,7 @@ mobs:register_mob("nssm:signosigno", {
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:slothful_soul_fragment", chance = 20, min = 1, max = 1}, {name = "nssm:slothful_soul_fragment", chance = 20, min = 1, max = 1}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -44,6 +44,6 @@ mobs:register_mob("nssm:signosigno", {
run_start = 200, run_start = 200,
run_end = 220, run_end = 220,
punch_start = 160, punch_start = 160,
punch_end = 190, punch_end = 190
} }
}) })

View File

@ -18,7 +18,7 @@ mobs:register_mob("nssm:snow_biter", {
walk_velocity = 0.8, walk_velocity = 0.8,
run_velocity = 3, run_velocity = 3,
sounds = { sounds = {
random = "snow_biter", random = "snow_biter"
}, },
damage = 4, damage = 4,
jump = true, jump = true,
@ -26,7 +26,7 @@ mobs:register_mob("nssm:snow_biter", {
{name = "nssm:life_energy", chance = 1, min = 2, max = 3}, {name = "nssm:life_energy", chance = 1, min = 2, max = 3},
{name = "nssm:frosted_amphibian_heart", chance = 2, min = 1, max = 1}, {name = "nssm:frosted_amphibian_heart", chance = 2, min = 1, max = 1},
{name = "nssm:amphibian_ribs", chance = 2, min = 1, max = 1}, {name = "nssm:amphibian_ribs", chance = 2, min = 1, max = 1},
{name = "nssm:little_ice_tooth", chance = 2, min = 0, max = 4}, {name = "nssm:little_ice_tooth", chance = 2, min = 0, max = 4}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -57,5 +57,5 @@ mobs:register_mob("nssm:snow_biter", {
}, },
do_custom = function(self) do_custom = function(self)
putting_ability(self, "default:ice", self.run_velocity) putting_ability(self, "default:ice", self.run_velocity)
end, end
}) })

View File

@ -16,7 +16,7 @@ mobs:register_mob("nssm:spiderduck", {
walk_velocity = 2, walk_velocity = 2,
run_velocity = 4, run_velocity = 4,
sounds = { sounds = {
random = "duck", random = "duck"
}, },
damage = 6, damage = 6,
jump = true, jump = true,
@ -25,7 +25,7 @@ mobs:register_mob("nssm:spiderduck", {
{name = "nssm:duck_legs", chance = 1, min = 1, max = 8}, {name = "nssm:duck_legs", chance = 1, min = 1, max = 8},
{name = "nssm:silk_gland", chance = 2, min = 1, max = 2}, {name = "nssm:silk_gland", chance = 2, min = 1, max = 2},
{name = "nssm:black_duck_feather", chance = 3, min = 1, max = 4}, {name = "nssm:black_duck_feather", chance = 3, min = 1, max = 4},
{name = "nssm:duck_beak", chance = 5, min = 1, max = 1}, {name = "nssm:duck_beak", chance = 5, min = 1, max = 1}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -56,6 +56,6 @@ mobs:register_mob("nssm:spiderduck", {
punch_start = 20, punch_start = 20,
punch_end = 46, punch_end = 46,
shoot_start = 150, shoot_start = 150,
shoot_end = 200, shoot_end = 200
} }
}) })

View File

@ -14,7 +14,7 @@ mobs:register_mob("nssm:stone_eater", {
rotate = 270, rotate = 270,
fear_height = 4, fear_height = 4,
jump = false, jump = false,
jump_height =0, jump_height = 0,
walk_velocity = 1, walk_velocity = 1,
run_velocity = 1.5, run_velocity = 1.5,
damage = 5, damage = 5,
@ -22,7 +22,7 @@ mobs:register_mob("nssm:stone_eater", {
drops = { drops = {
{name = "default:stone", chance = 2, min = 1, max = 3}, {name = "default:stone", chance = 2, min = 1, max = 3},
{name = "nssm:life_energy", chance = 1, min = 2, max = 3}, {name = "nssm:life_energy", chance = 1, min = 2, max = 3},
{name = "nssm:stoneater_mandible", chance = 2, min = 1, max = 4}, {name = "nssm:stoneater_mandible", chance = 2, min = 1, max = 4}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -34,12 +34,12 @@ mobs:register_mob("nssm:stone_eater", {
knock_back = 0, knock_back = 0,
blood_texture = "stone_blood.png", blood_texture = "stone_blood.png",
immune_to={ immune_to={
{'default:sword_stone', -2}, {"default:sword_stone", -2},
{'default:stone', -2}, {"default:stone", -2},
{'default:cobble', -2}, {"default:cobble", -2},
{'default:axe_stone', -2}, {"default:axe_stone", -2},
{'default:shovel_stone', -2}, {"default:shovel_stone", -2},
{'default:pick_stone', -2} {"default:pick_stone", -2}
}, },
light_damage = 0, light_damage = 0,
attack_type = "dogfight", attack_type = "dogfight",
@ -53,10 +53,11 @@ mobs:register_mob("nssm:stone_eater", {
run_start = 130, run_start = 130,
run_end = 150, run_end = 150,
punch_start = 160, punch_start = 160,
punch_end = 185, punch_end = 185
}, },
do_custom = function(self) do_custom = function(self)
--digging_ability(self, "stone", self.run_velocity, {x=0, y=2, z=0}) --digging_ability(self, "stone", self.run_velocity, {x=0, y=2, z=0})
digging_attack(self, "stone", self.run_velocity, {x = 0, y = 1, z = 0}) digging_attack(self, "stone", self.run_velocity, {x = 0, y = 1, z = 0})
end, end
}) })

View File

@ -19,13 +19,13 @@ mobs:register_mob("nssm:swimming_duck", {
jump_chance = 0, jump_chance = 0,
jump_height = 0, jump_height = 0,
sounds = { sounds = {
random = "duck", random = "duck"
}, },
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 1, max = 2}, {name = "nssm:life_energy", chance = 1, min = 1, max = 2},
{name = "nssm:duck_legs", chance = 1, min = 1, max = 2}, {name = "nssm:duck_legs", chance = 1, min = 1, max = 2},
{name = "nssm:duck_beak", chance = 5, min = 1, max = 1}, {name = "nssm:duck_beak", chance = 5, min = 1, max = 1},
{name = "nssm:duck_feather", chance = 6, min = 1, max = 2}, {name = "nssm:duck_feather", chance = 6, min = 1, max = 2}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -48,6 +48,6 @@ mobs:register_mob("nssm:swimming_duck", {
run_start = 80, run_start = 80,
run_end = 120, run_end = 120,
punch_start = 140, punch_start = 140,
punch_end = 160, punch_end = 160
} }
}) })

View File

@ -17,12 +17,12 @@ mobs:register_mob("nssm:tarantula", {
run_velocity = 3, run_velocity = 3,
rotate = 270, rotate = 270,
sounds = { sounds = {
random = "tarry", random = "tarry"
}, },
damage = 8, damage = 8,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:super_silk_gland", chance = 1, min = 3, max = 5}, {name = "nssm:super_silk_gland", chance = 1, min = 3, max = 5}
}, },
armor = 60, armor = 60,
drawtype = "front", drawtype = "front",
@ -51,7 +51,7 @@ mobs:register_mob("nssm:tarantula", {
punch_start = 180, punch_start = 180,
punch_end = 200, punch_end = 200,
shoot_start = 180, shoot_start = 180,
shoot_end = 200, shoot_end = 200
}, },
on_die = function(self, pos) on_die = function(self, pos)
@ -61,12 +61,12 @@ mobs:register_mob("nssm:tarantula", {
minetest.add_particlespawner({ minetest.add_particlespawner({
amount = 200, amount = 200,
time = 0.1, time = 0.1,
minpos = {x=pos.x-1, y=pos.y-1, z=pos.z-1}, minpos = {x = pos.x - 1, y = pos.y - 1, z = pos.z - 1},
maxpos = {x=pos.x+1, y=pos.y+1, z=pos.z+1}, maxpos = {x = pos.x + 1, y = pos.y + 1, z = pos.z + 1},
minvel = {x=-0, y=-0, z=-0}, minvel = {x = -0, y = -0, z = -0},
maxvel = {x=1, y=1, z=1}, maxvel = {x = 1, y = 1, z = 1},
minacc = {x=-0.5,y=5,z=-0.5}, minacc = {x = -0.5, y = 5, z = -0.5},
maxacc = {x=0.5,y=5,z=0.5}, maxacc = {x = 0.5, y = 5, z = 0.5},
minexptime = 0.1, minexptime = 0.1,
maxexptime = 1, maxexptime = 1,
minsize = 3, minsize = 3,
@ -76,7 +76,7 @@ mobs:register_mob("nssm:tarantula", {
}) })
minetest.add_entity(pos, "nssm:tarantula_propower") minetest.add_entity(pos, "nssm:tarantula_propower")
end, end
}) })
@ -98,7 +98,7 @@ mobs:register_mob("nssm:tarantula_propower", {
run_velocity = 3.3, run_velocity = 3.3,
rotate = 270, rotate = 270,
sounds = { sounds = {
random = "tarry", random = "tarry"
}, },
damage = 12, damage = 12,
jump = true, jump = true,
@ -107,7 +107,7 @@ mobs:register_mob("nssm:tarantula_propower", {
{name = "nssm:spider_leg", chance = 1, min = 1, max = 8}, {name = "nssm:spider_leg", chance = 1, min = 1, max = 8},
{name = "nssm:tarantula_chelicerae", chance = 1, min = 1, max = 1}, {name = "nssm:tarantula_chelicerae", chance = 1, min = 1, max = 1},
{name = "nssm:silk_gland", chance = 2, min = 1, max = 3}, {name = "nssm:silk_gland", chance = 2, min = 1, max = 3},
{name = "nssm:spider_meat", chance = 2, min = 1, max = 2}, {name = "nssm:spider_meat", chance = 2, min = 1, max = 2}
}, },
armor = 40, armor = 40,
drawtype = "front", drawtype = "front",
@ -130,6 +130,6 @@ mobs:register_mob("nssm:tarantula_propower", {
run_start = 140, run_start = 140,
run_end = 160, run_end = 160,
punch_start = 180, punch_start = 180,
punch_end = 200, punch_end = 200
} }
}) })

View File

@ -16,7 +16,7 @@ mobs:register_mob("nssm:uloboros", {
run_velocity = 2.5, run_velocity = 2.5,
rotate = 270, rotate = 270,
sounds = { sounds = {
random = "uloboros", random = "uloboros"
}, },
damage = 5, damage = 5,
reach = 2, reach = 2,
@ -25,7 +25,7 @@ mobs:register_mob("nssm:uloboros", {
{name = "nssm:life_energy", chance = 1, min = 1, max = 4}, {name = "nssm:life_energy", chance = 1, min = 1, max = 4},
{name = "nssm:spider_leg", chance = 2, min = 1, max = 8}, {name = "nssm:spider_leg", chance = 2, min = 1, max = 8},
{name = "nssm:silk_gland", chance = 4, min = 1, max = 3}, {name = "nssm:silk_gland", chance = 4, min = 1, max = 3},
{name = "nssm:spider_meat", chance = 4, min = 1, max = 2}, {name = "nssm:spider_meat", chance = 4, min = 1, max = 2}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -49,9 +49,10 @@ mobs:register_mob("nssm:uloboros", {
run_start = 120, run_start = 120,
run_end = 160, run_end = 160,
punch_start = 80, punch_start = 80,
punch_end = 110, punch_end = 110
}, },
do_custom = function(self) do_custom = function(self)
webber_ability(self, "nssm:web", 2) webber_ability(self, "nssm:web", 2)
end, end
}) })

View File

@ -15,14 +15,14 @@ mobs:register_mob("nssm:werewolf", {
fear_height = 4, fear_height = 4,
run_velocity = 5, run_velocity = 5,
sounds = { sounds = {
random = "werewolf", random = "werewolf"
}, },
damage = 5, damage = 5,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 3, max = 4}, {name = "nssm:life_energy", chance = 1, min = 3, max = 4},
{name = "nssm:werewolf_leg", chance = 2, min = 1, max = 2}, {name = "nssm:werewolf_leg", chance = 2, min = 1, max = 2},
{name = "nssm:wolf_fur", chance = 2, min = 1, max = 1}, {name = "nssm:wolf_fur", chance = 2, min = 1, max = 1}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -46,6 +46,6 @@ mobs:register_mob("nssm:werewolf", {
run_start = 140, run_start = 140,
run_end = 160, run_end = 160,
punch_start = 170, punch_start = 170,
punch_end = 193, punch_end = 193
} }
}) })

View File

@ -15,14 +15,14 @@ mobs:register_mob("nssm:white_werewolf", {
fear_height = 4, fear_height = 4,
run_velocity = 5, run_velocity = 5,
sounds = { sounds = {
random = "werewolf", random = "werewolf"
}, },
damage = 5, damage = 5,
jump = true, jump = true,
drops = { drops = {
{name = "nssm:life_energy", chance = 1, min = 3, max = 4}, {name = "nssm:life_energy", chance = 1, min = 3, max = 4},
{name = "nssm:werewolf_leg", chance = 2, min = 1, max = 2}, {name = "nssm:werewolf_leg", chance = 2, min = 1, max = 2},
{name = "nssm:white_wolf_fur", chance = 2, min = 1, max = 1}, {name = "nssm:white_wolf_fur", chance = 2, min = 1, max = 1}
}, },
armor = 80, armor = 80,
drawtype = "front", drawtype = "front",
@ -46,6 +46,6 @@ mobs:register_mob("nssm:white_werewolf", {
run_start = 140, run_start = 140,
run_end = 160, run_end = 160,
punch_start = 170, punch_start = 170,
punch_end = 193, punch_end = 193
} }
}) })