summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2024-09-04 18:55:24 +0200
committerRémi Verschelde <rverschelde@gmail.com>2024-09-04 18:55:24 +0200
commita1012058dd8cf9da42c36a75232e54f738f51314 (patch)
tree4604a04835808398cc9d2d2425e57ce555f6e10a /doc
parentdb6af2ecc697be74cab63f3715f4119ab3d6eabd (diff)
parentea9dff87ae29ea34cff8d0452c2ea799c16b2d0c (diff)
downloadredot-engine-a1012058dd8cf9da42c36a75232e54f738f51314.tar.gz
Merge pull request #94886 from gturri/dev
Add error checks for bad configuration in `PathFollow2D/3D` `set_progress_ratio`
Diffstat (limited to 'doc')
-rw-r--r--doc/classes/PathFollow2D.xml1
-rw-r--r--doc/classes/PathFollow3D.xml1
2 files changed, 2 insertions, 0 deletions
diff --git a/doc/classes/PathFollow2D.xml b/doc/classes/PathFollow2D.xml
index 61db34fb02..7444bfc23a 100644
--- a/doc/classes/PathFollow2D.xml
+++ b/doc/classes/PathFollow2D.xml
@@ -26,6 +26,7 @@
</member>
<member name="progress_ratio" type="float" setter="set_progress_ratio" getter="get_progress_ratio" default="0.0">
The distance along the path as a number in the range 0.0 (for the first vertex) to 1.0 (for the last). This is just another way of expressing the progress within the path, as the offset supplied is multiplied internally by the path's length.
+ It can be set or get only if the [PathFollow2D] is the child of a [Path2D] which is part of the scene tree, and that this [Path2D] has a [Curve2D] with a non-zero length. Otherwise, trying to set this field will print an error, and getting this field will return [code]0.0[/code].
</member>
<member name="rotates" type="bool" setter="set_rotates" getter="is_rotating" default="true">
If [code]true[/code], this node rotates to follow the path, with the +X direction facing forward on the path.
diff --git a/doc/classes/PathFollow3D.xml b/doc/classes/PathFollow3D.xml
index b505c6ea8b..bcd04d51ca 100644
--- a/doc/classes/PathFollow3D.xml
+++ b/doc/classes/PathFollow3D.xml
@@ -36,6 +36,7 @@
</member>
<member name="progress_ratio" type="float" setter="set_progress_ratio" getter="get_progress_ratio" default="0.0">
The distance from the first vertex, considering 0.0 as the first vertex and 1.0 as the last. This is just another way of expressing the progress within the path, as the progress supplied is multiplied internally by the path's length.
+ It can be set or get only if the [PathFollow3D] is the child of a [Path3D] which is part of the scene tree, and that this [Path3D] has a [Curve3D] with a non-zero length. Otherwise, trying to set this field will print an error, and getting this field will return [code]0.0[/code].
</member>
<member name="rotation_mode" type="int" setter="set_rotation_mode" getter="get_rotation_mode" enum="PathFollow3D.RotationMode" default="3">
Allows or forbids rotation on one or more axes, depending on the [enum RotationMode] constants being used.