Set player above controller after detaching

This commit is contained in:
stujones11 2017-02-05 18:57:50 +00:00
parent 516a2ae617
commit c6ef2fb2fb
1 changed files with 4 additions and 0 deletions

View File

@ -481,6 +481,10 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
entity.animation = "stand"
entity.object:set_animation({x=20, y=100}, 15)
default.player_attached[name] = false
local p = player:getpos()
minetest.after(0.1, function()
player:setpos({x=p.x, y=p.y + 1, z=p.z})
end)
elseif fields.animation_sit then
default.player_set_animation(player, "sit", 30)
entity.animation = "sit"