Skip to content

Latest commit

 

History

History
68 lines (41 loc) · 2.55 KB

class_skeleton2d.rst

File metadata and controls

68 lines (41 loc) · 2.55 KB
github_url:hide

Skeleton2D

Inherits: :ref:`Node2D<class_Node2D>` < :ref:`CanvasItem<class_CanvasItem>` < :ref:`Node<class_Node>` < :ref:`Object<class_Object>`

Skeleton for 2D characters and animated objects.

Description

Skeleton2D parents a hierarchy of :ref:`Bone2D<class_Bone2D>` objects. It is a requirement of :ref:`Bone2D<class_Bone2D>`. Skeleton2D holds a reference to the rest pose of its children and acts as a single point of access to its bones.

Tutorials

Methods

:ref:`Bone2D<class_Bone2D>` :ref:`get_bone<class_Skeleton2D_method_get_bone>` ( :ref:`int<class_int>` idx )
:ref:`int<class_int>` :ref:`get_bone_count<class_Skeleton2D_method_get_bone_count>` ( ) const
:ref:`RID<class_RID>` :ref:`get_skeleton<class_Skeleton2D_method_get_skeleton>` ( ) const

Signals

  • bone_setup_changed ( )

Method Descriptions

Returns a :ref:`Bone2D<class_Bone2D>` from the node hierarchy parented by Skeleton2D. The object to return is identified by the parameter idx. Bones are indexed by descending the node hierarchy from top to bottom, adding the children of each branch before moving to the next sibling.


Returns the number of :ref:`Bone2D<class_Bone2D>` nodes in the node hierarchy parented by Skeleton2D.


Returns the :ref:`RID<class_RID>` of a Skeleton2D instance.