class_skeletonmodifier3d.rst 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227
  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/SkeletonModifier3D.xml.
  6. .. _class_SkeletonModifier3D:
  7. SkeletonModifier3D
  8. ==================
  9. **Inherits:** :ref:`Node3D<class_Node3D>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
  10. **Inherited By:** :ref:`LookAtModifier3D<class_LookAtModifier3D>`, :ref:`PhysicalBoneSimulator3D<class_PhysicalBoneSimulator3D>`, :ref:`RetargetModifier3D<class_RetargetModifier3D>`, :ref:`SkeletonIK3D<class_SkeletonIK3D>`, :ref:`SpringBoneSimulator3D<class_SpringBoneSimulator3D>`, :ref:`XRBodyModifier3D<class_XRBodyModifier3D>`, :ref:`XRHandModifier3D<class_XRHandModifier3D>`
  11. A node that may modify Skeleton3D's bone.
  12. .. rst-class:: classref-introduction-group
  13. Description
  14. -----------
  15. **SkeletonModifier3D** retrieves a target :ref:`Skeleton3D<class_Skeleton3D>` by having a :ref:`Skeleton3D<class_Skeleton3D>` parent.
  16. If there is :ref:`AnimationMixer<class_AnimationMixer>`, modification always performs after playback process of the :ref:`AnimationMixer<class_AnimationMixer>`.
  17. This node should be used to implement custom IK solvers, constraints, or skeleton physics.
  18. .. rst-class:: classref-introduction-group
  19. Tutorials
  20. ---------
  21. - `Design of the Skeleton Modifier 3D <https://godotengine.org/article/design-of-the-skeleton-modifier-3d/>`__
  22. .. rst-class:: classref-reftable-group
  23. Properties
  24. ----------
  25. .. table::
  26. :widths: auto
  27. +---------------------------+---------------------------------------------------------------+----------+
  28. | :ref:`bool<class_bool>` | :ref:`active<class_SkeletonModifier3D_property_active>` | ``true`` |
  29. +---------------------------+---------------------------------------------------------------+----------+
  30. | :ref:`float<class_float>` | :ref:`influence<class_SkeletonModifier3D_property_influence>` | ``1.0`` |
  31. +---------------------------+---------------------------------------------------------------+----------+
  32. .. rst-class:: classref-reftable-group
  33. Methods
  34. -------
  35. .. table::
  36. :widths: auto
  37. +-------------------------------------+-------------------------------------------------------------------------------------------------------------+
  38. | |void| | :ref:`_process_modification<class_SkeletonModifier3D_private_method__process_modification>`\ (\ ) |virtual| |
  39. +-------------------------------------+-------------------------------------------------------------------------------------------------------------+
  40. | :ref:`Skeleton3D<class_Skeleton3D>` | :ref:`get_skeleton<class_SkeletonModifier3D_method_get_skeleton>`\ (\ ) |const| |
  41. +-------------------------------------+-------------------------------------------------------------------------------------------------------------+
  42. .. rst-class:: classref-section-separator
  43. ----
  44. .. rst-class:: classref-descriptions-group
  45. Signals
  46. -------
  47. .. _class_SkeletonModifier3D_signal_modification_processed:
  48. .. rst-class:: classref-signal
  49. **modification_processed**\ (\ ) :ref:`🔗<class_SkeletonModifier3D_signal_modification_processed>`
  50. Notifies when the modification have been finished.
  51. \ **Note:** If you want to get the modified bone pose by the modifier, you must use :ref:`Skeleton3D.get_bone_pose()<class_Skeleton3D_method_get_bone_pose>` or :ref:`Skeleton3D.get_bone_global_pose()<class_Skeleton3D_method_get_bone_global_pose>` at the moment this signal is fired.
  52. .. rst-class:: classref-section-separator
  53. ----
  54. .. rst-class:: classref-descriptions-group
  55. Enumerations
  56. ------------
  57. .. _enum_SkeletonModifier3D_BoneAxis:
  58. .. rst-class:: classref-enumeration
  59. enum **BoneAxis**: :ref:`🔗<enum_SkeletonModifier3D_BoneAxis>`
  60. .. _class_SkeletonModifier3D_constant_BONE_AXIS_PLUS_X:
  61. .. rst-class:: classref-enumeration-constant
  62. :ref:`BoneAxis<enum_SkeletonModifier3D_BoneAxis>` **BONE_AXIS_PLUS_X** = ``0``
  63. Enumerated value for the +X axis.
  64. .. _class_SkeletonModifier3D_constant_BONE_AXIS_MINUS_X:
  65. .. rst-class:: classref-enumeration-constant
  66. :ref:`BoneAxis<enum_SkeletonModifier3D_BoneAxis>` **BONE_AXIS_MINUS_X** = ``1``
  67. Enumerated value for the -X axis.
  68. .. _class_SkeletonModifier3D_constant_BONE_AXIS_PLUS_Y:
  69. .. rst-class:: classref-enumeration-constant
  70. :ref:`BoneAxis<enum_SkeletonModifier3D_BoneAxis>` **BONE_AXIS_PLUS_Y** = ``2``
  71. Enumerated value for the +Y axis.
  72. .. _class_SkeletonModifier3D_constant_BONE_AXIS_MINUS_Y:
  73. .. rst-class:: classref-enumeration-constant
  74. :ref:`BoneAxis<enum_SkeletonModifier3D_BoneAxis>` **BONE_AXIS_MINUS_Y** = ``3``
  75. Enumerated value for the -Y axis.
  76. .. _class_SkeletonModifier3D_constant_BONE_AXIS_PLUS_Z:
  77. .. rst-class:: classref-enumeration-constant
  78. :ref:`BoneAxis<enum_SkeletonModifier3D_BoneAxis>` **BONE_AXIS_PLUS_Z** = ``4``
  79. Enumerated value for the +Z axis.
  80. .. _class_SkeletonModifier3D_constant_BONE_AXIS_MINUS_Z:
  81. .. rst-class:: classref-enumeration-constant
  82. :ref:`BoneAxis<enum_SkeletonModifier3D_BoneAxis>` **BONE_AXIS_MINUS_Z** = ``5``
  83. Enumerated value for the -Z axis.
  84. .. rst-class:: classref-section-separator
  85. ----
  86. .. rst-class:: classref-descriptions-group
  87. Property Descriptions
  88. ---------------------
  89. .. _class_SkeletonModifier3D_property_active:
  90. .. rst-class:: classref-property
  91. :ref:`bool<class_bool>` **active** = ``true`` :ref:`🔗<class_SkeletonModifier3D_property_active>`
  92. .. rst-class:: classref-property-setget
  93. - |void| **set_active**\ (\ value\: :ref:`bool<class_bool>`\ )
  94. - :ref:`bool<class_bool>` **is_active**\ (\ )
  95. If ``true``, the **SkeletonModifier3D** will be processing.
  96. .. rst-class:: classref-item-separator
  97. ----
  98. .. _class_SkeletonModifier3D_property_influence:
  99. .. rst-class:: classref-property
  100. :ref:`float<class_float>` **influence** = ``1.0`` :ref:`🔗<class_SkeletonModifier3D_property_influence>`
  101. .. rst-class:: classref-property-setget
  102. - |void| **set_influence**\ (\ value\: :ref:`float<class_float>`\ )
  103. - :ref:`float<class_float>` **get_influence**\ (\ )
  104. Sets the influence of the modification.
  105. \ **Note:** This value is used by :ref:`Skeleton3D<class_Skeleton3D>` to blend, so the **SkeletonModifier3D** should always apply only 100% of the result without interpolation.
  106. .. rst-class:: classref-section-separator
  107. ----
  108. .. rst-class:: classref-descriptions-group
  109. Method Descriptions
  110. -------------------
  111. .. _class_SkeletonModifier3D_private_method__process_modification:
  112. .. rst-class:: classref-method
  113. |void| **_process_modification**\ (\ ) |virtual| :ref:`🔗<class_SkeletonModifier3D_private_method__process_modification>`
  114. Override this virtual method to implement a custom skeleton modifier. You should do things like get the :ref:`Skeleton3D<class_Skeleton3D>`'s current pose and apply the pose here.
  115. \ :ref:`_process_modification()<class_SkeletonModifier3D_private_method__process_modification>` must not apply :ref:`influence<class_SkeletonModifier3D_property_influence>` to bone poses because the :ref:`Skeleton3D<class_Skeleton3D>` automatically applies influence to all bone poses set by the modifier.
  116. .. rst-class:: classref-item-separator
  117. ----
  118. .. _class_SkeletonModifier3D_method_get_skeleton:
  119. .. rst-class:: classref-method
  120. :ref:`Skeleton3D<class_Skeleton3D>` **get_skeleton**\ (\ ) |const| :ref:`🔗<class_SkeletonModifier3D_method_get_skeleton>`
  121. Get parent :ref:`Skeleton3D<class_Skeleton3D>` node if found.
  122. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  123. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  124. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  125. .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
  126. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
  127. .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`
  128. .. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)`
  129. .. |void| replace:: :abbr:`void (No return value.)`