mirror of
https://github.com/APercy/airutils.git
synced 2025-03-21 18:41:21 +00:00
fix attach
This commit is contained in:
parent
e9547307d2
commit
8dcac84155
1 changed files with 4 additions and 0 deletions
|
@ -555,6 +555,10 @@ function airutils.checkattachBug(self)
|
||||||
local have_driver = (self.driver_name ~= nil)
|
local have_driver = (self.driver_name ~= nil)
|
||||||
if have_driver then
|
if have_driver then
|
||||||
-- attach the driver again
|
-- attach the driver again
|
||||||
|
if self.driver_name ~= self.owner then
|
||||||
|
self.driver_name = nil
|
||||||
|
return
|
||||||
|
end
|
||||||
local player = minetest.get_player_by_name(self.driver_name)
|
local player = minetest.get_player_by_name(self.driver_name)
|
||||||
if player then
|
if player then
|
||||||
if player:get_hp() > 0 then
|
if player:get_hp() > 0 then
|
||||||
|
|
Loading…
Add table
Reference in a new issue