forked from VoxeLibre/VoxeLibre
Add moveresult variable passing to on_step() of mob entity, Wuzzy/MineClone2#837
This commit is contained in:
parent
15cb94b9b3
commit
8df2aebd31
|
@ -13,8 +13,8 @@ minetest.register_on_mods_loaded(function()
|
||||||
if not on_step_old then
|
if not on_step_old then
|
||||||
on_step_old = function() end
|
on_step_old = function() end
|
||||||
end
|
end
|
||||||
local on_step = function(self, dtime)
|
local on_step = function(self, dtime, moveresult)
|
||||||
on_step_old(self, dtime)
|
on_step_old(self, dtime, moveresult)
|
||||||
local obj = self.object
|
local obj = self.object
|
||||||
local pos = obj:get_pos()
|
local pos = obj:get_pos()
|
||||||
-- Old on_step function might have deleted object,
|
-- Old on_step function might have deleted object,
|
||||||
|
|
Loading…
Reference in New Issue