function centerText(text, y, color) mX = mon.getSize() x = math.floor(mX/2) - math.floor(string.len(text)/2) mon.setCursorPos(x, y) mon.setTextColor(color) mon.write(text) end function Text(text, y, color) mX = mon.getSize() x = 3 mon.setCursorPos(x,y) mon.setTextColor(color) mon.write(text) end mon = peripheral.wrap("back") mon.setTextScale(1) mon.setBackgroundColor(colors.gray) mon.clear() centerText("Bienvenue à la boulangerie du serveur", 1,16384) centerText("Pour acheter un produit,", 2,2) centerText("clique gauche sur un coffre", 3,2) centerText("_________________________________________________________", 4,2) centerText("Item | Prix", 5,2) Text(" Bread | 3 euros", 6,2) Text(" Log | 1 euro", 7,2) Text(" Carrot | 2 euros", 8,2) Text(" Baked Potato | 5 euros", 9,2)