aboutsummaryrefslogtreecommitdiff
path: root/advtrains
diff options
context:
space:
mode:
authororwell96 <mono96.mml@gmail.com>2017-02-05 20:14:37 +0100
committerorwell96 <mono96.mml@gmail.com>2017-02-05 20:14:37 +0100
commit648e501f46d3e8f1600e7639924bddae4e577796 (patch)
tree6cecc71d2e37c72dbe3796820ee3ce206ece6c33 /advtrains
parentb31229d62e05e76a2a658e3b8ed85bd26059cc0e (diff)
downloadadvtrains-648e501f46d3e8f1600e7639924bddae4e577796.tar.gz
advtrains-648e501f46d3e8f1600e7639924bddae4e577796.tar.bz2
advtrains-648e501f46d3e8f1600e7639924bddae4e577796.zip
Fix "lock couples" checkbox on wagon properties form
Diffstat (limited to 'advtrains')
-rw-r--r--advtrains/advtrains/wagons.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/advtrains/advtrains/wagons.lua b/advtrains/advtrains/wagons.lua
index bf99718..c5ce6bf 100644
--- a/advtrains/advtrains/wagons.lua
+++ b/advtrains/advtrains/wagons.lua
@@ -666,7 +666,9 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
wagon.seat_access[sgr] = fcont~="" and fcont or nil
end
end
- wagon.lock_couples = fields.lock_couples == "true"
+ if fields.lock_couples then
+ wagon.lock_couples = fields.lock_couples == "true"
+ end
end
end
end