class_skeleton3d.rst 56 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923
  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/4.3/doc/tools/make_rst.py.
  5. .. XML source: https://github.com/godotengine/godot/tree/4.3/doc/classes/Skeleton3D.xml.
  6. .. _class_Skeleton3D:
  7. Skeleton3D
  8. ==========
  9. **Inherits:** :ref:`Node3D<class_Node3D>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
  10. A node containing a bone hierarchy, used to create a 3D skeletal animation.
  11. .. rst-class:: classref-introduction-group
  12. Description
  13. -----------
  14. **Skeleton3D** provides an interface for managing a hierarchy of bones, including pose, rest and animation (see :ref:`Animation<class_Animation>`). It can also use ragdoll physics.
  15. The overall transform of a bone with respect to the skeleton is determined by bone pose. Bone rest defines the initial transform of the bone pose.
  16. Note that "global pose" below refers to the overall transform of the bone with respect to skeleton, so it is not the actual global/world transform of the bone.
  17. .. rst-class:: classref-introduction-group
  18. Tutorials
  19. ---------
  20. - `Third Person Shooter (TPS) Demo <https://godotengine.org/asset-library/asset/2710>`__
  21. .. rst-class:: classref-reftable-group
  22. Properties
  23. ----------
  24. .. table::
  25. :widths: auto
  26. +---------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+-----------+
  27. | :ref:`bool<class_bool>` | :ref:`animate_physical_bones<class_Skeleton3D_property_animate_physical_bones>` | ``true`` |
  28. +---------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+-----------+
  29. | :ref:`ModifierCallbackModeProcess<enum_Skeleton3D_ModifierCallbackModeProcess>` | :ref:`modifier_callback_mode_process<class_Skeleton3D_property_modifier_callback_mode_process>` | ``1`` |
  30. +---------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+-----------+
  31. | :ref:`float<class_float>` | :ref:`motion_scale<class_Skeleton3D_property_motion_scale>` | ``1.0`` |
  32. +---------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+-----------+
  33. | :ref:`bool<class_bool>` | :ref:`show_rest_only<class_Skeleton3D_property_show_rest_only>` | ``false`` |
  34. +---------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+-----------+
  35. .. rst-class:: classref-reftable-group
  36. Methods
  37. -------
  38. .. table::
  39. :widths: auto
  40. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  41. | :ref:`int<class_int>` | :ref:`add_bone<class_Skeleton3D_method_add_bone>`\ (\ name\: :ref:`String<class_String>`\ ) |
  42. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  43. | |void| | :ref:`clear_bones<class_Skeleton3D_method_clear_bones>`\ (\ ) |
  44. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  45. | |void| | :ref:`clear_bones_global_pose_override<class_Skeleton3D_method_clear_bones_global_pose_override>`\ (\ ) |
  46. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  47. | :ref:`Skin<class_Skin>` | :ref:`create_skin_from_rest_transforms<class_Skeleton3D_method_create_skin_from_rest_transforms>`\ (\ ) |
  48. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  49. | :ref:`int<class_int>` | :ref:`find_bone<class_Skeleton3D_method_find_bone>`\ (\ name\: :ref:`String<class_String>`\ ) |const| |
  50. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  51. | |void| | :ref:`force_update_all_bone_transforms<class_Skeleton3D_method_force_update_all_bone_transforms>`\ (\ ) |
  52. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  53. | |void| | :ref:`force_update_bone_child_transform<class_Skeleton3D_method_force_update_bone_child_transform>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |
  54. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  55. | :ref:`PackedInt32Array<class_PackedInt32Array>` | :ref:`get_bone_children<class_Skeleton3D_method_get_bone_children>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  56. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  57. | :ref:`int<class_int>` | :ref:`get_bone_count<class_Skeleton3D_method_get_bone_count>`\ (\ ) |const| |
  58. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  59. | :ref:`Transform3D<class_Transform3D>` | :ref:`get_bone_global_pose<class_Skeleton3D_method_get_bone_global_pose>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  60. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  61. | :ref:`Transform3D<class_Transform3D>` | :ref:`get_bone_global_pose_no_override<class_Skeleton3D_method_get_bone_global_pose_no_override>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  62. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  63. | :ref:`Transform3D<class_Transform3D>` | :ref:`get_bone_global_pose_override<class_Skeleton3D_method_get_bone_global_pose_override>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  64. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  65. | :ref:`Transform3D<class_Transform3D>` | :ref:`get_bone_global_rest<class_Skeleton3D_method_get_bone_global_rest>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  66. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  67. | :ref:`String<class_String>` | :ref:`get_bone_name<class_Skeleton3D_method_get_bone_name>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  68. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  69. | :ref:`int<class_int>` | :ref:`get_bone_parent<class_Skeleton3D_method_get_bone_parent>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  70. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  71. | :ref:`Transform3D<class_Transform3D>` | :ref:`get_bone_pose<class_Skeleton3D_method_get_bone_pose>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  72. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  73. | :ref:`Vector3<class_Vector3>` | :ref:`get_bone_pose_position<class_Skeleton3D_method_get_bone_pose_position>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  74. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  75. | :ref:`Quaternion<class_Quaternion>` | :ref:`get_bone_pose_rotation<class_Skeleton3D_method_get_bone_pose_rotation>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  76. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  77. | :ref:`Vector3<class_Vector3>` | :ref:`get_bone_pose_scale<class_Skeleton3D_method_get_bone_pose_scale>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  78. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  79. | :ref:`Transform3D<class_Transform3D>` | :ref:`get_bone_rest<class_Skeleton3D_method_get_bone_rest>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  80. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  81. | :ref:`StringName<class_StringName>` | :ref:`get_concatenated_bone_names<class_Skeleton3D_method_get_concatenated_bone_names>`\ (\ ) |const| |
  82. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  83. | :ref:`PackedInt32Array<class_PackedInt32Array>` | :ref:`get_parentless_bones<class_Skeleton3D_method_get_parentless_bones>`\ (\ ) |const| |
  84. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  85. | :ref:`int<class_int>` | :ref:`get_version<class_Skeleton3D_method_get_version>`\ (\ ) |const| |
  86. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  87. | :ref:`bool<class_bool>` | :ref:`is_bone_enabled<class_Skeleton3D_method_is_bone_enabled>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| |
  88. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  89. | |void| | :ref:`localize_rests<class_Skeleton3D_method_localize_rests>`\ (\ ) |
  90. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  91. | |void| | :ref:`physical_bones_add_collision_exception<class_Skeleton3D_method_physical_bones_add_collision_exception>`\ (\ exception\: :ref:`RID<class_RID>`\ ) |
  92. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  93. | |void| | :ref:`physical_bones_remove_collision_exception<class_Skeleton3D_method_physical_bones_remove_collision_exception>`\ (\ exception\: :ref:`RID<class_RID>`\ ) |
  94. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  95. | |void| | :ref:`physical_bones_start_simulation<class_Skeleton3D_method_physical_bones_start_simulation>`\ (\ bones\: :ref:`Array<class_Array>`\[:ref:`StringName<class_StringName>`\] = []\ ) |
  96. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  97. | |void| | :ref:`physical_bones_stop_simulation<class_Skeleton3D_method_physical_bones_stop_simulation>`\ (\ ) |
  98. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  99. | :ref:`SkinReference<class_SkinReference>` | :ref:`register_skin<class_Skeleton3D_method_register_skin>`\ (\ skin\: :ref:`Skin<class_Skin>`\ ) |
  100. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  101. | |void| | :ref:`reset_bone_pose<class_Skeleton3D_method_reset_bone_pose>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |
  102. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  103. | |void| | :ref:`reset_bone_poses<class_Skeleton3D_method_reset_bone_poses>`\ (\ ) |
  104. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  105. | |void| | :ref:`set_bone_enabled<class_Skeleton3D_method_set_bone_enabled>`\ (\ bone_idx\: :ref:`int<class_int>`, enabled\: :ref:`bool<class_bool>` = true\ ) |
  106. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  107. | |void| | :ref:`set_bone_global_pose<class_Skeleton3D_method_set_bone_global_pose>`\ (\ bone_idx\: :ref:`int<class_int>`, pose\: :ref:`Transform3D<class_Transform3D>`\ ) |
  108. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  109. | |void| | :ref:`set_bone_global_pose_override<class_Skeleton3D_method_set_bone_global_pose_override>`\ (\ bone_idx\: :ref:`int<class_int>`, pose\: :ref:`Transform3D<class_Transform3D>`, amount\: :ref:`float<class_float>`, persistent\: :ref:`bool<class_bool>` = false\ ) |
  110. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  111. | |void| | :ref:`set_bone_name<class_Skeleton3D_method_set_bone_name>`\ (\ bone_idx\: :ref:`int<class_int>`, name\: :ref:`String<class_String>`\ ) |
  112. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  113. | |void| | :ref:`set_bone_parent<class_Skeleton3D_method_set_bone_parent>`\ (\ bone_idx\: :ref:`int<class_int>`, parent_idx\: :ref:`int<class_int>`\ ) |
  114. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  115. | |void| | :ref:`set_bone_pose<class_Skeleton3D_method_set_bone_pose>`\ (\ bone_idx\: :ref:`int<class_int>`, pose\: :ref:`Transform3D<class_Transform3D>`\ ) |
  116. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  117. | |void| | :ref:`set_bone_pose_position<class_Skeleton3D_method_set_bone_pose_position>`\ (\ bone_idx\: :ref:`int<class_int>`, position\: :ref:`Vector3<class_Vector3>`\ ) |
  118. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  119. | |void| | :ref:`set_bone_pose_rotation<class_Skeleton3D_method_set_bone_pose_rotation>`\ (\ bone_idx\: :ref:`int<class_int>`, rotation\: :ref:`Quaternion<class_Quaternion>`\ ) |
  120. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  121. | |void| | :ref:`set_bone_pose_scale<class_Skeleton3D_method_set_bone_pose_scale>`\ (\ bone_idx\: :ref:`int<class_int>`, scale\: :ref:`Vector3<class_Vector3>`\ ) |
  122. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  123. | |void| | :ref:`set_bone_rest<class_Skeleton3D_method_set_bone_rest>`\ (\ bone_idx\: :ref:`int<class_int>`, rest\: :ref:`Transform3D<class_Transform3D>`\ ) |
  124. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  125. | |void| | :ref:`unparent_bone_and_rest<class_Skeleton3D_method_unparent_bone_and_rest>`\ (\ bone_idx\: :ref:`int<class_int>`\ ) |
  126. +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  127. .. rst-class:: classref-section-separator
  128. ----
  129. .. rst-class:: classref-descriptions-group
  130. Signals
  131. -------
  132. .. _class_Skeleton3D_signal_bone_enabled_changed:
  133. .. rst-class:: classref-signal
  134. **bone_enabled_changed**\ (\ bone_idx\: :ref:`int<class_int>`\ ) :ref:`🔗<class_Skeleton3D_signal_bone_enabled_changed>`
  135. Emitted when the bone at ``bone_idx`` is toggled with :ref:`set_bone_enabled<class_Skeleton3D_method_set_bone_enabled>`. Use :ref:`is_bone_enabled<class_Skeleton3D_method_is_bone_enabled>` to check the new value.
  136. .. rst-class:: classref-item-separator
  137. ----
  138. .. _class_Skeleton3D_signal_bone_list_changed:
  139. .. rst-class:: classref-signal
  140. **bone_list_changed**\ (\ ) :ref:`🔗<class_Skeleton3D_signal_bone_list_changed>`
  141. .. container:: contribute
  142. There is currently no description for this signal. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
  143. .. rst-class:: classref-item-separator
  144. ----
  145. .. _class_Skeleton3D_signal_pose_updated:
  146. .. rst-class:: classref-signal
  147. **pose_updated**\ (\ ) :ref:`🔗<class_Skeleton3D_signal_pose_updated>`
  148. Emitted when the pose is updated.
  149. \ **Note:** During the update process, this signal is not fired, so modification by :ref:`SkeletonModifier3D<class_SkeletonModifier3D>` is not detected.
  150. .. rst-class:: classref-item-separator
  151. ----
  152. .. _class_Skeleton3D_signal_show_rest_only_changed:
  153. .. rst-class:: classref-signal
  154. **show_rest_only_changed**\ (\ ) :ref:`🔗<class_Skeleton3D_signal_show_rest_only_changed>`
  155. Emitted when the value of :ref:`show_rest_only<class_Skeleton3D_property_show_rest_only>` changes.
  156. .. rst-class:: classref-item-separator
  157. ----
  158. .. _class_Skeleton3D_signal_skeleton_updated:
  159. .. rst-class:: classref-signal
  160. **skeleton_updated**\ (\ ) :ref:`🔗<class_Skeleton3D_signal_skeleton_updated>`
  161. Emitted when the final pose has been calculated will be applied to the skin in the update process.
  162. This means that all :ref:`SkeletonModifier3D<class_SkeletonModifier3D>` processing is complete. In order to detect the completion of the processing of each :ref:`SkeletonModifier3D<class_SkeletonModifier3D>`, use :ref:`SkeletonModifier3D.modification_processed<class_SkeletonModifier3D_signal_modification_processed>`.
  163. .. rst-class:: classref-section-separator
  164. ----
  165. .. rst-class:: classref-descriptions-group
  166. Enumerations
  167. ------------
  168. .. _enum_Skeleton3D_ModifierCallbackModeProcess:
  169. .. rst-class:: classref-enumeration
  170. enum **ModifierCallbackModeProcess**: :ref:`🔗<enum_Skeleton3D_ModifierCallbackModeProcess>`
  171. .. _class_Skeleton3D_constant_MODIFIER_CALLBACK_MODE_PROCESS_PHYSICS:
  172. .. rst-class:: classref-enumeration-constant
  173. :ref:`ModifierCallbackModeProcess<enum_Skeleton3D_ModifierCallbackModeProcess>` **MODIFIER_CALLBACK_MODE_PROCESS_PHYSICS** = ``0``
  174. Set a flag to process modification during physics frames (see :ref:`Node.NOTIFICATION_INTERNAL_PHYSICS_PROCESS<class_Node_constant_NOTIFICATION_INTERNAL_PHYSICS_PROCESS>`).
  175. .. _class_Skeleton3D_constant_MODIFIER_CALLBACK_MODE_PROCESS_IDLE:
  176. .. rst-class:: classref-enumeration-constant
  177. :ref:`ModifierCallbackModeProcess<enum_Skeleton3D_ModifierCallbackModeProcess>` **MODIFIER_CALLBACK_MODE_PROCESS_IDLE** = ``1``
  178. Set a flag to process modification during process frames (see :ref:`Node.NOTIFICATION_INTERNAL_PROCESS<class_Node_constant_NOTIFICATION_INTERNAL_PROCESS>`).
  179. .. rst-class:: classref-section-separator
  180. ----
  181. .. rst-class:: classref-descriptions-group
  182. Constants
  183. ---------
  184. .. _class_Skeleton3D_constant_NOTIFICATION_UPDATE_SKELETON:
  185. .. rst-class:: classref-constant
  186. **NOTIFICATION_UPDATE_SKELETON** = ``50`` :ref:`🔗<class_Skeleton3D_constant_NOTIFICATION_UPDATE_SKELETON>`
  187. Notification received when this skeleton's pose needs to be updated. In that case, this is called only once per frame in a deferred process.
  188. .. rst-class:: classref-section-separator
  189. ----
  190. .. rst-class:: classref-descriptions-group
  191. Property Descriptions
  192. ---------------------
  193. .. _class_Skeleton3D_property_animate_physical_bones:
  194. .. rst-class:: classref-property
  195. :ref:`bool<class_bool>` **animate_physical_bones** = ``true`` :ref:`🔗<class_Skeleton3D_property_animate_physical_bones>`
  196. .. rst-class:: classref-property-setget
  197. - |void| **set_animate_physical_bones**\ (\ value\: :ref:`bool<class_bool>`\ )
  198. - :ref:`bool<class_bool>` **get_animate_physical_bones**\ (\ )
  199. **Deprecated:** This property may be changed or removed in future versions.
  200. If you follow the recommended workflow and explicitly have :ref:`PhysicalBoneSimulator3D<class_PhysicalBoneSimulator3D>` as a child of **Skeleton3D**, you can control whether it is affected by raycasting without running :ref:`physical_bones_start_simulation<class_Skeleton3D_method_physical_bones_start_simulation>`, by its :ref:`SkeletonModifier3D.active<class_SkeletonModifier3D_property_active>`.
  201. However, for old (deprecated) configurations, **Skeleton3D** has an internal virtual :ref:`PhysicalBoneSimulator3D<class_PhysicalBoneSimulator3D>` for compatibility. This property controls the internal virtual :ref:`PhysicalBoneSimulator3D<class_PhysicalBoneSimulator3D>`'s :ref:`SkeletonModifier3D.active<class_SkeletonModifier3D_property_active>`.
  202. .. rst-class:: classref-item-separator
  203. ----
  204. .. _class_Skeleton3D_property_modifier_callback_mode_process:
  205. .. rst-class:: classref-property
  206. :ref:`ModifierCallbackModeProcess<enum_Skeleton3D_ModifierCallbackModeProcess>` **modifier_callback_mode_process** = ``1`` :ref:`🔗<class_Skeleton3D_property_modifier_callback_mode_process>`
  207. .. rst-class:: classref-property-setget
  208. - |void| **set_modifier_callback_mode_process**\ (\ value\: :ref:`ModifierCallbackModeProcess<enum_Skeleton3D_ModifierCallbackModeProcess>`\ )
  209. - :ref:`ModifierCallbackModeProcess<enum_Skeleton3D_ModifierCallbackModeProcess>` **get_modifier_callback_mode_process**\ (\ )
  210. Sets the processing timing for the Modifier.
  211. .. rst-class:: classref-item-separator
  212. ----
  213. .. _class_Skeleton3D_property_motion_scale:
  214. .. rst-class:: classref-property
  215. :ref:`float<class_float>` **motion_scale** = ``1.0`` :ref:`🔗<class_Skeleton3D_property_motion_scale>`
  216. .. rst-class:: classref-property-setget
  217. - |void| **set_motion_scale**\ (\ value\: :ref:`float<class_float>`\ )
  218. - :ref:`float<class_float>` **get_motion_scale**\ (\ )
  219. Multiplies the 3D position track animation.
  220. \ **Note:** Unless this value is ``1.0``, the key value in animation will not match the actual position value.
  221. .. rst-class:: classref-item-separator
  222. ----
  223. .. _class_Skeleton3D_property_show_rest_only:
  224. .. rst-class:: classref-property
  225. :ref:`bool<class_bool>` **show_rest_only** = ``false`` :ref:`🔗<class_Skeleton3D_property_show_rest_only>`
  226. .. rst-class:: classref-property-setget
  227. - |void| **set_show_rest_only**\ (\ value\: :ref:`bool<class_bool>`\ )
  228. - :ref:`bool<class_bool>` **is_show_rest_only**\ (\ )
  229. If ``true``, forces the bones in their default rest pose, regardless of their values. In the editor, this also prevents the bones from being edited.
  230. .. rst-class:: classref-section-separator
  231. ----
  232. .. rst-class:: classref-descriptions-group
  233. Method Descriptions
  234. -------------------
  235. .. _class_Skeleton3D_method_add_bone:
  236. .. rst-class:: classref-method
  237. :ref:`int<class_int>` **add_bone**\ (\ name\: :ref:`String<class_String>`\ ) :ref:`🔗<class_Skeleton3D_method_add_bone>`
  238. Adds a new bone with the given name. Returns the new bone's index, or ``-1`` if this method fails.
  239. \ **Note:** Bone names should be unique, non empty, and cannot include the ``:`` and ``/`` characters.
  240. .. rst-class:: classref-item-separator
  241. ----
  242. .. _class_Skeleton3D_method_clear_bones:
  243. .. rst-class:: classref-method
  244. |void| **clear_bones**\ (\ ) :ref:`🔗<class_Skeleton3D_method_clear_bones>`
  245. Clear all the bones in this skeleton.
  246. .. rst-class:: classref-item-separator
  247. ----
  248. .. _class_Skeleton3D_method_clear_bones_global_pose_override:
  249. .. rst-class:: classref-method
  250. |void| **clear_bones_global_pose_override**\ (\ ) :ref:`🔗<class_Skeleton3D_method_clear_bones_global_pose_override>`
  251. **Deprecated:** This method may be changed or removed in future versions.
  252. Removes the global pose override on all bones in the skeleton.
  253. .. rst-class:: classref-item-separator
  254. ----
  255. .. _class_Skeleton3D_method_create_skin_from_rest_transforms:
  256. .. rst-class:: classref-method
  257. :ref:`Skin<class_Skin>` **create_skin_from_rest_transforms**\ (\ ) :ref:`🔗<class_Skeleton3D_method_create_skin_from_rest_transforms>`
  258. .. container:: contribute
  259. There is currently no description for this method. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
  260. .. rst-class:: classref-item-separator
  261. ----
  262. .. _class_Skeleton3D_method_find_bone:
  263. .. rst-class:: classref-method
  264. :ref:`int<class_int>` **find_bone**\ (\ name\: :ref:`String<class_String>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_find_bone>`
  265. Returns the bone index that matches ``name`` as its name. Returns ``-1`` if no bone with this name exists.
  266. .. rst-class:: classref-item-separator
  267. ----
  268. .. _class_Skeleton3D_method_force_update_all_bone_transforms:
  269. .. rst-class:: classref-method
  270. |void| **force_update_all_bone_transforms**\ (\ ) :ref:`🔗<class_Skeleton3D_method_force_update_all_bone_transforms>`
  271. **Deprecated:** This method should only be called internally.
  272. Force updates the bone transforms/poses for all bones in the skeleton.
  273. .. rst-class:: classref-item-separator
  274. ----
  275. .. _class_Skeleton3D_method_force_update_bone_child_transform:
  276. .. rst-class:: classref-method
  277. |void| **force_update_bone_child_transform**\ (\ bone_idx\: :ref:`int<class_int>`\ ) :ref:`🔗<class_Skeleton3D_method_force_update_bone_child_transform>`
  278. Force updates the bone transform for the bone at ``bone_idx`` and all of its children.
  279. .. rst-class:: classref-item-separator
  280. ----
  281. .. _class_Skeleton3D_method_get_bone_children:
  282. .. rst-class:: classref-method
  283. :ref:`PackedInt32Array<class_PackedInt32Array>` **get_bone_children**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_children>`
  284. Returns an array containing the bone indexes of all the child node of the passed in bone, ``bone_idx``.
  285. .. rst-class:: classref-item-separator
  286. ----
  287. .. _class_Skeleton3D_method_get_bone_count:
  288. .. rst-class:: classref-method
  289. :ref:`int<class_int>` **get_bone_count**\ (\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_count>`
  290. Returns the number of bones in the skeleton.
  291. .. rst-class:: classref-item-separator
  292. ----
  293. .. _class_Skeleton3D_method_get_bone_global_pose:
  294. .. rst-class:: classref-method
  295. :ref:`Transform3D<class_Transform3D>` **get_bone_global_pose**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_global_pose>`
  296. Returns the overall transform of the specified bone, with respect to the skeleton. Being relative to the skeleton frame, this is not the actual "global" transform of the bone.
  297. \ **Note:** This is the global pose you set to the skeleton in the process, the final global pose can get overridden by modifiers in the deferred process, if you want to access the final global pose, use :ref:`SkeletonModifier3D.modification_processed<class_SkeletonModifier3D_signal_modification_processed>`.
  298. .. rst-class:: classref-item-separator
  299. ----
  300. .. _class_Skeleton3D_method_get_bone_global_pose_no_override:
  301. .. rst-class:: classref-method
  302. :ref:`Transform3D<class_Transform3D>` **get_bone_global_pose_no_override**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_global_pose_no_override>`
  303. **Deprecated:** This method may be changed or removed in future versions.
  304. Returns the overall transform of the specified bone, with respect to the skeleton, but without any global pose overrides. Being relative to the skeleton frame, this is not the actual "global" transform of the bone.
  305. .. rst-class:: classref-item-separator
  306. ----
  307. .. _class_Skeleton3D_method_get_bone_global_pose_override:
  308. .. rst-class:: classref-method
  309. :ref:`Transform3D<class_Transform3D>` **get_bone_global_pose_override**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_global_pose_override>`
  310. **Deprecated:** This method may be changed or removed in future versions.
  311. Returns the global pose override transform for ``bone_idx``.
  312. .. rst-class:: classref-item-separator
  313. ----
  314. .. _class_Skeleton3D_method_get_bone_global_rest:
  315. .. rst-class:: classref-method
  316. :ref:`Transform3D<class_Transform3D>` **get_bone_global_rest**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_global_rest>`
  317. Returns the global rest transform for ``bone_idx``.
  318. .. rst-class:: classref-item-separator
  319. ----
  320. .. _class_Skeleton3D_method_get_bone_name:
  321. .. rst-class:: classref-method
  322. :ref:`String<class_String>` **get_bone_name**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_name>`
  323. Returns the name of the bone at index ``bone_idx``.
  324. .. rst-class:: classref-item-separator
  325. ----
  326. .. _class_Skeleton3D_method_get_bone_parent:
  327. .. rst-class:: classref-method
  328. :ref:`int<class_int>` **get_bone_parent**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_parent>`
  329. Returns the bone index which is the parent of the bone at ``bone_idx``. If -1, then bone has no parent.
  330. \ **Note:** The parent bone returned will always be less than ``bone_idx``.
  331. .. rst-class:: classref-item-separator
  332. ----
  333. .. _class_Skeleton3D_method_get_bone_pose:
  334. .. rst-class:: classref-method
  335. :ref:`Transform3D<class_Transform3D>` **get_bone_pose**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_pose>`
  336. Returns the pose transform of the specified bone.
  337. \ **Note:** This is the pose you set to the skeleton in the process, the final pose can get overridden by modifiers in the deferred process, if you want to access the final pose, use :ref:`SkeletonModifier3D.modification_processed<class_SkeletonModifier3D_signal_modification_processed>`.
  338. .. rst-class:: classref-item-separator
  339. ----
  340. .. _class_Skeleton3D_method_get_bone_pose_position:
  341. .. rst-class:: classref-method
  342. :ref:`Vector3<class_Vector3>` **get_bone_pose_position**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_pose_position>`
  343. Returns the pose position of the bone at ``bone_idx``. The returned :ref:`Vector3<class_Vector3>` is in the local coordinate space of the **Skeleton3D** node.
  344. .. rst-class:: classref-item-separator
  345. ----
  346. .. _class_Skeleton3D_method_get_bone_pose_rotation:
  347. .. rst-class:: classref-method
  348. :ref:`Quaternion<class_Quaternion>` **get_bone_pose_rotation**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_pose_rotation>`
  349. Returns the pose rotation of the bone at ``bone_idx``. The returned :ref:`Quaternion<class_Quaternion>` is local to the bone with respect to the rotation of any parent bones.
  350. .. rst-class:: classref-item-separator
  351. ----
  352. .. _class_Skeleton3D_method_get_bone_pose_scale:
  353. .. rst-class:: classref-method
  354. :ref:`Vector3<class_Vector3>` **get_bone_pose_scale**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_pose_scale>`
  355. Returns the pose scale of the bone at ``bone_idx``.
  356. .. rst-class:: classref-item-separator
  357. ----
  358. .. _class_Skeleton3D_method_get_bone_rest:
  359. .. rst-class:: classref-method
  360. :ref:`Transform3D<class_Transform3D>` **get_bone_rest**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_bone_rest>`
  361. Returns the rest transform for a bone ``bone_idx``.
  362. .. rst-class:: classref-item-separator
  363. ----
  364. .. _class_Skeleton3D_method_get_concatenated_bone_names:
  365. .. rst-class:: classref-method
  366. :ref:`StringName<class_StringName>` **get_concatenated_bone_names**\ (\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_concatenated_bone_names>`
  367. Returns all bone names concatenated with commas (``,``) as a single :ref:`StringName<class_StringName>`.
  368. It is useful to set it as a hint for the enum property.
  369. .. rst-class:: classref-item-separator
  370. ----
  371. .. _class_Skeleton3D_method_get_parentless_bones:
  372. .. rst-class:: classref-method
  373. :ref:`PackedInt32Array<class_PackedInt32Array>` **get_parentless_bones**\ (\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_parentless_bones>`
  374. Returns an array with all of the bones that are parentless. Another way to look at this is that it returns the indexes of all the bones that are not dependent or modified by other bones in the Skeleton.
  375. .. rst-class:: classref-item-separator
  376. ----
  377. .. _class_Skeleton3D_method_get_version:
  378. .. rst-class:: classref-method
  379. :ref:`int<class_int>` **get_version**\ (\ ) |const| :ref:`🔗<class_Skeleton3D_method_get_version>`
  380. Returns the number of times the bone hierarchy has changed within this skeleton, including renames.
  381. The Skeleton version is not serialized: only use within a single instance of Skeleton3D.
  382. Use for invalidating caches in IK solvers and other nodes which process bones.
  383. .. rst-class:: classref-item-separator
  384. ----
  385. .. _class_Skeleton3D_method_is_bone_enabled:
  386. .. rst-class:: classref-method
  387. :ref:`bool<class_bool>` **is_bone_enabled**\ (\ bone_idx\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_Skeleton3D_method_is_bone_enabled>`
  388. Returns whether the bone pose for the bone at ``bone_idx`` is enabled.
  389. .. rst-class:: classref-item-separator
  390. ----
  391. .. _class_Skeleton3D_method_localize_rests:
  392. .. rst-class:: classref-method
  393. |void| **localize_rests**\ (\ ) :ref:`🔗<class_Skeleton3D_method_localize_rests>`
  394. Returns all bones in the skeleton to their rest poses.
  395. .. rst-class:: classref-item-separator
  396. ----
  397. .. _class_Skeleton3D_method_physical_bones_add_collision_exception:
  398. .. rst-class:: classref-method
  399. |void| **physical_bones_add_collision_exception**\ (\ exception\: :ref:`RID<class_RID>`\ ) :ref:`🔗<class_Skeleton3D_method_physical_bones_add_collision_exception>`
  400. **Deprecated:** This method may be changed or removed in future versions.
  401. Adds a collision exception to the physical bone.
  402. Works just like the :ref:`RigidBody3D<class_RigidBody3D>` node.
  403. .. rst-class:: classref-item-separator
  404. ----
  405. .. _class_Skeleton3D_method_physical_bones_remove_collision_exception:
  406. .. rst-class:: classref-method
  407. |void| **physical_bones_remove_collision_exception**\ (\ exception\: :ref:`RID<class_RID>`\ ) :ref:`🔗<class_Skeleton3D_method_physical_bones_remove_collision_exception>`
  408. **Deprecated:** This method may be changed or removed in future versions.
  409. Removes a collision exception to the physical bone.
  410. Works just like the :ref:`RigidBody3D<class_RigidBody3D>` node.
  411. .. rst-class:: classref-item-separator
  412. ----
  413. .. _class_Skeleton3D_method_physical_bones_start_simulation:
  414. .. rst-class:: classref-method
  415. |void| **physical_bones_start_simulation**\ (\ bones\: :ref:`Array<class_Array>`\[:ref:`StringName<class_StringName>`\] = []\ ) :ref:`🔗<class_Skeleton3D_method_physical_bones_start_simulation>`
  416. **Deprecated:** This method may be changed or removed in future versions.
  417. Tells the :ref:`PhysicalBone3D<class_PhysicalBone3D>` nodes in the Skeleton to start simulating and reacting to the physics world.
  418. Optionally, a list of bone names can be passed-in, allowing only the passed-in bones to be simulated.
  419. .. rst-class:: classref-item-separator
  420. ----
  421. .. _class_Skeleton3D_method_physical_bones_stop_simulation:
  422. .. rst-class:: classref-method
  423. |void| **physical_bones_stop_simulation**\ (\ ) :ref:`🔗<class_Skeleton3D_method_physical_bones_stop_simulation>`
  424. **Deprecated:** This method may be changed or removed in future versions.
  425. Tells the :ref:`PhysicalBone3D<class_PhysicalBone3D>` nodes in the Skeleton to stop simulating.
  426. .. rst-class:: classref-item-separator
  427. ----
  428. .. _class_Skeleton3D_method_register_skin:
  429. .. rst-class:: classref-method
  430. :ref:`SkinReference<class_SkinReference>` **register_skin**\ (\ skin\: :ref:`Skin<class_Skin>`\ ) :ref:`🔗<class_Skeleton3D_method_register_skin>`
  431. Binds the given Skin to the Skeleton.
  432. .. rst-class:: classref-item-separator
  433. ----
  434. .. _class_Skeleton3D_method_reset_bone_pose:
  435. .. rst-class:: classref-method
  436. |void| **reset_bone_pose**\ (\ bone_idx\: :ref:`int<class_int>`\ ) :ref:`🔗<class_Skeleton3D_method_reset_bone_pose>`
  437. Sets the bone pose to rest for ``bone_idx``.
  438. .. rst-class:: classref-item-separator
  439. ----
  440. .. _class_Skeleton3D_method_reset_bone_poses:
  441. .. rst-class:: classref-method
  442. |void| **reset_bone_poses**\ (\ ) :ref:`🔗<class_Skeleton3D_method_reset_bone_poses>`
  443. Sets all bone poses to rests.
  444. .. rst-class:: classref-item-separator
  445. ----
  446. .. _class_Skeleton3D_method_set_bone_enabled:
  447. .. rst-class:: classref-method
  448. |void| **set_bone_enabled**\ (\ bone_idx\: :ref:`int<class_int>`, enabled\: :ref:`bool<class_bool>` = true\ ) :ref:`🔗<class_Skeleton3D_method_set_bone_enabled>`
  449. Disables the pose for the bone at ``bone_idx`` if ``false``, enables the bone pose if ``true``.
  450. .. rst-class:: classref-item-separator
  451. ----
  452. .. _class_Skeleton3D_method_set_bone_global_pose:
  453. .. rst-class:: classref-method
  454. |void| **set_bone_global_pose**\ (\ bone_idx\: :ref:`int<class_int>`, pose\: :ref:`Transform3D<class_Transform3D>`\ ) :ref:`🔗<class_Skeleton3D_method_set_bone_global_pose>`
  455. Sets the global pose transform, ``pose``, for the bone at ``bone_idx``.
  456. \ **Note:** If other bone poses have been changed, this method executes a dirty poses recalculation and will cause performance to deteriorate. If you know that multiple global poses will be applied, consider using :ref:`set_bone_pose<class_Skeleton3D_method_set_bone_pose>` with precalculation.
  457. .. rst-class:: classref-item-separator
  458. ----
  459. .. _class_Skeleton3D_method_set_bone_global_pose_override:
  460. .. rst-class:: classref-method
  461. |void| **set_bone_global_pose_override**\ (\ bone_idx\: :ref:`int<class_int>`, pose\: :ref:`Transform3D<class_Transform3D>`, amount\: :ref:`float<class_float>`, persistent\: :ref:`bool<class_bool>` = false\ ) :ref:`🔗<class_Skeleton3D_method_set_bone_global_pose_override>`
  462. **Deprecated:** This method may be changed or removed in future versions.
  463. Sets the global pose transform, ``pose``, for the bone at ``bone_idx``.
  464. \ ``amount`` is the interpolation strength that will be used when applying the pose, and ``persistent`` determines if the applied pose will remain.
  465. \ **Note:** The pose transform needs to be a global pose! To convert a world transform from a :ref:`Node3D<class_Node3D>` to a global bone pose, multiply the :ref:`Transform3D.affine_inverse<class_Transform3D_method_affine_inverse>` of the node's :ref:`Node3D.global_transform<class_Node3D_property_global_transform>` by the desired world transform.
  466. .. rst-class:: classref-item-separator
  467. ----
  468. .. _class_Skeleton3D_method_set_bone_name:
  469. .. rst-class:: classref-method
  470. |void| **set_bone_name**\ (\ bone_idx\: :ref:`int<class_int>`, name\: :ref:`String<class_String>`\ ) :ref:`🔗<class_Skeleton3D_method_set_bone_name>`
  471. Sets the bone name, ``name``, for the bone at ``bone_idx``.
  472. .. rst-class:: classref-item-separator
  473. ----
  474. .. _class_Skeleton3D_method_set_bone_parent:
  475. .. rst-class:: classref-method
  476. |void| **set_bone_parent**\ (\ bone_idx\: :ref:`int<class_int>`, parent_idx\: :ref:`int<class_int>`\ ) :ref:`🔗<class_Skeleton3D_method_set_bone_parent>`
  477. Sets the bone index ``parent_idx`` as the parent of the bone at ``bone_idx``. If -1, then bone has no parent.
  478. \ **Note:** ``parent_idx`` must be less than ``bone_idx``.
  479. .. rst-class:: classref-item-separator
  480. ----
  481. .. _class_Skeleton3D_method_set_bone_pose:
  482. .. rst-class:: classref-method
  483. |void| **set_bone_pose**\ (\ bone_idx\: :ref:`int<class_int>`, pose\: :ref:`Transform3D<class_Transform3D>`\ ) :ref:`🔗<class_Skeleton3D_method_set_bone_pose>`
  484. Sets the pose transform, ``pose``, for the bone at ``bone_idx``.
  485. .. rst-class:: classref-item-separator
  486. ----
  487. .. _class_Skeleton3D_method_set_bone_pose_position:
  488. .. rst-class:: classref-method
  489. |void| **set_bone_pose_position**\ (\ bone_idx\: :ref:`int<class_int>`, position\: :ref:`Vector3<class_Vector3>`\ ) :ref:`🔗<class_Skeleton3D_method_set_bone_pose_position>`
  490. Sets the pose position of the bone at ``bone_idx`` to ``position``. ``position`` is a :ref:`Vector3<class_Vector3>` describing a position local to the **Skeleton3D** node.
  491. .. rst-class:: classref-item-separator
  492. ----
  493. .. _class_Skeleton3D_method_set_bone_pose_rotation:
  494. .. rst-class:: classref-method
  495. |void| **set_bone_pose_rotation**\ (\ bone_idx\: :ref:`int<class_int>`, rotation\: :ref:`Quaternion<class_Quaternion>`\ ) :ref:`🔗<class_Skeleton3D_method_set_bone_pose_rotation>`
  496. Sets the pose rotation of the bone at ``bone_idx`` to ``rotation``. ``rotation`` is a :ref:`Quaternion<class_Quaternion>` describing a rotation in the bone's local coordinate space with respect to the rotation of any parent bones.
  497. .. rst-class:: classref-item-separator
  498. ----
  499. .. _class_Skeleton3D_method_set_bone_pose_scale:
  500. .. rst-class:: classref-method
  501. |void| **set_bone_pose_scale**\ (\ bone_idx\: :ref:`int<class_int>`, scale\: :ref:`Vector3<class_Vector3>`\ ) :ref:`🔗<class_Skeleton3D_method_set_bone_pose_scale>`
  502. Sets the pose scale of the bone at ``bone_idx`` to ``scale``.
  503. .. rst-class:: classref-item-separator
  504. ----
  505. .. _class_Skeleton3D_method_set_bone_rest:
  506. .. rst-class:: classref-method
  507. |void| **set_bone_rest**\ (\ bone_idx\: :ref:`int<class_int>`, rest\: :ref:`Transform3D<class_Transform3D>`\ ) :ref:`🔗<class_Skeleton3D_method_set_bone_rest>`
  508. Sets the rest transform for bone ``bone_idx``.
  509. .. rst-class:: classref-item-separator
  510. ----
  511. .. _class_Skeleton3D_method_unparent_bone_and_rest:
  512. .. rst-class:: classref-method
  513. |void| **unparent_bone_and_rest**\ (\ bone_idx\: :ref:`int<class_int>`\ ) :ref:`🔗<class_Skeleton3D_method_unparent_bone_and_rest>`
  514. Unparents the bone at ``bone_idx`` and sets its rest position to that of its parent prior to being reset.
  515. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  516. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  517. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  518. .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
  519. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
  520. .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`
  521. .. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)`
  522. .. |void| replace:: :abbr:`void (No return value.)`