emagiannu

MobEssenceTank

Jun 11th, 2014
286
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.47 KB | None | 0 0
  1. local valve = peripheral.wrap("right")
  2. local outSide = "back"
  3.  
  4. while true do
  5. local tank = valve.getTankInfo("right")
  6.  
  7. for k, v in pairs(tank) do
  8. for x, y in pairs(v) do
  9. if x == "amount"then
  10. print(x..": "..y)
  11. if y > 2800000 then
  12. redstone.setOutput(outSide, false)
  13. redstone.setBundledOutput(outSide, 0)
  14. else
  15. redstone.setOutput(outSide, true)
  16. redstone.setBundledOutput(outSide, 1)
  17. end
  18. end
  19. end
  20. end
  21. sleep(5)
  22. end
Advertisement
Add Comment
Please, Sign In to add comment