Martmists

Sample time + day

Apr 3rd, 2015
292
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.38 KB | None | 0 0
  1. br = peripheral.wrap("openperipheral_ticketmachine_0")
  2. br.clear()
  3. boxtime = br.addBox(5,5,100,10,0xFFFFFF,0.5)
  4. texttime = br.addText(6,6," ",0x123456)
  5. boxday = br.addBox(125,5,80,10,0xFFFFFF,0.5)
  6. textday = br.addText(126 ,6," ",0x123456)
  7. loop = true
  8. while true do
  9. time = os.time()
  10. day = os.day()
  11. texttime.setText("Current time: "..time)
  12. textday.setText("Current day: "..day)
Advertisement
Add Comment
Please, Sign In to add comment