Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --[[
- This program is designed for use with Computercraft
- This is a legacy version of the billboard program designed for use in Minecraft 1.6.4
- Custom version for: The Condemned Network - Tekkit Main (1.6.4) player mall
- Billboard Specs: 8 blocks wide by 5 blocks tall advanced monitor
- Programmed by Rolcam
- You can copy/modify this program as you wish, just please leave the documentation intact
- ]]--
- --Change this to the side the monitor is on
- side = "right"
- -- Time variable for how long (in seconds) to display each advert
- t = 5
- --Redirects setup/install output to monitor (for artistic effect)
- local monitor = peripheral.wrap(side)
- if not fs.exists("boot") then
- term.setTextColor(colors.red)
- print("Warning: boot image missing!")
- print("Downloading image...")
- term.setTextColor(colors.white)
- shell.run("pastebin get edscQ8zU boot")
- term.setTextColor(colors.green)
- print("Main boot image downloaded.")
- term.setTextColor(colors.white)
- else
- term.setTextColor(colors.green)
- print("boot image found!")
- term.setTextColor(colors.white)
- end
- local img = paintutils.loadImage("boot")
- term.redirect(monitor)
- paintutils.drawImage(img, 1,1)
- term.restore()
- term.setBackgroundColor(colors.blue)
- term.setTextColor(colors.orange)
- term.clear()
- print("Rolcam's Billboard Program V3")
- term.setTextColor(colors.white)
- print(" ")
- print("Beginning system check...")
- --Checks for missing signs and labels itself
- print("Checking signs...")
- if not fs.exists("image") then
- term.setTextColor(colors.red)
- print("Warning: advert image missing!")
- term.setTextColor(colors.white)
- print("Downloading image...")
- shell.run("pastebin get EZDcTC35 image")
- term.setTextColor(colors.green)
- print("File downloaded")
- term.setTextColor(colors.white)
- else
- term.setTextColor(colors.green)
- print("beach image found!")
- term.setTextColor(colors.white)
- end
- if not fs.exists("timnoot") then
- term.setTextColor(colors.red)
- print("Warning: timnoot's advert missing!")
- term.setTextColor(colors.white)
- print("Downloading image...")
- shell.run("pastebin get f0u7ttWn timnoot")
- term.setTextColor(colors.green)
- print("File downloaded")
- term.setTextColor(colors.white)
- else
- term.setTextColor(colors.green)
- print("timnoot's advert found!")
- term.setTextColor(colors.white)
- end
- if not fs.exists("XpqUUpqX") then
- term.setTextColor(colors.red)
- print("Warning: XpqUUpqX's advert missing!")
- term.setTextColor(colors.white)
- print("Downloading image...")
- shell.run("pastebin get fk2QQhw4 XpqUUpqX")
- term.setTextColor(colors.green)
- print("File downloaded")
- term.setTextColor(colors.white)
- else
- term.setTextColor(colors.green)
- print("XpqUUpqX's advert found!")
- term.setTextColor(colors.white)
- end
- if not fs.exists("mall") then
- term.setTextColor(colors.red)
- print("Warning: Mall sign is missing!")
- term.setTextColor(colors.white)
- print("Downloading image...")
- shell.run("pastebin get k1dsWddA mall")
- term.setTextColor(colors.green)
- print("File downloaded")
- term.setTextColor(colors.white)
- else
- term.setTextColor(colors.green)
- print("Mall sign image found!")
- term.setTextColor(colors.white)
- end
- mallImg = paintutils.loadImage("mall")
- print("Sign check completed!")
- print("Checking for computer label")
- if os.getComputerLabel() == nil then
- term.setTextColor(colors.red)
- print("Warning: Computer is not labeled!")
- term.setTextColor(colors.white)
- print("Labelling Computer")
- os.setComputerLabel("Mall - Billboard")
- else
- term.setTextColor(colors.green)
- print("Computer is already labelled. Great!")
- term.setTextColor(colors.white)
- end
- print("System Check Completed!")
- print("Starting Billboard!")
- term.redirect(monitor)
- adSign = paintutils.loadImage("image")
- tnAd = paintutils.loadImage("timnoot")
- XpqAd = paintutils.loadImage("XpqUUpqX")
- while true do
- paintutils.drawImage(mallImg, 1, 1)
- sleep(10)
- paintutils.drawImage(adSign, 1, 1)
- sleep(t)
- paintutils.drawImage(mallImg, 1, 1)
- sleep(10)
- paintutils.drawImage(tnAd, 1, 1)
- sleep(t)
- paintutils.drawImage(mallImg, 1, 1)
- sleep(10)
- paintutils.drawImage(XpqAd, 1, 1)
- sleep(t)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement