Make strider usable
parent
21f5586669
commit
3629f88dc0
|
@ -90,9 +90,12 @@ local strider = {
|
|||
|
||||
-- if driver present allow control of horse
|
||||
if self.driver then
|
||||
|
||||
local pos = self.object:get_pos()
|
||||
local v = self.object:get_velocity()
|
||||
self.object:set_velocity(vector.new(v.x,0,v.z))
|
||||
mcl_mobs.drive(self, "walk", "stand", false, dtime)
|
||||
|
||||
local l = minetest.find_node_near(pos,2,{"group:lava"})
|
||||
if l then self.object:set_pos(vector.new(pos.x,l.y+0.5,pos.z)) end
|
||||
return false -- skip rest of mob functions
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue