__RIK__

Untitled

Sep 3rd, 2013
147
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.21 KB | None | 0 0
  1. p = peripheral.wrap("right") -- glasses bridge
  2.  
  3. p.getStringWidth("Hello") -- returns the width of the text
  4.  
  5. ids = p.getAllIds() -- get a table of ids
  6. drawable = p.getById(drawableId) -- get an item by its ID
  7. p.clear() -- clear the screen
  8. p.getGuid() -- get the bridge guid
  9. p.resetGuid() -- reset the bridge guid
  10. p.getAllUsers() -- get a table of connected users
  11.  
  12. gradientBox = p.addGradientBox(x, y, width, height, color, opacity, color2, opacity2, gradientDirection) -- gradient direction should be 1 or 2
  13. box = p.addBox(x, y, width, height, color, opacity)
  14. box.setX(x)
  15. box.getX()
  16. box.setWidth(width)
  17. box.getWidth()
  18. box.setY(y)
  19. box.getY()
  20. box.setHeight(height)
  21. box.getHeight()
  22. box.getGradient()
  23. box.setGradient(mode)
  24. box.delete()
  25. box.setColor(color)
  26. box.getColor()
  27. box.setOpacity(opacity)
  28. box.getOpacity()
  29. box.setOpacity2(opacity2)
  30. box.getOpacity2()
  31. box.getZIndex()
  32. box.setZIndex(zindex)
  33. box.setColor2(color2)
  34. box.getColor2()
  35.  
  36.  
  37. text = p.addText(x, y, text, color)
  38. text.setX(x)
  39. text.getX()
  40. text.setY(y)
  41. text.getY()
  42. text.delete()
  43. text.setColor(color)
  44. text.getColor()
  45. text.getZIndex()
  46. text.setZIndex(zindex)
  47. text.setText(txt)
  48. text.getText()
  49. text.setScale(scale)
  50. text.getScale()
  51. text.getWidth()
Add Comment
Please, Sign In to add comment