MeXaN1cK

Text on OC glasses

Apr 27th, 2016
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.77 KB | None | 0 0
  1. local cmp= require("component")
  2. g=cmp.glasses
  3. p=g.addTextLabel().getPosition()
  4. g.removeAll()
  5. io.write("Введите X: ")
  6. x=io.read() xs=tonumber(x)
  7. io.write("Введите Y: ")
  8. y=io.read() ys=tonumber(y)
  9. io.write("Введите Z: ")
  10. z=io.read() zs=tonumber(z)
  11. io.write("Введите Размер: ")
  12. s=io.read() s=tonumber(s)
  13.  
  14. io.write("Введите R: ")
  15. r=io.read() r=tonumber(r)
  16.  
  17. io.write("Введите G: ")
  18. g1=io.read() g1=tonumber(g1)
  19.  
  20. io.write("Введите B: ")
  21. b=io.read() b=tonumber(b)
  22.  
  23. io.write("Введите текст: ")
  24. text=io.read() t=tostring(text)
  25. for x=xs-p, xs+p do
  26.  for y=ys-p, xs+p do
  27.   for z=zs-p, zs+p do
  28.  tx=g.addFloatingText()
  29.  tx.set3DPos(x,y,z)
  30.  tx.setColor(r,g1,b)
  31.  tx.setScale(s)
  32.  tx.setText(t)
  33. end
  34. end
  35. end
Add Comment
Please, Sign In to add comment