Advertisement
Guest User

startup

a guest
Dec 22nd, 2014
149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.42 KB | None | 0 0
  1. term.clear()
  2. term.setCursorPos(1, 1)
  3.  
  4. while true do
  5.   term.clear()
  6.   term.setCursorPos(1, 1)
  7.  
  8.   print("Enter a floor number. Underground levels are negative.")
  9.  
  10.   input = read()
  11.  
  12.   if input == "-2" then
  13.     rs.setAnalogOutput("back", 1)
  14.     rs.setAnalogOutput("back", 2)
  15.   elseif input == "-1" then
  16.    
  17.   elseif input == "0" then
  18.    
  19.   else
  20.     print("Invalid input.")
  21.     sleep(2)
  22.   end
  23.  
  24. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement