Advertisement
Derek1017

Missle Launch 2

Jul 9th, 2015
290
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 3.13 KB | None | 0 0
  1. term.clear()
  2. term.setCursorPos(1,1)
  3.  
  4. print("Korean Missile Launch Terminal")
  5. print(" 1 - Launch First Missile")
  6. print(" 2 - Launch Second Missile")
  7. print(" 3 - Launch Third Missile")
  8. print(" 4 - Launch All Missiles")
  9. print(" 5 - Lock Terminal")
  10. print(" 6 - Terminal Shutdown")
  11. while true do
  12. event, param1 = os.pullEvent()
  13. if event == "char" and param1 == "1" then
  14. term.clear()
  15. term.setCursorPos(1,1)
  16. print("Launch Commencing In T-Minus...")
  17. print("30 Seconds")
  18. sleep(10)
  19. term.clear()
  20. term.setCursorPos(1,1)
  21. print("Launch Commencing In T-Minus...")
  22. print("20 Seconds")
  23. sleep(10)
  24. term.clear()
  25. term.setCursorPos(1,1)
  26. print("Launch Commencing In T-Minus...")
  27. print("10 Seconds")
  28. sleep(10)
  29. term.clear()
  30. term.setCursorPos(1,1)
  31. print("Commencing Launch")
  32. redstone.setOutput("left", true)
  33. sleep(2)
  34. redstone.setOutput("left", false)
  35. term.clear()
  36. term.setCursorPos(1,1)
  37. shell.run("MissileLaunch.lua")
  38.         end
  39.  
  40. if event == "char" and param1 == "2" then
  41. term.clear()
  42. term.setCursorPos(1,1)
  43. print("Launch Commencing In T-Minus...")
  44. print("30 Seconds")
  45. sleep(10)
  46. term.clear()
  47. term.setCursorPos(1,1)
  48. print("Launch Commencing In T-Minus...")
  49. print("20 Seconds")
  50. sleep(10)
  51. term.clear()
  52. term.setCursorPos(1,1)
  53. print("Launch Commencing In T-Minus...")
  54. print("10 Seconds")
  55. sleep(10)
  56. term.clear()
  57. term.setCursorPos(1,1)
  58. print("Commencing Launch")
  59. redstone.setOutput("back", true)
  60. sleep(2)
  61. redstone.setOutput("back", false)
  62. term.clear()
  63. term.setCursorPos(1,1)
  64. shell.run("MissileLaunch.lua")
  65.         end
  66. if event == "char" and param1 == "3" then
  67. term.clear()
  68. term.setCursorPos(1,1)
  69. print("Launch Commencing In T-Minus...")
  70. print("30 Seconds")
  71. sleep(10)
  72. term.clear()
  73. term.setCursorPos(1,1)
  74. print("Launch Commencing In T-Minus...")
  75. print("20 Seconds")
  76. sleep(10)
  77. term.clear()
  78. term.setCursorPos(1,1)
  79. print("Launch Commencing In T-Minus...")
  80. print("10 Seconds")
  81. sleep(10)
  82. term.clear()
  83. term.setCursorPos(1,1)
  84. print("Commencing Launch")
  85. redstone.setOutput("right", true)
  86. sleep(2)
  87. redstone.setOutput("right", false)
  88. term.clear()
  89. term.setCursorPos(1,1)
  90. shell.run("MissileLaunch.lua")
  91.         end
  92. if event == "char" and param1 == "4" then
  93. term.clear()
  94. term.setCursorPos(1,1)
  95. print("Launch Commencing In T-Minus...")
  96. print("30 Seconds")
  97. sleep(10)
  98. term.clear()
  99. term.setCursorPos(1,1)
  100. print("Launch Commencing In T-Minus...")
  101. print("20 Seconds")
  102. sleep(10)
  103. term.clear()
  104. term.setCursorPos(1,1)
  105. print("Launch Commencing In T-Minus...")
  106. print("10 Seconds")
  107. sleep(10)
  108. term.clear()
  109. term.setCursorPos(1,1)
  110. print("Commencing Launch")
  111. redstone.setOutput("back", true)
  112. redstone.setOutput("left", true)
  113. redstone.setOutput("right", true)
  114. sleep(2)
  115. redstone.setOutput("back", false)
  116. redstone.setOutput("left", false)
  117. redstone.setOutput("right", false)
  118. term.clear()
  119. term.setCursorPos(1,1)
  120. shell.run("MissileLaunch.lua")
  121.         end
  122.         if event == "char" and param1 = "5" then
  123. term.clear()
  124. term.setCursorPos(1,1)
  125. print("Locking Terminal...")
  126. sleep(2)
  127. shell.run(startup)
  128. end
  129.  
  130. if event == "char" and param1 = "6" then
  131. term.clear()
  132. term.setCursorPos(1,1)
  133. print("Shutting Down...")
  134. sleep(2)
  135. shell.run(shutdown)
  136. end
  137. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement