projects
/
oweals
/
minetest_game.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b787fcf
)
Carts: Re-add erroneously removed driver reset
author
SmallJoker
<mk939@ymail.com>
Sat, 16 May 2020 17:26:28 +0000
(19:26 +0200)
committer
SmallJoker
<mk939@ymail.com>
Sat, 16 May 2020 17:26:28 +0000
(19:26 +0200)
carts:manage_attachment does not handle the driver value of the cart,
hence carts could not be used by another player until it's replaced.
mods/carts/cart_entity.lua
patch
|
blob
|
history
diff --git
a/mods/carts/cart_entity.lua
b/mods/carts/cart_entity.lua
index b95fde703eba92cc9f141efb040ec16e8eacb95c..734711be9714bed849d60612f5784bc379ce4e7b 100644
(file)
--- a/
mods/carts/cart_entity.lua
+++ b/
mods/carts/cart_entity.lua
@@
-66,6
+66,7
@@
end
-- 0.5.x and later: When the driver leaves
function cart_entity:on_detach_child(child)
if child and child:get_player_name() == self.driver then
+ self.driver = nil
carts:manage_attachment(child, nil)
end
end