class_segmentshape2d.rst 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the SegmentShape2D.xml source instead.
  3. .. The source is found in doc/classes or modules/<name>/doc_classes.
  4. .. _class_SegmentShape2D:
  5. SegmentShape2D
  6. ==============
  7. **Inherits:** :ref:`Shape2D<class_shape2d>` **<** :ref:`Resource<class_resource>` **<** :ref:`Reference<class_reference>` **<** :ref:`Object<class_object>`
  8. **Category:** Core
  9. Brief Description
  10. -----------------
  11. Segment shape for 2D collisions.
  12. Member Functions
  13. ----------------
  14. +--------------------------------+----------------------------------------------------------------------------------------+
  15. | :ref:`Vector2<class_vector2>` | :ref:`get_a<class_SegmentShape2D_get_a>` **(** **)** const |
  16. +--------------------------------+----------------------------------------------------------------------------------------+
  17. | :ref:`Vector2<class_vector2>` | :ref:`get_b<class_SegmentShape2D_get_b>` **(** **)** const |
  18. +--------------------------------+----------------------------------------------------------------------------------------+
  19. | void | :ref:`set_a<class_SegmentShape2D_set_a>` **(** :ref:`Vector2<class_vector2>` a **)** |
  20. +--------------------------------+----------------------------------------------------------------------------------------+
  21. | void | :ref:`set_b<class_SegmentShape2D_set_b>` **(** :ref:`Vector2<class_vector2>` b **)** |
  22. +--------------------------------+----------------------------------------------------------------------------------------+
  23. Member Variables
  24. ----------------
  25. - :ref:`Vector2<class_vector2>` **a** - The segment's first point position.
  26. - :ref:`Vector2<class_vector2>` **b** - The segment's second point position.
  27. Description
  28. -----------
  29. Segment shape for 2D collisions. Consists of two points, ``a`` and ``b``.
  30. Member Function Description
  31. ---------------------------
  32. .. _class_SegmentShape2D_get_a:
  33. - :ref:`Vector2<class_vector2>` **get_a** **(** **)** const
  34. Return the first point's position.
  35. .. _class_SegmentShape2D_get_b:
  36. - :ref:`Vector2<class_vector2>` **get_b** **(** **)** const
  37. Return the second point's position.
  38. .. _class_SegmentShape2D_set_a:
  39. - void **set_a** **(** :ref:`Vector2<class_vector2>` a **)**
  40. Set the first point's position.
  41. .. _class_SegmentShape2D_set_b:
  42. - void **set_b** **(** :ref:`Vector2<class_vector2>` b **)**
  43. Set the second point's position.