Advertisement
NewkoWasHere

computercraft image displayer

Feb 7th, 2023
117
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.36 KB | None | 0 0
  1. local targ={...}
  2. os.loadAPI("wrap")
  3. mon = wrap.attach("monitor")
  4. mon.setTextScale(0.5)
  5. mon.clear()
  6. mon.setCursorPos(1,1)
  7. if #targ==0 then
  8. print("Type the filename of the image you would like to load:")
  9. local filename = io.read()
  10. else
  11. filename = targ[1]
  12. end
  13. image = paintutils.loadImage(filename)
  14. term.redirect(mon)
  15. paintutils.drawImage(image,1,1)
  16.  
  17.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement