Advertisement
guitarplayer616

Untitled

Apr 28th, 2015
312
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.71 KB | None | 0 0
  1. os.loadAPI("GIF")
  2.  
  3. local mon = peripheral.find("monitor")
  4.  
  5. local gifs = {"image1.gif", "image2.gif", "anotherImage.gif", "youGetTheIdea.gif"}
  6.  
  7. mon.setTextScale(0.5)
  8. local x, y = mon.getSize()
  9.  
  10. while true do for i = 1, #gifs do
  11. local image = GIF.loadGIF(gifs[i])
  12. mon.setBackgroundColour(image[1].transparentCol or image.backgroundCol)
  13. mon.clear()
  14.  
  15. parallel.waitForAny(
  16. function()
  17. GIF.animateGIF(image, math.floor((x - image.width) / 2) + 1, math.floor((y - image.height) / 2) + 1, mon)
  18. end,
  19.  
  20. function()
  21. sleep(10)
  22. end
  23. )
  24. end end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement