aboutsummaryrefslogtreecommitdiff
path: root/advtrains_interlocking
diff options
context:
space:
mode:
authororwell96 <orwell@bleipb.de>2018-10-17 17:37:03 +0200
committerorwell96 <orwell@bleipb.de>2018-10-17 17:37:03 +0200
commite04d84cb4c137d006587f932b149007bdbe6823a (patch)
tree7cb8953e87c823c9bfc967c58ddb3bba735d4ba5 /advtrains_interlocking
parent85d752df6b33e190be71cddeb7839fc482be1bda (diff)
downloadadvtrains-e04d84cb4c137d006587f932b149007bdbe6823a.tar.gz
advtrains-e04d84cb4c137d006587f932b149007bdbe6823a.tar.bz2
advtrains-e04d84cb4c137d006587f932b149007bdbe6823a.zip
Actually allow what manual promises (setting IP on non-assigned signals)
Diffstat (limited to 'advtrains_interlocking')
-rw-r--r--advtrains_interlocking/route_prog.lua2
-rw-r--r--advtrains_interlocking/signal_api.lua3
2 files changed, 4 insertions, 1 deletions
diff --git a/advtrains_interlocking/route_prog.lua b/advtrains_interlocking/route_prog.lua
index 2ec9375..70eceb8 100644
--- a/advtrains_interlocking/route_prog.lua
+++ b/advtrains_interlocking/route_prog.lua
@@ -239,7 +239,7 @@ end
local function do_advance_route(pname, rp, sigd, tsname)
table.insert(rp.route, {next = sigd, locks = rp.tmp_lcks})
rp.tmp_lcks = {}
- chat(pname, "Added track section '"..tsname.."' to the route (revert with /at_rp_back)")
+ chat(pname, "Added track section '"..tsname.."' to the route.")
end
local function finishrpform(pname)
diff --git a/advtrains_interlocking/signal_api.lua b/advtrains_interlocking/signal_api.lua
index 3a042c0..3bc2705 100644
--- a/advtrains_interlocking/signal_api.lua
+++ b/advtrains_interlocking/signal_api.lua
@@ -230,6 +230,9 @@ local players_assign_ip = {}
-- shows small info form for signal IP state/assignment
-- only_notset: show only if it is not set yet (used by signal tcb assignment)
function advtrains.interlocking.show_ip_form(pos, pname, only_notset)
+ if not minetest.check_player_privs(pname, "interlocking") then
+ return
+ end
local form = "size[7,5]label[0.5,0.5;Signal at "..minetest.pos_to_string(pos).."]"
local pts, connid = advtrains.interlocking.db.get_ip_by_signalpos(pos)
if pts then