Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local sText = "plug walk!" -- You can change the text
- local sSide = "top" -- you can change the side of the monitor
- local function printCenter(mon, txt)
- local w, h = mon.getSize()
- local x = math.floor((w / 2) - (#txt / 2))
- local y = math.floor((h / 2))
- mon.setCursorPos(x, y)
- mon.write("plug walk!")
- sleep(.2)
- mon.setTextColor(red)
- sleep(.2)
- mon.setTextColor(magenta)
- sleep(.2)
- mon.setTextColor(red)
- sleep(.2)
- mon.setTextColor(magenta)
- sleep(.2)
- mon.setTextColor(red)
- sleep(.2)
- mon.setTextColor(magenta)
- sleep(.2)
- mon.setTextColor(red)
- sleep(.2)
- mon.setTextColor(magenta)
- sleep(.2)
- end
- local monitor = peripheral.wrap(sSide)
- printCenter(monitor, sText)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement