summaryrefslogtreecommitdiff
path: root/doc/classes/Tween.xml
diff options
context:
space:
mode:
authorDavid Sichma <david.sichma@student.kit.edu>2021-10-29 17:29:28 +0200
committerDavid Sichma <david.sichma@student.kit.edu>2021-10-29 17:29:28 +0200
commitb9c7c52a29d40d21afceed57e735242abe7ffbca (patch)
tree766a7e9febe855be23f315fdf1db87a30e134441 /doc/classes/Tween.xml
parent8c162f4a7ba0f542cd7e9fbbe30f004504cc0809 (diff)
Fixed Tween::interpolate_value argument order.
Diffstat (limited to 'doc/classes/Tween.xml')
-rw-r--r--doc/classes/Tween.xml12
1 files changed, 6 insertions, 6 deletions
diff --git a/doc/classes/Tween.xml b/doc/classes/Tween.xml
index 488a5aa340..05c83f0423 100644
--- a/doc/classes/Tween.xml
+++ b/doc/classes/Tween.xml
@@ -74,17 +74,17 @@
</method>
<method name="interpolate_value">
<return type="Variant" />
- <argument index="0" name="trans_type" type="Variant" />
- <argument index="1" name="ease_type" type="Variant" />
+ <argument index="0" name="initial_value" type="Variant" />
+ <argument index="1" name="delta_value" type="Variant" />
<argument index="2" name="elapsed_time" type="float" />
- <argument index="3" name="initial_value" type="float" />
- <argument index="4" name="delta_value" type="int" enum="Tween.TransitionType" />
- <argument index="5" name="duration" type="int" enum="Tween.EaseType" />
+ <argument index="3" name="duration" type="float" />
+ <argument index="4" name="trans_type" type="int" enum="Tween.TransitionType" />
+ <argument index="5" name="ease_type" type="int" enum="Tween.EaseType" />
<description>
This method can be used for manual interpolation of a value, when you don't want [Tween] to do animating for you. It's similar to [method @GlobalScope.lerp], but with support for custom transition and easing.
- [code]elapsed_time[/code] is the time in seconds that passed after the interping started and it's used to control the position of the interpolation. E.g. when it's equal to half of the [code]duration[/code], the interpolated value will be halfway between initial and final values. This value can also be greater than [code]duration[/code] or lower than 0, which will extrapolate the value.
[code]initial_value[/code] is the starting value of the interpolation.
[code]delta_value[/code] is the change of the value in the interpolation, i.e. it's equal to [code]final_value - initial_value[/code].
+ [code]elapsed_time[/code] is the time in seconds that passed after the interpolation started and it's used to control the position of the interpolation. E.g. when it's equal to half of the [code]duration[/code], the interpolated value will be halfway between initial and final values. This value can also be greater than [code]duration[/code] or lower than 0, which will extrapolate the value.
[code]duration[/code] is the total time of the interpolation.
[b]Note:[/b] If [code]duration[/code] is equal to [code]0[/code], the method will always return the final value, regardless of [code]elapsed_time[/code] provided.
</description>