diff options
-rw-r--r-- | doc/classes/PackedFloat32Array.xml | 6 | ||||
-rw-r--r-- | doc/classes/PackedFloat64Array.xml | 6 | ||||
-rw-r--r-- | doc/classes/PackedVector2Array.xml | 6 | ||||
-rw-r--r-- | doc/classes/PackedVector3Array.xml | 6 | ||||
-rw-r--r-- | doc/classes/Vector2.xml | 6 | ||||
-rw-r--r-- | doc/classes/Vector3.xml | 6 | ||||
-rw-r--r-- | doc/classes/Vector4.xml | 6 | ||||
-rw-r--r-- | doc/classes/float.xml | 6 | ||||
-rw-r--r-- | modules/gdscript/doc_classes/@GDScript.xml | 2 |
9 files changed, 49 insertions, 1 deletions
diff --git a/doc/classes/PackedFloat32Array.xml b/doc/classes/PackedFloat32Array.xml index 54a483aac9..6e33ad8f73 100644 --- a/doc/classes/PackedFloat32Array.xml +++ b/doc/classes/PackedFloat32Array.xml @@ -53,6 +53,7 @@ <description> Finds the index of an existing value (or the insertion index that maintains sorting order, if the value is not yet present in the array) using binary search. Optionally, a [param before] specifier can be passed. If [code]false[/code], the returned index comes after all existing entries of the value in the array. [b]Note:[/b] Calling [method bsearch] on an unsorted array results in unexpected behavior. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="clear"> @@ -66,6 +67,7 @@ <param index="0" name="value" type="float" /> <description> Returns the number of times an element is in the array. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="duplicate"> @@ -87,6 +89,7 @@ <param index="1" name="from" type="int" default="0" /> <description> Searches the array for a value and returns its index or [code]-1[/code] if not found. Optionally, the initial search index can be passed. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="has" qualifiers="const"> @@ -94,6 +97,7 @@ <param index="0" name="value" type="float" /> <description> Returns [code]true[/code] if the array contains [param value]. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="insert"> @@ -143,6 +147,7 @@ <param index="1" name="from" type="int" default="-1" /> <description> Searches the array in reverse order. Optionally, a start search index can be passed. If negative, the start index is considered relative to the end of the array. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="set"> @@ -173,6 +178,7 @@ <return type="void" /> <description> Sorts the elements of the array in ascending order. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="to_byte_array" qualifiers="const"> diff --git a/doc/classes/PackedFloat64Array.xml b/doc/classes/PackedFloat64Array.xml index be178e1eac..844eae3019 100644 --- a/doc/classes/PackedFloat64Array.xml +++ b/doc/classes/PackedFloat64Array.xml @@ -53,6 +53,7 @@ <description> Finds the index of an existing value (or the insertion index that maintains sorting order, if the value is not yet present in the array) using binary search. Optionally, a [param before] specifier can be passed. If [code]false[/code], the returned index comes after all existing entries of the value in the array. [b]Note:[/b] Calling [method bsearch] on an unsorted array results in unexpected behavior. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="clear"> @@ -66,6 +67,7 @@ <param index="0" name="value" type="float" /> <description> Returns the number of times an element is in the array. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="duplicate"> @@ -87,6 +89,7 @@ <param index="1" name="from" type="int" default="0" /> <description> Searches the array for a value and returns its index or [code]-1[/code] if not found. Optionally, the initial search index can be passed. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="has" qualifiers="const"> @@ -94,6 +97,7 @@ <param index="0" name="value" type="float" /> <description> Returns [code]true[/code] if the array contains [param value]. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="insert"> @@ -143,6 +147,7 @@ <param index="1" name="from" type="int" default="-1" /> <description> Searches the array in reverse order. Optionally, a start search index can be passed. If negative, the start index is considered relative to the end of the array. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="set"> @@ -173,6 +178,7 @@ <return type="void" /> <description> Sorts the elements of the array in ascending order. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="to_byte_array" qualifiers="const"> diff --git a/doc/classes/PackedVector2Array.xml b/doc/classes/PackedVector2Array.xml index 1cfa11a314..0f74e0d2e5 100644 --- a/doc/classes/PackedVector2Array.xml +++ b/doc/classes/PackedVector2Array.xml @@ -53,6 +53,7 @@ <description> Finds the index of an existing value (or the insertion index that maintains sorting order, if the value is not yet present in the array) using binary search. Optionally, a [param before] specifier can be passed. If [code]false[/code], the returned index comes after all existing entries of the value in the array. [b]Note:[/b] Calling [method bsearch] on an unsorted array results in unexpected behavior. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="clear"> @@ -66,6 +67,7 @@ <param index="0" name="value" type="Vector2" /> <description> Returns the number of times an element is in the array. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="duplicate"> @@ -87,6 +89,7 @@ <param index="1" name="from" type="int" default="0" /> <description> Searches the array for a value and returns its index or [code]-1[/code] if not found. Optionally, the initial search index can be passed. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="has" qualifiers="const"> @@ -94,6 +97,7 @@ <param index="0" name="value" type="Vector2" /> <description> Returns [code]true[/code] if the array contains [param value]. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="insert"> @@ -143,6 +147,7 @@ <param index="1" name="from" type="int" default="-1" /> <description> Searches the array in reverse order. Optionally, a start search index can be passed. If negative, the start index is considered relative to the end of the array. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="set"> @@ -173,6 +178,7 @@ <return type="void" /> <description> Sorts the elements of the array in ascending order. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="to_byte_array" qualifiers="const"> diff --git a/doc/classes/PackedVector3Array.xml b/doc/classes/PackedVector3Array.xml index f6a012f35e..9d0fdaa717 100644 --- a/doc/classes/PackedVector3Array.xml +++ b/doc/classes/PackedVector3Array.xml @@ -52,6 +52,7 @@ <description> Finds the index of an existing value (or the insertion index that maintains sorting order, if the value is not yet present in the array) using binary search. Optionally, a [param before] specifier can be passed. If [code]false[/code], the returned index comes after all existing entries of the value in the array. [b]Note:[/b] Calling [method bsearch] on an unsorted array results in unexpected behavior. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="clear"> @@ -65,6 +66,7 @@ <param index="0" name="value" type="Vector3" /> <description> Returns the number of times an element is in the array. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="duplicate"> @@ -86,6 +88,7 @@ <param index="1" name="from" type="int" default="0" /> <description> Searches the array for a value and returns its index or [code]-1[/code] if not found. Optionally, the initial search index can be passed. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="has" qualifiers="const"> @@ -93,6 +96,7 @@ <param index="0" name="value" type="Vector3" /> <description> Returns [code]true[/code] if the array contains [param value]. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="insert"> @@ -142,6 +146,7 @@ <param index="1" name="from" type="int" default="-1" /> <description> Searches the array in reverse order. Optionally, a start search index can be passed. If negative, the start index is considered relative to the end of the array. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="set"> @@ -172,6 +177,7 @@ <return type="void" /> <description> Sorts the elements of the array in ascending order. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this method may not be accurate if NaNs are included. </description> </method> <method name="to_byte_array" qualifiers="const"> diff --git a/doc/classes/Vector2.xml b/doc/classes/Vector2.xml index 6c9d96860a..cc406d9067 100644 --- a/doc/classes/Vector2.xml +++ b/doc/classes/Vector2.xml @@ -412,6 +412,7 @@ <description> Returns [code]true[/code] if the vectors are not equal. [b]Note:[/b] Due to floating-point precision errors, consider using [method is_equal_approx] instead, which is more reliable. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator *"> @@ -494,6 +495,7 @@ <param index="0" name="right" type="Vector2" /> <description> Compares two [Vector2] vectors by first checking if the X value of the left vector is less than the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator <="> @@ -501,6 +503,7 @@ <param index="0" name="right" type="Vector2" /> <description> Compares two [Vector2] vectors by first checking if the X value of the left vector is less than or equal to the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator =="> @@ -509,6 +512,7 @@ <description> Returns [code]true[/code] if the vectors are exactly equal. [b]Note:[/b] Due to floating-point precision errors, consider using [method is_equal_approx] instead, which is more reliable. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator >"> @@ -516,6 +520,7 @@ <param index="0" name="right" type="Vector2" /> <description> Compares two [Vector2] vectors by first checking if the X value of the left vector is greater than the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator >="> @@ -523,6 +528,7 @@ <param index="0" name="right" type="Vector2" /> <description> Compares two [Vector2] vectors by first checking if the X value of the left vector is greater than or equal to the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator []"> diff --git a/doc/classes/Vector3.xml b/doc/classes/Vector3.xml index d4ecf008f2..659707987d 100644 --- a/doc/classes/Vector3.xml +++ b/doc/classes/Vector3.xml @@ -435,6 +435,7 @@ <description> Returns [code]true[/code] if the vectors are not equal. [b]Note:[/b] Due to floating-point precision errors, consider using [method is_equal_approx] instead, which is more reliable. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator *"> @@ -531,6 +532,7 @@ <param index="0" name="right" type="Vector3" /> <description> Compares two [Vector3] vectors by first checking if the X value of the left vector is less than the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors, and then with the Z values. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator <="> @@ -538,6 +540,7 @@ <param index="0" name="right" type="Vector3" /> <description> Compares two [Vector3] vectors by first checking if the X value of the left vector is less than or equal to the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors, and then with the Z values. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator =="> @@ -546,6 +549,7 @@ <description> Returns [code]true[/code] if the vectors are exactly equal. [b]Note:[/b] Due to floating-point precision errors, consider using [method is_equal_approx] instead, which is more reliable. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator >"> @@ -553,6 +557,7 @@ <param index="0" name="right" type="Vector3" /> <description> Compares two [Vector3] vectors by first checking if the X value of the left vector is greater than the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors, and then with the Z values. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator >="> @@ -560,6 +565,7 @@ <param index="0" name="right" type="Vector3" /> <description> Compares two [Vector3] vectors by first checking if the X value of the left vector is greater than or equal to the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors, and then with the Z values. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator []"> diff --git a/doc/classes/Vector4.xml b/doc/classes/Vector4.xml index a89663a54a..daeda011da 100644 --- a/doc/classes/Vector4.xml +++ b/doc/classes/Vector4.xml @@ -273,6 +273,7 @@ <description> Returns [code]true[/code] if the vectors are not equal. [b]Note:[/b] Due to floating-point precision errors, consider using [method is_equal_approx] instead, which is more reliable. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator *"> @@ -361,6 +362,7 @@ <param index="0" name="right" type="Vector4" /> <description> Compares two [Vector4] vectors by first checking if the X value of the left vector is less than the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors, Z values of the two vectors, and then with the W values. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator <="> @@ -368,6 +370,7 @@ <param index="0" name="right" type="Vector4" /> <description> Compares two [Vector4] vectors by first checking if the X value of the left vector is less than or equal to the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors, Z values of the two vectors, and then with the W values. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator =="> @@ -376,6 +379,7 @@ <description> Returns [code]true[/code] if the vectors are exactly equal. [b]Note:[/b] Due to floating-point precision errors, consider using [method is_equal_approx] instead, which is more reliable. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator >"> @@ -383,6 +387,7 @@ <param index="0" name="right" type="Vector4" /> <description> Compares two [Vector4] vectors by first checking if the X value of the left vector is greater than the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors, Z values of the two vectors, and then with the W values. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator >="> @@ -390,6 +395,7 @@ <param index="0" name="right" type="Vector4" /> <description> Compares two [Vector4] vectors by first checking if the X value of the left vector is greater than or equal to the X value of the [param right] vector. If the X values are exactly equal, then it repeats this check with the Y values of the two vectors, Z values of the two vectors, and then with the W values. This operator is useful for sorting vectors. + [b]Note:[/b] Vectors with [constant @GDScript.NAN] elements don't behave the same as other vectors. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator []"> diff --git a/doc/classes/float.xml b/doc/classes/float.xml index fa0d4e6367..293ba2eaf9 100644 --- a/doc/classes/float.xml +++ b/doc/classes/float.xml @@ -54,6 +54,7 @@ <param index="0" name="right" type="float" /> <description> Returns [code]true[/code] if two floats are different from each other. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator !="> @@ -215,6 +216,7 @@ <param index="0" name="right" type="float" /> <description> Returns [code]true[/code] if the left float is less than the right one. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator <"> @@ -229,6 +231,7 @@ <param index="0" name="right" type="float" /> <description> Returns [code]true[/code] if the left float is less than or equal to the right one. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator <="> @@ -244,6 +247,7 @@ <description> Returns [code]true[/code] if both floats are exactly equal. [b]Note:[/b] Due to floating-point precision errors, consider using [method @GlobalScope.is_equal_approx] or [method @GlobalScope.is_zero_approx] instead, which are more reliable. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator =="> @@ -258,6 +262,7 @@ <param index="0" name="right" type="float" /> <description> Returns [code]true[/code] if the left float is greater than the right one. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator >"> @@ -272,6 +277,7 @@ <param index="0" name="right" type="float" /> <description> Returns [code]true[/code] if the left float is greater than or equal to the right one. + [b]Note:[/b] [constant @GDScript.NAN] doesn't behave the same as other numbers. Therefore, the results from this operator may not be accurate if NaNs are included. </description> </operator> <operator name="operator >="> diff --git a/modules/gdscript/doc_classes/@GDScript.xml b/modules/gdscript/doc_classes/@GDScript.xml index a40afa702c..5a28246555 100644 --- a/modules/gdscript/doc_classes/@GDScript.xml +++ b/modules/gdscript/doc_classes/@GDScript.xml @@ -274,7 +274,7 @@ [b]Warning:[/b] Numeric infinity is only a concept with floating-point numbers, and has no equivalent for integers. Dividing an integer number by [code]0[/code] will not result in [constant INF] and will result in a run-time error instead. </constant> <constant name="NAN" value="nan"> - "Not a Number", an invalid floating-point value. [constant NAN] has special properties, including that it is not equal to itself ([code]NAN == NAN[/code] returns [code]false[/code]). It is output by some invalid operations, such as dividing floating-point [code]0.0[/code] by [code]0.0[/code]. + "Not a Number", an invalid floating-point value. [constant NAN] has special properties, including that [code]!=[/code] always returns [code]true[/code], while other comparison operators always return [code]false[/code]. This is true even when comparing with itself ([code]NAN == NAN[/code] returns [code]false[/code] and [code]NAN != NAN[/code] returns [code]true[/code]). It is returned by some invalid operations, such as dividing floating-point [code]0.0[/code] by [code]0.0[/code]. [b]Warning:[/b] "Not a Number" is only a concept with floating-point numbers, and has no equivalent for integers. Dividing an integer [code]0[/code] by [code]0[/code] will not result in [constant NAN] and will result in a run-time error instead. </constant> </constants> |