Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local m = peripheral.wrap("bottom")
- m.setTextScale(0.5)
- m.clear()
- lines = {}
- local function writeCentered(text, y)
- local width, _ = m.getSize()
- m.setCursorPos(math.floor((width-#text)/2)+1, y)
- m.write(text)
- end
- local function writeLines(lines)
- for i=1, #lines do
- writeCentered(lines[i], i)
- end
- end
- writeLines(lines)
Add Comment
Please, Sign In to add comment