diff options
Diffstat (limited to 'advtrains_luaautomation/active_common.lua')
-rw-r--r-- | advtrains_luaautomation/active_common.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/advtrains_luaautomation/active_common.lua b/advtrains_luaautomation/active_common.lua index 8d0975f..3dc018d 100644 --- a/advtrains_luaautomation/active_common.lua +++ b/advtrains_luaautomation/active_common.lua @@ -71,7 +71,12 @@ function ac.on_receive_fields(pos, formname, fields, player) nodetbl.code=fields.code end if fields.save then + -- reset certain things nodetbl.err=nil + if advtrains.lines and advtrains.lines.sched then + -- discard all schedules for this node + advtrains.lines.sched.discard_all(advtrains.encode_pos(pos)) + end end if fields.cle then nodetbl.data={} |