class_joint2d.rst 4.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the doc/base/classes.xml source instead.
  3. .. _class_Joint2D:
  4. Joint2D
  5. =======
  6. **Inherits:** :ref:`Node2D<class_node2d>` **<** :ref:`CanvasItem<class_canvasitem>` **<** :ref:`Node<class_node>` **<** :ref:`Object<class_object>`
  7. **Inherited By:** :ref:`PinJoint2D<class_pinjoint2d>`, :ref:`DampedSpringJoint2D<class_dampedspringjoint2d>`, :ref:`GrooveJoint2D<class_groovejoint2d>`
  8. **Category:** Core
  9. Brief Description
  10. -----------------
  11. Base node for all joint constraints in 2D physics.
  12. Member Functions
  13. ----------------
  14. +----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
  15. | :ref:`float<class_float>` | :ref:`get_bias<class_Joint2D_get_bias>` **(** **)** const |
  16. +----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
  17. | :ref:`bool<class_bool>` | :ref:`get_exclude_nodes_from_collision<class_Joint2D_get_exclude_nodes_from_collision>` **(** **)** const |
  18. +----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
  19. | :ref:`NodePath<class_nodepath>` | :ref:`get_node_a<class_Joint2D_get_node_a>` **(** **)** const |
  20. +----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
  21. | :ref:`NodePath<class_nodepath>` | :ref:`get_node_b<class_Joint2D_get_node_b>` **(** **)** const |
  22. +----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
  23. | void | :ref:`set_bias<class_Joint2D_set_bias>` **(** :ref:`float<class_float>` bias **)** |
  24. +----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
  25. | void | :ref:`set_exclude_nodes_from_collision<class_Joint2D_set_exclude_nodes_from_collision>` **(** :ref:`bool<class_bool>` enable **)** |
  26. +----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
  27. | void | :ref:`set_node_a<class_Joint2D_set_node_a>` **(** :ref:`NodePath<class_nodepath>` node **)** |
  28. +----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
  29. | void | :ref:`set_node_b<class_Joint2D_set_node_b>` **(** :ref:`NodePath<class_nodepath>` node **)** |
  30. +----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------+
  31. Description
  32. -----------
  33. Base node for all joint constraints in 2D physics. Joints take 2 bodies and apply a custom constraint.
  34. Member Function Description
  35. ---------------------------
  36. .. _class_Joint2D_get_bias:
  37. - :ref:`float<class_float>` **get_bias** **(** **)** const
  38. .. _class_Joint2D_get_exclude_nodes_from_collision:
  39. - :ref:`bool<class_bool>` **get_exclude_nodes_from_collision** **(** **)** const
  40. .. _class_Joint2D_get_node_a:
  41. - :ref:`NodePath<class_nodepath>` **get_node_a** **(** **)** const
  42. Return the path to the A node for the joint.
  43. .. _class_Joint2D_get_node_b:
  44. - :ref:`NodePath<class_nodepath>` **get_node_b** **(** **)** const
  45. Return the path to the B node for the joint.
  46. .. _class_Joint2D_set_bias:
  47. - void **set_bias** **(** :ref:`float<class_float>` bias **)**
  48. .. _class_Joint2D_set_exclude_nodes_from_collision:
  49. - void **set_exclude_nodes_from_collision** **(** :ref:`bool<class_bool>` enable **)**
  50. .. _class_Joint2D_set_node_a:
  51. - void **set_node_a** **(** :ref:`NodePath<class_nodepath>` node **)**
  52. Set the path to the A node for the joint. Must be of type :ref:`PhysicsBody2D<class_physicsbody2d>`.
  53. .. _class_Joint2D_set_node_b:
  54. - void **set_node_b** **(** :ref:`NodePath<class_nodepath>` node **)**
  55. Set the path to the B node for the joint. Must be of type :ref:`PhysicsBody2D<class_physicsbody2d>`.