3 --made for MC like Survival game
4 --License for code WTFPL and otherwise stated in readmes
6 local S
= minetest
.get_translator("mobs_mc")
9 --################### WITHER
12 mobs
:register_mob("mobs_mc:wither", {
14 spawn_class
= "hostile",
18 -- This deviates from MC Wiki's size, which makes no sense
19 collisionbox
= {-0.9, 0.4, -0.9, 0.9, 2.45, 0.9},
21 mesh
= "mobs_mc_wither.b3d",
23 {"mobs_mc_wither.png"},
25 visual_size
= {x
=4, y
=4},
26 makes_footstep_sound
= true,
32 shoot_attack
= "mobs_mc_ender_dragon_shoot",
33 attack
= "mobs_mc_ender_dragon_attack",
41 dogshoot_count_max
=1,
42 attack_animals
= true,
44 {name
= mobs_mc
.items
.nether_star
,
51 attack_type
= "dogshoot",
52 explosion_strength
= 8,
54 arrow
= "mobs_mc:wither_skull",
59 walk_speed
= 12, run_speed
= 12, stand_speed
= 12,
60 stand_start
= 0, stand_end
= 20,
61 walk_start
= 0, walk_end
= 20,
62 run_start
= 0, run_end
= 20,
66 local mobs_griefing
= minetest
.settings
:get_bool("mobs_griefing") ~= false
68 mobs
:register_arrow("mobs_mc:wither_skull", {
70 visual_size
= {x
= 0.75, y
= 0.75},
71 -- TODO: 3D projectile, replace tetxture
72 textures
= {"mobs_mc_TEMP_wither_projectile.png"},
76 hit_player
= function(self
, player
)
77 player
:punch(self
.object
, 1.0, {
78 full_punch_interval
= 0.5,
79 damage_groups
= {fleshy
= 8},
81 mobs
:boom(self
, self
.object
:get_pos(), 1)
84 hit_mob
= function(self
, mob
)
85 mob
:punch(self
.object
, 1.0, {
86 full_punch_interval
= 0.5,
87 damage_groups
= {fleshy
= 8},
89 mobs
:boom(self
, self
.object
:get_pos(), 1)
93 hit_node
= function(self
, pos
, node
)
94 mobs
:boom(self
, pos
, 1)
97 -- TODO: Add blue wither skull
100 mobs
:register_egg("mobs_mc:wither", S("Wither"), "mobs_mc_spawn_icon_wither.png", 0, true)