summaryrefslogtreecommitdiff
path: root/doc/classes
diff options
context:
space:
mode:
Diffstat (limited to 'doc/classes')
-rw-r--r--doc/classes/@GlobalScope.xml9
-rw-r--r--doc/classes/AStarGrid2D.xml40
-rw-r--r--doc/classes/AnimatedSprite2D.xml11
-rw-r--r--doc/classes/AnimatedSprite3D.xml11
-rw-r--r--doc/classes/Animation.xml13
-rw-r--r--doc/classes/AnimationNode.xml5
-rw-r--r--doc/classes/AnimationNodeStateMachineTransition.xml18
-rw-r--r--doc/classes/AnimationTree.xml14
-rw-r--r--doc/classes/Area2D.xml60
-rw-r--r--doc/classes/Area3D.xml60
-rw-r--r--doc/classes/ArrayMesh.xml4
-rw-r--r--doc/classes/AudioStreamRandomizer.xml4
-rw-r--r--doc/classes/BaseMaterial3D.xml4
-rw-r--r--doc/classes/Button.xml1
-rw-r--r--doc/classes/ButtonGroup.xml4
-rw-r--r--doc/classes/CanvasGroup.xml17
-rw-r--r--doc/classes/CanvasItem.xml7
-rw-r--r--doc/classes/CanvasLayer.xml6
-rw-r--r--doc/classes/CharacterBody3D.xml8
-rw-r--r--doc/classes/CheckBox.xml1
-rw-r--r--doc/classes/CheckButton.xml1
-rw-r--r--doc/classes/CodeEdit.xml3
-rw-r--r--doc/classes/Color.xml30
-rw-r--r--doc/classes/ColorPicker.xml3
-rw-r--r--doc/classes/ColorPickerButton.xml1
-rw-r--r--doc/classes/Control.xml3
-rw-r--r--doc/classes/Curve3D.xml2
-rw-r--r--doc/classes/Dictionary.xml2
-rw-r--r--doc/classes/EditorPaths.xml2
-rw-r--r--doc/classes/EditorScenePostImport.xml6
-rw-r--r--doc/classes/EditorSettings.xml3
-rw-r--r--doc/classes/EditorSpinSlider.xml22
-rw-r--r--doc/classes/EditorUndoRedoManager.xml3
-rw-r--r--doc/classes/EditorVCSInterface.xml4
-rw-r--r--doc/classes/FontFile.xml14
-rw-r--r--doc/classes/GDExtension.xml (renamed from doc/classes/NativeExtension.xml)6
-rw-r--r--doc/classes/GDExtensionManager.xml (renamed from doc/classes/NativeExtensionManager.xml)10
-rw-r--r--doc/classes/GeometryInstance3D.xml10
-rw-r--r--doc/classes/Image.xml31
-rw-r--r--doc/classes/Input.xml14
-rw-r--r--doc/classes/InputEventScreenDrag.xml9
-rw-r--r--doc/classes/ItemList.xml1
-rw-r--r--doc/classes/Label.xml1
-rw-r--r--doc/classes/LineEdit.xml1
-rw-r--r--doc/classes/LinkButton.xml19
-rw-r--r--doc/classes/MenuBar.xml1
-rw-r--r--doc/classes/MenuButton.xml1
-rw-r--r--doc/classes/MeshLibrary.xml27
-rw-r--r--doc/classes/NavigationAgent2D.xml49
-rw-r--r--doc/classes/NavigationAgent3D.xml49
-rw-r--r--doc/classes/NavigationLink2D.xml4
-rw-r--r--doc/classes/NavigationLink3D.xml4
-rw-r--r--doc/classes/NavigationMesh.xml14
-rw-r--r--doc/classes/NavigationMeshGenerator.xml10
-rw-r--r--doc/classes/NavigationObstacle2D.xml2
-rw-r--r--doc/classes/NavigationObstacle3D.xml2
-rw-r--r--doc/classes/NavigationPathQueryParameters2D.xml24
-rw-r--r--doc/classes/NavigationPathQueryParameters3D.xml24
-rw-r--r--doc/classes/NavigationPathQueryResult2D.xml19
-rw-r--r--doc/classes/NavigationPathQueryResult3D.xml19
-rw-r--r--doc/classes/NavigationPolygon.xml14
-rw-r--r--doc/classes/NavigationRegion2D.xml10
-rw-r--r--doc/classes/NavigationRegion3D.xml10
-rw-r--r--doc/classes/NavigationServer2D.xml14
-rw-r--r--doc/classes/NavigationServer3D.xml20
-rw-r--r--doc/classes/Node2D.xml6
-rw-r--r--doc/classes/Node3D.xml6
-rw-r--r--doc/classes/OS.xml57
-rw-r--r--doc/classes/Object.xml2
-rw-r--r--doc/classes/OptionButton.xml5
-rw-r--r--doc/classes/PathFollow3D.xml2
-rw-r--r--doc/classes/PhysicsServer2D.xml32
-rw-r--r--doc/classes/PhysicsServer3D.xml15
-rw-r--r--doc/classes/PhysicsServer3DExtension.xml13
-rw-r--r--doc/classes/PopupMenu.xml1
-rw-r--r--doc/classes/ProgressBar.xml1
-rw-r--r--doc/classes/ProjectSettings.xml20
-rw-r--r--doc/classes/RenderingDevice.xml4
-rw-r--r--doc/classes/RenderingServer.xml18
-rw-r--r--doc/classes/RichTextLabel.xml10
-rw-r--r--doc/classes/SpriteFrames.xml40
-rw-r--r--doc/classes/String.xml10
-rw-r--r--doc/classes/StringName.xml10
-rw-r--r--doc/classes/TabBar.xml1
-rw-r--r--doc/classes/TabContainer.xml1
-rw-r--r--doc/classes/TextEdit.xml1
-rw-r--r--doc/classes/TextLine.xml2
-rw-r--r--doc/classes/TextParagraph.xml2
-rw-r--r--doc/classes/TextServer.xml14
-rw-r--r--doc/classes/TextServerExtension.xml3
-rw-r--r--doc/classes/TileMap.xml3
-rw-r--r--doc/classes/TileSet.xml1
-rw-r--r--doc/classes/Transform2D.xml22
-rw-r--r--doc/classes/Tree.xml1
-rw-r--r--doc/classes/TubeTrailMesh.xml6
-rw-r--r--doc/classes/VisualInstance3D.xml7
-rw-r--r--doc/classes/VisualShader.xml14
-rw-r--r--doc/classes/VisualShaderNode.xml17
-rw-r--r--doc/classes/VisualShaderNodeClamp.xml11
-rw-r--r--doc/classes/VisualShaderNodeCompare.xml15
-rw-r--r--doc/classes/VisualShaderNodeSwitch.xml15
-rw-r--r--doc/classes/VisualShaderNodeUIntConstant.xml16
-rw-r--r--doc/classes/VisualShaderNodeUIntFunc.xml27
-rw-r--r--doc/classes/VisualShaderNodeUIntOp.xml57
-rw-r--r--doc/classes/VisualShaderNodeUIntParameter.xml15
105 files changed, 922 insertions, 396 deletions
diff --git a/doc/classes/@GlobalScope.xml b/doc/classes/@GlobalScope.xml
index 4a6b85f229..6b0dccd7fc 100644
--- a/doc/classes/@GlobalScope.xml
+++ b/doc/classes/@GlobalScope.xml
@@ -1319,6 +1319,9 @@
<member name="EngineDebugger" type="EngineDebugger" setter="" getter="">
The [EngineDebugger] singleton.
</member>
+ <member name="GDExtensionManager" type="GDExtensionManager" setter="" getter="">
+ The [GDExtensionManager] singleton.
+ </member>
<member name="Geometry2D" type="Geometry2D" setter="" getter="">
The [Geometry2D] singleton.
</member>
@@ -1348,9 +1351,6 @@
<member name="Marshalls" type="Marshalls" setter="" getter="">
The [Marshalls] singleton.
</member>
- <member name="NativeExtensionManager" type="NativeExtensionManager" setter="" getter="">
- The [NativeExtensionManager] singleton.
- </member>
<member name="NavigationMeshGenerator" type="NavigationMeshGenerator" setter="" getter="">
The [NavigationMeshGenerator] singleton.
</member>
@@ -1479,6 +1479,9 @@
<constant name="INLINE_ALIGNMENT_CENTER_TO" value="1" enum="InlineAlignment">
Aligns the center of the inline object (e.g. image, table) to the position of the text specified by [code]INLINE_ALIGNMENT_TO_*[/code] constant.
</constant>
+ <constant name="INLINE_ALIGNMENT_BASELINE_TO" value="3" enum="InlineAlignment">
+ Aligns the baseline (user defined) of the inline object (e.g. image, table) to the position of the text specified by [code]INLINE_ALIGNMENT_TO_*[/code] constant.
+ </constant>
<constant name="INLINE_ALIGNMENT_BOTTOM_TO" value="2" enum="InlineAlignment">
Aligns the bottom of the inline object (e.g. image, table) to the position of the text specified by [code]INLINE_ALIGNMENT_TO_*[/code] constant.
</constant>
diff --git a/doc/classes/AStarGrid2D.xml b/doc/classes/AStarGrid2D.xml
index 8dde3748d7..32599d7f7d 100644
--- a/doc/classes/AStarGrid2D.xml
+++ b/doc/classes/AStarGrid2D.xml
@@ -69,6 +69,20 @@
[b]Note:[/b] This method is not thread-safe. If called from a [Thread], it will return an empty [PackedVector3Array] and will print an error message.
</description>
</method>
+ <method name="get_point_position" qualifiers="const">
+ <return type="Vector2" />
+ <param index="0" name="id" type="Vector2i" />
+ <description>
+ Returns the position of the point associated with the given [param id].
+ </description>
+ </method>
+ <method name="get_point_weight_scale" qualifiers="const">
+ <return type="float" />
+ <param index="0" name="id" type="Vector2i" />
+ <description>
+ Returns the weight scale of the point associated with the given [param id].
+ </description>
+ </method>
<method name="is_dirty" qualifiers="const">
<return type="bool" />
<description>
@@ -103,6 +117,16 @@
<param index="1" name="solid" type="bool" default="true" />
<description>
Disables or enables the specified point for pathfinding. Useful for making an obstacle. By default, all points are enabled.
+ [b]Note:[/b] Calling [method update] is not needed after the call of this function.
+ </description>
+ </method>
+ <method name="set_point_weight_scale">
+ <return type="void" />
+ <param index="0" name="id" type="Vector2i" />
+ <param index="1" name="weight_scale" type="float" />
+ <description>
+ Sets the [param weight_scale] for the point with the given [param id]. The [param weight_scale] 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.
+ [b]Note:[/b] Calling [method update] is not needed after the call of this function.
</description>
</method>
<method name="update">
@@ -116,14 +140,18 @@
<member name="cell_size" type="Vector2" setter="set_cell_size" getter="get_cell_size" default="Vector2(1, 1)">
The size of the point cell which will be applied to calculate the resulting point position returned by [method get_point_path]. If changed, [method update] needs to be called before finding the next path.
</member>
- <member name="default_heuristic" type="int" setter="set_default_heuristic" getter="get_default_heuristic" enum="AStarGrid2D.Heuristic" default="0">
- The default [enum Heuristic] which will be used to calculate the path if [method _compute_cost] and/or [method _estimate_cost] were not overridden.
+ <member name="default_compute_heuristic" type="int" setter="set_default_compute_heuristic" getter="get_default_compute_heuristic" enum="AStarGrid2D.Heuristic" default="0">
+ The default [enum Heuristic] which will be used to calculate the cost between two points if [method _compute_cost] was not overridden.
+ </member>
+ <member name="default_estimate_heuristic" type="int" setter="set_default_estimate_heuristic" getter="get_default_estimate_heuristic" enum="AStarGrid2D.Heuristic" default="0">
+ The default [enum Heuristic] which will be used to calculate the cost between the point and the end point if [method _estimate_cost] was not overridden.
</member>
<member name="diagonal_mode" type="int" setter="set_diagonal_mode" getter="get_diagonal_mode" enum="AStarGrid2D.DiagonalMode" default="0">
A specific [enum DiagonalMode] mode which will force the path to avoid or accept the specified diagonals.
</member>
<member name="jumping_enabled" type="bool" setter="set_jumping_enabled" getter="is_jumping_enabled" default="false">
Enables or disables jumping to skip up the intermediate points and speeds up the searching algorithm.
+ [b]Note:[/b] Currently, toggling it on disables the consideration of weight scaling in pathfinding.
</member>
<member name="offset" type="Vector2" setter="set_offset" getter="get_offset" default="Vector2(0, 0)">
The offset of the grid which will be applied to calculate the resulting point position returned by [method get_point_path]. If changed, [method update] needs to be called before finding the next path.
@@ -134,20 +162,22 @@
</members>
<constants>
<constant name="HEURISTIC_EUCLIDEAN" value="0" enum="Heuristic">
- The Euclidean heuristic to be used for the pathfinding using the following formula:
+ The [url=https://en.wikipedia.org/wiki/Euclidean_distance]Euclidean heuristic[/url] to be used for the pathfinding using the following formula:
[codeblock]
dx = abs(to_id.x - from_id.x)
dy = abs(to_id.y - from_id.y)
result = sqrt(dx * dx + dy * dy)
[/codeblock]
+ [b]Note:[/b] This is also the internal heuristic used in [AStar3D] and [AStar2D] by default (with the inclusion of possible z-axis coordinate).
</constant>
<constant name="HEURISTIC_MANHATTAN" value="1" enum="Heuristic">
- The Manhattan heuristic to be used for the pathfinding using the following formula:
+ The [url=https://en.wikipedia.org/wiki/Taxicab_geometry]Manhattan heuristic[/url] to be used for the pathfinding using the following formula:
[codeblock]
dx = abs(to_id.x - from_id.x)
dy = abs(to_id.y - from_id.y)
result = dx + dy
[/codeblock]
+ [b]Note:[/b] This heuristic is intended to be used with 4-side orthogonal movements, provided by setting the [member diagonal_mode] to [constant DIAGONAL_MODE_NEVER].
</constant>
<constant name="HEURISTIC_OCTILE" value="2" enum="Heuristic">
The Octile heuristic to be used for the pathfinding using the following formula:
@@ -159,7 +189,7 @@
[/codeblock]
</constant>
<constant name="HEURISTIC_CHEBYSHEV" value="3" enum="Heuristic">
- The Chebyshev heuristic to be used for the pathfinding using the following formula:
+ The [url=https://en.wikipedia.org/wiki/Chebyshev_distance]Chebyshev heuristic[/url] to be used for the pathfinding using the following formula:
[codeblock]
dx = abs(to_id.x - from_id.x)
dy = abs(to_id.y - from_id.y)
diff --git a/doc/classes/AnimatedSprite2D.xml b/doc/classes/AnimatedSprite2D.xml
index afbe34816a..e20fb71c7e 100644
--- a/doc/classes/AnimatedSprite2D.xml
+++ b/doc/classes/AnimatedSprite2D.xml
@@ -6,7 +6,7 @@
<description>
[AnimatedSprite2D] is similar to the [Sprite2D] node, except it carries multiple textures as animation frames. Animations are created using a [SpriteFrames] resource, which allows you to import image files (or a folder containing said files) to provide the animation frames for the sprite. The [SpriteFrames] resource can be configured in the editor via the SpriteFrames bottom panel.
After setting up [member frames], [method play] may be called. It's also possible to select an [member animation] and toggle [member playing], even within the editor.
- To pause the current animation, call [method stop] or set [member playing] to [code]false[/code]. Alternatively, setting [member speed_scale] to [code]0[/code] also preserves the current frame's elapsed time.
+ To pause the current animation, set [member playing] to [code]false[/code]. Alternatively, setting [member speed_scale] to [code]0[/code] also preserves the current frame's elapsed time.
[b]Note:[/b] You can associate a set of normal or specular maps by creating additional [SpriteFrames] resources with a [code]_normal[/code] or [code]_specular[/code] suffix. For example, having 3 [SpriteFrames] resources [code]run[/code], [code]run_normal[/code], and [code]run_specular[/code] will make it so the [code]run[/code] animation uses normal and specular maps.
</description>
<tutorials>
@@ -20,13 +20,14 @@
<param index="1" name="backwards" type="bool" default="false" />
<description>
Plays the animation named [param anim]. If no [param anim] is provided, the current animation is played. If [param backwards] is [code]true[/code], the animation is played in reverse.
+ [b]Note:[/b] If [member speed_scale] is negative, the animation direction specified by [param backwards] will be inverted.
</description>
</method>
<method name="stop">
<return type="void" />
<description>
Stops the current [member animation] at the current [member frame].
- [b]Note:[/b] This method resets the current frame's elapsed time. If this behavior is undesired, consider setting [member speed_scale] to [code]0[/code], instead.
+ [b]Note:[/b] This method resets the current frame's elapsed time and removes the [code]backwards[/code] flag from the current [member animation] (if it was previously set by [method play]). If this behavior is undesired, set [member playing] to [code]false[/code] instead.
</description>
</method>
</methods>
@@ -53,7 +54,9 @@
The texture's drawing offset.
</member>
<member name="playing" type="bool" setter="set_playing" getter="is_playing" default="false">
- If [code]true[/code], the [member animation] is currently playing. Setting this property to [code]false[/code] is the equivalent of calling [method stop].
+ If [code]true[/code], the [member animation] is currently playing. Setting this property to [code]false[/code] pauses the current animation. Use [method stop] to stop the animation at the current frame instead.
+ [b]Note:[/b] Unlike [method stop], changing this property to [code]false[/code] preserves the current frame's elapsed time and the [code]backwards[/code] flag of the current [member animation] (if it was previously set by [method play]).
+ [b]Note:[/b] After a non-looping animation finishes, the property still remains [code]true[/code].
</member>
<member name="speed_scale" type="float" setter="set_speed_scale" getter="get_speed_scale" default="1.0">
The animation speed is multiplied by this value. If set to a negative value, the animation is played in reverse. If set to [code]0[/code], the animation is paused, preserving the current frame's elapsed time.
@@ -62,7 +65,7 @@
<signals>
<signal name="animation_finished">
<description>
- Emitted when the animation is finished (when it plays the last frame). If the animation is looping, this signal is emitted every time the last frame is drawn.
+ Emitted when the animation reaches the end, or the start if it is played in reverse. If the animation is looping, this signal is emitted at the end of each loop.
</description>
</signal>
<signal name="frame_changed">
diff --git a/doc/classes/AnimatedSprite3D.xml b/doc/classes/AnimatedSprite3D.xml
index 09baf882fb..4837ae715f 100644
--- a/doc/classes/AnimatedSprite3D.xml
+++ b/doc/classes/AnimatedSprite3D.xml
@@ -6,7 +6,7 @@
<description>
[AnimatedSprite3D] is similar to the [Sprite3D] node, except it carries multiple textures as animation [member frames]. Animations are created using a [SpriteFrames] resource, which allows you to import image files (or a folder containing said files) to provide the animation frames for the sprite. The [SpriteFrames] resource can be configured in the editor via the SpriteFrames bottom panel.
After setting up [member frames], [method play] may be called. It's also possible to select an [member animation] and toggle [member playing], even within the editor.
- To pause the current animation, call [method stop] or set [member playing] to [code]false[/code]. Alternatively, setting [member speed_scale] to [code]0[/code] also preserves the current frame's elapsed time.
+ To pause the current animation, set [member playing] to [code]false[/code]. Alternatively, setting [member speed_scale] to [code]0[/code] also preserves the current frame's elapsed time.
</description>
<tutorials>
<link title="2D Sprite animation (also applies to 3D)">$DOCS_URL/tutorials/2d/2d_sprite_animation.html</link>
@@ -18,13 +18,14 @@
<param index="1" name="backwards" type="bool" default="false" />
<description>
Plays the animation named [param anim]. If no [param anim] is provided, the current animation is played. If [param backwards] is [code]true[/code], the animation is played in reverse.
+ [b]Note:[/b] If [member speed_scale] is negative, the animation direction specified by [param backwards] will be inverted.
</description>
</method>
<method name="stop">
<return type="void" />
<description>
Stops the current [member animation] at the current [member frame].
- [b]Note:[/b] This method resets the current frame's elapsed time. If this behavior is undesired, consider setting [member speed_scale] to [code]0[/code], instead.
+ [b]Note:[/b] This method resets the current frame's elapsed time and removes the [code]backwards[/code] flag from the current [member animation] (if it was previously set by [method play]). If this behavior is undesired, set [member playing] to [code]false[/code] instead.
</description>
</method>
</methods>
@@ -39,7 +40,9 @@
The [SpriteFrames] resource containing the animation(s).
</member>
<member name="playing" type="bool" setter="set_playing" getter="is_playing" default="false">
- If [code]true[/code], the [member animation] is currently playing. Setting this property to [code]false[/code] is the equivalent of calling [method stop].
+ If [code]true[/code], the [member animation] is currently playing. Setting this property to [code]false[/code] pauses the current animation. Use [method stop] to stop the animation at the current frame instead.
+ [b]Note:[/b] Unlike [method stop], changing this property to [code]false[/code] preserves the current frame's elapsed time and the [code]backwards[/code] flag of the current [member animation] (if it was previously set by [method play]).
+ [b]Note:[/b] After a non-looping animation finishes, the property still remains [code]true[/code].
</member>
<member name="speed_scale" type="float" setter="set_speed_scale" getter="get_speed_scale" default="1.0">
The animation speed is multiplied by this value. If set to a negative value, the animation is played in reverse. If set to [code]0[/code], the animation is paused, preserving the current frame's elapsed time.
@@ -48,7 +51,7 @@
<signals>
<signal name="animation_finished">
<description>
- Emitted when the animation is finished (when it plays the last frame). If the animation is looping, this signal is emitted every time the last frame is drawn.
+ Emitted when the animation reaches the end, or the start if it is played in reverse. If the animation is looping, this signal is emitted at the end of each loop.
</description>
</signal>
<signal name="frame_changed">
diff --git a/doc/classes/Animation.xml b/doc/classes/Animation.xml
index d9a1f896f1..c0626dcfe4 100644
--- a/doc/classes/Animation.xml
+++ b/doc/classes/Animation.xml
@@ -305,9 +305,9 @@
<return type="int" />
<param index="0" name="track_idx" type="int" />
<param index="1" name="time" type="float" />
- <param index="2" name="exact" type="bool" default="false" />
+ <param index="2" name="find_mode" type="int" enum="Animation.FindMode" default="0" />
<description>
- Finds the key index by time in a given track. Optionally, only find it if the exact time is given.
+ Finds the key index by time in a given track. Optionally, only find it if the approx/exact time is given.
</description>
</method>
<method name="track_get_interpolation_loop_wrap" qualifiers="const">
@@ -622,5 +622,14 @@
<constant name="LOOPED_FLAG_START" value="2" enum="LoopedFlag">
This flag indicates that the animation has reached the start of the animation and just after loop processed.
</constant>
+ <constant name="FIND_MODE_NEAREST" value="0" enum="FindMode">
+ Finds the nearest time key.
+ </constant>
+ <constant name="FIND_MODE_APPROX" value="1" enum="FindMode">
+ Finds only the key with approximating the time.
+ </constant>
+ <constant name="FIND_MODE_EXACT" value="2" enum="FindMode">
+ Finds only the key with matching the time.
+ </constant>
</constants>
</class>
diff --git a/doc/classes/AnimationNode.xml b/doc/classes/AnimationNode.xml
index 79deb008d2..a33ec2f6dc 100644
--- a/doc/classes/AnimationNode.xml
+++ b/doc/classes/AnimationNode.xml
@@ -165,11 +165,6 @@
</member>
</members>
<signals>
- <signal name="removed_from_graph">
- <description>
- Emitted when the node was removed from the graph.
- </description>
- </signal>
<signal name="tree_changed">
<description>
Emitted by nodes that inherit from this class and that have an internal tree when one of their nodes changes. The nodes that emit this signal are [AnimationNodeBlendSpace1D], [AnimationNodeBlendSpace2D], [AnimationNodeStateMachine], and [AnimationNodeBlendTree].
diff --git a/doc/classes/AnimationNodeStateMachineTransition.xml b/doc/classes/AnimationNodeStateMachineTransition.xml
index 4c2a30030b..814b2d0052 100644
--- a/doc/classes/AnimationNodeStateMachineTransition.xml
+++ b/doc/classes/AnimationNodeStateMachineTransition.xml
@@ -22,14 +22,11 @@
<member name="advance_expression" type="String" setter="set_advance_expression" getter="get_advance_expression" default="&quot;&quot;">
Use an expression as a condition for state machine transitions. It is possible to create complex animation advance conditions for switching between states and gives much greater flexibility for creating complex state machines by directly interfacing with the script code.
</member>
- <member name="auto_advance" type="bool" setter="set_auto_advance" getter="has_auto_advance" default="false">
- Turn on the transition automatically when this state is reached. This works best with [constant SWITCH_MODE_AT_END].
- </member>
- <member name="disabled" type="bool" setter="set_disabled" getter="is_disabled" default="false">
- Don't use this transition during [method AnimationNodeStateMachinePlayback.travel] or [member auto_advance].
+ <member name="advance_mode" type="int" setter="set_advance_mode" getter="get_advance_mode" enum="AnimationNodeStateMachineTransition.AdvanceMode" default="1">
+ Determines whether the transition should disabled, enabled when using [method AnimationNodeStateMachinePlayback.travel], or traversed automatically if the [member advance_condition] and [member advance_expression] checks are true (if assigned).
</member>
<member name="priority" type="int" setter="set_priority" getter="get_priority" default="1">
- Lower priority transitions are preferred when travelling through the tree via [method AnimationNodeStateMachinePlayback.travel] or [member auto_advance].
+ Lower priority transitions are preferred when travelling through the tree via [method AnimationNodeStateMachinePlayback.travel] or [member advance_mode] is set to [constant ADVANCE_MODE_AUTO].
</member>
<member name="switch_mode" type="int" setter="set_switch_mode" getter="get_switch_mode" enum="AnimationNodeStateMachineTransition.SwitchMode" default="0">
The transition type.
@@ -58,5 +55,14 @@
<constant name="SWITCH_MODE_AT_END" value="2" enum="SwitchMode">
Wait for the current state playback to end, then switch to the beginning of the next state animation.
</constant>
+ <constant name="ADVANCE_MODE_DISABLED" value="0" enum="AdvanceMode">
+ Don't use this transition.
+ </constant>
+ <constant name="ADVANCE_MODE_ENABLED" value="1" enum="AdvanceMode">
+ Only use this transition during [method AnimationNodeStateMachinePlayback.travel].
+ </constant>
+ <constant name="ADVANCE_MODE_AUTO" value="2" enum="AdvanceMode">
+ Automatically use this transition if the [member advance_condition] and [member advance_expression] checks are true (if assigned).
+ </constant>
</constants>
</class>
diff --git a/doc/classes/AnimationTree.xml b/doc/classes/AnimationTree.xml
index 21f4b37741..a17a727d7e 100644
--- a/doc/classes/AnimationTree.xml
+++ b/doc/classes/AnimationTree.xml
@@ -111,11 +111,25 @@
</member>
</members>
<signals>
+ <signal name="animation_finished">
+ <param index="0" name="anim_name" type="StringName" />
+ <description>
+ Notifies when an animation finished playing.
+ [b]Note:[/b] This signal is not emitted if an animation is looping or aborted. Also be aware of the possibility of unseen playback by sync and xfade.
+ </description>
+ </signal>
<signal name="animation_player_changed">
<description>
Emitted when the [member anim_player] is changed.
</description>
</signal>
+ <signal name="animation_started">
+ <param index="0" name="anim_name" type="StringName" />
+ <description>
+ Notifies when an animation starts playing.
+ [b]Note:[/b] This signal is not emitted if an animation is looping or playbacked from the middle. Also be aware of the possibility of unseen playback by sync and xfade.
+ </description>
+ </signal>
</signals>
<constants>
<constant name="ANIMATION_PROCESS_PHYSICS" value="0" enum="AnimationProcessCallback">
diff --git a/doc/classes/Area2D.xml b/doc/classes/Area2D.xml
index 29592f133d..3f76cc16ec 100644
--- a/doc/classes/Area2D.xml
+++ b/doc/classes/Area2D.xml
@@ -114,15 +114,13 @@
<signal name="area_entered">
<param index="0" name="area" type="Area2D" />
<description>
- Emitted when another Area2D enters this Area2D. Requires [member monitoring] to be set to [code]true[/code].
- [param area] the other Area2D.
+ Emitted when the received [param area] enters this area. Requires [member monitoring] to be set to [code]true[/code].
</description>
</signal>
<signal name="area_exited">
<param index="0" name="area" type="Area2D" />
<description>
- Emitted when another Area2D exits this Area2D. Requires [member monitoring] to be set to [code]true[/code].
- [param area] the other Area2D.
+ Emitted when the received [param area] exits this area. Requires [member monitoring] to be set to [code]true[/code].
</description>
</signal>
<signal name="area_shape_entered">
@@ -131,11 +129,18 @@
<param index="2" name="area_shape_index" type="int" />
<param index="3" name="local_shape_index" type="int" />
<description>
- 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].
- [param area_rid] the [RID] of the other Area2D's [CollisionObject2D] used by the [PhysicsServer2D].
- [param area] the other Area2D.
- [param area_shape_index] the index of the [Shape2D] of the other Area2D used by the [PhysicsServer2D]. Get the [CollisionShape2D] node with [code]area.shape_owner_get_owner(area.shape_find_owner(area_shape_index))[/code].
- [param local_shape_index] the index of the [Shape2D] of this Area2D used by the [PhysicsServer2D]. Get the [CollisionShape2D] node with [code]self.shape_owner_get_owner(self.shape_find_owner(local_shape_index))[/code].
+ Emitted when a [Shape2D] of the received [param area] enters a shape of this area. Requires [member monitoring] to be set to [code]true[/code].
+ [param local_shape_index] and [param area_shape_index] contain indices of the interacting shapes from this area and the other area, respectively. [param area_rid] contains the [RID] of the other area. These values can be used with the [PhysicsServer2D].
+ [b]Example of getting the[/b] [CollisionShape2D] [b]node from the shape index:[/b]
+ [codeblocks]
+ [gdscript]
+ var other_shape_owner = area.shape_find_owner(area_shape_index)
+ var other_shape_node = area.shape_owner_get_owner(other_shape_owner)
+
+ var local_shape_owner = shape_find_owner(local_shape_index)
+ var local_shape_node = shape_owner_get_owner(local_shape_owner)
+ [/gdscript]
+ [/codeblocks]
</description>
</signal>
<signal name="area_shape_exited">
@@ -144,25 +149,20 @@
<param index="2" name="area_shape_index" type="int" />
<param index="3" name="local_shape_index" type="int" />
<description>
- 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].
- [param area_rid] the [RID] of the other Area2D's [CollisionObject2D] used by the [PhysicsServer2D].
- [param area] the other Area2D.
- [param area_shape_index] the index of the [Shape2D] of the other Area2D used by the [PhysicsServer2D]. Get the [CollisionShape2D] node with [code]area.shape_owner_get_owner(area.shape_find_owner(area_shape_index))[/code].
- [param local_shape_index] the index of the [Shape2D] of this Area2D used by the [PhysicsServer2D]. Get the [CollisionShape2D] node with [code]self.shape_owner_get_owner(self.shape_find_owner(local_shape_index))[/code].
+ Emitted when a [Shape2D] of the received [param area] exits a shape of this area. Requires [member monitoring] to be set to [code]true[/code].
+ See also [signal area_shape_entered].
</description>
</signal>
<signal name="body_entered">
<param index="0" name="body" type="Node2D" />
<description>
- 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.
- [param body] the [Node], if it exists in the tree, of the other [PhysicsBody2D] or [TileMap].
+ Emitted when the received [param body] enters this area. [param body] can be a [PhysicsBody2D] or a [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes configured. Requires [member monitoring] to be set to [code]true[/code].
</description>
</signal>
<signal name="body_exited">
<param index="0" name="body" type="Node2D" />
<description>
- 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.
- [param body] the [Node], if it exists in the tree, of the other [PhysicsBody2D] or [TileMap].
+ Emitted when the received [param body] exits this area. [param body] can be a [PhysicsBody2D] or a [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes configured. Requires [member monitoring] to be set to [code]true[/code].
</description>
</signal>
<signal name="body_shape_entered">
@@ -171,11 +171,18 @@
<param index="2" name="body_shape_index" type="int" />
<param index="3" name="local_shape_index" type="int" />
<description>
- 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.
- [param body_rid] the [RID] of the [PhysicsBody2D] or [TileSet]'s [CollisionObject2D] used by the [PhysicsServer2D].
- [param body] the [Node], if it exists in the tree, of the [PhysicsBody2D] or [TileMap].
- [param body_shape_index] the index of the [Shape2D] of the [PhysicsBody2D] or [TileMap] used by the [PhysicsServer2D]. Get the [CollisionShape2D] node with [code]body.shape_owner_get_owner(body.shape_find_owner(body_shape_index))[/code].
- [param local_shape_index] the index of the [Shape2D] of this Area2D used by the [PhysicsServer2D]. Get the [CollisionShape2D] node with [code]self.shape_owner_get_owner(self.shape_find_owner(local_shape_index))[/code].
+ Emitted when a [Shape2D] of the received [param body] enters a shape of this area. [param body] can be a [PhysicsBody2D] or a [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes configured. Requires [member monitoring] to be set to [code]true[/code].
+ [param local_shape_index] and [param body_shape_index] contain indices of the interacting shapes from this area and the interacting body, respectively. [param body_rid] contains the [RID] of the body. These values can be used with the [PhysicsServer2D].
+ [b]Example of getting the[/b] [CollisionShape2D] [b]node from the shape index:[/b]
+ [codeblocks]
+ [gdscript]
+ var body_shape_owner = body.shape_find_owner(body_shape_index)
+ var body_shape_node = body.shape_owner_get_owner(body_shape_owner)
+
+ var local_shape_owner = shape_find_owner(local_shape_index)
+ var local_shape_node = shape_owner_get_owner(local_shape_owner)
+ [/gdscript]
+ [/codeblocks]
</description>
</signal>
<signal name="body_shape_exited">
@@ -184,11 +191,8 @@
<param index="2" name="body_shape_index" type="int" />
<param index="3" name="local_shape_index" type="int" />
<description>
- 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.
- [param body_rid] the [RID] of the [PhysicsBody2D] or [TileSet]'s [CollisionObject2D] used by the [PhysicsServer2D].
- [param body] the [Node], if it exists in the tree, of the [PhysicsBody2D] or [TileMap].
- [param body_shape_index] the index of the [Shape2D] of the [PhysicsBody2D] or [TileMap] used by the [PhysicsServer2D]. Get the [CollisionShape2D] node with [code]body.shape_owner_get_owner(body.shape_find_owner(body_shape_index))[/code].
- [param local_shape_index] the index of the [Shape2D] of this Area2D used by the [PhysicsServer2D]. Get the [CollisionShape2D] node with [code]self.shape_owner_get_owner(self.shape_find_owner(local_shape_index))[/code].
+ Emitted when a [Shape2D] of the received [param body] exits a shape of this area. [param body] can be a [PhysicsBody2D] or a [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes configured. Requires [member monitoring] to be set to [code]true[/code].
+ See also [signal body_shape_entered].
</description>
</signal>
</signals>
diff --git a/doc/classes/Area3D.xml b/doc/classes/Area3D.xml
index ea8cab324d..8923ac8aae 100644
--- a/doc/classes/Area3D.xml
+++ b/doc/classes/Area3D.xml
@@ -133,15 +133,13 @@
<signal name="area_entered">
<param index="0" name="area" type="Area3D" />
<description>
- Emitted when another Area3D enters this Area3D. Requires [member monitoring] to be set to [code]true[/code].
- [param area] the other Area3D.
+ Emitted when the received [param area] enters this area. Requires [member monitoring] to be set to [code]true[/code].
</description>
</signal>
<signal name="area_exited">
<param index="0" name="area" type="Area3D" />
<description>
- Emitted when another Area3D exits this Area3D. Requires [member monitoring] to be set to [code]true[/code].
- [param area] the other Area3D.
+ Emitted when the received [param area] exits this area. Requires [member monitoring] to be set to [code]true[/code].
</description>
</signal>
<signal name="area_shape_entered">
@@ -150,11 +148,18 @@
<param index="2" name="area_shape_index" type="int" />
<param index="3" name="local_shape_index" type="int" />
<description>
- 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].
- [param area_rid] the [RID] of the other Area3D's [CollisionObject3D] used by the [PhysicsServer3D].
- [param area] the other Area3D.
- [param area_shape_index] the index of the [Shape3D] of the other Area3D used by the [PhysicsServer3D]. Get the [CollisionShape3D] node with [code]area.shape_owner_get_owner(area.shape_find_owner(area_shape_index))[/code].
- [param local_shape_index] the index of the [Shape3D] of this Area3D used by the [PhysicsServer3D]. Get the [CollisionShape3D] node with [code]self.shape_owner_get_owner(self.shape_find_owner(local_shape_index))[/code].
+ Emitted when a [Shape3D] of the received [param area] enters a shape of this area. Requires [member monitoring] to be set to [code]true[/code].
+ [param local_shape_index] and [param area_shape_index] contain indices of the interacting shapes from this area and the other area, respectively. [param area_rid] contains the [RID] of the other area. These values can be used with the [PhysicsServer3D].
+ [b]Example of getting the[/b] [CollisionShape3D] [b]node from the shape index:[/b]
+ [codeblocks]
+ [gdscript]
+ var other_shape_owner = area.shape_find_owner(area_shape_index)
+ var other_shape_node = area.shape_owner_get_owner(other_shape_owner)
+
+ var local_shape_owner = shape_find_owner(local_shape_index)
+ var local_shape_node = shape_owner_get_owner(local_shape_owner)
+ [/gdscript]
+ [/codeblocks]
</description>
</signal>
<signal name="area_shape_exited">
@@ -163,25 +168,20 @@
<param index="2" name="area_shape_index" type="int" />
<param index="3" name="local_shape_index" type="int" />
<description>
- Emitted when one of another Area3D's [Shape3D]s exits one of this Area3D's [Shape3D]s. Requires [member monitoring] to be set to [code]true[/code].
- [param area_rid] the [RID] of the other Area3D's [CollisionObject3D] used by the [PhysicsServer3D].
- [param area] the other Area3D.
- [param area_shape_index] the index of the [Shape3D] of the other Area3D used by the [PhysicsServer3D]. Get the [CollisionShape3D] node with [code]area.shape_owner_get_owner(area.shape_find_owner(area_shape_index))[/code].
- [param local_shape_index] the index of the [Shape3D] of this Area3D used by the [PhysicsServer3D]. Get the [CollisionShape3D] node with [code]self.shape_owner_get_owner(self.shape_find_owner(local_shape_index))[/code].
+ Emitted when a [Shape3D] of the received [param area] exits a shape of this area. Requires [member monitoring] to be set to [code]true[/code].
+ See also [signal area_shape_entered].
</description>
</signal>
<signal name="body_entered">
<param index="0" name="body" type="Node3D" />
<description>
- 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.
- [param body] the [Node], if it exists in the tree, of the other [PhysicsBody3D] or [GridMap].
+ Emitted when the received [param body] enters this area. [param body] can be a [PhysicsBody3D] or a [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision shapes configured. Requires [member monitoring] to be set to [code]true[/code].
</description>
</signal>
<signal name="body_exited">
<param index="0" name="body" type="Node3D" />
<description>
- 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.
- [param body] the [Node], if it exists in the tree, of the other [PhysicsBody3D] or [GridMap].
+ Emitted when the received [param body] exits this area. [param body] can be a [PhysicsBody3D] or a [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision shapes configured. Requires [member monitoring] to be set to [code]true[/code].
</description>
</signal>
<signal name="body_shape_entered">
@@ -190,11 +190,18 @@
<param index="2" name="body_shape_index" type="int" />
<param index="3" name="local_shape_index" type="int" />
<description>
- 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.
- [param body_rid] the [RID] of the [PhysicsBody3D] or [MeshLibrary]'s [CollisionObject3D] used by the [PhysicsServer3D].
- [param body] the [Node], if it exists in the tree, of the [PhysicsBody3D] or [GridMap].
- [param body_shape_index] the index of the [Shape3D] of the [PhysicsBody3D] or [GridMap] used by the [PhysicsServer3D]. Get the [CollisionShape3D] node with [code]body.shape_owner_get_owner(body.shape_find_owner(body_shape_index))[/code].
- [param local_shape_index] the index of the [Shape3D] of this Area3D used by the [PhysicsServer3D]. Get the [CollisionShape3D] node with [code]self.shape_owner_get_owner(self.shape_find_owner(local_shape_index))[/code].
+ Emitted when a [Shape3D] of the received [param body] enters a shape of this area. [param body] can be a [PhysicsBody3D] or a [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision shapes configured. Requires [member monitoring] to be set to [code]true[/code].
+ [param local_shape_index] and [param body_shape_index] contain indices of the interacting shapes from this area and the interacting body, respectively. [param body_rid] contains the [RID] of the body. These values can be used with the [PhysicsServer3D].
+ [b]Example of getting the[/b] [CollisionShape3D] [b]node from the shape index:[/b]
+ [codeblocks]
+ [gdscript]
+ var body_shape_owner = body.shape_find_owner(body_shape_index)
+ var body_shape_node = body.shape_owner_get_owner(body_shape_owner)
+
+ var local_shape_owner = shape_find_owner(local_shape_index)
+ var local_shape_node = shape_owner_get_owner(local_shape_owner)
+ [/gdscript]
+ [/codeblocks]
</description>
</signal>
<signal name="body_shape_exited">
@@ -203,11 +210,8 @@
<param index="2" name="body_shape_index" type="int" />
<param index="3" name="local_shape_index" type="int" />
<description>
- 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.
- [param body_rid] the [RID] of the [PhysicsBody3D] or [MeshLibrary]'s [CollisionObject3D] used by the [PhysicsServer3D].
- [param body] the [Node], if it exists in the tree, of the [PhysicsBody3D] or [GridMap].
- [param body_shape_index] the index of the [Shape3D] of the [PhysicsBody3D] or [GridMap] used by the [PhysicsServer3D]. Get the [CollisionShape3D] node with [code]body.shape_owner_get_owner(body.shape_find_owner(body_shape_index))[/code].
- [param local_shape_index] the index of the [Shape3D] of this Area3D used by the [PhysicsServer3D]. Get the [CollisionShape3D] node with [code]self.shape_owner_get_owner(self.shape_find_owner(local_shape_index))[/code].
+ Emitted when a [Shape3D] of the received [param body] exits a shape of this area. [param body] can be a [PhysicsBody3D] or a [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision shapes configured. Requires [member monitoring] to be set to [code]true[/code].
+ See also [signal body_shape_entered].
</description>
</signal>
</signals>
diff --git a/doc/classes/ArrayMesh.xml b/doc/classes/ArrayMesh.xml
index b9c8ab0f6c..70ce4ad516 100644
--- a/doc/classes/ArrayMesh.xml
+++ b/doc/classes/ArrayMesh.xml
@@ -102,13 +102,13 @@
<param index="0" name="transform" type="Transform3D" />
<param index="1" name="texel_size" type="float" />
<description>
- Will perform a UV unwrap on the [ArrayMesh] to prepare the mesh for lightmapping.
+ Performs a UV unwrap on the [ArrayMesh] to prepare the mesh for lightmapping.
</description>
</method>
<method name="regen_normal_maps">
<return type="void" />
<description>
- Will regenerate normal maps for the [ArrayMesh].
+ Regenerates tangents for each of the [ArrayMesh]'s surfaces.
</description>
</method>
<method name="set_blend_shape_name">
diff --git a/doc/classes/AudioStreamRandomizer.xml b/doc/classes/AudioStreamRandomizer.xml
index 9b58d78af5..d93f853c89 100644
--- a/doc/classes/AudioStreamRandomizer.xml
+++ b/doc/classes/AudioStreamRandomizer.xml
@@ -12,8 +12,10 @@
<method name="add_stream">
<return type="void" />
<param index="0" name="index" type="int" />
+ <param index="1" name="stream" type="AudioStream" />
+ <param index="2" name="weight" type="float" default="1.0" />
<description>
- Insert a stream at the specified index.
+ Insert a stream at the specified index. If the index is less than zero, the insertion occurs at the end of the underlying pool.
</description>
</method>
<method name="get_stream" qualifiers="const">
diff --git a/doc/classes/BaseMaterial3D.xml b/doc/classes/BaseMaterial3D.xml
index 8a5048de6b..60225275f3 100644
--- a/doc/classes/BaseMaterial3D.xml
+++ b/doc/classes/BaseMaterial3D.xml
@@ -529,13 +529,13 @@
The material will use the texture's alpha values for transparency.
</constant>
<constant name="TRANSPARENCY_ALPHA_SCISSOR" value="2" enum="Transparency">
- The material will cut off all values below a threshold, the rest will remain opaque. The opaque portions will be rendering in the depth prepass.
+ The material will cut off all values below a threshold, the rest will remain opaque. The opaque portions will be rendered in the depth prepass.
</constant>
<constant name="TRANSPARENCY_ALPHA_HASH" value="3" enum="Transparency">
The material will cut off all values below a spatially-deterministic threshold, the rest will remain opaque.
</constant>
<constant name="TRANSPARENCY_ALPHA_DEPTH_PRE_PASS" value="4" enum="Transparency">
- The material will use the texture's alpha value for transparency, but will still be rendered in the depth prepass.
+ The material will use the texture's alpha value for transparency, but will discard fragments with an alpha of less than 0.99 during the depth prepass and fragments with an alpha less than 0.1 during the shadow pass.
</constant>
<constant name="TRANSPARENCY_MAX" value="5" enum="Transparency">
Represents the size of the [enum Transparency] enum.
diff --git a/doc/classes/Button.xml b/doc/classes/Button.xml
index d2c9a77486..961f3c495a 100644
--- a/doc/classes/Button.xml
+++ b/doc/classes/Button.xml
@@ -118,6 +118,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
[Font] of the [Button]'s text.
diff --git a/doc/classes/ButtonGroup.xml b/doc/classes/ButtonGroup.xml
index 277bda2836..8195669b10 100644
--- a/doc/classes/ButtonGroup.xml
+++ b/doc/classes/ButtonGroup.xml
@@ -4,8 +4,8 @@
Group of Buttons.
</brief_description>
<description>
- Group of [Button]. All direct and indirect children buttons become radios. Only one allows being pressed.
- [member BaseButton.toggle_mode] should be [code]true[/code].
+ Group of [BaseButton]. The members of this group are treated like radio buttons in the sense that only one button can be pressed at the same time.
+ Every member of the ButtonGroup should have [member BaseButton.toggle_mode] set to [code]true[/code].
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/CanvasGroup.xml b/doc/classes/CanvasGroup.xml
index d2bcf3c7ac..37827defec 100644
--- a/doc/classes/CanvasGroup.xml
+++ b/doc/classes/CanvasGroup.xml
@@ -5,16 +5,33 @@
</brief_description>
<description>
Child [CanvasItem] nodes of a [CanvasGroup] are drawn as a single object. It allows to e.g. draw overlapping translucent 2D nodes without blending (set [member CanvasItem.self_modulate] property of [CanvasGroup] to achieve this effect).
+ [b]Note:[/b] The [CanvasGroup] uses a custom shader to read from the backbuffer to draw its children. Assigning a [Material] to the [CanvasGroup] overrides the builtin shader. To duplicate the behavior of the builtin shader in a custom [Shader] use the following:
+ [codeblock]
+ shader_type canvas_item;
+
+ void fragment() {
+ vec4 c = textureLod(SCREEN_TEXTURE, SCREEN_UV, 0.0);
+
+ if (c.a &gt; 0.0001) {
+ c.rgb /= c.a;
+ }
+
+ COLOR *= c;
+ }
+ [/codeblock]
[b]Note:[/b] Since [CanvasGroup] and [member CanvasItem.clip_children] both utilize the backbuffer, children of a [CanvasGroup] who have their [member CanvasItem.clip_children] set to anything other than [constant CanvasItem.CLIP_CHILDREN_DISABLED] will not function correctly.
</description>
<tutorials>
</tutorials>
<members>
<member name="clear_margin" type="float" setter="set_clear_margin" getter="get_clear_margin" default="10.0">
+ Sets the size of the margin used to expand the clearing rect of this [CanvasGroup]. This expands the area of the backbuffer that will be used by the [CanvasGroup]. A smaller margin will reduce the area of the backbuffer used which can increase performance, however if [member use_mipmaps] is enabled, a small margin may result in mipmap errors at the edge of the [CanvasGroup]. Accordingly, this should be left as small as possible, but should be increased if artifacts appear along the edges of the canvas group.
</member>
<member name="fit_margin" type="float" setter="set_fit_margin" getter="get_fit_margin" default="10.0">
+ Sets the size of a margin used to expand the drawable rect of this [CanvasGroup]. The size of the [CanvasGroup] is determined by fitting a rect around its children then expanding that rect by [member fit_margin]. This increases both the backbuffer area used and the area covered by the [CanvasGroup] both of which can reduce performance. This should be kept as small as possible and should only be expanded when an increased size is needed (e.g. for custom shader effects).
</member>
<member name="use_mipmaps" type="bool" setter="set_use_mipmaps" getter="is_using_mipmaps" default="false">
+ If [code]true[/code], calculates mipmaps for the backbuffer before drawing the [CanvasGroup] so that mipmaps can be used in a custom [ShaderMaterial] attached to the [CanvasGroup]. Generating mipmaps has a performance cost so this should not be enabled unless required.
</member>
</members>
</class>
diff --git a/doc/classes/CanvasItem.xml b/doc/classes/CanvasItem.xml
index 499d53e63c..5171e0acbe 100644
--- a/doc/classes/CanvasItem.xml
+++ b/doc/classes/CanvasItem.xml
@@ -153,6 +153,7 @@
<param index="3" name="modulate" type="Color" default="Color(1, 1, 1, 1)" />
<param index="4" name="outline" type="float" default="0.0" />
<param index="5" name="pixel_range" type="float" default="4.0" />
+ <param index="6" name="scale" type="float" default="1.0" />
<description>
Draws a textured rectangle region of the multi-channel signed distance field texture at a given position, optionally modulated by a color. See [member FontFile.multichannel_signed_distance_field] for more information and caveats about MSDF font rendering.
If [param outline] is positive, each alpha channel value of pixel in region is set to maximum value of true distance in the [param outline] radius.
@@ -404,7 +405,7 @@
<method name="get_canvas_transform" qualifiers="const">
<return type="Transform2D" />
<description>
- Returns the transform matrix of this item's canvas.
+ Returns the transform from the coordinate system of the canvas, this item is in, to the [Viewport]s coordinate system.
</description>
</method>
<method name="get_global_mouse_position" qualifiers="const">
@@ -422,7 +423,7 @@
<method name="get_global_transform_with_canvas" qualifiers="const">
<return type="Transform2D" />
<description>
- Returns the global transform matrix of this item in relation to the canvas.
+ Returns the transform from the local coordinate system of this [CanvasItem] to the [Viewport]s coordinate system.
</description>
</method>
<method name="get_local_mouse_position" qualifiers="const">
@@ -453,7 +454,7 @@
<method name="get_viewport_transform" qualifiers="const">
<return type="Transform2D" />
<description>
- Returns this item's transform in relation to the viewport.
+ Returns the transform from the coordinate system of the canvas, this item is in, to the [Viewport]s embedders coordinate system.
</description>
</method>
<method name="get_visibility_layer_bit" qualifiers="const">
diff --git a/doc/classes/CanvasLayer.xml b/doc/classes/CanvasLayer.xml
index 7c1b19b961..ce999c06d3 100644
--- a/doc/classes/CanvasLayer.xml
+++ b/doc/classes/CanvasLayer.xml
@@ -19,6 +19,12 @@
Returns the RID of the canvas used by this layer.
</description>
</method>
+ <method name="get_final_transform" qualifiers="const">
+ <return type="Transform2D" />
+ <description>
+ Returns the transform from the [CanvasLayer]s coordinate system to the [Viewport]s coordinate system.
+ </description>
+ </method>
<method name="hide">
<return type="void" />
<description>
diff --git a/doc/classes/CharacterBody3D.xml b/doc/classes/CharacterBody3D.xml
index 309e2231a4..821117122c 100644
--- a/doc/classes/CharacterBody3D.xml
+++ b/doc/classes/CharacterBody3D.xml
@@ -41,10 +41,16 @@
Returns a [KinematicCollision3D], which contains information about the latest collision that occurred during the last call to [method move_and_slide].
</description>
</method>
+ <method name="get_platform_angular_velocity" qualifiers="const">
+ <return type="Vector3" />
+ <description>
+ Returns the angular velocity of the platform at the last collision point. Only valid after calling [method move_and_slide].
+ </description>
+ </method>
<method name="get_platform_velocity" qualifiers="const">
<return type="Vector3" />
<description>
- Returns the linear velocity of the floor at the last collision point. Only valid after calling [method move_and_slide] and when [method is_on_floor] returns [code]true[/code].
+ Returns the linear velocity of the platform at the last collision point. Only valid after calling [method move_and_slide].
</description>
</method>
<method name="get_position_delta" qualifiers="const">
diff --git a/doc/classes/CheckBox.xml b/doc/classes/CheckBox.xml
index 699e872e99..3ee18cf351 100644
--- a/doc/classes/CheckBox.xml
+++ b/doc/classes/CheckBox.xml
@@ -43,6 +43,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
The [Font] to use for the [CheckBox] text.
diff --git a/doc/classes/CheckButton.xml b/doc/classes/CheckButton.xml
index dfbaa7cbee..03578cafd0 100644
--- a/doc/classes/CheckButton.xml
+++ b/doc/classes/CheckButton.xml
@@ -43,6 +43,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
The [Font] to use for the [CheckButton] text.
diff --git a/doc/classes/CodeEdit.xml b/doc/classes/CodeEdit.xml
index e7ef5fb289..3ceb8967a0 100644
--- a/doc/classes/CodeEdit.xml
+++ b/doc/classes/CodeEdit.xml
@@ -448,7 +448,7 @@
<member name="code_completion_enabled" type="bool" setter="set_code_completion_enabled" getter="is_code_completion_enabled" default="false">
Sets whether code completion is allowed.
</member>
- <member name="code_completion_prefixes" type="String[]" setter="set_code_completion_prefixes" getter="get_code_comletion_prefixes" default="[]">
+ <member name="code_completion_prefixes" type="String[]" setter="set_code_completion_prefixes" getter="get_code_completion_prefixes" default="[]">
Sets prefixes that will trigger code completion.
</member>
<member name="delimiter_comments" type="String[]" setter="set_comment_delimiters" getter="get_comment_delimiters" default="[]">
@@ -651,6 +651,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
Sets the default [Font].
diff --git a/doc/classes/Color.xml b/doc/classes/Color.xml
index 4d78433915..d1387d088d 100644
--- a/doc/classes/Color.xml
+++ b/doc/classes/Color.xml
@@ -205,11 +205,18 @@
<description>
Returns the [Color] associated with the provided [param hex] integer in 32-bit ARGB format (8 bits per channel, alpha channel first).
In GDScript and C#, the [int] is best visualized with hexadecimal notation ([code]"0x"[/code] prefix).
- [codeblock]
+ [codeblocks]
+ [gdscript]
var red = Color.hex(0xffff0000)
var dark_cyan = Color.hex(0xff008b8b)
var my_color = Color.hex(0xa4bbefd2)
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ var red = new Color(0xffff0000);
+ var dark_cyan = new Color(0xff008b8b);
+ var my_color = new Color(0xa4bbefd2);
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="hex64" qualifiers="static">
@@ -234,9 +241,9 @@
var col = Color.html("663399cc") # col is Color(0.4, 0.2, 0.6, 0.8)
[/gdscript]
[csharp]
- var blue = new Color("#0000ff"); // blue is Color(0.0, 0.0, 1.0, 1.0)
- var green = new Color("#0F0"); // green is Color(0.0, 1.0, 0.0, 1.0)
- var col = new Color("663399cc"); // col is Color(0.4, 0.2, 0.6, 0.8)
+ var blue = Color.FromHtml("#0000ff"); // blue is Color(0.0, 0.0, 1.0, 1.0)
+ var green = Color.FromHtml("#0F0"); // green is Color(0.0, 1.0, 0.0, 1.0)
+ var col = Color.FromHtml("663399cc"); // col is Color(0.4, 0.2, 0.6, 0.8)
[/csharp]
[/codeblocks]
</description>
@@ -257,14 +264,13 @@
Color.html_is_valid("#55aaFF5") # Returns false
[/gdscript]
[csharp]
- // This method is not available in C#. Use `StringExtensions.IsValidHtmlColor()`, instead.
- "#55AAFF".IsValidHtmlColor(); // Returns true
- "#55AAFF20".IsValidHtmlColor(); // Returns true
- "55AAFF".IsValidHtmlColor(); // Returns true
- "#F2C".IsValidHtmlColor(); // Returns true
+ Color.IsHtmlValid("#55AAFF"); // Returns true
+ Color.IsHtmlValid("#55AAFF20"); // Returns true
+ Color.IsHtmlValid("55AAFF"); // Returns true
+ Color.IsHtmlValid("#F2C"); // Returns true
- "#AABBC".IsValidHtmlColor(); // Returns false
- "#55aaFF5".IsValidHtmlColor(); // Returns false
+ Color.IsHtmlValid("#AABBC"); // Returns false
+ Color.IsHtmlValid("#55aaFF5"); // Returns false
[/csharp]
[/codeblocks]
</description>
diff --git a/doc/classes/ColorPicker.xml b/doc/classes/ColorPicker.xml
index 2b287d7546..823433c2df 100644
--- a/doc/classes/ColorPicker.xml
+++ b/doc/classes/ColorPicker.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="ColorPicker" inherits="BoxContainer" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="ColorPicker" inherits="VBoxContainer" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Color picker control.
</brief_description>
@@ -88,7 +88,6 @@
<member name="sliders_visible" type="bool" setter="set_sliders_visible" getter="are_sliders_visible" default="true">
If [code]true[/code], the color sliders are visible.
</member>
- <member name="vertical" type="bool" setter="set_vertical" getter="is_vertical" overrides="BoxContainer" default="true" />
</members>
<signals>
<signal name="color_changed">
diff --git a/doc/classes/ColorPickerButton.xml b/doc/classes/ColorPickerButton.xml
index b7a0bdfb0c..2a37cc162a 100644
--- a/doc/classes/ColorPickerButton.xml
+++ b/doc/classes/ColorPickerButton.xml
@@ -79,6 +79,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
[Font] of the [ColorPickerButton]'s text.
diff --git a/doc/classes/Control.xml b/doc/classes/Control.xml
index fd6aab6a49..b0351559ee 100644
--- a/doc/classes/Control.xml
+++ b/doc/classes/Control.xml
@@ -1050,6 +1050,9 @@
<member name="rotation" type="float" setter="set_rotation" getter="get_rotation" default="0.0">
The node's rotation around its pivot, in radians. See [member pivot_offset] to change the pivot's position.
</member>
+ <member name="rotation_degrees" type="float" setter="set_rotation_degrees" getter="get_rotation_degrees">
+ Helper property to access [member rotation] in degrees instead of radians.
+ </member>
<member name="scale" type="Vector2" setter="set_scale" getter="get_scale" default="Vector2(1, 1)">
The node's scale, relative to its [member size]. Change this property to scale the node around its [member pivot_offset]. The Control's [member tooltip_text] will also scale according to this value.
[b]Note:[/b] This property is mainly intended to be used for animation purposes. Text inside the Control will look pixelated or blurry when the Control is scaled. To support multiple resolutions in your project, use an appropriate viewport stretch mode as described in the [url=$DOCS_URL/tutorials/rendering/multiple_resolutions.html]documentation[/url] instead of scaling Controls individually.
diff --git a/doc/classes/Curve3D.xml b/doc/classes/Curve3D.xml
index cfe2036499..362d792b39 100644
--- a/doc/classes/Curve3D.xml
+++ b/doc/classes/Curve3D.xml
@@ -138,7 +138,7 @@
<param index="1" name="cubic" type="bool" default="false" />
<param index="2" name="apply_tilt" type="bool" default="false" />
<description>
- Similar with [code]interpolate_baked()[/code]. The the return value is [code]Transform3D[/code], with [code]origin[/code] as point position, [code]basis.x[/code] as sideway vector, [code]basis.y[/code] as up vector, [code]basis.z[/code] as forward vector. When the curve length is 0, there is no reasonable way to caculate the rotation, all vectors aligned with global space axes.
+ Similar with [code]interpolate_baked()[/code]. The the return value is [code]Transform3D[/code], with [code]origin[/code] as point position, [code]basis.x[/code] as sideway vector, [code]basis.y[/code] as up vector, [code]basis.z[/code] as forward vector. When the curve length is 0, there is no reasonable way to calculate the rotation, all vectors aligned with global space axes.
</description>
</method>
<method name="samplef" qualifiers="const">
diff --git a/doc/classes/Dictionary.xml b/doc/classes/Dictionary.xml
index 92225b816f..5f99ba82b8 100644
--- a/doc/classes/Dictionary.xml
+++ b/doc/classes/Dictionary.xml
@@ -135,7 +135,7 @@
[/csharp]
[/codeblocks]
[b]Note:[/b] Erasing elements while iterating over dictionaries is [b]not[/b] supported and will result in unpredictable behavior.
- [b]Note:[/b] When declaring a dictionary with [code]const[/code], the dictionary becomes read-only. A read-only Dictionary's entries cannot be overriden at run-time. This does [i]not[/i] affect nested [Array] and [Dictionary] values.
+ [b]Note:[/b] When declaring a dictionary with [code]const[/code], the dictionary becomes read-only. A read-only Dictionary's entries cannot be overridden at run-time. This does [i]not[/i] affect nested [Array] and [Dictionary] values.
</description>
<tutorials>
<link title="GDScript basics: Dictionary">$DOCS_URL/tutorials/scripting/gdscript/gdscript_basics.html#dictionary</link>
diff --git a/doc/classes/EditorPaths.xml b/doc/classes/EditorPaths.xml
index 2975ea6d75..929cf767a6 100644
--- a/doc/classes/EditorPaths.xml
+++ b/doc/classes/EditorPaths.xml
@@ -6,7 +6,7 @@
<description>
This editor-only singleton returns OS-specific paths to various data folders and files. It can be used in editor plugins to ensure files are saved in the correct location on each operating system.
[b]Note:[/b] This singleton is not accessible in exported projects. Attempting to access it in an exported project will result in a script error as the singleton won't be declared. To prevent script errors in exported projects, use [method Engine.has_singleton] to check whether the singleton is available before using it.
- [b]Note:[/b] Godot complies with the [url=https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html]XDG Base Directory Specification[/url] on [i]all[/i] platforms. You can override environment variables following the specification to change the editor and project data paths.
+ [b]Note:[/b] On the Linux/BSD platform, Godot complies with the [url=https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html]XDG Base Directory Specification[/url]. You can override environment variables following the specification to change the editor and project data paths.
</description>
<tutorials>
<link title="File paths in Godot projects">https://docs.godotengine.org/en/latest/tutorials/io/data_paths.html</link>
diff --git a/doc/classes/EditorScenePostImport.xml b/doc/classes/EditorScenePostImport.xml
index 2bf2accf17..d2ad8d1bed 100644
--- a/doc/classes/EditorScenePostImport.xml
+++ b/doc/classes/EditorScenePostImport.xml
@@ -28,12 +28,12 @@
// This sample changes all node names.
// Called right after the scene is imported and gets the root node.
[Tool]
- public class NodeRenamer : EditorScenePostImport
+ public partial class NodeRenamer : EditorScenePostImport
{
- public override Object PostImport(Object scene)
+ public override Object _PostImport(Node scene)
{
// Change all node names to "modified_[oldnodename]"
- Iterate(scene as Node);
+ Iterate(scene);
return scene; // Remember to return the imported scene
}
public void Iterate(Node node)
diff --git a/doc/classes/EditorSettings.xml b/doc/classes/EditorSettings.xml
index 865faa13ae..98f4789163 100644
--- a/doc/classes/EditorSettings.xml
+++ b/doc/classes/EditorSettings.xml
@@ -628,6 +628,9 @@
<member name="network/tls/editor_tls_certificates" type="String" setter="" getter="">
The TLS certificate bundle to use for HTTP requests made within the editor (e.g. from the AssetLib tab). If left empty, the [url=https://github.com/godotengine/godot/blob/master/thirdparty/certs/ca-certificates.crt]included Mozilla certificate bundle[/url] will be used.
</member>
+ <member name="project_manager/default_renderer" type="String" setter="" getter="">
+ The renderer type that will be checked off by default when creating a new project. Accepted strings are "forward_plus", "mobile" or "gl_compatibility".
+ </member>
<member name="project_manager/sorting_order" type="int" setter="" getter="">
The sorting order to use in the project manager. When changing the sorting order in the project manager, this setting is set permanently in the editor settings.
</member>
diff --git a/doc/classes/EditorSpinSlider.xml b/doc/classes/EditorSpinSlider.xml
index de105b32e1..d270d32df7 100644
--- a/doc/classes/EditorSpinSlider.xml
+++ b/doc/classes/EditorSpinSlider.xml
@@ -28,4 +28,26 @@
The suffix to display after the value (in a faded color). This should generally be a plural word. You may have to use an abbreviation if the suffix is too long to be displayed.
</member>
</members>
+ <signals>
+ <signal name="grabbed">
+ <description>
+ Emitted when the spinner/slider is grabbed.
+ </description>
+ </signal>
+ <signal name="ungrabbed">
+ <description>
+ Emitted when the spinner/slider is ungrabbed.
+ </description>
+ </signal>
+ <signal name="value_focus_entered">
+ <description>
+ Emitted when the value form gains focus.
+ </description>
+ </signal>
+ <signal name="value_focus_exited">
+ <description>
+ Emitted when the value form loses focus.
+ </description>
+ </signal>
+ </signals>
</class>
diff --git a/doc/classes/EditorUndoRedoManager.xml b/doc/classes/EditorUndoRedoManager.xml
index 133ee9db0d..cd96e740e8 100644
--- a/doc/classes/EditorUndoRedoManager.xml
+++ b/doc/classes/EditorUndoRedoManager.xml
@@ -123,6 +123,9 @@
<constant name="GLOBAL_HISTORY" value="0" enum="SpecialHistory">
Global history not associated with any scene, but with external resources etc.
</constant>
+ <constant name="REMOTE_HISTORY" value="-9" enum="SpecialHistory">
+ History associated with remote inspector. Used when live editing a running project.
+ </constant>
<constant name="INVALID_HISTORY" value="-99" enum="SpecialHistory">
Invalid "null" history. It's a special value, not associated with any object.
</constant>
diff --git a/doc/classes/EditorVCSInterface.xml b/doc/classes/EditorVCSInterface.xml
index b766978c04..85c10fefd9 100644
--- a/doc/classes/EditorVCSInterface.xml
+++ b/doc/classes/EditorVCSInterface.xml
@@ -53,7 +53,7 @@
</description>
</method>
<method name="_get_branch_list" qualifiers="virtual">
- <return type="Dictionary[]" />
+ <return type="String[]" />
<description>
Gets an instance of an [Array] of [String]s containing available branch names in the VCS.
</description>
@@ -94,7 +94,7 @@
</description>
</method>
<method name="_get_remotes" qualifiers="virtual">
- <return type="Dictionary[]" />
+ <return type="String[]" />
<description>
Returns an [Array] of [String]s, each containing the name of a remote configured in the VCS.
</description>
diff --git a/doc/classes/FontFile.xml b/doc/classes/FontFile.xml
index 1019c271dc..69a7627774 100644
--- a/doc/classes/FontFile.xml
+++ b/doc/classes/FontFile.xml
@@ -570,7 +570,7 @@
Weight (boldness) of the font. A value in the [code]100...999[/code] range, normal font weight is [code]400[/code], bold font weight is [code]700[/code].
</member>
<member name="force_autohinter" type="bool" setter="set_force_autohinter" getter="is_force_autohinter" default="false">
- If set to [code]true[/code], auto-hinting is supported and preferred over font built-in hinting. Used by dynamic fonts only.
+ If set to [code]true[/code], auto-hinting is supported and preferred over font built-in hinting. Used by dynamic fonts only (MSDF fonts don't support hinting).
</member>
<member name="generate_mipmaps" type="bool" setter="set_generate_mipmaps" getter="get_generate_mipmaps" default="false">
If set to [code]true[/code], generate mipmaps for the font textures.
@@ -579,25 +579,27 @@
Font hinting mode. Used by dynamic fonts only.
</member>
<member name="msdf_pixel_range" type="int" setter="set_msdf_pixel_range" getter="get_msdf_pixel_range" default="16">
- The width of the range around the shape between the minimum and maximum representable signed distance.
+ The width of the range around the shape between the minimum and maximum representable signed distance. If using font outlines, [member msdf_pixel_range] must be set to at least [i]twice[/i] the size of the largest font outline. The default [member msdf_pixel_range] value of [code]16[/code] allows outline sizes up to [code]8[/code] to look correct.
</member>
<member name="msdf_size" type="int" setter="set_msdf_size" getter="get_msdf_size" default="48">
- Source font size used to generate MSDF textures.
+ Source font size used to generate MSDF textures. Higher values allow for more precision, but are slower to render and require more memory. Only increase this value if you notice a visible lack of precision in glyph rendering.
</member>
<member name="multichannel_signed_distance_field" type="bool" setter="set_multichannel_signed_distance_field" getter="is_multichannel_signed_distance_field" default="false">
- If set to [code]true[/code], glyphs of all sizes are rendered using single multichannel signed distance field generated from the dynamic font vector data.
+ If set to [code]true[/code], glyphs of all sizes are rendered using single multichannel signed distance field (MSDF) generated from the dynamic font vector data. Since this approach does not rely on rasterizing the font every time its size changes, this allows for resizing the font in real-time without any performance penalty. Text will also not look grainy for [Control]s that are scaled down (or for [Label3D]s viewed from a long distance). As a downside, font hinting is not available with MSDF. The lack of font hinting may result in less crisp and less readable fonts at small sizes.
+ [b]Note:[/b] If using font outlines, [member msdf_pixel_range] must be set to at least [i]twice[/i] the size of the largest font outline.
+ [b]Note:[/b] MSDF font rendering does not render glyphs with overlapping shapes correctly. Overlapping shapes are not valid per the OpenType standard, but are still commonly found in many font files, especially those converted by Google Fonts. To avoid issues with overlapping glyphs, consider downloading the font file directly from the type foundry instead of relying on Google Fonts.
</member>
<member name="opentype_feature_overrides" type="Dictionary" setter="set_opentype_feature_overrides" getter="get_opentype_feature_overrides" default="{}">
Font OpenType feature set override.
</member>
<member name="oversampling" type="float" setter="set_oversampling" getter="get_oversampling" default="0.0">
- Font oversampling factor, if set to [code]0.0[/code] global oversampling factor is used instead. Used by dynamic fonts only.
+ Font oversampling factor. If set to [code]0.0[/code], the global oversampling factor is used instead. Used by dynamic fonts only (MSDF fonts ignore oversampling).
</member>
<member name="style_name" type="String" setter="set_font_style_name" getter="get_font_style_name" default="&quot;&quot;">
Font style name.
</member>
<member name="subpixel_positioning" type="int" setter="set_subpixel_positioning" getter="get_subpixel_positioning" enum="TextServer.SubpixelPositioning" default="1">
- Font glyph subpixel positioning mode. Subpixel positioning provides shaper text and better kerning for smaller font sizes, at the cost of memory usage and font rasterization speed. Use [constant TextServer.SUBPIXEL_POSITIONING_AUTO] to automatically enable it based on the font size.
+ Font glyph subpixel positioning mode. Subpixel positioning provides shaper text and better kerning for smaller font sizes, at the cost of higher memory usage and lower font rasterization speed. Use [constant TextServer.SUBPIXEL_POSITIONING_AUTO] to automatically enable it based on the font size.
</member>
</members>
</class>
diff --git a/doc/classes/NativeExtension.xml b/doc/classes/GDExtension.xml
index 50f976ca6f..9791290bd9 100644
--- a/doc/classes/NativeExtension.xml
+++ b/doc/classes/GDExtension.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NativeExtension" inherits="Resource" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="GDExtension" inherits="Resource" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
</brief_description>
<description>
@@ -13,13 +13,13 @@
</description>
</method>
<method name="get_minimum_library_initialization_level" qualifiers="const">
- <return type="int" enum="NativeExtension.InitializationLevel" />
+ <return type="int" enum="GDExtension.InitializationLevel" />
<description>
</description>
</method>
<method name="initialize_library">
<return type="void" />
- <param index="0" name="level" type="int" enum="NativeExtension.InitializationLevel" />
+ <param index="0" name="level" type="int" enum="GDExtension.InitializationLevel" />
<description>
</description>
</method>
diff --git a/doc/classes/NativeExtensionManager.xml b/doc/classes/GDExtensionManager.xml
index 7d6eefa94f..f682d800c6 100644
--- a/doc/classes/NativeExtensionManager.xml
+++ b/doc/classes/GDExtensionManager.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NativeExtensionManager" inherits="Object" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="GDExtensionManager" inherits="Object" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
</brief_description>
<description>
@@ -8,7 +8,7 @@
</tutorials>
<methods>
<method name="get_extension">
- <return type="NativeExtension" />
+ <return type="GDExtension" />
<param index="0" name="path" type="String" />
<description>
</description>
@@ -25,19 +25,19 @@
</description>
</method>
<method name="load_extension">
- <return type="int" enum="NativeExtensionManager.LoadStatus" />
+ <return type="int" enum="GDExtensionManager.LoadStatus" />
<param index="0" name="path" type="String" />
<description>
</description>
</method>
<method name="reload_extension">
- <return type="int" enum="NativeExtensionManager.LoadStatus" />
+ <return type="int" enum="GDExtensionManager.LoadStatus" />
<param index="0" name="path" type="String" />
<description>
</description>
</method>
<method name="unload_extension">
- <return type="int" enum="NativeExtensionManager.LoadStatus" />
+ <return type="int" enum="GDExtensionManager.LoadStatus" />
<param index="0" name="path" type="String" />
<description>
</description>
diff --git a/doc/classes/GeometryInstance3D.xml b/doc/classes/GeometryInstance3D.xml
index 90a983d28b..1ae4718536 100644
--- a/doc/classes/GeometryInstance3D.xml
+++ b/doc/classes/GeometryInstance3D.xml
@@ -16,13 +16,6 @@
Get the value of a shader parameter as set on this instance.
</description>
</method>
- <method name="set_custom_aabb">
- <return type="void" />
- <param index="0" name="aabb" type="AABB" />
- <description>
- Overrides the bounding box of this node with a custom one. To remove it, set an [AABB] with all fields set to zero.
- </description>
- </method>
<method name="set_instance_shader_parameter">
<return type="void" />
<param index="0" name="name" type="StringName" />
@@ -36,6 +29,9 @@
<member name="cast_shadow" type="int" setter="set_cast_shadows_setting" getter="get_cast_shadows_setting" enum="GeometryInstance3D.ShadowCastingSetting" default="1">
The selected shadow casting flag. See [enum ShadowCastingSetting] for possible values.
</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 bounding box of this node with a custom one. This can be used to avoid the expensive [AABB] recalculation that happens when a skeleton is used with a [MeshInstance3D] or to have fine control over the [MeshInstance3D]'s bounding box. To remove this, set value to an [AABB] with all fields set to zero.
+ </member>
<member name="extra_cull_margin" type="float" setter="set_extra_cull_margin" getter="get_extra_cull_margin" default="0.0">
The extra distance added to the GeometryInstance3D's bounding box ([AABB]) to increase its cull box.
</member>
diff --git a/doc/classes/Image.xml b/doc/classes/Image.xml
index be66b8a7b9..ed1b40488e 100644
--- a/doc/classes/Image.xml
+++ b/doc/classes/Image.xml
@@ -76,8 +76,12 @@
<param index="0" name="mode" type="int" enum="Image.CompressMode" />
<param index="1" name="source" type="int" enum="Image.CompressSource" default="0" />
<param index="2" name="lossy_quality" type="float" default="0.7" />
+ <param index="3" name="astc_format" type="int" enum="Image.ASTCFormat" default="0" />
<description>
- Compresses the image to use less memory. Can not directly access pixel data while the image is compressed. Returns error if the chosen compression mode is not available. See [enum CompressMode] and [enum CompressSource] constants.
+ Compresses the image to use less memory. Can not directly access pixel data while the image is compressed. Returns error if the chosen compression mode is not available.
+ The [param mode] parameter helps to pick the best compression method for DXT and ETC2 formats. It is ignored for ASTC compression.
+ The [param lossy_quality] parameter is optional for compressors that support it.
+ For ASTC compression, the [param astc_format] parameter must be supplied.
</description>
</method>
<method name="compress_from_channels">
@@ -85,7 +89,12 @@
<param index="0" name="mode" type="int" enum="Image.CompressMode" />
<param index="1" name="channels" type="int" enum="Image.UsedChannels" />
<param index="2" name="lossy_quality" type="float" default="0.7" />
+ <param index="3" name="astc_format" type="int" enum="Image.ASTCFormat" default="0" />
<description>
+ Compresses the image to use less memory. Can not directly access pixel data while the image is compressed. Returns error if the chosen compression mode is not available.
+ This is an alternative to [method compress] that lets the user supply the channels used in order for the compressor to pick the best DXT and ETC2 formats. For other formats (non DXT or ETC2), this argument is ignored.
+ The [param lossy_quality] parameter is optional for compressors that support it.
+ For ASTC compression, the [param astc_format] parameter must be supplied.
</description>
</method>
<method name="compute_image_metrics">
@@ -658,7 +667,19 @@
</constant>
<constant name="FORMAT_DXT5_RA_AS_RG" value="34" enum="Format">
</constant>
- <constant name="FORMAT_MAX" value="35" enum="Format">
+ <constant name="FORMAT_ASTC_4x4" value="35" enum="Format">
+ [url=https://en.wikipedia.org/wiki/Adaptive_scalable_texture_compression]Adaptive Scalable Texutre Compression[/url]. This implements the 4x4 (high quality) mode.
+ </constant>
+ <constant name="FORMAT_ASTC_4x4_HDR" value="36" enum="Format">
+ Same format as [constant FORMAT_ASTC_4x4], but with the hint to let the GPU know it is used for HDR.
+ </constant>
+ <constant name="FORMAT_ASTC_8x8" value="37" enum="Format">
+ [url=https://en.wikipedia.org/wiki/Adaptive_scalable_texture_compression]Adaptive Scalable Texutre Compression[/url]. This implements the 8x8 (low quality) mode.
+ </constant>
+ <constant name="FORMAT_ASTC_8x8_HDR" value="38" enum="Format">
+ Same format as [constant FORMAT_ASTC_8x8], but with the hint to let the GPU know it is used for HDR.
+ </constant>
+ <constant name="FORMAT_MAX" value="39" enum="Format">
Represents the size of the [enum Format] enum.
</constant>
<constant name="INTERPOLATE_NEAREST" value="0" enum="Interpolation">
@@ -722,5 +743,11 @@
<constant name="COMPRESS_SOURCE_NORMAL" value="2" enum="CompressSource">
Source texture (before compression) is a normal texture (e.g. it can be compressed into two channels).
</constant>
+ <constant name="ASTC_FORMAT_4x4" value="0" enum="ASTCFormat">
+ Hint to indicate that the high quality 4x4 ASTC compression format should be used.
+ </constant>
+ <constant name="ASTC_FORMAT_8x8" value="1" enum="ASTCFormat">
+ Hint to indicate that the low quality 8x8 ASTC compression format should be used.
+ </constant>
</constants>
</class>
diff --git a/doc/classes/Input.xml b/doc/classes/Input.xml
index d246e64251..be8c8ff83f 100644
--- a/doc/classes/Input.xml
+++ b/doc/classes/Input.xml
@@ -339,7 +339,7 @@
<param index="2" name="strong_magnitude" type="float" />
<param index="3" name="duration" type="float" default="0" />
<description>
- Starts to vibrate the joypad. Joypads usually come with two rumble motors, a strong and a weak one. [param weak_magnitude] is the strength of the weak motor (between 0 and 1) and [param strong_magnitude] is the strength of the strong motor (between 0 and 1). [param duration] is the duration of the effect in seconds (a duration of 0 will try to play the vibration indefinitely).
+ Starts to vibrate the joypad. Joypads usually come with two rumble motors, a strong and a weak one. [param weak_magnitude] is the strength of the weak motor (between 0 and 1) and [param strong_magnitude] is the strength of the strong motor (between 0 and 1). [param duration] is the duration of the effect in seconds (a duration of 0 will try to play the vibration indefinitely). The vibration can be stopped early by calling [method stop_joy_vibration].
[b]Note:[/b] Not every hardware is compatible with long effect durations; it is recommended to restart an effect if it has to be played for more than a few seconds.
</description>
</method>
@@ -347,18 +347,18 @@
<return type="void" />
<param index="0" name="device" type="int" />
<description>
- Stops the vibration of the joypad.
+ Stops the vibration of the joypad started with [method start_joy_vibration].
</description>
</method>
<method name="vibrate_handheld">
<return type="void" />
<param index="0" name="duration_ms" type="int" default="500" />
<description>
- Vibrate handheld devices.
- [b]Note:[/b] This method is implemented on Android, iOS, and Web.
- [b]Note:[/b] For Android, it requires enabling the [code]VIBRATE[/code] permission in the export preset.
- [b]Note:[/b] For iOS, specifying the duration is supported in iOS 13 and later.
- [b]Note:[/b] Some web browsers such as Safari and Firefox for Android do not support this method.
+ Vibrate the handheld device for the specified duration in milliseconds.
+ [b]Note:[/b] This method is implemented on Android, iOS, and Web. It has no effect on other platforms.
+ [b]Note:[/b] For Android, [method vibrate_handheld] requires enabling the [code]VIBRATE[/code] permission in the export preset. Otherwise, [method vibrate_handheld] will have no effect.
+ [b]Note:[/b] For iOS, specifying the duration is only supported in iOS 13 and later.
+ [b]Note:[/b] Some web browsers such as Safari and Firefox for Android do not support [method vibrate_handheld].
</description>
</method>
<method name="warp_mouse">
diff --git a/doc/classes/InputEventScreenDrag.xml b/doc/classes/InputEventScreenDrag.xml
index e5cc522b21..c1d126ca4a 100644
--- a/doc/classes/InputEventScreenDrag.xml
+++ b/doc/classes/InputEventScreenDrag.xml
@@ -13,12 +13,21 @@
<member name="index" type="int" setter="set_index" getter="get_index" default="0">
The drag event index in the case of a multi-drag event.
</member>
+ <member name="pen_inverted" type="bool" setter="set_pen_inverted" getter="get_pen_inverted" default="false">
+ Returns [code]true[/code] when using the eraser end of a stylus pen.
+ </member>
<member name="position" type="Vector2" setter="set_position" getter="get_position" default="Vector2(0, 0)">
The drag position.
</member>
+ <member name="pressure" type="float" setter="set_pressure" getter="get_pressure" default="0.0">
+ Represents the pressure the user puts on the pen. Ranges from [code]0.0[/code] to [code]1.0[/code].
+ </member>
<member name="relative" type="Vector2" setter="set_relative" getter="get_relative" default="Vector2(0, 0)">
The drag position relative to the previous position (position at the last frame).
</member>
+ <member name="tilt" type="Vector2" setter="set_tilt" getter="get_tilt" default="Vector2(0, 0)">
+ Represents the angles of tilt of the pen. Positive X-coordinate value indicates a tilt to the right. Positive Y-coordinate value indicates a tilt toward the user. Ranges from [code]-1.0[/code] to [code]1.0[/code] for both axes.
+ </member>
<member name="velocity" type="Vector2" setter="set_velocity" getter="get_velocity" default="Vector2(0, 0)">
The drag velocity.
</member>
diff --git a/doc/classes/ItemList.xml b/doc/classes/ItemList.xml
index 844f260971..c485d26e0c 100644
--- a/doc/classes/ItemList.xml
+++ b/doc/classes/ItemList.xml
@@ -459,6 +459,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the item text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="v_separation" data_type="constant" type="int" default="2">
The vertical spacing between items.
diff --git a/doc/classes/Label.xml b/doc/classes/Label.xml
index cd87b4558f..1a8cbf0584 100644
--- a/doc/classes/Label.xml
+++ b/doc/classes/Label.xml
@@ -111,6 +111,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
Text outline size.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="shadow_offset_x" data_type="constant" type="int" default="1">
The horizontal offset of the text's shadow.
diff --git a/doc/classes/LineEdit.xml b/doc/classes/LineEdit.xml
index e57cc68b36..b8383aaed9 100644
--- a/doc/classes/LineEdit.xml
+++ b/doc/classes/LineEdit.xml
@@ -424,6 +424,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
Font used for the text.
diff --git a/doc/classes/LinkButton.xml b/doc/classes/LinkButton.xml
index d7701ea184..b3938999f3 100644
--- a/doc/classes/LinkButton.xml
+++ b/doc/classes/LinkButton.xml
@@ -28,7 +28,23 @@
Base text writing direction.
</member>
<member name="underline" type="int" setter="set_underline_mode" getter="get_underline_mode" enum="LinkButton.UnderlineMode" default="0">
- Determines when to show the underline. See [enum UnderlineMode] for options.
+ The underline mode to use for the text. See [enum LinkButton.UnderlineMode] for the available modes.
+ </member>
+ <member name="uri" type="String" setter="set_uri" getter="get_uri" default="&quot;&quot;">
+ The [url=https://en.wikipedia.org/wiki/Uniform_Resource_Identifier]URI[/url] for this [LinkButton]. If set to a valid URI, pressing the button opens the URI using the operating system's default program for the protocol (via [method OS.shell_open]). HTTP and HTTPS URLs open the default web browser.
+ [b]Examples:[/b]
+ [codeblocks]
+ [gdscript]
+ uri = "https://godotengine.org" # Opens the URL in the default web browser.
+ uri = "C:\SomeFolder" # Opens the file explorer at the given path.
+ uri = "C:\SomeImage.png" # Opens the given image in the default viewing app.
+ [/gdscript]
+ [csharp]
+ Uri = "https://godotengine.org"; // Opens the URL in the default web browser.
+ Uri = "C:\SomeFolder"; // Opens the file explorer at the given path.
+ Uri = "C:\SomeImage.png"; // Opens the given image in the default viewing app.
+ [/csharp]
+ [/codeblocks]
</member>
</members>
<constants>
@@ -60,6 +76,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="underline_spacing" data_type="constant" type="int" default="2">
The vertical space between the baseline of text and the underline.
diff --git a/doc/classes/MenuBar.xml b/doc/classes/MenuBar.xml
index e8505937ff..79876e56a3 100644
--- a/doc/classes/MenuBar.xml
+++ b/doc/classes/MenuBar.xml
@@ -143,6 +143,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
[Font] of the menu item's text.
diff --git a/doc/classes/MenuButton.xml b/doc/classes/MenuButton.xml
index 4d5d5a011b..3061149570 100644
--- a/doc/classes/MenuButton.xml
+++ b/doc/classes/MenuButton.xml
@@ -75,6 +75,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
[Font] of the [MenuButton]'s text.
diff --git a/doc/classes/MeshLibrary.xml b/doc/classes/MeshLibrary.xml
index 85e57dd0f3..7c93ba5dce 100644
--- a/doc/classes/MeshLibrary.xml
+++ b/doc/classes/MeshLibrary.xml
@@ -59,14 +59,21 @@
Returns the item's name.
</description>
</method>
- <method name="get_item_navmesh" qualifiers="const">
+ <method name="get_item_navigation_layers" qualifiers="const">
+ <return type="int" />
+ <param index="0" name="id" type="int" />
+ <description>
+ Returns the item's navigation layers bitmask.
+ </description>
+ </method>
+ <method name="get_item_navigation_mesh" qualifiers="const">
<return type="NavigationMesh" />
<param index="0" name="id" type="int" />
<description>
Returns the item's navigation mesh.
</description>
</method>
- <method name="get_item_navmesh_transform" qualifiers="const">
+ <method name="get_item_navigation_mesh_transform" qualifiers="const">
<return type="Transform3D" />
<param index="0" name="id" type="int" />
<description>
@@ -126,18 +133,26 @@
This name is shown in the editor. It can also be used to look up the item later using [method find_item_by_name].
</description>
</method>
- <method name="set_item_navmesh">
+ <method name="set_item_navigation_layers">
+ <return type="void" />
+ <param index="0" name="id" type="int" />
+ <param index="1" name="navigation_layers" type="int" />
+ <description>
+ Sets the item's navigation layers bitmask.
+ </description>
+ </method>
+ <method name="set_item_navigation_mesh">
<return type="void" />
<param index="0" name="id" type="int" />
- <param index="1" name="navmesh" type="NavigationMesh" />
+ <param index="1" name="navigation_mesh" type="NavigationMesh" />
<description>
Sets the item's navigation mesh.
</description>
</method>
- <method name="set_item_navmesh_transform">
+ <method name="set_item_navigation_mesh_transform">
<return type="void" />
<param index="0" name="id" type="int" />
- <param index="1" name="navmesh" type="Transform3D" />
+ <param index="1" name="navigation_mesh" type="Transform3D" />
<description>
Sets the transform to apply to the item's navigation mesh.
</description>
diff --git a/doc/classes/NavigationAgent2D.xml b/doc/classes/NavigationAgent2D.xml
index 8cf7824ff7..31d347d76c 100644
--- a/doc/classes/NavigationAgent2D.xml
+++ b/doc/classes/NavigationAgent2D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationAgent2D" inherits="Node" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationAgent2D" inherits="Node" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
2D Agent used in navigation for collision avoidance.
</brief_description>
@@ -16,24 +16,30 @@
Returns the distance to the target location, using the agent's global position. The user must set [member target_location] in order for this to be accurate.
</description>
</method>
- <method name="get_final_location">
- <return type="Vector2" />
- <description>
- Returns the reachable final location in global coordinates. This can change if the navigation path is altered in any way. Because of this, it would be best to check this each frame.
- </description>
- </method>
- <method name="get_nav_path" qualifiers="const">
+ <method name="get_current_navigation_path" qualifiers="const">
<return type="PackedVector2Array" />
<description>
Returns this agent's current path from start to finish in global coordinates. The path only updates when the target location is changed or the agent requires a repath. The path array is not intended to be used in direct path movement as the agent has its own internal path logic that would get corrupted by changing the path array manually. Use the intended [method get_next_location] once every physics frame to receive the next path point for the agents movement as this function also updates the internal path logic.
</description>
</method>
- <method name="get_nav_path_index" qualifiers="const">
+ <method name="get_current_navigation_path_index" qualifiers="const">
<return type="int" />
<description>
Returns which index the agent is currently on in the navigation path's [PackedVector2Array].
</description>
</method>
+ <method name="get_current_navigation_result" qualifiers="const">
+ <return type="NavigationPathQueryResult2D" />
+ <description>
+ Returns the path query result for the path the agent is currently following.
+ </description>
+ </method>
+ <method name="get_final_location">
+ <return type="Vector2" />
+ <description>
+ Returns the reachable final location in global coordinates. This can change if the navigation path is altered in any way. Because of this, it would be best to check this each frame.
+ </description>
+ </method>
<method name="get_navigation_layer_value" qualifiers="const">
<return type="bool" />
<param index="0" name="layer_number" type="int" />
@@ -122,6 +128,9 @@
<member name="path_max_distance" type="float" setter="set_path_max_distance" getter="get_path_max_distance" default="3.0">
The maximum distance the agent is allowed away from the ideal path to the final location. This can happen due to trying to avoid collisions. When the maximum distance is exceeded, it recalculates the ideal path.
</member>
+ <member name="path_metadata_flags" type="int" setter="set_path_metadata_flags" getter="get_path_metadata_flags" enum="NavigationPathQueryParameters2D.PathMetadataFlags" default="7">
+ Additional information to return with the navigation path.
+ </member>
<member name="radius" type="float" setter="set_radius" getter="get_radius" default="10.0">
The radius of the avoidance agent. This is the "body" of the avoidance agent and not the avoidance maneuver starting radius (which is controlled by [member neighbor_distance]).
Does not affect normal pathfinding. To change an actor's pathfinding radius bake [NavigationMesh] resources with a different [member NavigationMesh.agent_radius] property and use different navigation maps for each actor size.
@@ -137,6 +146,17 @@
</member>
</members>
<signals>
+ <signal name="link_reached">
+ <param index="0" name="details" type="Dictionary" />
+ <description>
+ Notifies when a navigation link has been reached.
+ The details dictionary may contain the following keys depending on the value of [member path_metadata_flags]:
+ - [code]location[/code]: The start location of the link that was reached.
+ - [code]type[/code]: Always [constant NavigationPathQueryResult2D.PATH_SEGMENT_TYPE_LINK].
+ - [code]rid[/code]: The [RID] of the link.
+ - [code]owner[/code]: The object which manages the link (usually [NavigationLink2D]).
+ </description>
+ </signal>
<signal name="navigation_finished">
<description>
Notifies when the final location is reached.
@@ -158,5 +178,16 @@
Notifies when the collision avoidance velocity is calculated. Emitted by [method set_velocity]. Only emitted when [member avoidance_enabled] is true.
</description>
</signal>
+ <signal name="waypoint_reached">
+ <param index="0" name="details" type="Dictionary" />
+ <description>
+ Notifies when a waypoint along the path has been reached.
+ The details dictionary may contain the following keys depending on the value of [member path_metadata_flags]:
+ - [code]location[/code]: The location of the waypoint that was reached.
+ - [code]type[/code]: The type of navigation primitive (region or link) that contains this waypoint.
+ - [code]rid[/code]: The [RID] of the containing navigation primitive (region or link).
+ - [code]owner[/code]: The object which manages the containing navigation primitive (region or link).
+ </description>
+ </signal>
</signals>
</class>
diff --git a/doc/classes/NavigationAgent3D.xml b/doc/classes/NavigationAgent3D.xml
index 44c17647f7..c3f4809b5e 100644
--- a/doc/classes/NavigationAgent3D.xml
+++ b/doc/classes/NavigationAgent3D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationAgent3D" inherits="Node" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationAgent3D" inherits="Node" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
3D Agent used in navigation for collision avoidance.
</brief_description>
@@ -16,24 +16,30 @@
Returns the distance to the target location, using the agent's global position. The user must set [member target_location] in order for this to be accurate.
</description>
</method>
- <method name="get_final_location">
- <return type="Vector3" />
- <description>
- Returns the reachable final location in global coordinates. This can change if the navigation path is altered in any way. Because of this, it would be best to check this each frame.
- </description>
- </method>
- <method name="get_nav_path" qualifiers="const">
+ <method name="get_current_navigation_path" qualifiers="const">
<return type="PackedVector3Array" />
<description>
Returns this agent's current path from start to finish in global coordinates. The path only updates when the target location is changed or the agent requires a repath. The path array is not intended to be used in direct path movement as the agent has its own internal path logic that would get corrupted by changing the path array manually. Use the intended [method get_next_location] once every physics frame to receive the next path point for the agents movement as this function also updates the internal path logic.
</description>
</method>
- <method name="get_nav_path_index" qualifiers="const">
+ <method name="get_current_navigation_path_index" qualifiers="const">
<return type="int" />
<description>
Returns which index the agent is currently on in the navigation path's [PackedVector3Array].
</description>
</method>
+ <method name="get_current_navigation_result" qualifiers="const">
+ <return type="NavigationPathQueryResult3D" />
+ <description>
+ Returns the path query result for the path the agent is currently following.
+ </description>
+ </method>
+ <method name="get_final_location">
+ <return type="Vector3" />
+ <description>
+ Returns the reachable final location in global coordinates. This can change if the navigation path is altered in any way. Because of this, it would be best to check this each frame.
+ </description>
+ </method>
<method name="get_navigation_layer_value" qualifiers="const">
<return type="bool" />
<param index="0" name="layer_number" type="int" />
@@ -128,6 +134,9 @@
<member name="path_max_distance" type="float" setter="set_path_max_distance" getter="get_path_max_distance" default="3.0">
The maximum distance the agent is allowed away from the ideal path to the final location. This can happen due to trying to avoid collisions. When the maximum distance is exceeded, it recalculates the ideal path.
</member>
+ <member name="path_metadata_flags" type="int" setter="set_path_metadata_flags" getter="get_path_metadata_flags" enum="NavigationPathQueryParameters3D.PathMetadataFlags" default="7">
+ Additional information to return with the navigation path.
+ </member>
<member name="radius" type="float" setter="set_radius" getter="get_radius" default="1.0">
The radius of the avoidance agent. This is the "body" of the avoidance agent and not the avoidance maneuver starting radius (which is controlled by [member neighbor_distance]).
Does not affect normal pathfinding. To change an actor's pathfinding radius bake [NavigationMesh] resources with a different [member NavigationMesh.agent_radius] property and use different navigation maps for each actor size.
@@ -143,6 +152,17 @@
</member>
</members>
<signals>
+ <signal name="link_reached">
+ <param index="0" name="details" type="Dictionary" />
+ <description>
+ Notifies when a navigation link has been reached.
+ The details dictionary may contain the following keys depending on the value of [member path_metadata_flags]:
+ - [code]location[/code]: The start location of the link that was reached.
+ - [code]type[/code]: Always [constant NavigationPathQueryResult3D.PATH_SEGMENT_TYPE_LINK].
+ - [code]rid[/code]: The [RID] of the link.
+ - [code]owner[/code]: The object which manages the link (usually [NavigationLink3D]).
+ </description>
+ </signal>
<signal name="navigation_finished">
<description>
Notifies when the final location is reached.
@@ -164,5 +184,16 @@
Notifies when the collision avoidance velocity is calculated. Emitted by [method set_velocity]. Only emitted when [member avoidance_enabled] is true.
</description>
</signal>
+ <signal name="waypoint_reached">
+ <param index="0" name="details" type="Dictionary" />
+ <description>
+ Notifies when a waypoint along the path has been reached.
+ The details dictionary may contain the following keys depending on the value of [member path_metadata_flags]:
+ - [code]location[/code]: The location of the waypoint that was reached.
+ - [code]type[/code]: The type of navigation primitive (region or link) that contains this waypoint.
+ - [code]rid[/code]: The [RID] of the containing navigation primitive (region or link).
+ - [code]owner[/code]: The object which manages the containing navigation primitive (region or link).
+ </description>
+ </signal>
</signals>
</class>
diff --git a/doc/classes/NavigationLink2D.xml b/doc/classes/NavigationLink2D.xml
index 1e086fb730..9d75694360 100644
--- a/doc/classes/NavigationLink2D.xml
+++ b/doc/classes/NavigationLink2D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationLink2D" inherits="Node2D" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationLink2D" inherits="Node2D" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Creates a link between two locations that [NavigationServer2D] can route agents through.
</brief_description>
@@ -38,7 +38,7 @@
The distance the link will search is controlled by [method NavigationServer2D.map_set_link_connection_radius].
</member>
<member name="enter_cost" type="float" setter="set_enter_cost" getter="get_enter_cost" default="0.0">
- When pathfinding enters this link from another regions navmesh the [code]enter_cost[/code] value is added to the path distance for determining the shortest path.
+ When pathfinding enters this link from another regions navigation mesh the [code]enter_cost[/code] value is added to the path distance for determining the shortest path.
</member>
<member name="navigation_layers" type="int" setter="set_navigation_layers" getter="get_navigation_layers" default="1">
A bitfield determining all navigation layers the link belongs to. These navigation layers will be checked when requesting a path with [method NavigationServer2D.map_get_path].
diff --git a/doc/classes/NavigationLink3D.xml b/doc/classes/NavigationLink3D.xml
index 4d5d81bec5..730c43c5a8 100644
--- a/doc/classes/NavigationLink3D.xml
+++ b/doc/classes/NavigationLink3D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationLink3D" inherits="Node3D" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationLink3D" inherits="Node3D" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Creates a link between two locations that [NavigationServer3D] can route agents through.
</brief_description>
@@ -38,7 +38,7 @@
The distance the link will search is controlled by [method NavigationServer3D.map_set_link_connection_radius].
</member>
<member name="enter_cost" type="float" setter="set_enter_cost" getter="get_enter_cost" default="0.0">
- When pathfinding enters this link from another regions navmesh the [code]enter_cost[/code] value is added to the path distance for determining the shortest path.
+ When pathfinding enters this link from another regions navigation mesh the [code]enter_cost[/code] value is added to the path distance for determining the shortest path.
</member>
<member name="navigation_layers" type="int" setter="set_navigation_layers" getter="get_navigation_layers" default="1">
A bitfield determining all navigation layers the link belongs to. These navigation layers will be checked when requesting a path with [method NavigationServer3D.map_get_path].
diff --git a/doc/classes/NavigationMesh.xml b/doc/classes/NavigationMesh.xml
index c86bc47e04..ff898551d4 100644
--- a/doc/classes/NavigationMesh.xml
+++ b/doc/classes/NavigationMesh.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationMesh" inherits="Resource" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationMesh" inherits="Resource" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
A mesh to approximate the walkable areas and obstacles.
</brief_description>
@@ -133,13 +133,10 @@
<member name="geometry_source_geometry_mode" type="int" setter="set_source_geometry_mode" getter="get_source_geometry_mode" enum="NavigationMesh.SourceGeometryMode" default="0">
The source of the geometry used when baking. See [enum SourceGeometryMode] for possible values.
</member>
- <member name="geometry_source_group_name" type="StringName" setter="set_source_group_name" getter="get_source_group_name" default="&amp;&quot;navmesh&quot;">
+ <member name="geometry_source_group_name" type="StringName" setter="set_source_group_name" getter="get_source_group_name" default="&amp;&quot;navigation_mesh_source_group&quot;">
The name of the group to scan for geometry.
Only used when [member geometry_source_geometry_mode] is [constant SOURCE_GEOMETRY_GROUPS_WITH_CHILDREN] or [constant SOURCE_GEOMETRY_GROUPS_EXPLICIT].
</member>
- <member name="polygon_verts_per_poly" type="float" setter="set_verts_per_poly" getter="get_verts_per_poly" default="6.0">
- The maximum number of vertices allowed for polygons generated during the contour to polygon conversion process.
- </member>
<member name="region_merge_size" type="float" setter="set_region_merge_size" getter="get_region_merge_size" default="20.0">
Any regions with a size smaller than this will be merged with larger regions if possible.
[b]Note:[/b] This value will be squared to calculate the number of cells. For example, a value of 20 will set the number of cells to 400.
@@ -151,6 +148,9 @@
<member name="sample_partition_type" type="int" setter="set_sample_partition_type" getter="get_sample_partition_type" enum="NavigationMesh.SamplePartitionType" default="0">
Partitioning algorithm for creating the navigation mesh polys. See [enum SamplePartitionType] for possible values.
</member>
+ <member name="vertices_per_polygon" type="float" setter="set_vertices_per_polygon" getter="get_vertices_per_polygon" default="6.0">
+ The maximum number of vertices allowed for polygons generated during the contour to polygon conversion process.
+ </member>
</members>
<constants>
<constant name="SAMPLE_PARTITION_WATERSHED" value="0" enum="SamplePartitionType">
@@ -177,8 +177,8 @@
<constant name="PARSED_GEOMETRY_MAX" value="3" enum="ParsedGeometryType">
Represents the size of the [enum ParsedGeometryType] enum.
</constant>
- <constant name="SOURCE_GEOMETRY_NAVMESH_CHILDREN" value="0" enum="SourceGeometryMode">
- Scans the child nodes of [NavigationRegion3D] recursively for geometry.
+ <constant name="SOURCE_GEOMETRY_ROOT_NODE_CHILDREN" value="0" enum="SourceGeometryMode">
+ Scans the child nodes of the root node recursively for geometry.
</constant>
<constant name="SOURCE_GEOMETRY_GROUPS_WITH_CHILDREN" value="1" enum="SourceGeometryMode">
Scans nodes in a group and their child nodes recursively for geometry. The group is specified by [member geometry_source_group_name].
diff --git a/doc/classes/NavigationMeshGenerator.xml b/doc/classes/NavigationMeshGenerator.xml
index 4c337db90f..15d149a229 100644
--- a/doc/classes/NavigationMeshGenerator.xml
+++ b/doc/classes/NavigationMeshGenerator.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationMeshGenerator" inherits="Object" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationMeshGenerator" inherits="Object" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Helper class for creating and clearing navigation meshes.
</brief_description>
@@ -15,17 +15,17 @@
<methods>
<method name="bake">
<return type="void" />
- <param index="0" name="nav_mesh" type="NavigationMesh" />
+ <param index="0" name="navigation_mesh" type="NavigationMesh" />
<param index="1" name="root_node" type="Node" />
<description>
- Bakes navigation data to the provided [param nav_mesh] by parsing child nodes under the provided [param root_node] or a specific group of nodes for potential source geometry. The parse behavior can be controlled with the [member NavigationMesh.geometry_parsed_geometry_type] and [member NavigationMesh.geometry_source_geometry_mode] properties on the [NavigationMesh] resource.
+ Bakes navigation data to the provided [param navigation_mesh] by parsing child nodes under the provided [param root_node] or a specific group of nodes for potential source geometry. The parse behavior can be controlled with the [member NavigationMesh.geometry_parsed_geometry_type] and [member NavigationMesh.geometry_source_geometry_mode] properties on the [NavigationMesh] resource.
</description>
</method>
<method name="clear">
<return type="void" />
- <param index="0" name="nav_mesh" type="NavigationMesh" />
+ <param index="0" name="navigation_mesh" type="NavigationMesh" />
<description>
- Removes all polygons and vertices from the provided [param nav_mesh] resource.
+ Removes all polygons and vertices from the provided [param navigation_mesh] resource.
</description>
</method>
</methods>
diff --git a/doc/classes/NavigationObstacle2D.xml b/doc/classes/NavigationObstacle2D.xml
index 68d9691ccf..ce0f05ad28 100644
--- a/doc/classes/NavigationObstacle2D.xml
+++ b/doc/classes/NavigationObstacle2D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationObstacle2D" inherits="Node" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationObstacle2D" inherits="Node" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
2D Obstacle used in navigation for collision avoidance.
</brief_description>
diff --git a/doc/classes/NavigationObstacle3D.xml b/doc/classes/NavigationObstacle3D.xml
index 90eb55887f..78bbb788d9 100644
--- a/doc/classes/NavigationObstacle3D.xml
+++ b/doc/classes/NavigationObstacle3D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationObstacle3D" inherits="Node" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationObstacle3D" inherits="Node" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
3D Obstacle used in navigation for collision avoidance.
</brief_description>
diff --git a/doc/classes/NavigationPathQueryParameters2D.xml b/doc/classes/NavigationPathQueryParameters2D.xml
index 397ca8b713..511b2e7a8c 100644
--- a/doc/classes/NavigationPathQueryParameters2D.xml
+++ b/doc/classes/NavigationPathQueryParameters2D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationPathQueryParameters2D" inherits="RefCounted" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationPathQueryParameters2D" inherits="RefCounted" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Parameters to be sent to a 2D navigation path query.
</brief_description>
@@ -12,6 +12,9 @@
<member name="map" type="RID" setter="set_map" getter="get_map">
The navigation [code]map[/code] [RID] used in the path query.
</member>
+ <member name="metadata_flags" type="int" setter="set_metadata_flags" getter="get_metadata_flags" enum="NavigationPathQueryParameters2D.PathMetadataFlags" default="7">
+ Additional information to include with the navigation path.
+ </member>
<member name="navigation_layers" type="int" setter="set_navigation_layers" getter="get_navigation_layers" default="1">
The navigation layers the query will use (as a bitmask).
</member>
@@ -33,10 +36,25 @@
The path query uses the default A* pathfinding algorithm.
</constant>
<constant name="PATH_POSTPROCESSING_CORRIDORFUNNEL" value="0" enum="PathPostProcessing">
- Applies a funnel algorithm to the raw path corridor found by the pathfinding algorithm. This will result in the shortest path possible inside the path corridor. This postprocessing very much depends on the navmesh polygon layout and the created corridor. Especially tile- or gridbased layouts can face artificial corners with diagonal movement due to a jagged path corridor imposed by the cell shapes.
+ Applies a funnel algorithm to the raw path corridor found by the pathfinding algorithm. This will result in the shortest path possible inside the path corridor. This postprocessing very much depends on the navigation mesh polygon layout and the created corridor. Especially tile- or gridbased layouts can face artificial corners with diagonal movement due to a jagged path corridor imposed by the cell shapes.
</constant>
<constant name="PATH_POSTPROCESSING_EDGECENTERED" value="1" enum="PathPostProcessing">
- Centers every path position in the middle of the traveled navmesh polygon edge. This creates better paths for tile- or gridbased layouts that restrict the movement to the cells center.
+ Centers every path position in the middle of the traveled navigation mesh polygon edge. This creates better paths for tile- or gridbased layouts that restrict the movement to the cells center.
+ </constant>
+ <constant name="PATH_METADATA_INCLUDE_NONE" value="0" enum="PathMetadataFlags" is_bitfield="true">
+ Don't include any additional metadata about the returned path.
+ </constant>
+ <constant name="PATH_METADATA_INCLUDE_TYPES" value="1" enum="PathMetadataFlags" is_bitfield="true">
+ Include the type of navigation primitive (region or link) that each point of the path goes through.
+ </constant>
+ <constant name="PATH_METADATA_INCLUDE_RIDS" value="2" enum="PathMetadataFlags" is_bitfield="true">
+ Include the [RID]s of the regions and links that each point of the path goes through.
+ </constant>
+ <constant name="PATH_METADATA_INCLUDE_OWNERS" value="4" enum="PathMetadataFlags" is_bitfield="true">
+ Include the [code]ObjectID[/code]s of the [Object]s which manage the regions and links each point of the path goes through.
+ </constant>
+ <constant name="PATH_METADATA_INCLUDE_ALL" value="7" enum="PathMetadataFlags" is_bitfield="true">
+ Include all available metadata about the returned path.
</constant>
</constants>
</class>
diff --git a/doc/classes/NavigationPathQueryParameters3D.xml b/doc/classes/NavigationPathQueryParameters3D.xml
index 29faa5561b..b5031f60f2 100644
--- a/doc/classes/NavigationPathQueryParameters3D.xml
+++ b/doc/classes/NavigationPathQueryParameters3D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationPathQueryParameters3D" inherits="RefCounted" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationPathQueryParameters3D" inherits="RefCounted" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Parameters to be sent to a 3D navigation path query.
</brief_description>
@@ -12,6 +12,9 @@
<member name="map" type="RID" setter="set_map" getter="get_map">
The navigation [code]map[/code] [RID] used in the path query.
</member>
+ <member name="metadata_flags" type="int" setter="set_metadata_flags" getter="get_metadata_flags" enum="NavigationPathQueryParameters3D.PathMetadataFlags" default="7">
+ Additional information to include with the navigation path.
+ </member>
<member name="navigation_layers" type="int" setter="set_navigation_layers" getter="get_navigation_layers" default="1">
The navigation layers the query will use (as a bitmask).
</member>
@@ -33,10 +36,25 @@
The path query uses the default A* pathfinding algorithm.
</constant>
<constant name="PATH_POSTPROCESSING_CORRIDORFUNNEL" value="0" enum="PathPostProcessing">
- Applies a funnel algorithm to the raw path corridor found by the pathfinding algorithm. This will result in the shortest path possible inside the path corridor. This postprocessing very much depends on the navmesh polygon layout and the created corridor. Especially tile- or gridbased layouts can face artificial corners with diagonal movement due to a jagged path corridor imposed by the cell shapes.
+ Applies a funnel algorithm to the raw path corridor found by the pathfinding algorithm. This will result in the shortest path possible inside the path corridor. This postprocessing very much depends on the navigation mesh polygon layout and the created corridor. Especially tile- or gridbased layouts can face artificial corners with diagonal movement due to a jagged path corridor imposed by the cell shapes.
</constant>
<constant name="PATH_POSTPROCESSING_EDGECENTERED" value="1" enum="PathPostProcessing">
- Centers every path position in the middle of the traveled navmesh polygon edge. This creates better paths for tile- or gridbased layouts that restrict the movement to the cells center.
+ Centers every path position in the middle of the traveled navigation mesh polygon edge. This creates better paths for tile- or gridbased layouts that restrict the movement to the cells center.
+ </constant>
+ <constant name="PATH_METADATA_INCLUDE_NONE" value="0" enum="PathMetadataFlags" is_bitfield="true">
+ Don't include any additional metadata about the returned path.
+ </constant>
+ <constant name="PATH_METADATA_INCLUDE_TYPES" value="1" enum="PathMetadataFlags" is_bitfield="true">
+ Include the type of navigation primitive (region or link) that each point of the path goes through.
+ </constant>
+ <constant name="PATH_METADATA_INCLUDE_RIDS" value="2" enum="PathMetadataFlags" is_bitfield="true">
+ Include the [RID]s of the regions and links that each point of the path goes through.
+ </constant>
+ <constant name="PATH_METADATA_INCLUDE_OWNERS" value="4" enum="PathMetadataFlags" is_bitfield="true">
+ Include the [code]ObjectID[/code]s of the [Object]s which manage the regions and links each point of the path goes through.
+ </constant>
+ <constant name="PATH_METADATA_INCLUDE_ALL" value="7" enum="PathMetadataFlags" is_bitfield="true">
+ Include all available metadata about the returned path.
</constant>
</constants>
</class>
diff --git a/doc/classes/NavigationPathQueryResult2D.xml b/doc/classes/NavigationPathQueryResult2D.xml
index 95b90e9383..75f7cc47aa 100644
--- a/doc/classes/NavigationPathQueryResult2D.xml
+++ b/doc/classes/NavigationPathQueryResult2D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationPathQueryResult2D" inherits="RefCounted" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationPathQueryResult2D" inherits="RefCounted" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Result from a [NavigationPathQueryParameters2D] navigation path query.
</brief_description>
@@ -20,5 +20,22 @@
<member name="path" type="PackedVector2Array" setter="set_path" getter="get_path" default="PackedVector2Array()">
The resulting path array from the navigation query. All path array positions are in global coordinates. Without customized query parameters this is the same path as returned by [method NavigationServer2D.map_get_path].
</member>
+ <member name="path_owner_ids" type="PackedInt64Array" setter="set_path_owner_ids" getter="get_path_owner_ids" default="PackedInt64Array()">
+ The [code]ObjectID[/code]s of the [Object]s which manage the regions and links each point of the path goes through.
+ </member>
+ <member name="path_rids" type="RID[]" setter="set_path_rids" getter="get_path_rids" default="[]">
+ The [RID]s of the regions and links that each point of the path goes through.
+ </member>
+ <member name="path_types" type="PackedInt32Array" setter="set_path_types" getter="get_path_types" default="PackedInt32Array()">
+ The type of navigation primitive (region or link) that each point of the path goes through.
+ </member>
</members>
+ <constants>
+ <constant name="PATH_SEGMENT_TYPE_REGION" value="0" enum="PathSegmentType">
+ This segment of the path goes through a region.
+ </constant>
+ <constant name="PATH_SEGMENT_TYPE_LINK" value="1" enum="PathSegmentType">
+ This segment of the path goes through a link.
+ </constant>
+ </constants>
</class>
diff --git a/doc/classes/NavigationPathQueryResult3D.xml b/doc/classes/NavigationPathQueryResult3D.xml
index b4ca8288db..03d41cb230 100644
--- a/doc/classes/NavigationPathQueryResult3D.xml
+++ b/doc/classes/NavigationPathQueryResult3D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationPathQueryResult3D" inherits="RefCounted" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationPathQueryResult3D" inherits="RefCounted" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Result from a [NavigationPathQueryParameters3D] navigation path query.
</brief_description>
@@ -20,5 +20,22 @@
<member name="path" type="PackedVector3Array" setter="set_path" getter="get_path" default="PackedVector3Array()">
The resulting path array from the navigation query. All path array positions are in global coordinates. Without customized query parameters this is the same path as returned by [method NavigationServer3D.map_get_path].
</member>
+ <member name="path_owner_ids" type="PackedInt64Array" setter="set_path_owner_ids" getter="get_path_owner_ids" default="PackedInt64Array()">
+ The [code]ObjectID[/code]s of the [Object]s which manage the regions and links each point of the path goes through.
+ </member>
+ <member name="path_rids" type="RID[]" setter="set_path_rids" getter="get_path_rids" default="[]">
+ The [RID]s of the regions and links that each point of the path goes through.
+ </member>
+ <member name="path_types" type="PackedInt32Array" setter="set_path_types" getter="get_path_types" default="PackedInt32Array()">
+ The type of navigation primitive (region or link) that each point of the path goes through.
+ </member>
</members>
+ <constants>
+ <constant name="PATH_SEGMENT_TYPE_REGION" value="0" enum="PathSegmentType">
+ This segment of the path goes through a region.
+ </constant>
+ <constant name="PATH_SEGMENT_TYPE_LINK" value="1" enum="PathSegmentType">
+ This segment of the path goes through a link.
+ </constant>
+ </constants>
</class>
diff --git a/doc/classes/NavigationPolygon.xml b/doc/classes/NavigationPolygon.xml
index 19466c171f..b30dd2703a 100644
--- a/doc/classes/NavigationPolygon.xml
+++ b/doc/classes/NavigationPolygon.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationPolygon" inherits="Resource" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationPolygon" inherits="Resource" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
A node that has methods to draw outlines or use indices of vertices to create navigation polygons.
</brief_description>
@@ -12,14 +12,14 @@
var outline = PackedVector2Array([Vector2(0, 0), Vector2(0, 50), Vector2(50, 50), Vector2(50, 0)])
polygon.add_outline(outline)
polygon.make_polygons_from_outlines()
- $NavigationRegion2D.navpoly = polygon
+ $NavigationRegion2D.navigation_polygon = polygon
[/gdscript]
[csharp]
var polygon = new NavigationPolygon();
var outline = new Vector2[] { new Vector2(0, 0), new Vector2(0, 50), new Vector2(50, 50), new Vector2(50, 0) };
polygon.AddOutline(outline);
polygon.MakePolygonsFromOutlines();
- GetNode&lt;NavigationRegion2D&gt;("NavigationRegion2D").Navpoly = polygon;
+ GetNode&lt;NavigationRegion2D&gt;("NavigationRegion2D").NavigationPolygon = polygon;
[/csharp]
[/codeblocks]
Using [method add_polygon] and indices of the vertices array.
@@ -30,7 +30,7 @@
polygon.vertices = vertices
var indices = PackedInt32Array([0, 1, 2, 3])
polygon.add_polygon(indices)
- $NavigationRegion2D.navpoly = polygon
+ $NavigationRegion2D.navigation_polygon = polygon
[/gdscript]
[csharp]
var polygon = new NavigationPolygon();
@@ -38,7 +38,7 @@
polygon.Vertices = vertices;
var indices = new int[] { 0, 1, 2, 3 };
polygon.AddPolygon(indices);
- GetNode&lt;NavigationRegion2D&gt;("NavigationRegion2D").Navpoly = polygon;
+ GetNode&lt;NavigationRegion2D&gt;("NavigationRegion2D").NavigationPolygon = polygon;
[/csharp]
[/codeblocks]
</description>
@@ -80,10 +80,10 @@
Clears the array of polygons, but it doesn't clear the array of outlines and vertices.
</description>
</method>
- <method name="get_mesh">
+ <method name="get_navigation_mesh">
<return type="NavigationMesh" />
<description>
- Returns the [NavigationMesh] resulting from this navigation polygon. This navmesh can be used to update the navmesh of a region with the [method NavigationServer3D.region_set_navmesh] API directly (as 2D uses the 3D server behind the scene).
+ Returns the [NavigationMesh] resulting from this navigation polygon. This navigation mesh can be used to update the navigation mesh of a region with the [method NavigationServer3D.region_set_navigation_mesh] API directly (as 2D uses the 3D server behind the scene).
</description>
</method>
<method name="get_outline" qualifiers="const">
diff --git a/doc/classes/NavigationRegion2D.xml b/doc/classes/NavigationRegion2D.xml
index 0f28081201..8b8793b3b4 100644
--- a/doc/classes/NavigationRegion2D.xml
+++ b/doc/classes/NavigationRegion2D.xml
@@ -1,12 +1,12 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationRegion2D" inherits="Node2D" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationRegion2D" inherits="Node2D" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
A region of the 2D navigation map.
</brief_description>
<description>
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.
+ [b]Note:[/b] Overlapping two regions' navigation 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.
@@ -42,16 +42,16 @@
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 region's navmesh from another regions navmesh the [code]enter_cost[/code] value is added to the path distance for determining the shortest path.
+ When pathfinding enters this region's navigation mesh from another regions navigation mesh the [code]enter_cost[/code] value is added to the path distance for determining the shortest path.
</member>
<member name="navigation_layers" type="int" setter="set_navigation_layers" getter="get_navigation_layers" default="1">
A bitfield determining all navigation layers the region belongs to. These navigation 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">
+ <member name="navigation_polygon" 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 region's navmesh the traveled distances are multiplied with [code]travel_cost[/code] for determining the shortest path.
+ When pathfinding moves inside this region's navigation mesh 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 85f163b3c2..10662db869 100644
--- a/doc/classes/NavigationRegion3D.xml
+++ b/doc/classes/NavigationRegion3D.xml
@@ -1,12 +1,12 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationRegion3D" inherits="Node3D" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationRegion3D" inherits="Node3D" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
A region of the navigation map.
</brief_description>
<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.
+ [b]Note:[/b] Overlapping two regions' navigation meshes 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.
@@ -49,16 +49,16 @@
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 region's navmesh from another regions navmesh the [code]enter_cost[/code] value is added to the path distance for determining the shortest path.
+ When pathfinding enters this region's navigation mesh from another regions navigation mesh the [code]enter_cost[/code] value is added to the path distance for determining the shortest path.
</member>
<member name="navigation_layers" type="int" setter="set_navigation_layers" getter="get_navigation_layers" default="1">
A bitfield determining all navigation layers the region belongs to. These navigation 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">
+ <member name="navigation_mesh" 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 region's navmesh the traveled distances are multiplied with [code]travel_cost[/code] for determining the shortest path.
+ When pathfinding moves inside this region's navigation mesh the traveled distances are multiplied with [code]travel_cost[/code] for determining the shortest path.
</member>
</members>
<signals>
diff --git a/doc/classes/NavigationServer2D.xml b/doc/classes/NavigationServer2D.xml
index ab59add092..32e48cde54 100644
--- a/doc/classes/NavigationServer2D.xml
+++ b/doc/classes/NavigationServer2D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationServer2D" inherits="Object" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationServer2D" inherits="Object" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Server interface for low-level 2D navigation access
</brief_description>
@@ -40,12 +40,12 @@
<method name="agent_set_callback" qualifiers="const">
<return type="void" />
<param index="0" name="agent" type="RID" />
- <param index="1" name="receiver" type="Object" />
+ <param index="1" name="object_id" type="int" />
<param index="2" name="method" type="StringName" />
<param index="3" name="userdata" type="Variant" default="null" />
<description>
- Callback called at the end of the RVO process. If a callback is created manually and the agent is placed on a navigation map it will calculate avoidance for the agent and dispatch the calculated [code]safe_velocity[/code] to the [param receiver] object with a signal to the chosen [param method] name.
- [b]Note:[/b] Created callbacks are always processed independently of the SceneTree state as long as the agent is on a navigation map and not freed. To disable the dispatch of a callback from an agent use [method agent_set_callback] again with a [code]null[/code] object as the [param receiver].
+ Sets the callback [param object_id] and [param method] that gets called after each avoidance processing step for the [param agent]. The calculated [code]safe_velocity[/code] will be dispatched with a signal to the object just before the physics calculations.
+ [b]Note:[/b] Created callbacks are always processed independently of the SceneTree state as long as the agent is on a navigation map and not freed. To disable the dispatch of a callback from an agent use [method agent_set_callback] again with a [code]0[/code] ObjectID as the [param object_id].
</description>
</method>
<method name="agent_set_map" qualifiers="const">
@@ -489,12 +489,12 @@
Set the region's navigation layers. This allows selecting regions from a path request (when using [method NavigationServer2D.map_get_path]).
</description>
</method>
- <method name="region_set_navpoly" qualifiers="const">
+ <method name="region_set_navigation_polygon" qualifiers="const">
<return type="void" />
<param index="0" name="region" type="RID" />
- <param index="1" name="nav_poly" type="NavigationPolygon" />
+ <param index="1" name="navigation_polygon" type="NavigationPolygon" />
<description>
- Sets the navigation mesh for the region.
+ Sets the [param navigation_polygon] for the region.
</description>
</method>
<method name="region_set_owner_id" qualifiers="const">
diff --git a/doc/classes/NavigationServer3D.xml b/doc/classes/NavigationServer3D.xml
index 27a07eda90..c156dfac16 100644
--- a/doc/classes/NavigationServer3D.xml
+++ b/doc/classes/NavigationServer3D.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="NavigationServer3D" inherits="Object" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="NavigationServer3D" inherits="Object" is_experimental="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Server interface for low-level 3D navigation access
</brief_description>
@@ -40,12 +40,12 @@
<method name="agent_set_callback" qualifiers="const">
<return type="void" />
<param index="0" name="agent" type="RID" />
- <param index="1" name="receiver" type="Object" />
+ <param index="1" name="object_id" type="int" />
<param index="2" name="method" type="StringName" />
<param index="3" name="userdata" type="Variant" default="null" />
<description>
- Callback called at the end of the RVO process. If a callback is created manually and the agent is placed on a navigation map it will calculate avoidance for the agent and dispatch the calculated [code]safe_velocity[/code] to the [param receiver] object with a signal to the chosen [param method] name.
- [b]Note:[/b] Created callbacks are always processed independently of the SceneTree state as long as the agent is on a navigation map and not freed. To disable the dispatch of a callback from an agent use [method agent_set_callback] again with a [code]null[/code] object as the [param receiver].
+ Sets the callback [param object_id] and [param method] that gets called after each avoidance processing step for the [param agent]. The calculated [code]safe_velocity[/code] will be dispatched with a signal to the object just before the physics calculations.
+ [b]Note:[/b] Created callbacks are always processed independently of the SceneTree state as long as the agent is on a navigation map and not freed. To disable the dispatch of a callback from an agent use [method agent_set_callback] again with a [code]0[/code] ObjectID as the [param object_id].
</description>
</method>
<method name="agent_set_map" qualifiers="const">
@@ -433,12 +433,12 @@
Queries a path in a given navigation map. Start and target position and other parameters are defined through [NavigationPathQueryParameters3D]. Updates the provided [NavigationPathQueryResult3D] result object with the path among other results requested by the query.
</description>
</method>
- <method name="region_bake_navmesh" qualifiers="const">
+ <method name="region_bake_navigation_mesh" qualifiers="const">
<return type="void" />
- <param index="0" name="mesh" type="NavigationMesh" />
- <param index="1" name="node" type="Node" />
+ <param index="0" name="navigation_mesh" type="NavigationMesh" />
+ <param index="1" name="root_node" type="Node" />
<description>
- Bakes the navigation mesh.
+ Bakes the [param navigation_mesh] with bake source geometry collected starting from the [param root_node].
</description>
</method>
<method name="region_create" qualifiers="const">
@@ -539,10 +539,10 @@
Set the region's navigation layers. This allows selecting regions from a path request (when using [method NavigationServer3D.map_get_path]).
</description>
</method>
- <method name="region_set_navmesh" qualifiers="const">
+ <method name="region_set_navigation_mesh" qualifiers="const">
<return type="void" />
<param index="0" name="region" type="RID" />
- <param index="1" name="nav_mesh" type="NavigationMesh" />
+ <param index="1" name="navigation_mesh" type="NavigationMesh" />
<description>
Sets the navigation mesh for the region.
</description>
diff --git a/doc/classes/Node2D.xml b/doc/classes/Node2D.xml
index 26efe37dce..9d224f09b1 100644
--- a/doc/classes/Node2D.xml
+++ b/doc/classes/Node2D.xml
@@ -99,6 +99,9 @@
<member name="global_rotation" type="float" setter="set_global_rotation" getter="get_global_rotation">
Global rotation in radians.
</member>
+ <member name="global_rotation_degrees" type="float" setter="set_global_rotation_degrees" getter="get_global_rotation_degrees">
+ Helper property to access [member global_rotation] in degrees instead of radians.
+ </member>
<member name="global_scale" type="Vector2" setter="set_global_scale" getter="get_global_scale">
Global scale.
</member>
@@ -114,6 +117,9 @@
<member name="rotation" type="float" setter="set_rotation" getter="get_rotation" default="0.0">
Rotation in radians, relative to the node's parent.
</member>
+ <member name="rotation_degrees" type="float" setter="set_rotation_degrees" getter="get_rotation_degrees">
+ Helper property to access [member rotation] in degrees instead of radians.
+ </member>
<member name="scale" type="Vector2" setter="set_scale" getter="get_scale" default="Vector2(1, 1)">
The node's scale. Unscaled value: [code](1, 1)[/code].
[b]Note:[/b] Negative X scales in 2D are not decomposable from the transformation matrix. Due to the way scale is represented with transformation matrices in Godot, negative scales on the X axis will be changed to negative scales on the Y axis and a rotation of 180 degrees when decomposed.
diff --git a/doc/classes/Node3D.xml b/doc/classes/Node3D.xml
index b6024b1887..1aa71113e9 100644
--- a/doc/classes/Node3D.xml
+++ b/doc/classes/Node3D.xml
@@ -274,6 +274,9 @@
Rotation part of the global transformation in radians, specified in terms of YXZ-Euler angles in the format (X angle, Y angle, Z angle).
[b]Note:[/b] In the mathematical sense, rotation is a matrix and not a vector. The three Euler angles, which are the three independent parameters of the Euler-angle parametrization of the rotation matrix, are stored in a [Vector3] data structure not because the rotation is a vector, but only because [Vector3] exists as a convenient data-structure to store 3 floating-point numbers. Therefore, applying affine operations on the rotation "vector" is not meaningful.
</member>
+ <member name="global_rotation_degrees" type="Vector3" setter="set_global_rotation_degrees" getter="get_global_rotation_degrees">
+ Helper property to access [member global_rotation] in degrees instead of radians.
+ </member>
<member name="global_transform" type="Transform3D" setter="set_global_transform" getter="get_global_transform">
World3D space (global) [Transform3D] of this node.
</member>
@@ -287,6 +290,9 @@
Rotation part of the local transformation in radians, specified in terms of Euler angles. The angles construct a rotaton in the order specified by the [member rotation_order] property.
[b]Note:[/b] In the mathematical sense, rotation is a matrix and not a vector. The three Euler angles, which are the three independent parameters of the Euler-angle parametrization of the rotation matrix, are stored in a [Vector3] data structure not because the rotation is a vector, but only because [Vector3] exists as a convenient data-structure to store 3 floating-point numbers. Therefore, applying affine operations on the rotation "vector" is not meaningful.
</member>
+ <member name="rotation_degrees" type="Vector3" setter="set_rotation_degrees" getter="get_rotation_degrees">
+ Helper property to access [member rotation] in degrees instead of radians.
+ </member>
<member name="rotation_edit_mode" type="int" setter="set_rotation_edit_mode" getter="get_rotation_edit_mode" enum="Node3D.RotationEditMode" default="0">
Specify how rotation (and scale) will be presented in the editor.
</member>
diff --git a/doc/classes/OS.xml b/doc/classes/OS.xml
index 0efc6ab399..ff4982e2fb 100644
--- a/doc/classes/OS.xml
+++ b/doc/classes/OS.xml
@@ -654,63 +654,6 @@
<constant name="RENDERING_DRIVER_OPENGL3" value="1" enum="RenderingDriver">
The OpenGL 3 rendering driver. It uses OpenGL 3.3 Core Profile on desktop platforms, OpenGL ES 3.0 on mobile devices, and WebGL 2.0 on Web.
</constant>
- <constant name="DAY_SUNDAY" value="0" enum="Weekday">
- Sunday.
- </constant>
- <constant name="DAY_MONDAY" value="1" enum="Weekday">
- Monday.
- </constant>
- <constant name="DAY_TUESDAY" value="2" enum="Weekday">
- Tuesday.
- </constant>
- <constant name="DAY_WEDNESDAY" value="3" enum="Weekday">
- Wednesday.
- </constant>
- <constant name="DAY_THURSDAY" value="4" enum="Weekday">
- Thursday.
- </constant>
- <constant name="DAY_FRIDAY" value="5" enum="Weekday">
- Friday.
- </constant>
- <constant name="DAY_SATURDAY" value="6" enum="Weekday">
- Saturday.
- </constant>
- <constant name="MONTH_JANUARY" value="1" enum="Month">
- January.
- </constant>
- <constant name="MONTH_FEBRUARY" value="2" enum="Month">
- February.
- </constant>
- <constant name="MONTH_MARCH" value="3" enum="Month">
- March.
- </constant>
- <constant name="MONTH_APRIL" value="4" enum="Month">
- April.
- </constant>
- <constant name="MONTH_MAY" value="5" enum="Month">
- May.
- </constant>
- <constant name="MONTH_JUNE" value="6" enum="Month">
- June.
- </constant>
- <constant name="MONTH_JULY" value="7" enum="Month">
- July.
- </constant>
- <constant name="MONTH_AUGUST" value="8" enum="Month">
- August.
- </constant>
- <constant name="MONTH_SEPTEMBER" value="9" enum="Month">
- September.
- </constant>
- <constant name="MONTH_OCTOBER" value="10" enum="Month">
- October.
- </constant>
- <constant name="MONTH_NOVEMBER" value="11" enum="Month">
- November.
- </constant>
- <constant name="MONTH_DECEMBER" value="12" enum="Month">
- December.
- </constant>
<constant name="SYSTEM_DIR_DESKTOP" value="0" enum="SystemDir">
Desktop directory path.
</constant>
diff --git a/doc/classes/Object.xml b/doc/classes/Object.xml
index 5e834b3d91..e015bec134 100644
--- a/doc/classes/Object.xml
+++ b/doc/classes/Object.xml
@@ -8,7 +8,7 @@
You can create new instances, using [code]Object.new()[/code] in GDScript, or [code]new Object[/code] in C#.
To delete an Object instance, call [method free]. This is necessary for most classes inheriting Object, because they do not manage memory on their own, and will otherwise cause memory leaks when no longer in use. There are a few classes that perform memory management. For example, [RefCounted] (and by extension [Resource]) deletes itself when no longer referenced, and [Node] deletes its children when freed.
Objects can have a [Script] attached to them. Once the [Script] is instantiated, it effectively acts as an extension to the base class, allowing it to define and inherit new properties, methods and signals.
- Inside a [Script], [method _get_property_list] may be overriden to customize properties in several ways. This allows them to be available to the editor, display as lists of options, sub-divide into groups, save on disk, etc. Scripting languages offer easier ways to customize properties, such as with the [annotation @GDScript.@export] annotation.
+ Inside a [Script], [method _get_property_list] may be overridden to customize properties in several ways. This allows them to be available to the editor, display as lists of options, sub-divide into groups, save on disk, etc. Scripting languages offer easier ways to customize properties, such as with the [annotation @GDScript.@export] annotation.
Godot is very dynamic. An object's script, and therefore its properties, methods and signals, can be changed at run-time. Because of this, there can be occasions where, for example, a property required by a method may not exist. To prevent run-time errors, see methods such as [method set], [method get], [method call], [method has_method], [method has_signal], etc. Note that these methods are [b]much[/b] slower than direct references.
In GDScript, you can also check if a given property, method, or signal name exists in an object with the [code]in[/code] operator:
[codeblock]
diff --git a/doc/classes/OptionButton.xml b/doc/classes/OptionButton.xml
index e63e822648..fdf0fff0fb 100644
--- a/doc/classes/OptionButton.xml
+++ b/doc/classes/OptionButton.xml
@@ -94,6 +94,8 @@
<return type="int" />
<param index="0" name="from_last" type="bool" default="false" />
<description>
+ Returns the index of the first item which is not disabled, or marked as a separator. If [param from_last] is [code]true[/code], the items will be searched in reverse order.
+ Returns [code]-1[/code] if no item is found.
</description>
</method>
<method name="get_selected_id" qualifiers="const">
@@ -111,6 +113,7 @@
<method name="has_selectable_items" qualifiers="const">
<return type="bool" />
<description>
+ Returns [code]true[/code] if this button contains at least one item which is not disabled, or marked as a separator.
</description>
</method>
<method name="is_item_disabled" qualifiers="const">
@@ -124,6 +127,7 @@
<return type="bool" />
<param index="0" name="idx" type="int" />
<description>
+ Returns [code]true[/code] if the item at index [param idx] is marked as a separator.
</description>
</method>
<method name="remove_item">
@@ -259,6 +263,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
[Font] of the [OptionButton]'s text.
diff --git a/doc/classes/PathFollow3D.xml b/doc/classes/PathFollow3D.xml
index fa7580b7b6..01275471d0 100644
--- a/doc/classes/PathFollow3D.xml
+++ b/doc/classes/PathFollow3D.xml
@@ -15,7 +15,7 @@
<param index="0" name="transform" type="Transform3D" />
<param index="1" name="rotation_mode" type="int" enum="PathFollow3D.RotationMode" />
<description>
- Correct the [code]transform[/code]. [code]rotation_mode[/code] implicitly specifies how posture (forward, up and sideway direction) is caculated.
+ Correct the [code]transform[/code]. [code]rotation_mode[/code] implicitly specifies how posture (forward, up and sideway direction) is calculated.
</description>
</method>
</methods>
diff --git a/doc/classes/PhysicsServer2D.xml b/doc/classes/PhysicsServer2D.xml
index 18ac8a11df..f1316fa991 100644
--- a/doc/classes/PhysicsServer2D.xml
+++ b/doc/classes/PhysicsServer2D.xml
@@ -736,6 +736,14 @@
<description>
</description>
</method>
+ <method name="joint_disable_collisions_between_bodies">
+ <return type="void" />
+ <param index="0" name="joint" type="RID" />
+ <param index="1" name="disable" type="bool" />
+ <description>
+ Sets whether the bodies attached to the [Joint2D] will collide with each other.
+ </description>
+ </method>
<method name="joint_get_param" qualifiers="const">
<return type="float" />
<param index="0" name="joint" type="RID" />
@@ -751,6 +759,13 @@
Returns a joint's type (see [enum JointType]).
</description>
</method>
+ <method name="joint_is_disabled_collisions_between_bodies" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="joint" type="RID" />
+ <description>
+ Returns whether the bodies attached to the [Joint2D] will collide with each other.
+ </description>
+ </method>
<method name="joint_make_damped_spring">
<return type="void" />
<param index="0" name="joint" type="RID" />
@@ -790,6 +805,23 @@
Sets a joint parameter. See [enum JointParam] for a list of available parameters.
</description>
</method>
+ <method name="pin_joint_get_param" qualifiers="const">
+ <return type="float" />
+ <param index="0" name="joint" type="RID" />
+ <param index="1" name="param" type="int" enum="PhysicsServer2D.PinJointParam" />
+ <description>
+ Returns the value of a pin joint parameter. See [enum PinJointParam] for a list of available parameters.
+ </description>
+ </method>
+ <method name="pin_joint_set_param">
+ <return type="void" />
+ <param index="0" name="joint" type="RID" />
+ <param index="1" name="param" type="int" enum="PhysicsServer2D.PinJointParam" />
+ <param index="2" name="value" type="float" />
+ <description>
+ Sets a pin joint parameter. See [enum PinJointParam] for a list of available parameters.
+ </description>
+ </method>
<method name="rectangle_shape_create">
<return type="RID" />
<description>
diff --git a/doc/classes/PhysicsServer3D.xml b/doc/classes/PhysicsServer3D.xml
index 95f7fb69a2..e62bda0dd3 100644
--- a/doc/classes/PhysicsServer3D.xml
+++ b/doc/classes/PhysicsServer3D.xml
@@ -815,6 +815,14 @@
<description>
</description>
</method>
+ <method name="joint_disable_collisions_between_bodies">
+ <return type="void" />
+ <param index="0" name="joint" type="RID" />
+ <param index="1" name="disable" type="bool" />
+ <description>
+ Sets whether the bodies attached to the [Joint3D] will collide with each other.
+ </description>
+ </method>
<method name="joint_get_solver_priority" qualifiers="const">
<return type="int" />
<param index="0" name="joint" type="RID" />
@@ -829,6 +837,13 @@
Returns the type of the Joint3D.
</description>
</method>
+ <method name="joint_is_disabled_collisions_between_bodies" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="joint" type="RID" />
+ <description>
+ Returns whether the bodies attached to the [Joint3D] will collide with each other.
+ </description>
+ </method>
<method name="joint_make_cone_twist">
<return type="void" />
<param index="0" name="joint" type="RID" />
diff --git a/doc/classes/PhysicsServer3DExtension.xml b/doc/classes/PhysicsServer3DExtension.xml
index 1e9df54de5..d45cb17510 100644
--- a/doc/classes/PhysicsServer3DExtension.xml
+++ b/doc/classes/PhysicsServer3DExtension.xml
@@ -772,6 +772,13 @@
<description>
</description>
</method>
+ <method name="_joint_disable_collisions_between_bodies" qualifiers="virtual">
+ <return type="void" />
+ <param index="0" name="joint" type="RID" />
+ <param index="1" name="disable" type="bool" />
+ <description>
+ </description>
+ </method>
<method name="_joint_get_solver_priority" qualifiers="virtual const">
<return type="int" />
<param index="0" name="joint" type="RID" />
@@ -784,6 +791,12 @@
<description>
</description>
</method>
+ <method name="_joint_is_disabled_collisions_between_bodies" qualifiers="virtual const">
+ <return type="bool" />
+ <param index="0" name="joint" type="RID" />
+ <description>
+ </description>
+ </method>
<method name="_joint_make_cone_twist" qualifiers="virtual">
<return type="void" />
<param index="0" name="joint" type="RID" />
diff --git a/doc/classes/PopupMenu.xml b/doc/classes/PopupMenu.xml
index 6810b0e8e4..8dec4eaf86 100644
--- a/doc/classes/PopupMenu.xml
+++ b/doc/classes/PopupMenu.xml
@@ -584,6 +584,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the item text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="separator_outline_size" data_type="constant" type="int" default="0">
The size of the labeled separator text outline.
diff --git a/doc/classes/ProgressBar.xml b/doc/classes/ProgressBar.xml
index 510b8d5bd1..9f89a4e4c3 100644
--- a/doc/classes/ProgressBar.xml
+++ b/doc/classes/ProgressBar.xml
@@ -42,6 +42,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
Font used to draw the fill percentage if [member show_percentage] is [code]true[/code].
diff --git a/doc/classes/ProjectSettings.xml b/doc/classes/ProjectSettings.xml
index dce9d5a55c..d4c42e36eb 100644
--- a/doc/classes/ProjectSettings.xml
+++ b/doc/classes/ProjectSettings.xml
@@ -70,15 +70,18 @@
<method name="get_setting" qualifiers="const">
<return type="Variant" />
<param index="0" name="name" type="String" />
+ <param index="1" name="default_value" type="Variant" default="null" />
<description>
- Returns the value of a setting.
+ Returns the value of the setting identified by [param name]. If the setting doesn't exist and [param default_value] is specified, the value of [param default_value] is returned. Otherwise, [code]null[/code] is returned.
[b]Example:[/b]
[codeblocks]
[gdscript]
print(ProjectSettings.get_setting("application/config/name"))
+ print(ProjectSettings.get_setting("application/config/custom_description", "No description specified."))
[/gdscript]
[csharp]
GD.Print(ProjectSettings.GetSetting("application/config/name"));
+ GD.Print(ProjectSettings.GetSetting("application/config/custom_description", "No description specified."));
[/csharp]
[/codeblocks]
</description>
@@ -344,9 +347,6 @@
<member name="compression/formats/zstd/window_log_size" type="int" setter="" getter="" default="27">
Largest size limit (in power of 2) allowed when compressing using long-distance matching with Zstandard. Higher values can result in better compression, but will require more memory when compressing and decompressing.
</member>
- <member name="debug/disable_touch" type="bool" setter="" getter="" default="false">
- Disable touch input. Only has effect on iOS.
- </member>
<member name="debug/file_logging/enable_file_logging" type="bool" setter="" getter="" default="false">
If [code]true[/code], logs all output to files.
</member>
@@ -464,9 +464,6 @@
<member name="debug/gdscript/warnings/unused_variable" type="int" setter="" getter="" default="1">
When set to [code]warn[/code] or [code]error[/code], produces a warning or an error respectively when a local variable is unused.
</member>
- <member name="debug/gdscript/warnings/void_assignment" type="int" setter="" getter="" default="1">
- When set to [code]warn[/code] or [code]error[/code], produces a warning or an error respectively when assigning the result of a function that returns [code]void[/code] to a variable.
- </member>
<member name="debug/settings/crash_handler/message" type="String" setter="" getter="" default="&quot;Please include this when reporting the bug to the project developer.&quot;">
Message to be displayed before the backtrace when the engine crashes. By default, this message is only used in exported projects due to the editor-only override applied to this setting.
</member>
@@ -585,7 +582,7 @@
[b]Note:[/b] This setting has no effect on the home indicator if [code]hide_home_indicator[/code] is [code]true[/code].
</member>
<member name="display/window/per_pixel_transparency/allowed" type="bool" setter="" getter="" default="false">
- If [code]true[/code], allows per-pixel transparency for the window background. This affects performance, so leave it on [code]false[/code] unless you need it. See also [member display/window/size/transparent] and [member rendering/transparent_background].
+ If [code]true[/code], allows per-pixel transparency for the window background. This affects performance, so leave it on [code]false[/code] unless you need it. See also [member display/window/size/transparent] and [member rendering/viewport/transparent_background].
</member>
<member name="display/window/size/always_on_top" type="bool" setter="" getter="" default="false">
Forces the main window to be always on top.
@@ -610,7 +607,7 @@
[b]Note:[/b] This setting is ignored on iOS.
</member>
<member name="display/window/size/transparent" type="bool" setter="" getter="" default="false">
- If [code]true[/code], enables a window manager hint that the main window background [i]can[/i] be transparent. This does not make the background actually transparent. For the background to be transparent, the root viewport must also be made transparent by enabling [member rendering/transparent_background].
+ If [code]true[/code], enables a window manager hint that the main window background [i]can[/i] be transparent. This does not make the background actually transparent. For the background to be transparent, the root viewport must also be made transparent by enabling [member rendering/viewport/transparent_background].
[b]Note:[/b] To use a transparent splash screen, set [member application/boot_splash/bg_color] to [code]Color(0, 0, 0, 0)[/code].
[b]Note:[/b] This setting has no effect if [member display/window/per_pixel_transparency/allowed] is set to [code]false[/code].
</member>
@@ -1895,9 +1892,6 @@
<member name="rendering/environment/glow/upscale_mode.mobile" type="int" setter="" getter="" default="0">
Lower-end override for [member rendering/environment/glow/upscale_mode] on mobile devices, due to performance concerns or driver support.
</member>
- <member name="rendering/environment/glow/use_high_quality" type="bool" setter="" getter="" default="false">
- Takes more samples during downsample pass of glow. This ensures that single pixels are captured by glow which makes the glow look smoother and more stable during movement. However, it is very expensive and makes the glow post process take twice as long.
- </member>
<member name="rendering/environment/screen_space_reflection/roughness_quality" type="int" setter="" getter="" default="1">
Sets the quality for rough screen-space reflections. Turning off will make all screen space reflections sharp, while higher values make rough reflections look better.
</member>
@@ -2259,7 +2253,7 @@
<member name="rendering/textures/webp_compression/lossless_compression_factor" type="float" setter="" getter="" default="25">
The default compression factor for lossless WebP. Decompression speed is mostly unaffected by the compression factor. Supported values are 0 to 100.
</member>
- <member name="rendering/transparent_background" type="bool" setter="" getter="" default="false">
+ <member name="rendering/viewport/transparent_background" type="bool" setter="" getter="" default="false">
If [code]true[/code], enables [member Viewport.transparent_bg] on the root viewport. This allows per-pixel transparency to be effective after also enabling [member display/window/size/transparent] and [member display/window/per_pixel_transparency/allowed].
</member>
<member name="rendering/vrs/mode" type="int" setter="" getter="" default="0">
diff --git a/doc/classes/RenderingDevice.xml b/doc/classes/RenderingDevice.xml
index 797231ac5e..f318430611 100644
--- a/doc/classes/RenderingDevice.xml
+++ b/doc/classes/RenderingDevice.xml
@@ -504,7 +504,7 @@
<return type="RID" />
<param index="0" name="size_bytes" type="int" />
<param index="1" name="data" type="PackedByteArray" default="PackedByteArray()" />
- <param index="2" name="usage" type="int" default="0" />
+ <param index="2" name="usage" type="int" enum="RenderingDevice.StorageBufferUsage" default="0" />
<description>
</description>
</method>
@@ -1273,7 +1273,7 @@
</constant>
<constant name="INDEX_BUFFER_FORMAT_UINT32" value="1" enum="IndexBufferFormat">
</constant>
- <constant name="STORAGE_BUFFER_USAGE_DISPATCH_INDIRECT" value="1" enum="StorageBufferUsage">
+ <constant name="STORAGE_BUFFER_USAGE_DISPATCH_INDIRECT" value="1" enum="StorageBufferUsage" is_bitfield="true">
</constant>
<constant name="UNIFORM_TYPE_SAMPLER" value="0" enum="UniformType">
</constant>
diff --git a/doc/classes/RenderingServer.xml b/doc/classes/RenderingServer.xml
index fc05f67416..87e569ba20 100644
--- a/doc/classes/RenderingServer.xml
+++ b/doc/classes/RenderingServer.xml
@@ -241,6 +241,7 @@
<param index="4" name="modulate" type="Color" default="Color(1, 1, 1, 1)" />
<param index="5" name="outline_size" type="int" default="0" />
<param index="6" name="px_range" type="float" default="1.0" />
+ <param index="7" name="scale" type="float" default="1.0" />
<description>
</description>
</method>
@@ -962,12 +963,6 @@
<description>
</description>
</method>
- <method name="environment_glow_set_use_high_quality">
- <return type="void" />
- <param index="0" name="enable" type="bool" />
- <description>
- </description>
- </method>
<method name="environment_set_adjustment">
<return type="void" />
<param index="0" name="env" type="RID" />
@@ -1565,7 +1560,7 @@
<param index="0" name="instance" type="RID" />
<param index="1" name="aabb" type="AABB" />
<description>
- Sets a custom AABB to use when culling objects from the view frustum. Equivalent to [method GeometryInstance3D.set_custom_aabb].
+ Sets a custom AABB to use when culling objects from the view frustum. Equivalent to setting [member GeometryInstance3D.custom_aabb].
</description>
</method>
<method name="instance_set_extra_visibility_margin">
@@ -1591,6 +1586,15 @@
Sets the render layers that this instance will be drawn to. Equivalent to [member VisualInstance3D.layers].
</description>
</method>
+ <method name="instance_set_pivot_data">
+ <return type="void" />
+ <param index="0" name="instance" type="RID" />
+ <param index="1" name="sorting_offset" type="float" />
+ <param index="2" name="use_aabb_center" type="bool" />
+ <description>
+ Sets the sorting offset and switches between using the bounding box or instance origin for depth sorting.
+ </description>
+ </method>
<method name="instance_set_scenario">
<return type="void" />
<param index="0" name="instance" type="RID" />
diff --git a/doc/classes/RichTextLabel.xml b/doc/classes/RichTextLabel.xml
index e222894647..dd291a425d 100644
--- a/doc/classes/RichTextLabel.xml
+++ b/doc/classes/RichTextLabel.xml
@@ -367,6 +367,7 @@
<return type="void" />
<param index="0" name="columns" type="int" />
<param index="1" name="inline_align" type="int" enum="InlineAlignment" default="0" />
+ <param index="2" name="align_to_row" type="int" default="-1" />
<description>
Adds a [code][table=columns,inline_align][/code] tag to the tag stack.
</description>
@@ -377,12 +378,12 @@
Adds a [code][u][/code] tag to the tag stack.
</description>
</method>
- <method name="remove_line">
+ <method name="remove_paragraph">
<return type="bool" />
- <param index="0" name="line" type="int" />
+ <param index="0" name="paragraph" type="int" />
<description>
- Removes a line of content from the label. Returns [code]true[/code] if the line exists.
- The [param line] argument is the index of the line to remove, it can take values in the interval [code][0, get_line_count() - 1][/code].
+ Removes a paragraph of content from the label. Returns [code]true[/code] if the paragraph exists.
+ The [param paragraph] argument is the index of the paragraph to remove, it can take values in the interval [code][0, get_paragraph_count() - 1][/code].
</description>
</method>
<method name="scroll_to_line">
@@ -655,6 +656,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="shadow_offset_x" data_type="constant" type="int" default="1">
The horizontal offset of the font's shadow.
diff --git a/doc/classes/SpriteFrames.xml b/doc/classes/SpriteFrames.xml
index e9721495dd..87b823bd2a 100644
--- a/doc/classes/SpriteFrames.xml
+++ b/doc/classes/SpriteFrames.xml
@@ -20,8 +20,9 @@
<method name="add_frame">
<return type="void" />
<param index="0" name="anim" type="StringName" />
- <param index="1" name="frame" type="Texture2D" />
- <param index="2" name="at_position" type="int" default="-1" />
+ <param index="1" name="texture" type="Texture2D" />
+ <param index="2" name="duration" type="float" default="1.0" />
+ <param index="3" name="at_position" type="int" default="-1" />
<description>
Adds a frame to the given animation.
</description>
@@ -56,22 +57,34 @@
<return type="float" />
<param index="0" name="anim" type="StringName" />
<description>
- The animation's speed in frames per second.
+ Returns the speed in frames per second for the [param anim] animation.
</description>
</method>
- <method name="get_frame" qualifiers="const">
- <return type="Texture2D" />
+ <method name="get_frame_count" qualifiers="const">
+ <return type="int" />
+ <param index="0" name="anim" type="StringName" />
+ <description>
+ Returns the number of frames for the [param anim] animation.
+ </description>
+ </method>
+ <method name="get_frame_duration" qualifiers="const">
+ <return type="float" />
<param index="0" name="anim" type="StringName" />
<param index="1" name="idx" type="int" />
<description>
- Returns the animation's selected frame.
+ Returns a relative duration of the frame [param idx] in the [param anim] animation (defaults to [code]1.0[/code]). For example, a frame with a duration of [code]2.0[/code] is displayed twice as long as a frame with a duration of [code]1.0[/code]. You can calculate the absolute duration (in seconds) of a frame using the following formula:
+ [codeblock]
+ absolute_duration = relative_duration / (animation_fps * abs(speed_scale))
+ [/codeblock]
+ In this example, [code]speed_scale[/code] refers to either [member AnimatedSprite2D.speed_scale] or [member AnimatedSprite3D.speed_scale].
</description>
</method>
- <method name="get_frame_count" qualifiers="const">
- <return type="int" />
+ <method name="get_frame_texture" qualifiers="const">
+ <return type="Texture2D" />
<param index="0" name="anim" type="StringName" />
+ <param index="1" name="idx" type="int" />
<description>
- Returns the number of frames in the animation.
+ Returns the texture of the frame [param idx] in the [param anim] animation.
</description>
</method>
<method name="has_animation" qualifiers="const">
@@ -115,18 +128,19 @@
<method name="set_animation_speed">
<return type="void" />
<param index="0" name="anim" type="StringName" />
- <param index="1" name="speed" type="float" />
+ <param index="1" name="fps" type="float" />
<description>
- The animation's speed in frames per second.
+ Sets the speed for the [param anim] animation in frames per second.
</description>
</method>
<method name="set_frame">
<return type="void" />
<param index="0" name="anim" type="StringName" />
<param index="1" name="idx" type="int" />
- <param index="2" name="txt" type="Texture2D" />
+ <param index="2" name="texture" type="Texture2D" />
+ <param index="3" name="duration" type="float" default="1.0" />
<description>
- Sets the texture of the given frame.
+ Sets the texture and the duration of the frame [param idx] in the [param anim] animation.
</description>
</method>
</methods>
diff --git a/doc/classes/String.xml b/doc/classes/String.xml
index d5624aeaa2..97466e7860 100644
--- a/doc/classes/String.xml
+++ b/doc/classes/String.xml
@@ -237,7 +237,7 @@
<description>
If the string is a valid file path, returns the base directory name.
[codeblock]
- var dir_path = "/path/to/file.txt".get_basename() # dir_path is "/path/to"
+ var dir_path = "/path/to/file.txt".get_base_dir() # dir_path is "/path/to"
[/codeblock]
</description>
</method>
@@ -973,11 +973,11 @@
[codeblocks]
[gdscript]
var url = "$DOCS_URL/?highlight=Godot%20Engine%3%docs"
- print(url.uri_decode()) # Prints "$DOCS_URL/?hightlight=Godot Engine:docs"
+ print(url.uri_decode()) # Prints "$DOCS_URL/?highlight=Godot Engine:docs"
[/gdscript]
[csharp]
var url = "$DOCS_URL/?highlight=Godot%20Engine%3%docs"
- GD.Print(url.URIDecode()) // Prints "$DOCS_URL/?hightlight=Godot Engine:docs"
+ GD.Print(url.URIDecode()) // Prints "$DOCS_URL/?highlight=Godot Engine:docs"
[/csharp]
[/codeblocks]
</description>
@@ -988,13 +988,13 @@
Encodes the string to URL-friendly format. This method is meant to properly encode the parameters in a URL when sending an HTTP request.
[codeblocks]
[gdscript]
- var prefix = "$DOCS_URL/?hightlight="
+ var prefix = "$DOCS_URL/?highlight="
var url = prefix + "Godot Engine:docs".uri_encode()
print(url) # Prints "$DOCS_URL/?highlight=Godot%20Engine%3%docs"
[/gdscript]
[csharp]
- var prefix = "$DOCS_URL/?hightlight=";
+ var prefix = "$DOCS_URL/?highlight=";
var url = prefix + "Godot Engine:docs".URIEncode();
GD.Print(url); // Prints "$DOCS_URL/?highlight=Godot%20Engine%3%docs"
diff --git a/doc/classes/StringName.xml b/doc/classes/StringName.xml
index e3cb6517f3..b46e39b8d7 100644
--- a/doc/classes/StringName.xml
+++ b/doc/classes/StringName.xml
@@ -220,7 +220,7 @@
<description>
If the string is a valid file path, returns the base directory name.
[codeblock]
- var dir_path = "/path/to/file.txt".get_basename() # dir_path is "/path/to"
+ var dir_path = "/path/to/file.txt".get_base_dir() # dir_path is "/path/to"
[/codeblock]
</description>
</method>
@@ -880,11 +880,11 @@
[codeblocks]
[gdscript]
var url = "$DOCS_URL/?highlight=Godot%20Engine%3%docs"
- print(url.uri_decode()) # Prints "$DOCS_URL/?hightlight=Godot Engine:docs"
+ print(url.uri_decode()) # Prints "$DOCS_URL/?highlight=Godot Engine:docs"
[/gdscript]
[csharp]
var url = "$DOCS_URL/?highlight=Godot%20Engine%3%docs"
- GD.Print(url.URIDecode()) // Prints "$DOCS_URL/?hightlight=Godot Engine:docs"
+ GD.Print(url.URIDecode()) // Prints "$DOCS_URL/?highlight=Godot Engine:docs"
[/csharp]
[/codeblocks]
</description>
@@ -895,13 +895,13 @@
Encodes the string to URL-friendly format. This method is meant to properly encode the parameters in a URL when sending an HTTP request.
[codeblocks]
[gdscript]
- var prefix = "$DOCS_URL/?hightlight="
+ var prefix = "$DOCS_URL/?highlight="
var url = prefix + "Godot Engine:docs".uri_encode()
print(url) # Prints "$DOCS_URL/?highlight=Godot%20Engine%3%docs"
[/gdscript]
[csharp]
- var prefix = "$DOCS_URL/?hightlight=";
+ var prefix = "$DOCS_URL/?highlight=";
var url = prefix + "Godot Engine:docs".URIEncode();
GD.Print(url); // Prints "$DOCS_URL/?highlight=Godot%20Engine%3%docs"
diff --git a/doc/classes/TabBar.xml b/doc/classes/TabBar.xml
index 713c016651..8d56cbda13 100644
--- a/doc/classes/TabBar.xml
+++ b/doc/classes/TabBar.xml
@@ -319,6 +319,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the tab text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
The font used to draw tab names.
diff --git a/doc/classes/TabContainer.xml b/doc/classes/TabContainer.xml
index e2e7a0c37e..c744c9b439 100644
--- a/doc/classes/TabContainer.xml
+++ b/doc/classes/TabContainer.xml
@@ -214,6 +214,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the tab text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="side_margin" data_type="constant" type="int" default="8">
The space at the left or right edges of the tab bar, accordingly with the current [member tab_alignment].
diff --git a/doc/classes/TextEdit.xml b/doc/classes/TextEdit.xml
index d4f5233438..1efd0f9326 100644
--- a/doc/classes/TextEdit.xml
+++ b/doc/classes/TextEdit.xml
@@ -1396,6 +1396,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="font" data_type="font" type="Font">
Sets the default [Font].
diff --git a/doc/classes/TextLine.xml b/doc/classes/TextLine.xml
index d1dfdecbd2..1ebae9889d 100644
--- a/doc/classes/TextLine.xml
+++ b/doc/classes/TextLine.xml
@@ -15,6 +15,7 @@
<param index="1" name="size" type="Vector2" />
<param index="2" name="inline_align" type="int" enum="InlineAlignment" default="5" />
<param index="3" name="length" type="int" default="1" />
+ <param index="4" name="baseline" type="float" default="0.0" />
<description>
Adds inline object to the text buffer, [param key] must be unique. In the text, object is represented as [param length] object replacement characters.
</description>
@@ -122,6 +123,7 @@
<param index="0" name="key" type="Variant" />
<param index="1" name="size" type="Vector2" />
<param index="2" name="inline_align" type="int" enum="InlineAlignment" default="5" />
+ <param index="3" name="baseline" type="float" default="0.0" />
<description>
Sets new size and alignment of embedded object.
</description>
diff --git a/doc/classes/TextParagraph.xml b/doc/classes/TextParagraph.xml
index e0729ba844..38afd9b5f8 100644
--- a/doc/classes/TextParagraph.xml
+++ b/doc/classes/TextParagraph.xml
@@ -15,6 +15,7 @@
<param index="1" name="size" type="Vector2" />
<param index="2" name="inline_align" type="int" enum="InlineAlignment" default="5" />
<param index="3" name="length" type="int" default="1" />
+ <param index="4" name="baseline" type="float" default="0.0" />
<description>
Adds inline object to the text buffer, [param key] must be unique. In the text, object is represented as [param length] object replacement characters.
</description>
@@ -228,6 +229,7 @@
<param index="0" name="key" type="Variant" />
<param index="1" name="size" type="Vector2" />
<param index="2" name="inline_align" type="int" enum="InlineAlignment" default="5" />
+ <param index="3" name="baseline" type="float" default="0.0" />
<description>
Sets new size and alignment of embedded object.
</description>
diff --git a/doc/classes/TextServer.xml b/doc/classes/TextServer.xml
index 4fc6ee3312..d2c6dee373 100644
--- a/doc/classes/TextServer.xml
+++ b/doc/classes/TextServer.xml
@@ -930,6 +930,7 @@
<param index="1" name="language" type="String" default="&quot;&quot;" />
<description>
Converts a number from the Western Arabic (0..9) to the numeral systems used in [param language].
+ If [param language] is omitted, the active locale will be used.
</description>
</method>
<method name="free_rid">
@@ -1097,6 +1098,7 @@
<param index="2" name="size" type="Vector2" />
<param index="3" name="inline_align" type="int" enum="InlineAlignment" default="5" />
<param index="4" name="length" type="int" default="1" />
+ <param index="5" name="baseline" type="float" default="0.0" />
<description>
Adds inline object to the text buffer, [param key] must be unique. In the text, object is represented as [param length] object replacement characters.
</description>
@@ -1438,6 +1440,7 @@
<param index="1" name="key" type="Variant" />
<param index="2" name="size" type="Vector2" />
<param index="3" name="inline_align" type="int" enum="InlineAlignment" default="5" />
+ <param index="4" name="baseline" type="float" default="0.0" />
<description>
Sets new size and alignment of embedded object.
</description>
@@ -1546,8 +1549,15 @@
<return type="PackedInt32Array" />
<param index="0" name="string" type="String" />
<param index="1" name="language" type="String" default="&quot;&quot;" />
- <description>
- Returns array of the word break character offsets.
+ <param index="2" name="chars_per_line" type="int" default="0" />
+ <description>
+ Returns an array of the word break boundaries. Elements in the returned array are the offsets of the start and end of words. Therefore the length of the array is always even.
+ When [param chars_per_line] is greater than zero, line break boundaries are returned instead.
+ [codeblock]
+ var ts = TextServerManager.get_primary_interface()
+ print(ts.string_get_word_breaks("Godot Engine")) # Prints [0, 5, 6, 12]
+ print(ts.string_get_word_breaks("Godot Engine", "en", 5)) # Prints [0, 5, 6, 11, 11, 12]
+ [/codeblock]
</description>
</method>
<method name="string_to_lower" qualifiers="const">
diff --git a/doc/classes/TextServerExtension.xml b/doc/classes/TextServerExtension.xml
index 4c9817fcd4..e144b09eb6 100644
--- a/doc/classes/TextServerExtension.xml
+++ b/doc/classes/TextServerExtension.xml
@@ -945,6 +945,7 @@
<param index="2" name="size" type="Vector2" />
<param index="3" name="inline_align" type="int" enum="InlineAlignment" />
<param index="4" name="length" type="int" />
+ <param index="5" name="baseline" type="float" />
<description>
</description>
</method>
@@ -1242,6 +1243,7 @@
<param index="1" name="key" type="Variant" />
<param index="2" name="size" type="Vector2" />
<param index="3" name="inline_align" type="int" enum="InlineAlignment" />
+ <param index="4" name="baseline" type="float" />
<description>
</description>
</method>
@@ -1344,6 +1346,7 @@
<return type="PackedInt32Array" />
<param index="0" name="string" type="String" />
<param index="1" name="language" type="String" />
+ <param index="2" name="chars_per_line" type="int" />
<description>
</description>
</method>
diff --git a/doc/classes/TileMap.xml b/doc/classes/TileMap.xml
index e9e2a738d3..8b537545bc 100644
--- a/doc/classes/TileMap.xml
+++ b/doc/classes/TileMap.xml
@@ -257,8 +257,9 @@
<description>
Sets the tile indentifiers for the cell on layer [param layer] at coordinates [param coords]. Each tile of the [TileSet] is identified using three parts:
- The source identifier [param source_id] identifies a [TileSetSource] identifier. See [method TileSet.set_source_id],
- - The atlas coordinates identifier [param atlas_coords] identifies a tile coordinates in the atlas (if the source is a [TileSetAtlasSource]. For [TileSetScenesCollectionSource] it should be 0),
+ - The atlas coordinates identifier [param atlas_coords] identifies a tile coordinates in the atlas (if the source is a [TileSetAtlasSource]. For [TileSetScenesCollectionSource] it should always be [code]Vector2i(0, 0)[/code]),
- The alternative tile identifier [param alternative_tile] identifies a tile alternative the source is a [TileSetAtlasSource], and the scene for a [TileSetScenesCollectionSource].
+ If [param source_id] is set to [code]-1[/code], [param atlas_coords] to [code]Vector2i(-1, -1)[/code] or [param alternative_tile] to [code]-1[/code], the cell will be erased. An erased cell gets [b]all[/b] its identifiers automatically set to their respective invalid values, namely [code]-1[/code], [code]Vector2i(-1, -1)[/code] and [code]-1[/code].
</description>
</method>
<method name="set_cells_terrain_connect">
diff --git a/doc/classes/TileSet.xml b/doc/classes/TileSet.xml
index 5a24483774..7fc6ba8161 100644
--- a/doc/classes/TileSet.xml
+++ b/doc/classes/TileSet.xml
@@ -616,6 +616,7 @@
</constant>
<constant name="TILE_SHAPE_ISOMETRIC" value="1" enum="TileShape">
Diamond tile shape (for isometric look).
+ [b]Note:[/b] Isometric [TileSet] works best if [TileMap] and all its layers have Y-sort enabled.
</constant>
<constant name="TILE_SHAPE_HALF_OFFSET_SQUARE" value="2" enum="TileShape">
Rectangular tile shape with one row/column out of two offset by half a tile.
diff --git a/doc/classes/Transform2D.xml b/doc/classes/Transform2D.xml
index 23d20a5a75..f3ed90a015 100644
--- a/doc/classes/Transform2D.xml
+++ b/doc/classes/Transform2D.xml
@@ -183,28 +183,6 @@
This can be seen as transforming with respect to the local frame.
</description>
</method>
- <method name="set_rotation">
- <return type="void" />
- <param index="0" name="rotation" type="float" />
- <description>
- Sets the transform's rotation (in radians).
- </description>
- </method>
- <method name="set_scale">
- <return type="void" />
- <param index="0" name="scale" type="Vector2" />
- <description>
- Sets the transform's scale.
- [b]Note:[/b] Negative X scales in 2D are not decomposable from the transformation matrix. Due to the way scale is represented with transformation matrices in Godot, negative scales on the X axis will be changed to negative scales on the Y axis and a rotation of 180 degrees when decomposed.
- </description>
- </method>
- <method name="set_skew">
- <return type="void" />
- <param index="0" name="skew" type="float" />
- <description>
- Sets the transform's skew (in radians).
- </description>
- </method>
<method name="translated" qualifiers="const">
<return type="Transform2D" />
<param index="0" name="offset" type="Vector2" />
diff --git a/doc/classes/Tree.xml b/doc/classes/Tree.xml
index 629c271417..584a2a2a7b 100644
--- a/doc/classes/Tree.xml
+++ b/doc/classes/Tree.xml
@@ -522,6 +522,7 @@
</theme_item>
<theme_item name="outline_size" data_type="constant" type="int" default="0">
The size of the text outline.
+ [b]Note:[/b] If using a font with [member FontFile.multichannel_signed_distance_field] enabled, its [member FontFile.msdf_pixel_range] must be set to at least [i]twice[/i] the value of [theme_item outline_size] for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.
</theme_item>
<theme_item name="parent_hl_line_margin" data_type="constant" type="int" default="0">
The space between the parent relationship lines for the selected [TreeItem] and the relationship lines to its siblings that are not selected.
diff --git a/doc/classes/TubeTrailMesh.xml b/doc/classes/TubeTrailMesh.xml
index ddc544dc97..7457aa4050 100644
--- a/doc/classes/TubeTrailMesh.xml
+++ b/doc/classes/TubeTrailMesh.xml
@@ -7,6 +7,12 @@
<tutorials>
</tutorials>
<members>
+ <member name="cap_bottom" type="bool" setter="set_cap_bottom" getter="is_cap_bottom" default="true">
+ If [code]true[/code], generates a cap at the bottom of the tube. This can be set to [code]false[/code] to speed up generation and rendering when the cap is never seen by the camera.
+ </member>
+ <member name="cap_top" type="bool" setter="set_cap_top" getter="is_cap_top" default="true">
+ If [code]true[/code], generates a cap at the top of the tube. This can be set to [code]false[/code] to speed up generation and rendering when the cap is never seen by the camera.
+ </member>
<member name="curve" type="Curve" setter="set_curve" getter="get_curve">
</member>
<member name="radial_steps" type="int" setter="set_radial_steps" getter="get_radial_steps" default="8">
diff --git a/doc/classes/VisualInstance3D.xml b/doc/classes/VisualInstance3D.xml
index 31811f817b..e069642e50 100644
--- a/doc/classes/VisualInstance3D.xml
+++ b/doc/classes/VisualInstance3D.xml
@@ -61,5 +61,12 @@
This object will only be visible for [Camera3D]s whose cull mask includes the render object this [VisualInstance3D] is set to.
For [Light3D]s, this can be used to control which [VisualInstance3D]s are affected by a specific light. For [GPUParticles3D], this can be used to control which particles are effected by a specific attractor. For [Decal]s, this can be used to control which [VisualInstance3D]s are affected by a specific decal.
</member>
+ <member name="sorting_offset" type="float" setter="set_sorting_offset" getter="get_sorting_offset" default="0.0">
+ The sorting offset used by this [VisualInstance3D]. Adjusting it to a higher value will make the [VisualInstance3D] reliably draw on top of other [VisualInstance3D]s that are otherwise positioned at the same spot.
+ </member>
+ <member name="sorting_use_aabb_center" type="bool" setter="set_sorting_use_aabb_center" getter="is_sorting_use_aabb_center" default="true">
+ If [code]true[/code], the object is sorted based on the [AABB] center. The object will be sorted based on the global position otherwise.
+ The [AABB] center based sorting is generally more accurate for 3D models. The position based sorting instead allows to better control the drawing order when working with [GPUParticles3D] and [CPUParticles3D].
+ </member>
</members>
</class>
diff --git a/doc/classes/VisualShader.xml b/doc/classes/VisualShader.xml
index a2089ae2b8..2d59810a5f 100644
--- a/doc/classes/VisualShader.xml
+++ b/doc/classes/VisualShader.xml
@@ -208,17 +208,19 @@
</constant>
<constant name="VARYING_TYPE_INT" value="1" enum="VaryingType">
</constant>
- <constant name="VARYING_TYPE_VECTOR_2D" value="2" enum="VaryingType">
+ <constant name="VARYING_TYPE_UINT" value="2" enum="VaryingType">
</constant>
- <constant name="VARYING_TYPE_VECTOR_3D" value="3" enum="VaryingType">
+ <constant name="VARYING_TYPE_VECTOR_2D" value="3" enum="VaryingType">
</constant>
- <constant name="VARYING_TYPE_VECTOR_4D" value="4" enum="VaryingType">
+ <constant name="VARYING_TYPE_VECTOR_3D" value="4" enum="VaryingType">
</constant>
- <constant name="VARYING_TYPE_BOOLEAN" value="5" enum="VaryingType">
+ <constant name="VARYING_TYPE_VECTOR_4D" value="5" enum="VaryingType">
</constant>
- <constant name="VARYING_TYPE_TRANSFORM" value="6" enum="VaryingType">
+ <constant name="VARYING_TYPE_BOOLEAN" value="6" enum="VaryingType">
</constant>
- <constant name="VARYING_TYPE_MAX" value="7" enum="VaryingType">
+ <constant name="VARYING_TYPE_TRANSFORM" value="7" enum="VaryingType">
+ </constant>
+ <constant name="VARYING_TYPE_MAX" value="8" enum="VaryingType">
</constant>
<constant name="NODE_ID_INVALID" value="-1">
</constant>
diff --git a/doc/classes/VisualShaderNode.xml b/doc/classes/VisualShaderNode.xml
index 1f3397f39c..f95f871e52 100644
--- a/doc/classes/VisualShaderNode.xml
+++ b/doc/classes/VisualShaderNode.xml
@@ -72,25 +72,28 @@
<constant name="PORT_TYPE_SCALAR_INT" value="1" enum="PortType">
Integer scalar. Translated to [code]int[/code] type in shader code.
</constant>
- <constant name="PORT_TYPE_VECTOR_2D" value="2" enum="PortType">
+ <constant name="PORT_TYPE_SCALAR_UINT" value="2" enum="PortType">
+ Unsigned integer scalar. Translated to [code]uint[/code] type in shader code.
+ </constant>
+ <constant name="PORT_TYPE_VECTOR_2D" value="3" enum="PortType">
2D vector of floating-point values. Translated to [code]vec2[/code] type in shader code.
</constant>
- <constant name="PORT_TYPE_VECTOR_3D" value="3" enum="PortType">
+ <constant name="PORT_TYPE_VECTOR_3D" value="4" enum="PortType">
3D vector of floating-point values. Translated to [code]vec3[/code] type in shader code.
</constant>
- <constant name="PORT_TYPE_VECTOR_4D" value="4" enum="PortType">
+ <constant name="PORT_TYPE_VECTOR_4D" value="5" enum="PortType">
4D vector of floating-point values. Translated to [code]vec4[/code] type in shader code.
</constant>
- <constant name="PORT_TYPE_BOOLEAN" value="5" enum="PortType">
+ <constant name="PORT_TYPE_BOOLEAN" value="6" enum="PortType">
Boolean type. Translated to [code]bool[/code] type in shader code.
</constant>
- <constant name="PORT_TYPE_TRANSFORM" value="6" enum="PortType">
+ <constant name="PORT_TYPE_TRANSFORM" value="7" enum="PortType">
Transform type. Translated to [code]mat4[/code] type in shader code.
</constant>
- <constant name="PORT_TYPE_SAMPLER" value="7" enum="PortType">
+ <constant name="PORT_TYPE_SAMPLER" value="8" enum="PortType">
Sampler type. Translated to reference of sampler uniform in shader code. Can only be used for input ports in non-uniform nodes.
</constant>
- <constant name="PORT_TYPE_MAX" value="8" enum="PortType">
+ <constant name="PORT_TYPE_MAX" value="9" enum="PortType">
Represents the size of the [enum PortType] enum.
</constant>
</constants>
diff --git a/doc/classes/VisualShaderNodeClamp.xml b/doc/classes/VisualShaderNodeClamp.xml
index 35f50a37c3..642a98ec8c 100644
--- a/doc/classes/VisualShaderNodeClamp.xml
+++ b/doc/classes/VisualShaderNodeClamp.xml
@@ -20,16 +20,19 @@
<constant name="OP_TYPE_INT" value="1" enum="OpType">
An integer scalar.
</constant>
- <constant name="OP_TYPE_VECTOR_2D" value="2" enum="OpType">
+ <constant name="OP_TYPE_UINT" value="2" enum="OpType">
+ An unsigned integer scalar.
+ </constant>
+ <constant name="OP_TYPE_VECTOR_2D" value="3" enum="OpType">
A 2D vector type.
</constant>
- <constant name="OP_TYPE_VECTOR_3D" value="3" enum="OpType">
+ <constant name="OP_TYPE_VECTOR_3D" value="4" enum="OpType">
A 3D vector type.
</constant>
- <constant name="OP_TYPE_VECTOR_4D" value="4" enum="OpType">
+ <constant name="OP_TYPE_VECTOR_4D" value="5" enum="OpType">
A 4D vector type.
</constant>
- <constant name="OP_TYPE_MAX" value="5" enum="OpType">
+ <constant name="OP_TYPE_MAX" value="6" enum="OpType">
Represents the size of the [enum OpType] enum.
</constant>
</constants>
diff --git a/doc/classes/VisualShaderNodeCompare.xml b/doc/classes/VisualShaderNodeCompare.xml
index 942ced2ebd..19ed42d1c7 100644
--- a/doc/classes/VisualShaderNodeCompare.xml
+++ b/doc/classes/VisualShaderNodeCompare.xml
@@ -26,22 +26,25 @@
<constant name="CTYPE_SCALAR_INT" value="1" enum="ComparisonType">
An integer scalar.
</constant>
- <constant name="CTYPE_VECTOR_2D" value="2" enum="ComparisonType">
+ <constant name="CTYPE_SCALAR_UINT" value="2" enum="ComparisonType">
+ An unsigned integer scalar.
+ </constant>
+ <constant name="CTYPE_VECTOR_2D" value="3" enum="ComparisonType">
A 2D vector type.
</constant>
- <constant name="CTYPE_VECTOR_3D" value="3" enum="ComparisonType">
+ <constant name="CTYPE_VECTOR_3D" value="4" enum="ComparisonType">
A 3D vector type.
</constant>
- <constant name="CTYPE_VECTOR_4D" value="4" enum="ComparisonType">
+ <constant name="CTYPE_VECTOR_4D" value="5" enum="ComparisonType">
A 4D vector type.
</constant>
- <constant name="CTYPE_BOOLEAN" value="5" enum="ComparisonType">
+ <constant name="CTYPE_BOOLEAN" value="6" enum="ComparisonType">
A boolean type.
</constant>
- <constant name="CTYPE_TRANSFORM" value="6" enum="ComparisonType">
+ <constant name="CTYPE_TRANSFORM" value="7" enum="ComparisonType">
A transform ([code]mat4[/code]) type.
</constant>
- <constant name="CTYPE_MAX" value="7" enum="ComparisonType">
+ <constant name="CTYPE_MAX" value="8" enum="ComparisonType">
Represents the size of the [enum ComparisonType] enum.
</constant>
<constant name="FUNC_EQUAL" value="0" enum="Function">
diff --git a/doc/classes/VisualShaderNodeSwitch.xml b/doc/classes/VisualShaderNodeSwitch.xml
index e74ff6e162..3fda4eb2b8 100644
--- a/doc/classes/VisualShaderNodeSwitch.xml
+++ b/doc/classes/VisualShaderNodeSwitch.xml
@@ -20,22 +20,25 @@
<constant name="OP_TYPE_INT" value="1" enum="OpType">
An integer scalar.
</constant>
- <constant name="OP_TYPE_VECTOR_2D" value="2" enum="OpType">
+ <constant name="OP_TYPE_UINT" value="2" enum="OpType">
+ An unsigned integer scalar.
+ </constant>
+ <constant name="OP_TYPE_VECTOR_2D" value="3" enum="OpType">
A 2D vector type.
</constant>
- <constant name="OP_TYPE_VECTOR_3D" value="3" enum="OpType">
+ <constant name="OP_TYPE_VECTOR_3D" value="4" enum="OpType">
A 3D vector type.
</constant>
- <constant name="OP_TYPE_VECTOR_4D" value="4" enum="OpType">
+ <constant name="OP_TYPE_VECTOR_4D" value="5" enum="OpType">
A 4D vector type.
</constant>
- <constant name="OP_TYPE_BOOLEAN" value="5" enum="OpType">
+ <constant name="OP_TYPE_BOOLEAN" value="6" enum="OpType">
A boolean type.
</constant>
- <constant name="OP_TYPE_TRANSFORM" value="6" enum="OpType">
+ <constant name="OP_TYPE_TRANSFORM" value="7" enum="OpType">
A transform type.
</constant>
- <constant name="OP_TYPE_MAX" value="7" enum="OpType">
+ <constant name="OP_TYPE_MAX" value="8" enum="OpType">
Represents the size of the [enum OpType] enum.
</constant>
</constants>
diff --git a/doc/classes/VisualShaderNodeUIntConstant.xml b/doc/classes/VisualShaderNodeUIntConstant.xml
new file mode 100644
index 0000000000..926e4e11d2
--- /dev/null
+++ b/doc/classes/VisualShaderNodeUIntConstant.xml
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="VisualShaderNodeUIntConstant" inherits="VisualShaderNodeConstant" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+ <brief_description>
+ An unsigned scalar integer constant to be used within the visual shader graph.
+ </brief_description>
+ <description>
+ Translated to [code]uint[/code] in the shader language.
+ </description>
+ <tutorials>
+ </tutorials>
+ <members>
+ <member name="constant" type="int" setter="set_constant" getter="get_constant" default="0">
+ An unsigned integer constant which represents a state of this node.
+ </member>
+ </members>
+</class>
diff --git a/doc/classes/VisualShaderNodeUIntFunc.xml b/doc/classes/VisualShaderNodeUIntFunc.xml
new file mode 100644
index 0000000000..c0c591304a
--- /dev/null
+++ b/doc/classes/VisualShaderNodeUIntFunc.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="VisualShaderNodeUIntFunc" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+ <brief_description>
+ An unsigned scalar integer function to be used within the visual shader graph.
+ </brief_description>
+ <description>
+ Accept an unsigned integer scalar ([code]x[/code]) to the input port and transform it according to [member function].
+ </description>
+ <tutorials>
+ </tutorials>
+ <members>
+ <member name="function" type="int" setter="set_function" getter="get_function" enum="VisualShaderNodeUIntFunc.Function" default="0">
+ A function to be applied to the scalar. See [enum Function] for options.
+ </member>
+ </members>
+ <constants>
+ <constant name="FUNC_NEGATE" value="0" enum="Function">
+ Negates the [code]x[/code] using [code]-(x)[/code].
+ </constant>
+ <constant name="FUNC_BITWISE_NOT" value="1" enum="Function">
+ Returns the result of bitwise [code]NOT[/code] operation on the integer. Translates to [code]~a[/code] in the Godot Shader Language.
+ </constant>
+ <constant name="FUNC_MAX" value="2" enum="Function">
+ Represents the size of the [enum Function] enum.
+ </constant>
+ </constants>
+</class>
diff --git a/doc/classes/VisualShaderNodeUIntOp.xml b/doc/classes/VisualShaderNodeUIntOp.xml
new file mode 100644
index 0000000000..44f71286e3
--- /dev/null
+++ b/doc/classes/VisualShaderNodeUIntOp.xml
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="VisualShaderNodeUIntOp" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+ <brief_description>
+ An unsigned integer scalar operator to be used within the visual shader graph.
+ </brief_description>
+ <description>
+ Applies [member operator] to two unsigned integer inputs: [code]a[/code] and [code]b[/code].
+ </description>
+ <tutorials>
+ </tutorials>
+ <members>
+ <member name="operator" type="int" setter="set_operator" getter="get_operator" enum="VisualShaderNodeUIntOp.Operator" default="0">
+ An operator to be applied to the inputs. See [enum Operator] for options.
+ </member>
+ </members>
+ <constants>
+ <constant name="OP_ADD" value="0" enum="Operator">
+ Sums two numbers using [code]a + b[/code].
+ </constant>
+ <constant name="OP_SUB" value="1" enum="Operator">
+ Subtracts two numbers using [code]a - b[/code].
+ </constant>
+ <constant name="OP_MUL" value="2" enum="Operator">
+ Multiplies two numbers using [code]a * b[/code].
+ </constant>
+ <constant name="OP_DIV" value="3" enum="Operator">
+ Divides two numbers using [code]a / b[/code].
+ </constant>
+ <constant name="OP_MOD" value="4" enum="Operator">
+ Calculates the remainder of two numbers using [code]a % b[/code].
+ </constant>
+ <constant name="OP_MAX" value="5" enum="Operator">
+ Returns the greater of two numbers. Translates to [code]max(a, b)[/code] in the Godot Shader Language.
+ </constant>
+ <constant name="OP_MIN" value="6" enum="Operator">
+ Returns the lesser of two numbers. Translates to [code]max(a, b)[/code] in the Godot Shader Language.
+ </constant>
+ <constant name="OP_BITWISE_AND" value="7" enum="Operator">
+ Returns the result of bitwise [code]AND[/code] operation on the integer. Translates to [code]a &amp; b[/code] in the Godot Shader Language.
+ </constant>
+ <constant name="OP_BITWISE_OR" value="8" enum="Operator">
+ Returns the result of bitwise [code]OR[/code] operation for two integers. Translates to [code]a | b[/code] in the Godot Shader Language.
+ </constant>
+ <constant name="OP_BITWISE_XOR" value="9" enum="Operator">
+ Returns the result of bitwise [code]XOR[/code] operation for two integers. Translates to [code]a ^ b[/code] in the Godot Shader Language.
+ </constant>
+ <constant name="OP_BITWISE_LEFT_SHIFT" value="10" enum="Operator">
+ Returns the result of bitwise left shift operation on the integer. Translates to [code]a &lt;&lt; b[/code] in the Godot Shader Language.
+ </constant>
+ <constant name="OP_BITWISE_RIGHT_SHIFT" value="11" enum="Operator">
+ Returns the result of bitwise right shift operation on the integer. Translates to [code]a &gt;&gt; b[/code] in the Godot Shader Language.
+ </constant>
+ <constant name="OP_ENUM_SIZE" value="12" enum="Operator">
+ Represents the size of the [enum Operator] enum.
+ </constant>
+ </constants>
+</class>
diff --git a/doc/classes/VisualShaderNodeUIntParameter.xml b/doc/classes/VisualShaderNodeUIntParameter.xml
new file mode 100644
index 0000000000..3b549c84f7
--- /dev/null
+++ b/doc/classes/VisualShaderNodeUIntParameter.xml
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="VisualShaderNodeUIntParameter" inherits="VisualShaderNodeParameter" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+ <brief_description>
+ </brief_description>
+ <description>
+ </description>
+ <tutorials>
+ </tutorials>
+ <members>
+ <member name="default_value" type="int" setter="set_default_value" getter="get_default_value" default="0">
+ </member>
+ <member name="default_value_enabled" type="bool" setter="set_default_value_enabled" getter="is_default_value_enabled" default="false">
+ </member>
+ </members>
+</class>