A resource that operates on [Bone2D] nodes in a [Skeleton2D].
</brief_description>
<description>
This resource provides an interface that can be expanded so code that operates on [Bone2D] nodes in a [Skeleton2D] can be mixed and matched together to create complex interactions.
This is used to provide Godot with a flexible and powerful Inverse Kinematics solution that can be adapted for many different uses.
Used for drawing [b]editor-only[/b] modification gizmos. This function will only be called in the Godot editor and can be overridden to draw custom gizmos.
[b]Note:[/b] You will need to use the Skeleton2D from [method SkeletonModificationStack2D.get_skeleton] and it's draw functions, as the [SkeletonModification2D] resource cannot draw on its own.
</description>
</method>
<methodname="_execute"qualifiers="virtual">
<returntype="void">
</return>
<argumentindex="0"name="delta"type="float">
</argument>
<description>
Executes the given modification. This is where the modification performs whatever function it is designed to do.
Called when the modification is setup. This is where the modification performs initialization.
</description>
</method>
<methodname="clamp_angle">
<returntype="float">
</return>
<argumentindex="0"name="angle"type="float">
</argument>
<argumentindex="1"name="min"type="float">
</argument>
<argumentindex="2"name="max"type="float">
</argument>
<argumentindex="3"name="invert"type="bool">
</argument>
<description>
Takes a angle and clamps it so it is within the passed-in [code]min[/code] and [code]max[/code] range. [code]invert[/code] will inversely clamp the angle, clamping it to the range outside of the given bounds.
Returns whether this modification will call [method _draw_editor_gizmo] in the Godot editor to draw modification-specific gizmos.
</description>
</method>
<methodname="get_is_setup"qualifiers="const">
<returntype="bool">
</return>
<description>
Returns whether this modification has been successfully setup or not.
</description>
</method>
<methodname="get_modification_stack">
<returntype="SkeletonModificationStack2D">
</return>
<description>
Returns the [SkeletonModificationStack2D] that this modification is bound to. Through the modification stack, you can access the Skeleton3D the modification is operating on.
</description>
</method>
<methodname="set_editor_draw_gizmo">
<returntype="void">
</return>
<argumentindex="0"name="draw_gizmo"type="bool">
</argument>
<description>
Sets whether this modification will call [method _draw_editor_gizmo] in the Godot editor to draw modification-specific gizmos.
</description>
</method>
<methodname="set_is_setup">
<returntype="void">
</return>
<argumentindex="0"name="is_setup"type="bool">
</argument>
<description>
Manually allows you to set the setup state of the modification. This function should only rarely be used, as the [SkeletonModificationStack2D] the modification is bound to should handle setting the modification up.
The execution mode for the modification. This tells the modification stack when to execute the modification. Some modifications have settings that are only available in certain execution modes.