View difference between Paste ID: LYj6fUej and Xmg9sfac
SHOW: | | - or go back to the newest paste.
1
m = peripheral.wrap("back")
2
m.clear()
3
m.setCursorPos(1,1)
4-
m.setTextScale(1)
4+
m.setTextScale(5)
5
6
local function centerText(text)
7
  x,y = m.getSize()
8
  x1,y1 = m.getCursorPos()
9
  m.setCursorPos((math.floor(x/2) - (math.floor(#text/2))), y1)
10
  m.write(text)  
11
end
12
13
--Call function "centerText("")" to set text
14
--Use m.setCursorPos(1,y) to choose placement on screen
15
16
y2 = 1
17-
m.setCursorPos(1, y2 + 1)
17+
18-
centerText("FINALCRAFT ONLINE")
18+
centerText("Admin Shop")