Mgen none special handling for flying mobs

This commit is contained in:
sapier 2013-10-03 19:47:26 +02:00
parent 52ab587e42
commit 860e024106

View File

@ -54,8 +54,12 @@ function mgen_none.callback(entity,now)
entity.data.movement.canfly)
entity.object:setacceleration({x=0,y=default_y_acceleration,z=0})
entity.object:setvelocity({x=0,y=speed.y,z=0})
if default_y_acceleration ~= 0 then
entity.object:setvelocity({x=0,y=speed.y,z=0})
else
entity.object:setvelocity({x=0,y=0,z=0})
end
end