diff options
author | orwell96 <orwell@bleipb.de> | 2018-11-20 11:57:46 +0100 |
---|---|---|
committer | orwell96 <orwell@bleipb.de> | 2018-11-20 11:57:46 +0100 |
commit | 37166b5c142b6b3578e589b75b86d2e11345f49d (patch) | |
tree | a3f09325dbe4c141d277c11c7a9016a6b711e1bb /advtrains_luaautomation/atc_rail.lua | |
parent | 8b80742fa5b21392999dbe6a3d259d57068899f3 (diff) | |
download | advtrains-37166b5c142b6b3578e589b75b86d2e11345f49d.tar.gz advtrains-37166b5c142b6b3578e589b75b86d2e11345f49d.tar.bz2 advtrains-37166b5c142b6b3578e589b75b86d2e11345f49d.zip |
Make "Line" property accessible from OBC and gettable via LATC, change subway wagon texture handling
Diffstat (limited to 'advtrains_luaautomation/atc_rail.lua')
-rw-r--r-- | advtrains_luaautomation/atc_rail.lua | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/advtrains_luaautomation/atc_rail.lua b/advtrains_luaautomation/atc_rail.lua index 1fab620..6a3959c 100644 --- a/advtrains_luaautomation/atc_rail.lua +++ b/advtrains_luaautomation/atc_rail.lua @@ -54,8 +54,14 @@ function r.fire_event(pos, evtdata) return true end, set_line = function(line) - train.line = line - return true + if type(line)~="string" and type(line)~="number" then + return false + end + train.line = line .. "" + return true + end, + get_line = function() + return train.line end, atc_reset = function(cmd) if not train_id then return false end |