aboutsummaryrefslogtreecommitdiff
path: root/advtrains/trainlogic.lua
diff options
context:
space:
mode:
authororwell96 <orwell@bleipb.de>2021-04-25 22:13:24 +0200
committerorwell96 <orwell@bleipb.de>2021-04-25 22:13:24 +0200
commit5aa700c3ab14434e36cabb2ba7c9f053e52730cc (patch)
tree1a3dea53bc17caab256ddf9af5e328248f081057 /advtrains/trainlogic.lua
parent571a5cd19b5f9ea1feebbfdef678865039b71370 (diff)
downloadadvtrains-5aa700c3ab14434e36cabb2ba7c9f053e52730cc.tar.gz
advtrains-5aa700c3ab14434e36cabb2ba7c9f053e52730cc.tar.bz2
advtrains-5aa700c3ab14434e36cabb2ba7c9f053e52730cc.zip
Deregister player from train on death in all cases (fixes #119)release-2.3.0
Diffstat (limited to 'advtrains/trainlogic.lua')
-rw-r--r--advtrains/trainlogic.lua2
1 files changed, 2 insertions, 0 deletions
diff --git a/advtrains/trainlogic.lua b/advtrains/trainlogic.lua
index 499144b..d83d89f 100644
--- a/advtrains/trainlogic.lua
+++ b/advtrains/trainlogic.lua
@@ -163,6 +163,8 @@ minetest.register_on_dieplayer(function(player)
wagon:get_off_plr(pname)
end
end
+ -- just in case no wagon felt responsible for this player: clear train mapping
+ advtrains.player_to_train_mapping[pname] = nil
end
end)