fix passenger dettach

master
Alexsandro Percy 2022-01-22 19:17:29 -03:00
parent 3e53421137
commit 9afb728d12
1 changed files with 6 additions and 4 deletions

View File

@ -113,10 +113,12 @@ function helicopter.dettach_pax(self, player)
self._passenger = nil
-- detach the player
player:set_detach()
player_api.player_attached[name] = nil
player:set_eye_offset({x=0,y=0,z=0},{x=0,y=0,z=0})
player_api.set_animation(player, "stand")
if player then
player:set_detach()
player_api.player_attached[name] = nil
player:set_eye_offset({x=0,y=0,z=0},{x=0,y=0,z=0})
player_api.set_animation(player, "stand")
end
end
-- destroy the helicopter