diff options
Diffstat (limited to 'doc/classes')
88 files changed, 1562 insertions, 528 deletions
diff --git a/doc/classes/@GlobalScope.xml b/doc/classes/@GlobalScope.xml index c8f216e199..bf81362e79 100644 --- a/doc/classes/@GlobalScope.xml +++ b/doc/classes/@GlobalScope.xml @@ -668,7 +668,7 @@ </method> <method name="print" qualifiers="vararg"> <description> - Converts one or more arguments to strings in the best way possible and prints them to the console. + Converts one or more arguments of any type to string in the best way possible and prints them to the console. [codeblock] a = [1, 2, 3] print("a", "b", a) # Prints ab[1, 2, 3] @@ -944,6 +944,22 @@ [/codeblock] </description> </method> + <method name="snapped"> + <return type="float"> + </return> + <argument index="0" name="x" type="float"> + </argument> + <argument index="1" name="step" type="float"> + </argument> + <description> + Snaps float value [code]x[/code] to a given [code]step[/code]. This can also be used to round a floating point number to an arbitrary number of decimals. + [codeblock] + snapped(100, 32) # Returns 96 + snapped(3.14159, 0.01) # Returns 3.14 + [/codeblock] + See also [method ceil], [method floor], and [method round]. + </description> + </method> <method name="sqrt"> <return type="float"> </return> @@ -974,27 +990,11 @@ [/codeblock] </description> </method> - <method name="snapped"> - <return type="float"> - </return> - <argument index="0" name="x" type="float"> - </argument> - <argument index="1" name="step" type="float"> - </argument> - <description> - Snaps float value [code]x[/code] to a given [code]step[/code]. This can also be used to round a floating point number to an arbitrary number of decimals. - [codeblock] - snapped(100, 32) # Returns 96 - snapped(3.14159, 0.01) # Returns 3.14 - [/codeblock] - See also [method ceil], [method floor], and [method round]. - </description> - </method> <method name="str" qualifiers="vararg"> <return type="String"> </return> <description> - Converts one or more arguments to string in the best way possible. + Converts one or more arguments of any type to string in the best way possible. </description> </method> <method name="str2var"> diff --git a/doc/classes/AABB.xml b/doc/classes/AABB.xml index baea84df65..8cd7e6f5fa 100644 --- a/doc/classes/AABB.xml +++ b/doc/classes/AABB.xml @@ -219,7 +219,7 @@ <argument index="0" name="aabb" type="AABB"> </argument> <description> - Returns [code]true[/code] if this [AABB] and [code]aabb[/code] are approximately equal, by calling [method @GDScript.is_equal_approx] on each component. + Returns [code]true[/code] if this [AABB] and [code]aabb[/code] are approximately equal, by calling [method @GlobalScope.is_equal_approx] on each component. </description> </method> <method name="merge"> diff --git a/doc/classes/AStar.xml b/doc/classes/AStar.xml index 0cd7d3dc25..bfdc66623d 100644 --- a/doc/classes/AStar.xml +++ b/doc/classes/AStar.xml @@ -33,6 +33,7 @@ [/csharp] [/codeblocks] [method _estimate_cost] should return a lower bound of the distance, i.e. [code]_estimate_cost(u, v) <= _compute_cost(u, v)[/code]. This serves as a hint to the algorithm because the custom [code]_compute_cost[/code] might be computation-heavy. If this is not the case, make [method _estimate_cost] return the same value as [method _compute_cost] to provide the algorithm with the most accurate information. + If the default [method _estimate_cost] and [method _compute_cost] methods are used, or if the supplied [method _estimate_cost] method returns a lower bound of the cost, then the paths returned by A* will be the lowest cost paths. Here, the cost of a path equals to the sum of the [method _compute_cost] results of all segments in the path multiplied by the [code]weight_scale[/code]s of the end points of the respective segments. If the default methods are used and the [code]weight_scale[/code]s of all points are set to [code]1.0[/code], then this equals to the sum of Euclidean distances of all segments in the path. </description> <tutorials> </tutorials> @@ -71,7 +72,8 @@ <argument index="2" name="weight_scale" type="float" default="1.0"> </argument> <description> - Adds a new point at the given position with the given identifier. The algorithm prefers points with lower [code]weight_scale[/code] to form a path. The [code]id[/code] must be 0 or larger, and the [code]weight_scale[/code] must be 1 or larger. + Adds a new point at the given position with the given identifier. The [code]id[/code] must be 0 or larger, and the [code]weight_scale[/code] must be 1 or larger. + The [code]weight_scale[/code] is multiplied by the result of [method _compute_cost] when determining the overall cost of traveling across a segment from a neighboring point to this point. Thus, all else being equal, the algorithm prefers points with lower [code]weight_scale[/code]s to form a path. [codeblocks] [gdscript] var astar = AStar.new() @@ -380,7 +382,7 @@ <argument index="1" name="weight_scale" type="float"> </argument> <description> - Sets the [code]weight_scale[/code] for the point with the given [code]id[/code]. + Sets the [code]weight_scale[/code] for the point with the given [code]id[/code]. The [code]weight_scale[/code] is multiplied by the result of [method _compute_cost] when determining the overall cost of traveling across a segment from a neighboring point to this point. </description> </method> </methods> diff --git a/doc/classes/AStar2D.xml b/doc/classes/AStar2D.xml index 1540d8dacc..2a51678209 100644 --- a/doc/classes/AStar2D.xml +++ b/doc/classes/AStar2D.xml @@ -43,7 +43,8 @@ <argument index="2" name="weight_scale" type="float" default="1.0"> </argument> <description> - Adds a new point at the given position with the given identifier. The algorithm prefers points with lower [code]weight_scale[/code] to form a path. The [code]id[/code] must be 0 or larger, and the [code]weight_scale[/code] must be 1 or larger. + Adds a new point at the given position with the given identifier. The [code]id[/code] must be 0 or larger, and the [code]weight_scale[/code] must be 1 or larger. + The [code]weight_scale[/code] is multiplied by the result of [method _compute_cost] when determining the overall cost of traveling across a segment from a neighboring point to this point. Thus, all else being equal, the algorithm prefers points with lower [code]weight_scale[/code]s to form a path. [codeblocks] [gdscript] var astar = AStar2D.new() @@ -350,7 +351,7 @@ <argument index="1" name="weight_scale" type="float"> </argument> <description> - Sets the [code]weight_scale[/code] for the point with the given [code]id[/code]. + Sets the [code]weight_scale[/code] for the point with the given [code]id[/code]. The [code]weight_scale[/code] is multiplied by the result of [method _compute_cost] when determining the overall cost of traveling across a segment from a neighboring point to this point. </description> </method> </methods> diff --git a/doc/classes/Animation.xml b/doc/classes/Animation.xml index 3e33a879b3..9720405ffd 100644 --- a/doc/classes/Animation.xml +++ b/doc/classes/Animation.xml @@ -168,7 +168,7 @@ <argument index="2" name="stream" type="Resource"> </argument> <description> - Sets the stream of the key identified by [code]key_idx[/code] to value [code]offset[/code]. The [code]track_idx[/code] must be the index of an Audio Track. + Sets the stream of the key identified by [code]key_idx[/code] to value [code]stream[/code]. The [code]track_idx[/code] must be the index of an Audio Track. </description> </method> <method name="bezier_track_get_key_in_handle" qualifiers="const"> @@ -409,7 +409,7 @@ <argument index="1" name="key_idx" type="int"> </argument> <description> - Returns the transition curve (easing) for a specific key (see the built-in math function [method @GDScript.ease]). + Returns the transition curve (easing) for a specific key (see the built-in math function [method @GlobalScope.ease]). </description> </method> <method name="track_get_key_value" qualifiers="const"> @@ -592,7 +592,7 @@ <argument index="2" name="transition" type="float"> </argument> <description> - Sets the transition curve (easing) for a specific key (see the built-in math function [method @GDScript.ease]). + Sets the transition curve (easing) for a specific key (see the built-in math function [method @GlobalScope.ease]). </description> </method> <method name="track_set_key_value"> diff --git a/doc/classes/AnimationNodeStateMachinePlayback.xml b/doc/classes/AnimationNodeStateMachinePlayback.xml index 60ff425cdb..c8468f9c8f 100644 --- a/doc/classes/AnimationNodeStateMachinePlayback.xml +++ b/doc/classes/AnimationNodeStateMachinePlayback.xml @@ -21,6 +21,12 @@ <link title="AnimationTree">https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> + <method name="get_current_length" qualifiers="const"> + <return type="float"> + </return> + <description> + </description> + </method> <method name="get_current_node" qualifiers="const"> <return type="StringName"> </return> @@ -28,6 +34,13 @@ Returns the currently playing animation state. </description> </method> + <method name="get_current_play_position" qualifiers="const"> + <return type="float"> + </return> + <description> + Returns the playback position within the current animation state. + </description> + </method> <method name="get_travel_path" qualifiers="const"> <return type="PackedStringArray"> </return> diff --git a/doc/classes/Area2D.xml b/doc/classes/Area2D.xml index 72c40478bb..a02f077cf7 100644 --- a/doc/classes/Area2D.xml +++ b/doc/classes/Area2D.xml @@ -140,14 +140,16 @@ <argument index="0" name="area" type="Area2D"> </argument> <description> - Emitted when another area enters. + Emitted when another Area2D enters this Area2D. Requires [member monitoring] to be set to [code]true[/code]. + [code]area[/code] the other Area2D. </description> </signal> <signal name="area_exited"> <argument index="0" name="area" type="Area2D"> </argument> <description> - Emitted when another area exits. + Emitted when another Area2D exits this Area2D. Requires [member monitoring] to be set to [code]true[/code]. + [code]area[/code] the other Area2D. </description> </signal> <signal name="area_shape_entered"> @@ -157,10 +159,14 @@ </argument> <argument index="2" name="area_shape" type="int"> </argument> - <argument index="3" name="self_shape" type="int"> + <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when another area enters, reporting which shapes overlapped. [code]shape_owner_get_owner(shape_find_owner(shape))[/code] returns the parent object of the owner of the [code]shape[/code]. + Emitted when one of another Area2D's [Shape2D]s enters one of this Area2D's [Shape2D]s. Requires [member monitoring] to be set to [code]true[/code]. + [code]area_id[/code] the [RID] of the other Area2D's [CollisionObject2D] used by the [PhysicsServer2D]. + [code]area[/code] the other Area2D. + [code]area_shape[/code] the index of the [Shape2D] of the other Area2D used by the [PhysicsServer2D]. + [code]local_shape[/code] the index of the [Shape2D] of this Area2D used by the [PhysicsServer2D]. </description> </signal> <signal name="area_shape_exited"> @@ -170,26 +176,30 @@ </argument> <argument index="2" name="area_shape" type="int"> </argument> - <argument index="3" name="self_shape" type="int"> + <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when another area exits, reporting which shapes were overlapping. + Emitted when one of another Area2D's [Shape2D]s exits one of this Area2D's [Shape2D]s. Requires [member monitoring] to be set to [code]true[/code]. + [code]area_id[/code] the [RID] of the other Area2D's [CollisionObject2D] used by the [PhysicsServer2D]. + [code]area[/code] the other Area2D. + [code]area_shape[/code] the index of the [Shape2D] of the other Area2D used by the [PhysicsServer2D]. + [code]local_shape[/code] the index of the [Shape2D] of this Area2D used by the [PhysicsServer2D]. </description> </signal> <signal name="body_entered"> <argument index="0" name="body" type="Node"> </argument> <description> - Emitted when a physics body enters. - The [code]body[/code] argument can either be a [PhysicsBody2D] or a [TileMap] instance (while TileMaps are not physics body themselves, they register their tiles with collision shapes as a virtual physics body). + Emitted when a [PhysicsBody2D] or [TileMap] enters this Area2D. Requires [member monitoring] to be set to [code]true[/code]. [TileMap]s are detected if the [TileSet] has Collision [Shape2D]s. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody2D] or [TileMap]. </description> </signal> <signal name="body_exited"> <argument index="0" name="body" type="Node"> </argument> <description> - Emitted when a physics body exits. - The [code]body[/code] argument can either be a [PhysicsBody2D] or a [TileMap] instance (while TileMaps are not physics body themselves, they register their tiles with collision shapes as a virtual physics body). + Emitted when a [PhysicsBody2D] or [TileMap] exits this Area2D. Requires [member monitoring] to be set to [code]true[/code]. [TileMap]s are detected if the [TileSet] has Collision [Shape2D]s. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody2D] or [TileMap]. </description> </signal> <signal name="body_shape_entered"> @@ -199,11 +209,14 @@ </argument> <argument index="2" name="body_shape" type="int"> </argument> - <argument index="3" name="area_shape" type="int"> + <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when a physics body enters, reporting which shapes overlapped. - The [code]body[/code] argument can either be a [PhysicsBody2D] or a [TileMap] instance (while TileMaps are not physics body themselves, they register their tiles with collision shapes as a virtual physics body). + Emitted when one of a [PhysicsBody2D] or [TileMap]'s [Shape2D]s enters one of this Area2D's [Shape2D]s. Requires [member monitoring] to be set to [code]true[/code]. [TileMap]s are detected if the [TileSet] has Collision [Shape2D]s. + [code]body_id[/code] the [RID] of the [PhysicsBody2D] or [TileSet]'s [CollisionObject2D] used by the [PhysicsServer2D]. + [code]body[/code] the [Node], if it exists in the tree, of the [PhysicsBody2D] or [TileMap]. + [code]body_shape[/code] the index of the [Shape2D] of the [PhysicsBody2D] or [TileMap] used by the [PhysicsServer2D]. + [code]local_shape[/code] the index of the [Shape2D] of this Area2D used by the [PhysicsServer2D]. </description> </signal> <signal name="body_shape_exited"> @@ -213,11 +226,14 @@ </argument> <argument index="2" name="body_shape" type="int"> </argument> - <argument index="3" name="area_shape" type="int"> + <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when a physics body exits, reporting which shapes were overlapping. - The [code]body[/code] argument can either be a [PhysicsBody2D] or a [TileMap] instance (while TileMaps are not physics body themselves, they register their tiles with collision shapes as a virtual physics body). + Emitted when one of a [PhysicsBody2D] or [TileMap]'s [Shape2D]s exits one of this Area2D's [Shape2D]s. Requires [member monitoring] to be set to [code]true[/code]. [TileMap]s are detected if the [TileSet] has Collision [Shape2D]s. + [code]body_id[/code] the [RID] of the [PhysicsBody2D] or [TileSet]'s [CollisionObject2D] used by the [PhysicsServer2D]. + [code]body[/code] the [Node], if it exists in the tree, of the [PhysicsBody2D] or [TileMap]. + [code]body_shape[/code] the index of the [Shape2D] of the [PhysicsBody2D] or [TileMap] used by the [PhysicsServer2D]. + [code]local_shape[/code] the index of the [Shape2D] of this Area2D used by the [PhysicsServer2D]. </description> </signal> </signals> diff --git a/doc/classes/Area3D.xml b/doc/classes/Area3D.xml index 2f8042bb1e..bd43d619dd 100644 --- a/doc/classes/Area3D.xml +++ b/doc/classes/Area3D.xml @@ -150,14 +150,16 @@ <argument index="0" name="area" type="Area3D"> </argument> <description> - Emitted when another area enters. + Emitted when another Area3D enters this Area3D. Requires [member monitoring] to be set to [code]true[/code]. + [code]area[/code] the other Area3D. </description> </signal> <signal name="area_exited"> <argument index="0" name="area" type="Area3D"> </argument> <description> - Emitted when another area exits. + Emitted when another Area3D exits this Area3D. Requires [member monitoring] to be set to [code]true[/code]. + [code]area[/code] the other Area3D. </description> </signal> <signal name="area_shape_entered"> @@ -167,10 +169,14 @@ </argument> <argument index="2" name="area_shape" type="int"> </argument> - <argument index="3" name="self_shape" type="int"> + <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when another area enters, reporting which areas overlapped. [code]shape_owner_get_owner(shape_find_owner(shape))[/code] returns the parent object of the owner of the [code]shape[/code]. + Emitted when one of another Area3D's [Shape3D]s enters one of this Area3D's [Shape3D]s. Requires [member monitoring] to be set to [code]true[/code]. + [code]area_id[/code] the [RID] of the other Area3D's [CollisionObject3D] used by the [PhysicsServer3D]. + [code]area[/code] the other Area3D. + [code]area_shape[/code] the index of the [Shape3D] of the other Area3D used by the [PhysicsServer3D]. + [code]local_shape[/code] the index of the [Shape3D] of this Area3D used by the [PhysicsServer3D]. </description> </signal> <signal name="area_shape_exited"> @@ -180,26 +186,30 @@ </argument> <argument index="2" name="area_shape" type="int"> </argument> - <argument index="3" name="self_shape" type="int"> + <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when another area exits, reporting which areas were overlapping. + Emitted when one of another Area3D's [Shape3D]s enters one of this Area3D's [Shape3D]s. Requires [member monitoring] to be set to [code]true[/code]. + [code]area_id[/code] the [RID] of the other Area3D's [CollisionObject3D] used by the [PhysicsServer3D]. + [code]area[/code] the other Area3D. + [code]area_shape[/code] the index of the [Shape3D] of the other Area3D used by the [PhysicsServer3D]. + [code]local_shape[/code] the index of the [Shape3D] of this Area3D used by the [PhysicsServer3D]. </description> </signal> <signal name="body_entered"> <argument index="0" name="body" type="Node"> </argument> <description> - Emitted when a physics body enters. - The [code]body[/code] argument can either be a [PhysicsBody3D] or a [GridMap] instance (while GridMaps are not physics body themselves, they register their tiles with collision shapes as a virtual physics body). + Emitted when a [PhysicsBody3D] or [GridMap] enters this Area3D. Requires [member monitoring] to be set to [code]true[/code]. [GridMap]s are detected if the [MeshLibrary] has Collision [Shape3D]s. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody3D] or [GridMap]. </description> </signal> <signal name="body_exited"> <argument index="0" name="body" type="Node"> </argument> <description> - Emitted when a physics body exits. - The [code]body[/code] argument can either be a [PhysicsBody3D] or a [GridMap] instance (while GridMaps are not physics body themselves, they register their tiles with collision shapes as a virtual physics body). + Emitted when a [PhysicsBody3D] or [GridMap] exits this Area3D. Requires [member monitoring] to be set to [code]true[/code]. [GridMap]s are detected if the [MeshLibrary] has Collision [Shape3D]s. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody3D] or [GridMap]. </description> </signal> <signal name="body_shape_entered"> @@ -209,11 +219,14 @@ </argument> <argument index="2" name="body_shape" type="int"> </argument> - <argument index="3" name="area_shape" type="int"> + <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when a physics body enters, reporting which shapes overlapped. - The [code]body[/code] argument can either be a [PhysicsBody3D] or a [GridMap] instance (while GridMaps are not physics body themselves, they register their tiles with collision shapes as a virtual physics body). + Emitted when one of a [PhysicsBody3D] or [GridMap]'s [Shape3D]s enters one of this Area3D's [Shape3D]s. Requires [member monitoring] to be set to [code]true[/code]. [GridMap]s are detected if the [MeshLibrary] has Collision [Shape3D]s. + [code]body_id[/code] the [RID] of the [PhysicsBody3D] or [MeshLibrary]'s [CollisionObject3D] used by the [PhysicsServer3D]. + [code]body[/code] the [Node], if it exists in the tree, of the [PhysicsBody3D] or [GridMap]. + [code]body_shape[/code] the index of the [Shape3D] of the [PhysicsBody3D] or [GridMap] used by the [PhysicsServer3D]. + [code]local_shape[/code] the index of the [Shape3D] of this Area3D used by the [PhysicsServer3D]. </description> </signal> <signal name="body_shape_exited"> @@ -223,11 +236,14 @@ </argument> <argument index="2" name="body_shape" type="int"> </argument> - <argument index="3" name="area_shape" type="int"> + <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when a physics body exits, reporting which shapes were overlapping. - The [code]body[/code] argument can either be a [PhysicsBody3D] or a [GridMap] instance (while GridMaps are not physics body themselves, they register their tiles with collision shapes as a virtual physics body). + Emitted when one of a [PhysicsBody3D] or [GridMap]'s [Shape3D]s enters one of this Area3D's [Shape3D]s. Requires [member monitoring] to be set to [code]true[/code]. [GridMap]s are detected if the [MeshLibrary] has Collision [Shape3D]s. + [code]body_id[/code] the [RID] of the [PhysicsBody3D] or [MeshLibrary]'s [CollisionObject3D] used by the [PhysicsServer3D]. + [code]body[/code] the [Node], if it exists in the tree, of the [PhysicsBody3D] or [GridMap]. + [code]body_shape[/code] the index of the [Shape3D] of the [PhysicsBody3D] or [GridMap] used by the [PhysicsServer3D]. + [code]local_shape[/code] the index of the [Shape3D] of this Area3D used by the [PhysicsServer3D]. </description> </signal> </signals> diff --git a/doc/classes/Array.xml b/doc/classes/Array.xml index e4f9dcf993..db5d377c62 100644 --- a/doc/classes/Array.xml +++ b/doc/classes/Array.xml @@ -228,13 +228,6 @@ If [code]deep[/code] is [code]true[/code], a deep copy is performed: all nested arrays and dictionaries are duplicated and will not be shared with the original array. If [code]false[/code], a shallow copy is made and references to the original nested arrays and dictionaries are kept, so that modifying a sub-array or dictionary in the copy will also impact those referenced in the source array. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the array is empty. - </description> - </method> <method name="erase"> <return type="void"> </return> @@ -339,6 +332,13 @@ Reverses the order of the elements in the array. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the array is empty. + </description> + </method> <method name="max"> <return type="Variant"> </return> @@ -482,7 +482,7 @@ <return type="void"> </return> <description> - Shuffles the array such that the items will have a random order. This method uses the global random number generator common to methods such as [method @GDScript.randi]. Call [method @GDScript.randomize] to ensure that a new seed will be used each time if you want non-reproducible shuffling. + Shuffles the array such that the items will have a random order. This method uses the global random number generator common to methods such as [method @GlobalScope.randi]. Call [method @GlobalScope.randomize] to ensure that a new seed will be used each time if you want non-reproducible shuffling. </description> </method> <method name="size"> diff --git a/doc/classes/ArrayMesh.xml b/doc/classes/ArrayMesh.xml index 59502e7017..1f532f4843 100644 --- a/doc/classes/ArrayMesh.xml +++ b/doc/classes/ArrayMesh.xml @@ -209,19 +209,13 @@ </method> </methods> <members> - <member name="blend_shape_mode" type="int" setter="set_blend_shape_mode" getter="get_blend_shape_mode" enum="ArrayMesh.BlendShapeMode" default="1"> - Sets the blend shape mode to one of [enum ArrayMesh.BlendShapeMode]. + <member name="blend_shape_mode" type="int" setter="set_blend_shape_mode" getter="get_blend_shape_mode" enum="Mesh.BlendShapeMode" default="1"> + Sets the blend shape mode to one of [enum Mesh.BlendShapeMode]. </member> <member name="custom_aabb" type="AABB" setter="set_custom_aabb" getter="get_custom_aabb" default="AABB( 0, 0, 0, 0, 0, 0 )"> Overrides the [AABB] with one defined by user for use with frustum culling. Especially useful to avoid unexpected culling when using a shader to offset vertices. </member> </members> <constants> - <constant name="BLEND_SHAPE_MODE_NORMALIZED" value="0" enum="BlendShapeMode"> - Blend shapes are normalized. - </constant> - <constant name="BLEND_SHAPE_MODE_RELATIVE" value="1" enum="BlendShapeMode"> - Blend shapes are relative to base weight. - </constant> </constants> </class> diff --git a/doc/classes/Camera2D.xml b/doc/classes/Camera2D.xml index f17c56fb11..2a4e726d43 100644 --- a/doc/classes/Camera2D.xml +++ b/doc/classes/Camera2D.xml @@ -52,7 +52,7 @@ <method name="get_drag_margin" qualifiers="const"> <return type="float"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <description> Returns the specified [enum Side]'s margin. See also [member drag_bottom_margin], [member drag_top_margin], [member drag_left_margin], and [member drag_right_margin]. @@ -61,7 +61,7 @@ <method name="get_limit" qualifiers="const"> <return type="int"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <description> Returns the camera limit for the specified [enum Side]. See also [member limit_bottom], [member limit_top], [member limit_left], and [member limit_right]. @@ -85,7 +85,7 @@ <method name="set_drag_margin"> <return type="void"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <argument index="1" name="drag_margin" type="float"> </argument> @@ -96,7 +96,7 @@ <method name="set_limit"> <return type="void"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <argument index="1" name="limit" type="int"> </argument> @@ -118,10 +118,10 @@ <member name="drag_bottom_margin" type="float" setter="set_drag_margin" getter="get_drag_margin" default="0.2"> Bottom margin needed to drag the camera. A value of [code]1[/code] makes the camera move only when reaching the bottom edge of the screen. </member> - <member name="drag_horizontal_enabled" type="bool" setter="set_h_drag_enabled" getter="is_h_drag_enabled" default="false"> + <member name="drag_horizontal_enabled" type="bool" setter="set_drag_horizontal_enabled" getter="is_drag_horizontal_enabled" default="false"> If [code]true[/code], the camera only moves when reaching the horizontal (left and right) drag margins. If [code]false[/code], the camera moves horizontally regardless of margins. </member> - <member name="drag_horizontal_offset" type="float" setter="set_h_offset" getter="get_h_offset" default="0.0"> + <member name="drag_horizontal_offset" type="float" setter="set_drag_horizontal_offset" getter="get_drag_horizontal_offset" default="0.0"> The relative horizontal drag offset of the camera between the right ([code]-1[/code]) and left ([code]1[/code]) drag margins. [b]Note:[/b] Used to set the initial horizontal drag offset; determine the current offset; or force the current offset. It's not automatically updated when the horizontal drag margin is enabled or the drag margins are changed. </member> @@ -137,7 +137,7 @@ <member name="drag_vertical_enabled" type="bool" setter="set_drag_vertical_enabled" getter="is_drag_vertical_enabled" default="false"> If [code]true[/code], the camera only moves when reaching the vertical (top and bottom) drag margins. If [code]false[/code], the camera moves vertically regardless of the drag margins. </member> - <member name="drag_vertical_offset" type="float" setter="set_drag_verticaloffset" getter="get_drag_vertical_offset" default="0.0"> + <member name="drag_vertical_offset" type="float" setter="set_drag_vertical_offset" getter="get_drag_vertical_offset" default="0.0"> The relative vertical drag offset of the camera between the bottom ([code]-1[/code]) and top ([code]1[/code]) drag margins. [b]Note:[/b] Used to set the initial vertical drag offset; determine the current offset; or force the current offset. It's not automatically updated when the vertical drag margin is enabled or the drag margins are changed. </member> diff --git a/doc/classes/CanvasItem.xml b/doc/classes/CanvasItem.xml index fcdd072c80..d13f431a16 100644 --- a/doc/classes/CanvasItem.xml +++ b/doc/classes/CanvasItem.xml @@ -9,7 +9,7 @@ Canvas items are drawn in tree order. By default, children are on top of their parents so a root [CanvasItem] will be drawn behind everything. This behavior can be changed on a per-item basis. A [CanvasItem] can also be hidden, which will also hide its children. It provides many ways to change parameters such as modulation (for itself and its children) and self modulation (only for itself), as well as its blend mode. Ultimately, a transform notification can be requested, which will notify the node that its global position changed in case the parent tree changed. - [b]Note:[/b] Unless otherwise specified, all methods that have angle parameters must have angles specified as [i]radians[/i]. To convert degrees to radians, use [method @GDScript.deg2rad]. + [b]Note:[/b] Unless otherwise specified, all methods that have angle parameters must have angles specified as [i]radians[/i]. To convert degrees to radians, use [method @GlobalScope.deg2rad]. </description> <tutorials> <link title="Viewport and canvas transforms">https://docs.godotengine.org/en/latest/tutorials/2d/2d_transforms.html</link> diff --git a/doc/classes/ClassDB.xml b/doc/classes/ClassDB.xml index 2a6a2ddd91..860bdc7c8f 100644 --- a/doc/classes/ClassDB.xml +++ b/doc/classes/ClassDB.xml @@ -67,6 +67,7 @@ </argument> <description> Returns an array with all the methods of [code]class[/code] or its ancestry if [code]no_inheritance[/code] is [code]false[/code]. Every element of the array is a [Dictionary] with the following keys: [code]args[/code], [code]default_args[/code], [code]flags[/code], [code]id[/code], [code]name[/code], [code]return: (class_name, hint, hint_string, name, type, usage)[/code]. + [b]Note:[/code] In exported release builds the debug info is not available, so the returned dictionaries will contain only method names. </description> </method> <method name="class_get_property" qualifiers="const"> diff --git a/doc/classes/Color.xml b/doc/classes/Color.xml index 755fd7eea2..8af5f29b65 100644 --- a/doc/classes/Color.xml +++ b/doc/classes/Color.xml @@ -5,7 +5,7 @@ </brief_description> <description> A color represented by red, green, blue, and alpha (RGBA) components. The alpha component is often used for transparency. Values are in floating-point and usually range from 0 to 1. Some properties (such as CanvasItem.modulate) may accept values greater than 1 (overbright or HDR colors). - You can also create a color from standardized color names by using [method @GDScript.ColorN] or directly using the color constants defined here. The standardized color set is based on the [url=https://en.wikipedia.org/wiki/X11_color_names]X11 color names[/url]. + You can also create a color from standardized color names by using [code]ColorN[/code] ([b]FIXME:[/b] No longer true, a Color(String) constructor should be re-implemented for that) or directly using the color constants defined here. The standardized color set is based on the [url=https://en.wikipedia.org/wiki/X11_color_names]X11 color names[/url]. If you want to supply values in a range of 0 to 255, you should use [method @GDScript.Color8]. [b]Note:[/b] In a boolean context, a Color will evaluate to [code]false[/code] if it's equal to [code]Color(0, 0, 0, 1)[/code] (opaque black). Otherwise, a Color will always evaluate to [code]true[/code]. [url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/color_constants.png]Color constants cheatsheet[/url] @@ -158,7 +158,7 @@ <argument index="0" name="to" type="Color"> </argument> <description> - Returns [code]true[/code] if this color and [code]color[/code] are approximately equal, by running [method @GDScript.is_equal_approx] on each component. + Returns [code]true[/code] if this color and [code]color[/code] are approximately equal, by running [method @GlobalScope.is_equal_approx] on each component. </description> </method> <method name="lerp"> diff --git a/doc/classes/Control.xml b/doc/classes/Control.xml index c3db716d3a..533748aced 100644 --- a/doc/classes/Control.xml +++ b/doc/classes/Control.xml @@ -213,17 +213,6 @@ Overrides the icon with given [code]name[/code] in the [member theme] resource the control uses. If [code]icon[/code] is [code]null[/code] or invalid, the override is cleared and the icon from assigned [Theme] is used. </description> </method> - <method name="add_theme_shader_override"> - <return type="void"> - </return> - <argument index="0" name="name" type="StringName"> - </argument> - <argument index="1" name="shader" type="Shader"> - </argument> - <description> - Overrides the [Shader] with given [code]name[/code] in the [member theme] resource the control uses. If [code]shader[/code] is [code]null[/code] or invalid, the override is cleared and the shader from assigned [Theme] is used. - </description> - </method> <method name="add_theme_stylebox_override"> <return type="void"> </return> @@ -417,20 +406,20 @@ Returns the position and size of the control relative to the top-left corner of the screen. See [member rect_position] and [member rect_size]. </description> </method> - <method name="get_offset" qualifiers="const"> - <return type="float"> + <method name="get_minimum_size" qualifiers="const"> + <return type="Vector2"> </return> - <argument index="0" name="side" type="int" enum="Side"> - </argument> <description> - Returns the anchor for the specified [enum Side]. A getter method for [member offset_bottom], [member offset_left], [member offset_right] and [member offset_top]. + Returns the minimum size for this control. See [member rect_min_size]. </description> </method> - <method name="get_minimum_size" qualifiers="const"> - <return type="Vector2"> + <method name="get_offset" qualifiers="const"> + <return type="float"> </return> + <argument index="0" name="offset" type="int" enum="Side"> + </argument> <description> - Returns the minimum size for this control. See [member rect_min_size]. + Returns the anchor for the specified [enum Side]. A getter method for [member offset_bottom], [member offset_left], [member offset_right] and [member offset_top]. </description> </method> <method name="get_parent_area_size" qualifiers="const"> @@ -685,15 +674,6 @@ Returns [code]true[/code] if icon with given [code]name[/code] has a valid override in this [Control] node. </description> </method> - <method name="has_theme_shader_override" qualifiers="const"> - <return type="bool"> - </return> - <argument index="0" name="name" type="StringName"> - </argument> - <description> - Returns [code]true[/code] if [Shader] with given [code]name[/code] has a valid override in this [Control] node. - </description> - </method> <method name="has_theme_stylebox" qualifiers="const"> <return type="bool"> </return> @@ -1063,6 +1043,13 @@ <member name="layout_direction" type="int" setter="set_layout_direction" getter="get_layout_direction" enum="Control.LayoutDirection" default="0"> Controls layout direction and text writing direction. Right-to-left layouts are necessary for certain languages (e.g. Arabic and Hebrew). </member> + <member name="mouse_default_cursor_shape" type="int" setter="set_default_cursor_shape" getter="get_default_cursor_shape" enum="Control.CursorShape" default="0"> + The default cursor shape for this control. Useful for Godot plugins and applications or games that use the system's mouse cursors. + [b]Note:[/b] On Linux, shapes may vary depending on the cursor theme of the system. + </member> + <member name="mouse_filter" type="int" setter="set_mouse_filter" getter="get_mouse_filter" enum="Control.MouseFilter" default="0"> + Controls whether the control will be able to receive mouse button input events through [method _gui_input] and how these events should be handled. Also controls whether the control can receive the [signal mouse_entered], and [signal mouse_exited] signals. See the constants to learn what each does. + </member> <member name="offset_bottom" type="float" setter="set_offset" getter="get_offset" default="0.0"> Distance between the node's bottom edge and its parent control, based on [member anchor_bottom]. Offsets are often controlled by one or multiple parent [Container] nodes, so you should not modify them manually if your node is a direct child of a [Container]. Offsets update automatically when you move or resize the node. @@ -1079,13 +1066,6 @@ Distance between the node's top edge and its parent control, based on [member anchor_top]. Offsets are often controlled by one or multiple parent [Container] nodes, so you should not modify them manually if your node is a direct child of a [Container]. Offsets update automatically when you move or resize the node. </member> - <member name="mouse_default_cursor_shape" type="int" setter="set_default_cursor_shape" getter="get_default_cursor_shape" enum="Control.CursorShape" default="0"> - The default cursor shape for this control. Useful for Godot plugins and applications or games that use the system's mouse cursors. - [b]Note:[/b] On Linux, shapes may vary depending on the cursor theme of the system. - </member> - <member name="mouse_filter" type="int" setter="set_mouse_filter" getter="get_mouse_filter" enum="Control.MouseFilter" default="0"> - Controls whether the control will be able to receive mouse button input events through [method _gui_input] and how these events should be handled. Also controls whether the control can receive the [signal mouse_entered], and [signal mouse_exited] signals. See the constants to learn what each does. - </member> <member name="rect_clip_content" type="bool" setter="set_clip_contents" getter="is_clipping_contents" default="false"> Enables whether rendering of [CanvasItem] based children should be clipped to this control's rectangle. If [code]true[/code], parts of a child which would be visibly outside of this control's rectangle will not be rendered. </member> diff --git a/doc/classes/Dictionary.xml b/doc/classes/Dictionary.xml index 2ca705cec7..d3fcbc9f64 100644 --- a/doc/classes/Dictionary.xml +++ b/doc/classes/Dictionary.xml @@ -215,13 +215,6 @@ Creates a copy of the dictionary, and returns it. The [code]deep[/code] parameter causes inner dictionaries and arrays to be copied recursively, but does not apply to objects. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the dictionary is empty. - </description> - </method> <method name="erase"> <return type="bool"> </return> @@ -299,6 +292,13 @@ [b]Note:[/b] Dictionaries with the same keys/values but in a different order will have a different hash. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the dictionary is empty. + </description> + </method> <method name="keys"> <return type="Array"> </return> diff --git a/doc/classes/EditorInterface.xml b/doc/classes/EditorInterface.xml index 5a61c05cee..b01af71852 100644 --- a/doc/classes/EditorInterface.xml +++ b/doc/classes/EditorInterface.xml @@ -40,13 +40,6 @@ Returns the edited (current) scene's root [Node]. </description> </method> - <method name="get_editor_settings"> - <return type="EditorSettings"> - </return> - <description> - Returns the editor's [EditorSettings] instance. - </description> - </method> <method name="get_editor_main_control"> <return type="Control"> </return> @@ -55,6 +48,13 @@ [b]Note:[/b] This returns the main editor control containing the whole editor, not the 2D or 3D viewports specifically. </description> </method> + <method name="get_editor_settings"> + <return type="EditorSettings"> + </return> + <description> + Returns the editor's [EditorSettings] instance. + </description> + </method> <method name="get_file_system_dock"> <return type="FileSystemDock"> </return> diff --git a/doc/classes/EditorSceneImporterAssimp.xml b/doc/classes/EditorSceneImporterAssimp.xml deleted file mode 100644 index c72d4ee25a..0000000000 --- a/doc/classes/EditorSceneImporterAssimp.xml +++ /dev/null @@ -1,36 +0,0 @@ -<?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorSceneImporterAssimp" inherits="EditorSceneImporter" version="4.0"> - <brief_description> - FBX 3D asset importer based on [url=http://assimp.org/]Assimp[/url]. - </brief_description> - <description> - This is an FBX 3D asset importer based on [url=http://assimp.org/]Assimp[/url]. It currently has many known limitations and works best with static meshes. Most animated meshes won't import correctly. - If exporting a FBX scene from Autodesk Maya, use these FBX export settings: - [codeblock] - - Smoothing Groups - - Smooth Mesh - - Triangluate (for meshes with blend shapes) - - Bake Animation - - Resample All - - Deformed Models - - Skins - - Blend Shapes - - Curve Filters - - Constant Key Reducer - - Auto Tangents Only - - *Do not check* Constraints (as it will break the file) - - Can check Embed Media (embeds textures into the exported FBX file) - - Note that when importing embedded media, the texture and mesh will be a single immutable file. - - You will have to re-export then re-import the FBX if the texture has changed. - - Units: Centimeters - - Up Axis: Y - - Binary format in FBX 2017 - [/codeblock] - </description> - <tutorials> - </tutorials> - <methods> - </methods> - <constants> - </constants> -</class> diff --git a/doc/classes/EditorSceneImporterGLTF.xml b/doc/classes/EditorSceneImporterGLTF.xml new file mode 100644 index 0000000000..e717b30f73 --- /dev/null +++ b/doc/classes/EditorSceneImporterGLTF.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="EditorSceneImporterGLTF" inherits="EditorSceneImporter" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <constants> + </constants> +</class> diff --git a/doc/classes/EditorSceneImporterMesh.xml b/doc/classes/EditorSceneImporterMesh.xml new file mode 100644 index 0000000000..1c903bd889 --- /dev/null +++ b/doc/classes/EditorSceneImporterMesh.xml @@ -0,0 +1,160 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="EditorSceneImporterMesh" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + <method name="add_blend_shape"> + <return type="void"> + </return> + <argument index="0" name="name" type="String"> + </argument> + <description> + </description> + </method> + <method name="add_surface"> + <return type="void"> + </return> + <argument index="0" name="primitive" type="int" enum="Mesh.PrimitiveType"> + </argument> + <argument index="1" name="arrays" type="Array"> + </argument> + <argument index="2" name="blend_shapes" type="Array" default="[ ]"> + </argument> + <argument index="3" name="lods" type="Dictionary" default="{ +}"> + </argument> + <argument index="4" name="material" type="Material" default="null"> + </argument> + <argument index="5" name="arg5" type="String" default=""""> + </argument> + <description> + </description> + </method> + <method name="clear"> + <return type="void"> + </return> + <description> + </description> + </method> + <method name="get_blend_shape_count" qualifiers="const"> + <return type="int"> + </return> + <description> + </description> + </method> + <method name="get_blend_shape_mode" qualifiers="const"> + <return type="int" enum="Mesh.BlendShapeMode"> + </return> + <description> + </description> + </method> + <method name="get_blend_shape_name" qualifiers="const"> + <return type="String"> + </return> + <argument index="0" name="blend_shape_idx" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_mesh"> + <return type="ArrayMesh"> + </return> + <description> + </description> + </method> + <method name="get_surface_arrays" qualifiers="const"> + <return type="Array"> + </return> + <argument index="0" name="surface_idx" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_surface_blend_shape_arrays" qualifiers="const"> + <return type="Array"> + </return> + <argument index="0" name="surface_idx" type="int"> + </argument> + <argument index="1" name="blend_shape_idx" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_surface_count" qualifiers="const"> + <return type="int"> + </return> + <description> + </description> + </method> + <method name="get_surface_lod_count" qualifiers="const"> + <return type="int"> + </return> + <argument index="0" name="surface_idx" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_surface_lod_indices" qualifiers="const"> + <return type="PackedInt32Array"> + </return> + <argument index="0" name="surface_idx" type="int"> + </argument> + <argument index="1" name="lod_idx" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_surface_lod_size" qualifiers="const"> + <return type="float"> + </return> + <argument index="0" name="surface_idx" type="int"> + </argument> + <argument index="1" name="lod_idx" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_surface_material" qualifiers="const"> + <return type="Material"> + </return> + <argument index="0" name="surface_idx" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_surface_name" qualifiers="const"> + <return type="String"> + </return> + <argument index="0" name="surface_idx" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_surface_primitive_type"> + <return type="int" enum="Mesh.PrimitiveType"> + </return> + <argument index="0" name="surface_idx" type="int"> + </argument> + <description> + </description> + </method> + <method name="set_blend_shape_mode"> + <return type="void"> + </return> + <argument index="0" name="mode" type="int" enum="Mesh.BlendShapeMode"> + </argument> + <description> + </description> + </method> + </methods> + <members> + <member name="_data" type="Dictionary" setter="_set_data" getter="_get_data" default="{"surfaces": [ ]}"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/EditorSceneImporterMeshNode3D.xml b/doc/classes/EditorSceneImporterMeshNode3D.xml new file mode 100644 index 0000000000..1e459c1cee --- /dev/null +++ b/doc/classes/EditorSceneImporterMeshNode3D.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="EditorSceneImporterMeshNode3D" inherits="Node3D" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <members> + <member name="mesh" type="EditorSceneImporterMesh" setter="set_mesh" getter="get_mesh"> + </member> + <member name="skeleton_path" type="NodePath" setter="set_skeleton_path" getter="get_skeleton_path" default="NodePath("")"> + </member> + <member name="skin" type="Skin" setter="set_skin" getter="get_skin"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/EncodedObjectAsID.xml b/doc/classes/EncodedObjectAsID.xml index fc68b47645..1e4fde453b 100644 --- a/doc/classes/EncodedObjectAsID.xml +++ b/doc/classes/EncodedObjectAsID.xml @@ -4,7 +4,7 @@ Holds a reference to an [Object]'s instance ID. </brief_description> <description> - Utility class which holds a reference to the internal identifier of an [Object] instance, as given by [method Object.get_instance_id]. This ID can then be used to retrieve the object instance with [method @GDScript.instance_from_id]. + Utility class which holds a reference to the internal identifier of an [Object] instance, as given by [method Object.get_instance_id]. This ID can then be used to retrieve the object instance with [method @GlobalScope.instance_from_id]. This class is used internally by the editor inspector and script debugger, but can also be used in plugins to pass and display objects as their IDs. </description> <tutorials> @@ -13,7 +13,7 @@ </methods> <members> <member name="object_id" type="int" setter="set_object_id" getter="get_object_id" default="0"> - The [Object] identifier stored in this [EncodedObjectAsID] instance. The object instance can be retrieved with [method @GDScript.instance_from_id]. + The [Object] identifier stored in this [EncodedObjectAsID] instance. The object instance can be retrieved with [method @GlobalScope.instance_from_id]. </member> </members> <constants> diff --git a/doc/classes/Engine.xml b/doc/classes/Engine.xml index c079085fb3..02b81ee9b7 100644 --- a/doc/classes/Engine.xml +++ b/doc/classes/Engine.xml @@ -51,13 +51,6 @@ Returns the frames per second of the running game. </description> </method> - <method name="get_process_frames" qualifiers="const"> - <return type="int"> - </return> - <description> - Returns the total number of frames passed since engine initialization which is advanced on each [b]process frame[/b], regardless of whether the render loop is enabled. See also [method get_frames_drawn]. - </description> - </method> <method name="get_license_info" qualifiers="const"> <return type="Dictionary"> </return> @@ -93,6 +86,13 @@ Returns the fraction through the current physics tick we are at the time of rendering the frame. This can be used to implement fixed timestep interpolation. </description> </method> + <method name="get_process_frames" qualifiers="const"> + <return type="int"> + </return> + <description> + Returns the total number of frames passed since engine initialization which is advanced on each [b]process frame[/b], regardless of whether the render loop is enabled. See also [method get_frames_drawn]. + </description> + </method> <method name="get_singleton" qualifiers="const"> <return type="Object"> </return> diff --git a/doc/classes/GLTFAccessor.xml b/doc/classes/GLTFAccessor.xml new file mode 100644 index 0000000000..a1f596f7dd --- /dev/null +++ b/doc/classes/GLTFAccessor.xml @@ -0,0 +1,43 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFAccessor" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <members> + <member name="buffer_view" type="int" setter="set_buffer_view" getter="get_buffer_view" default="0"> + </member> + <member name="byte_offset" type="int" setter="set_byte_offset" getter="get_byte_offset" default="0"> + </member> + <member name="component_type" type="int" setter="set_component_type" getter="get_component_type" default="0"> + </member> + <member name="count" type="int" setter="set_count" getter="get_count" default="0"> + </member> + <member name="max" type="PackedFloat64Array" setter="set_max" getter="get_max" default="PackedFloat64Array( )"> + </member> + <member name="min" type="PackedFloat64Array" setter="set_min" getter="get_min" default="PackedFloat64Array( )"> + </member> + <member name="normalized" type="bool" setter="set_normalized" getter="get_normalized" default="false"> + </member> + <member name="sparse_count" type="int" setter="set_sparse_count" getter="get_sparse_count" default="0"> + </member> + <member name="sparse_indices_buffer_view" type="int" setter="set_sparse_indices_buffer_view" getter="get_sparse_indices_buffer_view" default="0"> + </member> + <member name="sparse_indices_byte_offset" type="int" setter="set_sparse_indices_byte_offset" getter="get_sparse_indices_byte_offset" default="0"> + </member> + <member name="sparse_indices_component_type" type="int" setter="set_sparse_indices_component_type" getter="get_sparse_indices_component_type" default="0"> + </member> + <member name="sparse_values_buffer_view" type="int" setter="set_sparse_values_buffer_view" getter="get_sparse_values_buffer_view" default="0"> + </member> + <member name="sparse_values_byte_offset" type="int" setter="set_sparse_values_byte_offset" getter="get_sparse_values_byte_offset" default="0"> + </member> + <member name="type" type="int" setter="set_type" getter="get_type" default="0"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFAnimation.xml b/doc/classes/GLTFAnimation.xml new file mode 100644 index 0000000000..5c1fa02f11 --- /dev/null +++ b/doc/classes/GLTFAnimation.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFAnimation" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <members> + <member name="loop" type="bool" setter="set_loop" getter="get_loop" default="false"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFBufferView.xml b/doc/classes/GLTFBufferView.xml new file mode 100644 index 0000000000..edaad85e0a --- /dev/null +++ b/doc/classes/GLTFBufferView.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFBufferView" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <members> + <member name="buffer" type="int" setter="set_buffer" getter="get_buffer" default="-1"> + </member> + <member name="byte_length" type="int" setter="set_byte_length" getter="get_byte_length" default="0"> + </member> + <member name="byte_offset" type="int" setter="set_byte_offset" getter="get_byte_offset" default="0"> + </member> + <member name="byte_stride" type="int" setter="set_byte_stride" getter="get_byte_stride" default="-1"> + </member> + <member name="indices" type="bool" setter="set_indices" getter="get_indices" default="false"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFCamera.xml b/doc/classes/GLTFCamera.xml new file mode 100644 index 0000000000..0b95f2c802 --- /dev/null +++ b/doc/classes/GLTFCamera.xml @@ -0,0 +1,23 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFCamera" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <members> + <member name="fov_size" type="float" setter="set_fov_size" getter="get_fov_size" default="75.0"> + </member> + <member name="perspective" type="bool" setter="set_perspective" getter="get_perspective" default="true"> + </member> + <member name="zfar" type="float" setter="set_zfar" getter="get_zfar" default="4000.0"> + </member> + <member name="znear" type="float" setter="set_znear" getter="get_znear" default="0.05"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFDocument.xml b/doc/classes/GLTFDocument.xml new file mode 100644 index 0000000000..04c40dd752 --- /dev/null +++ b/doc/classes/GLTFDocument.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFDocument" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFLight.xml b/doc/classes/GLTFLight.xml new file mode 100644 index 0000000000..bfeaf9a86e --- /dev/null +++ b/doc/classes/GLTFLight.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFLight" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <members> + <member name="color" type="Color" setter="set_color" getter="get_color" default="Color( 0, 0, 0, 1 )"> + </member> + <member name="inner_cone_angle" type="float" setter="set_inner_cone_angle" getter="get_inner_cone_angle" default="0.0"> + </member> + <member name="intensity" type="float" setter="set_intensity" getter="get_intensity" default="0.0"> + </member> + <member name="outer_cone_angle" type="float" setter="set_outer_cone_angle" getter="get_outer_cone_angle" default="0.0"> + </member> + <member name="range" type="float" setter="set_range" getter="get_range" default="0.0"> + </member> + <member name="type" type="String" setter="set_type" getter="get_type" default=""""> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFMesh.xml b/doc/classes/GLTFMesh.xml new file mode 100644 index 0000000000..55f79d2c55 --- /dev/null +++ b/doc/classes/GLTFMesh.xml @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFMesh" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <members> + <member name="blend_weights" type="PackedFloat32Array" setter="set_blend_weights" getter="get_blend_weights" default="PackedFloat32Array( )"> + </member> + <member name="mesh" type="EditorSceneImporterMesh" setter="set_mesh" getter="get_mesh"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFNode.xml b/doc/classes/GLTFNode.xml new file mode 100644 index 0000000000..5b7d4fadec --- /dev/null +++ b/doc/classes/GLTFNode.xml @@ -0,0 +1,43 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFNode" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <members> + <member name="camera" type="int" setter="set_camera" getter="get_camera" default="-1"> + </member> + <member name="children" type="PackedInt32Array" setter="set_children" getter="get_children" default="PackedInt32Array( )"> + </member> + <member name="fake_joint_parent" type="int" setter="set_fake_joint_parent" getter="get_fake_joint_parent" default="-1"> + </member> + <member name="height" type="int" setter="set_height" getter="get_height" default="-1"> + </member> + <member name="joint" type="bool" setter="set_joint" getter="get_joint" default="false"> + </member> + <member name="light" type="int" setter="set_light" getter="get_light" default="-1"> + </member> + <member name="mesh" type="int" setter="set_mesh" getter="get_mesh" default="-1"> + </member> + <member name="parent" type="int" setter="set_parent" getter="get_parent" default="-1"> + </member> + <member name="rotation" type="Quat" setter="set_rotation" getter="get_rotation" default="Quat( 0, 0, 0, 1 )"> + </member> + <member name="scale" type="Vector3" setter="set_scale" getter="get_scale" default="Vector3( 1, 1, 1 )"> + </member> + <member name="skeleton" type="int" setter="set_skeleton" getter="get_skeleton" default="-1"> + </member> + <member name="skin" type="int" setter="set_skin" getter="get_skin" default="-1"> + </member> + <member name="translation" type="Vector3" setter="set_translation" getter="get_translation" default="Vector3( 0, 0, 0 )"> + </member> + <member name="xform" type="Transform" setter="set_xform" getter="get_xform" default="Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFSkeleton.xml b/doc/classes/GLTFSkeleton.xml new file mode 100644 index 0000000000..e27c838648 --- /dev/null +++ b/doc/classes/GLTFSkeleton.xml @@ -0,0 +1,67 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFSkeleton" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + <method name="get_bone_attachment"> + <return type="BoneAttachment3D"> + </return> + <argument index="0" name="arg0" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_bone_attachment_count"> + <return type="int"> + </return> + <description> + </description> + </method> + <method name="get_godot_bone_node"> + <return type="Dictionary"> + </return> + <description> + </description> + </method> + <method name="get_godot_skeleton"> + <return type="Skeleton3D"> + </return> + <description> + </description> + </method> + <method name="get_unique_names"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="set_godot_bone_node"> + <return type="void"> + </return> + <argument index="0" name="godot_bone_node" type="Dictionary"> + </argument> + <description> + </description> + </method> + <method name="set_unique_names"> + <return type="void"> + </return> + <argument index="0" name="unique_names" type="Array"> + </argument> + <description> + </description> + </method> + </methods> + <members> + <member name="joints" type="PackedInt32Array" setter="set_joints" getter="get_joints" default="PackedInt32Array( )"> + </member> + <member name="roots" type="PackedInt32Array" setter="set_roots" getter="get_roots" default="PackedInt32Array( )"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFSkin.xml b/doc/classes/GLTFSkin.xml new file mode 100644 index 0000000000..5a80c7097a --- /dev/null +++ b/doc/classes/GLTFSkin.xml @@ -0,0 +1,71 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFSkin" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + <method name="get_inverse_binds"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_joint_i_to_bone_i"> + <return type="Dictionary"> + </return> + <description> + </description> + </method> + <method name="get_joint_i_to_name"> + <return type="Dictionary"> + </return> + <description> + </description> + </method> + <method name="set_inverse_binds"> + <return type="void"> + </return> + <argument index="0" name="inverse_binds" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_joint_i_to_bone_i"> + <return type="void"> + </return> + <argument index="0" name="joint_i_to_bone_i" type="Dictionary"> + </argument> + <description> + </description> + </method> + <method name="set_joint_i_to_name"> + <return type="void"> + </return> + <argument index="0" name="joint_i_to_name" type="Dictionary"> + </argument> + <description> + </description> + </method> + </methods> + <members> + <member name="godot_skin" type="Skin" setter="set_godot_skin" getter="get_godot_skin"> + </member> + <member name="joints" type="PackedInt32Array" setter="set_joints" getter="get_joints" default="PackedInt32Array( )"> + </member> + <member name="joints_original" type="PackedInt32Array" setter="set_joints_original" getter="get_joints_original" default="PackedInt32Array( )"> + </member> + <member name="non_joints" type="PackedInt32Array" setter="set_non_joints" getter="get_non_joints" default="PackedInt32Array( )"> + </member> + <member name="roots" type="PackedInt32Array" setter="set_roots" getter="get_roots" default="PackedInt32Array( )"> + </member> + <member name="skeleton" type="int" setter="set_skeleton" getter="get_skeleton" default="-1"> + </member> + <member name="skin_root" type="int" setter="set_skin_root" getter="get_skin_root" default="-1"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFSpecGloss.xml b/doc/classes/GLTFSpecGloss.xml new file mode 100644 index 0000000000..68cc7c845d --- /dev/null +++ b/doc/classes/GLTFSpecGloss.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFSpecGloss" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <members> + <member name="diffuse_factor" type="Color" setter="set_diffuse_factor" getter="get_diffuse_factor" default="Color( 1, 1, 1, 1 )"> + </member> + <member name="diffuse_img" type="Image" setter="set_diffuse_img" getter="get_diffuse_img"> + </member> + <member name="gloss_factor" type="float" setter="set_gloss_factor" getter="get_gloss_factor" default="1.0"> + </member> + <member name="spec_gloss_img" type="Image" setter="set_spec_gloss_img" getter="get_spec_gloss_img"> + </member> + <member name="specular_factor" type="Color" setter="set_specular_factor" getter="get_specular_factor" default="Color( 1, 1, 1, 1 )"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFState.xml b/doc/classes/GLTFState.xml new file mode 100644 index 0000000000..f7763efdb1 --- /dev/null +++ b/doc/classes/GLTFState.xml @@ -0,0 +1,251 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFState" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + <method name="get_accessors"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_animation_player"> + <return type="AnimationPlayer"> + </return> + <argument index="0" name="arg0" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_animation_players_count"> + <return type="int"> + </return> + <argument index="0" name="arg0" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_animations"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_buffer_views"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_cameras"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_images"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_lights"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_materials"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_meshes"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_nodes"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_scene_node"> + <return type="Node"> + </return> + <argument index="0" name="arg0" type="int"> + </argument> + <description> + </description> + </method> + <method name="get_skeleton_to_node"> + <return type="Dictionary"> + </return> + <description> + </description> + </method> + <method name="get_skeletons"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_skins"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_textures"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="get_unique_names"> + <return type="Array"> + </return> + <description> + </description> + </method> + <method name="set_accessors"> + <return type="void"> + </return> + <argument index="0" name="accessors" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_animations"> + <return type="void"> + </return> + <argument index="0" name="animations" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_buffer_views"> + <return type="void"> + </return> + <argument index="0" name="buffer_views" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_cameras"> + <return type="void"> + </return> + <argument index="0" name="cameras" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_images"> + <return type="void"> + </return> + <argument index="0" name="images" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_lights"> + <return type="void"> + </return> + <argument index="0" name="lights" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_materials"> + <return type="void"> + </return> + <argument index="0" name="materials" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_meshes"> + <return type="void"> + </return> + <argument index="0" name="meshes" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_nodes"> + <return type="void"> + </return> + <argument index="0" name="nodes" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_skeleton_to_node"> + <return type="void"> + </return> + <argument index="0" name="skeleton_to_node" type="Dictionary"> + </argument> + <description> + </description> + </method> + <method name="set_skeletons"> + <return type="void"> + </return> + <argument index="0" name="skeletons" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_skins"> + <return type="void"> + </return> + <argument index="0" name="skins" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_textures"> + <return type="void"> + </return> + <argument index="0" name="textures" type="Array"> + </argument> + <description> + </description> + </method> + <method name="set_unique_names"> + <return type="void"> + </return> + <argument index="0" name="unique_names" type="Array"> + </argument> + <description> + </description> + </method> + </methods> + <members> + <member name="buffers" type="Array" setter="set_buffers" getter="get_buffers" default="[ ]"> + </member> + <member name="glb_data" type="PackedByteArray" setter="set_glb_data" getter="get_glb_data" default="PackedByteArray( )"> + </member> + <member name="json" type="Dictionary" setter="set_json" getter="get_json" default="{}"> + </member> + <member name="major_version" type="int" setter="set_major_version" getter="get_major_version" default="0"> + </member> + <member name="minor_version" type="int" setter="set_minor_version" getter="get_minor_version" default="0"> + </member> + <member name="root_nodes" type="Array" setter="set_root_nodes" getter="get_root_nodes" default="[ ]"> + </member> + <member name="scene_name" type="String" setter="set_scene_name" getter="get_scene_name" default=""""> + </member> + <member name="use_named_skin_binds" type="bool" setter="set_use_named_skin_binds" getter="get_use_named_skin_binds" default="false"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GLTFTexture.xml b/doc/classes/GLTFTexture.xml new file mode 100644 index 0000000000..c7f94ab0da --- /dev/null +++ b/doc/classes/GLTFTexture.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="GLTFTexture" inherits="Resource" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <members> + <member name="src_image" type="int" setter="set_src_image" getter="get_src_image" default="4"> + </member> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/GeometryInstance3D.xml b/doc/classes/GeometryInstance3D.xml index cc85ce295b..631a30abab 100644 --- a/doc/classes/GeometryInstance3D.xml +++ b/doc/classes/GeometryInstance3D.xml @@ -48,6 +48,8 @@ </member> <member name="gi_mode" type="int" setter="set_gi_mode" getter="get_gi_mode" enum="GeometryInstance3D.GIMode" default="0"> </member> + <member name="lod_bias" type="float" setter="set_lod_bias" getter="get_lod_bias" default="1.0"> + </member> <member name="lod_max_distance" type="float" setter="set_lod_max_distance" getter="get_lod_max_distance" default="0.0"> The GeometryInstance3D's max LOD distance. [b]Note:[/b] This property currently has no effect. diff --git a/doc/classes/GraphEdit.xml b/doc/classes/GraphEdit.xml index 2347627c31..10afa4c339 100644 --- a/doc/classes/GraphEdit.xml +++ b/doc/classes/GraphEdit.xml @@ -281,17 +281,17 @@ Emitted at the end of a GraphNode movement. </description> </signal> - <signal name="node_selected"> + <signal name="node_deselected"> <argument index="0" name="node" type="Node"> </argument> <description> - Emitted when a GraphNode is selected. </description> </signal> - <signal name="node_deselected"> + <signal name="node_selected"> <argument index="0" name="node" type="Node"> </argument> <description> + Emitted when a GraphNode is selected. </description> </signal> <signal name="paste_nodes_request"> diff --git a/doc/classes/ItemList.xml b/doc/classes/ItemList.xml index 8542cdaca4..2c322027e7 100644 --- a/doc/classes/ItemList.xml +++ b/doc/classes/ItemList.xml @@ -12,18 +12,18 @@ </tutorials> <methods> <method name="add_icon_item"> - <return type="void"> + <return type="int"> </return> <argument index="0" name="icon" type="Texture2D"> </argument> <argument index="1" name="selectable" type="bool" default="true"> </argument> <description> - Adds an item to the item list with no text, only an icon. + Adds an item to the item list with no text, only an icon. Returns the index of an added item. </description> </method> <method name="add_item"> - <return type="void"> + <return type="int"> </return> <argument index="0" name="text" type="String"> </argument> @@ -32,7 +32,8 @@ <argument index="2" name="selectable" type="bool" default="true"> </argument> <description> - Adds an item to the item list with specified text. Specify an [code]icon[/code], or use [code]null[/code] as the [code]icon[/code] for a list item with no icon. + Adds an item to the item list with specified text. Returns the index of an added item. + Specify an [code]icon[/code], or use [code]null[/code] as the [code]icon[/code] for a list item with no icon. If selectable is [code]true[/code], the list item will be selectable. </description> </method> @@ -52,6 +53,22 @@ Removes all OpenType features from the item's text. </description> </method> + <method name="deselect"> + <return type="void"> + </return> + <argument index="0" name="idx" type="int"> + </argument> + <description> + Ensures the item associated with the specified index is not selected. + </description> + </method> + <method name="deselect_all"> + <return type="void"> + </return> + <description> + Ensures there are no items selected. + </description> + </method> <method name="ensure_current_is_visible"> <return type="void"> </return> @@ -471,22 +488,6 @@ Sorts items in the list by their text. </description> </method> - <method name="deselect"> - <return type="void"> - </return> - <argument index="0" name="idx" type="int"> - </argument> - <description> - Ensures the item associated with the specified index is not selected. - </description> - </method> - <method name="deselect_all"> - <return type="void"> - </return> - <description> - Ensures there are no items selected. - </description> - </method> </methods> <members> <member name="allow_reselect" type="bool" setter="set_allow_reselect" getter="get_allow_reselect" default="false"> diff --git a/doc/classes/JSONParseResult.xml b/doc/classes/JSONParseResult.xml index 991ebcd7a0..bc94f74b07 100644 --- a/doc/classes/JSONParseResult.xml +++ b/doc/classes/JSONParseResult.xml @@ -21,7 +21,7 @@ The error message if the JSON source was not successfully parsed. See the [enum Error] constants. </member> <member name="result" type="Variant" setter="set_result" getter="get_result"> - A [Variant] containing the parsed JSON. Use [method @GDScript.typeof] or the [code]is[/code] keyword to check if it is what you expect. For example, if the JSON source starts with curly braces ([code]{}[/code]), a [Dictionary] will be returned. If the JSON source starts with brackets ([code][][/code]), an [Array] will be returned. + A [Variant] containing the parsed JSON. Use [method @GlobalScope.typeof] or the [code]is[/code] keyword to check if it is what you expect. For example, if the JSON source starts with curly braces ([code]{}[/code]), a [Dictionary] will be returned. If the JSON source starts with brackets ([code][][/code]), an [Array] will be returned. [b]Note:[/b] The JSON specification does not define integer or float types, but only a [i]number[/i] type. Therefore, parsing a JSON text will convert all numerical values to [float] types. [b]Note:[/b] JSON objects do not preserve key order like Godot dictionaries, thus, you should not rely on keys being in a certain order if a dictionary is constructed from JSON. In contrast, JSON arrays retain the order of their elements: [codeblocks] diff --git a/doc/classes/MainLoop.xml b/doc/classes/MainLoop.xml index 7682379b64..537ecf2b2b 100644 --- a/doc/classes/MainLoop.xml +++ b/doc/classes/MainLoop.xml @@ -19,7 +19,7 @@ print("Initialized:") print(" Starting time: %s" % str(time_elapsed)) - func _idle(delta): + func _process(delta): time_elapsed += delta # Return true to end the main loop. return quit @@ -51,30 +51,30 @@ Called before the program exits. </description> </method> - <method name="_idle" qualifiers="virtual"> - <return type="bool"> + <method name="_initialize" qualifiers="virtual"> + <return type="void"> </return> - <argument index="0" name="delta" type="float"> - </argument> <description> - Called each idle frame with the time since the last idle frame as argument (in seconds). Equivalent to [method Node._process]. - If implemented, the method must return a boolean value. [code]true[/code] ends the main loop, while [code]false[/code] lets it proceed to the next frame. + Called once during initialization. </description> </method> - <method name="_initialize" qualifiers="virtual"> - <return type="void"> + <method name="_physics_process" qualifiers="virtual"> + <return type="bool"> </return> + <argument index="0" name="delta" type="float"> + </argument> <description> - Called once during initialization. + Called each physics frame with the time since the last physics frame as argument ([code]delta[/code], in seconds). Equivalent to [method Node._physics_process]. + If implemented, the method must return a boolean value. [code]true[/code] ends the main loop, while [code]false[/code] lets it proceed to the next frame. </description> </method> - <method name="_iteration" qualifiers="virtual"> + <method name="_process" qualifiers="virtual"> <return type="bool"> </return> <argument index="0" name="delta" type="float"> </argument> <description> - Called each physics frame with the time since the last physics frame as argument (in seconds). Equivalent to [method Node._physics_process]. + Called each process (idle) frame with the time since the last process frame as argument (in seconds). Equivalent to [method Node._process]. If implemented, the method must return a boolean value. [code]true[/code] ends the main loop, while [code]false[/code] lets it proceed to the next frame. </description> </method> diff --git a/doc/classes/Mesh.xml b/doc/classes/Mesh.xml index dff4b4f7ab..ed7c39d4d9 100644 --- a/doc/classes/Mesh.xml +++ b/doc/classes/Mesh.xml @@ -242,5 +242,11 @@ </constant> <constant name="ARRAY_FLAG_USE_8_BONE_WEIGHTS" value="134217728" enum="ArrayFormat"> </constant> + <constant name="BLEND_SHAPE_MODE_NORMALIZED" value="0" enum="BlendShapeMode"> + Blend shapes are normalized. + </constant> + <constant name="BLEND_SHAPE_MODE_RELATIVE" value="1" enum="BlendShapeMode"> + Blend shapes are relative to base weight. + </constant> </constants> </class> diff --git a/doc/classes/NinePatchRect.xml b/doc/classes/NinePatchRect.xml index f4b9d75e91..d6de0ef4cf 100644 --- a/doc/classes/NinePatchRect.xml +++ b/doc/classes/NinePatchRect.xml @@ -12,7 +12,7 @@ <method name="get_patch_margin" qualifiers="const"> <return type="int"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <description> Returns the size of the margin on the specified [enum Side]. @@ -21,7 +21,7 @@ <method name="set_patch_margin"> <return type="void"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <argument index="1" name="value" type="int"> </argument> diff --git a/doc/classes/Node.xml b/doc/classes/Node.xml index 62d88afa51..e8913f2623 100644 --- a/doc/classes/Node.xml +++ b/doc/classes/Node.xml @@ -9,7 +9,7 @@ [b]Scene tree:[/b] The [SceneTree] contains the active tree of nodes. When a node is added to the scene tree, it receives the [constant NOTIFICATION_ENTER_TREE] notification and its [method _enter_tree] callback is triggered. Child nodes are always added [i]after[/i] their parent node, i.e. the [method _enter_tree] callback of a parent node will be triggered before its child's. Once all nodes have been added in the scene tree, they receive the [constant NOTIFICATION_READY] notification and their respective [method _ready] callbacks are triggered. For groups of nodes, the [method _ready] callback is called in reverse order, starting with the children and moving up to the parent nodes. This means that when adding a node to the scene tree, the following order will be used for the callbacks: [method _enter_tree] of the parent, [method _enter_tree] of the children, [method _ready] of the children and finally [method _ready] of the parent (recursively for the entire scene tree). - [b]Processing:[/b] Nodes can override the "process" state, so that they receive a callback on each frame requesting them to process (do something). Normal processing (callback [method _process], toggled with [method set_process]) happens as fast as possible and is dependent on the frame rate, so the processing time [i]delta[/i] is passed as an argument. Physics processing (callback [method _physics_process], toggled with [method set_physics_process]) happens a fixed number of times per second (60 by default) and is useful for code related to the physics engine. + [b]Processing:[/b] Nodes can override the "process" state, so that they receive a callback on each frame requesting them to process (do something). Normal processing (callback [method _process], toggled with [method set_process]) happens as fast as possible and is dependent on the frame rate, so the processing time [i]delta[/i] (in seconds) is passed as an argument. Physics processing (callback [method _physics_process], toggled with [method set_physics_process]) happens a fixed number of times per second (60 by default) and is useful for code related to the physics engine. Nodes can also process input events. When present, the [method _input] function will be called for each input that the program receives. In many cases, this can be overkill (unless used for simple projects), and the [method _unhandled_input] function might be preferred; it is called when the input event was not handled by anyone else (typically, GUI [Control] nodes), ensuring that the node only receives the events that were meant for it. To keep track of the scene hierarchy (especially when instancing scenes into other scenes), an "owner" can be set for the node with the [member owner] property. This keeps track of who instanced what. This is mostly useful when writing editors and tools, though. Finally, when a node is freed with [method Object.free] or [method queue_free], it will also free all its children. @@ -65,7 +65,7 @@ <argument index="0" name="delta" type="float"> </argument> <description> - Called during the physics processing step of the main loop. Physics processing means that the frame rate is synced to the physics, i.e. the [code]delta[/code] variable should be constant. + Called during the physics processing step of the main loop. Physics processing means that the frame rate is synced to the physics, i.e. the [code]delta[/code] variable should be constant. [code]delta[/code] is in seconds. It is only called if physics processing is enabled, which is done automatically if this method is overridden, and can be toggled with [method set_physics_process]. Corresponds to the [constant NOTIFICATION_PHYSICS_PROCESS] notification in [method Object._notification]. [b]Note:[/b] This method is only called if the node is present in the scene tree (i.e. if it's not orphan). @@ -77,7 +77,7 @@ <argument index="0" name="delta" type="float"> </argument> <description> - Called during the processing step of the main loop. Processing happens at every frame and as fast as possible, so the [code]delta[/code] time since the previous frame is not constant. + Called during the processing step of the main loop. Processing happens at every frame and as fast as possible, so the [code]delta[/code] time since the previous frame is not constant. [code]delta[/code] is in seconds. It is only called if processing is enabled, which is done automatically if this method is overridden, and can be toggled with [method set_process]. Corresponds to the [constant NOTIFICATION_PROCESS] notification in [method Object._notification]. [b]Note:[/b] This method is only called if the node is present in the scene tree (i.e. if it's not orphan). @@ -361,7 +361,7 @@ <return type="float"> </return> <description> - Returns the time elapsed since the last physics-bound frame (see [method _physics_process]). This is always a constant value in physics processing unless the frames per second is changed via [member Engine.iterations_per_second]. + Returns the time elapsed (in seconds) since the last physics-bound frame (see [method _physics_process]). This is always a constant value in physics processing unless the frames per second is changed via [member Engine.iterations_per_second]. </description> </method> <method name="get_process_delta_time" qualifiers="const"> @@ -590,7 +590,7 @@ <return type="void"> </return> <description> - Moves this node to the bottom of parent node's children hierarchy. This is often useful in GUIs ([Control] nodes), because their order of drawing depends on their order in the tree, i.e. the further they are on the node list, the higher they are drawn. After using [code]raise[/code], a Control will be drawn on top of their siblings. + Moves this node to the bottom of parent node's children hierarchy. This is often useful in GUIs ([Control] nodes), because their order of drawing depends on their order in the tree. The top Node is drawn first, then any siblings below the top Node in the hierarchy are successively drawn on top of it. After using [code]raise[/code], a Control will be drawn on top of its siblings. </description> </method> <method name="remove_and_skip"> diff --git a/doc/classes/Node3D.xml b/doc/classes/Node3D.xml index f6ff514474..8b56050058 100644 --- a/doc/classes/Node3D.xml +++ b/doc/classes/Node3D.xml @@ -6,7 +6,7 @@ <description> Most basic 3D game object, with a 3D [Transform] and visibility settings. All other 3D game objects inherit from Node3D. Use [Node3D] as a parent node to move, scale, rotate and show/hide children in a 3D project. Affine operations (rotate, scale, translate) happen in parent's local coordinate system, unless the [Node3D] object is set as top-level. Affine operations in this coordinate system correspond to direct affine operations on the [Node3D]'s transform. The word local below refers to this coordinate system. The coordinate system that is attached to the [Node3D] object itself is referred to as object-local coordinate system. - [b]Note:[/b] Unless otherwise specified, all methods that have angle parameters must have angles specified as [i]radians[/i]. To convert degrees to radians, use [method @GDScript.deg2rad]. + [b]Note:[/b] Unless otherwise specified, all methods that have angle parameters must have angles specified as [i]radians[/i]. To convert degrees to radians, use [method @GlobalScope.deg2rad]. </description> <tutorials> <link title="Introduction to 3D">https://docs.godotengine.org/en/latest/tutorials/3d/introduction_to_3d.html</link> @@ -229,7 +229,7 @@ <argument index="0" name="enable" type="bool"> </argument> <description> - Sets whether the node notifies about its global and local transformation changes. [Node3D] will not propagate this by default. + Sets whether the node notifies about its global and local transformation changes. [Node3D] will not propagate this by default, unless it is in the editor context and it has a valid gizmo. </description> </method> <method name="show"> @@ -324,7 +324,7 @@ <constants> <constant name="NOTIFICATION_TRANSFORM_CHANGED" value="2000"> Node3D nodes receives this notification when their global transform changes. This means that either the current or a parent node changed its transform. - In order for [constant NOTIFICATION_TRANSFORM_CHANGED] to work, users first need to ask for it, with [method set_notify_transform]. + In order for [constant NOTIFICATION_TRANSFORM_CHANGED] to work, users first need to ask for it, with [method set_notify_transform]. The notification is also sent if the node is in the editor context and it has a valid gizmo. </constant> <constant name="NOTIFICATION_ENTER_WORLD" value="41"> Node3D nodes receives this notification when they are registered to new [World3D] resource. diff --git a/doc/classes/OS.xml b/doc/classes/OS.xml index 65a815a603..ed94f9d90f 100644 --- a/doc/classes/OS.xml +++ b/doc/classes/OS.xml @@ -25,6 +25,29 @@ [b]Note:[/b] This method is implemented on Linux, macOS and Windows. </description> </method> + <method name="create_process"> + <return type="int"> + </return> + <argument index="0" name="path" type="String"> + </argument> + <argument index="1" name="arguments" type="PackedStringArray"> + </argument> + <description> + Creates a new process that runs independently of Godot. It will not terminate if Godot terminates. The file specified in [code]path[/code] must exist and be executable. Platform path resolution will be used. The [code]arguments[/code] are used in the given order and separated by a space. + If the process creation succeeds, the method will return the new process ID, which you can use to monitor the process (and potentially terminate it with [method kill]). If the process creation fails, the method will return [code]-1[/code]. + For example, running another instance of the project: + [codeblocks] + [gdscript] + var pid = OS.create_process(OS.get_executable_path(), []) + [/gdscript] + [csharp] + var pid = OS.CreateProcess(OS.GetExecutablePath(), new string[] {}); + [/csharp] + [/codeblocks] + See [method execute] if you wish to run an external command and retrieve the results. + [b]Note:[/b] This method is implemented on Android, iOS, Linux, macOS and Windows. + </description> + </method> <method name="delay_msec" qualifiers="const"> <return type="void"> </return> @@ -71,48 +94,34 @@ </argument> <argument index="1" name="arguments" type="PackedStringArray"> </argument> - <argument index="2" name="blocking" type="bool" default="true"> - </argument> - <argument index="3" name="output" type="Array" default="[ ]"> + <argument index="2" name="output" type="Array" default="[ ]"> </argument> - <argument index="4" name="read_stderr" type="bool" default="false"> + <argument index="3" name="read_stderr" type="bool" default="false"> </argument> <description> - Execute the file at the given path with the arguments passed as an array of strings. Platform path resolution will take place. The resolved file must exist and be executable. - The arguments are used in the given order and separated by a space, so [code]OS.execute("ping", ["-w", "3", "godotengine.org"], false)[/code] will resolve to [code]ping -w 3 godotengine.org[/code] in the system's shell. - This method has slightly different behavior based on whether the [code]blocking[/code] mode is enabled. - If [code]blocking[/code] is [code]true[/code], the Godot thread will pause its execution while waiting for the process to terminate. The shell output of the process will be written to the [code]output[/code] array as a single string. When the process terminates, the Godot thread will resume execution. - If [code]blocking[/code] is [code]false[/code], the Godot thread will continue while the new process runs. It is not possible to retrieve the shell output in non-blocking mode, so [code]output[/code] will be empty. - The return value also depends on the blocking mode. When blocking, the method will return an exit code of the process. When non-blocking, the method returns a process ID, which you can use to monitor the process (and potentially terminate it with [method kill]). If the process forking (non-blocking) or opening (blocking) fails, the method will return [code]-1[/code] or another exit code. - Example of blocking mode and retrieving the shell output: + Executes a command. The file specified in [code]path[/code] must exist and be executable. Platform path resolution will be used. The [code]arguments[/code] are used in the given order and separated by a space. If an [code]output[/code] [Array] is provided, the complete shell output of the process will be appended as a single [String] element in [code]output[/code]. If [code]read_stderr[/code] is [code]true[/code], the output to the standard error stream will be included too. + If the command is successfully executed, the method will return the exit code of the command, or [code]-1[/code] if it fails. + [b]Note:[/b] The Godot thread will pause its execution until the executed command terminates. Use [Thread] to create a separate thread that will not pause the Godot thread, or use [method create_process] to create a completely independent process. + For example, to retrieve a list of the working directory's contents: [codeblocks] [gdscript] var output = [] - var exit_code = OS.execute("ls", ["-l", "/tmp"], true, output) + var exit_code = OS.execute("ls", ["-l", "/tmp"], output) [/gdscript] [csharp] var output = new Godot.Collections.Array(); - int exitCode = OS.Execute("ls", new string[] {"-l", "/tmp"}, true, output); - [/csharp] - [/codeblocks] - Example of non-blocking mode, running another instance of the project and storing its process ID: - [codeblocks] - [gdscript] - var pid = OS.execute(OS.get_executable_path(), [], false) - [/gdscript] - [csharp] - var pid = OS.Execute(OS.GetExecutablePath(), new string[] {}, false); + int exitCode = OS.Execute("ls", new string[] {"-l", "/tmp"}, output); [/csharp] [/codeblocks] - If you wish to access a shell built-in or perform a composite command, a platform-specific shell can be invoked. For example: + To execute a composite command, a platform-specific shell can be invoked. For example: [codeblocks] [gdscript] var output = [] - OS.execute("CMD.exe", ["/C", "cd %TEMP% && dir"], true, output) + OS.execute("CMD.exe", ["/C", "cd %TEMP% && dir"], output) [/gdscript] [csharp] var output = new Godot.Collections.Array(); - OS.Execute("CMD.exe", new string[] {"/C", "cd %TEMP% && dir"}, true, output); + OS.Execute("CMD.exe", new string[] {"/C", "cd %TEMP% && dir"}, output); [/csharp] [/codeblocks] [b]Note:[/b] This method is implemented on Android, iOS, Linux, macOS and Windows. diff --git a/doc/classes/Object.xml b/doc/classes/Object.xml index 50d91c7943..6ff7e34194 100644 --- a/doc/classes/Object.xml +++ b/doc/classes/Object.xml @@ -242,7 +242,7 @@ </return> <description> Returns the object's unique instance ID. - This ID can be saved in [EncodedObjectAsID], and can be used to retrieve the object instance with [method @GDScript.instance_from_id]. + This ID can be saved in [EncodedObjectAsID], and can be used to retrieve the object instance with [method @GlobalScope.instance_from_id]. </description> </method> <method name="get_meta" qualifiers="const"> diff --git a/doc/classes/PackedByteArray.xml b/doc/classes/PackedByteArray.xml index b00c59ade9..75fb7c1465 100644 --- a/doc/classes/PackedByteArray.xml +++ b/doc/classes/PackedByteArray.xml @@ -92,13 +92,6 @@ Creates a copy of the array, and returns it. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the array is empty. - </description> - </method> <method name="get_string_from_ascii"> <return type="String"> </return> @@ -171,6 +164,13 @@ Reverses the order of the elements in the array. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the array is empty. + </description> + </method> <method name="operator !=" qualifiers="operator"> <return type="bool"> </return> diff --git a/doc/classes/PackedColorArray.xml b/doc/classes/PackedColorArray.xml index d6cd5196e4..48d5822f7c 100644 --- a/doc/classes/PackedColorArray.xml +++ b/doc/classes/PackedColorArray.xml @@ -59,13 +59,6 @@ Creates a copy of the array, and returns it. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the array is empty. - </description> - </method> <method name="has"> <return type="bool"> </return> @@ -93,6 +86,13 @@ Reverses the order of the elements in the array. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the array is empty. + </description> + </method> <method name="operator !=" qualifiers="operator"> <return type="bool"> </return> diff --git a/doc/classes/PackedFloat32Array.xml b/doc/classes/PackedFloat32Array.xml index 52f6ece158..6598828089 100644 --- a/doc/classes/PackedFloat32Array.xml +++ b/doc/classes/PackedFloat32Array.xml @@ -60,13 +60,6 @@ Creates a copy of the array, and returns it. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the array is empty. - </description> - </method> <method name="has"> <return type="bool"> </return> @@ -94,6 +87,13 @@ Reverses the order of the elements in the array. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the array is empty. + </description> + </method> <method name="operator !=" qualifiers="operator"> <return type="bool"> </return> diff --git a/doc/classes/PackedFloat64Array.xml b/doc/classes/PackedFloat64Array.xml index 2f317d4b8c..d116c6756b 100644 --- a/doc/classes/PackedFloat64Array.xml +++ b/doc/classes/PackedFloat64Array.xml @@ -60,13 +60,6 @@ Creates a copy of the array, and returns it. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the array is empty. - </description> - </method> <method name="has"> <return type="bool"> </return> @@ -94,6 +87,13 @@ Reverses the order of the elements in the array. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the array is empty. + </description> + </method> <method name="operator !=" qualifiers="operator"> <return type="bool"> </return> diff --git a/doc/classes/PackedInt32Array.xml b/doc/classes/PackedInt32Array.xml index bda902b15f..2ac7a67b4b 100644 --- a/doc/classes/PackedInt32Array.xml +++ b/doc/classes/PackedInt32Array.xml @@ -60,13 +60,6 @@ Creates a copy of the array, and returns it. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the array is empty. - </description> - </method> <method name="has"> <return type="bool"> </return> @@ -94,6 +87,13 @@ Reverses the order of the elements in the array. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the array is empty. + </description> + </method> <method name="operator !=" qualifiers="operator"> <return type="bool"> </return> diff --git a/doc/classes/PackedInt64Array.xml b/doc/classes/PackedInt64Array.xml index 9c52ec808b..a7b6bf0a0f 100644 --- a/doc/classes/PackedInt64Array.xml +++ b/doc/classes/PackedInt64Array.xml @@ -60,13 +60,6 @@ Creates a copy of the array, and returns it. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the array is empty. - </description> - </method> <method name="has"> <return type="bool"> </return> @@ -94,6 +87,13 @@ Reverses the order of the elements in the array. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the array is empty. + </description> + </method> <method name="operator !=" qualifiers="operator"> <return type="bool"> </return> diff --git a/doc/classes/PackedSceneGLTF.xml b/doc/classes/PackedSceneGLTF.xml new file mode 100644 index 0000000000..a04c6ef0b6 --- /dev/null +++ b/doc/classes/PackedSceneGLTF.xml @@ -0,0 +1,58 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="PackedSceneGLTF" inherits="PackedScene" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + <method name="export_gltf"> + <return type="int" enum="Error"> + </return> + <argument index="0" name="node" type="Node"> + </argument> + <argument index="1" name="path" type="String"> + </argument> + <argument index="2" name="flags" type="int" default="0"> + </argument> + <argument index="3" name="bake_fps" type="float" default="1000.0"> + </argument> + <description> + </description> + </method> + <method name="import_gltf_scene"> + <return type="Node"> + </return> + <argument index="0" name="path" type="String"> + </argument> + <argument index="1" name="flags" type="int" default="0"> + </argument> + <argument index="2" name="bake_fps" type="float" default="1000.0"> + </argument> + <argument index="3" name="state" type="GLTFState" default="null"> + </argument> + <description> + </description> + </method> + <method name="pack_gltf"> + <return type="void"> + </return> + <argument index="0" name="path" type="String"> + </argument> + <argument index="1" name="flags" type="int" default="0"> + </argument> + <argument index="2" name="bake_fps" type="float" default="1000.0"> + </argument> + <argument index="3" name="state" type="GLTFState" default="null"> + </argument> + <description> + </description> + </method> + </methods> + <members> + <member name="_bundled" type="Dictionary" setter="_set_bundled_scene" getter="_get_bundled_scene" override="true" default="{"conn_count": 0,"conns": PackedInt32Array( ),"editable_instances": [ ],"names": PackedStringArray( ),"node_count": 0,"node_paths": [ ],"nodes": PackedInt32Array( ),"variants": [ ],"version": 2}" /> + </members> + <constants> + </constants> +</class> diff --git a/doc/classes/PackedStringArray.xml b/doc/classes/PackedStringArray.xml index 24406c53d4..fb7ed2a906 100644 --- a/doc/classes/PackedStringArray.xml +++ b/doc/classes/PackedStringArray.xml @@ -60,13 +60,6 @@ Creates a copy of the array, and returns it. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the array is empty. - </description> - </method> <method name="has"> <return type="bool"> </return> @@ -94,6 +87,13 @@ Reverses the order of the elements in the array. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the array is empty. + </description> + </method> <method name="operator !=" qualifiers="operator"> <return type="bool"> </return> diff --git a/doc/classes/PackedVector2Array.xml b/doc/classes/PackedVector2Array.xml index 2f583e2b9b..eb364ddb18 100644 --- a/doc/classes/PackedVector2Array.xml +++ b/doc/classes/PackedVector2Array.xml @@ -60,13 +60,6 @@ Creates a copy of the array, and returns it. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the array is empty. - </description> - </method> <method name="has"> <return type="bool"> </return> @@ -94,6 +87,13 @@ Reverses the order of the elements in the array. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the array is empty. + </description> + </method> <method name="operator !=" qualifiers="operator"> <return type="bool"> </return> diff --git a/doc/classes/PackedVector3Array.xml b/doc/classes/PackedVector3Array.xml index 6004454dc9..08ce187b5c 100644 --- a/doc/classes/PackedVector3Array.xml +++ b/doc/classes/PackedVector3Array.xml @@ -59,13 +59,6 @@ Creates a copy of the array, and returns it. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the array is empty. - </description> - </method> <method name="has"> <return type="bool"> </return> @@ -93,6 +86,13 @@ Reverses the order of the elements in the array. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the array is empty. + </description> + </method> <method name="operator !=" qualifiers="operator"> <return type="bool"> </return> diff --git a/doc/classes/PhysicsDirectSpaceState2D.xml b/doc/classes/PhysicsDirectSpaceState2D.xml index c26cf0514c..b6f95305ed 100644 --- a/doc/classes/PhysicsDirectSpaceState2D.xml +++ b/doc/classes/PhysicsDirectSpaceState2D.xml @@ -16,8 +16,9 @@ <argument index="0" name="shape" type="PhysicsShapeQueryParameters2D"> </argument> <description> - Checks how far the shape can travel toward a point. If the shape can not move, the array will be empty. - [b]Note:[/b] Both the shape and the motion are supplied through a [PhysicsShapeQueryParameters2D] object. The method will return an array with two floats between 0 and 1, both representing a fraction of [code]motion[/code]. The first is how far the shape can move without triggering a collision, and the second is the point at which a collision will occur. If no collision is detected, the returned array will be [code][1, 1][/code]. + Checks how far a [Shape2D] can move without colliding. All the parameters for the query, including the shape and the motion, are supplied through a [PhysicsShapeQueryParameters2D] object. + Returns an array with the safe and unsafe proportions (between 0 and 1) of the motion. The safe proportion is the maximum fraction of the motion that can be made without a collision. The unsafe proportion is the minimum fraction of the distance that must be moved for a collision. If no collision is detected a result of [code][1.0, 1.0][/code] will be returned. + [b]Note:[/b] Any [Shape2D]s that the shape is already colliding with e.g. inside of, will be ignored. Use [method collide_shape] to determine the [Shape2D]s that the shape is already colliding with. </description> </method> <method name="collide_shape"> diff --git a/doc/classes/PhysicsDirectSpaceState3D.xml b/doc/classes/PhysicsDirectSpaceState3D.xml index 789e8cc731..243d071c56 100644 --- a/doc/classes/PhysicsDirectSpaceState3D.xml +++ b/doc/classes/PhysicsDirectSpaceState3D.xml @@ -18,8 +18,9 @@ <argument index="1" name="motion" type="Vector3"> </argument> <description> - Checks whether the shape can travel to a point. The method will return an array with two floats between 0 and 1, both representing a fraction of [code]motion[/code]. The first is how far the shape can move without triggering a collision, and the second is the point at which a collision will occur. If no collision is detected, the returned array will be [code][1, 1][/code]. - If the shape can not move, the returned array will be [code][0, 0][/code] under Bullet, and empty under GodotPhysics3D. + Checks how far a [Shape3D] can move without colliding. All the parameters for the query, including the shape, are supplied through a [PhysicsShapeQueryParameters3D] object. + Returns an array with the safe and unsafe proportions (between 0 and 1) of the motion. The safe proportion is the maximum fraction of the motion that can be made without a collision. The unsafe proportion is the minimum fraction of the distance that must be moved for a collision. If no collision is detected a result of [code][1.0, 1.0][/code] will be returned. + [b]Note:[/b] Any [Shape3D]s that the shape is already colliding with e.g. inside of, will be ignored. Use [method collide_shape] to determine the [Shape3D]s that the shape is already colliding with. </description> </method> <method name="collide_shape"> diff --git a/doc/classes/Plane.xml b/doc/classes/Plane.xml index e3242512c4..ed96f753c2 100644 --- a/doc/classes/Plane.xml +++ b/doc/classes/Plane.xml @@ -142,7 +142,7 @@ <argument index="0" name="to_plane" type="Plane"> </argument> <description> - Returns [code]true[/code] if this plane and [code]plane[/code] are approximately equal, by running [method @GDScript.is_equal_approx] on each component. + Returns [code]true[/code] if this plane and [code]plane[/code] are approximately equal, by running [method @GlobalScope.is_equal_approx] on each component. </description> </method> <method name="is_point_over"> diff --git a/doc/classes/ProjectSettings.xml b/doc/classes/ProjectSettings.xml index e856d1ea9c..a82cf9a2a9 100644 --- a/doc/classes/ProjectSettings.xml +++ b/doc/classes/ProjectSettings.xml @@ -619,245 +619,245 @@ <member name="input_devices/pointing/ios/touch_delay" type="float" setter="" getter="" default="0.15"> Default delay for touch events. This only affects iOS devices. </member> + <member name="layer_names/2d_physics/layer_0" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 0. If left empty, the layer will display as "Layer 0". + </member> <member name="layer_names/2d_physics/layer_1" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 1. + Optional name for the 2D physics layer 1. If left empty, the layer will display as "Layer 1". </member> <member name="layer_names/2d_physics/layer_10" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 10. + Optional name for the 2D physics layer 10. If left empty, the layer will display as "Layer 10". </member> <member name="layer_names/2d_physics/layer_11" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 11. + Optional name for the 2D physics layer 11. If left empty, the layer will display as "Layer 11". </member> <member name="layer_names/2d_physics/layer_12" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 12. + Optional name for the 2D physics layer 12. If left empty, the layer will display as "Layer 12". </member> <member name="layer_names/2d_physics/layer_13" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 13. + Optional name for the 2D physics layer 13. If left empty, the layer will display as "Layer 13". </member> <member name="layer_names/2d_physics/layer_14" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 14. + Optional name for the 2D physics layer 14. If left empty, the layer will display as "Layer 14". </member> <member name="layer_names/2d_physics/layer_15" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 15. + Optional name for the 2D physics layer 15. If left empty, the layer will display as "Layer 15". </member> <member name="layer_names/2d_physics/layer_16" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 16. + Optional name for the 2D physics layer 16. If left empty, the layer will display as "Layer 16". </member> <member name="layer_names/2d_physics/layer_17" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 17. + Optional name for the 2D physics layer 17. If left empty, the layer will display as "Layer 17". </member> <member name="layer_names/2d_physics/layer_18" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 18. + Optional name for the 2D physics layer 18. If left empty, the layer will display as "Layer 18". </member> <member name="layer_names/2d_physics/layer_19" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 19. + Optional name for the 2D physics layer 19. If left empty, the layer will display as "Layer 19". </member> <member name="layer_names/2d_physics/layer_2" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 2. - </member> - <member name="layer_names/2d_physics/layer_20" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 20. + Optional name for the 2D physics layer 2. If left empty, the layer will display as "Layer 2". </member> <member name="layer_names/2d_physics/layer_3" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 3. + Optional name for the 2D physics layer 3. If left empty, the layer will display as "Layer 3". </member> <member name="layer_names/2d_physics/layer_4" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 4. + Optional name for the 2D physics layer 4. If left empty, the layer will display as "Layer 4". </member> <member name="layer_names/2d_physics/layer_5" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 5. + Optional name for the 2D physics layer 5. If left empty, the layer will display as "Layer 5". </member> <member name="layer_names/2d_physics/layer_6" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 6. + Optional name for the 2D physics layer 6. If left empty, the layer will display as "Layer 6". </member> <member name="layer_names/2d_physics/layer_7" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 7. + Optional name for the 2D physics layer 7. If left empty, the layer will display as "Layer 7". </member> <member name="layer_names/2d_physics/layer_8" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 8. + Optional name for the 2D physics layer 8. If left empty, the layer will display as "Layer 8". </member> <member name="layer_names/2d_physics/layer_9" type="String" setter="" getter="" default=""""> - Optional name for the 2D physics layer 9. + Optional name for the 2D physics layer 9. If left empty, the layer will display as "Layer 9". + </member> + <member name="layer_names/2d_render/layer_0" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 0. If left empty, the layer will display as "Layer 0". </member> <member name="layer_names/2d_render/layer_1" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 1. + Optional name for the 2D render layer 1. If left empty, the layer will display as "Layer 1". </member> <member name="layer_names/2d_render/layer_10" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 10. + Optional name for the 2D render layer 10. If left empty, the layer will display as "Layer 10". </member> <member name="layer_names/2d_render/layer_11" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 11. + Optional name for the 2D render layer 11. If left empty, the layer will display as "Layer 11". </member> <member name="layer_names/2d_render/layer_12" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 12. + Optional name for the 2D render layer 12. If left empty, the layer will display as "Layer 12". </member> <member name="layer_names/2d_render/layer_13" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 13. + Optional name for the 2D render layer 13. If left empty, the layer will display as "Layer 13". </member> <member name="layer_names/2d_render/layer_14" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 14. + Optional name for the 2D render layer 14. If left empty, the layer will display as "Layer 14". </member> <member name="layer_names/2d_render/layer_15" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 15. + Optional name for the 2D render layer 15. If left empty, the layer will display as "Layer 15". </member> <member name="layer_names/2d_render/layer_16" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 16. + Optional name for the 2D render layer 16. If left empty, the layer will display as "Layer 16". </member> <member name="layer_names/2d_render/layer_17" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 17. + Optional name for the 2D render layer 17. If left empty, the layer will display as "Layer 17". </member> <member name="layer_names/2d_render/layer_18" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 18. + Optional name for the 2D render layer 18. If left empty, the layer will display as "Layer 18". </member> <member name="layer_names/2d_render/layer_19" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 19. + Optional name for the 2D render layer 19. If left empty, the layer will display as "Layer 19". </member> <member name="layer_names/2d_render/layer_2" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 2. - </member> - <member name="layer_names/2d_render/layer_20" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 20. + Optional name for the 2D render layer 2. If left empty, the layer will display as "Layer 2". </member> <member name="layer_names/2d_render/layer_3" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 3. + Optional name for the 2D render layer 3. If left empty, the layer will display as "Layer 3". </member> <member name="layer_names/2d_render/layer_4" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 4. + Optional name for the 2D render layer 4. If left empty, the layer will display as "Layer 4". </member> <member name="layer_names/2d_render/layer_5" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 5. + Optional name for the 2D render layer 5. If left empty, the layer will display as "Layer 5". </member> <member name="layer_names/2d_render/layer_6" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 6. + Optional name for the 2D render layer 6. If left empty, the layer will display as "Layer 6". </member> <member name="layer_names/2d_render/layer_7" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 7. + Optional name for the 2D render layer 7. If left empty, the layer will display as "Layer 7". </member> <member name="layer_names/2d_render/layer_8" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 8. + Optional name for the 2D render layer 8. If left empty, the layer will display as "Layer 8". </member> <member name="layer_names/2d_render/layer_9" type="String" setter="" getter="" default=""""> - Optional name for the 2D render layer 9. + Optional name for the 2D render layer 9. If left empty, the layer will display as "Layer 9". + </member> + <member name="layer_names/3d_physics/layer_0" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 0. If left empty, the layer will display as "Layer 0". </member> <member name="layer_names/3d_physics/layer_1" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 1. + Optional name for the 3D physics layer 1. If left empty, the layer will display as "Layer 1". </member> <member name="layer_names/3d_physics/layer_10" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 10. + Optional name for the 3D physics layer 10. If left empty, the layer will display as "Layer 10". </member> <member name="layer_names/3d_physics/layer_11" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 11. + Optional name for the 3D physics layer 11. If left empty, the layer will display as "Layer 11". </member> <member name="layer_names/3d_physics/layer_12" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 12. + Optional name for the 3D physics layer 12. If left empty, the layer will display as "Layer 12". </member> <member name="layer_names/3d_physics/layer_13" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 13. + Optional name for the 3D physics layer 13. If left empty, the layer will display as "Layer 13". </member> <member name="layer_names/3d_physics/layer_14" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 14. + Optional name for the 3D physics layer 14. If left empty, the layer will display as "Layer 14". </member> <member name="layer_names/3d_physics/layer_15" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 15. + Optional name for the 3D physics layer 15. If left empty, the layer will display as "Layer 15". </member> <member name="layer_names/3d_physics/layer_16" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 16. + Optional name for the 3D physics layer 16. If left empty, the layer will display as "Layer 16". </member> <member name="layer_names/3d_physics/layer_17" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 17. + Optional name for the 3D physics layer 17. If left empty, the layer will display as "Layer 17". </member> <member name="layer_names/3d_physics/layer_18" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 18. + Optional name for the 3D physics layer 18. If left empty, the layer will display as "Layer 18". </member> <member name="layer_names/3d_physics/layer_19" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 19. + Optional name for the 3D physics layer 19. If left empty, the layer will display as "Layer 19". </member> <member name="layer_names/3d_physics/layer_2" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 2. - </member> - <member name="layer_names/3d_physics/layer_20" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 20. + Optional name for the 3D physics layer 2. If left empty, the layer will display as "Layer 2". </member> <member name="layer_names/3d_physics/layer_3" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 3. + Optional name for the 3D physics layer 3. If left empty, the layer will display as "Layer 3". </member> <member name="layer_names/3d_physics/layer_4" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 4. + Optional name for the 3D physics layer 4. If left empty, the layer will display as "Layer 4". </member> <member name="layer_names/3d_physics/layer_5" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 5. + Optional name for the 3D physics layer 5. If left empty, the layer will display as "Layer 5". </member> <member name="layer_names/3d_physics/layer_6" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 6. + Optional name for the 3D physics layer 6. If left empty, the layer will display as "Layer 6". </member> <member name="layer_names/3d_physics/layer_7" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 7. + Optional name for the 3D physics layer 7. If left empty, the layer will display as "Layer 7". </member> <member name="layer_names/3d_physics/layer_8" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 8. + Optional name for the 3D physics layer 8. If left empty, the layer will display as "Layer 8". </member> <member name="layer_names/3d_physics/layer_9" type="String" setter="" getter="" default=""""> - Optional name for the 3D physics layer 9. + Optional name for the 3D physics layer 9. If left empty, the layer will display as "Layer 9". + </member> + <member name="layer_names/3d_render/layer_0" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 0. If left empty, the layer will display as "Layer 0". </member> <member name="layer_names/3d_render/layer_1" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 1. + Optional name for the 3D render layer 1. If left empty, the layer will display as "Layer 1". </member> <member name="layer_names/3d_render/layer_10" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 10. + Optional name for the 3D render layer 10. If left empty, the layer will display as "Layer 10". </member> <member name="layer_names/3d_render/layer_11" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 11. + Optional name for the 3D render layer 11. If left empty, the layer will display as "Layer 11". </member> <member name="layer_names/3d_render/layer_12" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 12. + Optional name for the 3D render layer 12. If left empty, the layer will display as "Layer 12". </member> <member name="layer_names/3d_render/layer_13" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 13. + Optional name for the 3D render layer 13. If left empty, the layer will display as "Layer 13". </member> <member name="layer_names/3d_render/layer_14" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 14 + Optional name for the 3D render layer 14. If left empty, the layer will display as "Layer 14" </member> <member name="layer_names/3d_render/layer_15" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 15. + Optional name for the 3D render layer 15. If left empty, the layer will display as "Layer 15". </member> <member name="layer_names/3d_render/layer_16" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 16. + Optional name for the 3D render layer 16. If left empty, the layer will display as "Layer 16". </member> <member name="layer_names/3d_render/layer_17" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 17. + Optional name for the 3D render layer 17. If left empty, the layer will display as "Layer 17". </member> <member name="layer_names/3d_render/layer_18" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 18. + Optional name for the 3D render layer 18. If left empty, the layer will display as "Layer 18". </member> <member name="layer_names/3d_render/layer_19" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 19. + Optional name for the 3D render layer 19. If left empty, the layer will display as "Layer 19". </member> <member name="layer_names/3d_render/layer_2" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 2. - </member> - <member name="layer_names/3d_render/layer_20" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 20. + Optional name for the 3D render layer 2. If left empty, the layer will display as "Layer 2". </member> <member name="layer_names/3d_render/layer_3" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 3. + Optional name for the 3D render layer 3. If left empty, the layer will display as "Layer 3". </member> <member name="layer_names/3d_render/layer_4" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 4. + Optional name for the 3D render layer 4. If left empty, the layer will display as "Layer 4". </member> <member name="layer_names/3d_render/layer_5" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 5. + Optional name for the 3D render layer 5. If left empty, the layer will display as "Layer 5". </member> <member name="layer_names/3d_render/layer_6" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 6. + Optional name for the 3D render layer 6. If left empty, the layer will display as "Layer 6". </member> <member name="layer_names/3d_render/layer_7" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 7. + Optional name for the 3D render layer 7. If left empty, the layer will display as "Layer 7". </member> <member name="layer_names/3d_render/layer_8" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 8. + Optional name for the 3D render layer 8. If left empty, the layer will display as "Layer 8". </member> <member name="layer_names/3d_render/layer_9" type="String" setter="" getter="" default=""""> - Optional name for the 3D render layer 9. + Optional name for the 3D render layer 9. If left empty, the layer will display as "Layer 9". </member> <member name="locale/fallback" type="String" setter="" getter="" default=""en""> The locale to fall back to if a translation isn't available in a given language. If left empty, [code]en[/code] (English) will be used. @@ -869,6 +869,7 @@ If [code]true[/code], logs all output to files. </member> <member name="logging/file_logging/enable_file_logging.pc" type="bool" setter="" getter="" default="true"> + Desktop override for [member logging/file_logging/enable_file_logging], as log files are not readily accessible on mobile/Web platforms. </member> <member name="logging/file_logging/log_path" type="String" setter="" getter="" default=""user://logs/godot.log""> Path to logs within the project. Using an [code]user://[/code] path is recommended. @@ -1057,6 +1058,8 @@ <member name="rendering/environment/default_environment" type="String" setter="" getter="" default=""""> [Environment] that will be used as a fallback environment in case a scene does not specify its own environment. The default environment is loaded in at scene load time regardless of whether you have set an environment or not. If you do not rely on the fallback environment, it is best to delete [code]default_env.tres[/code], or to specify a different default environment here. </member> + <member name="rendering/forward_renderer/threaded_render_minimum_instances" type="int" setter="" getter="" default="500"> + </member> <member name="rendering/gpu_lightmapper/performance/max_rays_per_pass" type="int" setter="" getter="" default="32"> </member> <member name="rendering/gpu_lightmapper/performance/max_rays_per_probe_pass" type="int" setter="" getter="" default="64"> @@ -1152,6 +1155,12 @@ <member name="rendering/quality/intended_usage/framebuffer_allocation.mobile" type="int" setter="" getter="" default="3"> Lower-end override for [member rendering/quality/intended_usage/framebuffer_allocation] on mobile devices, due to performance concerns or driver support. </member> + <member name="rendering/quality/mesh_lod/threshold_pixels" type="float" setter="" getter="" default="1.0"> + </member> + <member name="rendering/quality/rd_renderer/use_low_end_renderer" type="bool" setter="" getter="" default="false"> + </member> + <member name="rendering/quality/rd_renderer/use_low_end_renderer.mobile" type="bool" setter="" getter="" default="true"> + </member> <member name="rendering/quality/reflection_atlas/reflection_count" type="int" setter="" getter="" default="64"> Number of cubemaps to store in the reflection atlas. The number of [ReflectionProbe]s in a scene will be limited by this amount. A higher number requires more VRAM. </member> @@ -1280,6 +1289,10 @@ </member> <member name="rendering/sdfgi/probe_ray_count" type="int" setter="" getter="" default="2"> </member> + <member name="rendering/spatial_indexer/threaded_cull_minimum_instances" type="int" setter="" getter="" default="1000"> + </member> + <member name="rendering/spatial_indexer/update_iterations_per_frame" type="int" setter="" getter="" default="10"> + </member> <member name="rendering/threads/thread_model" type="int" setter="" getter="" default="1"> Thread model for rendering. Rendering on a thread can vastly improve performance, but synchronizing to the main thread can cause a bit more jitter. </member> diff --git a/doc/classes/Quat.xml b/doc/classes/Quat.xml index 425e82c744..ef83ae7fb9 100644 --- a/doc/classes/Quat.xml +++ b/doc/classes/Quat.xml @@ -127,7 +127,7 @@ <argument index="0" name="to" type="Quat"> </argument> <description> - Returns [code]true[/code] if this quaterion and [code]quat[/code] are approximately equal, by running [method @GDScript.is_equal_approx] on each component. + Returns [code]true[/code] if this quaterion and [code]quat[/code] are approximately equal, by running [method @GlobalScope.is_equal_approx] on each component. </description> </method> <method name="is_normalized"> diff --git a/doc/classes/Rect2.xml b/doc/classes/Rect2.xml index 3d2852f393..5d7ff39587 100644 --- a/doc/classes/Rect2.xml +++ b/doc/classes/Rect2.xml @@ -72,16 +72,6 @@ Returns a [Rect2] with equivalent position and area, modified so that the top-left corner is the origin and [code]width[/code] and [code]height[/code] are positive. </description> </method> - <method name="intersection"> - <return type="Rect2"> - </return> - <argument index="0" name="b" type="Rect2"> - </argument> - <description> - Returns the intersection of this [Rect2] and [code]b[/code]. - If the rectangles do not intersect, an empty [Rect2] is returned. - </description> - </method> <method name="encloses"> <return type="bool"> </return> @@ -134,7 +124,7 @@ <method name="grow_side"> <return type="Rect2"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="side" type="int"> </argument> <argument index="1" name="amount" type="float"> </argument> @@ -158,6 +148,16 @@ Returns [code]true[/code] if the [Rect2] contains a point. </description> </method> + <method name="intersection"> + <return type="Rect2"> + </return> + <argument index="0" name="b" type="Rect2"> + </argument> + <description> + Returns the intersection of this [Rect2] and [code]b[/code]. + If the rectangles do not intersect, an empty [Rect2] is returned. + </description> + </method> <method name="intersects"> <return type="bool"> </return> diff --git a/doc/classes/Rect2i.xml b/doc/classes/Rect2i.xml index 66e5dae78a..e581ccdb11 100644 --- a/doc/classes/Rect2i.xml +++ b/doc/classes/Rect2i.xml @@ -70,16 +70,6 @@ Returns a [Rect2i] with equivalent position and area, modified so that the top-left corner is the origin and [code]width[/code] and [code]height[/code] are positive. </description> </method> - <method name="intersection"> - <return type="Rect2i"> - </return> - <argument index="0" name="b" type="Rect2i"> - </argument> - <description> - Returns the intersection of this [Rect2i] and [code]b[/code]. - If the rectangles do not intersect, an empty [Rect2i] is returned. - </description> - </method> <method name="encloses"> <return type="bool"> </return> @@ -132,7 +122,7 @@ <method name="grow_side"> <return type="Rect2i"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="side" type="int"> </argument> <argument index="1" name="amount" type="int"> </argument> @@ -156,6 +146,16 @@ Returns [code]true[/code] if the [Rect2i] contains a point. </description> </method> + <method name="intersection"> + <return type="Rect2i"> + </return> + <argument index="0" name="b" type="Rect2i"> + </argument> + <description> + Returns the intersection of this [Rect2i] and [code]b[/code]. + If the rectangles do not intersect, an empty [Rect2i] is returned. + </description> + </method> <method name="intersects"> <return type="bool"> </return> diff --git a/doc/classes/Reference.xml b/doc/classes/Reference.xml index 44ee6fbda1..724d2db924 100644 --- a/doc/classes/Reference.xml +++ b/doc/classes/Reference.xml @@ -5,7 +5,7 @@ </brief_description> <description> Base class for any object that keeps a reference count. [Resource] and many other helper objects inherit this class. - Unlike [Object]s, References keep an internal reference counter so that they are automatically released when no longer in use, and only then. References therefore do not need to be freed manually with [method Object.free]. + Unlike other [Object] types, References keep an internal reference counter so that they are automatically released when no longer in use, and only then. References therefore do not need to be freed manually with [method Object.free]. In the vast majority of use cases, instantiating and using [Reference]-derived types is all you need to do. The methods provided in this class are only for advanced users, and can cause issues if misused. [b]Note:[/b] In C#, references will not be freed instantly after they are no longer in use. Instead, garbage collection will run periodically and will free references that are no longer in use. This means that unused references will linger on for a while before being removed. </description> diff --git a/doc/classes/ReflectionProbe.xml b/doc/classes/ReflectionProbe.xml index 5458b496da..cd08778c89 100644 --- a/doc/classes/ReflectionProbe.xml +++ b/doc/classes/ReflectionProbe.xml @@ -37,6 +37,8 @@ <member name="interior" type="bool" setter="set_as_interior" getter="is_set_as_interior" default="false"> If [code]true[/code], reflections will ignore sky contribution. </member> + <member name="lod_threshold" type="float" setter="set_lod_threshold" getter="get_lod_threshold" default="1.0"> + </member> <member name="max_distance" type="float" setter="set_max_distance" getter="get_max_distance" default="0.0"> Sets the max distance away from the probe an object can be before it is culled. </member> diff --git a/doc/classes/RenderingDevice.xml b/doc/classes/RenderingDevice.xml index 7e5df9c40d..7cdc9ffaca 100644 --- a/doc/classes/RenderingDevice.xml +++ b/doc/classes/RenderingDevice.xml @@ -730,6 +730,8 @@ </argument> <argument index="1" name="data" type="PackedByteArray" default="PackedByteArray( )"> </argument> + <argument index="2" name="use_as_storage" type="bool" default="false"> + </argument> <description> </description> </method> diff --git a/doc/classes/RenderingServer.xml b/doc/classes/RenderingServer.xml index 036b50f0ed..4be97b7d3d 100644 --- a/doc/classes/RenderingServer.xml +++ b/doc/classes/RenderingServer.xml @@ -859,6 +859,12 @@ Tries to free an object in the RenderingServer. </description> </method> + <method name="get_frame_setup_time_cpu" qualifiers="const"> + <return type="float"> + </return> + <description> + </description> + </method> <method name="get_render_info"> <return type="int"> </return> @@ -1354,7 +1360,7 @@ <argument index="1" name="scenario" type="RID"> </argument> <description> - Returns an array of object IDs intersecting with the provided AABB. Only visual 3D nodes are considered, such as [MeshInstance3D] or [DirectionalLight3D]. Use [method @GDScript.instance_from_id] to obtain the actual nodes. A scenario RID must be provided, which is available in the [World3D] you want to query. This forces an update for all resources queued to update. + Returns an array of object IDs intersecting with the provided AABB. Only visual 3D nodes are considered, such as [MeshInstance3D] or [DirectionalLight3D]. Use [method @GlobalScope.instance_from_id] to obtain the actual nodes. A scenario RID must be provided, which is available in the [World3D] you want to query. This forces an update for all resources queued to update. [b]Warning:[/b] This function is primarily intended for editor usage. For in-game use cases, prefer physics collision. </description> </method> @@ -1366,7 +1372,7 @@ <argument index="1" name="scenario" type="RID"> </argument> <description> - Returns an array of object IDs intersecting with the provided convex shape. Only visual 3D nodes are considered, such as [MeshInstance3D] or [DirectionalLight3D]. Use [method @GDScript.instance_from_id] to obtain the actual nodes. A scenario RID must be provided, which is available in the [World3D] you want to query. This forces an update for all resources queued to update. + Returns an array of object IDs intersecting with the provided convex shape. Only visual 3D nodes are considered, such as [MeshInstance3D] or [DirectionalLight3D]. Use [method @GlobalScope.instance_from_id] to obtain the actual nodes. A scenario RID must be provided, which is available in the [World3D] you want to query. This forces an update for all resources queued to update. [b]Warning:[/b] This function is primarily intended for editor usage. For in-game use cases, prefer physics collision. </description> </method> @@ -1380,7 +1386,7 @@ <argument index="2" name="scenario" type="RID"> </argument> <description> - Returns an array of object IDs intersecting with the provided 3D ray. Only visual 3D nodes are considered, such as [MeshInstance3D] or [DirectionalLight3D]. Use [method @GDScript.instance_from_id] to obtain the actual nodes. A scenario RID must be provided, which is available in the [World3D] you want to query. This forces an update for all resources queued to update. + Returns an array of object IDs intersecting with the provided 3D ray. Only visual 3D nodes are considered, such as [MeshInstance3D] or [DirectionalLight3D]. Use [method @GlobalScope.instance_from_id] to obtain the actual nodes. A scenario RID must be provided, which is available in the [World3D] you want to query. This forces an update for all resources queued to update. [b]Warning:[/b] This function is primarily intended for editor usage. For in-game use cases, prefer physics collision. </description> </method> @@ -2715,6 +2721,22 @@ Once finished with your RID, you will want to free the RID using the RenderingServer's [method free_rid] static method. </description> </method> + <method name="viewport_get_measured_render_time_cpu" qualifiers="const"> + <return type="float"> + </return> + <argument index="0" name="viewport" type="RID"> + </argument> + <description> + </description> + </method> + <method name="viewport_get_measured_render_time_gpu" qualifiers="const"> + <return type="float"> + </return> + <argument index="0" name="viewport" type="RID"> + </argument> + <description> + </description> + </method> <method name="viewport_get_render_info"> <return type="int"> </return> @@ -2852,6 +2874,16 @@ Currently unimplemented in Godot 3.x. </description> </method> + <method name="viewport_set_measure_render_time"> + <return type="void"> + </return> + <argument index="0" name="viewport" type="RID"> + </argument> + <argument index="1" name="enable" type="bool"> + </argument> + <description> + </description> + </method> <method name="viewport_set_msaa"> <return type="void"> </return> diff --git a/doc/classes/Resource.xml b/doc/classes/Resource.xml index 54984b7785..a9697c7fce 100644 --- a/doc/classes/Resource.xml +++ b/doc/classes/Resource.xml @@ -4,7 +4,7 @@ Base class for all resources. </brief_description> <description> - Resource is the base class for all Godot-specific resource types, serving primarily as data containers. Unlike [Object]s, they are reference-counted and freed when no longer in use. They are also cached once loaded from disk, so that any further attempts to load a resource from a given path will return the same reference (all this in contrast to a [Node], which is not reference-counted and can be instanced from disk as many times as desired). Resources can be saved externally on disk or bundled into another object, such as a [Node] or another resource. + Resource is the base class for all Godot-specific resource types, serving primarily as data containers. Since they inherit from [Reference], resources are reference-counted and freed when no longer in use. They are also cached once loaded from disk, so that any further attempts to load a resource from a given path will return the same reference (all this in contrast to a [Node], which is not reference-counted and can be instanced from disk as many times as desired). Resources can be saved externally on disk or bundled into another object, such as a [Node] or another resource. [b]Note:[/b] In C#, resources will not be freed instantly after they are no longer in use. Instead, garbage collection will run periodically and will free resources that are no longer in use. This means that unused resources will linger on for a while before being removed. </description> <tutorials> @@ -29,6 +29,19 @@ [b]Note:[/b] If [code]subresources[/code] is [code]true[/code], this method will only perform a shallow copy. Nested resources within subresources will not be duplicated and will still be shared. </description> </method> + <method name="emit_changed"> + <return type="void"> + </return> + <description> + Emits the [signal changed] signal. + If external objects which depend on this resource should be updated, this method must be called manually whenever the state of this resource has changed (such as modification of properties). + The method is equivalent to: + [codeblock] + emit_signal("changed") + [/codeblock] + [b]Note:[/b] This method is called automatically for built-in resources. + </description> + </method> <method name="get_local_scene" qualifiers="const"> <return type="Node"> </return> diff --git a/doc/classes/RichTextLabel.xml b/doc/classes/RichTextLabel.xml index 147e41bf1b..a182abc17b 100644 --- a/doc/classes/RichTextLabel.xml +++ b/doc/classes/RichTextLabel.xml @@ -455,6 +455,7 @@ </member> <member name="visible_characters" type="int" setter="set_visible_characters" getter="get_visible_characters" default="-1"> The restricted number of characters to display in the label. If [code]-1[/code], all characters will be displayed. + [b]Note:[/b] Setting this property updates [member percent_visible] based on current [method get_total_character_count]. </member> </members> <signals> diff --git a/doc/classes/RigidBody2D.xml b/doc/classes/RigidBody2D.xml index 2a0b44f3f3..6b27c77f26 100644 --- a/doc/classes/RigidBody2D.xml +++ b/doc/classes/RigidBody2D.xml @@ -180,14 +180,16 @@ <argument index="0" name="body" type="Node"> </argument> <description> - Emitted when a body enters into contact with this one. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. + Emitted when a collision with another [PhysicsBody2D] or [TileMap] occurs. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. [TileMap]s are detected if the [TileSet] has Collision [Shape2D]s. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody2D] or [TileMap]. </description> </signal> <signal name="body_exited"> <argument index="0" name="body" type="Node"> </argument> <description> - Emitted when a body exits contact with this one. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. + Emitted when the collision with another [PhysicsBody2D] or [TileMap] ends. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. [TileMap]s are detected if the [TileSet] has Collision [Shape2D]s. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody2D] or [TileMap]. </description> </signal> <signal name="body_shape_entered"> @@ -200,7 +202,11 @@ <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when a body enters into contact with this one. Reports colliding shape information. See [CollisionObject2D] for shape index information. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. + Emitted when one of this RigidBody2D's [Shape2D]s collides with another [PhysicsBody2D] or [TileMap]'s [Shape2D]s. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. [TileMap]s are detected if the [TileSet] has Collision [Shape2D]s. + [code]body_id[/code] the [RID] of the other [PhysicsBody2D] or [TileSet]'s [CollisionObject2D] used by the [PhysicsServer2D]. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody2D] or [TileMap]. + [code]body_shape[/code] the index of the [Shape2D] of the other [PhysicsBody2D] or [TileMap] used by the [PhysicsServer2D]. + [code]local_shape[/code] the index of the [Shape2D] of this RigidBody2D used by the [PhysicsServer2D]. </description> </signal> <signal name="body_shape_exited"> @@ -213,7 +219,11 @@ <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when a body shape exits contact with this one. Reports colliding shape information. See [CollisionObject2D] for shape index information. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. + Emitted when the collision between one of this RigidBody2D's [Shape2D]s and another [PhysicsBody2D] or [TileMap]'s [Shape2D]s ends. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. [TileMap]s are detected if the [TileSet] has Collision [Shape2D]s. + [code]body_id[/code] the [RID] of the other [PhysicsBody2D] or [TileSet]'s [CollisionObject2D] used by the [PhysicsServer2D]. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody2D] or [TileMap]. + [code]body_shape[/code] the index of the [Shape2D] of the other [PhysicsBody2D] or [TileMap] used by the [PhysicsServer2D]. + [code]local_shape[/code] the index of the [Shape2D] of this RigidBody2D used by the [PhysicsServer2D]. </description> </signal> <signal name="sleeping_state_changed"> diff --git a/doc/classes/RigidBody3D.xml b/doc/classes/RigidBody3D.xml index b4171d36fc..1c6c8852a9 100644 --- a/doc/classes/RigidBody3D.xml +++ b/doc/classes/RigidBody3D.xml @@ -204,14 +204,16 @@ <argument index="0" name="body" type="Node"> </argument> <description> - Emitted when a body enters into contact with this one. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. + Emitted when a collision with another [PhysicsBody3D] or [GridMap] occurs. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. [GridMap]s are detected if the [MeshLibrary] has Collision [Shape3D]s. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody3D] or [GridMap]. </description> </signal> <signal name="body_exited"> <argument index="0" name="body" type="Node"> </argument> <description> - Emitted when a body shape exits contact with this one. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. + Emitted when the collision with another [PhysicsBody3D] or [GridMap] ends. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. [GridMap]s are detected if the [MeshLibrary] has Collision [Shape3D]s. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody3D] or [GridMap]. </description> </signal> <signal name="body_shape_entered"> @@ -224,8 +226,11 @@ <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when a body enters into contact with this one. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. - This signal not only receives the body that collided with this one, but also its [RID] ([code]body_id[/code]), the shape index from the colliding body ([code]body_shape[/code]), and the shape index from this body ([code]local_shape[/code]) the other body collided with. + Emitted when one of this RigidBody3D's [Shape3D]s collides with another [PhysicsBody3D] or [GridMap]'s [Shape3D]s. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. [GridMap]s are detected if the [MeshLibrary] has Collision [Shape3D]s. + [code]body_id[/code] the [RID] of the other [PhysicsBody3D] or [MeshLibrary]'s [CollisionObject3D] used by the [PhysicsServer3D]. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody3D] or [GridMap]. + [code]body_shape[/code] the index of the [Shape3D] of the other [PhysicsBody3D] or [GridMap] used by the [PhysicsServer3D]. + [code]local_shape[/code] the index of the [Shape3D] of this RigidBody3D used by the [PhysicsServer3D]. [b]Note:[/b] Bullet physics cannot identify the shape index when using a [ConcavePolygonShape3D]. Don't use multiple [CollisionShape3D]s when using a [ConcavePolygonShape3D] with Bullet physics if you need shape indices. </description> </signal> @@ -239,8 +244,11 @@ <argument index="3" name="local_shape" type="int"> </argument> <description> - Emitted when a body shape exits contact with this one. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. - This signal not only receives the body that stopped colliding with this one, but also its [RID] ([code]body_id[/code]), the shape index from the colliding body ([code]body_shape[/code]), and the shape index from this body ([code]local_shape[/code]) the other body stopped colliding with. + Emitted when the collision between one of this RigidBody3D's [Shape3D]s and another [PhysicsBody3D] or [GridMap]'s [Shape3D]s ends. Requires [member contact_monitor] to be set to [code]true[/code] and [member contacts_reported] to be set high enough to detect all the collisions. [GridMap]s are detected if the [MeshLibrary] has Collision [Shape3D]s. + [code]body_id[/code] the [RID] of the other [PhysicsBody3D] or [MeshLibrary]'s [CollisionObject3D] used by the [PhysicsServer3D]. [GridMap]s are detected if the Meshes have [Shape3D]s. + [code]body[/code] the [Node], if it exists in the tree, of the other [PhysicsBody3D] or [GridMap]. + [code]body_shape[/code] the index of the [Shape3D] of the other [PhysicsBody3D] or [GridMap] used by the [PhysicsServer3D]. + [code]local_shape[/code] the index of the [Shape3D] of this RigidBody3D used by the [PhysicsServer3D]. [b]Note:[/b] Bullet physics cannot identify the shape index when using a [ConcavePolygonShape3D]. Don't use multiple [CollisionShape3D]s when using a [ConcavePolygonShape3D] with Bullet physics if you need shape indices. </description> </signal> diff --git a/doc/classes/SceneTree.xml b/doc/classes/SceneTree.xml index 5fc1d0b895..2c99815abf 100644 --- a/doc/classes/SceneTree.xml +++ b/doc/classes/SceneTree.xml @@ -260,7 +260,7 @@ The default [MultiplayerAPI] instance for this [SceneTree]. </member> <member name="multiplayer_poll" type="bool" setter="set_multiplayer_poll_enabled" getter="is_multiplayer_poll_enabled" default="true"> - If [code]true[/code] (default value), enables automatic polling of the [MultiplayerAPI] for this SceneTree during [signal idle_frame]. + If [code]true[/code] (default value), enables automatic polling of the [MultiplayerAPI] for this SceneTree during [signal process_frame]. If [code]false[/code], you need to manually call [method MultiplayerAPI.poll] to process network packets and deliver RPCs/RSETs. This allows running RPCs/RSETs in a different loop (e.g. physics, thread, specific time step) and for manual [Mutex] protection when accessing the [MultiplayerAPI] from threads. </member> <member name="network_peer" type="NetworkedMultiplayerPeer" setter="set_network_peer" getter="get_network_peer"> @@ -298,11 +298,6 @@ Emitted when files are dragged from the OS file manager and dropped in the game window. The arguments are a list of file paths and the identifier of the screen where the drag originated. </description> </signal> - <signal name="idle_frame"> - <description> - Emitted immediately before [method Node._process] is called on every node in the [SceneTree]. - </description> - </signal> <signal name="network_peer_connected"> <argument index="0" name="id" type="int"> </argument> @@ -350,6 +345,11 @@ Emitted immediately before [method Node._physics_process] is called on every node in the [SceneTree]. </description> </signal> + <signal name="process_frame"> + <description> + Emitted immediately before [method Node._process] is called on every node in the [SceneTree]. + </description> + </signal> <signal name="server_disconnected"> <description> Emitted whenever this [SceneTree]'s [member network_peer] disconnected from server. Only emitted on clients. diff --git a/doc/classes/String.xml b/doc/classes/String.xml index cbaf1196e3..fcc70d166e 100644 --- a/doc/classes/String.xml +++ b/doc/classes/String.xml @@ -135,13 +135,6 @@ Returns a copy of the string with indentation (leading tabs and spaces) removed. </description> </method> - <method name="is_empty"> - <return type="bool"> - </return> - <description> - Returns [code]true[/code] if the length of the string equals [code]0[/code]. - </description> - </method> <method name="ends_with"> <return type="bool"> </return> @@ -276,6 +269,13 @@ If the string is a path to a file or directory, returns [code]true[/code] if the path is absolute. </description> </method> + <method name="is_empty"> + <return type="bool"> + </return> + <description> + Returns [code]true[/code] if the length of the string equals [code]0[/code]. + </description> + </method> <method name="is_rel_path"> <return type="bool"> </return> @@ -406,7 +406,8 @@ <argument index="0" name="chars" type="String"> </argument> <description> - Returns a copy of the string with characters removed from the left. + Returns a copy of the string with characters removed from the left. The [code]chars[/code] argument is a string specifying the set of characters to be removed. + [b]Note:[/b] The [code]chars[/code] is not a prefix. See [method trim_prefix] method that will remove a single prefix string rather than a set of characters. </description> </method> <method name="match"> @@ -698,7 +699,8 @@ <argument index="0" name="chars" type="String"> </argument> <description> - Returns a copy of the string with characters removed from the right. + Returns a copy of the string with characters removed from the right. The [code]chars[/code] argument is a string specifying the set of characters to be removed. + [b]Note:[/b] The [code]chars[/code] is not a suffix. See [method trim_suffix] method that will remove a single suffix string rather than a set of characters. </description> </method> <method name="sha1_buffer"> diff --git a/doc/classes/StyleBox.xml b/doc/classes/StyleBox.xml index 525dba0549..a01dfbd4b8 100644 --- a/doc/classes/StyleBox.xml +++ b/doc/classes/StyleBox.xml @@ -39,7 +39,7 @@ <method name="get_default_margin" qualifiers="const"> <return type="float"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <description> Returns the default margin of the specified [enum Side]. @@ -48,7 +48,7 @@ <method name="get_margin" qualifiers="const"> <return type="float"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <description> Returns the content margin offset for the specified [enum Side]. @@ -72,7 +72,7 @@ <method name="set_default_margin"> <return type="void"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <argument index="1" name="offset" type="float"> </argument> diff --git a/doc/classes/StyleBoxFlat.xml b/doc/classes/StyleBoxFlat.xml index 71f227dfb0..13ea7df294 100644 --- a/doc/classes/StyleBoxFlat.xml +++ b/doc/classes/StyleBoxFlat.xml @@ -27,7 +27,7 @@ <method name="get_border_width" qualifiers="const"> <return type="int"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <description> Returns the specified [enum Side]'s border width. @@ -52,7 +52,7 @@ <method name="get_expand_margin" qualifiers="const"> <return type="float"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <description> Returns the size of the specified [enum Side]'s expand margin. @@ -61,7 +61,7 @@ <method name="set_border_width"> <return type="void"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <argument index="1" name="width" type="int"> </argument> @@ -116,7 +116,7 @@ <method name="set_expand_margin"> <return type="void"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <argument index="1" name="size" type="float"> </argument> diff --git a/doc/classes/StyleBoxTexture.xml b/doc/classes/StyleBoxTexture.xml index 5b17f25978..895d0c357d 100644 --- a/doc/classes/StyleBoxTexture.xml +++ b/doc/classes/StyleBoxTexture.xml @@ -12,7 +12,7 @@ <method name="get_expand_margin_size" qualifiers="const"> <return type="float"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <description> Returns the expand margin size of the specified [enum Side]. @@ -21,7 +21,7 @@ <method name="get_margin_size" qualifiers="const"> <return type="float"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <description> Returns the margin size of the specified [enum Side]. @@ -54,7 +54,7 @@ <method name="set_expand_margin_size"> <return type="void"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <argument index="1" name="size" type="float"> </argument> @@ -65,7 +65,7 @@ <method name="set_margin_size"> <return type="void"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <argument index="1" name="size" type="float"> </argument> diff --git a/doc/classes/SurfaceTool.xml b/doc/classes/SurfaceTool.xml index 82ffe86251..e10b65e309 100644 --- a/doc/classes/SurfaceTool.xml +++ b/doc/classes/SurfaceTool.xml @@ -31,15 +31,6 @@ Adds an index to index array if you are using indexed vertices. Does not need to be called before adding vertices. </description> </method> - <method name="add_smooth_group"> - <return type="void"> - </return> - <argument index="0" name="smooth" type="bool"> - </argument> - <description> - Specifies whether the current vertex (if using only vertex arrays) or current index (if also using index arrays) should use smooth normals for normal calculation. - </description> - </method> <method name="add_triangle_fan"> <return type="void"> </return> @@ -148,6 +139,16 @@ Removes the index array by expanding the vertex array. </description> </method> + <method name="generate_lod"> + <return type="PackedInt32Array"> + </return> + <argument index="0" name="nd_threshold" type="float"> + </argument> + <argument index="1" name="target_index_count" type="int" default="3"> + </argument> + <description> + </description> + </method> <method name="generate_normals"> <return type="void"> </return> @@ -173,6 +174,12 @@ <description> </description> </method> + <method name="get_max_axis_length" qualifiers="const"> + <return type="float"> + </return> + <description> + </description> + </method> <method name="get_skin_weight_count" qualifiers="const"> <return type="int" enum="SurfaceTool.SkinWeightCount"> </return> @@ -186,6 +193,12 @@ Shrinks the vertex array by creating an index array (avoids reusing vertices). </description> </method> + <method name="optimize_indices_for_cache"> + <return type="void"> + </return> + <description> + </description> + </method> <method name="set_bones"> <return type="void"> </return> @@ -251,6 +264,15 @@ <description> </description> </method> + <method name="set_smooth_group"> + <return type="void"> + </return> + <argument index="0" name="index" type="int"> + </argument> + <description> + Specifies whether the current vertex (if using only vertex arrays) or current index (if also using index arrays) should use smooth normals for normal calculation. + </description> + </method> <method name="set_tangent"> <return type="void"> </return> diff --git a/doc/classes/TabContainer.xml b/doc/classes/TabContainer.xml index c9ed1aaec9..10cdd0eade 100644 --- a/doc/classes/TabContainer.xml +++ b/doc/classes/TabContainer.xml @@ -137,6 +137,9 @@ </method> </methods> <members> + <member name="all_tabs_in_front" type="bool" setter="set_all_tabs_in_front" getter="is_all_tabs_in_front" default="false"> + If [code]true[/code], all tabs are drawn in front of the panel. If [code]false[/code], inactive tabs are drawn behind the panel. + </member> <member name="current_tab" type="int" setter="set_current_tab" getter="get_current_tab" default="0"> The current tab index. When set, this index's [Control] node's [code]visible[/code] property is set to [code]true[/code] and all others are set to [code]false[/code]. </member> @@ -149,9 +152,6 @@ <member name="tabs_visible" type="bool" setter="set_tabs_visible" getter="are_tabs_visible" default="true"> If [code]true[/code], tabs are visible. If [code]false[/code], tabs' content and titles are hidden. </member> - <member name="all_tabs_in_front" type="bool" setter="set_all_tabs_in_front" getter="is_all_tabs_in_front" default="false"> - If [code]true[/code], all tabs are drawn in front of the panel. If [code]false[/code], inactive tabs are drawn behind the panel. - </member> <member name="use_hidden_tabs_for_min_size" type="bool" setter="set_use_hidden_tabs_for_min_size" getter="get_use_hidden_tabs_for_min_size" default="false"> If [code]true[/code], children [Control] nodes that are hidden have their minimum size take into account in the total, instead of only the currently visible one. </member> diff --git a/doc/classes/TextureProgressBar.xml b/doc/classes/TextureProgressBar.xml index cfc8f16648..b40759578f 100644 --- a/doc/classes/TextureProgressBar.xml +++ b/doc/classes/TextureProgressBar.xml @@ -12,7 +12,7 @@ <method name="get_stretch_margin" qualifiers="const"> <return type="int"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <description> </description> @@ -20,7 +20,7 @@ <method name="set_stretch_margin"> <return type="void"> </return> - <argument index="0" name="side" type="int" enum="Side"> + <argument index="0" name="margin" type="int" enum="Side"> </argument> <argument index="1" name="value" type="int"> </argument> diff --git a/doc/classes/UndoRedo.xml b/doc/classes/UndoRedo.xml index 2cc3e974e2..0e4a76a1a9 100644 --- a/doc/classes/UndoRedo.xml +++ b/doc/classes/UndoRedo.xml @@ -110,8 +110,10 @@ <method name="commit_action"> <return type="void"> </return> + <argument index="0" name="execute" type="bool" default="true"> + </argument> <description> - Commit the action. All "do" methods/properties are called/set when this function is called. + Commit the action. If [code]execute[/code] is true (default), all "do" methods/properties are called/set when this function is called. </description> </method> <method name="create_action"> @@ -126,11 +128,34 @@ The way actions are merged is dictated by the [code]merge_mode[/code] argument. See [enum MergeMode] for details. </description> </method> + <method name="get_action_name"> + <return type="String"> + </return> + <argument index="0" name="arg0" type="int"> + </argument> + <description> + Gets the action name from its index. + </description> + </method> + <method name="get_current_action"> + <return type="int"> + </return> + <description> + Gets the index of the current action. + </description> + </method> <method name="get_current_action_name" qualifiers="const"> <return type="String"> </return> <description> - Gets the name of the current action. + Gets the name of the current action, equivalent to [code]get_action_name(get_current_action())[/code]. + </description> + </method> + <method name="get_history_count"> + <return type="int"> + </return> + <description> + Return how many element are in the history. </description> </method> <method name="get_version" qualifiers="const"> diff --git a/doc/classes/Variant.xml b/doc/classes/Variant.xml index cd76689ffe..775bd58bcf 100644 --- a/doc/classes/Variant.xml +++ b/doc/classes/Variant.xml @@ -17,7 +17,7 @@ - VisualScript tracks properties inside Variants as well, but it also uses static typing. The GUI interface enforces that properties have a particular type that doesn't change over time. - C# is statically typed, but uses the Mono [code]object[/code] type in place of Godot's Variant class when it needs to represent a dynamic value. [code]object[/code] is the Mono runtime's equivalent of the same concept. - The statically-typed language NativeScript C++ does not define a built-in Variant-like class. Godot's GDNative bindings provide their own godot::Variant class for users; Any point at which the C++ code starts interacting with the Godot runtime is a place where you might have to start wrapping data inside Variant objects. - The global [method @GDScript.typeof] function returns the enumerated value of the Variant type stored in the current variable (see [enum Variant.Type]). + The global [method @GlobalScope.typeof] function returns the enumerated value of the Variant type stored in the current variable (see [enum Variant.Type]). [codeblock] var foo = 2 match typeof(foo): diff --git a/doc/classes/Vector2.xml b/doc/classes/Vector2.xml index fef2d7cedd..4159a38d96 100644 --- a/doc/classes/Vector2.xml +++ b/doc/classes/Vector2.xml @@ -66,7 +66,7 @@ <description> Returns this vector's angle with respect to the positive X axis, or [code](1, 0)[/code] vector, in radians. For example, [code]Vector2.RIGHT.angle()[/code] will return zero, [code]Vector2.DOWN.angle()[/code] will return [code]PI / 2[/code] (a quarter turn, or 90 degrees), and [code]Vector2(1, -1).angle()[/code] will return [code]-PI / 4[/code] (a negative eighth turn, or -45 degrees). - Equivalent to the result of [method @GDScript.atan2] when called with the vector's [member y] and [member x] as parameters: [code]atan2(y, x)[/code]. + Equivalent to the result of [method @GlobalScope.atan2] when called with the vector's [member y] and [member x] as parameters: [code]atan2(y, x)[/code]. </description> </method> <method name="angle_to"> @@ -196,7 +196,7 @@ <argument index="0" name="to" type="Vector2"> </argument> <description> - Returns [code]true[/code] if this vector and [code]v[/code] are approximately equal, by running [method @GDScript.is_equal_approx] on each component. + Returns [code]true[/code] if this vector and [code]v[/code] are approximately equal, by running [method @GlobalScope.is_equal_approx] on each component. </description> </method> <method name="is_normalized"> @@ -390,13 +390,20 @@ <description> </description> </method> + <method name="orthogonal"> + <return type="Vector2"> + </return> + <description> + Returns a perpendicular vector rotated 90 degrees counter-clockwise compared to the original, with the same length. + </description> + </method> <method name="posmod"> <return type="Vector2"> </return> <argument index="0" name="mod" type="float"> </argument> <description> - Returns a vector composed of the [method @GDScript.fposmod] of this vector's components and [code]mod[/code]. + Returns a vector composed of the [method @GlobalScope.fposmod] of this vector's components and [code]mod[/code]. </description> </method> <method name="posmodv"> @@ -405,7 +412,7 @@ <argument index="0" name="modv" type="Vector2"> </argument> <description> - Returns a vector composed of the [method @GDScript.fposmod] of this vector's components and [code]modv[/code]'s components. + Returns a vector composed of the [method @GlobalScope.fposmod] of this vector's components and [code]modv[/code]'s components. </description> </method> <method name="project"> @@ -432,7 +439,7 @@ <argument index="0" name="phi" type="float"> </argument> <description> - Returns the vector rotated by [code]phi[/code] radians. See also [method @GDScript.deg2rad]. + Returns the vector rotated by [code]phi[/code] radians. See also [method @GlobalScope.deg2rad]. </description> </method> <method name="round"> @@ -446,7 +453,7 @@ <return type="Vector2"> </return> <description> - Returns the vector with each component set to one or negative one, depending on the signs of the components, or zero if the component is zero, by calling [method @GDScript.sign] on each component. + Returns the vector with each component set to one or negative one, depending on the signs of the components, or zero if the component is zero, by calling [method @GlobalScope.sign] on each component. </description> </method> <method name="slerp"> @@ -479,13 +486,6 @@ Returns this vector with each component snapped to the nearest multiple of [code]step[/code]. This can also be used to round to an arbitrary number of decimals. </description> </method> - <method name="orthogonal"> - <return type="Vector2"> - </return> - <description> - Returns a perpendicular vector rotated 90 degrees counter-clockwise compared to the original, with the same length. - </description> - </method> </methods> <members> <member name="x" type="float" setter="" getter="" default="0.0"> diff --git a/doc/classes/Vector3.xml b/doc/classes/Vector3.xml index 46fd45f85f..2d129a2c86 100644 --- a/doc/classes/Vector3.xml +++ b/doc/classes/Vector3.xml @@ -171,7 +171,7 @@ <argument index="0" name="to" type="Vector3"> </argument> <description> - Returns [code]true[/code] if this vector and [code]v[/code] are approximately equal, by running [method @GDScript.is_equal_approx] on each component. + Returns [code]true[/code] if this vector and [code]v[/code] are approximately equal, by running [method @GlobalScope.is_equal_approx] on each component. </description> </method> <method name="is_normalized"> @@ -410,7 +410,7 @@ <argument index="0" name="mod" type="float"> </argument> <description> - Returns a vector composed of the [method @GDScript.fposmod] of this vector's components and [code]mod[/code]. + Returns a vector composed of the [method @GlobalScope.fposmod] of this vector's components and [code]mod[/code]. </description> </method> <method name="posmodv"> @@ -419,7 +419,7 @@ <argument index="0" name="modv" type="Vector3"> </argument> <description> - Returns a vector composed of the [method @GDScript.fposmod] of this vector's components and [code]modv[/code]'s components. + Returns a vector composed of the [method @GlobalScope.fposmod] of this vector's components and [code]modv[/code]'s components. </description> </method> <method name="project"> @@ -462,7 +462,7 @@ <return type="Vector3"> </return> <description> - Returns a vector with each component set to one or negative one, depending on the signs of this vector's components, or zero if the component is zero, by calling [method @GDScript.sign] on each component. + Returns a vector with each component set to one or negative one, depending on the signs of this vector's components, or zero if the component is zero, by calling [method @GlobalScope.sign] on each component. </description> </method> <method name="slerp"> diff --git a/doc/classes/Viewport.xml b/doc/classes/Viewport.xml index 7b513d56c3..e66b8353a8 100644 --- a/doc/classes/Viewport.xml +++ b/doc/classes/Viewport.xml @@ -222,6 +222,8 @@ </member> <member name="handle_input_locally" type="bool" setter="set_handle_input_locally" getter="is_handling_input_locally" default="true"> </member> + <member name="lod_threshold" type="float" setter="set_lod_threshold" getter="get_lod_threshold" default="1.0"> + </member> <member name="msaa" type="int" setter="set_msaa" getter="get_msaa" enum="Viewport.MSAA" default="0"> The multisample anti-aliasing mode. A higher number results in smoother edges at the cost of significantly worse performance. A value of 4 is best unless targeting very high-end systems. </member> @@ -405,6 +407,8 @@ </constant> <constant name="DEBUG_DRAW_GI_BUFFER" value="17" enum="DebugDraw"> </constant> + <constant name="DEBUG_DRAW_DISABLE_LOD" value="18" enum="DebugDraw"> + </constant> <constant name="DEFAULT_CANVAS_ITEM_TEXTURE_FILTER_NEAREST" value="0" enum="DefaultCanvasItemTextureFilter"> The texture filter reads from the nearest pixel only. The simplest and fastest method of filtering, but the texture will look pixelized. </constant> diff --git a/doc/classes/WeakRef.xml b/doc/classes/WeakRef.xml index 07d82289a3..4140df5828 100644 --- a/doc/classes/WeakRef.xml +++ b/doc/classes/WeakRef.xml @@ -4,7 +4,7 @@ Holds an [Object], but does not contribute to the reference count if the object is a reference. </brief_description> <description> - A weakref can hold a [Reference], without contributing to the reference counter. A weakref can be created from an [Object] using [method @GDScript.weakref]. If this object is not a reference, weakref still works, however, it does not have any effect on the object. Weakrefs are useful in cases where multiple classes have variables that refer to each other. Without weakrefs, using these classes could lead to memory leaks, since both references keep each other from being released. Making part of the variables a weakref can prevent this cyclic dependency, and allows the references to be released. + A weakref can hold a [Reference], without contributing to the reference counter. A weakref can be created from an [Object] using [method @GlobalScope.weakref]. If this object is not a reference, weakref still works, however, it does not have any effect on the object. Weakrefs are useful in cases where multiple classes have variables that refer to each other. Without weakrefs, using these classes could lead to memory leaks, since both references keep each other from being released. Making part of the variables a weakref can prevent this cyclic dependency, and allows the references to be released. </description> <tutorials> </tutorials> diff --git a/doc/classes/XRController3D.xml b/doc/classes/XRController3D.xml index 345e5efdee..a4a86cc22a 100644 --- a/doc/classes/XRController3D.xml +++ b/doc/classes/XRController3D.xml @@ -19,13 +19,6 @@ If active, returns the name of the associated controller if provided by the AR/VR SDK used. </description> </method> - <method name="get_tracker_hand" qualifiers="const"> - <return type="int" enum="XRPositionalTracker.TrackerHand"> - </return> - <description> - Returns the hand holding this controller, if known. See [enum XRPositionalTracker.TrackerHand]. - </description> - </method> <method name="get_is_active" qualifiers="const"> <return type="bool"> </return> @@ -56,6 +49,13 @@ If provided by the [XRInterface], this returns a mesh associated with the controller. This can be used to visualize the controller. </description> </method> + <method name="get_tracker_hand" qualifiers="const"> + <return type="int" enum="XRPositionalTracker.TrackerHand"> + </return> + <description> + Returns the hand holding this controller, if known. See [enum XRPositionalTracker.TrackerHand]. + </description> + </method> <method name="is_button_pressed" qualifiers="const"> <return type="bool"> </return> diff --git a/doc/classes/XRPositionalTracker.xml b/doc/classes/XRPositionalTracker.xml index 36ff312e4d..36cd6e2ea0 100644 --- a/doc/classes/XRPositionalTracker.xml +++ b/doc/classes/XRPositionalTracker.xml @@ -12,13 +12,6 @@ <link title="VR tutorial index">https://docs.godotengine.org/en/latest/tutorials/vr/index.html</link> </tutorials> <methods> - <method name="get_tracker_hand" qualifiers="const"> - <return type="int" enum="XRPositionalTracker.TrackerHand"> - </return> - <description> - Returns the hand holding this tracker, if known. See [enum TrackerHand] constants. - </description> - </method> <method name="get_joy_id" qualifiers="const"> <return type="int"> </return> @@ -47,6 +40,13 @@ Returns the world-space controller position. </description> </method> + <method name="get_tracker_hand" qualifiers="const"> + <return type="int" enum="XRPositionalTracker.TrackerHand"> + </return> + <description> + Returns the hand holding this tracker, if known. See [enum TrackerHand] constants. + </description> + </method> <method name="get_tracker_id" qualifiers="const"> <return type="int"> </return> @@ -68,6 +68,15 @@ Returns the tracker's type, which will be one of the values from the [enum XRServer.TrackerType] enum. </description> </method> + <method name="get_transform" qualifiers="const"> + <return type="Transform"> + </return> + <argument index="0" name="adjust_by_reference_frame" type="bool"> + </argument> + <description> + Returns the transform combining this device's orientation and position. + </description> + </method> <method name="is_tracking_orientation" qualifiers="const"> <return type="bool"> </return> @@ -82,15 +91,6 @@ Returns [code]true[/code] if this device is tracking position. </description> </method> - <method name="get_transform" qualifiers="const"> - <return type="Transform"> - </return> - <argument index="0" name="adjust_by_reference_frame" type="bool"> - </argument> - <description> - Returns the transform combining this device's orientation and position. - </description> - </method> </methods> <members> <member name="rumble" type="float" setter="set_rumble" getter="get_rumble" default="0.0"> |