Advertisement
bennyuoppd

Minecraft CC Music player turtle

Nov 23rd, 2012
450
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.40 KB | None | 0 0
  1. turtle.suck()
  2. term.clear()
  3. term.setCursorPos(1,1)
  4. rednet.open("right")
  5. idcon = 87
  6. print("Music disk player booted!")
  7. turtle.select(1)
  8. while true do
  9. id , msg = rednet.receive()
  10. if id == idcon then
  11. song = tonumber(msg)
  12. if song > 0 and song < 15 then
  13. turtle.suck()
  14. turtle.select(song)
  15. turtle.drop(1)
  16. disk.playAudio("front")
  17. elseif song == 15 then
  18. disk.stopAudio()
  19. turtle.suck()
  20. end
  21. end
  22. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement