forked from MineClone5/MineClone5
Gut even more elements of the api
This commit is contained in:
parent
220d30df5f
commit
ed60266713
|
@ -604,14 +604,15 @@ end
|
||||||
|
|
||||||
local mob_step = function(self, dtime)
|
local mob_step = function(self, dtime)
|
||||||
|
|
||||||
|
--do not continue if non-existent
|
||||||
if not self or not self.object or not self.object:get_luaentity() then
|
if not self or not self.object or not self.object:get_luaentity() then
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
|
|
||||||
if self.state == "die" then
|
--if self.state == "die" then
|
||||||
print("need custom die stop moving thing")
|
-- print("need custom die stop moving thing")
|
||||||
return
|
-- return
|
||||||
end
|
--end
|
||||||
|
|
||||||
-- can mob be pushed, if so calculate direction -- do this first to prevent issues
|
-- can mob be pushed, if so calculate direction -- do this first to prevent issues
|
||||||
if self.pushable then
|
if self.pushable then
|
||||||
|
@ -629,8 +630,8 @@ local mob_step = function(self, dtime)
|
||||||
--cmi.notify_step(self.object, dtime)
|
--cmi.notify_step(self.object, dtime)
|
||||||
--end
|
--end
|
||||||
|
|
||||||
local pos = self.object:get_pos()
|
--local pos = self.object:get_pos()
|
||||||
local yaw = 0
|
--local yaw = 0
|
||||||
|
|
||||||
--if mobs_debug then
|
--if mobs_debug then
|
||||||
--update_tag(self)
|
--update_tag(self)
|
||||||
|
@ -653,6 +654,7 @@ local mob_step = function(self, dtime)
|
||||||
|
|
||||||
-- smooth rotation by ThomasMonroe314
|
-- smooth rotation by ThomasMonroe314
|
||||||
|
|
||||||
|
--[[
|
||||||
if self.delay and self.delay > 0 then
|
if self.delay and self.delay > 0 then
|
||||||
|
|
||||||
local yaw = self.object:get_yaw() or 0
|
local yaw = self.object:get_yaw() or 0
|
||||||
|
@ -692,6 +694,7 @@ local mob_step = function(self, dtime)
|
||||||
self.object:set_yaw(yaw)
|
self.object:set_yaw(yaw)
|
||||||
--update_roll(self)
|
--update_roll(self)
|
||||||
end
|
end
|
||||||
|
]]--
|
||||||
|
|
||||||
-- end rotation
|
-- end rotation
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue