diff --git a/mods/ENTITIES/mobs_mc/hoglin+zoglin.lua b/mods/ENTITIES/mobs_mc/hoglin+zoglin.lua index 4714ff31c..29c8bae7a 100644 --- a/mods/ENTITIES/mobs_mc/hoglin+zoglin.lua +++ b/mods/ENTITIES/mobs_mc/hoglin+zoglin.lua @@ -84,7 +84,7 @@ local hoglin = { else self._zombie_transform_timer = nil end - if self._zombie_transform_timer >= 15 then + if self._zombie_transform_timer and self._zombie_transform_timer >= 15 then local zog = minetest.add_entity(self.object:get_pos(), "mobs_mc:zoglin") zog:set_rotation(self.object:get_rotation()) mcl_potions.give_effect("nausea", zog, 1, 10) @@ -130,7 +130,7 @@ baby_hoglin.do_custom = function(self, dtime) else self._zombie_transform_timer = nil end - if self._zombie_transform_timer >= 15 then + if self._zombie_transform_timer and self._zombie_transform_timer >= 15 then local zog = minetest.add_entity(self.object:get_pos(), "mobs_mc:baby_zoglin") zog:set_rotation(self.object:get_rotation()) mcl_potions.give_effect("nausea", zog, 1, 10) diff --git a/mods/ENTITIES/mobs_mc/piglin.lua b/mods/ENTITIES/mobs_mc/piglin.lua index fb3d575c7..bd9c15971 100644 --- a/mods/ENTITIES/mobs_mc/piglin.lua +++ b/mods/ENTITIES/mobs_mc/piglin.lua @@ -109,7 +109,7 @@ local piglin = { else self._zombie_transform_timer = nil end - if self._zombie_transform_timer >= 15 then + if self._zombie_transform_timer and self._zombie_transform_timer >= 15 then local zog = minetest.add_entity(self.object:get_pos(), "mobs_mc:zombified_piglin") zog:set_rotation(self.object:get_rotation()) mcl_potions.give_effect("nausea", zog, 1, 10) @@ -269,7 +269,7 @@ local zombified_piglin = { textures = { { "blank.png", --baby "default_tool_goldsword.png", --sword - "mobs_mc_zombie_pigman.png", --pigman + "extra_mobs_zombified_piglin.png", --pigman } }, visual_size = {x=3, y=3}, sounds = { @@ -376,7 +376,7 @@ piglin_brute.do_custom = function(self, dtime) else self._zombie_transform_timer = nil end - if self._zombie_transform_timer >= 15 then + if self._zombie_transform_timer and self._zombie_transform_timer >= 15 then local zog = minetest.add_entity(self.object:get_pos(), "mobs_mc:zombified_piglin") zog:set_rotation(self.object:get_rotation()) mcl_potions.give_effect("nausea", zog, 1, 10) @@ -496,4 +496,4 @@ mcl_mobs:non_spawn_specific("mobs_mc:zombified_piglin","overworld",0,minetest.LI mcl_mobs.register_egg("mobs_mc:piglin", S("Piglin"), "#7b4a17","#d5c381", 0) mcl_mobs.register_egg("mobs_mc:piglin_brute", S("Piglin Brute"), "#562b0c","#ddc89d", 0) -mcl_mobs.register_egg("mobs_mc:zombified_piglin", S("Zombie Piglin"), "#ea9393", "#4c7129", 0) \ No newline at end of file +mcl_mobs.register_egg("mobs_mc:zombified_piglin", S("Zombie Piglin"), "#ea9393", "#4c7129", 0)