diff options
Diffstat (limited to 'doc/classes')
25 files changed, 227 insertions, 40 deletions
diff --git a/doc/classes/@GlobalScope.xml b/doc/classes/@GlobalScope.xml index 43101d6e5e..dce96fb315 100644 --- a/doc/classes/@GlobalScope.xml +++ b/doc/classes/@GlobalScope.xml @@ -2626,6 +2626,8 @@ <constant name="METHOD_FLAG_FROM_SCRIPT" value="64" enum="MethodFlags"> Deprecated method flag, unused. </constant> + <constant name="METHOD_FLAG_VARARG" value="128" enum="MethodFlags"> + </constant> <constant name="METHOD_FLAG_STATIC" value="256" enum="MethodFlags"> </constant> <constant name="METHOD_FLAG_OBJECT_CORE" value="512" enum="MethodFlags"> diff --git a/doc/classes/Array.xml b/doc/classes/Array.xml index ef4f86f1a9..94181db95f 100644 --- a/doc/classes/Array.xml +++ b/doc/classes/Array.xml @@ -123,6 +123,48 @@ </constructor> </constructors> <methods> + <method name="all" qualifiers="const"> + <return type="bool" /> + <argument index="0" name="method" type="Callable" /> + <description> + Calls the provided [Callable] on each element in the array and returns [code]true[/code] if the [Callable] returns [code]true[/code] for [i]all[/i] elements in the array. If the [Callable] returns [code]false[/code] for one array element or more, this method returns [code]false[/code]. + The callable's method should take one [Variant] parameter (the current array element) and return a boolean value. + [codeblock] + func _ready(): + print([6, 10, 6].all(greater_than_5)) # Prints True (3 elements evaluate to `true`). + print([4, 10, 4].all(greater_than_5)) # Prints False (1 elements evaluate to `true`). + print([4, 4, 4].all(greater_than_5)) # Prints False (0 elements evaluate to `true`). + + print([6, 10, 6].all(func(number): return number > 5)) # Prints True. Same as the first line above, but using lambda function. + + func greater_than_5(number): + return number > 5 + [/codeblock] + See also [method any], [method filter], [method map] and [method reduce]. + [b]Note:[/b] Unlike relying on the size of an array returned by [method filter], this method will return as early as possible to improve performance (especially with large arrays). + </description> + </method> + <method name="any" qualifiers="const"> + <return type="bool" /> + <argument index="0" name="method" type="Callable" /> + <description> + Calls the provided [Callable] on each element in the array and returns [code]true[/code] if the [Callable] returns [code]true[/code] for [i]one or more[/i] elements in the array. If the [Callable] returns [code]false[/code] for all elements in the array, this method returns [code]false[/code]. + The callable's method should take one [Variant] parameter (the current array element) and return a boolean value. + [codeblock] + func _ready(): + print([6, 10, 6].any(greater_than_5)) # Prints True (3 elements evaluate to `true`). + print([4, 10, 4].any(greater_than_5)) # Prints True (1 elements evaluate to `true`). + print([4, 4, 4].any(greater_than_5)) # Prints False (0 elements evaluate to `true`). + + print([6, 10, 6].any(func(number): return number > 5)) # Prints True. Same as the first line above, but using lambda function. + + func greater_than_5(number): + return number > 5 + [/codeblock] + See also [method all], [method filter], [method map] and [method reduce]. + [b]Note:[/b] Unlike relying on the size of an array returned by [method filter], this method will return as early as possible to improve performance (especially with large arrays). + </description> + </method> <method name="append"> <return type="void" /> <argument index="0" name="value" type="Variant" /> @@ -232,6 +274,7 @@ func remove_1(number): return number != 1 [/codeblock] + See also [method any], [method all], [method map] and [method reduce]. </description> </method> <method name="find" qualifiers="const"> @@ -333,6 +376,7 @@ func negate(number): return -number [/codeblock] + See also [method filter], [method reduce], [method any] and [method all]. </description> </method> <method name="max" qualifiers="const"> @@ -398,6 +442,7 @@ func sum(accum, number): return accum + number [/codeblock] + See also [method map], [method filter], [method any] and [method all]. </description> </method> <method name="remove_at"> diff --git a/doc/classes/Color.xml b/doc/classes/Color.xml index 7b8a57ed22..59ad104ad1 100644 --- a/doc/classes/Color.xml +++ b/doc/classes/Color.xml @@ -157,10 +157,28 @@ Constructs a color from an [url=https://en.wikipedia.org/wiki/HSL_and_HSV]HSV profile[/url]. [code]h[/code] (hue), [code]s[/code] (saturation), and [code]v[/code] (value) are typically between 0 and 1. [codeblocks] [gdscript] - var c = Color.from_hsv(0.58, 0.5, 0.79, 0.8) + var color = Color.from_hsv(0.58, 0.5, 0.79, 0.8) [/gdscript] [csharp] - var c = Color.FromHsv(0.58f, 0.5f, 0.79f, 0.8f); + var color = Color.FromHsv(0.58f, 0.5f, 0.79f, 0.8f); + [/csharp] + [/codeblocks] + </description> + </method> + <method name="from_ok_hsl" qualifiers="static"> + <return type="Color" /> + <argument index="0" name="h" type="float" /> + <argument index="1" name="s" type="float" /> + <argument index="2" name="l" type="float" /> + <argument index="3" name="alpha" type="float" default="1.0" /> + <description> + Constructs a color from an [url=https://bottosson.github.io/posts/colorpicker/]OK HSL profile[/url]. [code]h[/code] (hue), [code]s[/code] (saturation), and [code]v[/code] (value) are typically between 0 and 1. + [codeblocks] + [gdscript] + var color = Color.from_ok_hsl(0.58, 0.5, 0.79, 0.8) + [/gdscript] + [csharp] + var color = Color.FromOkHsl(0.58f, 0.5f, 0.79f, 0.8f); [/csharp] [/codeblocks] </description> diff --git a/doc/classes/ColorPicker.xml b/doc/classes/ColorPicker.xml index 5c47d6fb54..7c9c4ed4d6 100644 --- a/doc/classes/ColorPicker.xml +++ b/doc/classes/ColorPicker.xml @@ -91,6 +91,9 @@ <constant name="SHAPE_VHS_CIRCLE" value="2" enum="PickerShapeType"> HSV Color Model circle color space. Use Saturation as a radius. </constant> + <constant name="SHAPE_OKHSL_CIRCLE" value="3" enum="PickerShapeType"> + HSL OK Color Model circle color space. + </constant> </constants> <theme_items> <theme_item name="h_width" data_type="constant" type="int" default="30"> diff --git a/doc/classes/Dictionary.xml b/doc/classes/Dictionary.xml index b46719c758..6f2ad5205c 100644 --- a/doc/classes/Dictionary.xml +++ b/doc/classes/Dictionary.xml @@ -291,6 +291,14 @@ Returns the list of keys in the [Dictionary]. </description> </method> + <method name="merge"> + <return type="void" /> + <argument index="0" name="dictionary" type="Dictionary" /> + <argument index="1" name="overwrite" type="bool" default="false" /> + <description> + Adds elements from [code]dictionary[/code] to this [Dictionary]. By default, duplicate keys will not be copied over, unless [code]overwrite[/code] is [code]true[/code]. + </description> + </method> <method name="size" qualifiers="const"> <return type="int" /> <description> diff --git a/doc/classes/EditorPlugin.xml b/doc/classes/EditorPlugin.xml index 7bbb2ae26c..48d0636df4 100644 --- a/doc/classes/EditorPlugin.xml +++ b/doc/classes/EditorPlugin.xml @@ -479,7 +479,7 @@ <method name="get_script_create_dialog"> <return type="ScriptCreateDialog" /> <description> - Gets the Editor's dialogue used for making scripts. + Gets the Editor's dialog used for making scripts. [b]Note:[/b] Users can configure it before use. [b]Warning:[/b] Removing and freeing this node will render a part of the editor useless and may cause a crash. </description> diff --git a/doc/classes/Input.xml b/doc/classes/Input.xml index 2a4381b41b..66683fa0ee 100644 --- a/doc/classes/Input.xml +++ b/doc/classes/Input.xml @@ -40,7 +40,7 @@ <method name="flush_buffered_events"> <return type="void" /> <description> - Sends all input events which are in the current buffer to the game loop. These events may have been buffered as a result of accumulated input ([method set_use_accumulated_input]) or agile input flushing ([member ProjectSettings.input_devices/buffering/agile_event_flushing]). + Sends all input events which are in the current buffer to the game loop. These events may have been buffered as a result of accumulated input ([member use_accumulated_input]) or agile input flushing ([member ProjectSettings.input_devices/buffering/agile_event_flushing]). The engine will already do this itself at key execution points (at least once per frame). However, this can be useful in advanced cases where you want precise control over the timing of event handling. </description> </method> @@ -80,7 +80,7 @@ </description> </method> <method name="get_connected_joypads"> - <return type="Array" /> + <return type="int[]" /> <description> Returns an [Array] containing the device IDs of all currently connected joypads. </description> @@ -160,12 +160,6 @@ Returns mouse buttons as a bitmask. If multiple mouse buttons are pressed at the same time, the bits are added together. </description> </method> - <method name="get_mouse_mode" qualifiers="const"> - <return type="int" enum="Input.MouseMode" /> - <description> - Returns the mouse mode. See the constants for more information. - </description> - </method> <method name="get_vector" qualifiers="const"> <return type="Vector2" /> <argument index="0" name="negative_x" type="StringName" /> @@ -338,21 +332,6 @@ [b]Note:[/b] This value can be immediately overwritten by the hardware sensor value on Android and iOS. </description> </method> - <method name="set_mouse_mode"> - <return type="void" /> - <argument index="0" name="mode" type="int" enum="Input.MouseMode" /> - <description> - Sets the mouse mode. See the constants for more information. - </description> - </method> - <method name="set_use_accumulated_input"> - <return type="void" /> - <argument index="0" name="enable" type="bool" /> - <description> - Enables or disables the accumulation of similar input events sent by the operating system. When input accumulation is enabled, all input events generated during a frame will be merged and emitted when the frame is done rendering. Therefore, this limits the number of input method calls per second to the rendering FPS. - Input accumulation is enabled by default. It can be disabled to get slightly more precise/reactive input at the cost of increased CPU usage. In applications where drawing freehand lines is required, input accumulation should generally be disabled while the user is drawing the line to get results that closely follow the actual input. - </description> - </method> <method name="start_joy_vibration"> <return type="void" /> <argument index="0" name="device" type="int" /> @@ -389,6 +368,15 @@ </description> </method> </methods> + <members> + <member name="mouse_mode" type="int" setter="set_mouse_mode" getter="get_mouse_mode" enum="Input.MouseMode"> + Controls the mouse mode. See [enum MouseMode] for more information. + </member> + <member name="use_accumulated_input" type="bool" setter="set_use_accumulated_input" getter="is_using_accumulated_input"> + If [code]true[/code], similar input events sent by the operating system are accumulated. When input accumulation is enabled, all input events generated during a frame will be merged and emitted when the frame is done rendering. Therefore, this limits the number of input method calls per second to the rendering FPS. + Input accumulation can be disabled to get slightly more precise/reactive input at the cost of increased CPU usage. In applications where drawing freehand lines is required, input accumulation should generally be disabled while the user is drawing the line to get results that closely follow the actual input. + </member> + </members> <signals> <signal name="joy_connection_changed"> <argument index="0" name="device" type="int" /> diff --git a/doc/classes/InputEventMouseMotion.xml b/doc/classes/InputEventMouseMotion.xml index 7cc3de8fcb..ad74204d82 100644 --- a/doc/classes/InputEventMouseMotion.xml +++ b/doc/classes/InputEventMouseMotion.xml @@ -5,7 +5,7 @@ </brief_description> <description> Contains mouse and pen motion information. Supports relative, absolute positions and velocity. See [method Node._input]. - [b]Note:[/b] By default, this event is only emitted once per frame rendered at most. If you need more precise input reporting, call [method Input.set_use_accumulated_input] with [code]false[/code] to make events emitted as often as possible. If you use InputEventMouseMotion to draw lines, consider implementing [url=https://en.wikipedia.org/wiki/Bresenham%27s_line_algorithm]Bresenham's line algorithm[/url] as well to avoid visible gaps in lines if the user is moving the mouse quickly. + [b]Note:[/b] By default, this event is only emitted once per frame rendered at most. If you need more precise input reporting, set [member Input.use_accumulated_input] to [code]false[/code] to make events emitted as often as possible. If you use InputEventMouseMotion to draw lines, consider implementing [url=https://en.wikipedia.org/wiki/Bresenham%27s_line_algorithm]Bresenham's line algorithm[/url] as well to avoid visible gaps in lines if the user is moving the mouse quickly. </description> <tutorials> <link title="Mouse and input coordinates">$DOCS_URL/tutorials/inputs/mouse_and_input_coordinates.html</link> diff --git a/doc/classes/Mesh.xml b/doc/classes/Mesh.xml index 2b24901fe2..eeb6af24c9 100644 --- a/doc/classes/Mesh.xml +++ b/doc/classes/Mesh.xml @@ -123,7 +123,7 @@ <method name="generate_triangle_mesh" qualifiers="const"> <return type="TriangleMesh" /> <description> - Generate a [TriangleMesh] from the mesh. + Generate a [TriangleMesh] from the mesh. Considers only surfaces using one of these primitive types: [constant PRIMITIVE_TRIANGLES], [constant PRIMITIVE_TRIANGLE_STRIP]. </description> </method> <method name="get_aabb" qualifiers="const"> diff --git a/doc/classes/MultiplayerSynchronizer.xml b/doc/classes/MultiplayerSynchronizer.xml index 43355481b6..ac067791e6 100644 --- a/doc/classes/MultiplayerSynchronizer.xml +++ b/doc/classes/MultiplayerSynchronizer.xml @@ -7,7 +7,7 @@ <tutorials> </tutorials> <members> - <member name="congiruation" type="SceneReplicationConfig" setter="set_replication_config" getter="get_replication_config"> + <member name="replication_config" type="SceneReplicationConfig" setter="set_replication_config" getter="get_replication_config"> </member> <member name="replication_interval" type="float" setter="set_replication_interval" getter="get_replication_interval" default="0.0"> </member> diff --git a/doc/classes/NavigationRegion2D.xml b/doc/classes/NavigationRegion2D.xml index 5cd2e035b6..542aa8f619 100644 --- a/doc/classes/NavigationRegion2D.xml +++ b/doc/classes/NavigationRegion2D.xml @@ -7,6 +7,9 @@ A region of the navigation map. It tells the [NavigationServer2D] what can be navigated and what cannot, based on its [NavigationPolygon] resource. Two regions can be connected to each other if they share a similar edge. You can set the minimum distance between two vertices required to connect two edges by using [method NavigationServer2D.map_set_edge_connection_margin]. [b]Note:[/b] Overlapping two regions' polygons is not enough for connecting two regions. They must share a similar edge. + The pathfinding cost of entering this region from another region can be controlled with the [member enter_cost] value. + [b]Note[/b]: This value is not added to the path cost when the start position is already inside this region. + The pathfinding cost of traveling distances inside this region can be controlled with the [member travel_cost] multiplier. </description> <tutorials> </tutorials> @@ -22,11 +25,17 @@ <member name="enabled" type="bool" setter="set_enabled" getter="is_enabled" default="true"> Determines if the [NavigationRegion2D] is enabled or disabled. </member> + <member name="enter_cost" type="float" setter="set_enter_cost" getter="get_enter_cost" default="0.0"> + When pathfinding enters this regions navmesh from another regions navmesh the [code]enter_cost[/code] value is added to the path distance for determining the shortest path. + </member> <member name="layers" type="int" setter="set_layers" getter="get_layers" default="1"> A bitfield determining all layers the region belongs to. These layers can be checked upon when requesting a path with [method NavigationServer2D.map_get_path]. </member> <member name="navpoly" type="NavigationPolygon" setter="set_navigation_polygon" getter="get_navigation_polygon"> The [NavigationPolygon] resource to use. </member> + <member name="travel_cost" type="float" setter="set_travel_cost" getter="get_travel_cost" default="1.0"> + When pathfinding moves inside this regions navmesh the traveled distances are multiplied with [code]travel_cost[/code] for determining the shortest path. + </member> </members> </class> diff --git a/doc/classes/NavigationRegion3D.xml b/doc/classes/NavigationRegion3D.xml index 42f0e0c5d9..e45bca7f8b 100644 --- a/doc/classes/NavigationRegion3D.xml +++ b/doc/classes/NavigationRegion3D.xml @@ -6,6 +6,10 @@ <description> A region of the navigation map. It tells the [NavigationServer3D] what can be navigated and what cannot, based on its [NavigationMesh] resource. Two regions can be connected to each other if they share a similar edge. You can set the minimum distance between two vertices required to connect two edges by using [method NavigationServer3D.map_set_edge_connection_margin]. + [b]Note:[/b] Overlapping two regions' navmeshes is not enough for connecting two regions. They must share a similar edge. + The cost of entering this region from another region can be controlled with the [member enter_cost] value. + [b]Note[/b]: This value is not added to the path cost when the start position is already inside this region. + The cost of traveling distances inside this region can be controlled with the [member travel_cost] multiplier. </description> <tutorials> </tutorials> @@ -28,12 +32,18 @@ <member name="enabled" type="bool" setter="set_enabled" getter="is_enabled" default="true"> Determines if the [NavigationRegion3D] is enabled or disabled. </member> + <member name="enter_cost" type="float" setter="set_enter_cost" getter="get_enter_cost" default="0.0"> + When pathfinding enters this regions navmesh from another regions navmesh the [code]enter_cost[/code] value is added to the path distance for determining the shortest path. + </member> <member name="layers" type="int" setter="set_layers" getter="get_layers" default="1"> A bitfield determining all layers the region belongs to. These layers can be checked upon when requesting a path with [method NavigationServer3D.map_get_path]. </member> <member name="navmesh" type="NavigationMesh" setter="set_navigation_mesh" getter="get_navigation_mesh"> The [NavigationMesh] resource to use. </member> + <member name="travel_cost" type="float" setter="set_travel_cost" getter="get_travel_cost" default="1.0"> + When pathfinding moves inside this regions navmesh the traveled distances are multiplied with [code]travel_cost[/code] for determining the shortest path. + </member> </members> <signals> <signal name="bake_finished"> diff --git a/doc/classes/NavigationServer2D.xml b/doc/classes/NavigationServer2D.xml index 1994a7a4c4..7b0dac99c3 100644 --- a/doc/classes/NavigationServer2D.xml +++ b/doc/classes/NavigationServer2D.xml @@ -247,6 +247,13 @@ Returns how many connections this [code]region[/code] has with other regions in the map. </description> </method> + <method name="region_get_enter_cost" qualifiers="const"> + <return type="float" /> + <argument index="0" name="region" type="RID" /> + <description> + Returns the [code]enter_cost[/code] of this [code]region[/code]. + </description> + </method> <method name="region_get_layers" qualifiers="const"> <return type="int" /> <argument index="0" name="region" type="RID" /> @@ -261,6 +268,21 @@ Returns the navigation map [RID] the requested [code]region[/code] is currently assigned to. </description> </method> + <method name="region_get_travel_cost" qualifiers="const"> + <return type="float" /> + <argument index="0" name="region" type="RID" /> + <description> + Returns the [code]travel_cost[/code] of this [code]region[/code]. + </description> + </method> + <method name="region_set_enter_cost" qualifiers="const"> + <return type="void" /> + <argument index="0" name="region" type="RID" /> + <argument index="1" name="enter_cost" type="float" /> + <description> + Sets the [code]enter_cost[/code] for this [code]region[/code]. + </description> + </method> <method name="region_set_layers" qualifiers="const"> <return type="void" /> <argument index="0" name="region" type="RID" /> @@ -293,6 +315,14 @@ Sets the global transformation for the region. </description> </method> + <method name="region_set_travel_cost" qualifiers="const"> + <return type="void" /> + <argument index="0" name="region" type="RID" /> + <argument index="1" name="travel_cost" type="float" /> + <description> + Sets the [code]travel_cost[/code] for this [code]region[/code]. + </description> + </method> </methods> <signals> <signal name="map_changed"> diff --git a/doc/classes/NavigationServer3D.xml b/doc/classes/NavigationServer3D.xml index 2a729e7108..d6574dd69a 100644 --- a/doc/classes/NavigationServer3D.xml +++ b/doc/classes/NavigationServer3D.xml @@ -297,6 +297,13 @@ Returns how many connections this [code]region[/code] has with other regions in the map. </description> </method> + <method name="region_get_enter_cost" qualifiers="const"> + <return type="float" /> + <argument index="0" name="region" type="RID" /> + <description> + Returns the [code]enter_cost[/code] of this [code]region[/code]. + </description> + </method> <method name="region_get_layers" qualifiers="const"> <return type="int" /> <argument index="0" name="region" type="RID" /> @@ -311,6 +318,21 @@ Returns the navigation map [RID] the requested [code]region[/code] is currently assigned to. </description> </method> + <method name="region_get_travel_cost" qualifiers="const"> + <return type="float" /> + <argument index="0" name="region" type="RID" /> + <description> + Returns the [code]travel_cost[/code] of this [code]region[/code]. + </description> + </method> + <method name="region_set_enter_cost" qualifiers="const"> + <return type="void" /> + <argument index="0" name="region" type="RID" /> + <argument index="1" name="enter_cost" type="float" /> + <description> + Sets the [code]enter_cost[/code] for this [code]region[/code]. + </description> + </method> <method name="region_set_layers" qualifiers="const"> <return type="void" /> <argument index="0" name="region" type="RID" /> @@ -343,6 +365,14 @@ Sets the global transformation for the region. </description> </method> + <method name="region_set_travel_cost" qualifiers="const"> + <return type="void" /> + <argument index="0" name="region" type="RID" /> + <argument index="1" name="travel_cost" type="float" /> + <description> + Sets the [code]travel_cost[/code] for this [code]region[/code]. + </description> + </method> <method name="set_active" qualifiers="const"> <return type="void" /> <argument index="0" name="active" type="bool" /> diff --git a/doc/classes/NodePath.xml b/doc/classes/NodePath.xml index 3319e5d822..00c5dcaa3d 100644 --- a/doc/classes/NodePath.xml +++ b/doc/classes/NodePath.xml @@ -107,7 +107,7 @@ <return type="StringName" /> <argument index="0" name="idx" type="int" /> <description> - Gets the node name indicated by [code]idx[/code] (0 to [method get_name_count]). + Gets the node name indicated by [code]idx[/code] (0 to [method get_name_count] - 1). [codeblocks] [gdscript] var node_path = NodePath("Path2D/PathFollow2D/Sprite2D") @@ -157,6 +157,12 @@ For example, [code]"Path2D/PathFollow2D/Sprite2D:texture:load_path"[/code] has 2 subnames. </description> </method> + <method name="hash" qualifiers="const"> + <return type="int" /> + <description> + Returns the 32-bit hash value representing the [NodePath]'s contents. + </description> + </method> <method name="is_absolute" qualifiers="const"> <return type="bool" /> <description> diff --git a/doc/classes/OS.xml b/doc/classes/OS.xml index 266a2573de..2512dec4b3 100644 --- a/doc/classes/OS.xml +++ b/doc/classes/OS.xml @@ -550,7 +550,7 @@ Requests the OS to open a resource with the most appropriate program. For example: - [code]OS.shell_open("C:\\Users\name\Downloads")[/code] on Windows opens the file explorer at the user's Downloads folder. - [code]OS.shell_open("https://godotengine.org")[/code] opens the default web browser on the official Godot website. - - [code]OS.shell_open("mailto:example@example.com")[/code] opens the default email client with the "To" field set to [code]example@example.com[/code]. See [url=https://blog.escapecreative.com/customizing-mailto-links/]Customizing [code]mailto:[/code] Links[/url] for a list of fields that can be added. + - [code]OS.shell_open("mailto:example@example.com")[/code] opens the default email client with the "To" field set to [code]example@example.com[/code]. See [url=https://datatracker.ietf.org/doc/html/rfc2368]RFC 2368 - The [code]mailto[/code] URL scheme[/url] for a list of fields that can be added. Use [method ProjectSettings.globalize_path] to convert a [code]res://[/code] or [code]user://[/code] path into a system path for use with this method. [b]Note:[/b] This method is implemented on Android, iOS, HTML5, Linux, macOS and Windows. </description> diff --git a/doc/classes/ProjectSettings.xml b/doc/classes/ProjectSettings.xml index 98205e0e16..8a3677c0b4 100644 --- a/doc/classes/ProjectSettings.xml +++ b/doc/classes/ProjectSettings.xml @@ -216,6 +216,9 @@ <member name="application/config/description" type="String" setter="" getter="" default=""""> The project's description, displayed as a tooltip in the Project Manager when hovering the project. </member> + <member name="application/config/features" type="PackedStringArray" setter="" getter=""> + List of internal features associated with the project, like [code]Double Precision[/code] or [code]C#[/code]. Not to be confused with feature tags. + </member> <member name="application/config/icon" type="String" setter="" getter="" default=""""> Icon used for the project, set when project loads. Exporters will also use this icon when possible. </member> @@ -811,6 +814,12 @@ <member name="internationalization/locale/test" type="String" setter="" getter="" default=""""> If non-empty, this locale will be used when running the project from the editor. </member> + <member name="internationalization/locale/translation_remaps" type="PackedStringArray" setter="" getter=""> + Locale-dependent resource remaps. Edit them in the "Localization" tab of Project Settings editor. + </member> + <member name="internationalization/locale/translations" type="PackedStringArray" setter="" getter=""> + List of translation files available in the project. Edit them in the "Localization" tab of Project Settings editor. + </member> <member name="internationalization/pseudolocalization/double_vowels" type="bool" setter="" getter="" default="false"> Double vowels in strings during pseudolocalization to simulate the lengthening of text due to localization. </member> @@ -1375,10 +1384,10 @@ <member name="navigation/2d/default_edge_connection_margin" type="int" setter="" getter="" default="1"> Default edge connection margin for 2D navigation maps. See [method NavigationServer2D.map_set_edge_connection_margin]. </member> - <member name="navigation/3d/default_cell_size" type="float" setter="" getter="" default="0.3"> + <member name="navigation/3d/default_cell_size" type="float" setter="" getter="" default="0.25"> Default cell size for 3D navigation maps. See [method NavigationServer3D.map_set_cell_size]. </member> - <member name="navigation/3d/default_edge_connection_margin" type="float" setter="" getter="" default="0.3"> + <member name="navigation/3d/default_edge_connection_margin" type="float" setter="" getter="" default="0.25"> Default edge connection margin for 3D navigation maps. See [method NavigationServer3D.map_set_edge_connection_margin]. </member> <member name="network/limits/debugger/max_chars_per_second" type="int" setter="" getter="" default="32768"> @@ -1584,6 +1593,10 @@ </member> <member name="rendering/anti_aliasing/quality/use_debanding" type="bool" setter="" getter="" default="false"> </member> + <member name="rendering/anti_aliasing/quality/use_taa" type="bool" setter="" getter="" default="false"> + Enables Temporal Anti-Aliasing for the default screen [Viewport]. TAA works by jittering the camera and accumulating the images of the last rendered frames, motion vector rendering is used to account for camera and object motion. + [b]Note:[/b] The implementation is not complete yet, some visual instances such as particles and skinned meshes may show artifacts. + </member> <member name="rendering/anti_aliasing/screen_space_roughness_limiter/amount" type="float" setter="" getter="" default="0.25"> </member> <member name="rendering/anti_aliasing/screen_space_roughness_limiter/enabled" type="bool" setter="" getter="" default="true"> diff --git a/doc/classes/Range.xml b/doc/classes/Range.xml index df6efd155a..22793e75d8 100644 --- a/doc/classes/Range.xml +++ b/doc/classes/Range.xml @@ -4,7 +4,7 @@ Abstract base class for range-based controls. </brief_description> <description> - Range is a base class for [Control] nodes that change a floating-point [i]value[/i] between a [i]minimum[/i] and a [i]maximum[/i], using [i]step[/i] and [i]page[/i], for example a [ScrollBar]. + Range is a base class for [Control] nodes that change a floating-point [member value] between a [member min_value] and [member max_value], using a configured [member step] and [member page] size. See e.g. [ScrollBar] and [Slider] for examples of higher level nodes using Range. </description> <tutorials> </tutorials> diff --git a/doc/classes/RenderingServer.xml b/doc/classes/RenderingServer.xml index 4d039227ce..d92121a950 100644 --- a/doc/classes/RenderingServer.xml +++ b/doc/classes/RenderingServer.xml @@ -3035,7 +3035,7 @@ $Viewport.set_attach_to_screen_rect(Rect2(0, 0, 600, 600)) [/gdscript] [/codeblocks] - Using this can result in significant optimization, especially on lower-end devices. However, it comes at the cost of having to manage your viewports manually. For a further optimization see, [method viewport_set_render_direct_to_screen]. + Using this can result in significant optimization, especially on lower-end devices. However, it comes at the cost of having to manage your viewports manually. For further optimization, see [method viewport_set_render_direct_to_screen]. </description> </method> <method name="viewport_create"> @@ -3340,6 +3340,14 @@ <description> </description> </method> + <method name="viewport_set_use_taa"> + <return type="void" /> + <argument index="0" name="viewport" type="RID" /> + <argument index="1" name="enable" type="bool" /> + <description> + If [code]true[/code], use Temporal Anti-Aliasing. + </description> + </method> <method name="viewport_set_use_xr"> <return type="void" /> <argument index="0" name="viewport" type="RID" /> @@ -4105,6 +4113,8 @@ </constant> <constant name="VIEWPORT_DEBUG_DRAW_OCCLUDERS" value="24" enum="ViewportDebugDraw"> </constant> + <constant name="VIEWPORT_DEBUG_DRAW_MOTION_VECTORS" value="25" enum="ViewportDebugDraw"> + </constant> <constant name="SKY_MODE_AUTOMATIC" value="0" enum="SkyMode"> </constant> <constant name="SKY_MODE_QUALITY" value="1" enum="SkyMode"> diff --git a/doc/classes/SceneTreeTimer.xml b/doc/classes/SceneTreeTimer.xml index 427608ead3..2e9aeebceb 100644 --- a/doc/classes/SceneTreeTimer.xml +++ b/doc/classes/SceneTreeTimer.xml @@ -22,7 +22,7 @@ } [/csharp] [/codeblocks] - The timer will be automatically freed after its time elapses. + The timer will be automatically freed after its time elapses, so be aware that any reference you might have kept to it will become invalid. </description> <tutorials> </tutorials> diff --git a/doc/classes/StringName.xml b/doc/classes/StringName.xml index ffa1227500..a2bcac9788 100644 --- a/doc/classes/StringName.xml +++ b/doc/classes/StringName.xml @@ -32,6 +32,14 @@ </description> </constructor> </constructors> + <methods> + <method name="hash" qualifiers="const"> + <return type="int" /> + <description> + Returns the 32-bit hash value representing the [StringName]'s contents. + </description> + </method> + </methods> <operators> <operator name="operator !="> <return type="bool" /> diff --git a/doc/classes/Texture2D.xml b/doc/classes/Texture2D.xml index 1bbebe085e..3721058d25 100644 --- a/doc/classes/Texture2D.xml +++ b/doc/classes/Texture2D.xml @@ -106,7 +106,8 @@ <method name="get_image" qualifiers="const"> <return type="Image" /> <description> - Returns an [Image] that is a copy of data from this [Texture2D]. [Image]s can be accessed and manipulated directly. + Returns an [Image] that is a copy of data from this [Texture2D] (a new [Image] is created each time). [Image]s can be accessed and manipulated directly. + [b]Note:[/b] This will fetch the texture data from the GPU, which might cause performance problems when overused. </description> </method> <method name="get_size" qualifiers="const"> diff --git a/doc/classes/Viewport.xml b/doc/classes/Viewport.xml index 148c6d7064..4727bc389e 100644 --- a/doc/classes/Viewport.xml +++ b/doc/classes/Viewport.xml @@ -227,7 +227,7 @@ The multisample anti-aliasing mode. A higher number results in smoother edges at the cost of significantly worse performance. A value of 2 or 4 is best unless targeting very high-end systems. See also bilinear scaling 3d [member scaling_3d_mode] for supersampling, which provides higher quality but is much more expensive. </member> <member name="own_world_3d" type="bool" setter="set_use_own_world_3d" getter="is_using_own_world_3d" default="false"> - If [code]true[/code], the viewport will use the [World3D] defined in [member world_3d]. + If [code]true[/code], the viewport will use a unique copy of the [World3D] defined in [member world_3d]. </member> <member name="physics_object_picking" type="bool" setter="set_physics_object_picking" getter="get_physics_object_picking" default="false"> If [code]true[/code], the objects rendered by viewport become subjects of mouse picking process. @@ -279,6 +279,10 @@ If [code]true[/code], [OccluderInstance3D] nodes will be usable for occlusion culling in 3D for this viewport. For the root viewport, [member ProjectSettings.rendering/occlusion_culling/use_occlusion_culling] must be set to [code]true[/code] instead. [b]Note:[/b] Enabling occlusion culling has a cost on the CPU. Only enable occlusion culling if you actually plan to use it, and think whether your scene can actually benefit from occlusion culling. Large, open scenes with few or no objects blocking the view will generally not benefit much from occlusion culling. Large open scenes generally benefit more from mesh LOD and visibility ranges ([member GeometryInstance3D.visibility_range_begin] and [member GeometryInstance3D.visibility_range_end]) compared to occlusion culling. </member> + <member name="use_taa" type="bool" setter="set_use_taa" getter="is_using_taa" default="false"> + Enables Temporal Anti-Aliasing for this viewport. TAA works by jittering the camera and accumulating the images of the last rendered frames, motion vector rendering is used to account for camera and object motion. + [b]Note:[/b] The implementation is not complete yet, some visual instances such as particles and skinned meshes may show artifacts. + </member> <member name="use_xr" type="bool" setter="set_use_xr" getter="is_using_xr" default="false"> If [code]true[/code], the viewport will use the primary XR interface to render XR output. When applicable this can result in a stereoscopic image and the resulting render being output to a headset. </member> @@ -441,6 +445,8 @@ </constant> <constant name="DEBUG_DRAW_OCCLUDERS" value="24" enum="DebugDraw"> </constant> + <constant name="DEBUG_DRAW_MOTION_VECTORS" value="25" 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/VisualShaderNodeFloatFunc.xml b/doc/classes/VisualShaderNodeFloatFunc.xml index 0f057b2e6d..1226013c67 100644 --- a/doc/classes/VisualShaderNodeFloatFunc.xml +++ b/doc/classes/VisualShaderNodeFloatFunc.xml @@ -65,7 +65,7 @@ <constant name="FUNC_CEIL" value="16" enum="Function"> Finds the nearest integer that is greater than or equal to the parameter. Translates to [code]ceil(x)[/code] in the Godot Shader Language. </constant> - <constant name="FUNC_FRAC" value="17" enum="Function"> + <constant name="FUNC_FRACT" value="17" enum="Function"> Computes the fractional part of the argument. Translates to [code]fract(x)[/code] in the Godot Shader Language. </constant> <constant name="FUNC_SATURATE" value="18" enum="Function"> diff --git a/doc/classes/VisualShaderNodeVectorFunc.xml b/doc/classes/VisualShaderNodeVectorFunc.xml index bc4e12c0b3..7524025f21 100644 --- a/doc/classes/VisualShaderNodeVectorFunc.xml +++ b/doc/classes/VisualShaderNodeVectorFunc.xml @@ -68,7 +68,7 @@ <constant name="FUNC_FLOOR" value="17" enum="Function"> Finds the nearest integer less than or equal to the parameter. </constant> - <constant name="FUNC_FRAC" value="18" enum="Function"> + <constant name="FUNC_FRACT" value="18" enum="Function"> Computes the fractional part of the argument. </constant> <constant name="FUNC_INVERSE_SQRT" value="19" enum="Function"> |