Advertisement
Muzze77

Heater

Dec 7th, 2013
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.81 KB | None | 0 0
  1. ---------------------------------------------------------
  2. ---------------(c)Muzze77 Interface----------------------
  3. ---------------------------------------------------------
  4.  
  5. --functions--
  6. local function next()
  7. sleep(2)
  8. shell.run("clear")
  9. end
  10. -------------
  11. --xxxxx--
  12. --Variables--
  13. local bl = colors.blue
  14. local re = colors.red
  15. local we = colors.white
  16. local bk = colors.black
  17. local gr = colors.green
  18. local gl = colors.gelb
  19. local br = colors.brown
  20. local null = 0
  21. local count = 0
  22. --check--
  23. if rs.getInput("right") == true then
  24.  
  25. print(" PC Bootet | Bitte Warten")
  26. next()
  27. rs.setBundledCable("left", bk)
  28. print("Laden | 0%|")
  29. next()
  30. print("Laden | 10%|")
  31. next()
  32. print("Laden | 20%|")
  33. next()
  34. print("Laden | 30%|")
  35. next()
  36. print("Laden | 40%|")
  37. next()
  38. print("Laden | 50%|")
  39. next()
  40. print("Laden | 60%|")
  41. next()
  42. print("Laden | 70%|")
  43. next()
  44. print("Laden | 80%|")
  45. next()
  46. print("Laden | 90%|")
  47. next()
  48. print("Laden |100%|")
  49. next()
  50. print("Laden Erfolgreich. Bitte Aktion Wählen")
  51. next()
  52. sleep(2)
  53. print("Welches Material Liefern ?")
  54. print("1 = Iron")
  55. print("2 = Tin")
  56. print("3 = Copper")
  57. print("4 = Silver")
  58. print("5 = Gold")
  59. print("Bitte Eintippen: ")
  60. local an = io.read()
  61. if an == "1" then
  62. rs.setBundledOutput("back", bl)
  63. sleep(4)
  64. rs.setBundledOutput("back", null)
  65. -----------------------------------
  66. while rs.getInput("top") == true do
  67. count = count+1
  68. print(count)
  69.  
  70. end
  71.  
  72.  
  73. elseif an == "2" then
  74. rs.setBundledOutput("back", re)
  75. sleep(4)
  76. rs.setBundledOutput("back", null)
  77. -----------------------------------
  78. while rs.getInput("top") == true do
  79. count = count+1
  80. print(count)
  81. end
  82. elseif an == "3" then
  83. rs.setBundledOutput("back", gr)
  84. sleep(4)
  85. rs.setBundledOutput("back", null)
  86. -----------------------------------
  87. while rs.getInput("top") == true do
  88. count = count+1
  89. print(count)
  90. end
  91. elseif an == "4" then
  92. rs.setBundledOutput("back", gl)
  93. sleep(4)
  94. rs.setBundledOutput("back", null)
  95. -----------------------------------
  96. while rs.getInput("top") == true do
  97. count = count+1
  98. print(count)
  99. end
  100. elseif an == "5" then
  101. rs.setBundledOutput("back", br)
  102. sleep(4)
  103. rs.setBundledOutput("back", null)
  104. -----------------------------------
  105. while rs.getInput("top") == true do
  106. count = count+1
  107. print(count)
  108. end
  109. else
  110. rs.setBundledOutput("back", null)
  111. sleep(2)
  112. print("Falsche eingabe. Neustart!")
  113. shell.run("reboot")
  114. ----------------------------------
  115. end
  116.  
  117. else
  118. print("Kein Strom")
  119. sleep(4)
  120. shell.run("reboot")
  121. --xxxxx--
  122. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement