Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- m = peripheral.wrap("top")
- m.clear()
- m.setCursorPos(1,1)
- local function centerText(text)
- x,y = m.getSize()
- x1,y1 = m.getCursorPos()
- m.setCursorPos((math.floor(x/2) - (math.floor(#text/2))), y1)
- m.write(text)
- end
- --Call function "centerText("")" to set text
- --Use m.setCursorPos(1,y) to choose placement on screen
- m.setCursorPos(21,1)
- m.setTextColor(colors.red)
- m.write(" Rules!")
- y2 = 3
- m.setCursorPos(1, y2 + 1)
- m.setTextColor(colors.lightBlue)
- centerText("1.)No Surface Mining.")
- m.setCursorPos(1, y2 + 3)
- m.setTextColor(colors.lime)
- centerText("2.)Be Respectful To All Staff Members.")
- m.setCursorPos(1, y2 + 5)
- m.setTextColor(colors.yellow)
- centerText("3.)Please Don't Be Rude To Other's.")
- m.setCursorPos(1, y2 + 7)
- m.setTextColor(colors.green)
- centerText("4.)No Sexual Harassment.")
- m.setCursorPos(1, y2 + 9)
- m.setTextColor(colors.purple)
- centerText("5.)Use Your Common Sense")
- m.setCursorPos(1, y2 + 11)
- m.setTextColor(colors.white)
- centerText("5.)Be Ethical.")
- m.setCursorPos(1, y2 + 13)
- m.setTextColor(colors.blue)
- centerText("6.)No Advertising")
- m.setCursorPos(1, y2 + 15)
- m.setTextColor(colors.orange)
- centerText("Failure To Follow These Rules Will,")
- m.setCursorPos(1, y2 + 17)
- centerText("Result In Your Ban")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement