Advertisement
Guest User

Untitled

a guest
Jul 5th, 2015
160
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.26 KB | None | 0 0
  1. m = peripheral.wrap("bottom")
  2. m.clear()
  3. m.setCursorPos(1,1)
  4.  
  5. local function centerText(text)
  6. x,y = m.getSize()
  7. x1,y1 = m.getCursorPos()
  8. m.setCursorPos((math.floor(x/2) - (math.floor(#text/2))), y1)
  9. m.write(text)
  10. end
  11.  
  12. m.setCursorPos(1,1)
  13. m.setTextColor(colors.red)
  14. centerText("REGULAMIN")
  15. m.setCursorPos(1,2)
  16. m.setTextColor(colors.white)
  17. centerText("1.Szanuj administracje i innych graczy. Kazdy jest traktowany z takim samym szacunkiem.")
  18. m.setCursorPos(1,3)
  19. m.setTextColor(colors.white)
  20. centerText("2.Zawsze sluchaj admintracji. W sprawach serwerowych wszelkie informacje zna tylko ona.")
  21. m.setCursorPos(1,4)
  22. m.setTextColor(colors.white)
  23. centerText("3.Nigdy nie zebraj, nie pros o range, nie probuj oszukiwac.")
  24. m.setCursorPos(1,5)
  25. m.setTextColor(colors.white)
  26. centerText("4.Nigdy nie podawaj nikomu swoich danych. Administracja nigdy cie o to nie zapyta.")
  27. m.setCursorPos(1,6)
  28. m.setTextColor(colors.white)
  29. centerText("5.Zgraj zgodnie z zasadami Fair Play.")
  30. m.setCursorPos(1,7)
  31. m.setTextColor(colors.white)
  32. centerText("6.Jezeli cos sie dzieje natychmiastowo zglos to admintracji.")
  33. m.setCursorPos(1,8)
  34. m.setTextColor(colors.white)
  35. centerText("7.Stosuj sie regulaminu.")
  36. m.setCursorPos(1,9)
  37. m.setTextColor(colors.red)
  38. centerText("MILEJ GRY")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement