summaryrefslogtreecommitdiffstats
path: root/doc/classes
diff options
context:
space:
mode:
authorHugo Locurcio <hugo.locurcio@hugo.pro>2022-07-12 19:26:10 +0200
committerHugo Locurcio <hugo.locurcio@hugo.pro>2023-06-15 07:50:54 +0200
commit84a3fd9daa8893661867dade7003c761ab188977 (patch)
tree8f24e19f63d02e9be00eec96093964c83b9c6d6f /doc/classes
parent33957aee69683cf1f542a8622e5a9efd23070f1c (diff)
downloadredot-engine-84a3fd9daa8893661867dade7003c761ab188977.tar.gz
Document initializing PackedVectorArray/PackedColorArray correctly
Diffstat (limited to 'doc/classes')
-rw-r--r--doc/classes/PackedColorArray.xml4
-rw-r--r--doc/classes/PackedVector2Array.xml4
-rw-r--r--doc/classes/PackedVector3Array.xml4
3 files changed, 12 insertions, 0 deletions
diff --git a/doc/classes/PackedColorArray.xml b/doc/classes/PackedColorArray.xml
index 663050e567..eb5a0edfd6 100644
--- a/doc/classes/PackedColorArray.xml
+++ b/doc/classes/PackedColorArray.xml
@@ -27,6 +27,10 @@
<param index="0" name="from" type="Array" />
<description>
Constructs a new [PackedColorArray]. Optionally, you can pass in a generic [Array] that will be converted.
+ [b]Note:[/b] When initializing a [PackedColorArray] with elements, it must be initialized with an [Array] of [Color] values:
+ [codeblock]
+ var array = PackedColorArray([Color(0.1, 0.2, 0.3), Color(0.4, 0.5, 0.6)])
+ [/codeblock]
</description>
</constructor>
</constructors>
diff --git a/doc/classes/PackedVector2Array.xml b/doc/classes/PackedVector2Array.xml
index 0f74e0d2e5..a5a5d2f2df 100644
--- a/doc/classes/PackedVector2Array.xml
+++ b/doc/classes/PackedVector2Array.xml
@@ -28,6 +28,10 @@
<param index="0" name="from" type="Array" />
<description>
Constructs a new [PackedVector2Array]. Optionally, you can pass in a generic [Array] that will be converted.
+ [b]Note:[/b] When initializing a [PackedVector2Array] with elements, it must be initialized with an [Array] of [Vector2] values:
+ [codeblock]
+ var array = PackedVector2Array([Vector2(12, 34), Vector2(56, 78)])
+ [/codeblock]
</description>
</constructor>
</constructors>
diff --git a/doc/classes/PackedVector3Array.xml b/doc/classes/PackedVector3Array.xml
index 9d0fdaa717..2557549703 100644
--- a/doc/classes/PackedVector3Array.xml
+++ b/doc/classes/PackedVector3Array.xml
@@ -27,6 +27,10 @@
<param index="0" name="from" type="Array" />
<description>
Constructs a new [PackedVector3Array]. Optionally, you can pass in a generic [Array] that will be converted.
+ [b]Note:[/b] When initializing a [PackedVector3Array] with elements, it must be initialized with an [Array] of [Vector3] values:
+ [codeblock]
+ var array = PackedVector3Array([Vector3(12, 34, 56), Vector3(78, 90, 12)])
+ [/codeblock]
</description>
</constructor>
</constructors>