forked from MineClone5/MineClone5
Fix enderman teleport attack
This commit is contained in:
parent
4fb9e69e41
commit
f6fa90096d
|
@ -282,8 +282,8 @@ mobs:register_mob("mobs_mc:enderman", {
|
||||||
--self:teleport(nil)
|
--self:teleport(nil)
|
||||||
--self.state = ""
|
--self.state = ""
|
||||||
--else
|
--else
|
||||||
if self.attack then
|
if self.attacking then
|
||||||
local target = self.attack
|
local target = self.attacking
|
||||||
local pos = target:get_pos()
|
local pos = target:get_pos()
|
||||||
if pos ~= nil then
|
if pos ~= nil then
|
||||||
if vector.distance(self.object:get_pos(), target:get_pos()) > 10 then
|
if vector.distance(self.object:get_pos(), target:get_pos()) > 10 then
|
||||||
|
|
Loading…
Reference in New Issue