class_splineik3d.rst 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209
  1. :github_url: hide
  2. .. DO NOT EDIT THIS FILE!!!
  3. .. Generated automatically from Godot engine sources.
  4. .. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py.
  5. .. XML source: https://github.com/godotengine/godot/tree/master/doc/classes/SplineIK3D.xml.
  6. .. _class_SplineIK3D:
  7. SplineIK3D
  8. ==========
  9. **Inherits:** :ref:`ChainIK3D<class_ChainIK3D>` **<** :ref:`IKModifier3D<class_IKModifier3D>` **<** :ref:`SkeletonModifier3D<class_SkeletonModifier3D>` **<** :ref:`Node3D<class_Node3D>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
  10. A :ref:`SkeletonModifier3D<class_SkeletonModifier3D>` for aligning bones along a :ref:`Path3D<class_Path3D>`.
  11. .. rst-class:: classref-introduction-group
  12. Description
  13. -----------
  14. A :ref:`SkeletonModifier3D<class_SkeletonModifier3D>` for aligning bones along a :ref:`Path3D<class_Path3D>`. The smoothness of the fitting depends on the :ref:`Curve3D.bake_interval<class_Curve3D_property_bake_interval>`.
  15. If you want the :ref:`Path3D<class_Path3D>` to attach to a specific bone, it is recommended to place a :ref:`ModifierBoneTarget3D<class_ModifierBoneTarget3D>` before the **SplineIK3D** in the :ref:`SkeletonModifier3D<class_SkeletonModifier3D>` list (children of the :ref:`Skeleton3D<class_Skeleton3D>`), and then place a :ref:`Path3D<class_Path3D>` as the :ref:`ModifierBoneTarget3D<class_ModifierBoneTarget3D>`'s child.
  16. Bone twist is determined based on the :ref:`Curve3D.get_point_tilt()<class_Curve3D_method_get_point_tilt>`.
  17. If the root bone joint and the start point of the :ref:`Curve3D<class_Curve3D>` are separated, it assumes that there is a linear line segment between them. This means that the vector pointing toward the start point of the :ref:`Curve3D<class_Curve3D>` takes precedence over the shortest intersection point along the :ref:`Curve3D<class_Curve3D>`.
  18. If the end bone joint exceeds the path length, it is bent as close as possible to the end point of the :ref:`Curve3D<class_Curve3D>`.
  19. .. rst-class:: classref-reftable-group
  20. Properties
  21. ----------
  22. .. table::
  23. :widths: auto
  24. +-----------------------+---------------------------------------------------------------+-------+
  25. | :ref:`int<class_int>` | :ref:`setting_count<class_SplineIK3D_property_setting_count>` | ``0`` |
  26. +-----------------------+---------------------------------------------------------------+-------+
  27. .. rst-class:: classref-reftable-group
  28. Methods
  29. -------
  30. .. table::
  31. :widths: auto
  32. +---------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------+
  33. | :ref:`NodePath<class_NodePath>` | :ref:`get_path_3d<class_SplineIK3D_method_get_path_3d>`\ (\ index\: :ref:`int<class_int>`\ ) |const| |
  34. +---------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------+
  35. | :ref:`int<class_int>` | :ref:`get_tilt_fade_in<class_SplineIK3D_method_get_tilt_fade_in>`\ (\ index\: :ref:`int<class_int>`\ ) |const| |
  36. +---------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------+
  37. | :ref:`int<class_int>` | :ref:`get_tilt_fade_out<class_SplineIK3D_method_get_tilt_fade_out>`\ (\ index\: :ref:`int<class_int>`\ ) |const| |
  38. +---------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------+
  39. | :ref:`bool<class_bool>` | :ref:`is_tilt_enabled<class_SplineIK3D_method_is_tilt_enabled>`\ (\ index\: :ref:`int<class_int>`\ ) |const| |
  40. +---------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------+
  41. | |void| | :ref:`set_path_3d<class_SplineIK3D_method_set_path_3d>`\ (\ index\: :ref:`int<class_int>`, path_3d\: :ref:`NodePath<class_NodePath>`\ ) |
  42. +---------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------+
  43. | |void| | :ref:`set_tilt_enabled<class_SplineIK3D_method_set_tilt_enabled>`\ (\ index\: :ref:`int<class_int>`, enabled\: :ref:`bool<class_bool>`\ ) |
  44. +---------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------+
  45. | |void| | :ref:`set_tilt_fade_in<class_SplineIK3D_method_set_tilt_fade_in>`\ (\ index\: :ref:`int<class_int>`, size\: :ref:`int<class_int>`\ ) |
  46. +---------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------+
  47. | |void| | :ref:`set_tilt_fade_out<class_SplineIK3D_method_set_tilt_fade_out>`\ (\ index\: :ref:`int<class_int>`, size\: :ref:`int<class_int>`\ ) |
  48. +---------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------+
  49. .. rst-class:: classref-section-separator
  50. ----
  51. .. rst-class:: classref-descriptions-group
  52. Property Descriptions
  53. ---------------------
  54. .. _class_SplineIK3D_property_setting_count:
  55. .. rst-class:: classref-property
  56. :ref:`int<class_int>` **setting_count** = ``0`` :ref:`🔗<class_SplineIK3D_property_setting_count>`
  57. .. rst-class:: classref-property-setget
  58. - |void| **set_setting_count**\ (\ value\: :ref:`int<class_int>`\ )
  59. - :ref:`int<class_int>` **get_setting_count**\ (\ )
  60. The number of settings.
  61. .. rst-class:: classref-section-separator
  62. ----
  63. .. rst-class:: classref-descriptions-group
  64. Method Descriptions
  65. -------------------
  66. .. _class_SplineIK3D_method_get_path_3d:
  67. .. rst-class:: classref-method
  68. :ref:`NodePath<class_NodePath>` **get_path_3d**\ (\ index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_SplineIK3D_method_get_path_3d>`
  69. Returns the node path of the :ref:`Path3D<class_Path3D>` which is describing the path.
  70. .. rst-class:: classref-item-separator
  71. ----
  72. .. _class_SplineIK3D_method_get_tilt_fade_in:
  73. .. rst-class:: classref-method
  74. :ref:`int<class_int>` **get_tilt_fade_in**\ (\ index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_SplineIK3D_method_get_tilt_fade_in>`
  75. Returns the tilt interpolation method used between the root bone and the start point of the :ref:`Curve3D<class_Curve3D>` when they are apart. See also :ref:`set_tilt_fade_in()<class_SplineIK3D_method_set_tilt_fade_in>`.
  76. .. rst-class:: classref-item-separator
  77. ----
  78. .. _class_SplineIK3D_method_get_tilt_fade_out:
  79. .. rst-class:: classref-method
  80. :ref:`int<class_int>` **get_tilt_fade_out**\ (\ index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_SplineIK3D_method_get_tilt_fade_out>`
  81. Returns the tilt interpolation method used between the end bone and the end point of the :ref:`Curve3D<class_Curve3D>` when they are apart. See also :ref:`set_tilt_fade_out()<class_SplineIK3D_method_set_tilt_fade_out>`.
  82. .. rst-class:: classref-item-separator
  83. ----
  84. .. _class_SplineIK3D_method_is_tilt_enabled:
  85. .. rst-class:: classref-method
  86. :ref:`bool<class_bool>` **is_tilt_enabled**\ (\ index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_SplineIK3D_method_is_tilt_enabled>`
  87. Returns if the tilt property of the :ref:`Curve3D<class_Curve3D>` affects the bone twist.
  88. .. rst-class:: classref-item-separator
  89. ----
  90. .. _class_SplineIK3D_method_set_path_3d:
  91. .. rst-class:: classref-method
  92. |void| **set_path_3d**\ (\ index\: :ref:`int<class_int>`, path_3d\: :ref:`NodePath<class_NodePath>`\ ) :ref:`🔗<class_SplineIK3D_method_set_path_3d>`
  93. Sets the node path of the :ref:`Path3D<class_Path3D>` which is describing the path.
  94. .. rst-class:: classref-item-separator
  95. ----
  96. .. _class_SplineIK3D_method_set_tilt_enabled:
  97. .. rst-class:: classref-method
  98. |void| **set_tilt_enabled**\ (\ index\: :ref:`int<class_int>`, enabled\: :ref:`bool<class_bool>`\ ) :ref:`🔗<class_SplineIK3D_method_set_tilt_enabled>`
  99. Sets if the tilt property of the :ref:`Curve3D<class_Curve3D>` should affect the bone twist.
  100. .. rst-class:: classref-item-separator
  101. ----
  102. .. _class_SplineIK3D_method_set_tilt_fade_in:
  103. .. rst-class:: classref-method
  104. |void| **set_tilt_fade_in**\ (\ index\: :ref:`int<class_int>`, size\: :ref:`int<class_int>`\ ) :ref:`🔗<class_SplineIK3D_method_set_tilt_fade_in>`
  105. If ``size`` is greater than ``0``, the tilt is interpolated between ``size`` start bones from the start point of the :ref:`Curve3D<class_Curve3D>` when they are apart.
  106. If ``size`` is equal ``0``, the tilts between the root bone head and the start point of the :ref:`Curve3D<class_Curve3D>` are unified with a tilt of the start point of the :ref:`Curve3D<class_Curve3D>`.
  107. If ``size`` is less than ``0``, the tilts between the root bone and the start point of the :ref:`Curve3D<class_Curve3D>` are ``0.0``.
  108. .. rst-class:: classref-item-separator
  109. ----
  110. .. _class_SplineIK3D_method_set_tilt_fade_out:
  111. .. rst-class:: classref-method
  112. |void| **set_tilt_fade_out**\ (\ index\: :ref:`int<class_int>`, size\: :ref:`int<class_int>`\ ) :ref:`🔗<class_SplineIK3D_method_set_tilt_fade_out>`
  113. If ``size`` is greater than ``0``, the tilt is interpolated between ``size`` end bones from the end point of the :ref:`Curve3D<class_Curve3D>` when they are apart.
  114. If ``size`` is equal ``0``, the tilts between the end bone tail and the end point of the :ref:`Curve3D<class_Curve3D>` are unified with a tilt of the end point of the :ref:`Curve3D<class_Curve3D>`.
  115. If ``size`` is less than ``0``, the tilts between the end bone and the end point of the :ref:`Curve3D<class_Curve3D>` are ``0.0``.
  116. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  117. .. |required| replace:: :abbr:`required (This method is required to be overridden when extending its base class.)`
  118. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  119. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  120. .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
  121. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
  122. .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`
  123. .. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)`
  124. .. |void| replace:: :abbr:`void (No return value.)`