Advertisement
Daraketh

Basic Clock

Aug 25th, 2013
42
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.32 KB | None | 0 0
  1. side = "top" --This is the side of the monitor
  2. text = "Joss Inc."
  3. mon = peripheral.wrap(side)
  4. mon.setTextScale(2)
  5. while true
  6. do
  7.  mon.setCursorPos(1,1)
  8.  mon.write(text)
  9.  mon.setCursorPos(1,2)
  10.  mon.write(textutils.formatTime(os.time(),false)) -- use true for 12h time
  11.  sleep(1)
  12.  mon.clear()
  13.  term.setCursorPos(1,1)
  14. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement