class_hingejoint.rst 3.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the HingeJoint.xml source instead.
  3. .. The source is found in doc/classes or modules/<name>/doc_classes.
  4. .. _class_HingeJoint:
  5. HingeJoint
  6. ==========
  7. **Inherits:** :ref:`Joint<class_joint>` **<** :ref:`Spatial<class_spatial>` **<** :ref:`Node<class_node>` **<** :ref:`Object<class_object>`
  8. **Category:** Core
  9. Brief Description
  10. -----------------
  11. A hinge between two 3D bodies.
  12. Member Variables
  13. ----------------
  14. .. _class_HingeJoint_angular_limit/bias:
  15. - :ref:`float<class_float>` **angular_limit/bias** - The speed with which the rotation across the axis perpendicular to the hinge gets corrected.
  16. .. _class_HingeJoint_angular_limit/enable:
  17. - :ref:`bool<class_bool>` **angular_limit/enable** - If ``true`` the hinges maximum and minimum rotation, defined by :ref:`angular_limit/lower<class_HingeJoint_angular_limit/lower>` and :ref:`angular_limit/upper<class_HingeJoint_angular_limit/upper>` has effects.
  18. .. _class_HingeJoint_angular_limit/lower:
  19. - :ref:`float<class_float>` **angular_limit/lower** - The minimum rotation. only active if :ref:`angular_limit/enable<class_HingeJoint_angular_limit/enable>` is ``true``.
  20. .. _class_HingeJoint_angular_limit/relaxation:
  21. - :ref:`float<class_float>` **angular_limit/relaxation** - The lower this value, the more the rotation gets slowed down.
  22. .. _class_HingeJoint_angular_limit/softness:
  23. - :ref:`float<class_float>` **angular_limit/softness**
  24. .. _class_HingeJoint_angular_limit/upper:
  25. - :ref:`float<class_float>` **angular_limit/upper** - The maximum rotation. only active if :ref:`angular_limit/enable<class_HingeJoint_angular_limit/enable>` is ``true``.
  26. .. _class_HingeJoint_motor/enable:
  27. - :ref:`bool<class_bool>` **motor/enable** - When activated, a motor turns the hinge.
  28. .. _class_HingeJoint_motor/max_impulse:
  29. - :ref:`float<class_float>` **motor/max_impulse** - Maximum acceleration for the motor.
  30. .. _class_HingeJoint_motor/target_velocity:
  31. - :ref:`float<class_float>` **motor/target_velocity** - Target speed for the motor.
  32. .. _class_HingeJoint_params/bias:
  33. - :ref:`float<class_float>` **params/bias** - The speed with which the two bodies get pulled together when they move in different directions.
  34. Enums
  35. -----
  36. .. _enum_HingeJoint_Flag:
  37. enum **Flag**
  38. - **FLAG_USE_LIMIT** = **0** --- If ``true`` the hinges maximum and minimum rotation, defined by :ref:`angular_limit/lower<class_HingeJoint_angular_limit/lower>` and :ref:`angular_limit/upper<class_HingeJoint_angular_limit/upper>` has effects.
  39. - **FLAG_ENABLE_MOTOR** = **1** --- When activated, a motor turns the hinge.
  40. - **FLAG_MAX** = **2** --- End flag of FLAG\_\* constants, used internally.
  41. .. _enum_HingeJoint_Param:
  42. enum **Param**
  43. - **PARAM_BIAS** = **0** --- The speed with which the two bodies get pulled together when they move in different directions.
  44. - **PARAM_LIMIT_UPPER** = **1** --- The maximum rotation. only active if :ref:`angular_limit/enable<class_HingeJoint_angular_limit/enable>` is ``true``.
  45. - **PARAM_LIMIT_LOWER** = **2** --- The minimum rotation. only active if :ref:`angular_limit/enable<class_HingeJoint_angular_limit/enable>` is ``true``.
  46. - **PARAM_LIMIT_BIAS** = **3** --- The speed with which the rotation across the axis perpendicular to the hinge gets corrected.
  47. - **PARAM_LIMIT_SOFTNESS** = **4**
  48. - **PARAM_LIMIT_RELAXATION** = **5** --- The lower this value, the more the rotation gets slowed down.
  49. - **PARAM_MOTOR_TARGET_VELOCITY** = **6** --- Target speed for the motor.
  50. - **PARAM_MOTOR_MAX_IMPULSE** = **7** --- Maximum acceleration for the motor.
  51. - **PARAM_MAX** = **8** --- End flag of PARAM\_\* constants, used internally.
  52. Description
  53. -----------
  54. Normally uses the z-axis of body A as the hinge axis, another axis can be specified when adding it manually though.