summaryrefslogtreecommitdiff
path: root/far/nodes/(30834,16,1863).lua
blob: 580113418bbbaa615f5012b82cbed57302db470d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
-- far_luaatctrack_farcom_op_01.lua


if event.type == "punch" then
--  F.delete_train_info("298909")
  S.stop_display = false

  F.send_update_displays()

  if S.stop_display then
    date = F.date_formatted()
    time = F.time_formatted()
    digiline_send("time", "    FAR COM\n\n   " .. date .. "\n " .. time)
    F.list_trains(true)
  else
    local pos = POS(30848,15,1852)
    interrupt_pos(pos, "display")
  end

  return
end

if event.type == "digiline" then
  if event.channel == "display" then
    if event.msg == "update" then
      date = F.date_formatted()
      time = F.time_formatted()
      digiline_send("time", "    FAR COM\n\n   " .. date .. "\n " .. time)
      F.list_trains(false)
    end
  end
  return
end