mirror of
https://git.minetest.land/VoxeLibre/VoxeLibre.git
synced 2024-11-25 20:11:06 +01:00
Make strider usable
This commit is contained in:
parent
21f5586669
commit
3629f88dc0
1 changed files with 5 additions and 2 deletions
|
@ -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 a new issue