diff options
author | orwell <orwell@bleipb.de> | 2024-12-01 23:51:41 +0100 |
---|---|---|
committer | orwell <orwell@bleipb.de> | 2024-12-01 23:51:41 +0100 |
commit | c081129fe040d2dd62d36777ec5eeae315fd0928 (patch) | |
tree | 5f2ea14aec4ab5d3829027ac2b824349eed9b14f /advtrains/trackplacer.lua | |
parent | 2bfc24ef27ea4098a93cc025b513afe1b8c4ee1f (diff) | |
download | advtrains-c081129fe040d2dd62d36777ec5eeae315fd0928.tar.gz advtrains-c081129fe040d2dd62d36777ec5eeae315fd0928.tar.bz2 advtrains-c081129fe040d2dd62d36777ec5eeae315fd0928.zip |
Misc Fixes found during play
Diffstat (limited to 'advtrains/trackplacer.lua')
-rw-r--r-- | advtrains/trackplacer.lua | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/advtrains/trackplacer.lua b/advtrains/trackplacer.lua index 1543209..3278b8c 100644 --- a/advtrains/trackplacer.lua +++ b/advtrains/trackplacer.lua @@ -152,10 +152,10 @@ local function check_or_bend_rail(origin, dir, pname, commit) end end -local function track_place_node(pos, node, ndef, pname) +local function track_place_node(pos, node, ndef_p, pname) --atdebug("track_place_node: ",pos, node) advtrains.ndb.swap_node(pos, node) - local ndef = minetest.registered_nodes[node.name] + local ndef = ndef_p or minetest.registered_nodes[node.name] if ndef and ndef.after_place_node then -- resolve player again local player = pname and core.get_player_by_name(pname) or nil @@ -202,7 +202,7 @@ function tp.place_track(pos, tpg, pname, yaw) if node then check_or_bend_rail(pos, conn1, pname, true) check_or_bend_rail(pos, conn2, pname, true) - track_place_node(pos, node, pname) -- calls after_place_node implicitly + track_place_node(pos, node, nil, pname) -- calls after_place_node implicitly return true end end |