Advertisement
Tomyf4

Simple_GantryController

Feb 13th, 2024
10
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1.  
  2. local status = "waiting"
  3. local InputDir = "left"
  4. local InterfaceDir = "top"
  5. local GantryDir = "bottom"
  6.  
  7. function MoveGantry()
  8. redstone.setAnalogueOutput(GantryDir, 15)
  9. redstone.setAnalogueOutput(InterfaceDir, 15)
  10. os.sleep(60)
  11. redstone.setAnalogueOutput(GantryDir, 0)
  12. redstone.setAnalogueOutput(InterfaceDir, 0)
  13. end
  14.  
  15. while true do
  16. if redstone.getAnalogueInput(InputDir) > 0 then
  17. MoveGantry()
  18. end
  19. os.sleep(0.5)
  20. end
  21.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement