Advertisement
Guest User

startup

a guest
Aug 4th, 2015
173
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.28 KB | None | 0 0
  1. mon = peripheral.wrap("top")
  2.  
  3. while (true) do
  4.   text = textutils.formatTime(os.time(), true)
  5.   w, h = mon.getSize()
  6.   x = math.max(math.floor((w / 2) - (#text / 2)), 0)
  7.   x = x + 2
  8.   mon.clear()
  9.   mon.setTextScale(1.5)
  10.   mon.setCursorPos(x,2)
  11.   mon.write(text)
  12.   sleep(2)
  13. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement