Advertisement
MagmaLP

Door

May 7th, 2022 (edited)
948
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.43 KB | None | 0 0
  1. function zu()
  2.     for i = 1,5 do
  3.         rs.setOutput("bottom", true)
  4.         sleep(0.5)
  5.         rs.setOutput("bottom", false)
  6.         sleep(0.5)
  7.     end
  8. end
  9.  
  10. function auf()
  11.     for i = 1,5 do
  12.         rs.setOutput("left", true)
  13.         sleep(0.5)
  14.         rs.setOutput("left", false)
  15.         sleep(0.5)
  16.     end
  17. end
  18.  
  19. while true do
  20.     if rs.getInput("right", true) and rs.getInput("top", true) then
  21.         auf()
  22.         sleep(1.5)
  23.         zu()
  24.     end
  25. sleep(1)
  26. end
  27.  
  28.        
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement