95Roadkill

Vinex Gui

Oct 27th, 2014
255
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.51 KB | None | 0 0
  1. while true do
  2.  
  3. term.clear()
  4. term.setCursorPos(1,1)
  5. print("[|]--------------[|]--------------------------[|]")
  6. print(" |1:Update Notes  |                            |")
  7. print(" |----------------|                            |")
  8. print(" |2:Alarm         |                            |")
  9. print(" |----------------|                            |")
  10. print(" |3:Cookie        |                            |")
  11. print(" |----------------|                            |")
  12. print(" |4:Log Out       |                            |")
  13. print(" |----------------|                            |")
  14. print(" |5:Shutdown      |                            |")
  15. print(" |----------------|                            |")
  16. print(" |0:Next Page     |                            |")
  17. print("[|]--------------[|]                           |")
  18. print(" |                                             |")
  19. print(" |                                             |")
  20. print(" |                                             |")
  21. print("[|]-------------------------------------------[|]")
  22.  
  23.  
  24. event,key = os.pullEvent("char")
  25.  
  26. if key == "1" then
  27.   shell.run("Vinex/Note")
  28.   break
  29. elseif key == "2" then
  30.   shell.run("Vinex/Alarm")
  31.   break
  32. elseif key == "3" then
  33.   shell.run("Vinex/Cookie")
  34.   break
  35. elseif key == "4" then
  36.   os.reboot(true)
  37. elseif key == "5" then
  38.   os.shutdown(true)
  39. elseif key == "0" then
  40.   sleep(0.3)
  41.   shell.run("Vinex/GUI2")
  42.   break
  43. else
  44.   term.setCursorPos(3,14)
  45.   print("You pressed an invalid option")
  46.   sleep(3)
  47. end
  48.  
  49. end
Add Comment
Please, Sign In to add comment