mirror of
https://github.com/godotengine/godot.git
synced 2024-12-21 10:25:24 +08:00
65 lines
2.9 KiB
XML
65 lines
2.9 KiB
XML
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<class name="SkeletonModification3DLookAt" inherits="SkeletonModification3D" version="4.0">
|
|
<brief_description>
|
|
A modification that rotates a bone to look at a target.
|
|
</brief_description>
|
|
<description>
|
|
This [SkeletonModification3D] rotates a bone to look a target. This is extremely helpful for moving character's heads to look at the player, rotating a turret to look at a target, or any other case where you want to make a bone rotate towards something quickly and easily.
|
|
</description>
|
|
<tutorials>
|
|
</tutorials>
|
|
<methods>
|
|
<method name="get_additional_rotation" qualifiers="const">
|
|
<return type="Vector3" />
|
|
<description>
|
|
Returns the amount of extra rotation that is applied to the bone after the LookAt modification executes.
|
|
</description>
|
|
</method>
|
|
<method name="get_lock_rotation_plane" qualifiers="const">
|
|
<return type="int" />
|
|
<description>
|
|
Returns the plane that the LookAt modification is limiting rotation to.
|
|
</description>
|
|
</method>
|
|
<method name="get_lock_rotation_to_plane" qualifiers="const">
|
|
<return type="bool" />
|
|
<description>
|
|
Returns whether the LookAt modification is limiting rotation to a single plane in 3D space.
|
|
</description>
|
|
</method>
|
|
<method name="set_additional_rotation">
|
|
<return type="void" />
|
|
<argument index="0" name="additional_rotation" type="Vector3" />
|
|
<description>
|
|
Sets the amount of extra rotation to be applied after the LookAt modification executes. This allows you to adjust the finished result.
|
|
</description>
|
|
</method>
|
|
<method name="set_lock_rotation_plane">
|
|
<return type="void" />
|
|
<argument index="0" name="plane" type="int" />
|
|
<description>
|
|
</description>
|
|
</method>
|
|
<method name="set_lock_rotation_to_plane">
|
|
<return type="void" />
|
|
<argument index="0" name="lock_to_plane" type="bool" />
|
|
<description>
|
|
When [code]true[/code], the LookAt modification will limit its rotation to a single plane in 3D space. The plane used can be configured using the [code]set_lock_rotation_plane[/code] function.
|
|
</description>
|
|
</method>
|
|
</methods>
|
|
<members>
|
|
<member name="bone_index" type="int" setter="set_bone_index" getter="get_bone_index" default="-2">
|
|
The bone index of the bone that should be operated on by this modification.
|
|
When possible, this will also update the [member bone_name] based on data provided by the [Skeleton3D].
|
|
</member>
|
|
<member name="bone_name" type="String" setter="set_bone_name" getter="get_bone_name" default="""">
|
|
The name of the bone that should be operated on by this modification.
|
|
When possible, this will also update the [member bone_index] based on data provided by the [Skeleton3D].
|
|
</member>
|
|
<member name="target_nodepath" type="NodePath" setter="set_target_node" getter="get_target_node" default="NodePath("")">
|
|
The NodePath to the node that is the target for the modification.
|
|
</member>
|
|
</members>
|
|
</class>
|