Tommo5261

fuelSelection

Oct 24th, 2020
1,092
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. while true do
  2.   function close()
  3.     redstone.setOutput("right",false)
  4.     redstone.setOutput("top",false)
  5.     redstone.setOutput("back",false)
  6.   end
  7.   term.clear()
  8.   term.setCursorPos(1,1)
  9.   print("== Fuel Delivery System ==")
  10.   print("Type a specified number to select fuel type")
  11.   print("(1) - Gaseous Fuel")
  12.   print("(2) - Dense Fuel")
  13.   print("(3) - Light Fuel")
  14.   print("(off) - Close all valves")
  15.   print("")
  16.   option = read()
  17.   if option == "1" then
  18.     close()
  19.     redstone.setOutput("right",true)
  20.     texutils.slowPrint("Selected (1), Gaseous Fuel")
  21.     sleep(2)
  22.   elseif option == "2" then
  23.     close()
  24.     redstone.setOutput("top",true)
  25.     texutils.slowPrint("Selected (2), Dense Fuel")
  26.     sleep(2)
  27.   elseif option == "3" then
  28.     close()
  29.     redstone.setOutput("back",true)
  30.     texutils.slowPrint("Selected (3), Light Fuel")
  31.     sleep(2)
  32.   elseif option == "off" then
  33.     close()
  34.     texutils.slowPrint("Selected (off), closed all valves")
  35.     sleep(2)
  36.   else
  37.   end
  38. end
RAW Paste Data