summaryrefslogtreecommitdiff
path: root/doc/classes/Animation.xml
diff options
context:
space:
mode:
Diffstat (limited to 'doc/classes/Animation.xml')
-rw-r--r--doc/classes/Animation.xml113
1 files changed, 55 insertions, 58 deletions
diff --git a/doc/classes/Animation.xml b/doc/classes/Animation.xml
index d853345268..ea503f8aa9 100644
--- a/doc/classes/Animation.xml
+++ b/doc/classes/Animation.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="Animation" inherits="Resource" category="Core" version="3.0.alpha.custom_build">
+<class name="Animation" inherits="Resource" category="Core" version="3.1">
<brief_description>
Contains data used to animate everything in the engine.
</brief_description>
@@ -8,6 +8,7 @@
Animations are just data containers, and must be added to odes such as an [AnimationPlayer] or [AnimationTreePlayer] to be played back.
</description>
<tutorials>
+ http://docs.godotengine.org/en/3.0/tutorials/animation/index.html
</tutorials>
<demos>
</demos>
@@ -30,27 +31,24 @@
Clear the animation (clear all tracks and reset all).
</description>
</method>
- <method name="find_track" qualifiers="const">
- <return type="int">
+ <method name="copy_track">
+ <return type="void">
</return>
- <argument index="0" name="path" type="NodePath">
+ <argument index="0" name="track" type="int">
+ </argument>
+ <argument index="1" name="to_animation" type="Animation">
</argument>
<description>
- Return the index of the specified track. If the track is not found, return -1.
- </description>
- </method>
- <method name="get_length" qualifiers="const">
- <return type="float">
- </return>
- <description>
- Return the total length of the animation (in seconds).
+ Adds a new track that is a copy of the given track from [code]to_animation[/code].
</description>
</method>
- <method name="get_step" qualifiers="const">
- <return type="float">
+ <method name="find_track" qualifiers="const">
+ <return type="int">
</return>
+ <argument index="0" name="path" type="NodePath">
+ </argument>
<description>
- Get the animation step value.
+ Return the index of the specified track. If the track is not found, return -1.
</description>
</method>
<method name="get_track_count" qualifiers="const">
@@ -60,13 +58,6 @@
Return the amount of tracks in the animation.
</description>
</method>
- <method name="has_loop" qualifiers="const">
- <return type="bool">
- </return>
- <description>
- Return whether the animation has the loop flag set.
- </description>
- </method>
<method name="method_track_get_key_indices" qualifiers="const">
<return type="PoolIntArray">
</return>
@@ -111,33 +102,6 @@
Remove a track by specifying the track index.
</description>
</method>
- <method name="set_length">
- <return type="void">
- </return>
- <argument index="0" name="time_sec" type="float">
- </argument>
- <description>
- Set the total length of the animation (in seconds). Note that length is not delimited by the last key, as this one may be before or after the end to ensure correct interpolation and looping.
- </description>
- </method>
- <method name="set_loop">
- <return type="void">
- </return>
- <argument index="0" name="enabled" type="bool">
- </argument>
- <description>
- Set a flag indicating that the animation must loop. This is uses for correct interpolation of animation cycles, and for hinting the player that it must restart the animation.
- </description>
- </method>
- <method name="set_step">
- <return type="void">
- </return>
- <argument index="0" name="size_sec" type="float">
- </argument>
- <description>
- Set the animation step value.
- </description>
- </method>
<method name="track_find_key" qualifiers="const">
<return type="int">
</return>
@@ -157,6 +121,7 @@
<argument index="0" name="idx" type="int">
</argument>
<description>
+ Returns [code]true[/code] if the track at [code]idx[/code] wraps the interpolation loop. Default value: [code]true[/code].
</description>
</method>
<method name="track_get_interpolation_type" qualifiers="const">
@@ -243,6 +208,15 @@
Insert a generic key in a given track.
</description>
</method>
+ <method name="track_is_enabled" qualifiers="const">
+ <return type="bool">
+ </return>
+ <argument index="0" name="idx" type="int">
+ </argument>
+ <description>
+ Returns [code]true[/code] if the track at index [code]idx[/code] is enabled.
+ </description>
+ </method>
<method name="track_is_imported" qualifiers="const">
<return type="bool">
</return>
@@ -292,6 +266,17 @@
Remove a key by position (seconds) in a given track.
</description>
</method>
+ <method name="track_set_enabled">
+ <return type="void">
+ </return>
+ <argument index="0" name="idx" type="int">
+ </argument>
+ <argument index="1" name="enabled" type="bool">
+ </argument>
+ <description>
+ Enables/disables the given track. Tracks are enabled by default.
+ </description>
+ </method>
<method name="track_set_imported">
<return type="void">
</return>
@@ -311,6 +296,7 @@
<argument index="1" name="interpolation" type="bool">
</argument>
<description>
+ If [code]true[/code] the track at [code]idx[/code] wraps the interpolation loop.
</description>
</method>
<method name="track_set_interpolation_type">
@@ -423,32 +409,43 @@
</description>
</method>
</methods>
+ <members>
+ <member name="length" type="float" setter="set_length" getter="get_length">
+ The total length of the animation (in seconds). Note that length is not delimited by the last key, as this one may be before or after the end to ensure correct interpolation and looping.
+ </member>
+ <member name="loop" type="bool" setter="set_loop" getter="has_loop">
+ A flag indicating that the animation must loop. This is uses for correct interpolation of animation cycles, and for hinting the player that it must restart the animation.
+ </member>
+ <member name="step" type="float" setter="set_step" getter="get_step">
+ The animation step value.
+ </member>
+ </members>
<constants>
- <constant name="TYPE_VALUE" value="0">
+ <constant name="TYPE_VALUE" value="0" enum="TrackType">
Value tracks set values in node properties, but only those which can be Interpolated.
</constant>
- <constant name="TYPE_TRANSFORM" value="1">
+ <constant name="TYPE_TRANSFORM" value="1" enum="TrackType">
Transform tracks are used to change node local transforms or skeleton pose bones. Transitions are Interpolated.
</constant>
- <constant name="TYPE_METHOD" value="2">
+ <constant name="TYPE_METHOD" value="2" enum="TrackType">
Method tracks call functions with given arguments per key.
</constant>
- <constant name="INTERPOLATION_NEAREST" value="0">
+ <constant name="INTERPOLATION_NEAREST" value="0" enum="InterpolationType">
No interpolation (nearest value).
</constant>
- <constant name="INTERPOLATION_LINEAR" value="1">
+ <constant name="INTERPOLATION_LINEAR" value="1" enum="InterpolationType">
Linear interpolation.
</constant>
- <constant name="INTERPOLATION_CUBIC" value="2">
+ <constant name="INTERPOLATION_CUBIC" value="2" enum="InterpolationType">
Cubic interpolation.
</constant>
- <constant name="UPDATE_CONTINUOUS" value="0">
+ <constant name="UPDATE_CONTINUOUS" value="0" enum="UpdateMode">
Update between keyframes.
</constant>
- <constant name="UPDATE_DISCRETE" value="1">
+ <constant name="UPDATE_DISCRETE" value="1" enum="UpdateMode">
Update at the keyframes and hold the value.
</constant>
- <constant name="UPDATE_TRIGGER" value="2">
+ <constant name="UPDATE_TRIGGER" value="2" enum="UpdateMode">
Update at the keyframes.
</constant>
</constants>