A [SkeletonModifier3D] to apply inertial wavering to bone chains.
</brief_description>
<description>
This [SkeletonModifier3D] can be used to wiggle hair, cloth, and tails. This modifier behaves differently from [PhysicalBoneSimulator3D] as it attempts to return the original pose after modification.
If you setup [method set_root_bone] and [method set_end_bone], it is treated as one bone chain. Note that it does not support a branched chain like Y-shaped chains.
When a bone chain is created, an array is generated from the bones that exist in between and listed in the joint list.
Several properties can be applied to each joint, such as [method set_joint_stiffness], [method set_joint_drag], and [method set_joint_gravity].
For simplicity, you can set values to all joints at the same time by using a [Curve]. If you want to specify detailed values individually, set [method set_individual_config] to [code]true[/code].
For physical simulation, [SpringBoneSimulator3D] can have children as self-standing collisions that are not related to [PhysicsServer3D], see also [SpringBoneCollision3D].
[b]Warning:[/b] A scaled [SpringBoneSimulator3D] will likely not behave as expected. Make sure that the parent [Skeleton3D] and its bones are not scaled.
Clears all collisions from the collision list at [param index] in the settings when [method are_all_child_collisions_enabled] is [code]false[/code].
</description>
</method>
<methodname="clear_exclude_collisions">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<description>
Clears all exclude collisions from the collision list at [param index] in the settings when [method are_all_child_collisions_enabled] is [code]true[/code].
Returns the node path of the [SpringBoneCollision3D] at [param collision] in the bone chain's collision list when [method are_all_child_collisions_enabled] is [code]false[/code].
</description>
</method>
<methodname="get_drag"qualifiers="const">
<returntype="float"/>
<paramindex="0"name="index"type="int"/>
<description>
Returns the drag force damping curve of the bone chain.
Returns the node path of the [SpringBoneCollision3D] at [param collision] in the bone chain's exclude collision list when [method are_all_child_collisions_enabled] is [code]true[/code].
Returns the rotation axis vector for the specified joint in the bone chain. This vector represents the axis around which the joint can rotate. It is determined based on the rotation axis set for the joint.
If [method get_joint_rotation_axis] is [constant ROTATION_AXIS_ALL], this method returns [code]Vector3(0, 0, 0)[/code].
Returns the rotation axis vector of the bone chain. This vector represents the axis around which the bone chain can rotate. It is determined based on the rotation axis set for the bone chain.
If [method get_rotation_axis] is [constant ROTATION_AXIS_ALL], this method returns [code]Vector3(0, 0, 0)[/code].
Returns [code]true[/code] if the end bone is extended to have the tail.
</description>
</method>
<methodname="reset">
<returntype="void"/>
<description>
Resets a simulating state with respect to the current bone pose.
It is useful to prevent the simulation result getting violent. For example, calling this immediately after a call to [method AnimationPlayer.play] without a fading, or within the previous [signal SkeletonModifier3D.modification_processed] signal if it's condition changes significantly.
Sets what the center originates from in the bone chain.
Bone movement is calculated based on the difference in relative distance between center and bone in the previous and next frames.
For example, if the parent [Skeleton3D] is used as the center, the bones are considered to have not moved if the [Skeleton3D] moves in the world.
In this case, only a change in the bone pose is considered to be a bone movement.
</description>
</method>
<methodname="set_center_node">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="node_path"type="NodePath"/>
<description>
Sets the center node path of the bone chain.
</description>
</method>
<methodname="set_collision_count">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="count"type="int"/>
<description>
Sets the number of collisions in the collision list at [param index] in the settings when [method are_all_child_collisions_enabled] is [code]false[/code].
</description>
</method>
<methodname="set_collision_path">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="collision"type="int"/>
<paramindex="2"name="node_path"type="NodePath"/>
<description>
Sets the node path of the [SpringBoneCollision3D] at [param collision] in the bone chain's collision list when [method are_all_child_collisions_enabled] is [code]false[/code].
</description>
</method>
<methodname="set_drag">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="drag"type="float"/>
<description>
Sets the drag force of the bone chain. The greater the value, the more suppressed the wiggling.
The value is scaled by [method set_drag_damping_curve] and cached in each joint setting in the joint list.
</description>
</method>
<methodname="set_drag_damping_curve">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="curve"type="Curve"/>
<description>
Sets the drag force damping curve of the bone chain.
If [param enabled] is [code]true[/code], all child [SpringBoneCollision3D]s are colliding and [method set_exclude_collision_path] is enabled as an exclusion list at [param index] in the settings.
If [param enabled] is [code]false[/code], you need to manually register all valid collisions with [method set_collision_path].
Sets the end bone tail direction of the bone chain when [method is_end_bone_extended] is [code]true[/code].
</description>
</method>
<methodname="set_end_bone_length">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="length"type="float"/>
<description>
Sets the end bone tail length of the bone chain when [method is_end_bone_extended] is [code]true[/code].
</description>
</method>
<methodname="set_end_bone_name">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="bone_name"type="String"/>
<description>
Sets the end bone name of the bone chain.
[b]Note:[/b] End bone must be the root bone or a child of the root bone. If they are the same, the tail must be extended by [method set_extend_end_bone] to jiggle the bone.
</description>
</method>
<methodname="set_exclude_collision_count">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="count"type="int"/>
<description>
Sets the number of exclude collisions in the exclude collision list at [param index] in the settings when [method are_all_child_collisions_enabled] is [code]true[/code].
</description>
</method>
<methodname="set_exclude_collision_path">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="collision"type="int"/>
<paramindex="2"name="node_path"type="NodePath"/>
<description>
Sets the node path of the [SpringBoneCollision3D] at [param collision] in the bone chain's exclude collision list when [method are_all_child_collisions_enabled] is [code]true[/code].
</description>
</method>
<methodname="set_extend_end_bone">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="enabled"type="bool"/>
<description>
If [param enabled] is [code]true[/code], the end bone is extended to have the tail.
The axes are based on the [method Skeleton3D.get_bone_rest]'s space, if [param axis] is [constant ROTATION_AXIS_CUSTOM], you can specify any axis.
[b]Note:[/b] The rotation axis and the forward vector shouldn't be colinear to avoid unintended rotation since [SpringBoneSimulator3D] does not factor in twisting forces.
</description>
</method>
<methodname="set_joint_rotation_axis_vector">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="joint"type="int"/>
<paramindex="2"name="vector"type="Vector3"/>
<description>
Sets the rotation axis vector for the specified joint in the bone chain.
This vector is normalized by an internal process and represents the axis around which the bone chain can rotate.
If the vector length is [code]0[/code], it is considered synonymous with [constant ROTATION_AXIS_ALL].
Sets the rotation axis of the bone chain. If set to a specific axis, it acts like a hinge joint. The value is cached in each joint setting in the joint list.
The axes are based on the [method Skeleton3D.get_bone_rest]'s space, if [param axis] is [constant ROTATION_AXIS_CUSTOM], you can specify any axis.
[b]Note:[/b] The rotation axis vector and the forward vector shouldn't be colinear to avoid unintended rotation since [SpringBoneSimulator3D] does not factor in twisting forces.
</description>
</method>
<methodname="set_rotation_axis_vector">
<returntype="void"/>
<paramindex="0"name="index"type="int"/>
<paramindex="1"name="vector"type="Vector3"/>
<description>
Sets the rotation axis vector of the bone chain. The value is cached in each joint setting in the joint list.
This vector is normalized by an internal process and represents the axis around which the bone chain can rotate.
If the vector length is [code]0[/code], it is considered synonymous with [constant ROTATION_AXIS_ALL].