fix crash when blaze attacks logged off player
parent
414e2e7725
commit
379972ea11
|
@ -77,7 +77,7 @@ mobs:register_mob("mobs_mc:blaze", {
|
||||||
glow = 14,
|
glow = 14,
|
||||||
fire_resistant = true,
|
fire_resistant = true,
|
||||||
do_custom = function(self)
|
do_custom = function(self)
|
||||||
if self.state == "attack" and vector.distance(self.object:get_pos(), self.attack:get_pos()) < 1.2 then
|
if self.state == "attack" and self.attack:get_pos() and vector.distance(self.object:get_pos(), self.attack:get_pos()) < 1.2 then
|
||||||
mcl_burning.set_on_fire(self.attack, 5)
|
mcl_burning.set_on_fire(self.attack, 5)
|
||||||
end
|
end
|
||||||
local pos = self.object:get_pos()
|
local pos = self.object:get_pos()
|
||||||
|
|
Loading…
Reference in New Issue