Astronomic_pancake

Mad funky bedrock thing

Jan 20th, 2021 (edited)
505
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.89 KB | None | 0 0
  1. local side = "back"
  2. local time = 20
  3. local working = false
  4.  
  5. while true do
  6.    
  7. local leverinput = redstone.getInput("front")
  8.    
  9. if leverinput == true then
  10.     working = true
  11. else
  12.     working = false
  13. end
  14.  
  15.     while working == true do
  16.         local leverinput = redstone.getInput("front")
  17.             if leverinput == false then
  18.                 working = false
  19.             end
  20.        
  21.         term.clear()
  22.         term.setCursorPos(1,1)
  23.         print("on")
  24.         redstone.setOutput(side, true)
  25.         sleep(2)
  26.         redstone.setOutput(side, false)
  27.         sleep(time)
  28.         redstone.setOutput(side, true)
  29.         sleep(2)
  30.         redstone.setOutput(side, false)
  31.         sleep(time)
  32.        
  33.     end
  34.    
  35.     while working == false do
  36.        
  37.     local leverinput = redstone.getInput("front")
  38.         if leverinput == true then
  39.             working = true
  40.         end
  41.  
  42.     term.clear()
  43.     term.setCursorPos(1,1)
  44.     print("wating!")
  45.     sleep(1)
  46.     term.clear()
  47.     term.setCursorPos(1,1)
  48.     print("wating")
  49.     sleep(1)
  50.     end
  51.  
  52. end
Add Comment
Please, Sign In to add comment