Guest User

certusDisplayOG

a guest
Nov 24th, 2025
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.30 KB | None | 0 0
  1. local barrel = peripheral.find("me_bridge")
  2. local monitor = peripheral.find("monitor")
  3.  
  4. local w, h = monitor.getSize()
  5. monitor.setTextScale(0.5)
  6.  
  7. local old_term = term.current()
  8. local imageName = "certus_quartz_crystal_small.nfp"
  9.  
  10. local items
  11.  
  12. local image1 = paintutils.loadImage(imageName)
  13. local image2 = paintutils.loadImage(imageName)
  14. local image3 = paintutils.loadImage(imageName)
  15. local image4 = paintutils.loadImage(imageName)
  16.  
  17. local images = {image1, image2, image3, image4}
  18. local fallens = {0, 8, -8, -16}
  19. local imagex = {10, 26, 42, 58}
  20.  
  21. function drawImage(image, fallen, x)
  22.     monitor.setTextScale(1.0)
  23.     term.redirect(monitor)
  24.     paintutils.drawImage(image, x, fallen)
  25.     term.redirect(old_term)
  26.     fallen = fallen + 1
  27.     if fallen > h then
  28.         fallen = -16
  29.     end
  30.     term.redirect(old_term)
  31.     return fallen
  32. end
  33.  
  34.  
  35. while true do
  36.     for i = 1, 4, 1 do
  37.         fallens[i] = drawImage(images[i], fallens[i], imagex[i])
  38.     end
  39.     monitor.setCursorPos((w/2)-10,(h/2)-2)
  40.     print("Total Certus Quartz\n")
  41.     monitor.write("Total Certus Quartz")
  42.     monitor.setCursorPos((w/2)-10,(h/2))
  43.     items = barrel.getItem({name = "ae2:certus_quartz_crystal", count = 1})
  44.     print(items.amount)
  45.     monitor.write("%d", items.amount)
  46.     sleep(0.5)
  47.     monitor.clear()
  48. end
  49.  
Advertisement
Add Comment
Please, Sign In to add comment