summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to 'doc')
-rw-r--r--doc/classes/@GlobalScope.xml622
-rw-r--r--doc/classes/AABB.xml2
-rw-r--r--doc/classes/AESContext.xml33
-rw-r--r--doc/classes/AStar3D.xml11
-rw-r--r--doc/classes/AStarGrid2D.xml39
-rw-r--r--doc/classes/AcceptDialog.xml4
-rw-r--r--doc/classes/AnimatableBody3D.xml1
-rw-r--r--doc/classes/AnimatedSprite2D.xml100
-rw-r--r--doc/classes/AnimatedSprite3D.xml101
-rw-r--r--doc/classes/Animation.xml28
-rw-r--r--doc/classes/AnimationNode.xml33
-rw-r--r--doc/classes/AnimationNodeBlendSpace1D.xml14
-rw-r--r--doc/classes/AnimationNodeOneShot.xml6
-rw-r--r--doc/classes/AnimationNodeStateMachine.xml5
-rw-r--r--doc/classes/AnimationNodeStateMachinePlayback.xml17
-rw-r--r--doc/classes/AnimationNodeStateMachineTransition.xml23
-rw-r--r--doc/classes/AnimationNodeTransition.xml21
-rw-r--r--doc/classes/AnimationPlayer.xml45
-rw-r--r--doc/classes/AnimationTree.xml31
-rw-r--r--doc/classes/Area2D.xml65
-rw-r--r--doc/classes/Area3D.xml66
-rw-r--r--doc/classes/Array.xml56
-rw-r--r--doc/classes/ArrayMesh.xml19
-rw-r--r--doc/classes/AudioServer.xml26
-rw-r--r--doc/classes/AudioStreamPlaybackPolyphonic.xml61
-rw-r--r--doc/classes/AudioStreamPlayer.xml6
-rw-r--r--doc/classes/AudioStreamPlayer2D.xml6
-rw-r--r--doc/classes/AudioStreamPlayer3D.xml6
-rw-r--r--doc/classes/AudioStreamPolyphonic.xml17
-rw-r--r--doc/classes/AudioStreamRandomizer.xml4
-rw-r--r--doc/classes/BackBufferCopy.xml4
-rw-r--r--doc/classes/BaseButton.xml4
-rw-r--r--doc/classes/BaseMaterial3D.xml4
-rw-r--r--doc/classes/BoneAttachment3D.xml31
-rw-r--r--doc/classes/Button.xml1
-rw-r--r--doc/classes/ButtonGroup.xml4
-rw-r--r--doc/classes/Callable.xml31
-rw-r--r--doc/classes/Camera2D.xml19
-rw-r--r--doc/classes/CanvasGroup.xml4
-rw-r--r--doc/classes/CanvasItem.xml41
-rw-r--r--doc/classes/CanvasLayer.xml6
-rw-r--r--doc/classes/CharacterBody3D.xml13
-rw-r--r--doc/classes/CheckBox.xml1
-rw-r--r--doc/classes/CheckButton.xml1
-rw-r--r--doc/classes/CodeEdit.xml11
-rw-r--r--doc/classes/CollisionObject3D.xml7
-rw-r--r--doc/classes/CollisionPolygon3D.xml1
-rw-r--r--doc/classes/CollisionShape3D.xml1
-rw-r--r--doc/classes/Color.xml33
-rw-r--r--doc/classes/ColorPicker.xml3
-rw-r--r--doc/classes/ColorPickerButton.xml1
-rw-r--r--doc/classes/ConfirmationDialog.xml4
-rw-r--r--doc/classes/Control.xml159
-rw-r--r--doc/classes/ConvexPolygonShape3D.xml2
-rw-r--r--doc/classes/Crypto.xml30
-rw-r--r--doc/classes/Cubemap.xml8
-rw-r--r--doc/classes/CubemapArray.xml8
-rw-r--r--doc/classes/Curve2D.xml2
-rw-r--r--doc/classes/Curve3D.xml2
-rw-r--r--doc/classes/DTLSServer.xml77
-rw-r--r--doc/classes/Decal.xml6
-rw-r--r--doc/classes/Dictionary.xml20
-rw-r--r--doc/classes/DirAccess.xml4
-rw-r--r--doc/classes/DisplayServer.xml43
-rw-r--r--doc/classes/EditorCommandPalette.xml2
-rw-r--r--doc/classes/EditorExportPlatform.xml3
-rw-r--r--doc/classes/EditorFileSystem.xml11
-rw-r--r--doc/classes/EditorImportPlugin.xml44
-rw-r--r--doc/classes/EditorInspectorPlugin.xml6
-rw-r--r--doc/classes/EditorPlugin.xml60
-rw-r--r--doc/classes/EditorResourceConversionPlugin.xml23
-rw-r--r--doc/classes/EditorScenePostImport.xml7
-rw-r--r--doc/classes/EditorScript.xml3
-rw-r--r--doc/classes/EditorSettings.xml26
-rw-r--r--doc/classes/EditorSpinSlider.xml24
-rw-r--r--doc/classes/EditorTranslationParserPlugin.xml27
-rw-r--r--doc/classes/EditorUndoRedoManager.xml2
-rw-r--r--doc/classes/EditorVCSInterface.xml4
-rw-r--r--doc/classes/Expression.xml12
-rw-r--r--doc/classes/FileAccess.xml4
-rw-r--r--doc/classes/FileSystemDock.xml5
-rw-r--r--doc/classes/FogVolume.xml10
-rw-r--r--doc/classes/FontFile.xml14
-rw-r--r--doc/classes/GPUParticles2D.xml4
-rw-r--r--doc/classes/GPUParticlesAttractorBox3D.xml4
-rw-r--r--doc/classes/GPUParticlesAttractorVectorField3D.xml6
-rw-r--r--doc/classes/GPUParticlesCollisionBox3D.xml4
-rw-r--r--doc/classes/GPUParticlesCollisionHeightField3D.xml6
-rw-r--r--doc/classes/GPUParticlesCollisionSDF3D.xml8
-rw-r--r--doc/classes/Geometry2D.xml7
-rw-r--r--doc/classes/GeometryInstance3D.xml15
-rw-r--r--doc/classes/GraphEdit.xml5
-rw-r--r--doc/classes/GraphNode.xml20
-rw-r--r--doc/classes/HMACContext.xml19
-rw-r--r--doc/classes/HTTPClient.xml20
-rw-r--r--doc/classes/HTTPRequest.xml33
-rw-r--r--doc/classes/HashingContext.xml27
-rw-r--r--doc/classes/HeightMapShape3D.xml4
-rw-r--r--doc/classes/Image.xml37
-rw-r--r--doc/classes/ImporterMesh.xml10
-rw-r--r--doc/classes/Input.xml29
-rw-r--r--doc/classes/InputEventAction.xml1
-rw-r--r--doc/classes/InputEventKey.xml52
-rw-r--r--doc/classes/InputEventMIDI.xml20
-rw-r--r--doc/classes/InputEventMouse.xml2
-rw-r--r--doc/classes/InputEventScreenDrag.xml9
-rw-r--r--doc/classes/InputEventWithModifiers.xml6
-rw-r--r--doc/classes/ItemList.xml1
-rw-r--r--doc/classes/JSON.xml14
-rw-r--r--doc/classes/JavaScriptBridge.xml9
-rw-r--r--doc/classes/Label.xml3
-rw-r--r--doc/classes/Label3D.xml12
-rw-r--r--doc/classes/Light3D.xml2
-rw-r--r--doc/classes/LightmapGI.xml18
-rw-r--r--doc/classes/LineEdit.xml90
-rw-r--r--doc/classes/LinkButton.xml19
-rw-r--r--doc/classes/MainLoop.xml15
-rw-r--r--doc/classes/Marshalls.xml2
-rw-r--r--doc/classes/Material.xml6
-rw-r--r--doc/classes/MenuBar.xml1
-rw-r--r--doc/classes/MenuButton.xml1
-rw-r--r--doc/classes/Mesh.xml63
-rw-r--r--doc/classes/MeshInstance2D.xml4
-rw-r--r--doc/classes/MeshLibrary.xml27
-rw-r--r--doc/classes/MultiMeshInstance2D.xml4
-rw-r--r--doc/classes/MultiplayerAPI.xml4
-rw-r--r--doc/classes/MultiplayerAPIExtension.xml8
-rw-r--r--doc/classes/Mutex.xml4
-rw-r--r--doc/classes/NavigationAgent2D.xml103
-rw-r--r--doc/classes/NavigationAgent3D.xml90
-rw-r--r--doc/classes/NavigationLink2D.xml15
-rw-r--r--doc/classes/NavigationLink3D.xml15
-rw-r--r--doc/classes/NavigationMesh.xml15
-rw-r--r--doc/classes/NavigationMeshGenerator.xml11
-rw-r--r--doc/classes/NavigationObstacle2D.xml3
-rw-r--r--doc/classes/NavigationObstacle3D.xml3
-rw-r--r--doc/classes/NavigationPathQueryParameters2D.xml25
-rw-r--r--doc/classes/NavigationPathQueryParameters3D.xml25
-rw-r--r--doc/classes/NavigationPathQueryResult2D.xml20
-rw-r--r--doc/classes/NavigationPathQueryResult3D.xml20
-rw-r--r--doc/classes/NavigationPolygon.xml15
-rw-r--r--doc/classes/NavigationRegion2D.xml11
-rw-r--r--doc/classes/NavigationRegion3D.xml11
-rw-r--r--doc/classes/NavigationServer2D.xml106
-rw-r--r--doc/classes/NavigationServer3D.xml147
-rw-r--r--doc/classes/Node.xml20
-rw-r--r--doc/classes/Node2D.xml6
-rw-r--r--doc/classes/Node3D.xml6
-rw-r--r--doc/classes/OS.xml78
-rw-r--r--doc/classes/Object.xml65
-rw-r--r--doc/classes/OptionButton.xml5
-rw-r--r--doc/classes/PackedScene.xml2
-rw-r--r--doc/classes/PacketPeerDTLS.xml7
-rw-r--r--doc/classes/ParticleProcessMaterial.xml3
-rw-r--r--doc/classes/Performance.xml74
-rw-r--r--doc/classes/PhysicalBone3D.xml1
-rw-r--r--doc/classes/PhysicsBody3D.xml3
-rw-r--r--doc/classes/PhysicsDirectBodyState2D.xml7
-rw-r--r--doc/classes/PhysicsDirectBodyState2DExtension.xml6
-rw-r--r--doc/classes/PhysicsDirectBodyState3D.xml4
-rw-r--r--doc/classes/PhysicsDirectBodyState3DExtension.xml2
-rw-r--r--doc/classes/PhysicsDirectSpaceState2DExtension.xml6
-rw-r--r--doc/classes/PhysicsDirectSpaceState3DExtension.xml6
-rw-r--r--doc/classes/PhysicsPointQueryParameters2D.xml1
-rw-r--r--doc/classes/PhysicsServer2D.xml50
-rw-r--r--doc/classes/PhysicsServer2DExtension.xml12
-rw-r--r--doc/classes/PhysicsServer3D.xml41
-rw-r--r--doc/classes/PhysicsServer3DExtension.xml25
-rw-r--r--doc/classes/PhysicsServer3DManager.xml2
-rw-r--r--doc/classes/Plane.xml17
-rw-r--r--doc/classes/PopupMenu.xml1
-rw-r--r--doc/classes/ProgressBar.xml1
-rw-r--r--doc/classes/ProjectSettings.xml119
-rw-r--r--doc/classes/Projection.xml2
-rw-r--r--doc/classes/Range.xml2
-rw-r--r--doc/classes/Rect2i.xml6
-rw-r--r--doc/classes/ReflectionProbe.xml22
-rw-r--r--doc/classes/RemoteTransform2D.xml6
-rw-r--r--doc/classes/RenderingDevice.xml35
-rw-r--r--doc/classes/RenderingServer.xml187
-rw-r--r--doc/classes/Resource.xml3
-rw-r--r--doc/classes/ResourceFormatLoader.xml9
-rw-r--r--doc/classes/ResourceFormatSaver.xml10
-rw-r--r--doc/classes/ResourcePreloader.xml4
-rw-r--r--doc/classes/RichTextEffect.xml2
-rw-r--r--doc/classes/RichTextLabel.xml26
-rw-r--r--doc/classes/RigidBody3D.xml1
-rw-r--r--doc/classes/SceneTree.xml16
-rw-r--r--doc/classes/SceneTreeTimer.xml4
-rw-r--r--doc/classes/Semaphore.xml4
-rw-r--r--doc/classes/Shader.xml10
-rw-r--r--doc/classes/ShaderMaterial.xml3
-rw-r--r--doc/classes/Signal.xml4
-rw-r--r--doc/classes/Skeleton2D.xml2
-rw-r--r--doc/classes/Skeleton3D.xml96
-rw-r--r--doc/classes/SkeletonModification2D.xml2
-rw-r--r--doc/classes/SkeletonModification3D.xml66
-rw-r--r--doc/classes/SkeletonModification3DCCDIK.xml136
-rw-r--r--doc/classes/SkeletonModification3DFABRIK.xml161
-rw-r--r--doc/classes/SkeletonModification3DJiggle.xml199
-rw-r--r--doc/classes/SkeletonModification3DLookAt.xml64
-rw-r--r--doc/classes/SkeletonModification3DStackHolder.xml27
-rw-r--r--doc/classes/SkeletonModification3DTwoBoneIK.xml191
-rw-r--r--doc/classes/SkeletonModificationStack3D.xml88
-rw-r--r--doc/classes/SkeletonProfile.xml11
-rw-r--r--doc/classes/SkeletonProfileHumanoid.xml1
-rw-r--r--doc/classes/SpinBox.xml2
-rw-r--r--doc/classes/Sprite2D.xml6
-rw-r--r--doc/classes/SpriteBase3D.xml15
-rw-r--r--doc/classes/SpriteFrames.xml59
-rw-r--r--doc/classes/StaticBody3D.xml5
-rw-r--r--doc/classes/StreamPeer.xml2
-rw-r--r--doc/classes/StreamPeerTLS.xml18
-rw-r--r--doc/classes/String.xml8
-rw-r--r--doc/classes/StringName.xml8
-rw-r--r--doc/classes/StyleBox.xml37
-rw-r--r--doc/classes/StyleBoxTexture.xml59
-rw-r--r--doc/classes/SubViewport.xml1
-rw-r--r--doc/classes/SubViewportContainer.xml1
-rw-r--r--doc/classes/SurfaceTool.xml4
-rw-r--r--doc/classes/SystemFont.xml6
-rw-r--r--doc/classes/TLSOptions.xml53
-rw-r--r--doc/classes/TabBar.xml7
-rw-r--r--doc/classes/TabContainer.xml1
-rw-r--r--doc/classes/TextEdit.xml104
-rw-r--r--doc/classes/TextLine.xml2
-rw-r--r--doc/classes/TextParagraph.xml2
-rw-r--r--doc/classes/TextServer.xml23
-rw-r--r--doc/classes/TextServerExtension.xml5
-rw-r--r--doc/classes/Texture2D.xml6
-rw-r--r--doc/classes/Texture2DArray.xml8
-rw-r--r--doc/classes/Texture3D.xml6
-rw-r--r--doc/classes/TextureProgressBar.xml2
-rw-r--r--doc/classes/TextureRect.xml24
-rw-r--r--doc/classes/TileData.xml2
-rw-r--r--doc/classes/TileMap.xml32
-rw-r--r--doc/classes/TileSet.xml19
-rw-r--r--doc/classes/Timer.xml2
-rw-r--r--doc/classes/Transform2D.xml22
-rw-r--r--doc/classes/Transform3D.xml1
-rw-r--r--doc/classes/Tree.xml26
-rw-r--r--doc/classes/TreeItem.xml42
-rw-r--r--doc/classes/TubeTrailMesh.xml6
-rw-r--r--doc/classes/Tween.xml38
-rw-r--r--doc/classes/UDPServer.xml54
-rw-r--r--doc/classes/UndoRedo.xml18
-rw-r--r--doc/classes/VScrollBar.xml4
-rw-r--r--doc/classes/VSlider.xml4
-rw-r--r--doc/classes/Variant.xml4
-rw-r--r--doc/classes/VehicleBody3D.xml1
-rw-r--r--doc/classes/VideoStream.xml14
-rw-r--r--doc/classes/VideoStreamPlayback.xml104
-rw-r--r--doc/classes/Viewport.xml3
-rw-r--r--doc/classes/VisualInstance3D.xml7
-rw-r--r--doc/classes/VisualShader.xml38
-rw-r--r--doc/classes/VisualShaderNode.xml24
-rw-r--r--doc/classes/VisualShaderNodeClamp.xml11
-rw-r--r--doc/classes/VisualShaderNodeCompare.xml15
-rw-r--r--doc/classes/VisualShaderNodeConstant.xml1
-rw-r--r--doc/classes/VisualShaderNodeCustom.xml6
-rw-r--r--doc/classes/VisualShaderNodeDerivativeFunc.xml15
-rw-r--r--doc/classes/VisualShaderNodeDistanceFade.xml2
-rw-r--r--doc/classes/VisualShaderNodeIntParameter.xml12
-rw-r--r--doc/classes/VisualShaderNodeLinearSceneDepth.xml2
-rw-r--r--doc/classes/VisualShaderNodeParameter.xml4
-rw-r--r--doc/classes/VisualShaderNodeParticleAccelerator.xml6
-rw-r--r--doc/classes/VisualShaderNodeParticleBoxEmitter.xml2
-rw-r--r--doc/classes/VisualShaderNodeParticleConeVelocity.xml2
-rw-r--r--doc/classes/VisualShaderNodeParticleEmit.xml8
-rw-r--r--doc/classes/VisualShaderNodeParticleEmitter.xml1
-rw-r--r--doc/classes/VisualShaderNodeParticleMeshEmitter.xml5
-rw-r--r--doc/classes/VisualShaderNodeParticleMultiplyByAxisAngle.xml3
-rw-r--r--doc/classes/VisualShaderNodeParticleOutput.xml2
-rw-r--r--doc/classes/VisualShaderNodeParticleRandomness.xml7
-rw-r--r--doc/classes/VisualShaderNodeParticleRingEmitter.xml2
-rw-r--r--doc/classes/VisualShaderNodeParticleSphereEmitter.xml2
-rw-r--r--doc/classes/VisualShaderNodeProximityFade.xml2
-rw-r--r--doc/classes/VisualShaderNodeRandomRange.xml2
-rw-r--r--doc/classes/VisualShaderNodeRemap.xml2
-rw-r--r--doc/classes/VisualShaderNodeSwitch.xml15
-rw-r--r--doc/classes/VisualShaderNodeTexture.xml10
-rw-r--r--doc/classes/VisualShaderNodeTexture2DArrayParameter.xml2
-rw-r--r--doc/classes/VisualShaderNodeTextureParameter.xml30
-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.xml19
-rw-r--r--doc/classes/VisualShaderNodeUVFunc.xml1
-rw-r--r--doc/classes/VisualShaderNodeUVPolarCoord.xml2
-rw-r--r--doc/classes/VisualShaderNodeVarying.xml4
-rw-r--r--doc/classes/VisualShaderNodeVaryingGetter.xml2
-rw-r--r--doc/classes/VisualShaderNodeVaryingSetter.xml2
-rw-r--r--doc/classes/VisualShaderNodeVectorBase.xml5
-rw-r--r--doc/classes/VoxelGI.xml6
-rw-r--r--doc/classes/VoxelGIData.xml4
-rw-r--r--doc/classes/Window.xml60
-rw-r--r--doc/classes/XRController3D.xml31
-rw-r--r--doc/classes/XRInterfaceExtension.xml6
-rw-r--r--doc/classes/XRPositionalTracker.xml12
-rw-r--r--doc/classes/bool.xml2
-rw-r--r--doc/translations/ar.po6
-rw-r--r--doc/translations/ca.po6
-rw-r--r--doc/translations/classes.pot10
-rw-r--r--doc/translations/cs.po6
-rw-r--r--doc/translations/de.po6
-rw-r--r--doc/translations/el.po6
-rw-r--r--doc/translations/es.po17
-rw-r--r--doc/translations/et.po6
-rw-r--r--doc/translations/extract.py4
-rw-r--r--doc/translations/fa.po6
-rw-r--r--doc/translations/fi.po6
-rw-r--r--doc/translations/fil.po6
-rw-r--r--doc/translations/fr.po16
-rw-r--r--doc/translations/gl.po6
-rw-r--r--doc/translations/hi.po6
-rw-r--r--doc/translations/hu.po6
-rw-r--r--doc/translations/id.po6
-rw-r--r--doc/translations/is.po6
-rw-r--r--doc/translations/it.po6
-rw-r--r--doc/translations/ja.po6
-rw-r--r--doc/translations/ko.po15
-rw-r--r--doc/translations/lt.po6
-rw-r--r--doc/translations/lv.po6
-rw-r--r--doc/translations/mr.po6
-rw-r--r--doc/translations/nb.po6
-rw-r--r--doc/translations/ne.po6
-rw-r--r--doc/translations/nl.po6
-rw-r--r--doc/translations/pl.po6
-rw-r--r--doc/translations/pt.po91
-rw-r--r--doc/translations/pt_BR.po80
-rw-r--r--doc/translations/ro.po6
-rw-r--r--doc/translations/ru.po267
-rw-r--r--doc/translations/sk.po6
-rw-r--r--doc/translations/sr_Cyrl.po6
-rw-r--r--doc/translations/sv.po6
-rw-r--r--doc/translations/th.po6
-rw-r--r--doc/translations/tl.po6
-rw-r--r--doc/translations/tr.po6
-rw-r--r--doc/translations/uk.po111
-rw-r--r--doc/translations/vi.po6
-rw-r--r--doc/translations/zh_CN.po611
-rw-r--r--doc/translations/zh_TW.po59
342 files changed, 4867 insertions, 3567 deletions
diff --git a/doc/classes/@GlobalScope.xml b/doc/classes/@GlobalScope.xml
index 50c1ed847a..3b2e260dcb 100644
--- a/doc/classes/@GlobalScope.xml
+++ b/doc/classes/@GlobalScope.xml
@@ -442,9 +442,14 @@
<param index="0" name="variable" type="Variant" />
<description>
Returns the integer hash of the passed [param variable].
- [codeblock]
+ [codeblocks]
+ [gdscript]
print(hash("a")) # Prints 177670
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.Print(GD.Hash("a")); // Prints 177670
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="instance_from_id">
@@ -452,13 +457,29 @@
<param index="0" name="instance_id" type="int" />
<description>
Returns the [Object] that corresponds to [param instance_id]. All Objects have a unique instance ID. See also [method Object.get_instance_id].
- [codeblock]
+ [codeblocks]
+ [gdscript]
var foo = "bar"
+
func _ready():
var id = get_instance_id()
var inst = instance_from_id(id)
print(inst.foo) # Prints bar
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ public partial class MyNode : Node
+ {
+ public string Foo { get; set; } = "bar";
+
+ public override void _Ready()
+ {
+ ulong id = GetInstanceId();
+ var inst = (MyNode)InstanceFromId(Id);
+ GD.Print(inst.Foo); // Prints bar
+ }
+ }
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="inverse_lerp">
@@ -494,7 +515,7 @@
<return type="bool" />
<param index="0" name="x" type="float" />
<description>
- Returns whether [code]x[/code] is a finite value, i.e. it is not [constant @GDScript.NAN], positive infinity, or negative infinity.
+ Returns whether [param x] is a finite value, i.e. it is not [constant @GDScript.NAN], positive infinity, or negative infinity.
</description>
</method>
<method name="is_inf">
@@ -525,11 +546,36 @@
Returns [code]true[/code] if [param x] is a NaN ("Not a Number" or invalid) value.
</description>
</method>
+ <method name="is_same">
+ <return type="bool" />
+ <param index="0" name="a" type="Variant" />
+ <param index="1" name="b" type="Variant" />
+ <description>
+ Returns [code]true[/code], for value types, if [param a] and [param b] share the same value. Returns [code]true[/code], for reference types, if the references of [param a] and [param b] are the same.
+ [codeblock]
+ # Vector2 is a value type
+ var vec2_a = Vector2(0, 0)
+ var vec2_b = Vector2(0, 0)
+ var vec2_c = Vector2(1, 1)
+ is_same(vec2_a, vec2_a) # true
+ is_same(vec2_a, vec2_b) # true
+ is_same(vec2_a, vec2_c) # false
+
+ # Array is a reference type
+ var arr_a = []
+ var arr_b = []
+ is_same(arr_a, arr_a) # true
+ is_same(arr_a, arr_b) # false
+ [/codeblock]
+ These are [Variant] value types: [code]null[/code], [bool], [int], [float], [String], [StringName], [Vector2], [Vector2i], [Vector3], [Vector3i], [Vector4], [Vector4i], [Rect2], [Rect2i], [Transform2D], [Transform3D], [Plane], [Quaternion], [AABB], [Basis], [Projection], [Color], [NodePath], [RID], [Callable] and [Signal].
+ These are [Variant] reference types: [Object], [Dictionary], [Array], [PackedByteArray], [PackedInt32Array], [PackedInt64Array], [PackedFloat32Array], [PackedFloat64Array], [PackedStringArray], [PackedVector2Array], [PackedVector3Array] and [PackedColorArray].
+ </description>
+ </method>
<method name="is_zero_approx">
<return type="bool" />
<param index="0" name="x" type="float" />
<description>
- Returns [code]true[/code] if [param x] is zero or almost zero.
+ Returns [code]true[/code] if [param x] is zero or almost zero. The comparison is done using a tolerance calculation with a small internal epsilon.
This function is faster than using [method is_equal_approx] with one value as zero.
</description>
</method>
@@ -764,10 +810,16 @@
<method name="print" qualifiers="vararg">
<description>
Converts one or more arguments of any type to string in the best way possible and prints them to the console.
- [codeblock]
+ [codeblocks]
+ [gdscript]
var a = [1, 2, 3]
print("a", "b", a) # Prints ab[1, 2, 3]
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ var a = new Godot.Collections.Array { 1, 2, 3 };
+ GD.Print("a", "b", a); // Prints ab[1, 2, 3]
+ [/csharp]
+ [/codeblocks]
[b]Note:[/b] Consider using [method push_error] and [method push_warning] to print error and warning messages instead of [method print] or [method print_rich]. This distinguishes them from print messages used for debugging purposes, while also displaying a stack trace when an error or warning is printed.
</description>
</method>
@@ -775,9 +827,14 @@
<description>
Converts one or more arguments of any type to string in the best way possible and prints them to the console. The following BBCode tags are supported: b, i, u, s, indent, code, url, center, right, color, bgcolor, fgcolor. Color tags only support named colors such as [code]red[/code], [i]not[/i] hexadecimal color codes. Unsupported tags will be left as-is in standard output.
When printing to standard output, the supported subset of BBCode is converted to ANSI escape codes for the terminal emulator to display. Displaying ANSI escape codes is currently only supported on Linux and macOS. Support for ANSI escape codes may vary across terminal emulators, especially for italic and strikethrough.
- [codeblock]
+ [codeblocks]
+ [gdscript]
print_rich("[code][b]Hello world![/b][/code]") # Prints out: [b]Hello world![/b]
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.PrintRich("[code][b]Hello world![/b][/code]"); // Prints out: [b]Hello world![/b]
+ [/csharp]
+ [/codeblocks]
[b]Note:[/b] Consider using [method push_error] and [method push_warning] to print error and warning messages instead of [method print] or [method print_rich]. This distinguishes them from print messages used for debugging purposes, while also displaying a stack trace when an error or warning is printed.
</description>
</method>
@@ -789,53 +846,86 @@
<method name="printerr" qualifiers="vararg">
<description>
Prints one or more arguments to strings in the best way possible to standard error line.
- [codeblock]
+ [codeblocks]
+ [gdscript]
printerr("prints to stderr")
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.PrintErr("prints to stderr");
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="printraw" qualifiers="vararg">
<description>
Prints one or more arguments to strings in the best way possible to the OS terminal. Unlike [method print], no newline is automatically added at the end.
- [codeblock]
+ [codeblocks]
+ [gdscript]
printraw("A")
printraw("B")
printraw("C")
# Prints ABC to terminal
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.PrintRaw("A");
+ GD.PrintRaw("B");
+ GD.PrintRaw("C");
+ // Prints ABC to terminal
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="prints" qualifiers="vararg">
<description>
Prints one or more arguments to the console with a space between each argument.
- [codeblock]
+ [codeblocks]
+ [gdscript]
prints("A", "B", "C") # Prints A B C
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.PrintS("A", "B", "C"); // Prints A B C
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="printt" qualifiers="vararg">
<description>
Prints one or more arguments to the console with a tab between each argument.
- [codeblock]
+ [codeblocks]
+ [gdscript]
printt("A", "B", "C") # Prints A B C
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.PrintT("A", "B", "C"); // Prints A B C
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="push_error" qualifiers="vararg">
<description>
Pushes an error message to Godot's built-in debugger and to the OS terminal.
- [codeblock]
+ [codeblocks]
+ [gdscript]
push_error("test error") # Prints "test error" to debugger and terminal as error call
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.PushError("test error"); // Prints "test error" to debugger and terminal as error call
+ [/csharp]
+ [/codeblocks]
[b]Note:[/b] This function does not pause project execution. To print an error message and pause project execution in debug builds, use [code]assert(false, "test error")[/code] instead.
</description>
</method>
<method name="push_warning" qualifiers="vararg">
<description>
Pushes a warning message to Godot's built-in debugger and to the OS terminal.
- [codeblock]
+ [codeblocks]
+ [gdscript]
push_warning("test warning") # Prints "test warning" to debugger and terminal as warning call
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.PushWarning("test warning"); // Prints "test warning" to debugger and terminal as warning call
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="rad_to_deg">
@@ -868,9 +958,14 @@
<return type="float" />
<description>
Returns a random floating point value between [code]0.0[/code] and [code]1.0[/code] (inclusive).
- [codeblock]
+ [codeblocks]
+ [gdscript]
randf() # Returns e.g. 0.375671
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.Randf(); // Returns e.g. 0.375671
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="randf_range">
@@ -879,10 +974,16 @@
<param index="1" name="to" type="float" />
<description>
Returns a random floating point value between [param from] and [param to] (inclusive).
- [codeblock]
+ [codeblocks]
+ [gdscript]
randf_range(0, 20.5) # Returns e.g. 7.45315
randf_range(-10, 10) # Returns e.g. -3.844535
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.RandRange(0.0, 20.5); // Returns e.g. 7.45315
+ GD.RandRange(-10.0, 10.0); // Returns e.g. -3.844535
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="randfn">
@@ -897,12 +998,20 @@
<return type="int" />
<description>
Returns a random unsigned 32-bit integer. Use remainder to obtain a random value in the interval [code][0, N - 1][/code] (where N is smaller than 2^32).
- [codeblock]
+ [codeblocks]
+ [gdscript]
randi() # Returns random integer between 0 and 2^32 - 1
randi() % 20 # Returns random integer between 0 and 19
randi() % 100 # Returns random integer between 0 and 99
randi() % 100 + 1 # Returns random integer between 1 and 100
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.Randi(); // Returns random integer between 0 and 2^32 - 1
+ GD.Randi() % 20; // Returns random integer between 0 and 19
+ GD.Randi() % 100; // Returns random integer between 0 and 99
+ GD.Randi() % 100 + 1; // Returns random integer between 1 and 100
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="randi_range">
@@ -911,10 +1020,16 @@
<param index="1" name="to" type="int" />
<description>
Returns a random signed 32-bit integer between [param from] and [param to] (inclusive). If [param to] is lesser than [param from], they are swapped.
- [codeblock]
+ [codeblocks]
+ [gdscript]
randi_range(0, 1) # Returns either 0 or 1
randi_range(-10, 1000) # Returns random integer between -10 and 1000
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ GD.RandRange(0, 1); // Returns either 0 or 1
+ GD.RandRange(-10, 1000); // Returns random integer between -10 and 1000
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="randomize">
@@ -985,14 +1100,24 @@
<param index="0" name="base" type="int" />
<description>
Sets the seed for the random number generator to [param base]. Setting the seed manually can ensure consistent, repeatable results for most random functions.
- [codeblock]
+ [codeblocks]
+ [gdscript]
var my_seed = "Godot Rocks".hash()
seed(my_seed)
var a = randf() + randi()
seed(my_seed)
var b = randf() + randi()
# a and b are now identical
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ ulong mySeed = (ulong)GD.Hash("Godot Rocks");
+ GD.Seed(mySeed);
+ var a = GD.Randf() + GD.Randi();
+ GD.Seed(mySeed);
+ var b = GD.Randf() + GD.Randi();
+ // a and b are now identical
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="sign">
@@ -1146,7 +1271,13 @@
<method name="str" qualifiers="vararg">
<return type="String" />
<description>
- Converts one or more arguments of any [Variant] type to [String] in the best way possible.
+ Converts one or more arguments of any [Variant] type to a [String] in the best way possible.
+ [codeblock]
+ var a = [10, 20, 30]
+ var b = str(a)
+ print(len(a)) # Prints 3 (the number of elements in the array).
+ print(len(b)) # Prints 12 (the length of the string "[10, 20, 30]").
+ [/codeblock]
</description>
</method>
<method name="str_to_var">
@@ -1154,11 +1285,18 @@
<param index="0" name="string" type="String" />
<description>
Converts a formatted [param string] that was returned by [method var_to_str] to the original [Variant].
- [codeblock]
+ [codeblocks]
+ [gdscript]
var a = '{ "a": 1, "b": 2 }' # a is a String
var b = str_to_var(a) # b is a Dictionary
print(b["a"]) # Prints 1
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ string a = "{ \"a\": 1, \"b\": 2 }"; // a is a string
+ var b = GD.StrToVar(a).AsGodotDictionary(); // b is a Dictionary
+ GD.Print(b["a"]); // Prints 1
+ [/csharp]
+ [/codeblocks]
</description>
</method>
<method name="tan">
@@ -1218,15 +1356,21 @@
<param index="0" name="variable" type="Variant" />
<description>
Converts a [Variant] [param variable] to a formatted [String] that can then be parsed using [method str_to_var].
- [codeblock]
- a = { "a": 1, "b": 2 }
+ [codeblocks]
+ [gdscript]
+ var a = { "a": 1, "b": 2 }
print(var_to_str(a))
- [/codeblock]
+ [/gdscript]
+ [csharp]
+ var a = new Godot.Collections.Dictionary { ["a"] = 1, ["b"] = 2 };
+ GD.Print(GD.VarToStr(a));
+ [/csharp]
+ [/codeblocks]
Prints:
[codeblock]
{
- "a": 1,
- "b": 2
+ "a": 1,
+ "b": 2
}
[/codeblock]
</description>
@@ -1479,6 +1623,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>
@@ -1764,30 +1911,15 @@
<constant name="KEY_KP_9" value="4194447" enum="Key">
Number 9 on the numeric keypad.
</constant>
- <constant name="KEY_SUPER_L" value="4194368" enum="Key">
- Left Super key (Windows key).
- </constant>
- <constant name="KEY_SUPER_R" value="4194369" enum="Key">
- Right Super key (Windows key).
- </constant>
<constant name="KEY_MENU" value="4194370" enum="Key">
Context menu key.
</constant>
- <constant name="KEY_HYPER_L" value="4194371" enum="Key">
- Left Hyper key.
- </constant>
- <constant name="KEY_HYPER_R" value="4194372" enum="Key">
- Right Hyper key.
+ <constant name="KEY_HYPER" value="4194371" enum="Key">
+ Hyper key. (On Linux/X11 only).
</constant>
<constant name="KEY_HELP" value="4194373" enum="Key">
Help key.
</constant>
- <constant name="KEY_DIRECTION_L" value="4194374" enum="Key">
- Left Direction key.
- </constant>
- <constant name="KEY_DIRECTION_R" value="4194375" enum="Key">
- Right Direction key.
- </constant>
<constant name="KEY_BACK" value="4194376" enum="Key">
Media back key. Not to be confused with the Back button on an Android device.
</constant>
@@ -1809,21 +1941,6 @@
<constant name="KEY_VOLUMEUP" value="4194382" enum="Key">
Volume up key.
</constant>
- <constant name="KEY_BASSBOOST" value="4194383" enum="Key">
- Bass Boost key.
- </constant>
- <constant name="KEY_BASSUP" value="4194384" enum="Key">
- Bass up key.
- </constant>
- <constant name="KEY_BASSDOWN" value="4194385" enum="Key">
- Bass down key.
- </constant>
- <constant name="KEY_TREBLEUP" value="4194386" enum="Key">
- Treble up key.
- </constant>
- <constant name="KEY_TREBLEDOWN" value="4194387" enum="Key">
- Treble down key.
- </constant>
<constant name="KEY_MEDIAPLAY" value="4194388" enum="Key">
Media play key.
</constant>
@@ -1908,7 +2025,7 @@
<constant name="KEY_LAUNCHF" value="4194415" enum="Key">
Launch Shortcut F key.
</constant>
- <constant name="KEY_UNKNOWN" value="16777215" enum="Key">
+ <constant name="KEY_UNKNOWN" value="8388607" enum="Key">
Unknown key.
</constant>
<constant name="KEY_SPACE" value="32" enum="Key">
@@ -2118,229 +2235,49 @@
<constant name="KEY_ASCIITILDE" value="126" enum="Key">
~ key.
</constant>
- <constant name="KEY_NOBREAKSPACE" value="160" enum="Key">
- Non-breakable space key.
- </constant>
- <constant name="KEY_EXCLAMDOWN" value="161" enum="Key">
- ¡ key.
- </constant>
- <constant name="KEY_CENT" value="162" enum="Key">
- ¢ key.
- </constant>
- <constant name="KEY_STERLING" value="163" enum="Key">
- £ key.
- </constant>
- <constant name="KEY_CURRENCY" value="164" enum="Key">
- ¤ key.
- </constant>
<constant name="KEY_YEN" value="165" enum="Key">
Â¥ key.
</constant>
- <constant name="KEY_BROKENBAR" value="166" enum="Key">
- ¦ key.
- </constant>
<constant name="KEY_SECTION" value="167" enum="Key">
§ key.
</constant>
- <constant name="KEY_DIAERESIS" value="168" enum="Key">
- ¨ key.
- </constant>
- <constant name="KEY_COPYRIGHT" value="169" enum="Key">
- © key.
- </constant>
- <constant name="KEY_ORDFEMININE" value="170" enum="Key">
- ª key.
- </constant>
- <constant name="KEY_GUILLEMOTLEFT" value="171" enum="Key">
- « key.
- </constant>
- <constant name="KEY_NOTSIGN" value="172" enum="Key">
- ¬ key.
+ <constant name="KEY_GLOBE" value="4194416" enum="Key">
+ "Globe" key on Mac / iPad keyboard.
</constant>
- <constant name="KEY_HYPHEN" value="173" enum="Key">
- Soft hyphen key.
+ <constant name="KEY_KEYBOARD" value="4194417" enum="Key">
+ "On-screen keyboard" key iPad keyboard.
</constant>
- <constant name="KEY_REGISTERED" value="174" enum="Key">
- ® key.
+ <constant name="KEY_JIS_EISU" value="4194418" enum="Key">
+ 英数 key on Mac keyboard.
</constant>
- <constant name="KEY_MACRON" value="175" enum="Key">
- ¯ key.
+ <constant name="KEY_JIS_KANA" value="4194419" enum="Key">
+ ã‹ãª key on Mac keyboard.
</constant>
- <constant name="KEY_DEGREE" value="176" enum="Key">
- ° key.
- </constant>
- <constant name="KEY_PLUSMINUS" value="177" enum="Key">
- ± key.
- </constant>
- <constant name="KEY_TWOSUPERIOR" value="178" enum="Key">
- ² key.
- </constant>
- <constant name="KEY_THREESUPERIOR" value="179" enum="Key">
- ³ key.
- </constant>
- <constant name="KEY_ACUTE" value="180" enum="Key">
- ´ key.
- </constant>
- <constant name="KEY_MU" value="181" enum="Key">
- µ key.
- </constant>
- <constant name="KEY_PARAGRAPH" value="182" enum="Key">
- ¶ key.
- </constant>
- <constant name="KEY_PERIODCENTERED" value="183" enum="Key">
- · key.
- </constant>
- <constant name="KEY_CEDILLA" value="184" enum="Key">
- ¸ key.
- </constant>
- <constant name="KEY_ONESUPERIOR" value="185" enum="Key">
- ¹ key.
- </constant>
- <constant name="KEY_MASCULINE" value="186" enum="Key">
- º key.
- </constant>
- <constant name="KEY_GUILLEMOTRIGHT" value="187" enum="Key">
- » key.
- </constant>
- <constant name="KEY_ONEQUARTER" value="188" enum="Key">
- ¼ key.
- </constant>
- <constant name="KEY_ONEHALF" value="189" enum="Key">
- ½ key.
- </constant>
- <constant name="KEY_THREEQUARTERS" value="190" enum="Key">
- ¾ key.
- </constant>
- <constant name="KEY_QUESTIONDOWN" value="191" enum="Key">
- ¿ key.
- </constant>
- <constant name="KEY_AGRAVE" value="192" enum="Key">
- À key.
- </constant>
- <constant name="KEY_AACUTE" value="193" enum="Key">
- Ã key.
- </constant>
- <constant name="KEY_ACIRCUMFLEX" value="194" enum="Key">
- Â key.
- </constant>
- <constant name="KEY_ATILDE" value="195" enum="Key">
- Ã key.
- </constant>
- <constant name="KEY_ADIAERESIS" value="196" enum="Key">
- Ä key.
- </constant>
- <constant name="KEY_ARING" value="197" enum="Key">
- Ã… key.
- </constant>
- <constant name="KEY_AE" value="198" enum="Key">
- Æ key.
- </constant>
- <constant name="KEY_CCEDILLA" value="199" enum="Key">
- Ç key.
- </constant>
- <constant name="KEY_EGRAVE" value="200" enum="Key">
- È key.
- </constant>
- <constant name="KEY_EACUTE" value="201" enum="Key">
- É key.
- </constant>
- <constant name="KEY_ECIRCUMFLEX" value="202" enum="Key">
- Ê key.
- </constant>
- <constant name="KEY_EDIAERESIS" value="203" enum="Key">
- Ë key.
- </constant>
- <constant name="KEY_IGRAVE" value="204" enum="Key">
- Ì key.
- </constant>
- <constant name="KEY_IACUTE" value="205" enum="Key">
- Ã key.
- </constant>
- <constant name="KEY_ICIRCUMFLEX" value="206" enum="Key">
- ÃŽ key.
- </constant>
- <constant name="KEY_IDIAERESIS" value="207" enum="Key">
- Ã key.
- </constant>
- <constant name="KEY_ETH" value="208" enum="Key">
- Ã key.
- </constant>
- <constant name="KEY_NTILDE" value="209" enum="Key">
- Ñ key.
- </constant>
- <constant name="KEY_OGRAVE" value="210" enum="Key">
- Ã’ key.
- </constant>
- <constant name="KEY_OACUTE" value="211" enum="Key">
- Ó key.
- </constant>
- <constant name="KEY_OCIRCUMFLEX" value="212" enum="Key">
- Ô key.
- </constant>
- <constant name="KEY_OTILDE" value="213" enum="Key">
- Õ key.
- </constant>
- <constant name="KEY_ODIAERESIS" value="214" enum="Key">
- Ö key.
- </constant>
- <constant name="KEY_MULTIPLY" value="215" enum="Key">
- × key.
- </constant>
- <constant name="KEY_OOBLIQUE" value="216" enum="Key">
- Ø key.
- </constant>
- <constant name="KEY_UGRAVE" value="217" enum="Key">
- Ù key.
- </constant>
- <constant name="KEY_UACUTE" value="218" enum="Key">
- Ú key.
- </constant>
- <constant name="KEY_UCIRCUMFLEX" value="219" enum="Key">
- Û key.
- </constant>
- <constant name="KEY_UDIAERESIS" value="220" enum="Key">
- Ü key.
- </constant>
- <constant name="KEY_YACUTE" value="221" enum="Key">
- Ã key.
- </constant>
- <constant name="KEY_THORN" value="222" enum="Key">
- Þ key.
- </constant>
- <constant name="KEY_SSHARP" value="223" enum="Key">
- ß key.
- </constant>
- <constant name="KEY_DIVISION" value="247" enum="Key">
- ÷ key.
- </constant>
- <constant name="KEY_YDIAERESIS" value="255" enum="Key">
- ÿ key.
- </constant>
- <constant name="KEY_CODE_MASK" value="8388607" enum="KeyModifierMask">
+ <constant name="KEY_CODE_MASK" value="8388607" enum="KeyModifierMask" is_bitfield="true">
Key Code mask.
</constant>
- <constant name="KEY_MODIFIER_MASK" value="532676608" enum="KeyModifierMask">
+ <constant name="KEY_MODIFIER_MASK" value="532676608" enum="KeyModifierMask" is_bitfield="true">
Modifier key mask.
</constant>
- <constant name="KEY_MASK_CMD_OR_CTRL" value="16777216" enum="KeyModifierMask">
+ <constant name="KEY_MASK_CMD_OR_CTRL" value="16777216" enum="KeyModifierMask" is_bitfield="true">
Automatically remapped to [constant KEY_META] on macOS and [constant KEY_CTRL] on other platforms, this mask is never set in the actual events, and should be used for key mapping only.
</constant>
- <constant name="KEY_MASK_SHIFT" value="33554432" enum="KeyModifierMask">
+ <constant name="KEY_MASK_SHIFT" value="33554432" enum="KeyModifierMask" is_bitfield="true">
Shift key mask.
</constant>
- <constant name="KEY_MASK_ALT" value="67108864" enum="KeyModifierMask">
+ <constant name="KEY_MASK_ALT" value="67108864" enum="KeyModifierMask" is_bitfield="true">
Alt or Option (on macOS) key mask.
</constant>
- <constant name="KEY_MASK_META" value="134217728" enum="KeyModifierMask">
+ <constant name="KEY_MASK_META" value="134217728" enum="KeyModifierMask" is_bitfield="true">
Command (on macOS) or Meta/Windows key mask.
</constant>
- <constant name="KEY_MASK_CTRL" value="268435456" enum="KeyModifierMask">
+ <constant name="KEY_MASK_CTRL" value="268435456" enum="KeyModifierMask" is_bitfield="true">
Ctrl key mask.
</constant>
- <constant name="KEY_MASK_KPAD" value="536870912" enum="KeyModifierMask">
+ <constant name="KEY_MASK_KPAD" value="536870912" enum="KeyModifierMask" is_bitfield="true">
Keypad key mask.
</constant>
- <constant name="KEY_MASK_GROUP_SWITCH" value="1073741824" enum="KeyModifierMask">
+ <constant name="KEY_MASK_GROUP_SWITCH" value="1073741824" enum="KeyModifierMask" is_bitfield="true">
Group Switch key mask.
</constant>
<constant name="MOUSE_BUTTON_NONE" value="0" enum="MouseButton">
@@ -2373,19 +2310,19 @@
<constant name="MOUSE_BUTTON_XBUTTON2" value="9" enum="MouseButton">
Extra mouse button 2. This is sometimes present, usually to the sides of the mouse.
</constant>
- <constant name="MOUSE_BUTTON_MASK_LEFT" value="1" enum="MouseButton">
+ <constant name="MOUSE_BUTTON_MASK_LEFT" value="1" enum="MouseButtonMask" is_bitfield="true">
Primary mouse button mask, usually for the left button.
</constant>
- <constant name="MOUSE_BUTTON_MASK_RIGHT" value="2" enum="MouseButton">
+ <constant name="MOUSE_BUTTON_MASK_RIGHT" value="2" enum="MouseButtonMask" is_bitfield="true">
Secondary mouse button mask, usually for the right button.
</constant>
- <constant name="MOUSE_BUTTON_MASK_MIDDLE" value="4" enum="MouseButton">
+ <constant name="MOUSE_BUTTON_MASK_MIDDLE" value="4" enum="MouseButtonMask" is_bitfield="true">
Middle mouse button mask.
</constant>
- <constant name="MOUSE_BUTTON_MASK_XBUTTON1" value="128" enum="MouseButton">
+ <constant name="MOUSE_BUTTON_MASK_MB_XBUTTON1" value="128" enum="MouseButtonMask" is_bitfield="true">
Extra mouse button 1 mask.
</constant>
- <constant name="MOUSE_BUTTON_MASK_XBUTTON2" value="256" enum="MouseButton">
+ <constant name="MOUSE_BUTTON_MASK_MB_XBUTTON2" value="256" enum="MouseButtonMask" is_bitfield="true">
Extra mouse button 2 mask.
</constant>
<constant name="JOY_BUTTON_INVALID" value="-1" enum="JoyButton">
@@ -2716,7 +2653,7 @@
Additionally, other keywords can be included: [code]"exp"[/code] for exponential range editing, [code]"radians"[/code] for editing radian angles in degrees, [code]"degrees"[/code] to hint at an angle and [code]"hide_slider"[/code] to hide the slider.
</constant>
<constant name="PROPERTY_HINT_ENUM" value="2" enum="PropertyHint">
- Hints that an [int], [float], or [String] property is an enumerated value to pick in a list specified via a hint string.
+ Hints that an [int] or [String] property is an enumerated value to pick in a list specified via a hint string.
The hint string is a comma separated list of names such as [code]"Hello,Something,Else"[/code]. Whitespaces are [b]not[/b] removed from either end of a name. For integer and float properties, the first name in the list has value 0, the next 1, and so on. Explicit values can also be specified by appending [code]:integer[/code] to the name, e.g. [code]"Zero,One,Three:3,Four,Six:6"[/code].
</constant>
<constant name="PROPERTY_HINT_ENUM_SUGGESTION" value="3" enum="PropertyHint">
@@ -2791,157 +2728,138 @@
</constant>
<constant name="PROPERTY_HINT_NODE_PATH_TO_EDITED_NODE" value="24" enum="PropertyHint">
</constant>
- <constant name="PROPERTY_HINT_METHOD_OF_VARIANT_TYPE" value="25" enum="PropertyHint">
- </constant>
- <constant name="PROPERTY_HINT_METHOD_OF_BASE_TYPE" value="26" enum="PropertyHint">
- </constant>
- <constant name="PROPERTY_HINT_METHOD_OF_INSTANCE" value="27" enum="PropertyHint">
- </constant>
- <constant name="PROPERTY_HINT_METHOD_OF_SCRIPT" value="28" enum="PropertyHint">
- </constant>
- <constant name="PROPERTY_HINT_PROPERTY_OF_VARIANT_TYPE" value="29" enum="PropertyHint">
- </constant>
- <constant name="PROPERTY_HINT_PROPERTY_OF_BASE_TYPE" value="30" enum="PropertyHint">
- </constant>
- <constant name="PROPERTY_HINT_PROPERTY_OF_INSTANCE" value="31" enum="PropertyHint">
- </constant>
- <constant name="PROPERTY_HINT_PROPERTY_OF_SCRIPT" value="32" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_OBJECT_TOO_BIG" value="25" enum="PropertyHint">
</constant>
- <constant name="PROPERTY_HINT_OBJECT_TOO_BIG" value="33" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_NODE_PATH_VALID_TYPES" value="26" enum="PropertyHint">
</constant>
- <constant name="PROPERTY_HINT_NODE_PATH_VALID_TYPES" value="34" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_SAVE_FILE" value="27" enum="PropertyHint">
</constant>
- <constant name="PROPERTY_HINT_SAVE_FILE" value="35" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_GLOBAL_SAVE_FILE" value="28" enum="PropertyHint">
</constant>
- <constant name="PROPERTY_HINT_GLOBAL_SAVE_FILE" value="36" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_INT_IS_OBJECTID" value="29" enum="PropertyHint">
</constant>
- <constant name="PROPERTY_HINT_INT_IS_OBJECTID" value="37" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_INT_IS_POINTER" value="30" enum="PropertyHint">
</constant>
- <constant name="PROPERTY_HINT_INT_IS_POINTER" value="38" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_ARRAY_TYPE" value="31" enum="PropertyHint">
</constant>
- <constant name="PROPERTY_HINT_ARRAY_TYPE" value="39" enum="PropertyHint">
- </constant>
- <constant name="PROPERTY_HINT_LOCALE_ID" value="40" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_LOCALE_ID" value="32" enum="PropertyHint">
Hints that a string property is a locale code. Editing it will show a locale dialog for picking language and country.
</constant>
- <constant name="PROPERTY_HINT_LOCALIZABLE_STRING" value="41" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_LOCALIZABLE_STRING" value="33" enum="PropertyHint">
Hints that a dictionary property is string translation map. Dictionary keys are locale codes and, values are translated strings.
</constant>
- <constant name="PROPERTY_HINT_NODE_TYPE" value="42" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_NODE_TYPE" value="34" enum="PropertyHint">
</constant>
- <constant name="PROPERTY_HINT_HIDE_QUATERNION_EDIT" value="43" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_HIDE_QUATERNION_EDIT" value="35" enum="PropertyHint">
Hints that a quaternion property should disable the temporary euler editor.
</constant>
- <constant name="PROPERTY_HINT_PASSWORD" value="44" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_PASSWORD" value="36" enum="PropertyHint">
Hints that a string property is a password, and every character is replaced with the secret character.
</constant>
- <constant name="PROPERTY_HINT_MAX" value="45" enum="PropertyHint">
+ <constant name="PROPERTY_HINT_MAX" value="37" enum="PropertyHint">
</constant>
- <constant name="PROPERTY_USAGE_NONE" value="0" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_NONE" value="0" enum="PropertyUsageFlags" is_bitfield="true">
The property is not stored, and does not display in the editor. This is the default for non-exported properties.
</constant>
- <constant name="PROPERTY_USAGE_STORAGE" value="2" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_STORAGE" value="2" enum="PropertyUsageFlags" is_bitfield="true">
The property is serialized and saved in the scene file (default).
</constant>
- <constant name="PROPERTY_USAGE_EDITOR" value="4" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_EDITOR" value="4" enum="PropertyUsageFlags" is_bitfield="true">
The property is shown in the [EditorInspector] (default).
</constant>
- <constant name="PROPERTY_USAGE_CHECKABLE" value="8" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_INTERNAL" value="8" enum="PropertyUsageFlags" is_bitfield="true">
+ </constant>
+ <constant name="PROPERTY_USAGE_CHECKABLE" value="16" enum="PropertyUsageFlags" is_bitfield="true">
The property can be checked in the [EditorInspector].
</constant>
- <constant name="PROPERTY_USAGE_CHECKED" value="16" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_CHECKED" value="32" enum="PropertyUsageFlags" is_bitfield="true">
The property is checked in the [EditorInspector].
</constant>
- <constant name="PROPERTY_USAGE_INTERNATIONALIZED" value="32" enum="PropertyUsageFlags">
- The property is a translatable string.
- </constant>
- <constant name="PROPERTY_USAGE_GROUP" value="64" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_GROUP" value="64" enum="PropertyUsageFlags" is_bitfield="true">
Used to group properties together in the editor. See [EditorInspector].
</constant>
- <constant name="PROPERTY_USAGE_CATEGORY" value="128" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_CATEGORY" value="128" enum="PropertyUsageFlags" is_bitfield="true">
Used to categorize properties together in the editor.
</constant>
- <constant name="PROPERTY_USAGE_SUBGROUP" value="256" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_SUBGROUP" value="256" enum="PropertyUsageFlags" is_bitfield="true">
Used to group properties together in the editor in a subgroup (under a group). See [EditorInspector].
</constant>
- <constant name="PROPERTY_USAGE_CLASS_IS_BITFIELD" value="512" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_CLASS_IS_BITFIELD" value="512" enum="PropertyUsageFlags" is_bitfield="true">
</constant>
- <constant name="PROPERTY_USAGE_NO_INSTANCE_STATE" value="1024" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_NO_INSTANCE_STATE" value="1024" enum="PropertyUsageFlags" is_bitfield="true">
The property does not save its state in [PackedScene].
</constant>
- <constant name="PROPERTY_USAGE_RESTART_IF_CHANGED" value="2048" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_RESTART_IF_CHANGED" value="2048" enum="PropertyUsageFlags" is_bitfield="true">
Editing the property prompts the user for restarting the editor.
</constant>
- <constant name="PROPERTY_USAGE_SCRIPT_VARIABLE" value="4096" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_SCRIPT_VARIABLE" value="4096" enum="PropertyUsageFlags" is_bitfield="true">
The property is a script variable which should be serialized and saved in the scene file.
</constant>
- <constant name="PROPERTY_USAGE_STORE_IF_NULL" value="8192" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_STORE_IF_NULL" value="8192" enum="PropertyUsageFlags" is_bitfield="true">
+ </constant>
+ <constant name="PROPERTY_USAGE_UPDATE_ALL_IF_MODIFIED" value="16384" enum="PropertyUsageFlags" is_bitfield="true">
</constant>
- <constant name="PROPERTY_USAGE_UPDATE_ALL_IF_MODIFIED" value="16384" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_SCRIPT_DEFAULT_VALUE" value="32768" enum="PropertyUsageFlags" is_bitfield="true">
</constant>
- <constant name="PROPERTY_USAGE_SCRIPT_DEFAULT_VALUE" value="32768" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_CLASS_IS_ENUM" value="65536" enum="PropertyUsageFlags" is_bitfield="true">
</constant>
- <constant name="PROPERTY_USAGE_CLASS_IS_ENUM" value="65536" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_NIL_IS_VARIANT" value="131072" enum="PropertyUsageFlags" is_bitfield="true">
</constant>
- <constant name="PROPERTY_USAGE_NIL_IS_VARIANT" value="131072" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_ARRAY" value="262144" enum="PropertyUsageFlags" is_bitfield="true">
+ The property is an array.
</constant>
- <constant name="PROPERTY_USAGE_INTERNAL" value="262144" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_ALWAYS_DUPLICATE" value="524288" enum="PropertyUsageFlags" is_bitfield="true">
+ When duplicating a resource with [method Resource.duplicate], and this flag is set on a property of that resource, the property should always be duplicated, regardless of the [code]subresources[/code] bool parameter.
</constant>
- <constant name="PROPERTY_USAGE_DO_NOT_SHARE_ON_DUPLICATE" value="524288" enum="PropertyUsageFlags">
- If the property is a [Resource], a new copy of it is always created when calling [method Node.duplicate] or [method Resource.duplicate].
+ <constant name="PROPERTY_USAGE_NEVER_DUPLICATE" value="1048576" enum="PropertyUsageFlags" is_bitfield="true">
+ When duplicating a resource with [method Resource.duplicate], and this flag is set on a property of that resource, the property should never be duplicated, regardless of the [code]subresources[/code] bool parameter.
</constant>
- <constant name="PROPERTY_USAGE_HIGH_END_GFX" value="1048576" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_HIGH_END_GFX" value="2097152" enum="PropertyUsageFlags" is_bitfield="true">
The property is only shown in the editor if modern renderers are supported (GLES3 is excluded).
</constant>
- <constant name="PROPERTY_USAGE_NODE_PATH_FROM_SCENE_ROOT" value="2097152" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_NODE_PATH_FROM_SCENE_ROOT" value="4194304" enum="PropertyUsageFlags" is_bitfield="true">
</constant>
- <constant name="PROPERTY_USAGE_RESOURCE_NOT_PERSISTENT" value="4194304" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_RESOURCE_NOT_PERSISTENT" value="8388608" enum="PropertyUsageFlags" is_bitfield="true">
</constant>
- <constant name="PROPERTY_USAGE_KEYING_INCREMENTS" value="8388608" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_KEYING_INCREMENTS" value="16777216" enum="PropertyUsageFlags" is_bitfield="true">
</constant>
- <constant name="PROPERTY_USAGE_DEFERRED_SET_RESOURCE" value="16777216" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_DEFERRED_SET_RESOURCE" value="33554432" enum="PropertyUsageFlags" is_bitfield="true">
</constant>
- <constant name="PROPERTY_USAGE_EDITOR_INSTANTIATE_OBJECT" value="33554432" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_EDITOR_INSTANTIATE_OBJECT" value="67108864" enum="PropertyUsageFlags" is_bitfield="true">
</constant>
- <constant name="PROPERTY_USAGE_EDITOR_BASIC_SETTING" value="67108864" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_EDITOR_BASIC_SETTING" value="134217728" enum="PropertyUsageFlags" is_bitfield="true">
</constant>
- <constant name="PROPERTY_USAGE_READ_ONLY" value="134217728" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_READ_ONLY" value="268435456" enum="PropertyUsageFlags" is_bitfield="true">
The property is read-only in the [EditorInspector].
</constant>
- <constant name="PROPERTY_USAGE_ARRAY" value="268435456" enum="PropertyUsageFlags">
- The property is an array.
- </constant>
- <constant name="PROPERTY_USAGE_DEFAULT" value="6" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_DEFAULT" value="6" enum="PropertyUsageFlags" is_bitfield="true">
Default usage (storage, editor and network).
</constant>
- <constant name="PROPERTY_USAGE_DEFAULT_INTL" value="38" enum="PropertyUsageFlags">
- Default usage for translatable strings (storage, editor, network and internationalized).
- </constant>
- <constant name="PROPERTY_USAGE_NO_EDITOR" value="2" enum="PropertyUsageFlags">
+ <constant name="PROPERTY_USAGE_NO_EDITOR" value="2" enum="PropertyUsageFlags" is_bitfield="true">
Default usage but without showing the property in the editor (storage, network).
</constant>
- <constant name="METHOD_FLAG_NORMAL" value="1" enum="MethodFlags">
+ <constant name="METHOD_FLAG_NORMAL" value="1" enum="MethodFlags" is_bitfield="true">
Flag for a normal method.
</constant>
- <constant name="METHOD_FLAG_EDITOR" value="2" enum="MethodFlags">
+ <constant name="METHOD_FLAG_EDITOR" value="2" enum="MethodFlags" is_bitfield="true">
Flag for an editor method.
</constant>
- <constant name="METHOD_FLAG_CONST" value="4" enum="MethodFlags">
+ <constant name="METHOD_FLAG_CONST" value="4" enum="MethodFlags" is_bitfield="true">
Flag for a constant method.
</constant>
- <constant name="METHOD_FLAG_VIRTUAL" value="8" enum="MethodFlags">
+ <constant name="METHOD_FLAG_VIRTUAL" value="8" enum="MethodFlags" is_bitfield="true">
Flag for a virtual method.
</constant>
- <constant name="METHOD_FLAG_VARARG" value="16" enum="MethodFlags">
+ <constant name="METHOD_FLAG_VARARG" value="16" enum="MethodFlags" is_bitfield="true">
Flag for a method with a variable number of arguments.
</constant>
- <constant name="METHOD_FLAG_STATIC" value="32" enum="MethodFlags">
+ <constant name="METHOD_FLAG_STATIC" value="32" enum="MethodFlags" is_bitfield="true">
Flag for a static method.
</constant>
- <constant name="METHOD_FLAG_OBJECT_CORE" value="64" enum="MethodFlags">
+ <constant name="METHOD_FLAG_OBJECT_CORE" value="64" enum="MethodFlags" is_bitfield="true">
Used internally. Allows to not dump core virtual methods (such as [method Object._notification]) to the JSON API.
</constant>
- <constant name="METHOD_FLAGS_DEFAULT" value="1" enum="MethodFlags">
+ <constant name="METHOD_FLAGS_DEFAULT" value="1" enum="MethodFlags" is_bitfield="true">
Default method flags (normal).
</constant>
<constant name="TYPE_NIL" value="0" enum="Variant.Type">
diff --git a/doc/classes/AABB.xml b/doc/classes/AABB.xml
index ca454cafa3..2c5337eea3 100644
--- a/doc/classes/AABB.xml
+++ b/doc/classes/AABB.xml
@@ -66,7 +66,7 @@
[/gdscript]
[csharp]
// position (-3, 2, 0), size (1, 1, 1)
- var box = new AABB(new Vector3(-3, 2, 0), new Vector3(1, 1, 1));
+ var box = new Aabb(new Vector3(-3, 2, 0), new Vector3(1, 1, 1));
// position (-3, -1, 0), size (3, 4, 2), so we fit both the original AABB and Vector3(0, -1, 2)
var box2 = box.Expand(new Vector3(0, -1, 2));
[/csharp]
diff --git a/doc/classes/AESContext.xml b/doc/classes/AESContext.xml
index 7f582e4be7..747968ea91 100644
--- a/doc/classes/AESContext.xml
+++ b/doc/classes/AESContext.xml
@@ -39,39 +39,38 @@
[/gdscript]
[csharp]
using Godot;
- using System;
using System.Diagnostics;
- public class Example : Node
+ public partial class MyNode : Node
{
- public AESContext Aes = new AESContext();
+ private AesContext _aes = new AesContext();
public override void _Ready()
{
string key = "My secret key!!!"; // Key must be either 16 or 32 bytes.
string data = "My secret text!!"; // Data size must be multiple of 16 bytes, apply padding if needed.
// Encrypt ECB
- Aes.Start(AESContext.Mode.EcbEncrypt, key.ToUTF8());
- byte[] encrypted = Aes.Update(data.ToUTF8());
- Aes.Finish();
+ _aes.Start(AesContext.Mode.EcbEncrypt, key.ToUtf8());
+ byte[] encrypted = _aes.Update(data.ToUtf8());
+ _aes.Finish();
// Decrypt ECB
- Aes.Start(AESContext.Mode.EcbDecrypt, key.ToUTF8());
- byte[] decrypted = Aes.Update(encrypted);
- Aes.Finish();
+ _aes.Start(AesContext.Mode.EcbDecrypt, key.ToUtf8());
+ byte[] decrypted = _aes.Update(encrypted);
+ _aes.Finish();
// Check ECB
- Debug.Assert(decrypted == data.ToUTF8());
+ Debug.Assert(decrypted == data.ToUtf8());
string iv = "My secret iv!!!!"; // IV must be of exactly 16 bytes.
// Encrypt CBC
- Aes.Start(AESContext.Mode.EcbEncrypt, key.ToUTF8(), iv.ToUTF8());
- encrypted = Aes.Update(data.ToUTF8());
- Aes.Finish();
+ _aes.Start(AesContext.Mode.EcbEncrypt, key.ToUtf8(), iv.ToUtf8());
+ encrypted = _aes.Update(data.ToUtf8());
+ _aes.Finish();
// Decrypt CBC
- Aes.Start(AESContext.Mode.EcbDecrypt, key.ToUTF8(), iv.ToUTF8());
- decrypted = Aes.Update(encrypted);
- Aes.Finish();
+ _aes.Start(AesContext.Mode.EcbDecrypt, key.ToUtf8(), iv.ToUtf8());
+ decrypted = _aes.Update(encrypted);
+ _aes.Finish();
// Check CBC
- Debug.Assert(decrypted == data.ToUTF8());
+ Debug.Assert(decrypted == data.ToUtf8());
}
}
[/csharp]
diff --git a/doc/classes/AStar3D.xml b/doc/classes/AStar3D.xml
index 4e8394195d..f0481c1745 100644
--- a/doc/classes/AStar3D.xml
+++ b/doc/classes/AStar3D.xml
@@ -19,15 +19,16 @@
return min(0, abs(u - v) - 1)
[/gdscript]
[csharp]
- public class MyAStar : AStar3D
+ public partial class MyAStar : AStar3D
{
- public override float _ComputeCost(int u, int v)
+ public override float _ComputeCost(long fromId, long toId)
{
- return Mathf.Abs(u - v);
+ return Mathf.Abs((int)(fromId - toId));
}
- public override float _EstimateCost(int u, int v)
+
+ public override float _EstimateCost(long fromId, long toId)
{
- return Mathf.Min(0, Mathf.Abs(u - v) - 1);
+ return Mathf.Min(0, Mathf.Abs((int)(fromId - toId)) - 1);
}
}
[/csharp]
diff --git a/doc/classes/AStarGrid2D.xml b/doc/classes/AStarGrid2D.xml
index bffa395770..b253a33377 100644
--- a/doc/classes/AStarGrid2D.xml
+++ b/doc/classes/AStarGrid2D.xml
@@ -17,11 +17,11 @@
[/gdscript]
[csharp]
AStarGrid2D astarGrid = new AStarGrid2D();
- astarGrid.Size = new Vector2i(32, 32);
- astarGrid.CellSize = new Vector2i(16, 16);
+ astarGrid.Size = new Vector2I(32, 32);
+ astarGrid.CellSize = new Vector2I(16, 16);
astarGrid.Update();
- GD.Print(astarGrid.GetIdPath(Vector2i.Zero, new Vector2i(3, 4))); // prints (0, 0), (1, 1), (2, 2), (3, 3), (3, 4)
- GD.Print(astarGrid.GetPointPath(Vector2i.Zero, new Vector2i(3, 4))); // prints (0, 0), (16, 16), (32, 32), (48, 48), (48, 64)
+ GD.Print(astarGrid.GetIdPath(Vector2I.Zero, new Vector2I(3, 4))); // prints (0, 0), (1, 1), (2, 2), (3, 3), (3, 4)
+ GD.Print(astarGrid.GetPointPath(Vector2I.Zero, new Vector2I(3, 4))); // prints (0, 0), (16, 16), (32, 32), (48, 48), (48, 64)
[/csharp]
[/codeblocks]
</description>
@@ -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>
@@ -106,6 +120,15 @@
[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">
<return type="void" />
<description>
@@ -117,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.
diff --git a/doc/classes/AcceptDialog.xml b/doc/classes/AcceptDialog.xml
index 4da9e41ca8..c0e5d6ad07 100644
--- a/doc/classes/AcceptDialog.xml
+++ b/doc/classes/AcceptDialog.xml
@@ -53,7 +53,7 @@
<return type="void" />
<param index="0" name="button" type="Control" />
<description>
- Removes the [param button] from the dialog. Does NOT free the [param button]. The [param button] must be a [Button] added with [method add_button] or [method add_cancel_button] method. After removal, pressing the [param button] will no longer emit this dialog's [signal custom_action] or [signal cancelled] signals.
+ Removes the [param button] from the dialog. Does NOT free the [param button]. The [param button] must be a [Button] added with [method add_button] or [method add_cancel_button] method. After removal, pressing the [param button] will no longer emit this dialog's [signal custom_action] or [signal canceled] signals.
</description>
</method>
</methods>
@@ -81,7 +81,7 @@
<member name="wrap_controls" type="bool" setter="set_wrap_controls" getter="is_wrapping_controls" overrides="Window" default="true" />
</members>
<signals>
- <signal name="cancelled">
+ <signal name="canceled">
<description>
Emitted when the dialog is closed or the button created with [method add_cancel_button] is pressed.
</description>
diff --git a/doc/classes/AnimatableBody3D.xml b/doc/classes/AnimatableBody3D.xml
index 2a08c4c8f1..0733780bf7 100644
--- a/doc/classes/AnimatableBody3D.xml
+++ b/doc/classes/AnimatableBody3D.xml
@@ -7,6 +7,7 @@
Animatable body for 3D physics.
An animatable body can't be moved by external forces or contacts, but can be moved by script or animation to affect other bodies in its path. It is ideal for implementing moving objects in the environment, such as moving platforms or doors.
When the body is moved manually, either from code or from an [AnimationPlayer] (with [member AnimationPlayer.playback_process_mode] set to [code]physics[/code]), the physics will automatically compute an estimate of their linear and angular velocity. This makes them very useful for moving platforms or other AnimationPlayer-controlled objects (like a door, a bridge that opens, etc).
+ [b]Warning:[/b] With a non-uniform scale this node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change the size(s) of its collision shape(s) instead.
</description>
<tutorials>
<link title="3D Physics Tests Demo">https://godotengine.org/asset-library/asset/675</link>
diff --git a/doc/classes/AnimatedSprite2D.xml b/doc/classes/AnimatedSprite2D.xml
index afbe34816a..9872c59990 100644
--- a/doc/classes/AnimatedSprite2D.xml
+++ b/doc/classes/AnimatedSprite2D.xml
@@ -5,34 +5,82 @@
</brief_description>
<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.
- [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>
<link title="2D Sprite animation">$DOCS_URL/tutorials/2d/2d_sprite_animation.html</link>
<link title="2D Dodge The Creeps Demo">https://godotengine.org/asset-library/asset/515</link>
</tutorials>
<methods>
+ <method name="get_playing_speed" qualifiers="const">
+ <return type="float" />
+ <description>
+ Returns the actual playing speed of current animation or [code]0[/code] if not playing. This speed is the [member speed_scale] property multiplied by [code]custom_speed[/code] argument specified when calling the [method play] method.
+ Returns a negative value if the current animation is playing backwards.
+ </description>
+ </method>
+ <method name="is_playing" qualifiers="const">
+ <return type="bool" />
+ <description>
+ Returns [code]true[/code] if an animation is currently playing (even if [member speed_scale] and/or [code]custom_speed[/code] are [code]0[/code]).
+ </description>
+ </method>
+ <method name="pause">
+ <return type="void" />
+ <description>
+ Pauses the currently playing animation. The [member frame] and [member frame_progress] will be kept and calling [method play] or [method play_backwards] without arguments will resume the animation from the current playback position.
+ See also [method stop].
+ </description>
+ </method>
<method name="play">
<return type="void" />
- <param index="0" name="anim" type="StringName" default="&amp;&quot;&quot;" />
- <param index="1" name="backwards" type="bool" default="false" />
+ <param index="0" name="name" type="StringName" default="&amp;&quot;&quot;" />
+ <param index="1" name="custom_speed" type="float" default="1.0" />
+ <param index="2" name="from_end" type="bool" default="false" />
+ <description>
+ Plays the animation with key [param name]. If [param custom_speed] is negative and [param from_end] is [code]true[/code], the animation will play backwards (which is equivalent to calling [method play_backwards]).
+ If this method is called with that same animation [param name], or with no [param name] parameter, the assigned animation will resume playing if it was paused.
+ </description>
+ </method>
+ <method name="play_backwards">
+ <return type="void" />
+ <param index="0" name="name" type="StringName" default="&amp;&quot;&quot;" />
+ <description>
+ Plays the animation with key [param name] in reverse.
+ This method is a shorthand for [method play] with [code]custom_speed = -1.0[/code] and [code]from_end = true[/code], so see its description for more information.
+ </description>
+ </method>
+ <method name="set_frame_and_progress">
+ <return type="void" />
+ <param index="0" name="frame" type="int" />
+ <param index="1" name="progress" type="float" />
<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.
+ The setter of [member frame] resets the [member frame_progress] to [code]0.0[/code] implicitly, but this method avoids that.
+ This is useful when you want to carry over the current [member frame_progress] to another [member frame].
+ [b]Example:[/b]
+ [codeblocks]
+ [gdscript]
+ # Change the animation with keeping the frame index and progress.
+ var current_frame = animated_sprite.get_frame()
+ var current_progress = animated_sprite.get_frame_progress()
+ animated_sprite.play("walk_another_skin")
+ animated_sprite.set_frame_and_progress(current_frame, current_progress)
+ [/gdscript]
+ [/codeblocks]
</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.
+ Stops the currently playing animation. The animation position is reset to [code]0[/code] and the [code]custom_speed[/code] is reset to [code]1.0[/code]. See also [method pause].
</description>
</method>
</methods>
<members>
<member name="animation" type="StringName" setter="set_animation" getter="get_animation" default="&amp;&quot;default&quot;">
- The current animation from the [member frames] resource. If this value changes, the [code]frame[/code] counter is reset.
+ The current animation from the [member sprite_frames] resource. If this value is changed, the [member frame] counter and the [member frame_progress] are reset.
+ </member>
+ <member name="autoplay" type="String" setter="set_autoplay" getter="get_autoplay" default="&quot;&quot;">
+ The key of the animation to play when the scene loads.
</member>
<member name="centered" type="bool" setter="set_centered" getter="is_centered" default="true">
If [code]true[/code], texture will be centered.
@@ -44,30 +92,46 @@
If [code]true[/code], texture is flipped vertically.
</member>
<member name="frame" type="int" setter="set_frame" getter="get_frame" default="0">
- The displayed animation frame's index.
+ The displayed animation frame's index. Setting this property also resets [member frame_progress]. If this is not desired, use [method set_frame_and_progress].
</member>
- <member name="frames" type="SpriteFrames" setter="set_sprite_frames" getter="get_sprite_frames">
- The [SpriteFrames] resource containing the animation(s). Allows you the option to load, edit, clear, make unique and save the states of the [SpriteFrames] resource.
+ <member name="frame_progress" type="float" setter="set_frame_progress" getter="get_frame_progress" default="0.0">
+ The progress value between [code]0.0[/code] and [code]1.0[/code] until the current frame transitions to the next frame. If the animation is playing backwards, the value transitions from [code]1.0[/code] to [code]0.0[/code].
</member>
<member name="offset" type="Vector2" setter="set_offset" getter="get_offset" default="Vector2(0, 0)">
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].
- </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.
+ The speed scaling ratio. For example, if this value is [code]1[/code], then the animation plays at normal speed. If it's [code]0.5[/code], then it plays at half speed. If it's [code]2[/code], then it plays at double speed.
+ If set to a negative value, the animation is played in reverse. If set to [code]0[/code], the animation will not advance.
+ </member>
+ <member name="sprite_frames" type="SpriteFrames" setter="set_sprite_frames" getter="get_sprite_frames">
+ The [SpriteFrames] resource containing the animation(s). Allows you the option to load, edit, clear, make unique and save the states of the [SpriteFrames] resource.
</member>
</members>
<signals>
+ <signal name="animation_changed">
+ <description>
+ Emitted when [member animation] changes.
+ </description>
+ </signal>
<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. When the animation finishes, it pauses the playback.
+ </description>
+ </signal>
+ <signal name="animation_looped">
+ <description>
+ Emitted when the animation loops.
</description>
</signal>
<signal name="frame_changed">
<description>
- Emitted when [member frame] changed.
+ Emitted when [member frame] changes.
+ </description>
+ </signal>
+ <signal name="sprite_frames_changed">
+ <description>
+ Emitted when [member sprite_frames] changes.
</description>
</signal>
</signals>
diff --git a/doc/classes/AnimatedSprite3D.xml b/doc/classes/AnimatedSprite3D.xml
index 09baf882fb..c39bb99827 100644
--- a/doc/classes/AnimatedSprite3D.xml
+++ b/doc/classes/AnimatedSprite3D.xml
@@ -4,56 +4,121 @@
2D sprite node in 3D world, that can use multiple 2D textures for animation.
</brief_description>
<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.
+ [AnimatedSprite3D] is similar to the [Sprite3D] node, except it carries multiple textures as animation [member sprite_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.
</description>
<tutorials>
<link title="2D Sprite animation (also applies to 3D)">$DOCS_URL/tutorials/2d/2d_sprite_animation.html</link>
</tutorials>
<methods>
+ <method name="get_playing_speed" qualifiers="const">
+ <return type="float" />
+ <description>
+ Returns the actual playing speed of current animation or [code]0[/code] if not playing. This speed is the [member speed_scale] property multiplied by [code]custom_speed[/code] argument specified when calling the [method play] method.
+ Returns a negative value if the current animation is playing backwards.
+ </description>
+ </method>
+ <method name="is_playing" qualifiers="const">
+ <return type="bool" />
+ <description>
+ Returns [code]true[/code] if an animation is currently playing (even if [member speed_scale] and/or [code]custom_speed[/code] are [code]0[/code]).
+ </description>
+ </method>
+ <method name="pause">
+ <return type="void" />
+ <description>
+ Pauses the currently playing animation. The [member frame] and [member frame_progress] will be kept and calling [method play] or [method play_backwards] without arguments will resume the animation from the current playback position.
+ See also [method stop].
+ </description>
+ </method>
<method name="play">
<return type="void" />
- <param index="0" name="anim" type="StringName" default="&amp;&quot;&quot;" />
- <param index="1" name="backwards" type="bool" default="false" />
+ <param index="0" name="name" type="StringName" default="&amp;&quot;&quot;" />
+ <param index="1" name="custom_speed" type="float" default="1.0" />
+ <param index="2" name="from_end" type="bool" default="false" />
+ <description>
+ Plays the animation with key [param name]. If [param custom_speed] is negative and [param from_end] is [code]true[/code], the animation will play backwards (which is equivalent to calling [method play_backwards]).
+ If this method is called with that same animation [param name], or with no [param name] parameter, the assigned animation will resume playing if it was paused.
+ </description>
+ </method>
+ <method name="play_backwards">
+ <return type="void" />
+ <param index="0" name="name" type="StringName" default="&amp;&quot;&quot;" />
+ <description>
+ Plays the animation with key [param name] in reverse.
+ This method is a shorthand for [method play] with [code]custom_speed = -1.0[/code] and [code]from_end = true[/code], so see its description for more information.
+ </description>
+ </method>
+ <method name="set_frame_and_progress">
+ <return type="void" />
+ <param index="0" name="frame" type="int" />
+ <param index="1" name="progress" type="float" />
<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.
+ The setter of [member frame] resets the [member frame_progress] to [code]0.0[/code] implicitly, but this method avoids that.
+ This is useful when you want to carry over the current [member frame_progress] to another [member frame].
+ [b]Example:[/b]
+ [codeblocks]
+ [gdscript]
+ # Change the animation with keeping the frame index and progress.
+ var current_frame = animated_sprite.get_frame()
+ var current_progress = animated_sprite.get_frame_progress()
+ animated_sprite.play("walk_another_skin")
+ animated_sprite.set_frame_and_progress(current_frame, current_progress)
+ [/gdscript]
+ [/codeblocks]
</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.
+ Stops the currently playing animation. The animation position is reset to [code]0[/code] and the [code]custom_speed[/code] is reset to [code]1.0[/code]. See also [method pause].
</description>
</method>
</methods>
<members>
<member name="animation" type="StringName" setter="set_animation" getter="get_animation" default="&amp;&quot;default&quot;">
- The current animation from the [code]frames[/code] resource. If this value changes, the [code]frame[/code] counter is reset.
+ The current animation from the [member sprite_frames] resource. If this value is changed, the [member frame] counter and the [member frame_progress] are reset.
</member>
- <member name="frame" type="int" setter="set_frame" getter="get_frame" default="0">
- The displayed animation frame's index.
+ <member name="autoplay" type="String" setter="set_autoplay" getter="get_autoplay" default="&quot;&quot;">
+ The key of the animation to play when the scene loads.
</member>
- <member name="frames" type="SpriteFrames" setter="set_sprite_frames" getter="get_sprite_frames">
- The [SpriteFrames] resource containing the animation(s).
+ <member name="frame" type="int" setter="set_frame" getter="get_frame" default="0">
+ The displayed animation frame's index. Setting this property also resets [member frame_progress]. If this is not desired, use [method set_frame_and_progress].
</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].
+ <member name="frame_progress" type="float" setter="set_frame_progress" getter="get_frame_progress" default="0.0">
+ The progress value between [code]0.0[/code] and [code]1.0[/code] until the current frame transitions to the next frame. If the animation is playing backwards, the value transitions from [code]1.0[/code] to [code]0.0[/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.
+ The speed scaling ratio. For example, if this value is [code]1[/code], then the animation plays at normal speed. If it's [code]0.5[/code], then it plays at half speed. If it's [code]2[/code], then it plays at double speed.
+ If set to a negative value, the animation is played in reverse. If set to [code]0[/code], the animation will not advance.
+ </member>
+ <member name="sprite_frames" type="SpriteFrames" setter="set_sprite_frames" getter="get_sprite_frames">
+ The [SpriteFrames] resource containing the animation(s). Allows you the option to load, edit, clear, make unique and save the states of the [SpriteFrames] resource.
</member>
</members>
<signals>
+ <signal name="animation_changed">
+ <description>
+ Emitted when [member animation] changes.
+ </description>
+ </signal>
<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. When the animation finishes, it pauses the playback.
+ </description>
+ </signal>
+ <signal name="animation_looped">
+ <description>
+ Emitted when the animation loops.
</description>
</signal>
<signal name="frame_changed">
<description>
- Emitted when [member frame] changed.
+ Emitted when [member frame] changes.
+ </description>
+ </signal>
+ <signal name="sprite_frames_changed">
+ <description>
+ Emitted when [member sprite_frames] changes.
</description>
</signal>
</signals>
diff --git a/doc/classes/Animation.xml b/doc/classes/Animation.xml
index d9a1f896f1..74ee13a3d2 100644
--- a/doc/classes/Animation.xml
+++ b/doc/classes/Animation.xml
@@ -104,6 +104,13 @@
[param stream] is the [AudioStream] resource to play. [param start_offset] is the number of seconds cut off at the beginning of the audio stream, while [param end_offset] is at the ending.
</description>
</method>
+ <method name="audio_track_is_use_blend" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="track_idx" type="int" />
+ <description>
+ Returns [code]true[/code] if the track at [code]idx[/code] will be blended with other animations.
+ </description>
+ </method>
<method name="audio_track_set_key_end_offset">
<return type="void" />
<param index="0" name="track_idx" type="int" />
@@ -131,6 +138,14 @@
Sets the stream of the key identified by [param key_idx] to value [param stream]. The [param track_idx] must be the index of an Audio Track.
</description>
</method>
+ <method name="audio_track_set_use_blend">
+ <return type="void" />
+ <param index="0" name="track_idx" type="int" />
+ <param index="1" name="enable" type="bool" />
+ <description>
+ Sets whether the track will be blended with other animations. If [code]true[/code], the audio playback volume changes depending on the blend value.
+ </description>
+ </method>
<method name="bezier_track_get_key_in_handle" qualifiers="const">
<return type="Vector2" />
<param index="0" name="track_idx" type="int" />
@@ -305,9 +320,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 +637,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..bc65e6013b 100644
--- a/doc/classes/AnimationNode.xml
+++ b/doc/classes/AnimationNode.xml
@@ -49,6 +49,13 @@
When inheriting from [AnimationRootNode], implement this virtual method to return whether the blend tree editor should display filter editing on this node.
</description>
</method>
+ <method name="_is_parameter_read_only" qualifiers="virtual const">
+ <return type="bool" />
+ <param index="0" name="parameter" type="StringName" />
+ <description>
+ When inheriting from [AnimationRootNode], implement this virtual method to return whether the [param parameter] is read-only. Parameters are custom local memory used for your nodes, given a resource can be reused in multiple trees.
+ </description>
+ </method>
<method name="_process" qualifiers="virtual const">
<return type="float" />
<param index="0" name="time" type="float" />
@@ -61,10 +68,10 @@
</description>
</method>
<method name="add_input">
- <return type="void" />
+ <return type="bool" />
<param index="0" name="name" type="String" />
<description>
- Adds an input to the node. This is only useful for nodes created for use in an [AnimationNodeBlendTree].
+ Adds an input to the node. This is only useful for nodes created for use in an [AnimationNodeBlendTree]. If the addition fails, returns [code]false[/code].
</description>
</method>
<method name="blend_animation">
@@ -108,13 +115,20 @@
Blend another animation node (in case this node contains children animation nodes). This function is only useful if you inherit from [AnimationRootNode] instead, else editors will not display your node for addition.
</description>
</method>
+ <method name="find_input" qualifiers="const">
+ <return type="int" />
+ <param index="0" name="name" type="String" />
+ <description>
+ Returns the input index which corresponds to [param name]. If not found, returns [code]-1[/code].
+ </description>
+ </method>
<method name="get_input_count" qualifiers="const">
<return type="int" />
<description>
Amount of inputs in this node, only useful for nodes that go into [AnimationNodeBlendTree].
</description>
</method>
- <method name="get_input_name">
+ <method name="get_input_name" qualifiers="const">
<return type="String" />
<param index="0" name="input" type="int" />
<description>
@@ -150,6 +164,14 @@
Adds or removes a path for the filter.
</description>
</method>
+ <method name="set_input_name">
+ <return type="bool" />
+ <param index="0" name="input" type="int" />
+ <param index="1" name="name" type="String" />
+ <description>
+ Sets the name of the input at the given [param input] index. If the setting fails, returns [code]false[/code].
+ </description>
+ </method>
<method name="set_parameter">
<return type="void" />
<param index="0" name="name" type="StringName" />
@@ -165,11 +187,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/AnimationNodeBlendSpace1D.xml b/doc/classes/AnimationNodeBlendSpace1D.xml
index 0f1ce127cd..9a7872f50e 100644
--- a/doc/classes/AnimationNodeBlendSpace1D.xml
+++ b/doc/classes/AnimationNodeBlendSpace1D.xml
@@ -67,6 +67,9 @@
</method>
</methods>
<members>
+ <member name="blend_mode" type="int" setter="set_blend_mode" getter="get_blend_mode" enum="AnimationNodeBlendSpace1D.BlendMode" default="0">
+ Controls the interpolation between animations. See [enum BlendMode] constants.
+ </member>
<member name="max_space" type="float" setter="set_max_space" getter="get_max_space" default="1.0">
The blend space's axis's upper limit for the points' position. See [method add_blend_point].
</member>
@@ -84,4 +87,15 @@
Label of the virtual axis of the blend space.
</member>
</members>
+ <constants>
+ <constant name="BLEND_MODE_INTERPOLATED" value="0" enum="BlendMode">
+ The interpolation between animations is linear.
+ </constant>
+ <constant name="BLEND_MODE_DISCRETE" value="1" enum="BlendMode">
+ The blend space plays the animation of the node the blending position is closest to. Useful for frame-by-frame 2D animations.
+ </constant>
+ <constant name="BLEND_MODE_DISCRETE_CARRY" value="2" enum="BlendMode">
+ Similar to [constant BLEND_MODE_DISCRETE], but starts the new animation at the last animation's playback position.
+ </constant>
+ </constants>
</class>
diff --git a/doc/classes/AnimationNodeOneShot.xml b/doc/classes/AnimationNodeOneShot.xml
index 14abc34992..9e8193868c 100644
--- a/doc/classes/AnimationNodeOneShot.xml
+++ b/doc/classes/AnimationNodeOneShot.xml
@@ -28,6 +28,12 @@
</member>
</members>
<constants>
+ <constant name="ONE_SHOT_REQUEST_NONE" value="0" enum="OneShotRequest">
+ </constant>
+ <constant name="ONE_SHOT_REQUEST_FIRE" value="1" enum="OneShotRequest">
+ </constant>
+ <constant name="ONE_SHOT_REQUEST_ABORT" value="2" enum="OneShotRequest">
+ </constant>
<constant name="MIX_MODE_BLEND" value="0" enum="MixMode">
</constant>
<constant name="MIX_MODE_ADD" value="1" enum="MixMode">
diff --git a/doc/classes/AnimationNodeStateMachine.xml b/doc/classes/AnimationNodeStateMachine.xml
index 0fb789875f..95891a9061 100644
--- a/doc/classes/AnimationNodeStateMachine.xml
+++ b/doc/classes/AnimationNodeStateMachine.xml
@@ -161,4 +161,9 @@
</description>
</method>
</methods>
+ <members>
+ <member name="allow_transition_to_self" type="bool" setter="set_allow_transition_to_self" getter="is_allow_transition_to_self" default="false">
+ If [code]true[/code], allows teleport to the self state with [method AnimationNodeStateMachinePlayback.travel]. When the reset option is enabled in [method AnimationNodeStateMachinePlayback.travel], the animation is restarted. If [code]false[/code], nothing happens on the teleportation to the self state.
+ </member>
+ </members>
</class>
diff --git a/doc/classes/AnimationNodeStateMachinePlayback.xml b/doc/classes/AnimationNodeStateMachinePlayback.xml
index 8f53ef0dcf..17a946bb3e 100644
--- a/doc/classes/AnimationNodeStateMachinePlayback.xml
+++ b/doc/classes/AnimationNodeStateMachinePlayback.xml
@@ -38,6 +38,12 @@
Returns the playback position within the current animation state.
</description>
</method>
+ <method name="get_fading_from_node" qualifiers="const">
+ <return type="StringName" />
+ <description>
+ Returns the starting state of currently fading animation.
+ </description>
+ </method>
<method name="get_travel_path" qualifiers="const">
<return type="PackedStringArray" />
<description>
@@ -50,11 +56,19 @@
Returns [code]true[/code] if an animation is playing.
</description>
</method>
+ <method name="next">
+ <return type="void" />
+ <description>
+ If there is a next path by travel or auto advance, immediately transitions from the current state to the next state.
+ </description>
+ </method>
<method name="start">
<return type="void" />
<param index="0" name="node" type="StringName" />
+ <param index="1" name="reset" type="bool" default="true" />
<description>
Starts playing the given animation.
+ If [param reset] is [code]true[/code], the animation is played from the beginning.
</description>
</method>
<method name="stop">
@@ -66,8 +80,11 @@
<method name="travel">
<return type="void" />
<param index="0" name="to_node" type="StringName" />
+ <param index="1" name="reset_on_teleport" type="bool" default="true" />
<description>
Transitions from the current state to another one, following the shortest path.
+ If the path does not connect from the current state, the animation will play after the state teleports.
+ If [param reset_on_teleport] is [code]true[/code], the animation is played from the beginning when the travel cause a teleportation.
</description>
</method>
</methods>
diff --git a/doc/classes/AnimationNodeStateMachineTransition.xml b/doc/classes/AnimationNodeStateMachineTransition.xml
index 4c2a30030b..bccab4613a 100644
--- a/doc/classes/AnimationNodeStateMachineTransition.xml
+++ b/doc/classes/AnimationNodeStateMachineTransition.xml
@@ -15,21 +15,21 @@
$animation_tree.set("parameters/conditions/idle", is_on_floor and (linear_velocity.x == 0))
[/gdscript]
[csharp]
- GetNode&lt;AnimationTree&gt;("animation_tree").Set("parameters/conditions/idle", IsOnFloor &amp;&amp; (LinearVelocity.x == 0));
+ GetNode&lt;AnimationTree&gt;("animation_tree").Set("parameters/conditions/idle", IsOnFloor &amp;&amp; (LinearVelocity.X == 0));
[/csharp]
[/codeblocks]
</member>
<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="reset" type="bool" setter="set_reset" getter="is_reset" default="true">
+ If [code]true[/code], the destination animation is played back from the beginning when switched.
</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 +58,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/AnimationNodeTransition.xml b/doc/classes/AnimationNodeTransition.xml
index f6e2fc5eb2..bc3e5716dd 100644
--- a/doc/classes/AnimationNodeTransition.xml
+++ b/doc/classes/AnimationNodeTransition.xml
@@ -12,16 +12,18 @@
<link title="Third Person Shooter Demo">https://godotengine.org/asset-library/asset/678</link>
</tutorials>
<methods>
- <method name="get_input_caption" qualifiers="const">
- <return type="String" />
+ <method name="is_input_reset" qualifiers="const">
+ <return type="bool" />
<param index="0" name="input" type="int" />
<description>
+ Returns whether the animation restarts when the animation transitions from the other animation.
</description>
</method>
<method name="is_input_set_as_auto_advance" qualifiers="const">
<return type="bool" />
<param index="0" name="input" type="int" />
<description>
+ Returns [code]true[/code] if auto-advance is enabled for the given [param input] index.
</description>
</method>
<method name="set_input_as_auto_advance">
@@ -29,24 +31,27 @@
<param index="0" name="input" type="int" />
<param index="1" name="enable" type="bool" />
<description>
+ Enables or disables auto-advance for the given [param input] index. If enabled, state changes to the next input after playing the animation once. If enabled for the last input state, it loops to the first.
</description>
</method>
- <method name="set_input_caption">
+ <method name="set_input_reset">
<return type="void" />
<param index="0" name="input" type="int" />
- <param index="1" name="caption" type="String" />
+ <param index="1" name="enable" type="bool" />
<description>
+ If [code]true[/code], the destination animation is restarted when the animation transitions.
</description>
</method>
</methods>
<members>
- <member name="enabled_inputs" type="int" setter="set_enabled_inputs" getter="get_enabled_inputs" default="0">
- The number of enabled input ports for this node.
+ <member name="allow_transition_to_self" type="bool" setter="set_allow_transition_to_self" getter="is_allow_transition_to_self" default="false">
+ If [code]true[/code], allows transition to the self state. When the reset option is enabled in input, the animation is restarted. If [code]false[/code], nothing happens on the transition to the self state.
</member>
- <member name="from_start" type="bool" setter="set_from_start" getter="is_from_start" default="true">
- If [code]true[/code], the destination animation is played back from the beginning when switched.
+ <member name="input_count" type="int" setter="set_input_count" getter="get_input_count" default="0">
+ The number of enabled input ports for this node.
</member>
<member name="xfade_curve" type="Curve" setter="set_xfade_curve" getter="get_xfade_curve">
+ Determines how cross-fading between animations is eased. If empty, the transition will be linear.
</member>
<member name="xfade_time" type="float" setter="set_xfade_time" getter="get_xfade_time" default="0.0">
Cross-fading time (in seconds) between each animation connected to the inputs.
diff --git a/doc/classes/AnimationPlayer.xml b/doc/classes/AnimationPlayer.xml
index 9efd3ac939..25e4a4549d 100644
--- a/doc/classes/AnimationPlayer.xml
+++ b/doc/classes/AnimationPlayer.xml
@@ -15,6 +15,17 @@
<link title="Third Person Shooter Demo">https://godotengine.org/asset-library/asset/678</link>
</tutorials>
<methods>
+ <method name="_post_process_key_value" qualifiers="virtual const">
+ <return type="Variant" />
+ <param index="0" name="animation" type="Animation" />
+ <param index="1" name="track" type="int" />
+ <param index="2" name="value" type="Variant" />
+ <param index="3" name="object" type="Object" />
+ <param index="4" name="object_idx" type="int" />
+ <description>
+ A virtual function for processing after key getting during playback.
+ </description>
+ </method>
<method name="add_animation_library">
<return type="int" enum="Error" />
<param index="0" name="name" type="StringName" />
@@ -102,13 +113,14 @@
<param index="0" name="anim_from" type="StringName" />
<param index="1" name="anim_to" type="StringName" />
<description>
- Gets the blend time (in seconds) between two animations, referenced by their keys.
+ Returns the blend time (in seconds) between two animations, referenced by their keys.
</description>
</method>
<method name="get_playing_speed" qualifiers="const">
<return type="float" />
<description>
- Gets the actual playing speed of current animation or 0 if not playing. This speed is the [member playback_speed] property multiplied by [code]custom_speed[/code] argument specified when calling the [method play] method.
+ Returns the actual playing speed of current animation or [code]0[/code] if not playing. This speed is the [member speed_scale] property multiplied by [code]custom_speed[/code] argument specified when calling the [method play] method.
+ Returns a negative value if the current animation is playing backwards.
</description>
</method>
<method name="get_queue">
@@ -134,7 +146,14 @@
<method name="is_playing" qualifiers="const">
<return type="bool" />
<description>
- Returns [code]true[/code] if playing an animation.
+ Returns [code]true[/code] if an animation is currently playing (even if [member speed_scale] and/or [code]custom_speed[/code] are [code]0[/code]).
+ </description>
+ </method>
+ <method name="pause">
+ <return type="void" />
+ <description>
+ Pauses the currently playing animation. The [member current_animation_position] will be kept and calling [method play] or [method play_backwards] without arguments or with the same animation name as [member assigned_animation] will resume the animation.
+ See also [method stop].
</description>
</method>
<method name="play">
@@ -145,7 +164,7 @@
<param index="3" name="from_end" type="bool" default="false" />
<description>
Plays the animation with key [param name]. Custom blend times and speed can be set. If [param custom_speed] is negative and [param from_end] is [code]true[/code], the animation will play backwards (which is equivalent to calling [method play_backwards]).
- The [AnimationPlayer] keeps track of its current or last played animation with [member assigned_animation]. If this method is called with that same animation [param name], or with no [param name] parameter, the assigned animation will resume playing if it was paused, or restart if it was stopped (see [method stop] for both pause and stop). If the animation was already playing, it will keep playing.
+ The [AnimationPlayer] keeps track of its current or last played animation with [member assigned_animation]. If this method is called with that same animation [param name], or with no [param name] parameter, the assigned animation will resume playing if it was paused.
[b]Note:[/b] The animation will be updated the next time the [AnimationPlayer] is processed. If other variables are updated at the same time this is called, they may be updated too early. To perform the update immediately, call [code]advance(0)[/code].
</description>
</method>
@@ -201,10 +220,11 @@
</method>
<method name="stop">
<return type="void" />
- <param index="0" name="reset" type="bool" default="true" />
+ <param index="0" name="keep_state" type="bool" default="false" />
<description>
- Stops or pauses the currently playing animation. If [param reset] is [code]true[/code], the animation position is reset to [code]0[/code] and the playback speed is reset to [code]1.0[/code].
- If [param reset] is [code]false[/code], the [member current_animation_position] will be kept and calling [method play] or [method play_backwards] without arguments or with the same animation name as [member assigned_animation] will resume the animation.
+ Stops the currently playing animation. The animation position is reset to [code]0[/code] and the [code]custom_speed[/code] is reset to [code]1.0[/code]. See also [method pause].
+ If [param keep_state] is [code]true[/code], the animation state is not updated visually.
+ [b]Note:[/b] The method / audio / animation playback tracks will not be processed by this method.
</description>
</method>
</methods>
@@ -212,6 +232,10 @@
<member name="assigned_animation" type="String" setter="set_assigned_animation" getter="get_assigned_animation">
If playing, the the current animation's key, otherwise, the animation last played. When set, this changes the animation, but will not play it unless already playing. See also [member current_animation].
</member>
+ <member name="audio_max_polyphony" type="int" setter="set_audio_max_polyphony" getter="get_audio_max_polyphony" default="32">
+ The number of possible simultaneous sounds for each of the assigned AudioStreamPlayers.
+ For example, if this value is [code]32[/code] and the animation has two audio tracks, the two [AudioStreamPlayer]s assigned can play simultaneously up to [code]32[/code] voices each.
+ </member>
<member name="autoplay" type="String" setter="set_autoplay" getter="get_autoplay" default="&quot;&quot;">
The key of the animation to play when the scene loads.
</member>
@@ -241,9 +265,6 @@
<member name="playback_process_mode" type="int" setter="set_process_callback" getter="get_process_callback" enum="AnimationPlayer.AnimationProcessCallback" default="1">
The process notification in which to update animations.
</member>
- <member name="playback_speed" type="float" setter="set_speed_scale" getter="get_speed_scale" default="1.0">
- The speed scaling ratio. For example, if this value is 1, then the animation plays at normal speed. If it's 0.5, then it plays at half speed. If it's 2, then it plays at double speed.
- </member>
<member name="reset_on_save" type="bool" setter="set_reset_on_save_enabled" getter="is_reset_on_save_enabled" default="true">
This is used by the editor. If set to [code]true[/code], the scene will be saved with the effects of the reset animation (the animation with the key [code]"RESET"[/code]) applied as if it had been seeked to time 0, with the editor keeping the values that the scene had before saving.
This makes it more convenient to preview and edit animations in the editor, as changes to the scene will not be saved as long as they are set in the reset animation.
@@ -251,6 +272,10 @@
<member name="root_node" type="NodePath" setter="set_root" getter="get_root" default="NodePath(&quot;..&quot;)">
The node from which node path references will travel.
</member>
+ <member name="speed_scale" type="float" setter="set_speed_scale" getter="get_speed_scale" default="1.0">
+ The speed scaling ratio. For example, if this value is [code]1[/code], then the animation plays at normal speed. If it's [code]0.5[/code], then it plays at half speed. If it's [code]2[/code], then it plays at double speed.
+ If set to a negative value, the animation is played in reverse. If set to [code]0[/code], the animation will not advance.
+ </member>
</members>
<signals>
<signal name="animation_changed">
diff --git a/doc/classes/AnimationTree.xml b/doc/classes/AnimationTree.xml
index 21f4b37741..86562c340d 100644
--- a/doc/classes/AnimationTree.xml
+++ b/doc/classes/AnimationTree.xml
@@ -12,6 +12,17 @@
<link title="Third Person Shooter Demo">https://godotengine.org/asset-library/asset/678</link>
</tutorials>
<methods>
+ <method name="_post_process_key_value" qualifiers="virtual const">
+ <return type="Variant" />
+ <param index="0" name="animation" type="Animation" />
+ <param index="1" name="track" type="int" />
+ <param index="2" name="value" type="Variant" />
+ <param index="3" name="object" type="Object" />
+ <param index="4" name="object_idx" type="int" />
+ <description>
+ A virtual function for processing after key getting during playback.
+ </description>
+ </method>
<method name="advance">
<return type="void" />
<param index="0" name="delta" type="float" />
@@ -99,23 +110,41 @@
<member name="anim_player" type="NodePath" setter="set_animation_player" getter="get_animation_player" default="NodePath(&quot;&quot;)">
The path to the [AnimationPlayer] used for animating.
</member>
+ <member name="audio_max_polyphony" type="int" setter="set_audio_max_polyphony" getter="get_audio_max_polyphony" default="32">
+ The number of possible simultaneous sounds for each of the assigned AudioStreamPlayers.
+ For example, if this value is [code]32[/code] and the animation has two audio tracks, the two [AudioStreamPlayer]s assigned can play simultaneously up to [code]32[/code] voices each.
+ </member>
<member name="process_callback" type="int" setter="set_process_callback" getter="get_process_callback" enum="AnimationTree.AnimationProcessCallback" default="1">
The process mode of this [AnimationTree]. See [enum AnimationProcessCallback] for available modes.
</member>
<member name="root_motion_track" type="NodePath" setter="set_root_motion_track" getter="get_root_motion_track" default="NodePath(&quot;&quot;)">
The path to the Animation track used for root motion. Paths must be valid scene-tree paths to a node, and must be specified starting from the parent node of the node that will reproduce the animation. To specify a track that controls properties or bones, append its name after the path, separated by [code]":"[/code]. For example, [code]"character/skeleton:ankle"[/code] or [code]"character/mesh:transform/local"[/code].
- If the track has type [constant Animation.TYPE_POSITION_3D], [constant Animation.TYPE_ROTATION_3D] or [constant Animation.TYPE_SCALE_3D] the transformation will be cancelled visually, and the animation will appear to stay in place. See also [method get_root_motion_position], [method get_root_motion_rotation], [method get_root_motion_scale] and [RootMotionView].
+ If the track has type [constant Animation.TYPE_POSITION_3D], [constant Animation.TYPE_ROTATION_3D] or [constant Animation.TYPE_SCALE_3D] the transformation will be canceled visually, and the animation will appear to stay in place. See also [method get_root_motion_position], [method get_root_motion_rotation], [method get_root_motion_scale] and [RootMotionView].
</member>
<member name="tree_root" type="AnimationNode" setter="set_tree_root" getter="get_tree_root">
The root animation node of this [AnimationTree]. See [AnimationNode].
</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..8a98921a60 100644
--- a/doc/classes/Area2D.xml
+++ b/doc/classes/Area2D.xml
@@ -87,8 +87,9 @@
<member name="gravity_point_center" type="Vector2" setter="set_gravity_point_center" getter="get_gravity_point_center" default="Vector2(0, 1)">
If gravity is a point (see [member gravity_point]), this will be the point of attraction.
</member>
- <member name="gravity_point_distance_scale" type="float" setter="set_gravity_point_distance_scale" getter="get_gravity_point_distance_scale" default="0.0">
- The falloff factor for point gravity. The greater the value, the faster gravity decreases with distance.
+ <member name="gravity_point_unit_distance" type="float" setter="set_gravity_point_unit_distance" getter="get_gravity_point_unit_distance" default="0.0">
+ The distance at which the gravity strength is equal to [member gravity]. For example, on a planet 100 pixels in radius with a surface gravity of 4.0 px/s², set the [member gravity] to 4.0 and the unit distance to 100.0. The gravity will have falloff according to the inverse square law, so in the example, at 200 pixels from the center the gravity will be 1.0 px/s² (twice the distance, 1/4th the gravity), at 50 pixels it will be 16.0 px/s² (half the distance, 4x the gravity), and so on.
+ The above is true only when the unit distance is a positive number. When this is set to 0.0, the gravity will be constant regardless of distance.
</member>
<member name="gravity_space_override" type="int" setter="set_gravity_space_override_mode" getter="get_gravity_space_override_mode" enum="Area2D.SpaceOverride" default="0">
Override mode for gravity calculations within this area. See [enum SpaceOverride] for possible values.
@@ -114,15 +115,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 +130,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 +150,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 +172,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 +192,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..bd046b7cb8 100644
--- a/doc/classes/Area3D.xml
+++ b/doc/classes/Area3D.xml
@@ -7,6 +7,7 @@
3D area that detects [CollisionObject3D] nodes overlapping, entering, or exiting. Can also alter or override local physics parameters (gravity, damping) and route audio to custom audio buses.
To give the area its shape, add a [CollisionShape3D] or a [CollisionPolygon3D] node as a [i]direct[/i] child (or add multiple such nodes as direct children) of the area.
[b]Warning:[/b] See [ConcavePolygonShape3D] (also called "trimesh") for a warning about possibly unexpected behavior when using that shape for an area.
+ [b]Warning:[/b] With a non-uniform scale this node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change the size(s) of its collision shape(s) instead.
</description>
<tutorials>
<link title="3D Platformer Demo">https://godotengine.org/asset-library/asset/125</link>
@@ -85,8 +86,9 @@
<member name="gravity_point_center" type="Vector3" setter="set_gravity_point_center" getter="get_gravity_point_center" default="Vector3(0, -1, 0)">
If gravity is a point (see [member gravity_point]), this will be the point of attraction.
</member>
- <member name="gravity_point_distance_scale" type="float" setter="set_gravity_point_distance_scale" getter="get_gravity_point_distance_scale" default="0.0">
- The falloff factor for point gravity. The greater the value, the faster gravity decreases with distance.
+ <member name="gravity_point_unit_distance" type="float" setter="set_gravity_point_unit_distance" getter="get_gravity_point_unit_distance" default="0.0">
+ The distance at which the gravity strength is equal to [member gravity]. For example, on a planet 100 meters in radius with a surface gravity of 4.0 m/s², set the [member gravity] to 4.0 and the unit distance to 100.0. The gravity will have falloff according to the inverse square law, so in the example, at 200 meters from the center the gravity will be 1.0 m/s² (twice the distance, 1/4th the gravity), at 50 meters it will be 16.0 m/s² (half the distance, 4x the gravity), and so on.
+ The above is true only when the unit distance is a positive number. When this is set to 0.0, the gravity will be constant regardless of distance.
</member>
<member name="gravity_space_override" type="int" setter="set_gravity_space_override_mode" getter="get_gravity_space_override_mode" enum="Area3D.SpaceOverride" default="0">
Override mode for gravity calculations within this area. See [enum SpaceOverride] for possible values.
@@ -133,15 +135,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 +150,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 +170,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 +192,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 +212,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/Array.xml b/doc/classes/Array.xml
index 603974d619..213a2254af 100644
--- a/doc/classes/Array.xml
+++ b/doc/classes/Array.xml
@@ -40,6 +40,7 @@
[/codeblocks]
[b]Note:[/b] Concatenating with the [code]+=[/code] operator will create a new array, which has a cost. If you want to append another array to an existing array, [method append_array] is more efficient.
[b]Note:[/b] Arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use [method duplicate].
+ [b]Note:[/b] Erasing elements while iterating over arrays is [b]not[/b] supported and will result in unpredictable behavior.
[b]Note:[/b] When declaring an array with [code]const[/code], the array itself can still be mutated by defining the values at individual indices or pushing/removing elements. Using [code]const[/code] will only prevent assigning the constant with another value after it was initialized.
</description>
<tutorials>
@@ -58,14 +59,14 @@
<param index="2" name="class_name" type="StringName" />
<param index="3" name="script" type="Variant" />
<description>
- Creates a typed array from the [param base] array. The base array can't be already typed. See [method set_typed] for more details.
+ Creates a typed array from the [param base] array.
</description>
</constructor>
<constructor name="Array">
<return type="Array" />
<param index="0" name="from" type="Array" />
<description>
- Constructs an [Array] as a copy of the given [Array].
+ Returns the same array as [param from]. If you need a copy of the array, use [method duplicate].
</description>
</constructor>
<constructor name="Array">
@@ -199,6 +200,13 @@
[/codeblock]
</description>
</method>
+ <method name="assign">
+ <return type="void" />
+ <param index="0" name="array" type="Array" />
+ <description>
+ Assigns elements of another [param array] into the array. Resizes the array to match [param array]. Performs type conversions if the array is typed.
+ </description>
+ </method>
<method name="back" qualifiers="const">
<return type="Variant" />
<description>
@@ -243,7 +251,7 @@
<param index="0" name="deep" type="bool" default="false" />
<description>
Returns a copy of the array.
- If [param deep] is [code]true[/code], a deep copy is performed: all nested arrays and dictionaries are duplicated and will not be shared with the original array. If [code]false[/code], a shallow copy is made and references to the original nested arrays and dictionaries are kept, so that modifying a sub-array or dictionary in the copy will also impact those referenced in the source array.
+ If [param deep] is [code]true[/code], a deep copy is performed: all nested arrays and dictionaries are duplicated and will not be shared with the original array. If [code]false[/code], a shallow copy is made and references to the original nested arrays and dictionaries are kept, so that modifying a sub-array or dictionary in the copy will also impact those referenced in the source array. Note that any [Object]-derived elements will be shallow copied regardless of the [param deep] setting.
</description>
</method>
<method name="erase">
@@ -253,6 +261,7 @@
Removes the first occurrence of a value from the array. If the value does not exist in the array, nothing happens. To remove an element by index, use [method remove_at] instead.
[b]Note:[/b] This method acts in-place and doesn't return a value.
[b]Note:[/b] On large arrays, this method will be slower if the removed element is close to the beginning of the array (index 0). This is because all elements placed after the removed element have to be reindexed.
+ [b]Note:[/b] Do not erase entries while iterating over the array.
</description>
</method>
<method name="fill">
@@ -390,7 +399,14 @@
<method name="is_read_only" qualifiers="const">
<return type="bool" />
<description>
- Returns [code]true[/code] if the array is read-only. See [method set_read_only]. Arrays are automatically read-only if declared with [code]const[/code] keyword.
+ Returns [code]true[/code] if the array is read-only. See [method make_read_only]. Arrays are automatically read-only if declared with [code]const[/code] keyword.
+ </description>
+ </method>
+ <method name="is_same_typed" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="array" type="Array" />
+ <description>
+ Returns [code]true[/code] if the array is typed the same as [param array].
</description>
</method>
<method name="is_typed" qualifiers="const">
@@ -399,6 +415,12 @@
Returns [code]true[/code] if the array is typed. Typed arrays can only store elements of their associated type and provide type safety for the [code][][/code] operator. Methods of typed array still return [Variant].
</description>
</method>
+ <method name="make_read_only">
+ <return type="void" />
+ <description>
+ Makes the array read-only, i.e. disabled modifying of the array's elements. Does not apply to nested content, e.g. content of nested arrays.
+ </description>
+ </method>
<method name="map" qualifiers="const">
<return type="Array" />
<param index="0" name="method" type="Callable" />
@@ -522,23 +544,6 @@
Searches the array in reverse order. Optionally, a start search index can be passed. If negative, the start index is considered relative to the end of the array.
</description>
</method>
- <method name="set_read_only">
- <return type="void" />
- <param index="0" name="enable" type="bool" />
- <description>
- Makes the [Array] read-only, i.e. disabled modifying of the array's elements. Does not apply to nested content, e.g. content of nested arrays.
- </description>
- </method>
- <method name="set_typed">
- <return type="void" />
- <param index="0" name="type" type="int" />
- <param index="1" name="class_name" type="StringName" />
- <param index="2" name="script" type="Variant" />
- <description>
- Makes the [Array] typed. The [param type] should be one of the [enum Variant.Type] constants. [param class_name] is optional and can only be provided for [constant TYPE_OBJECT]. [param script] can only be provided if [param class_name] is not empty.
- The method fails if an array is already typed.
- </description>
- </method>
<method name="shuffle">
<return type="void" />
<description>
@@ -618,13 +623,6 @@
[/codeblocks]
</description>
</method>
- <method name="typed_assign">
- <return type="bool" />
- <param index="0" name="array" type="Array" />
- <description>
- Assigns a different [Array] to this array reference. It the array is typed, the new array's type must be compatible and its elements will be automatically converted.
- </description>
- </method>
</methods>
<operators>
<operator name="operator !=">
@@ -677,7 +675,7 @@
</description>
</operator>
<operator name="operator []">
- <return type="void" />
+ <return type="Variant" />
<param index="0" name="index" type="int" />
<description>
Returns a reference to the element of type [Variant] at the specified location. Arrays start at index 0. [param index] can be a zero or positive value to start from the beginning, or a negative value to start from the end. Out-of-bounds array access causes a run-time error, which will result in an error being printed and the project execution pausing if run from the editor.
diff --git a/doc/classes/ArrayMesh.xml b/doc/classes/ArrayMesh.xml
index b9c8ab0f6c..6dc66194b8 100644
--- a/doc/classes/ArrayMesh.xml
+++ b/doc/classes/ArrayMesh.xml
@@ -65,11 +65,15 @@
<param index="1" name="arrays" type="Array" />
<param index="2" name="blend_shapes" type="Array[]" default="[]" />
<param index="3" name="lods" type="Dictionary" default="{}" />
- <param index="4" name="compress_flags" type="int" default="0" />
+ <param index="4" name="flags" type="int" enum="Mesh.ArrayFormat" default="0" />
<description>
- Creates a new surface.
- Surfaces are created to be rendered using a [param primitive], which may be any of the types defined in [enum Mesh.PrimitiveType]. (As a note, when using indices, it is recommended to only use points, lines, or triangles.) [method Mesh.get_surface_count] will become the [code]surf_idx[/code] for this new surface.
- The [param arrays] argument is an array of arrays. See [enum Mesh.ArrayType] for the values used in this array. For example, [code]arrays[0][/code] is the array of vertices. That first vertex sub-array is always required; the others are optional. Adding an index array puts this function into "index mode" where the vertex and other arrays become the sources of data and the index array defines the vertex order. All sub-arrays must have the same length as the vertex array (or be an exact multiple of the vertex array's length, when multiple elements of a sub-array correspond to a single vertex) or be empty, except for [constant Mesh.ARRAY_INDEX] if it is used.
+ Creates a new surface. [method Mesh.get_surface_count] will become the [code]surf_idx[/code] for this new surface.
+ Surfaces are created to be rendered using a [param primitive], which may be any of the values defined in [enum Mesh.PrimitiveType].
+ The [param arrays] argument is an array of arrays. Each of the [constant Mesh.ARRAY_MAX] elements contains an array with some of the mesh data for this surface as described by the corresponding member of [enum Mesh.ArrayType] or [code]null[/code] if it is not used by the surface. For example, [code]arrays[0][/code] is the array of vertices. That first vertex sub-array is always required; the others are optional. Adding an index array puts this surface into "index mode" where the vertex and other arrays become the sources of data and the index array defines the vertex order. All sub-arrays must have the same length as the vertex array (or be an exact multiple of the vertex array's length, when multiple elements of a sub-array correspond to a single vertex) or be empty, except for [constant Mesh.ARRAY_INDEX] if it is used.
+ The [param blend_shapes] argument is an array of vertex data for each blend shape. Each element is an array of the same structure as [param arrays], but [constant Mesh.ARRAY_VERTEX], [constant Mesh.ARRAY_NORMAL], and [constant Mesh.ARRAY_TANGENT] are set if and only if they are set in [param arrays] and all other entries are [code]null[/code].
+ The [param lods] argument is a dictionary with [float] keys and [PackedInt32Array] values. Each entry in the dictionary represents a LOD level of the surface, where the value is the [constant Mesh.ARRAY_INDEX] array to use for the LOD level and the key is roughly proportional to the distance at which the LOD stats being used. I.e., increasing the key of a LOD also increases the distance that the objects has to be from the camera before the LOD is used.
+ The [param flags] argument is the bitwise or of, as required: One value of [enum Mesh.ArrayCustomFormat] left shifted by [code]ARRAY_FORMAT_CUSTOMn_SHIFT[/code] for each custom channel in use, [constant Mesh.ARRAY_FLAG_USE_DYNAMIC_UPDATE], [constant Mesh.ARRAY_FLAG_USE_8_BONE_WEIGHTS], or [constant Mesh.ARRAY_FLAG_USES_EMPTY_VERTEX_ARRAY].
+ [b]Note:[/b] When using indices, it is recommended to only use points, lines, or triangles.
</description>
</method>
<method name="clear_blend_shapes">
@@ -102,13 +106,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">
@@ -141,7 +145,7 @@
</description>
</method>
<method name="surface_get_format" qualifiers="const">
- <return type="int" />
+ <return type="int" enum="Mesh.ArrayFormat" />
<param index="0" name="surf_idx" type="int" />
<description>
Returns the format mask of the requested surface (see [method add_surface_from_arrays]).
@@ -202,6 +206,7 @@
Overrides the [AABB] with one defined by user for use with frustum culling. Especially useful to avoid unexpected culling when using a shader to offset vertices.
</member>
<member name="shadow_mesh" type="ArrayMesh" setter="set_shadow_mesh" getter="get_shadow_mesh">
+ An optional mesh which is used for rendering shadows and can be used for the depth prepass. Can be used to increase performance of shadow rendering by using a mesh that only contains vertex position data (without normals, UVs, colors, etc.).
</member>
</members>
</class>
diff --git a/doc/classes/AudioServer.xml b/doc/classes/AudioServer.xml
index 36f12dd5c4..ae331f8491 100644
--- a/doc/classes/AudioServer.xml
+++ b/doc/classes/AudioServer.xml
@@ -29,13 +29,6 @@
Adds an [AudioEffect] effect to the bus [param bus_idx] at [param at_position].
</description>
</method>
- <method name="capture_get_device_list">
- <return type="PackedStringArray" />
- <description>
- Returns the names of all audio input devices detected on the system.
- [b]Note:[/b] [member ProjectSettings.audio/driver/enable_input] must be [code]true[/code] for audio input to work. See also that setting's description for caveats related to permissions and operating system privacy settings.
- </description>
- </method>
<method name="generate_bus_layout" qualifiers="const">
<return type="AudioBusLayout" />
<description>
@@ -117,10 +110,11 @@
Returns the volume of the bus at index [param bus_idx] in dB.
</description>
</method>
- <method name="get_device_list">
+ <method name="get_input_device_list">
<return type="PackedStringArray" />
<description>
- Returns the names of all audio devices detected on the system.
+ Returns the names of all audio input devices detected on the system.
+ [b]Note:[/b] [member ProjectSettings.audio/driver/enable_input] must be [code]true[/code] for audio input to work. See also that setting's description for caveats related to permissions and operating system privacy settings.
</description>
</method>
<method name="get_mix_rate" qualifiers="const">
@@ -129,6 +123,12 @@
Returns the sample rate at the output of the [AudioServer].
</description>
</method>
+ <method name="get_output_device_list">
+ <return type="PackedStringArray" />
+ <description>
+ Returns the names of all audio output devices detected on the system.
+ </description>
+ </method>
<method name="get_output_latency" qualifiers="const">
<return type="float" />
<description>
@@ -302,12 +302,12 @@
<member name="bus_count" type="int" setter="set_bus_count" getter="get_bus_count" default="1">
Number of available audio buses.
</member>
- <member name="capture_device" type="String" setter="capture_set_device" getter="capture_get_device" default="&quot;Default&quot;">
- Name of the current device for audio input (see [method capture_get_device_list]). On systems with multiple audio inputs (such as analog, USB and HDMI audio), this can be used to select the audio input device. The value [code]"Default"[/code] will record audio on the system-wide default audio input. If an invalid device name is set, the value will be reverted back to [code]"Default"[/code].
+ <member name="input_device" type="String" setter="set_input_device" getter="get_input_device" default="&quot;Default&quot;">
+ Name of the current device for audio input (see [method get_input_device_list]). On systems with multiple audio inputs (such as analog, USB and HDMI audio), this can be used to select the audio input device. The value [code]"Default"[/code] will record audio on the system-wide default audio input. If an invalid device name is set, the value will be reverted back to [code]"Default"[/code].
[b]Note:[/b] [member ProjectSettings.audio/driver/enable_input] must be [code]true[/code] for audio input to work. See also that setting's description for caveats related to permissions and operating system privacy settings.
</member>
- <member name="device" type="String" setter="set_device" getter="get_device" default="&quot;Default&quot;">
- Name of the current device for audio output (see [method get_device_list]). On systems with multiple audio outputs (such as analog, USB and HDMI audio), this can be used to select the audio output device. The value [code]"Default"[/code] will play audio on the system-wide default audio output. If an invalid device name is set, the value will be reverted back to [code]"Default"[/code].
+ <member name="output_device" type="String" setter="set_output_device" getter="get_output_device" default="&quot;Default&quot;">
+ Name of the current device for audio output (see [method get_output_device_list]). On systems with multiple audio outputs (such as analog, USB and HDMI audio), this can be used to select the audio output device. The value [code]"Default"[/code] will play audio on the system-wide default audio output. If an invalid device name is set, the value will be reverted back to [code]"Default"[/code].
</member>
<member name="playback_speed_scale" type="float" setter="set_playback_speed_scale" getter="get_playback_speed_scale" default="1.0">
Scales the rate at which audio is played (i.e. setting it to [code]0.5[/code] will make the audio be played at half its speed).
diff --git a/doc/classes/AudioStreamPlaybackPolyphonic.xml b/doc/classes/AudioStreamPlaybackPolyphonic.xml
new file mode 100644
index 0000000000..8b0951153b
--- /dev/null
+++ b/doc/classes/AudioStreamPlaybackPolyphonic.xml
@@ -0,0 +1,61 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="AudioStreamPlaybackPolyphonic" inherits="AudioStreamPlayback" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+ <brief_description>
+ Playback instance for [AudioStreamPolyphonic].
+ </brief_description>
+ <description>
+ Playback instance for [AudioStreamPolyphonic]. After setting the [code]stream[/code] property of [AudioStreamPlayer], [AudioStreamPlayer2D], or [AudioStreamPlayer3D], the playback instance can be obtained by calling [method AudioStreamPlayer.get_stream_playback], [method AudioStreamPlayer2D.get_stream_playback] or [method AudioStreamPlayer3D.get_stream_playback] methods.
+ </description>
+ <tutorials>
+ </tutorials>
+ <methods>
+ <method name="is_stream_playing" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="stream" type="int" />
+ <description>
+ Return true whether the stream associated with an integer ID is still playing. Check [method play_stream] for information on when this ID becomes invalid.
+ </description>
+ </method>
+ <method name="play_stream">
+ <return type="int" />
+ <param index="0" name="stream" type="AudioStream" />
+ <param index="1" name="from_offset" type="float" default="0" />
+ <param index="2" name="volume_db" type="float" default="0" />
+ <param index="3" name="pitch_scale" type="float" default="1.0" />
+ <description>
+ Play an [AudioStream] at a given offset, volume and pitch scale. Playback starts immediately.
+ The return value is an unique integer ID that is associated to this playback stream and which can be used to control it.
+ This ID becomes invalid when the stream ends (if it does not loop), when the [AudioStreamPlaybackPolyphonic] is stopped, or when [method stop_stream] is called.
+ This function returns [constant INVALID_ID] if the amount of streams currently playing equals [member AudioStreamPolyphonic.polyphony]. If you need a higher amount of maximum polyphony, raise this value.
+ </description>
+ </method>
+ <method name="set_stream_pitch_scale">
+ <return type="void" />
+ <param index="0" name="stream" type="int" />
+ <param index="1" name="pitch_scale" type="float" />
+ <description>
+ Change the stream pitch scale. The [param stream] argument is an integer ID returned by [method play_stream].
+ </description>
+ </method>
+ <method name="set_stream_volume">
+ <return type="void" />
+ <param index="0" name="stream" type="int" />
+ <param index="1" name="volume_db" type="float" />
+ <description>
+ Change the stream volume (in db). The [param stream] argument is an integer ID returned by [method play_stream].
+ </description>
+ </method>
+ <method name="stop_stream">
+ <return type="void" />
+ <param index="0" name="stream" type="int" />
+ <description>
+ Stop a stream. The [param stream] argument is an integer ID returned by [method play_stream], which becomes invalid after calling this function.
+ </description>
+ </method>
+ </methods>
+ <constants>
+ <constant name="INVALID_ID" value="-1">
+ Returned by [method play_stream] in case it could not allocate a stream for playback.
+ </constant>
+ </constants>
+</class>
diff --git a/doc/classes/AudioStreamPlayer.xml b/doc/classes/AudioStreamPlayer.xml
index 06e183f4e2..9b3a4f7bba 100644
--- a/doc/classes/AudioStreamPlayer.xml
+++ b/doc/classes/AudioStreamPlayer.xml
@@ -28,6 +28,12 @@
Returns the [AudioStreamPlayback] object associated with this [AudioStreamPlayer].
</description>
</method>
+ <method name="has_stream_playback">
+ <return type="bool" />
+ <description>
+ Returns whether the [AudioStreamPlayer] can return the [AudioStreamPlayback] object or not.
+ </description>
+ </method>
<method name="play">
<return type="void" />
<param index="0" name="from_position" type="float" default="0.0" />
diff --git a/doc/classes/AudioStreamPlayer2D.xml b/doc/classes/AudioStreamPlayer2D.xml
index 81755b580f..18869e87cb 100644
--- a/doc/classes/AudioStreamPlayer2D.xml
+++ b/doc/classes/AudioStreamPlayer2D.xml
@@ -25,6 +25,12 @@
Returns the [AudioStreamPlayback] object associated with this [AudioStreamPlayer2D].
</description>
</method>
+ <method name="has_stream_playback">
+ <return type="bool" />
+ <description>
+ Returns whether the [AudioStreamPlayer] can return the [AudioStreamPlayback] object or not.
+ </description>
+ </method>
<method name="play">
<return type="void" />
<param index="0" name="from_position" type="float" default="0.0" />
diff --git a/doc/classes/AudioStreamPlayer3D.xml b/doc/classes/AudioStreamPlayer3D.xml
index f711210ca1..d5a06dcad6 100644
--- a/doc/classes/AudioStreamPlayer3D.xml
+++ b/doc/classes/AudioStreamPlayer3D.xml
@@ -25,6 +25,12 @@
Returns the [AudioStreamPlayback] object associated with this [AudioStreamPlayer3D].
</description>
</method>
+ <method name="has_stream_playback">
+ <return type="bool" />
+ <description>
+ Returns whether the [AudioStreamPlayer] can return the [AudioStreamPlayback] object or not.
+ </description>
+ </method>
<method name="play">
<return type="void" />
<param index="0" name="from_position" type="float" default="0.0" />
diff --git a/doc/classes/AudioStreamPolyphonic.xml b/doc/classes/AudioStreamPolyphonic.xml
new file mode 100644
index 0000000000..baa1fc7037
--- /dev/null
+++ b/doc/classes/AudioStreamPolyphonic.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="AudioStreamPolyphonic" inherits="AudioStream" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+ <brief_description>
+ AudioStream that lets the user play custom streams at any time from code, simultaneously using a single player.
+ </brief_description>
+ <description>
+ AudioStream that lets the user play custom streams at any time from code, simultaneously using a single player.
+ Playback control is done via the [AudioStreamPlaybackPolyphonic] instance set inside the player, which can be obtained via [method AudioStreamPlayer.get_stream_playback], [method AudioStreamPlayer2D.get_stream_playback] or [method AudioStreamPlayer3D.get_stream_playback] methods. Obtaining the playback instance is only valid after the [code]stream[/code] property is set as an [AudioStreamPolyphonic] in those players.
+ </description>
+ <tutorials>
+ </tutorials>
+ <members>
+ <member name="polyphony" type="int" setter="set_polyphony" getter="get_polyphony" default="32">
+ Maximum amount of simultaneous streams that can be played.
+ </member>
+ </members>
+</class>
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/BackBufferCopy.xml b/doc/classes/BackBufferCopy.xml
index b2c5a1756f..be4a649b50 100644
--- a/doc/classes/BackBufferCopy.xml
+++ b/doc/classes/BackBufferCopy.xml
@@ -1,10 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="BackBufferCopy" inherits="Node2D" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
- Copies a region of the screen (or the whole screen) to a buffer so it can be accessed in your shader scripts through the [code]texture(SCREEN_TEXTURE, ...)[/code] function.
+ Copies a region of the screen (or the whole screen) to a buffer so it can be accessed in your shader scripts using the screen texture (i.e. a uniform sampler with ``hint_screen_texture``).
</brief_description>
<description>
- Node for back-buffering the currently-displayed screen. The region defined in the [BackBufferCopy] node is buffered with the content of the screen it covers, or the entire screen according to the copy mode set. Use the [code]texture(SCREEN_TEXTURE, ...)[/code] function in your shader scripts to access the buffer.
+ Node for back-buffering the currently-displayed screen. The region defined in the [BackBufferCopy] node is buffered with the content of the screen it covers, or the entire screen according to the copy mode set. Use the screen texture in your shader scripts to access the buffer.
[b]Note:[/b] Since this node inherits from [Node2D] (and not [Control]), anchors and margins won't apply to child [Control]-derived nodes. This can be problematic when resizing the window. To avoid this, add [Control]-derived nodes as [i]siblings[/i] to the [BackBufferCopy] node instead of adding them as children.
</description>
<tutorials>
diff --git a/doc/classes/BaseButton.xml b/doc/classes/BaseButton.xml
index c92e39e08a..68f62d1c00 100644
--- a/doc/classes/BaseButton.xml
+++ b/doc/classes/BaseButton.xml
@@ -50,7 +50,7 @@
<member name="button_group" type="ButtonGroup" setter="set_button_group" getter="get_button_group">
The [ButtonGroup] associated with the button. Not to be confused with node groups.
</member>
- <member name="button_mask" type="int" setter="set_button_mask" getter="get_button_mask" enum="MouseButton" default="1">
+ <member name="button_mask" type="int" setter="set_button_mask" getter="get_button_mask" enum="MouseButtonMask" default="1">
Binary mask to choose which mouse buttons this button will respond to.
To allow both left-click and right-click, use [code]MOUSE_BUTTON_MASK_LEFT | MOUSE_BUTTON_MASK_RIGHT[/code].
</member>
@@ -70,7 +70,7 @@
[Shortcut] associated to the button.
</member>
<member name="shortcut_feedback" type="bool" setter="set_shortcut_feedback" getter="is_shortcut_feedback" default="true">
- If [code]true[/code], the button will appear pressed when its shortcut is activated. If [code]false[/code] and [member toggle_mode] is [code]false[/code], the shortcut will activate the button without appearing to press the button.
+ If [code]true[/code], the button will highlight for a short amount of time when its shortcut is activated. If [code]false[/code] and [member toggle_mode] is [code]false[/code], the shortcut will activate without any visual feedback.
</member>
<member name="shortcut_in_tooltip" type="bool" setter="set_shortcut_in_tooltip" getter="is_shortcut_in_tooltip_enabled" default="true">
If [code]true[/code], the button will add information about its shortcut in the tooltip.
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/BoneAttachment3D.xml b/doc/classes/BoneAttachment3D.xml
index f29525038e..dd01de3607 100644
--- a/doc/classes/BoneAttachment3D.xml
+++ b/doc/classes/BoneAttachment3D.xml
@@ -16,19 +16,6 @@
Returns the [NodePath] to the external [Skeleton3D] node, if one has been set.
</description>
</method>
- <method name="get_override_mode" qualifiers="const" is_deprecated="true">
- <return type="int" />
- <description>
- Deprecated. Local pose overrides will be removed.
- Returns the override mode for the BoneAttachment3D node (0=global / 1=local).
- </description>
- </method>
- <method name="get_override_pose" qualifiers="const">
- <return type="bool" />
- <description>
- Returns whether the BoneAttachment3D node is overriding the bone pose of the bone it's attached to.
- </description>
- </method>
<method name="get_use_external_skeleton" qualifiers="const">
<return type="bool" />
<description>
@@ -49,21 +36,6 @@
Sets the [NodePath] to the external skeleton that the BoneAttachment3D node should use. The external [Skeleton3D] node is only used when [code]use_external_skeleton[/code] is set to [code]true[/code].
</description>
</method>
- <method name="set_override_mode" is_deprecated="true">
- <return type="void" />
- <param index="0" name="override_mode" type="int" />
- <description>
- Deprecated. Local pose overrides will be removed.
- Sets the override mode for the BoneAttachment3D node (0=global / 1=local). The override mode defines which of the bone poses the BoneAttachment3D node will override.
- </description>
- </method>
- <method name="set_override_pose">
- <return type="void" />
- <param index="0" name="override_pose" type="bool" />
- <description>
- Sets whether the BoneAttachment3D node will override the bone pose of the bone it is attached to. When set to [code]true[/code], the BoneAttachment3D node can change the pose of the bone.
- </description>
- </method>
<method name="set_use_external_skeleton">
<return type="void" />
<param index="0" name="use_external_skeleton" type="bool" />
@@ -79,5 +51,8 @@
<member name="bone_name" type="String" setter="set_bone_name" getter="get_bone_name" default="&quot;&quot;">
The name of the attached bone.
</member>
+ <member name="override_pose" type="bool" setter="set_override_pose" getter="get_override_pose" default="false">
+ Whether the BoneAttachment3D node will override the bone pose of the bone it is attached to. When set to [code]true[/code], the BoneAttachment3D node can change the pose of the bone. When set to [code]false[/code], the BoneAttachment3D will always be set to the bone's transform.
+ </member>
</members>
</class>
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/Callable.xml b/doc/classes/Callable.xml
index 1fb4f91920..8fc44d7536 100644
--- a/doc/classes/Callable.xml
+++ b/doc/classes/Callable.xml
@@ -14,21 +14,23 @@
func test():
var callable = Callable(self, "print_args")
callable.call("hello", "world") # Prints "hello world ".
- callable.call(Vector2.UP, 42, callable) # Prints "(0, -1) 42 Node(Node.gd)::print_args".
+ callable.call(Vector2.UP, 42, callable) # Prints "(0, -1) 42 Node(node.gd)::print_args".
callable.call("invalid") # Invalid call, should have at least 2 arguments.
[/gdscript]
[csharp]
- public void PrintArgs(object arg1, object arg2, object arg3 = null)
+ // Default parameter values are not supported.
+ public void PrintArgs(Variant arg1, Variant arg2, Variant arg3 = default)
{
GD.PrintS(arg1, arg2, arg3);
}
public void Test()
{
- Callable callable = new Callable(this, nameof(PrintArgs));
- callable.Call("hello", "world"); // Prints "hello world null".
+ // Invalid calls fail silently.
+ Callable callable = new Callable(this, MethodName.PrintArgs);
+ callable.Call("hello", "world"); // Default parameter values are not supported, should have 3 arguments.
callable.Call(Vector2.Up, 42, callable); // Prints "(0, -1) 42 Node(Node.cs)::PrintArgs".
- callable.Call("invalid"); // Invalid call, should have at least 2 arguments.
+ callable.Call("invalid"); // Invalid call, should have 3 arguments.
}
[/csharp]
[/codeblocks]
@@ -77,6 +79,13 @@
Returns a copy of this [Callable] with one or more arguments bound. When called, the bound arguments are passed [i]after[/i] the arguments supplied by [method call].
</description>
</method>
+ <method name="bindv">
+ <return type="Callable" />
+ <param index="0" name="arguments" type="Array" />
+ <description>
+ Returns a copy of this [Callable] with one or more arguments bound, reading them from an array. When called, the bound arguments are passed [i]after[/i] the arguments supplied by [method call].
+ </description>
+ </method>
<method name="call" qualifiers="vararg const">
<return type="Variant" />
<description>
@@ -100,6 +109,18 @@
Calls the method represented by this [Callable]. Unlike [method call], this method expects all arguments to be contained inside the [param arguments] [Array].
</description>
</method>
+ <method name="get_bound_arguments" qualifiers="const">
+ <return type="Array" />
+ <description>
+ Return the bound arguments (as long as [method get_bound_arguments_count] is greater than zero), or empty (if [method get_bound_arguments_count] is less than or equal to zero).
+ </description>
+ </method>
+ <method name="get_bound_arguments_count" qualifiers="const">
+ <return type="int" />
+ <description>
+ Returns the total amount of arguments bound (or unbound) via successive [method bind] or [method unbind] calls. If the amount of arguments unbound is greater than the ones bound, this function returns a value less than zero.
+ </description>
+ </method>
<method name="get_method" qualifiers="const">
<return type="StringName" />
<description>
diff --git a/doc/classes/Camera2D.xml b/doc/classes/Camera2D.xml
index 9315a85e1f..4156c9451a 100644
--- a/doc/classes/Camera2D.xml
+++ b/doc/classes/Camera2D.xml
@@ -55,6 +55,18 @@
[b]Note:[/b] The returned value is not the same as [member Node2D.global_position], as it is affected by the drag properties. It is also not the same as the current position if [member position_smoothing_enabled] is [code]true[/code] (see [method get_screen_center_position]).
</description>
</method>
+ <method name="is_current" qualifiers="const">
+ <return type="bool" />
+ <description>
+ Returns [code]true[/code] if this [Camera2D] is the active camera (see [method Viewport.get_camera_2d]).
+ </description>
+ </method>
+ <method name="make_current">
+ <return type="void" />
+ <description>
+ Forces this [Camera2D] to become the current active one. [member enabled] must be [code]true[/code].
+ </description>
+ </method>
<method name="reset_smoothing">
<return type="void" />
<description>
@@ -83,9 +95,6 @@
<member name="anchor_mode" type="int" setter="set_anchor_mode" getter="get_anchor_mode" enum="Camera2D.AnchorMode" default="1">
The Camera2D's anchor point. See [enum AnchorMode] constants.
</member>
- <member name="current" type="bool" setter="set_current" getter="is_current" default="false">
- If [code]true[/code], the camera acts as the active camera for its [Viewport] ancestor. Only one camera can be current in a given viewport, so setting a different camera in the same viewport [code]current[/code] will disable whatever camera was already active in that viewport.
- </member>
<member name="custom_viewport" type="Node" setter="set_custom_viewport" getter="get_custom_viewport">
The custom [Viewport] node attached to the [Camera2D]. If [code]null[/code] or not a [Viewport], uses the default viewport instead.
</member>
@@ -124,6 +133,10 @@
<member name="editor_draw_screen" type="bool" setter="set_screen_drawing_enabled" getter="is_screen_drawing_enabled" default="true">
If [code]true[/code], draws the camera's screen rectangle in the editor.
</member>
+ <member name="enabled" type="bool" setter="set_enabled" getter="is_enabled" default="true">
+ Controls whether the camera can be active or not. If [code]true[/code], the [Camera2D] will become the main camera when it enters the scene tree and there is no active camera currently (see [method Viewport.get_camera_2d]).
+ When the camera is currently active and [member enabled] is set to [code]false[/code], the next enabled [Camera2D] in the scene tree will become active.
+ </member>
<member name="ignore_rotation" type="bool" setter="set_ignore_rotation" getter="is_ignoring_rotation" default="true">
If [code]true[/code], the camera's rendered view is not affected by its [member Node2D.rotation] and [member Node2D.global_rotation].
</member>
diff --git a/doc/classes/CanvasGroup.xml b/doc/classes/CanvasGroup.xml
index 37827defec..6eeff8fef3 100644
--- a/doc/classes/CanvasGroup.xml
+++ b/doc/classes/CanvasGroup.xml
@@ -9,8 +9,10 @@
[codeblock]
shader_type canvas_item;
+ uniform sampler2D screen_texture : hint_screen_texture, repeat_disable, filter_nearest;
+
void fragment() {
- vec4 c = textureLod(SCREEN_TEXTURE, SCREEN_UV, 0.0);
+ vec4 c = textureLod(screen_texture, SCREEN_UV, 0.0);
if (c.a &gt; 0.0001) {
c.rgb /= c.a;
diff --git a/doc/classes/CanvasItem.xml b/doc/classes/CanvasItem.xml
index 499d53e63c..c3c768c12d 100644
--- a/doc/classes/CanvasItem.xml
+++ b/doc/classes/CanvasItem.xml
@@ -42,10 +42,12 @@
<param index="3" name="end_angle" type="float" />
<param index="4" name="point_count" type="int" />
<param index="5" name="color" type="Color" />
- <param index="6" name="width" type="float" default="1.0" />
+ <param index="6" name="width" type="float" default="-1.0" />
<param index="7" name="antialiased" type="bool" default="false" />
<description>
- Draws a unfilled arc between the given angles. The larger the value of [param point_count], the smoother the curve. See also [method draw_circle].
+ Draws an unfilled arc between the given angles with a uniform [param color] and [param width] and optional antialiasing (supported only for positive [param width]). The larger the value of [param point_count], the smoother the curve. See also [method draw_circle].
+ If [param width] is negative, then the arc is drawn using [constant RenderingServer.PRIMITIVE_LINE_STRIP]. This means that when the CanvasItem is scaled, the arc will remain thin. If this behavior is not desired, then pass a positive [param width] like [code]1.0[/code].
+ The arc is drawn from [param start_angle] towards the value of [param end_angle] so in clockwise direction if [code]start_angle &lt; end_angle[/code] and counter-clockwise otherwise. Passing the same angles but in reversed order will produce the same arc. If absolute difference of [param start_angle] and [param end_angle] is greater than [constant @GDScript.TAU] radians, then a full circle arc is drawn (i.e. arc will not overlap itself).
</description>
</method>
<method name="draw_char" qualifiers="const">
@@ -95,10 +97,12 @@
<param index="0" name="from" type="Vector2" />
<param index="1" name="to" type="Vector2" />
<param index="2" name="color" type="Color" />
- <param index="3" name="width" type="float" default="1.0" />
+ <param index="3" name="width" type="float" default="-1.0" />
<param index="4" name="dash" type="float" default="2.0" />
+ <param index="5" name="aligned" type="bool" default="true" />
<description>
Draws a dashed line from a 2D point to another, with a given color and width. See also [method draw_multiline] and [method draw_polyline].
+ If [param width] is negative, then a two-point primitives will be drawn instead of a four-point ones. This means that when the CanvasItem is scaled, the line parts will remain thin. If this behavior is not desired, then pass a positive [param width] like [code]1.0[/code].
</description>
</method>
<method name="draw_end_animation">
@@ -129,10 +133,11 @@
<param index="0" name="from" type="Vector2" />
<param index="1" name="to" type="Vector2" />
<param index="2" name="color" type="Color" />
- <param index="3" name="width" type="float" default="1.0" />
+ <param index="3" name="width" type="float" default="-1.0" />
<param index="4" name="antialiased" type="bool" default="false" />
<description>
Draws a line from a 2D point to another, with a given color and width. It can be optionally antialiased. See also [method draw_multiline] and [method draw_polyline].
+ If [param width] is negative, then a two-point primitive will be drawn instead of a four-point one. This means that when the CanvasItem is scaled, the line will remain thin. If this behavior is not desired, then pass a positive [param width] like [code]1.0[/code].
</description>
</method>
<method name="draw_mesh">
@@ -153,6 +158,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.
@@ -163,18 +169,20 @@
<return type="void" />
<param index="0" name="points" type="PackedVector2Array" />
<param index="1" name="color" type="Color" />
- <param index="2" name="width" type="float" default="1.0" />
+ <param index="2" name="width" type="float" default="-1.0" />
<description>
Draws multiple disconnected lines with a uniform [param color]. When drawing large amounts of lines, this is faster than using individual [method draw_line] calls. To draw interconnected lines, use [method draw_polyline] instead.
+ If [param width] is negative, then two-point primitives will be drawn instead of a four-point ones. This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not desired, then pass a positive [param width] like [code]1.0[/code].
</description>
</method>
<method name="draw_multiline_colors">
<return type="void" />
<param index="0" name="points" type="PackedVector2Array" />
<param index="1" name="colors" type="PackedColorArray" />
- <param index="2" name="width" type="float" default="1.0" />
+ <param index="2" name="width" type="float" default="-1.0" />
<description>
Draws multiple disconnected lines with a uniform [param width] and segment-by-segment coloring. Colors assigned to line segments match by index between [param points] and [param colors]. When drawing large amounts of lines, this is faster than using individual [method draw_line] calls. To draw interconnected lines, use [method draw_polyline_colors] instead.
+ If [param width] is negative, then two-point primitives will be drawn instead of a four-point ones. This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not desired, then pass a positive [param width] like [code]1.0[/code].
</description>
</method>
<method name="draw_multiline_string" qualifiers="const">
@@ -236,20 +244,22 @@
<return type="void" />
<param index="0" name="points" type="PackedVector2Array" />
<param index="1" name="color" type="Color" />
- <param index="2" name="width" type="float" default="1.0" />
+ <param index="2" name="width" type="float" default="-1.0" />
<param index="3" name="antialiased" type="bool" default="false" />
<description>
- Draws interconnected line segments with a uniform [param color] and [param width] and optional antialiasing. When drawing large amounts of lines, this is faster than using individual [method draw_line] calls. To draw disconnected lines, use [method draw_multiline] instead. See also [method draw_polygon].
+ Draws interconnected line segments with a uniform [param color] and [param width] and optional antialiasing (supported only for positive [param width]). When drawing large amounts of lines, this is faster than using individual [method draw_line] calls. To draw disconnected lines, use [method draw_multiline] instead. See also [method draw_polygon].
+ If [param width] is negative, the polyline is drawn using [constant RenderingServer.PRIMITIVE_LINE_STRIP]. This means that when the CanvasItem is scaled, the polyline will remain thin. If this behavior is not desired, then pass a positive [param width] like [code]1.0[/code].
</description>
</method>
<method name="draw_polyline_colors">
<return type="void" />
<param index="0" name="points" type="PackedVector2Array" />
<param index="1" name="colors" type="PackedColorArray" />
- <param index="2" name="width" type="float" default="1.0" />
+ <param index="2" name="width" type="float" default="-1.0" />
<param index="3" name="antialiased" type="bool" default="false" />
<description>
- Draws interconnected line segments with a uniform [param width] and segment-by-segment coloring, and optional antialiasing. Colors assigned to line segments match by index between [param points] and [param colors]. When drawing large amounts of lines, this is faster than using individual [method draw_line] calls. To draw disconnected lines, use [method draw_multiline_colors] instead. See also [method draw_polygon].
+ Draws interconnected line segments with a uniform [param width] and segment-by-segment coloring, and optional antialiasing (supported only for positive [param width]). Colors assigned to line segments match by index between [param points] and [param colors]. When drawing large amounts of lines, this is faster than using individual [method draw_line] calls. To draw disconnected lines, use [method draw_multiline_colors] instead. See also [method draw_polygon].
+ If [param width] is negative, then the polyline is drawn using [constant RenderingServer.PRIMITIVE_LINE_STRIP]. This means that when the CanvasItem is scaled, the polyline will remain thin. If this behavior is not desired, then pass a positive [param width] like [code]1.0[/code].
</description>
</method>
<method name="draw_primitive">
@@ -258,7 +268,6 @@
<param index="1" name="colors" type="PackedColorArray" />
<param index="2" name="uvs" type="PackedVector2Array" />
<param index="3" name="texture" type="Texture2D" default="null" />
- <param index="4" name="width" type="float" default="1.0" />
<description>
Draws a custom primitive. 1 point for a point, 2 points for a line, 3 points for a triangle, and 4 points for a quad. If 0 points or more than 4 points are specified, nothing will be drawn and an error message will be printed. See also [method draw_line], [method draw_polyline], [method draw_polygon], and [method draw_rect].
</description>
@@ -268,10 +277,12 @@
<param index="0" name="rect" type="Rect2" />
<param index="1" name="color" type="Color" />
<param index="2" name="filled" type="bool" default="true" />
- <param index="3" name="width" type="float" default="1.0" />
+ <param index="3" name="width" type="float" default="-1.0" />
<description>
Draws a rectangle. If [param filled] is [code]true[/code], the rectangle will be filled with the [param color] specified. If [param filled] is [code]false[/code], the rectangle will be drawn as a stroke with the [param color] and [param width] specified.
+ If [param width] is negative, then two-point primitives will be drawn instead of a four-point ones. This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not desired, then pass a positive [param width] like [code]1.0[/code].
[b]Note:[/b] [param width] is only effective if [param filled] is [code]false[/code].
+ [b]Note:[/b] Unfilled rectangles drawn with a negative [param width] may not display perfectly. For example, corners may be missing or brighter due to overlapping lines (for a translucent [param color]).
</description>
</method>
<method name="draw_set_transform">
@@ -404,7 +415,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 +433,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 +464,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..2ff207acb7 100644
--- a/doc/classes/CharacterBody3D.xml
+++ b/doc/classes/CharacterBody3D.xml
@@ -5,8 +5,9 @@
</brief_description>
<description>
Character bodies are special types of bodies that are meant to be user-controlled. They are not affected by physics at all; to other types of bodies, such as a rigid body, these are the same as a [AnimatableBody3D]. However, they have two main uses:
- [b]Kinematic characters:[/b] Character bodies have an API for moving objects with walls and slopes detection ([method move_and_slide] method), in addition to collision detection (also done with [method PhysicsBody3D.move_and_collide]). This makes them really useful to implement characters that move in specific ways and collide with the world, but don't require advanced physics.
- [b]Kinematic motion:[/b] Character bodies can also be used for kinematic motion (same functionality as [AnimatableBody3D]), which allows them to be moved by code and push other bodies on their path.
+ [i]Kinematic characters:[/i] Character bodies have an API for moving objects with walls and slopes detection ([method move_and_slide] method), in addition to collision detection (also done with [method PhysicsBody3D.move_and_collide]). This makes them really useful to implement characters that move in specific ways and collide with the world, but don't require advanced physics.
+ [i]Kinematic motion:[/i] Character bodies can also be used for kinematic motion (same functionality as [AnimatableBody3D]), which allows them to be moved by code and push other bodies on their path.
+ [b]Warning:[/b] With a non-uniform scale this node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change the size(s) of its collision shape(s) instead.
</description>
<tutorials>
<link title="Kinematic character (2D)">$DOCS_URL/tutorials/physics/kinematic_character_2d.html</link>
@@ -41,10 +42,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..df40d2a4cf 100644
--- a/doc/classes/CodeEdit.xml
+++ b/doc/classes/CodeEdit.xml
@@ -132,12 +132,6 @@
Perform an indent as if the user activated the "ui_text_indent" action.
</description>
</method>
- <method name="do_unindent">
- <return type="void" />
- <description>
- Perform an unindent as if the user activated the "ui_text_unindent" action.
- </description>
- </method>
<method name="fold_all_lines">
<return type="void" />
<description>
@@ -423,7 +417,7 @@
<method name="unindent_lines">
<return type="void" />
<description>
- Unindents selected lines, or in the case of no selection the caret line by one.
+ Unindents selected lines, or in the case of no selection the caret line by one. Same as performing "ui_text_unindent" action.
</description>
</method>
<method name="update_code_completion_options">
@@ -448,7 +442,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 +645,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/CollisionObject3D.xml b/doc/classes/CollisionObject3D.xml
index c302963b92..01b0d88326 100644
--- a/doc/classes/CollisionObject3D.xml
+++ b/doc/classes/CollisionObject3D.xml
@@ -5,6 +5,7 @@
</brief_description>
<description>
CollisionObject3D is the base class for physics objects. It can hold any number of collision [Shape3D]s. Each shape must be assigned to a [i]shape owner[/i]. The CollisionObject3D can have any number of shape owners. Shape owners are not nodes and do not appear in the editor, but are accessible through code using the [code]shape_owner_*[/code] methods.
+ [b]Warning:[/b] With a non-uniform scale this node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change the size(s) of its collision shape(s) instead.
</description>
<tutorials>
</tutorials>
@@ -216,13 +217,13 @@
<signal name="mouse_entered">
<description>
Emitted when the mouse pointer enters any of this object's shapes. Requires [member input_ray_pickable] to be [code]true[/code] and at least one [member collision_layer] bit to be set.
- [b]Note:[/b] Due to the lack of continuous collision detection, this signal may not be emitted in the expected order if the mouse moves fast enough and the [CollisionObject2D]'s area is small. This signal may also not be emitted if another [CollisionObject2D] is overlapping the [CollisionObject2D] in question.
+ [b]Note:[/b] Due to the lack of continuous collision detection, this signal may not be emitted in the expected order if the mouse moves fast enough and the [CollisionObject3D]'s area is small. This signal may also not be emitted if another [CollisionObject3D] is overlapping the [CollisionObject3D] in question.
</description>
</signal>
<signal name="mouse_exited">
<description>
Emitted when the mouse pointer exits all this object's shapes. Requires [member input_ray_pickable] to be [code]true[/code] and at least one [member collision_layer] bit to be set.
- [b]Note:[/b] Due to the lack of continuous collision detection, this signal may not be emitted in the expected order if the mouse moves fast enough and the [CollisionObject2D]'s area is small. This signal may also not be emitted if another [CollisionObject2D] is overlapping the [CollisionObject2D] in question.
+ [b]Note:[/b] Due to the lack of continuous collision detection, this signal may not be emitted in the expected order if the mouse moves fast enough and the [CollisionObject3D]'s area is small. This signal may also not be emitted if another [CollisionObject3D] is overlapping the [CollisionObject3D] in question.
</description>
</signal>
</signals>
@@ -232,7 +233,7 @@
Automatically re-added to the physics simulation when the [Node] is processed again.
</constant>
<constant name="DISABLE_MODE_MAKE_STATIC" value="1" enum="DisableMode">
- When [member Node.process_mode] is set to [constant Node.PROCESS_MODE_DISABLED], make the body static. Doesn't affect [Area2D]. [PhysicsBody3D] can't be affected by forces or other bodies while static.
+ When [member Node.process_mode] is set to [constant Node.PROCESS_MODE_DISABLED], make the body static. Doesn't affect [Area3D]. [PhysicsBody3D] can't be affected by forces or other bodies while static.
Automatically set [PhysicsBody3D] back to its original mode when the [Node] is processed again.
</constant>
<constant name="DISABLE_MODE_KEEP_ACTIVE" value="2" enum="DisableMode">
diff --git a/doc/classes/CollisionPolygon3D.xml b/doc/classes/CollisionPolygon3D.xml
index 7d718cff27..29e55367a8 100644
--- a/doc/classes/CollisionPolygon3D.xml
+++ b/doc/classes/CollisionPolygon3D.xml
@@ -6,6 +6,7 @@
<description>
Allows editing a concave or convex collision polygon's vertices on a selected plane. Can also set a depth perpendicular to that plane. This class is only available in the editor. It will not appear in the scene tree at run-time. Creates several [ConvexPolygonShape3D]s at run-time to represent the original polygon using convex decomposition.
[b]Note:[/b] Since this is an editor-only helper, properties modified during gameplay will have no effect.
+ [b]Warning:[/b] A non-uniformly scaled CollisionPolygon3D node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change its [member polygon]'s vertices instead.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/CollisionShape3D.xml b/doc/classes/CollisionShape3D.xml
index 304b46ba27..c5d05670e9 100644
--- a/doc/classes/CollisionShape3D.xml
+++ b/doc/classes/CollisionShape3D.xml
@@ -6,6 +6,7 @@
<description>
Editor facility for creating and editing collision shapes in 3D space. Set the [member shape] property to configure the shape. [b]IMPORTANT[/b]: this is an Editor-only helper to create shapes, use [method CollisionObject3D.shape_owner_get_shape] to get the actual shape.
You can use this node to represent all sorts of collision shapes, for example, add this to an [Area3D] to give it a detection shape, or add it to a [PhysicsBody3D] to create a solid object.
+ [b]Warning:[/b] A non-uniformly scaled CollisionShape3D node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change the size of its [member shape] resource instead.
</description>
<tutorials>
<link title="Physics introduction">$DOCS_URL/tutorials/physics/physics_introduction.html</link>
diff --git a/doc/classes/Color.xml b/doc/classes/Color.xml
index 4d78433915..cee0e3ef7d 100644
--- a/doc/classes/Color.xml
+++ b/doc/classes/Color.xml
@@ -101,7 +101,7 @@
<return type="Color" />
<param index="0" name="over" type="Color" />
<description>
- Returns a new color resulting from overlaying this color over the given color. In a painting program, you can imagine it as the [param over] color painted over this colour (including alpha).
+ Returns a new color resulting from overlaying this color over the given color. In a painting program, you can imagine it as the [param over] color painted over this color (including alpha).
[codeblocks]
[gdscript]
var bg = Color(0.0, 1.0, 0.0, 0.5) # Green with alpha of 50%
@@ -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">
@@ -226,7 +233,6 @@
<description>
Returns a new color from [param rgba], an HTML hexadecimal color string. [param rgba] is not case-sensitive, and may be prefixed by a hash sign ([code]#[/code]).
[param rgba] must be a valid three-digit or six-digit hexadecimal color string, and may contain an alpha channel value. If [param rgba] does not contain an alpha channel value, an alpha channel value of 1.0 is applied. If [param rgba] is invalid, returns an empty color.
- [b]Note:[/b] In C#, this method is not implemented. The same functionality is provided by the Color constructor.
[codeblocks]
[gdscript]
var blue = Color.html("#0000ff") # blue is Color(0.0, 0.0, 1.0, 1.0)
@@ -234,9 +240,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 +263,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.HtmlIsValid("#55AAFF"); // Returns true
+ Color.HtmlIsValid("#55AAFF20"); // Returns true
+ Color.HtmlIsValid("55AAFF"); // Returns true
+ Color.HtmlIsValid("#F2C"); // Returns true
- "#AABBC".IsValidHtmlColor(); // Returns false
- "#55aaFF5".IsValidHtmlColor(); // Returns false
+ Color.HtmlIsValid("#AABBC"); // Returns false
+ Color.HtmlIsValid("#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/ConfirmationDialog.xml b/doc/classes/ConfirmationDialog.xml
index 48b4df9126..ac2ea5be17 100644
--- a/doc/classes/ConfirmationDialog.xml
+++ b/doc/classes/ConfirmationDialog.xml
@@ -8,10 +8,10 @@
To get cancel action, you can use:
[codeblocks]
[gdscript]
- get_cancel_button().pressed.connect(self.cancelled)
+ get_cancel_button().pressed.connect(self.canceled)
[/gdscript]
[csharp]
- GetCancelButton().Pressed += Cancelled;
+ GetCancelButton().Pressed += Canceled;
[/csharp]
[/codeblocks]
</description>
diff --git a/doc/classes/Control.xml b/doc/classes/Control.xml
index fd6aab6a49..d74ddba369 100644
--- a/doc/classes/Control.xml
+++ b/doc/classes/Control.xml
@@ -37,11 +37,11 @@
return typeof(data) == TYPE_DICTIONARY and data.has("expected")
[/gdscript]
[csharp]
- public override bool CanDropData(Vector2 position, object data)
+ public override bool _CanDropData(Vector2 atPosition, Variant data)
{
// Check position if it is relevant to you
// Otherwise, just check data
- return data is Godot.Collections.Dictionary &amp;&amp; (data as Godot.Collections.Dictionary).Contains("expected");
+ return data.VariantType == Variant.Type.Dictionary &amp;&amp; data.AsGodotDictionary().Contains("expected");
}
[/csharp]
[/codeblocks]
@@ -57,17 +57,19 @@
[gdscript]
func _can_drop_data(position, data):
return typeof(data) == TYPE_DICTIONARY and data.has("color")
+
func _drop_data(position, data):
var color = data["color"]
[/gdscript]
[csharp]
- public override bool CanDropData(Vector2 position, object data)
+ public override bool _CanDropData(Vector2 atPosition, Variant data)
{
- return data is Godot.Collections.Dictionary &amp;&amp; (data as Godot.Collections.Dictionary).Contains("color");
+ return data.VariantType == Variant.Type.Dictionary &amp;&amp; dict.AsGodotDictionary().Contains("color");
}
- public override void DropData(Vector2 position, object data)
+
+ public override void _DropData(Vector2 atPosition, Variant data)
{
- Color color = (Color)(data as Godot.Collections.Dictionary)["color"];
+ Color color = data.AsGodotDictionary()["color"].AsColor();
}
[/csharp]
[/codeblocks]
@@ -87,11 +89,11 @@
return mydata
[/gdscript]
[csharp]
- public override object GetDragData(Vector2 position)
+ public override Variant _GetDragData(Vector2 atPosition)
{
- object mydata = MakeData(); // This is your custom method generating the drag data.
- SetDragPreview(MakePreview(mydata)); // This is your custom method generating the preview of the drag data.
- return mydata;
+ var myData = MakeData(); // This is your custom method generating the drag data.
+ SetDragPreview(MakePreview(myData)); // This is your custom method generating the preview of the drag data.
+ return myData;
}
[/csharp]
[/codeblocks]
@@ -121,10 +123,9 @@
[csharp]
public override void _GuiInput(InputEvent @event)
{
- if (@event is InputEventMouseButton)
+ if (@event is InputEventMouseButton mb)
{
- var mb = @event as InputEventMouseButton;
- if (mb.ButtonIndex == (int)ButtonList.Left &amp;&amp; mb.Pressed)
+ if (mb.ButtonIndex == MouseButton.Left &amp;&amp; mb.Pressed)
{
GD.Print("I've been clicked D:");
}
@@ -168,7 +169,7 @@
return label
[/gdscript]
[csharp]
- public override Godot.Control _MakeCustomTooltip(String forText)
+ public override Control _MakeCustomTooltip(string forText)
{
var label = new Label();
label.Text = forText;
@@ -180,14 +181,14 @@
[codeblocks]
[gdscript]
func _make_custom_tooltip(for_text):
- var tooltip = preload("res://SomeTooltipScene.tscn").instantiate()
+ var tooltip = preload("res://some_tooltip_scene.tscn").instantiate()
tooltip.get_node("Label").text = for_text
return tooltip
[/gdscript]
[csharp]
- public override Godot.Control _MakeCustomTooltip(String forText)
+ public override Control _MakeCustomTooltip(string forText)
{
- Node tooltip = ResourceLoader.Load&lt;PackedScene&gt;("res://SomeTooltipScene.tscn").Instantiate();
+ Node tooltip = ResourceLoader.Load&lt;PackedScene&gt;("res://some_tooltip_scene.tscn").Instantiate();
tooltip.GetNode&lt;Label&gt;("Label").Text = forText;
return tooltip;
}
@@ -196,12 +197,12 @@
</description>
</method>
<method name="_structured_text_parser" qualifiers="virtual const">
- <return type="Vector2i[]" />
+ <return type="Vector3i[]" />
<param index="0" name="args" type="Array" />
<param index="1" name="text" type="String" />
<description>
User defined BiDi algorithm override function.
- Returns an [Array] of [Vector2i] text ranges, in the left-to-right order. Ranges should cover full source [param text] without overlaps. BiDi algorithm will be used on each range separately.
+ Returns an [Array] of [Vector3i] text ranges and text base directions, in the left-to-right order. Ranges should cover full source [param text] without overlaps. BiDi algorithm will be used on each range separately.
</description>
</method>
<method name="accept_event">
@@ -229,11 +230,11 @@
[/gdscript]
[csharp]
// Given the child Label node "MyLabel", override its font color with a custom value.
- GetNode&lt;Label&gt;("MyLabel").AddThemeColorOverride("font_color", new Color(1, 0.5f, 0))
+ GetNode&lt;Label&gt;("MyLabel").AddThemeColorOverride("font_color", new Color(1, 0.5f, 0));
// Reset the font color of the child label.
- GetNode&lt;Label&gt;("MyLabel").RemoveThemeColorOverride("font_color")
+ GetNode&lt;Label&gt;("MyLabel").RemoveThemeColorOverride("font_color");
// Alternatively it can be overridden with the default value from the Label type.
- GetNode&lt;Label&gt;("MyLabel").AddThemeColorOverride("font_color", GetThemeColor("font_color", "Label"))
+ GetNode&lt;Label&gt;("MyLabel").AddThemeColorOverride("font_color", GetThemeColor("font_color", "Label"));
[/csharp]
[/codeblocks]
</description>
@@ -383,7 +384,9 @@
<method name="get_global_rect" qualifiers="const">
<return type="Rect2" />
<description>
- Returns the position and size of the control relative to the [CanvasLayer]. See [member global_position] and [member size].
+ Returns the position and size of the control relative to the containing canvas. See [member global_position] and [member size].
+ [b]Note:[/b] If the node itself or any parent [CanvasItem] between the node and the canvas have a non default rotation or skew, the resulting size is likely not meaningful.
+ [b]Note:[/b] Setting [member Viewport.gui_snap_controls_to_pixels] to [code]true[/code] can lead to rounding inaccuracies between the displayed control and the returned [Rect2].
</description>
</method>
<method name="get_minimum_size" qualifiers="const">
@@ -414,7 +417,9 @@
<method name="get_rect" qualifiers="const">
<return type="Rect2" />
<description>
- Returns the position and size of the control relative to the top-left corner of the parent Control. See [member position] and [member size].
+ Returns the position and size of the control in the coordinate system of the containing node. See [member position], [member scale] and [member size].
+ [b]Note:[/b] If [member rotation] is not the default rotation, the resulting size is not meaningful.
+ [b]Note:[/b] Setting [member Viewport.gui_snap_controls_to_pixels] to [code]true[/code] can lead to rounding inaccuracies between the displayed control and the returned [Rect2].
</description>
</method>
<method name="get_screen_position" qualifiers="const">
@@ -538,12 +543,12 @@
[codeblocks]
[gdscript]
func _process(delta):
- grab_click_focus() #when clicking another Control node, this node will be clicked instead
+ grab_click_focus() # When clicking another Control node, this node will be clicked instead.
[/gdscript]
[csharp]
- public override void _Process(float delta)
+ public override void _Process(double delta)
{
- GrabClickFocus(); //when clicking another Control node, this node will be clicked instead
+ GrabClickFocus(); // When clicking another Control node, this node will be clicked instead.
}
[/csharp]
[/codeblocks]
@@ -780,67 +785,13 @@
</method>
<method name="set_drag_forwarding">
<return type="void" />
- <param index="0" name="target" type="Object" />
+ <param index="0" name="drag_func" type="Callable" />
+ <param index="1" name="can_drop_func" type="Callable" />
+ <param index="2" name="drop_func" type="Callable" />
<description>
- Forwards the handling of this control's drag and drop to [param target] object.
- Forwarding can be implemented in the target object similar to the methods [method _get_drag_data], [method _can_drop_data], and [method _drop_data] but with two differences:
- 1. The function name must be suffixed with [b]_fw[/b]
- 2. The function must take an extra argument that is the control doing the forwarding
- [codeblocks]
- [gdscript]
- # ThisControl.gd
- extends Control
- export(Control) var target_control
-
- func _ready():
- set_drag_forwarding(target_control)
-
- # TargetControl.gd
- extends Control
-
- func _can_drop_data_fw(position, data, from_control):
- return true
-
- func _drop_data_fw(position, data, from_control):
- my_handle_data(data) # Your handler method.
-
- func _get_drag_data_fw(position, from_control):
- set_drag_preview(my_preview)
- return my_data()
- [/gdscript]
- [csharp]
- // ThisControl.cs
- public class ThisControl : Control
- {
- [Export]
- public Control TargetControl { get; set; }
- public override void _Ready()
- {
- SetDragForwarding(TargetControl);
- }
- }
-
- // TargetControl.cs
- public class TargetControl : Control
- {
- public void CanDropDataFw(Vector2 position, object data, Control fromControl)
- {
- return true;
- }
-
- public void DropDataFw(Vector2 position, object data, Control fromControl)
- {
- MyHandleData(data); // Your handler method.
- }
-
- public void GetDragDataFw(Vector2 position, Control fromControl)
- {
- SetDragPreview(MyPreview);
- return MyData();
- }
- }
- [/csharp]
- [/codeblocks]
+ Forwards the handling of this control's [method _get_drag_data], [method _can_drop_data] and [method _drop_data] virtual functions to delegate callables.
+ For each argument, if not empty, the delegate callable is used, otherwise the local (virtual) function is used.
+ The function format for each callable should be exactly the same as the virtual functions described above.
</description>
</method>
<method name="set_drag_preview">
@@ -862,16 +813,16 @@
[/gdscript]
[csharp]
[Export]
- public Color Color = new Color(1, 0, 0, 1);
+ private Color _color = new Color(1, 0, 0, 1);
- public override object GetDragData(Vector2 position)
+ public override Variant _GetDragData(Vector2 atPosition)
{
// Use a control that is not in the tree
var cpb = new ColorPickerButton();
- cpb.Color = Color;
- cpb.RectSize = new Vector2(50, 50);
+ cpb.Color = _color;
+ cpb.Size = new Vector2(50, 50);
SetDragPreview(cpb);
- return Color;
+ return _color;
}
[/csharp]
[/codeblocks]
@@ -949,6 +900,7 @@
<param index="0" name="position" type="Vector2" />
<description>
Moves the mouse cursor to [param position], relative to [member position] of this [Control].
+ [b]Note:[/b] [method warp_mouse] is only supported on Windows, macOS and Linux. It has no effect on Android, iOS and Web.
</description>
</method>
</methods>
@@ -1045,11 +997,14 @@
By default, the node's pivot is its top-left corner. When you change its [member rotation] or [member scale], it will rotate or scale around this pivot. Set this property to [member size] / 2 to pivot around the Control's center.
</member>
<member name="position" type="Vector2" setter="_set_position" getter="get_position" default="Vector2(0, 0)">
- The node's position, relative to its parent. It corresponds to the rectangle's top-left corner. The property is not affected by [member pivot_offset].
+ The node's position, relative to its containing node. It corresponds to the rectangle's top-left corner. The property is not affected by [member pivot_offset].
</member>
<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.
@@ -1059,15 +1014,15 @@
The [Node] which must be a parent of the focused [Control] for the shortcut to be activated. If [code]null[/code], the shortcut can be activated when any control is focused (a global shortcut). This allows shortcuts to be accepted only when the user has a certain area of the GUI focused.
</member>
<member name="size" type="Vector2" setter="_set_size" getter="get_size" default="Vector2(0, 0)">
- The size of the node's bounding rectangle, in pixels. [Container] nodes update this property automatically.
+ The size of the node's bounding rectangle, in the node's coordinate system. [Container] nodes update this property automatically.
</member>
- <member name="size_flags_horizontal" type="int" setter="set_h_size_flags" getter="get_h_size_flags" default="1">
+ <member name="size_flags_horizontal" type="int" setter="set_h_size_flags" getter="get_h_size_flags" enum="Control.SizeFlags" default="1">
Tells the parent [Container] nodes how they should resize and place the node on the X axis. Use one of the [enum SizeFlags] constants to change the flags. See the constants to learn what each does.
</member>
<member name="size_flags_stretch_ratio" type="float" setter="set_stretch_ratio" getter="get_stretch_ratio" default="1.0">
If the node and at least one of its neighbors uses the [constant SIZE_EXPAND] size flag, the parent [Container] will let it take more or less space depending on this property. If this node has a stretch ratio of 2 and its neighbor a ratio of 1, this node will take two thirds of the available space.
</member>
- <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" default="1">
+ <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" enum="Control.SizeFlags" default="1">
Tells the parent [Container] nodes how they should resize and place the node on the Y axis. Use one of the [enum SizeFlags] constants to change the flags. See the constants to learn what each does.
</member>
<member name="theme" type="Theme" setter="set_theme" getter="get_theme">
@@ -1312,23 +1267,23 @@
<constant name="PRESET_MODE_KEEP_SIZE" value="3" enum="LayoutPresetMode">
The control's size will not change.
</constant>
- <constant name="SIZE_SHRINK_BEGIN" value="0" enum="SizeFlags">
+ <constant name="SIZE_SHRINK_BEGIN" value="0" enum="SizeFlags" is_bitfield="true">
Tells the parent [Container] to align the node with its start, either the top or the left edge. It is mutually exclusive with [constant SIZE_FILL] and other shrink size flags, but can be used with [constant SIZE_EXPAND] in some containers. Use with [member size_flags_horizontal] and [member size_flags_vertical].
[b]Note:[/b] Setting this flag is equal to not having any size flags.
</constant>
- <constant name="SIZE_FILL" value="1" enum="SizeFlags">
+ <constant name="SIZE_FILL" value="1" enum="SizeFlags" is_bitfield="true">
Tells the parent [Container] to expand the bounds of this node to fill all the available space without pushing any other node. It is mutually exclusive with shrink size flags. Use with [member size_flags_horizontal] and [member size_flags_vertical].
</constant>
- <constant name="SIZE_EXPAND" value="2" enum="SizeFlags">
+ <constant name="SIZE_EXPAND" value="2" enum="SizeFlags" is_bitfield="true">
Tells the parent [Container] to let this node take all the available space on the axis you flag. If multiple neighboring nodes are set to expand, they'll share the space based on their stretch ratio. See [member size_flags_stretch_ratio]. Use with [member size_flags_horizontal] and [member size_flags_vertical].
</constant>
- <constant name="SIZE_EXPAND_FILL" value="3" enum="SizeFlags">
+ <constant name="SIZE_EXPAND_FILL" value="3" enum="SizeFlags" is_bitfield="true">
Sets the node's size flags to both fill and expand. See [constant SIZE_FILL] and [constant SIZE_EXPAND] for more information.
</constant>
- <constant name="SIZE_SHRINK_CENTER" value="4" enum="SizeFlags">
+ <constant name="SIZE_SHRINK_CENTER" value="4" enum="SizeFlags" is_bitfield="true">
Tells the parent [Container] to center the node in the available space. It is mutually exclusive with [constant SIZE_FILL] and other shrink size flags, but can be used with [constant SIZE_EXPAND] in some containers. Use with [member size_flags_horizontal] and [member size_flags_vertical].
</constant>
- <constant name="SIZE_SHRINK_END" value="8" enum="SizeFlags">
+ <constant name="SIZE_SHRINK_END" value="8" enum="SizeFlags" is_bitfield="true">
Tells the parent [Container] to align the node with its end, either the bottom or the right edge. It is mutually exclusive with [constant SIZE_FILL] and other shrink size flags, but can be used with [constant SIZE_EXPAND] in some containers. Use with [member size_flags_horizontal] and [member size_flags_vertical].
</constant>
<constant name="MOUSE_FILTER_STOP" value="0" enum="MouseFilter">
diff --git a/doc/classes/ConvexPolygonShape3D.xml b/doc/classes/ConvexPolygonShape3D.xml
index 32dc8f673b..66d2280280 100644
--- a/doc/classes/ConvexPolygonShape3D.xml
+++ b/doc/classes/ConvexPolygonShape3D.xml
@@ -4,7 +4,7 @@
Convex polygon shape resource for 3D physics.
</brief_description>
<description>
- 3D convex polygon shape resource to be added as a [i]direct[/i] child of a [PhysicsBody3D] or [Area3D] using a [CollisionShape3D] node. Unlike [ConcavePolygonShape3D], [ConvexPolygonShape3D] cannot store concave polygon shapes. [ConvexPolygonShape2D]s can be manually drawn in the editor using the [CollisionPolygon3D] node.
+ 3D convex polygon shape resource to be added as a [i]direct[/i] child of a [PhysicsBody3D] or [Area3D] using a [CollisionShape3D] node. Unlike [ConcavePolygonShape3D], [ConvexPolygonShape3D] cannot store concave polygon shapes. [ConvexPolygonShape3D]s can be manually drawn in the editor using the [CollisionPolygon3D] node.
[b]Convex decomposition:[/b] Concave objects' collisions can be represented accurately using [i]several[/i] [ConvexPolygonShape3D]s. This allows dynamic physics bodies to have complex concave collisions (at a performance cost). This is available in the editor by selecting the [MeshInstance3D], going to the [b]Mesh[/b] menu and choosing [b]Create Multiple Convex Collision Siblings[/b]. Alternatively, [method MeshInstance3D.create_multiple_convex_collisions] can be called in a script to perform this decomposition at run-time.
[b]Performance:[/b] [ConvexPolygonShape3D] is faster to check collisions against compared to [ConcavePolygonShape3D], but it is slower than primitive collision shapes such as [SphereShape3D] or [BoxShape3D]. Its use should generally be limited to medium-sized objects that cannot have their collision accurately represented by a primitive shape.
</description>
diff --git a/doc/classes/Crypto.xml b/doc/classes/Crypto.xml
index ade63225dc..a7e7e756c6 100644
--- a/doc/classes/Crypto.xml
+++ b/doc/classes/Crypto.xml
@@ -9,9 +9,11 @@
[codeblocks]
[gdscript]
extends Node
+
var crypto = Crypto.new()
var key = CryptoKey.new()
var cert = X509Certificate.new()
+
func _ready():
# Generate new RSA key.
key = crypto.generate_rsa(4096)
@@ -35,35 +37,35 @@
[/gdscript]
[csharp]
using Godot;
- using System;
using System.Diagnostics;
- public class CryptoNode : Node
+ public partial class MyNode : Node
{
- public Crypto Crypto = new Crypto();
- public CryptoKey Key = new CryptoKey();
- public X509Certificate Cert = new X509Certificate();
+ private Crypto _crypto = new Crypto();
+ private CryptoKey _key = new CryptoKey();
+ private X509Certificate _cert = new X509Certificate();
+
public override void _Ready()
{
// Generate new RSA key.
- Key = Crypto.GenerateRsa(4096);
+ _key = _crypto.GenerateRsa(4096);
// Generate new self-signed certificate with the given key.
- Cert = Crypto.GenerateSelfSignedCertificate(Key, "CN=mydomain.com,O=My Game Company,C=IT");
+ _cert = _crypto.GenerateSelfSignedCertificate(_key, "CN=mydomain.com,O=My Game Company,C=IT");
// Save key and certificate in the user folder.
- Key.Save("user://generated.key");
- Cert.Save("user://generated.crt");
+ _key.Save("user://generated.key");
+ _cert.Save("user://generated.crt");
// Encryption
string data = "Some data";
- byte[] encrypted = Crypto.Encrypt(Key, data.ToUTF8());
+ byte[] encrypted = _crypto.Encrypt(_key, data.ToUtf8());
// Decryption
- byte[] decrypted = Crypto.Decrypt(Key, encrypted);
+ byte[] decrypted = _crypto.Decrypt(_key, encrypted);
// Signing
- byte[] signature = Crypto.Sign(HashingContext.HashType.Sha256, Data.SHA256Buffer(), Key);
+ byte[] signature = _crypto.Sign(HashingContext.HashType.Sha256, Data.Sha256Buffer(), _key);
// Verifying
- bool verified = Crypto.Verify(HashingContext.HashType.Sha256, Data.SHA256Buffer(), signature, Key);
+ bool verified = _crypto.Verify(HashingContext.HashType.Sha256, Data.Sha256Buffer(), signature, _key);
// Checks
Debug.Assert(verified);
- Debug.Assert(data.ToUTF8() == decrypted);
+ Debug.Assert(data.ToUtf8() == decrypted);
}
}
[/csharp]
diff --git a/doc/classes/Cubemap.xml b/doc/classes/Cubemap.xml
index 46ddede9b1..01ec4c40d7 100644
--- a/doc/classes/Cubemap.xml
+++ b/doc/classes/Cubemap.xml
@@ -11,4 +11,12 @@
</description>
<tutorials>
</tutorials>
+ <methods>
+ <method name="create_placeholder" qualifiers="const">
+ <return type="Resource" />
+ <description>
+ Creates a placeholder version of this resource ([PlaceholderCubemap]).
+ </description>
+ </method>
+ </methods>
</class>
diff --git a/doc/classes/CubemapArray.xml b/doc/classes/CubemapArray.xml
index 2fd55b66c6..1b410671c1 100644
--- a/doc/classes/CubemapArray.xml
+++ b/doc/classes/CubemapArray.xml
@@ -12,4 +12,12 @@
</description>
<tutorials>
</tutorials>
+ <methods>
+ <method name="create_placeholder" qualifiers="const">
+ <return type="Resource" />
+ <description>
+ Creates a placeholder version of this resource ([PlaceholderCubemapArray]).
+ </description>
+ </method>
+ </methods>
</class>
diff --git a/doc/classes/Curve2D.xml b/doc/classes/Curve2D.xml
index b5e75dff68..fe597d0955 100644
--- a/doc/classes/Curve2D.xml
+++ b/doc/classes/Curve2D.xml
@@ -162,6 +162,8 @@
<param index="0" name="max_stages" type="int" default="5" />
<param index="1" name="tolerance_length" type="float" default="20.0" />
<description>
+ Returns a list of points along the curve, with almost uniform density. [param max_stages] controls how many subdivisions a curve segment may face before it is considered approximate enough. Each subdivision splits the segment in half, so the default 5 stages may mean up to 32 subdivisions per curve segment. Increase with care!
+ [param tolerance_length] controls the maximal distance between two neighboring points, before the segment has to be subdivided.
</description>
</method>
</methods>
diff --git a/doc/classes/Curve3D.xml b/doc/classes/Curve3D.xml
index 362d792b39..72ac95a700 100644
--- a/doc/classes/Curve3D.xml
+++ b/doc/classes/Curve3D.xml
@@ -198,7 +198,7 @@
<param index="1" name="tolerance_length" type="float" default="0.2" />
<description>
Returns a list of points along the curve, with almost uniform density. [param max_stages] controls how many subdivisions a curve segment may face before it is considered approximate enough. Each subdivision splits the segment in half, so the default 5 stages may mean up to 32 subdivisions per curve segment. Increase with care!
- [param tolerance_length] controls the maximal distance between two neighbouring points, before the segment has to be subdivided.
+ [param tolerance_length] controls the maximal distance between two neighboring points, before the segment has to be subdivided.
</description>
</method>
</methods>
diff --git a/doc/classes/DTLSServer.xml b/doc/classes/DTLSServer.xml
index 9af8be99ef..ae1ba10ec7 100644
--- a/doc/classes/DTLSServer.xml
+++ b/doc/classes/DTLSServer.xml
@@ -8,7 +8,7 @@
Below a small example of how to use it:
[codeblocks]
[gdscript]
- # ServerNode.gd
+ # server_node.gd
extends Node
var dtls := DTLSServer.new()
@@ -38,45 +38,46 @@
p.put_packet("Hello DTLS client".to_utf8())
[/gdscript]
[csharp]
- using Godot;
- using System;
// ServerNode.cs
- public class ServerNode : Node
+ using Godot;
+
+ public partial class ServerNode : Node
{
- public DTLSServer Dtls = new DTLSServer();
- public UDPServer Server = new UDPServer();
- public Godot.Collections.Array&lt;PacketPeerDTLS&gt; Peers = new Godot.Collections.Array&lt;PacketPeerDTLS&gt;();
+ private DtlsServer _dtls = new DtlsServer();
+ private UdpServer _server = new UdpServer();
+ private Godot.Collections.Array&lt;PacketPeerDTLS&gt; _peers = new Godot.Collections.Array&lt;PacketPeerDTLS&gt;();
+
public override void _Ready()
{
- Server.Listen(4242);
+ _server.Listen(4242);
var key = GD.Load&lt;CryptoKey&gt;("key.key"); // Your private key.
var cert = GD.Load&lt;X509Certificate&gt;("cert.crt"); // Your X509 certificate.
- Dtls.Setup(key, cert);
+ _dtls.Setup(key, cert);
}
- public override void _Process(float delta)
+ public override void _Process(double delta)
{
while (Server.IsConnectionAvailable())
{
- PacketPeerUDP peer = Server.TakeConnection();
- PacketPeerDTLS dtlsPeer = Dtls.TakeConnection(peer);
- if (dtlsPeer.GetStatus() != PacketPeerDTLS.Status.Handshaking)
+ PacketPeerUDP peer = _server.TakeConnection();
+ PacketPeerDTLS dtlsPeer = _dtls.TakeConnection(peer);
+ if (dtlsPeer.GetStatus() != PacketPeerDtls.Status.Handshaking)
{
continue; // It is normal that 50% of the connections fails due to cookie exchange.
}
GD.Print("Peer connected!");
- Peers.Add(dtlsPeer);
+ _peers.Add(dtlsPeer);
}
- foreach (var p in Peers)
+ foreach (var p in _peers)
{
p.Poll(); // Must poll to update the state.
- if (p.GetStatus() == PacketPeerDTLS.Status.Connected)
+ if (p.GetStatus() == PacketPeerDtls.Status.Connected)
{
while (p.GetAvailablePacketCount() &gt; 0)
{
- GD.Print("Received Message From Client: " + p.GetPacket().GetStringFromUTF8());
- p.PutPacket("Hello Dtls Client".ToUTF8());
+ GD.Print($"Received Message From Client: {p.GetPacket().GetStringFromUtf8()}");
+ p.PutPacket("Hello DTLS Client".ToUtf8());
}
}
}
@@ -86,7 +87,7 @@
[/codeblocks]
[codeblocks]
[gdscript]
- # ClientNode.gd
+ # client_node.gd
extends Node
var dtls := PacketPeerDTLS.new()
@@ -108,34 +109,36 @@
connected = true
[/gdscript]
[csharp]
+ // ClientNode.cs
using Godot;
using System.Text;
- // ClientNode.cs
- public class ClientNode : Node
+
+ public partial class ClientNode : Node
{
- public PacketPeerDTLS Dtls = new PacketPeerDTLS();
- public PacketPeerUDP Udp = new PacketPeerUDP();
- public bool Connected = false;
+ private PacketPeerDtls _dtls = new PacketPeerDtls();
+ private PacketPeerUdp _udp = new PacketPeerUdp();
+ private bool _connected = false;
+
public override void _Ready()
{
- Udp.ConnectToHost("127.0.0.1", 4242);
- Dtls.ConnectToPeer(Udp, false); // Use true in production for certificate validation!
+ _udp.ConnectToHost("127.0.0.1", 4242);
+ _dtls.ConnectToPeer(_udp, validateCerts: false); // Use true in production for certificate validation!
}
- public override void _Process(float delta)
+ public override void _Process(double delta)
{
- Dtls.Poll();
- if (Dtls.GetStatus() == PacketPeerDTLS.Status.Connected)
+ _dtls.Poll();
+ if (_dtls.GetStatus() == PacketPeerDtls.Status.Connected)
{
- if (!Connected)
+ if (!_connected)
{
// Try to contact server
- Dtls.PutPacket("The Answer Is..42!".ToUTF8());
+ _dtls.PutPacket("The Answer Is..42!".ToUtf8());
}
- while (Dtls.GetAvailablePacketCount() &gt; 0)
+ while (_dtls.GetAvailablePacketCount() &gt; 0)
{
- GD.Print("Connected: " + Dtls.GetPacket().GetStringFromUTF8());
- Connected = true;
+ GD.Print($"Connected: {_dtls.GetPacket().GetStringFromUtf8()}");
+ _connected = true;
}
}
}
@@ -148,11 +151,9 @@
<methods>
<method name="setup">
<return type="int" enum="Error" />
- <param index="0" name="key" type="CryptoKey" />
- <param index="1" name="certificate" type="X509Certificate" />
- <param index="2" name="chain" type="X509Certificate" default="null" />
+ <param index="0" name="server_options" type="TLSOptions" />
<description>
- Setup the DTLS server to use the given [param key] and provide the given [param certificate] to clients. You can pass the optional [param chain] parameter to provide additional CA chain information along with the certificate.
+ Setup the DTLS server to use the given [param server_options]. See [method TLSOptions.server].
</description>
</method>
<method name="take_connection">
diff --git a/doc/classes/Decal.xml b/doc/classes/Decal.xml
index b9d3f1d81e..fb8bc18c1a 100644
--- a/doc/classes/Decal.xml
+++ b/doc/classes/Decal.xml
@@ -75,9 +75,6 @@
<member name="emission_energy" type="float" setter="set_emission_energy" getter="get_emission_energy" default="1.0">
Energy multiplier for the emission texture. This will make the decal emit light at a higher or lower intensity, independently of the albedo color. See also [member modulate].
</member>
- <member name="extents" type="Vector3" setter="set_extents" getter="get_extents" default="Vector3(1, 1, 1)">
- Sets the size of the [AABB] used by the decal. The AABB goes from [code]-extents[/code] to [code]extents[/code].
- </member>
<member name="lower_fade" type="float" setter="set_lower_fade" getter="get_lower_fade" default="0.3">
Sets the curve over which the decal will fade as the surface gets further from the center of the [AABB]. Only positive values are valid (negative values will be clamped to [code]0.0[/code]). See also [member upper_fade].
</member>
@@ -88,6 +85,9 @@
Fades the Decal if the angle between the Decal's [AABB] and the target surface becomes too large. A value of [code]0[/code] projects the Decal regardless of angle, a value of [code]1[/code] limits the Decal to surfaces that are nearly perpendicular.
[b]Note:[/b] Setting [member normal_fade] to a value greater than [code]0.0[/code] has a small performance cost due to the added normal angle computations.
</member>
+ <member name="size" type="Vector3" setter="set_size" getter="get_size" default="Vector3(2, 2, 2)">
+ Sets the size of the [AABB] used by the decal. The AABB goes from [code]-size/2[/code] to [code]size/2[/code].
+ </member>
<member name="texture_albedo" type="Texture2D" setter="set_texture" getter="get_texture">
[Texture2D] with the base [Color] of the Decal. Either this or the [member texture_emission] must be set for the Decal to be visible. Use the alpha channel like a mask to smoothly blend the edges of the decal with the underlying object.
[b]Note:[/b] Unlike [BaseMaterial3D] whose filter mode can be adjusted on a per-material basis, the filter mode for [Decal] textures is set globally with [member ProjectSettings.rendering/textures/decals/filter].
diff --git a/doc/classes/Dictionary.xml b/doc/classes/Dictionary.xml
index 5f99ba82b8..a5a50b4c6a 100644
--- a/doc/classes/Dictionary.xml
+++ b/doc/classes/Dictionary.xml
@@ -42,7 +42,7 @@
You can access a dictionary's value by referencing its corresponding key. In the above example, [code]points_dict["White"][/code] will return [code]50[/code]. You can also write [code]points_dict.White[/code], which is equivalent. However, you'll have to use the bracket syntax if the key you're accessing the dictionary with isn't a fixed string (such as a number or variable).
[codeblocks]
[gdscript]
- @export(String, "White", "Yellow", "Orange") var my_color
+ @export_enum("White", "Yellow", "Orange") var my_color: String
var points_dict = {"White": 50, "Yellow": 75, "Orange": 100}
func _ready():
# We can't use dot syntax here as `my_color` is a variable.
@@ -51,7 +51,7 @@
[csharp]
[Export(PropertyHint.Enum, "White,Yellow,Orange")]
public string MyColor { get; set; }
- public Godot.Collections.Dictionary pointsDict = new Godot.Collections.Dictionary
+ private Godot.Collections.Dictionary _pointsDict = new Godot.Collections.Dictionary
{
{"White", 50},
{"Yellow", 75},
@@ -60,7 +60,7 @@
public override void _Ready()
{
- int points = (int)pointsDict[MyColor];
+ int points = (int)_pointsDict[MyColor];
}
[/csharp]
[/codeblocks]
@@ -153,7 +153,7 @@
<return type="Dictionary" />
<param index="0" name="from" type="Dictionary" />
<description>
- Returns the same array as [param from]. If you need a copy of the array, use [method duplicate].
+ Returns the same dictionary as [param from]. If you need a copy of the dictionary, use [method duplicate].
</description>
</constructor>
</constructors>
@@ -271,12 +271,24 @@
Returns [code]true[/code] if the dictionary is empty (its size is [code]0[/code]). See also [method size].
</description>
</method>
+ <method name="is_read_only" qualifiers="const">
+ <return type="bool" />
+ <description>
+ Returns [code]true[/code] if the dictionary is read-only. See [method make_read_only]. Dictionaries are automatically read-only if declared with [code]const[/code] keyword.
+ </description>
+ </method>
<method name="keys" qualifiers="const">
<return type="Array" />
<description>
Returns the list of keys in the dictionary.
</description>
</method>
+ <method name="make_read_only">
+ <return type="void" />
+ <description>
+ Makes the dictionary read-only, i.e. disables modification of the dictionary's contents. Does not apply to nested content, e.g. content of nested dictionaries.
+ </description>
+ </method>
<method name="merge">
<return type="void" />
<param index="0" name="dictionary" type="Dictionary" />
diff --git a/doc/classes/DirAccess.xml b/doc/classes/DirAccess.xml
index 181d2eb485..27f2eb7f2f 100644
--- a/doc/classes/DirAccess.xml
+++ b/doc/classes/DirAccess.xml
@@ -44,11 +44,11 @@
{
if (dir.CurrentIsDir())
{
- GD.Print("Found directory: " + fileName);
+ GD.Print($"Found directory: {fileName}");
}
else
{
- GD.Print("Found file: " + fileName);
+ GD.Print($"Found file: {fileName}");
}
fileName = dir.GetNext();
}
diff --git a/doc/classes/DisplayServer.xml b/doc/classes/DisplayServer.xml
index 29135376c5..6f4a7fc13d 100644
--- a/doc/classes/DisplayServer.xml
+++ b/doc/classes/DisplayServer.xml
@@ -130,12 +130,25 @@
The names of built-in display servers are [code]Windows[/code], [code]macOS[/code], [code]X11[/code] (Linux), [code]Android[/code], [code]iOS[/code], [code]web[/code] (HTML5) and [code]headless[/code] (when started with the [code]--headless[/code] [url=$DOCS_URL/tutorials/editor/command_line_tutorial.html]command line argument[/url]).
</description>
</method>
+ <method name="get_primary_screen" qualifiers="const">
+ <return type="int" />
+ <description>
+ Returns index of the primary screen.
+ </description>
+ </method>
<method name="get_screen_count" qualifiers="const">
<return type="int" />
<description>
Returns the number of displays available.
</description>
</method>
+ <method name="get_screen_from_rect" qualifiers="const">
+ <return type="int" />
+ <param index="0" name="rect" type="Rect2" />
+ <description>
+ Returns index of the screen which contains specified rectangle.
+ </description>
+ </method>
<method name="get_swap_cancel_ok">
<return type="bool" />
<description>
@@ -177,6 +190,7 @@
<description>
Adds a new checkable item with text [param label] to the global menu with ID [param menu_root].
Returns index of the inserted item, it's not guaranteed to be the same as [param index] value.
+ [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented on macOS.
[b]Supported system menu IDs:[/b]
[codeblock]
@@ -198,6 +212,7 @@
<description>
Adds a new checkable item with text [param label] and icon [param icon] to the global menu with ID [param menu_root].
Returns index of the inserted item, it's not guaranteed to be the same as [param index] value.
+ [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented on macOS.
[b]Supported system menu IDs:[/b]
[codeblock]
@@ -219,6 +234,7 @@
<description>
Adds a new item with text [param label] and icon [param icon] to the global menu with ID [param menu_root].
Returns index of the inserted item, it's not guaranteed to be the same as [param index] value.
+ [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented on macOS.
[b]Supported system menu IDs:[/b]
[codeblock]
@@ -241,6 +257,7 @@
Adds a new radio-checkable item with text [param label] and icon [param icon] to the global menu with ID [param menu_root].
Returns index of the inserted item, it's not guaranteed to be the same as [param index] value.
[b]Note:[/b] Radio-checkable items just display a checkmark, but don't have any built-in checking behavior and must be checked/unchecked manually. See [method global_menu_set_item_checked] for more info on how to control it.
+ [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented on macOS.
[b]Supported system menu IDs:[/b]
[codeblock]
@@ -261,6 +278,7 @@
<description>
Adds a new item with text [param label] to the global menu with ID [param menu_root].
Returns index of the inserted item, it's not guaranteed to be the same as [param index] value.
+ [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented on macOS.
[b]Supported system menu IDs:[/b]
[codeblock]
@@ -272,7 +290,7 @@
<method name="global_menu_add_multistate_item">
<return type="int" />
<param index="0" name="menu_root" type="String" />
- <param index="1" name="labe" type="String" />
+ <param index="1" name="label" type="String" />
<param index="2" name="max_states" type="int" />
<param index="3" name="default_state" type="int" />
<param index="4" name="callback" type="Callable" />
@@ -281,10 +299,11 @@
<param index="7" name="accelerator" type="int" enum="Key" default="0" />
<param index="8" name="index" type="int" default="-1" />
<description>
- Adds a new item with text [param labe] to the global menu with ID [param menu_root].
+ Adds a new item with text [param label] to the global menu with ID [param menu_root].
Contrarily to normal binary items, multistate items can have more than two states, as defined by [param max_states]. Each press or activate of the item will increase the state by one. The default value is defined by [param default_state].
Returns index of the inserted item, it's not guaranteed to be the same as [param index] value.
[b]Note:[/b] By default, there's no indication of the current item state, it should be changed manually.
+ [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented on macOS.
[b]Supported system menu IDs:[/b]
[codeblock]
@@ -306,6 +325,7 @@
Adds a new radio-checkable item with text [param label] to the global menu with ID [param menu_root].
Returns index of the inserted item, it's not guaranteed to be the same as [param index] value.
[b]Note:[/b] Radio-checkable items just display a checkmark, but don't have any built-in checking behavior and must be checked/unchecked manually. See [method global_menu_set_item_checked] for more info on how to control it.
+ [b]Note:[/b] The [param callback] and [param key_callback] Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to [param tag].
[b]Note:[/b] This method is implemented on macOS.
[b]Supported system menu IDs:[/b]
[codeblock]
@@ -549,6 +569,7 @@
<param index="2" name="callback" type="Callable" />
<description>
Sets the callback of the item at index [param idx]. Callback is emitted when an item is pressed.
+ [b]Note:[/b] The [param callback] Callable needs to accept exactly one Variant parameter, the parameter passed to the Callable will be the value passed to the tag parameter when the menu item was created.
[b]Note:[/b] This method is implemented on macOS.
</description>
</method>
@@ -610,6 +631,7 @@
<param index="2" name="key_callback" type="Callable" />
<description>
Sets the callback of the item at index [param idx]. Callback is emitted when its accelerator is activated.
+ [b]Note:[/b] The [param key_callback] Callable needs to accept exactly one Variant parameter, the parameter passed to the Callable will be the value passed to the tag parameter when the menu item was created.
[b]Note:[/b] This method is implemented on macOS.
</description>
</method>
@@ -772,7 +794,7 @@
</description>
</method>
<method name="mouse_get_button_state" qualifiers="const">
- <return type="int" enum="MouseButton" />
+ <return type="int" enum="MouseButtonMask" />
<description>
Returns the current state of mouse buttons (whether each button is pressed) as a bitmask. If multiple mouse buttons are pressed at the same time, the bits are added together. Equivalent to [method Input.get_mouse_button_mask].
</description>
@@ -1077,6 +1099,7 @@
<param index="0" name="position" type="Vector2i" />
<description>
Sets the mouse cursor position to the given [param position] relative to an origin at the upper left corner of the currently focused game Window Manager window.
+ [b]Note:[/b] [method warp_mouse] is only supported on Windows, macOS and Linux. It has no effect on Android, iOS and Web.
</description>
</method>
<method name="window_can_draw" qualifiers="const">
@@ -1421,9 +1444,9 @@
<param index="0" name="vsync_mode" type="int" enum="DisplayServer.VSyncMode" />
<param index="1" name="window_id" type="int" default="0" />
<description>
- Sets the V-Sync mode of the given window.
+ Sets the V-Sync mode of the given window. See also [member ProjectSettings.display/window/vsync/vsync_mode].
See [enum DisplayServer.VSyncMode] for possible values and how they affect the behavior of your application.
- Depending on the platform and used renderer, the engine will fall back to [constant VSYNC_ENABLED], if the desired mode is not supported.
+ Depending on the platform and used renderer, the engine will fall back to [constant VSYNC_ENABLED] if the desired mode is not supported.
</description>
</method>
<method name="window_set_window_buttons_offset">
@@ -1512,7 +1535,7 @@
Makes the mouse cursor hidden if it is visible.
</constant>
<constant name="MOUSE_MODE_CAPTURED" value="2" enum="MouseMode">
- Captures the mouse. The mouse will be hidden and its position locked at the center of the screen.
+ Captures the mouse. The mouse will be hidden and its position locked at the center of the window manager's window.
[b]Note:[/b] If you want to process the mouse's movement in this mode, you need to use [member InputEventMouseMotion.relative].
</constant>
<constant name="MOUSE_MODE_CONFINED" value="3" enum="MouseMode">
@@ -1521,6 +1544,9 @@
<constant name="MOUSE_MODE_CONFINED_HIDDEN" value="4" enum="MouseMode">
Confines the mouse cursor to the game window, and make it hidden.
</constant>
+ <constant name="SCREEN_PRIMARY" value="-2">
+ Represents the primary screen.
+ </constant>
<constant name="SCREEN_OF_MAIN_WINDOW" value="-1">
Represents the screen where the main window is located. This is usually the default value in functions that allow specifying one of several screens.
</constant>
@@ -1678,7 +1704,10 @@
Use [method window_get_safe_title_margins] to determine area under the title bar that is not covered by decorations.
[b]Note:[/b] This flag is implemented on macOS.
</constant>
- <constant name="WINDOW_FLAG_MAX" value="7" enum="WindowFlags">
+ <constant name="WINDOW_FLAG_MOUSE_PASSTHROUGH" value="7" enum="WindowFlags">
+ All mouse events are passed to the underlying window of the same application.
+ </constant>
+ <constant name="WINDOW_FLAG_MAX" value="8" enum="WindowFlags">
Max value of the [enum WindowFlags].
</constant>
<constant name="WINDOW_EVENT_MOUSE_ENTER" value="0" enum="WindowEvent">
diff --git a/doc/classes/EditorCommandPalette.xml b/doc/classes/EditorCommandPalette.xml
index 380c79fc1a..448a622ae4 100644
--- a/doc/classes/EditorCommandPalette.xml
+++ b/doc/classes/EditorCommandPalette.xml
@@ -16,7 +16,7 @@
[csharp]
EditorCommandPalette commandPalette = GetEditorInterface().GetCommandPalette();
// ExternalCommand is a function that will be called with the command is executed.
- Callable commandCallable = new Callable(this, nameof(ExternalCommand));
+ Callable commandCallable = new Callable(this, MethodName.ExternalCommand);
commandPalette.AddCommand("command", "test/command", commandCallable)
[/csharp]
[/codeblocks]
diff --git a/doc/classes/EditorExportPlatform.xml b/doc/classes/EditorExportPlatform.xml
index 1d63af9233..f2b39ab134 100644
--- a/doc/classes/EditorExportPlatform.xml
+++ b/doc/classes/EditorExportPlatform.xml
@@ -1,8 +1,11 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="EditorExportPlatform" inherits="RefCounted" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ Identifies a supported export platform, and internally provides the functionality of exporting to that platform.
</brief_description>
<description>
+ Base resource that provides the functionality of exporting a release build of a project to a platform, from the editor. Stores platform-specific metadata such as the name and supported features of the platform, and performs the exporting of projects, PCK files, and ZIP files. Uses an export template for the platform provided at the time of project exporting.
+ Used in scripting by [EditorExportPlugin] to configure platform-specific customization of scenes and resources. See [method EditorExportPlugin._begin_customize_scenes] and [method EditorExportPlugin._begin_customize_resources] for more details.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/EditorFileSystem.xml b/doc/classes/EditorFileSystem.xml
index e8df6ae7fe..5f33c68a7d 100644
--- a/doc/classes/EditorFileSystem.xml
+++ b/doc/classes/EditorFileSystem.xml
@@ -71,12 +71,6 @@
This will not import the file. To reimport, call [method reimport_files] or [method scan] methods.
</description>
</method>
- <method name="update_script_classes">
- <return type="void" />
- <description>
- Scans the script files and updates the list of custom class names.
- </description>
- </method>
</methods>
<signals>
<signal name="filesystem_changed">
@@ -96,6 +90,11 @@
Emitted if at least one resource is reloaded when the filesystem is scanned.
</description>
</signal>
+ <signal name="script_classes_updated">
+ <description>
+ Emitted when the list of global script classes gets updated.
+ </description>
+ </signal>
<signal name="sources_changed">
<param index="0" name="exist" type="bool" />
<description>
diff --git a/doc/classes/EditorImportPlugin.xml b/doc/classes/EditorImportPlugin.xml
index c395815117..6a976d218f 100644
--- a/doc/classes/EditorImportPlugin.xml
+++ b/doc/classes/EditorImportPlugin.xml
@@ -37,8 +37,8 @@
return [{"name": "my_option", "default_value": false}]
func _import(source_file, save_path, options, platform_variants, gen_files):
- var file = File.new()
- if file.open(source_file, File.READ) != OK:
+ var file = FileAccess.open(source_file, FileAccess.READ)
+ if file == null:
return FAILED
var mesh = ArrayMesh.new()
# Fill the Mesh with data read in "file", left as an exercise to the reader.
@@ -48,61 +48,67 @@
[/gdscript]
[csharp]
using Godot;
- using System;
- public class MySpecialPlugin : EditorImportPlugin
+ public partial class MySpecialPlugin : EditorImportPlugin
{
- public override String GetImporterName()
+ public override string _GetImporterName()
{
return "my.special.plugin";
}
- public override String GetVisibleName()
+ public override string _GetVisibleName()
{
return "Special Mesh";
}
- public override Godot.Collections.Array GetRecognizedExtensions()
+ public override string[] _GetRecognizedExtensions()
{
- return new Godot.Collections.Array{"special", "spec"};
+ return new string[] { "special", "spec" };
}
- public override String GetSaveExtension()
+ public override string _GetSaveExtension()
{
return "mesh";
}
- public override String GetResourceType()
+ public override string _GetResourceType()
{
return "Mesh";
}
- public override int GetPresetCount()
+ public override int _GetPresetCount()
{
return 1;
}
- public override String GetPresetName(int i)
+ public override string _GetPresetName(int presetIndex)
{
return "Default";
}
- public override Godot.Collections.Array GetImportOptions(int i)
+ public override Godot.Collections.Array&lt;Godot.Collections.Dictionary&gt; _GetImportOptions(string path, int presetIndex)
{
- return new Godot.Collections.Array{new Godot.Collections.Dictionary{{"name", "myOption"}, {"defaultValue", false}}};
+ return new Godot.Collections.Array&lt;Godot.Collections.Dictionary&gt;
+ {
+ new Godot.Collections.Dictionary
+ {
+ { "name", "myOption" },
+ { "defaultValue", false },
+ }
+ };
}
- public override int Import(String sourceFile, String savePath, Godot.Collections.Dictionary options, Godot.Collections.Array platformVariants, Godot.Collections.Array genFiles)
+ public override int _Import(string sourceFile, string savePath, Godot.Collections.Dictionary options, Godot.Collections.Array&lt;string&gt; platformVariants, Godot.Collections.Array&lt;string&gt; genFiles)
{
- var file = new File();
- if (file.Open(sourceFile, File.ModeFlags.Read) != Error.Ok)
+ using var file = FileAccess.Open(sourceFile, FileAccess.ModeFlags.Read);
+ if (file.GetError() != Error.Ok)
{
return (int)Error.Failed;
}
var mesh = new ArrayMesh();
// Fill the Mesh with data read in "file", left as an exercise to the reader.
- String filename = savePath + "." + GetSaveExtension();
+ string filename = $"{savePath}.{_GetSaveExtension()}";
return (int)ResourceSaver.Save(mesh, filename);
}
}
@@ -210,7 +216,7 @@
</description>
</method>
<method name="_import" qualifiers="virtual const">
- <return type="int" />
+ <return type="int" enum="Error" />
<param index="0" name="source_file" type="String" />
<param index="1" name="save_path" type="String" />
<param index="2" name="options" type="Dictionary" />
diff --git a/doc/classes/EditorInspectorPlugin.xml b/doc/classes/EditorInspectorPlugin.xml
index ba2f7b24bf..7ffd7f9426 100644
--- a/doc/classes/EditorInspectorPlugin.xml
+++ b/doc/classes/EditorInspectorPlugin.xml
@@ -56,11 +56,11 @@
<method name="_parse_property" qualifiers="virtual">
<return type="bool" />
<param index="0" name="object" type="Object" />
- <param index="1" name="type" type="int" />
+ <param index="1" name="type" type="int" enum="Variant.Type" />
<param index="2" name="name" type="String" />
- <param index="3" name="hint_type" type="int" />
+ <param index="3" name="hint_type" type="int" enum="PropertyHint" />
<param index="4" name="hint_string" type="String" />
- <param index="5" name="usage_flags" type="int" />
+ <param index="5" name="usage_flags" type="int" enum="PropertyUsageFlags" />
<param index="6" name="wide" type="bool" />
<description>
Called to allow adding property-specific editors to the property list for [param object]. The added editor control must extend [EditorProperty]. Returning [code]true[/code] removes the built-in editor for this property, otherwise allows to insert a custom editor before the built-in one.
diff --git a/doc/classes/EditorPlugin.xml b/doc/classes/EditorPlugin.xml
index adcc87d062..f4b912de9e 100644
--- a/doc/classes/EditorPlugin.xml
+++ b/doc/classes/EditorPlugin.xml
@@ -41,6 +41,7 @@
<param index="0" name="object" type="Variant" />
<description>
This function is used for plugins that edit specific object types (nodes or resources). It requests the editor to edit the given object.
+ [param object] can be [code]null[/code] if the plugin was editing an object, but there is no longer any selected object handled by this plugin. It can be used to cleanup editing state.
</description>
</method>
<method name="_enable_plugin" qualifiers="virtual">
@@ -68,21 +69,22 @@
return EditorPlugin.AFTER_GUI_INPUT_PASS
[/gdscript]
[csharp]
- public override void _Forward3dDrawOverViewport(Godot.Control overlay)
+ public override void _Forward3DDrawOverViewport(Control viewportControl)
{
// Draw a circle at cursor position.
- overlay.DrawCircle(overlay.GetLocalMousePosition(), 64, Colors.White);
+ viewportControl.DrawCircle(viewportControl.GetLocalMousePosition(), 64, Colors.White);
}
- public override EditorPlugin.AfterGUIInput _Forward3dGuiInput(Godot.Camera3D camera, InputEvent @event)
+ public override EditorPlugin.AfterGuiInput _Forward3DGuiInput(Camera3D viewportCamera, InputEvent @event)
{
if (@event is InputEventMouseMotion)
{
// Redraw viewport when cursor is moved.
UpdateOverlays();
- return EditorPlugin.AFTER_GUI_INPUT_STOP;
+ return EditorPlugin.AfterGuiInput.Stop;
}
- return EditorPlugin.AFTER_GUI_INPUT_PASS;
+ return EditorPlugin.AfterGuiInput.Pass;
+ }
[/csharp]
[/codeblocks]
</description>
@@ -110,9 +112,9 @@
[/gdscript]
[csharp]
// Prevents the InputEvent from reaching other Editor classes.
- public override EditorPlugin.AfterGUIInput _Forward3dGuiInput(Camera3D camera, InputEvent @event)
+ public override EditorPlugin.AfterGuiInput _Forward3DGuiInput(Camera3D camera, InputEvent @event)
{
- return EditorPlugin.AFTER_GUI_INPUT_STOP;
+ return EditorPlugin.AfterGuiInput.Stop;
}
[/csharp]
[/codeblocks]
@@ -126,9 +128,9 @@
[/gdscript]
[csharp]
// Consumes InputEventMouseMotion and forwards other InputEvent types.
- public override EditorPlugin.AfterGUIInput _Forward3dGuiInput(Camera3D camera, InputEvent @event)
+ public override EditorPlugin.AfterGuiInput _Forward3DGuiInput(Camera3D camera, InputEvent @event)
{
- return @event is InputEventMouseMotion ? EditorPlugin.AFTER_GUI_INPUT_STOP : EditorPlugin.AFTER_GUI_INPUT_PASS;
+ return @event is InputEventMouseMotion ? EditorPlugin.AfterGuiInput.Stop : EditorPlugin.AfterGuiInput.Pass;
}
[/csharp]
[/codeblocks]
@@ -143,7 +145,7 @@
[gdscript]
func _forward_canvas_draw_over_viewport(overlay):
# Draw a circle at cursor position.
- overlay.draw_circle(overlay.get_local_mouse_position(), 64, Color.white)
+ overlay.draw_circle(overlay.get_local_mouse_position(), 64, Color.WHITE)
func _forward_canvas_gui_input(event):
if event is InputEventMouseMotion:
@@ -153,13 +155,13 @@
return false
[/gdscript]
[csharp]
- public override void ForwardCanvasDrawOverViewport(Godot.Control overlay)
+ public override void _ForwardCanvasDrawOverViewport(Control viewportControl)
{
// Draw a circle at cursor position.
- overlay.DrawCircle(overlay.GetLocalMousePosition(), 64, Colors.White);
+ viewportControl.DrawCircle(viewportControl.GetLocalMousePosition(), 64, Colors.White);
}
- public override bool ForwardCanvasGuiInput(InputEvent @event)
+ public override bool _ForwardCanvasGuiInput(InputEvent @event)
{
if (@event is InputEventMouseMotion)
{
@@ -168,6 +170,7 @@
return true;
}
return false;
+ }
[/csharp]
[/codeblocks]
</description>
@@ -212,12 +215,13 @@
[/gdscript]
[csharp]
// Consumes InputEventMouseMotion and forwards other InputEvent types.
- public override bool ForwardCanvasGuiInput(InputEvent @event)
+ public override bool _ForwardCanvasGuiInput(InputEvent @event)
{
- if (@event is InputEventMouseMotion) {
+ if (@event is InputEventMouseMotion)
+ {
return true;
}
- return false
+ return false;
}
[/csharp]
[/codeblocks]
@@ -244,7 +248,7 @@
return get_editor_interface().get_base_control().get_theme_icon("Node", "EditorIcons")
[/gdscript]
[csharp]
- public override Texture2D GetPluginIcon()
+ public override Texture2D _GetPluginIcon()
{
// You can use a custom icon:
return ResourceLoader.Load&lt;Texture2D&gt;("res://addons/my_plugin/my_plugin_icon.svg");
@@ -347,7 +351,7 @@
[codeblock]
func _set_state(data):
zoom = data.get("zoom", 1.0)
- preferred_color = data.get("my_color", Color.white)
+ preferred_color = data.get("my_color", Color.WHITE)
[/codeblock]
</description>
</method>
@@ -359,7 +363,7 @@
[codeblock]
func _set_window_layout(configuration):
$Window.position = configuration.get_value("MyPlugin", "window_position", Vector2())
- $Icon.modulate = configuration.get_value("MyPlugin", "icon_color", Color.white)
+ $Icon.modulate = configuration.get_value("MyPlugin", "icon_color", Color.WHITE)
[/codeblock]
</description>
</method>
@@ -408,6 +412,7 @@
<description>
Adds a custom type, which will appear in the list of nodes or resources. An icon can be optionally passed.
When a given node or resource is selected, the base type will be instantiated (e.g. "Node3D", "Control", "Resource"), then the script will be loaded and set to this object.
+ [b]Note:[/b] The base type is the base engine class which this type's class hierarchy inherits, not any custom type parent classes.
You can use the virtual method [method _handles] to check if your custom object is being edited by checking the script or using the [code]is[/code] keyword.
During run-time, this will be a simple object with a script so this function does not need to be called then.
[b]Note:[/b] Custom types added this way are not true classes. They are just a helper to create a node with specific script.
@@ -467,6 +472,14 @@
See [method add_inspector_plugin] for an example of how to register a plugin.
</description>
</method>
+ <method name="add_resource_conversion_plugin">
+ <return type="void" />
+ <param index="0" name="plugin" type="EditorResourceConversionPlugin" />
+ <description>
+ Registers a new [EditorResourceConversionPlugin]. Resource conversion plugins are used to add custom resource converters to the editor inspector.
+ See [EditorResourceConversionPlugin] for an example of how to create a resource conversion plugin.
+ </description>
+ </method>
<method name="add_scene_format_importer_plugin">
<return type="void" />
<param index="0" name="scene_format_importer" type="EditorSceneFormatImporter" />
@@ -632,6 +645,13 @@
Removes a gizmo plugin registered by [method add_node_3d_gizmo_plugin].
</description>
</method>
+ <method name="remove_resource_conversion_plugin">
+ <return type="void" />
+ <param index="0" name="plugin" type="EditorResourceConversionPlugin" />
+ <description>
+ Removes a resource conversion plugin registered by [method add_resource_conversion_plugin].
+ </description>
+ </method>
<method name="remove_scene_format_importer_plugin">
<return type="void" />
<param index="0" name="scene_format_importer" type="EditorSceneFormatImporter" />
@@ -664,7 +684,7 @@
<return type="void" />
<param index="0" name="callable" type="Callable" />
<description>
- Removes a callback previsously added by [method add_undo_redo_inspector_hook_callback].
+ Removes a callback previously added by [method add_undo_redo_inspector_hook_callback].
</description>
</method>
<method name="set_force_draw_over_forwarding_enabled">
diff --git a/doc/classes/EditorResourceConversionPlugin.xml b/doc/classes/EditorResourceConversionPlugin.xml
index c40bb1d91e..6bdfbbe40c 100644
--- a/doc/classes/EditorResourceConversionPlugin.xml
+++ b/doc/classes/EditorResourceConversionPlugin.xml
@@ -1,8 +1,28 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="EditorResourceConversionPlugin" inherits="RefCounted" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ Plugin for adding custom converters from one resource format to another in the editor resource picker context menu; for example, converting a [StandardMaterial3D] to a [ShaderMaterial].
</brief_description>
<description>
+ [EditorResourceConversionPlugin] is invoked when the context menu is brought up for a resource in the editor inspector. Relevant conversion plugins will appear as menu options to convert the given resource to a target type.
+ Below shows an example of a basic plugin that will convert an [ImageTexture] to a [PortableCompressedTexture2D].
+ [codeblocks]
+ [gdscript]
+ extends EditorResourceConversionPlugin
+
+ func _handles(resource : Resource):
+ return resource is ImageTexture
+
+ func _converts_to():
+ return "PortableCompressedTexture2D"
+
+ func _convert(itex : Resource):
+ var ptex = PortableCompressedTexture2D.new()
+ ptex.create_from_image(itex.get_image(), PortableCompressedTexture2D.COMPRESSION_MODE_LOSSLESS)
+ return ptex
+ [/gdscript]
+ [/codeblocks]
+ To use an [EditorResourceConversionPlugin], register it using the [method EditorPlugin.add_resource_conversion_plugin] method first.
</description>
<tutorials>
</tutorials>
@@ -11,17 +31,20 @@
<return type="Resource" />
<param index="0" name="resource" type="Resource" />
<description>
+ Takes an input [Resource] and converts it to the type given in [method _converts_to]. The returned [Resource] is the result of the conversion, and the input [Resource] remains unchanged.
</description>
</method>
<method name="_converts_to" qualifiers="virtual const">
<return type="String" />
<description>
+ Returns the class name of the target type of [Resource] that this plugin converts source resources to.
</description>
</method>
<method name="_handles" qualifiers="virtual const">
<return type="bool" />
<param index="0" name="resource" type="Resource" />
<description>
+ Called to determine whether a particular [Resource] can be converted to the target resource type by this plugin.
</description>
</method>
</methods>
diff --git a/doc/classes/EditorScenePostImport.xml b/doc/classes/EditorScenePostImport.xml
index d2ad8d1bed..44bc72ea49 100644
--- a/doc/classes/EditorScenePostImport.xml
+++ b/doc/classes/EditorScenePostImport.xml
@@ -10,12 +10,14 @@
[gdscript]
@tool # Needed so it runs in editor.
extends EditorScenePostImport
+
# This sample changes all node names.
# Called right after the scene is imported and gets the root node.
func _post_import(scene):
# Change all node names to "modified_[oldnodename]"
iterate(scene)
return scene # Remember to return the imported scene
+
func iterate(node):
if node != null:
node.name = "modified_" + node.name
@@ -30,17 +32,18 @@
[Tool]
public partial class NodeRenamer : EditorScenePostImport
{
- public override Object _PostImport(Node scene)
+ public override GodotObject _PostImport(Node scene)
{
// Change all node names to "modified_[oldnodename]"
Iterate(scene);
return scene; // Remember to return the imported scene
}
+
public void Iterate(Node node)
{
if (node != null)
{
- node.Name = "modified_" + node.Name;
+ node.Name = $"modified_{node.Name}";
foreach (Node child in node.GetChildren())
{
Iterate(child);
diff --git a/doc/classes/EditorScript.xml b/doc/classes/EditorScript.xml
index a02fd215d8..33d2f40d0b 100644
--- a/doc/classes/EditorScript.xml
+++ b/doc/classes/EditorScript.xml
@@ -17,10 +17,9 @@
[/gdscript]
[csharp]
using Godot;
- using System;
[Tool]
- public class HelloEditor : EditorScript
+ public partial class HelloEditor : EditorScript
{
public override void _Run()
{
diff --git a/doc/classes/EditorSettings.xml b/doc/classes/EditorSettings.xml
index 98f4789163..1bf8cbf175 100644
--- a/doc/classes/EditorSettings.xml
+++ b/doc/classes/EditorSettings.xml
@@ -22,7 +22,7 @@
settings.SetSetting("some/property", Value);
// `settings.get("some/property", value)` also works as this class overrides `_get()` internally.
settings.GetSetting("some/property");
- Godot.Collections.Array listOfSettings = settings.GetPropertyList();
+ Godot.Collections.Array&lt;Godot.Collections.Dictionary&gt; listOfSettings = settings.GetPropertyList();
[/csharp]
[/codeblocks]
[b]Note:[/b] This class shouldn't be instantiated directly. Instead, access the singleton using [method EditorInterface.get_editor_settings].
@@ -433,12 +433,24 @@
The size to use for port previews in the visual shader uniforms (toggled by clicking the "eye" icon next to an output). The value is defined in pixels at 100% zoom, and will scale with zoom automatically.
</member>
<member name="filesystem/directories/autoscan_project_path" type="String" setter="" getter="">
- The folder where projects should be scanned for (recursively), in a way similar to the project manager's [b]Scan[/b]button. This can be set to the same value as [member filesystem/directories/default_project_path] for convenience.
+ The folder where projects should be scanned for (recursively), in a way similar to the project manager's [b]Scan[/b] button. This can be set to the same value as [member filesystem/directories/default_project_path] for convenience.
[b]Note:[/b] Setting this path to a folder with very large amounts of files/folders can slow down the project manager startup significantly. To keep the project manager quick to start up, it is recommended to set this value to a folder as "specific" as possible.
</member>
<member name="filesystem/directories/default_project_path" type="String" setter="" getter="">
The folder where new projects should be created by default when clicking the project manager's [b]New Project[/b] button. This can be set to the same value as [member filesystem/directories/autoscan_project_path] for convenience.
</member>
+ <member name="filesystem/external_programs/3d_model_editor" type="String" setter="" getter="">
+ The program that opens 3D model scene files when clicking "Open in External Program" option in Filesystem Dock. If not specified, the file will be opened in the system's default program.
+ </member>
+ <member name="filesystem/external_programs/audio_editor" type="String" setter="" getter="">
+ The program that opens audio files when clicking "Open in External Program" option in Filesystem Dock. If not specified, the file will be opened in the system's default program.
+ </member>
+ <member name="filesystem/external_programs/raster_image_editor" type="String" setter="" getter="">
+ The program that opens raster image files when clicking "Open in External Program" option in Filesystem Dock. If not specified, the file will be opened in the system's default program.
+ </member>
+ <member name="filesystem/external_programs/vector_image_editor" type="String" setter="" getter="">
+ The program that opens vector image files when clicking "Open in External Program" option in Filesystem Dock. If not specified, the file will be opened in the system's default program.
+ </member>
<member name="filesystem/file_dialog/display_mode" type="int" setter="" getter="">
The display mode to use in the editor's file dialogs.
- [b]Thumbnails[/b] takes more space, but displays dynamic resource thumbnails, making resources easier to preview without having to open them.
@@ -499,7 +511,7 @@
</member>
<member name="interface/editor/editor_language" type="String" setter="" getter="">
The language to use for the editor interface.
- Translations are provided by the community. If you spot a mistake, [url=https://docs.godotengine.org/en/latest/community/contributing/editor_and_docs_localization.html]contribute to editor translations on Weblate![/url]
+ Translations are provided by the community. If you spot a mistake, [url=$DOCS_URL/contributing/documentation/editor_and_docs_localization.html]contribute to editor translations on Weblate![/url]
</member>
<member name="interface/editor/expand_to_title" type="bool" setter="" getter="">
Expanding main editor window content to the title, if supported by [DisplayServer]. See [constant DisplayServer.WINDOW_FLAG_EXTEND_TO_TITLE].
@@ -595,6 +607,10 @@
<member name="interface/theme/draw_extra_borders" type="bool" setter="" getter="">
If [code]true[/code], draws additional borders around interactive UI elements in the editor. This is automatically enabled when using the [b]Black (OLED)[/b] theme preset, as this theme preset uses a fully black background.
</member>
+ <member name="interface/theme/enable_touchscreen_touch_area" type="bool" setter="" getter="">
+ If [code]true[/code], increases the touch area for the UI elements to improve usability on touchscreen devices.
+ [b]Note:[/b] Defaults to [code]true[/code] on touchscreen devices.
+ </member>
<member name="interface/theme/icon_and_font_color" type="int" setter="" getter="">
The icon and font color scheme to use in the editor.
- [b]Auto[/b] determines the color scheme to use automatically based on [member interface/theme/base_color].
@@ -741,7 +757,7 @@
</member>
<member name="text_editor/behavior/indent/type" type="int" setter="" getter="">
The indentation style to use (tabs or spaces).
- [b]Note:[/b] The [url=https://docs.godotengine.org/en/latest/getting_started/scripting/gdscript/gdscript_styleguide.html]GDScript style guide[/url] recommends using tabs for indentation. It is advised to change this setting only if you need to work on a project that currently uses spaces for indentation.
+ [b]Note:[/b] The [url=$DOCS_URL/getting_started/scripting/gdscript/gdscript_styleguide.html]GDScript style guide[/url] recommends using tabs for indentation. It is advised to change this setting only if you need to work on a project that currently uses spaces for indentation.
</member>
<member name="text_editor/behavior/navigation/drag_and_drop_selection" type="bool" setter="" getter="">
If [code]true[/code], allows drag-and-dropping text in the script editor to move text. Disable this if you find yourself accidentally drag-and-dropping text in the script editor.
@@ -782,7 +798,7 @@
If [code]true[/code], the code completion tooltip will appear below the current line unless there is no space on screen below the current line. If [code]false[/code], the code completion tooltip will appear above the current line.
</member>
<member name="text_editor/completion/use_single_quotes" type="bool" setter="" getter="">
- If [code]true[/code], performs string autocompletion with single quotes. If [code]false[/code], performs string autocompletion with double quotes (which matches the [url=https://docs.godotengine.org/en/latest/tutorials/scripting/gdscript/gdscript_styleguide.html]GDScript style guide[/url]).
+ If [code]true[/code], performs string autocompletion with single quotes. If [code]false[/code], performs string autocompletion with double quotes (which matches the [url=$DOCS_URL/tutorials/scripting/gdscript/gdscript_styleguide.html]GDScript style guide[/url]).
</member>
<member name="text_editor/help/class_reference_examples" type="int" setter="" getter="">
Controls which multi-line code blocks should be displayed in the editor help. This setting does not affect single-line code literals in the editor help.
diff --git a/doc/classes/EditorSpinSlider.xml b/doc/classes/EditorSpinSlider.xml
index de105b32e1..1aef79f6e5 100644
--- a/doc/classes/EditorSpinSlider.xml
+++ b/doc/classes/EditorSpinSlider.xml
@@ -22,10 +22,32 @@
<member name="read_only" type="bool" setter="set_read_only" getter="is_read_only" default="false">
If [code]true[/code], the slider can't be interacted with.
</member>
- <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" default="1" />
+ <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" enum="Control.SizeFlags" default="1" />
<member name="step" type="float" setter="set_step" getter="get_step" overrides="Range" default="1.0" />
<member name="suffix" type="String" setter="set_suffix" getter="get_suffix" default="&quot;&quot;">
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/EditorTranslationParserPlugin.xml b/doc/classes/EditorTranslationParserPlugin.xml
index df10c645ef..40b469de0a 100644
--- a/doc/classes/EditorTranslationParserPlugin.xml
+++ b/doc/classes/EditorTranslationParserPlugin.xml
@@ -15,8 +15,7 @@
extends EditorTranslationParserPlugin
func _parse_file(path, msgids, msgids_context_plural):
- var file = File.new()
- file.open(path, File.READ)
+ var file = FileAccess.open(path, FileAccess.READ)
var text = file.get_as_text()
var split_strs = text.split(",", false)
for s in split_strs:
@@ -28,27 +27,25 @@
[/gdscript]
[csharp]
using Godot;
- using System;
[Tool]
- public class CustomParser : EditorTranslationParserPlugin
+ public partial class CustomParser : EditorTranslationParserPlugin
{
- public override void ParseFile(string path, Godot.Collections.Array msgids, Godot.Collections.Array msgidsContextPlural)
+ public override void _ParseFile(string path, Godot.Collections.Array&lt;string&gt; msgids, Godot.Collections.Array&lt;Godot.Collections.Array&gt; msgidsContextPlural)
{
- var file = new File();
- file.Open(path, File.ModeFlags.Read);
+ using var file = FileAccess.Open(path, FileAccess.ModeFlags.Read);
string text = file.GetAsText();
- string[] splitStrs = text.Split(",", false);
- foreach (var s in splitStrs)
+ string[] splitStrs = text.Split(",", allowEmpty: false);
+ foreach (string s in splitStrs)
{
msgids.Add(s);
- //GD.Print("Extracted string: " + s)
+ //GD.Print($"Extracted string: {s}");
}
}
- public override Godot.Collections.Array GetRecognizedExtensions()
+ public override string[] _GetRecognizedExtensions()
{
- return new Godot.Collections.Array{"csv"};
+ return new string[] { "csv" };
}
}
[/csharp]
@@ -85,16 +82,16 @@
return ["gd"]
[/gdscript]
[csharp]
- public override void ParseFile(string path, Godot.Collections.Array msgids, Godot.Collections.Array msgidsContextPlural)
+ public override void _ParseFile(string path, Godot.Collections.Array&lt;string&gt; msgids, Godot.Collections.Array&lt;Godot.Collections.Array&gt; msgidsContextPlural)
{
var res = ResourceLoader.Load&lt;Script&gt;(path, "Script");
string text = res.SourceCode;
// Parsing logic.
}
- public override Godot.Collections.Array GetRecognizedExtensions()
+ public override string[] _GetRecognizedExtensions()
{
- return new Godot.Collections.Array{"gd"};
+ return new string[] { "gd" };
}
[/csharp]
[/codeblocks]
diff --git a/doc/classes/EditorUndoRedoManager.xml b/doc/classes/EditorUndoRedoManager.xml
index cd96e740e8..4d6938e6aa 100644
--- a/doc/classes/EditorUndoRedoManager.xml
+++ b/doc/classes/EditorUndoRedoManager.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="EditorUndoRedoManager" inherits="RefCounted" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="EditorUndoRedoManager" inherits="Object" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Manages undo history of scenes opened in the editor.
</brief_description>
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/Expression.xml b/doc/classes/Expression.xml
index 4670e0c382..fd5a921836 100644
--- a/doc/classes/Expression.xml
+++ b/doc/classes/Expression.xml
@@ -24,23 +24,23 @@
$LineEdit.text = str(result)
[/gdscript]
[csharp]
- public Expression expression = new Expression();
+ private Expression _expression = new Expression();
public override void _Ready()
{
- GetNode("LineEdit").TextSubmitted += OnTextEntered;
+ GetNode&lt;LineEdit&gt;("LineEdit").TextSubmitted += OnTextEntered;
}
private void OnTextEntered(string command)
{
- Error error = expression.Parse(command);
+ Error error = _expression.Parse(command);
if (error != Error.Ok)
{
- GD.Print(expression.GetErrorText());
+ GD.Print(_expression.GetErrorText());
return;
}
- object result = expression.Execute();
- if (!expression.HasExecuteFailed())
+ Variant result = _expression.Execute();
+ if (!_expression.HasExecuteFailed())
{
GetNode&lt;LineEdit&gt;("LineEdit").Text = result.ToString();
}
diff --git a/doc/classes/FileAccess.xml b/doc/classes/FileAccess.xml
index be0c8fd6ca..687a64b8ff 100644
--- a/doc/classes/FileAccess.xml
+++ b/doc/classes/FileAccess.xml
@@ -348,8 +348,8 @@
f.Seek(0); // Go back to start to read the stored value.
ushort read1 = f.Get16(); // 65494
ushort read2 = f.Get16(); // 121
- short converted1 = BitConverter.ToInt16(BitConverter.GetBytes(read1), 0); // -42
- short converted2 = BitConverter.ToInt16(BitConverter.GetBytes(read2), 0); // 121
+ short converted1 = (short)read1; // -42
+ short converted2 = (short)read2; // 121
}
[/csharp]
[/codeblocks]
diff --git a/doc/classes/FileSystemDock.xml b/doc/classes/FileSystemDock.xml
index 00f5c7ddff..f76bc2c279 100644
--- a/doc/classes/FileSystemDock.xml
+++ b/doc/classes/FileSystemDock.xml
@@ -51,5 +51,10 @@
<description>
</description>
</signal>
+ <signal name="resource_removed">
+ <param index="0" name="resource" type="Resource" />
+ <description>
+ </description>
+ </signal>
</signals>
</class>
diff --git a/doc/classes/FogVolume.xml b/doc/classes/FogVolume.xml
index d9fa2e6ebb..e2f9038be5 100644
--- a/doc/classes/FogVolume.xml
+++ b/doc/classes/FogVolume.xml
@@ -11,16 +11,16 @@
<tutorials>
</tutorials>
<members>
- <member name="extents" type="Vector3" setter="set_extents" getter="get_extents" default="Vector3(1, 1, 1)">
- The size of the [FogVolume] when [member shape] is [constant RenderingServer.FOG_VOLUME_SHAPE_ELLIPSOID], [constant RenderingServer.FOG_VOLUME_SHAPE_CONE], [constant RenderingServer.FOG_VOLUME_SHAPE_CYLINDER] or [constant RenderingServer.FOG_VOLUME_SHAPE_BOX].
- [b]Note:[/b] Thin fog volumes may appear to flicker when the camera moves or rotates. This can be alleviated by increasing [member ProjectSettings.rendering/environment/volumetric_fog/volume_depth] (at a performance cost) or by decreasing [member Environment.volumetric_fog_length] (at no performance cost, but at the cost of lower fog range). Alternatively, the [FogVolume] can be made thicker and use a lower density in the [member material].
- [b]Note:[/b] If [member shape] is [constant RenderingServer.FOG_VOLUME_SHAPE_CONE] or [constant RenderingServer.FOG_VOLUME_SHAPE_CYLINDER], the cone/cylinder will be adjusted to fit within the extents. Non-uniform scaling of cone/cylinder shapes via the [member extents] property is not supported, but you can scale the [FogVolume] node instead.
- </member>
<member name="material" type="Material" setter="set_material" getter="get_material">
The [Material] used by the [FogVolume]. Can be either a built-in [FogMaterial] or a custom [ShaderMaterial].
</member>
<member name="shape" type="int" setter="set_shape" getter="get_shape" enum="RenderingServer.FogVolumeShape" default="3">
The shape of the [FogVolume]. This can be set to either [constant RenderingServer.FOG_VOLUME_SHAPE_ELLIPSOID], [constant RenderingServer.FOG_VOLUME_SHAPE_CONE], [constant RenderingServer.FOG_VOLUME_SHAPE_CYLINDER], [constant RenderingServer.FOG_VOLUME_SHAPE_BOX] or [constant RenderingServer.FOG_VOLUME_SHAPE_WORLD].
</member>
+ <member name="size" type="Vector3" setter="set_size" getter="get_size" default="Vector3(2, 2, 2)">
+ The size of the [FogVolume] when [member shape] is [constant RenderingServer.FOG_VOLUME_SHAPE_ELLIPSOID], [constant RenderingServer.FOG_VOLUME_SHAPE_CONE], [constant RenderingServer.FOG_VOLUME_SHAPE_CYLINDER] or [constant RenderingServer.FOG_VOLUME_SHAPE_BOX].
+ [b]Note:[/b] Thin fog volumes may appear to flicker when the camera moves or rotates. This can be alleviated by increasing [member ProjectSettings.rendering/environment/volumetric_fog/volume_depth] (at a performance cost) or by decreasing [member Environment.volumetric_fog_length] (at no performance cost, but at the cost of lower fog range). Alternatively, the [FogVolume] can be made thicker and use a lower density in the [member material].
+ [b]Note:[/b] If [member shape] is [constant RenderingServer.FOG_VOLUME_SHAPE_CONE] or [constant RenderingServer.FOG_VOLUME_SHAPE_CYLINDER], the cone/cylinder will be adjusted to fit within the size. Non-uniform scaling of cone/cylinder shapes via the [member size] property is not supported, but you can scale the [FogVolume] node instead.
+ </member>
</members>
</class>
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/GPUParticles2D.xml b/doc/classes/GPUParticles2D.xml
index c7d10078e8..29779e4a77 100644
--- a/doc/classes/GPUParticles2D.xml
+++ b/doc/classes/GPUParticles2D.xml
@@ -5,7 +5,8 @@
</brief_description>
<description>
2D particle node used to create a variety of particle systems and effects. [GPUParticles2D] features an emitter that generates some number of particles at a given rate.
- Use the [code]process_material[/code] property to add a [ParticleProcessMaterial] to configure particle appearance and behavior. Alternatively, you can add a [ShaderMaterial] which will be applied to all particles.
+ Use the [member process_material] property to add a [ParticleProcessMaterial] to configure particle appearance and behavior. Alternatively, you can add a [ShaderMaterial] which will be applied to all particles.
+ 2D particles can optionally collide with [LightOccluder2D] nodes (note: they don't collide with [PhysicsBody2D] nodes).
</description>
<tutorials>
<link title="Particle systems (2D)">$DOCS_URL/tutorials/2d/particle_systems_2d.html</link>
@@ -42,6 +43,7 @@
Number of particles emitted in one emission cycle.
</member>
<member name="collision_base_size" type="float" setter="set_collision_base_size" getter="get_collision_base_size" default="1.0">
+ Multiplier for particle's collision radius. [code]1.0[/code] corresponds to the size of the sprite.
</member>
<member name="draw_order" type="int" setter="set_draw_order" getter="get_draw_order" enum="GPUParticles2D.DrawOrder" default="1">
Particle draw order. Uses [enum DrawOrder] values.
diff --git a/doc/classes/GPUParticlesAttractorBox3D.xml b/doc/classes/GPUParticlesAttractorBox3D.xml
index 6595428cc2..65a4c6d4a5 100644
--- a/doc/classes/GPUParticlesAttractorBox3D.xml
+++ b/doc/classes/GPUParticlesAttractorBox3D.xml
@@ -10,8 +10,8 @@
<tutorials>
</tutorials>
<members>
- <member name="extents" type="Vector3" setter="set_extents" getter="get_extents" default="Vector3(1, 1, 1)">
- The attractor box's extents in 3D units.
+ <member name="size" type="Vector3" setter="set_size" getter="get_size" default="Vector3(2, 2, 2)">
+ The attractor box's size in 3D units.
</member>
</members>
</class>
diff --git a/doc/classes/GPUParticlesAttractorVectorField3D.xml b/doc/classes/GPUParticlesAttractorVectorField3D.xml
index aeadfaf4ab..12e6774471 100644
--- a/doc/classes/GPUParticlesAttractorVectorField3D.xml
+++ b/doc/classes/GPUParticlesAttractorVectorField3D.xml
@@ -11,12 +11,12 @@
<tutorials>
</tutorials>
<members>
- <member name="extents" type="Vector3" setter="set_extents" getter="get_extents" default="Vector3(1, 1, 1)">
- The extents of the vector field box in 3D units.
+ <member name="size" type="Vector3" setter="set_size" getter="get_size" default="Vector3(2, 2, 2)">
+ The size of the vector field box in 3D units.
</member>
<member name="texture" type="Texture3D" setter="set_texture" getter="get_texture">
The 3D texture to be used. Values are linearly interpolated between the texture's pixels.
- [b]Note:[/b] To get better performance, the 3D texture's resolution should reflect the [member extents] of the attractor. Since particle attraction is usually low-frequency data, the texture can be kept at a low resolution such as 64×64×64.
+ [b]Note:[/b] To get better performance, the 3D texture's resolution should reflect the [member size] of the attractor. Since particle attraction is usually low-frequency data, the texture can be kept at a low resolution such as 64×64×64.
</member>
</members>
</class>
diff --git a/doc/classes/GPUParticlesCollisionBox3D.xml b/doc/classes/GPUParticlesCollisionBox3D.xml
index 103be18bfd..737db0ba8a 100644
--- a/doc/classes/GPUParticlesCollisionBox3D.xml
+++ b/doc/classes/GPUParticlesCollisionBox3D.xml
@@ -11,8 +11,8 @@
<tutorials>
</tutorials>
<members>
- <member name="extents" type="Vector3" setter="set_extents" getter="get_extents" default="Vector3(1, 1, 1)">
- The collision box's extents in 3D units.
+ <member name="size" type="Vector3" setter="set_size" getter="get_size" default="Vector3(2, 2, 2)">
+ The collision box's size in 3D units.
</member>
</members>
</class>
diff --git a/doc/classes/GPUParticlesCollisionHeightField3D.xml b/doc/classes/GPUParticlesCollisionHeightField3D.xml
index 6e996d5fbd..c8ed78b85e 100644
--- a/doc/classes/GPUParticlesCollisionHeightField3D.xml
+++ b/doc/classes/GPUParticlesCollisionHeightField3D.xml
@@ -13,9 +13,6 @@
<tutorials>
</tutorials>
<members>
- <member name="extents" type="Vector3" setter="set_extents" getter="get_extents" default="Vector3(1, 1, 1)">
- The collision heightmap's extents in 3D units. To improve heightmap quality, [member extents] should be set as small as possible while covering the parts of the scene you need.
- </member>
<member name="follow_camera_enabled" type="bool" setter="set_follow_camera_enabled" getter="is_follow_camera_enabled" default="false">
If [code]true[/code], the [GPUParticlesCollisionHeightField3D] will follow the current camera in global space. The [GPUParticlesCollisionHeightField3D] does not need to be a child of the [Camera3D] node for this to work.
Following the camera has a performance cost, as it will force the heightmap to update whenever the camera moves. Consider lowering [member resolution] to improve performance if [member follow_camera_enabled] is [code]true[/code].
@@ -23,6 +20,9 @@
<member name="resolution" type="int" setter="set_resolution" getter="get_resolution" enum="GPUParticlesCollisionHeightField3D.Resolution" default="2">
Higher resolutions can represent small details more accurately in large scenes, at the cost of lower performance. If [member update_mode] is [constant UPDATE_MODE_ALWAYS], consider using the lowest resolution possible.
</member>
+ <member name="size" type="Vector3" setter="set_size" getter="get_size" default="Vector3(2, 2, 2)">
+ The collision heightmap's size in 3D units. To improve heightmap quality, [member size] should be set as small as possible while covering the parts of the scene you need.
+ </member>
<member name="update_mode" type="int" setter="set_update_mode" getter="get_update_mode" enum="GPUParticlesCollisionHeightField3D.UpdateMode" default="0">
The update policy to use for the generated heightmap.
</member>
diff --git a/doc/classes/GPUParticlesCollisionSDF3D.xml b/doc/classes/GPUParticlesCollisionSDF3D.xml
index 8467cfdda1..dc4a4a2027 100644
--- a/doc/classes/GPUParticlesCollisionSDF3D.xml
+++ b/doc/classes/GPUParticlesCollisionSDF3D.xml
@@ -6,7 +6,7 @@
<description>
Baked signed distance field 3D particle attractor affecting [GPUParticles3D] nodes.
Signed distance fields (SDF) allow for efficiently representing approximate collision shapes for convex and concave objects of any shape. This is more flexible than [GPUParticlesCollisionHeightField3D], but it requires a baking step.
- [b]Baking:[/b] The signed distance field texture can be baked by selecting the [GPUParticlesCollisionSDF3D] node in the editor, then clicking [b]Bake SDF[/b] at the top of the 3D viewport. Any [i]visible[/i] [MeshInstance3D]s touching the [member extents] will be taken into account for baking, regardless of their [member GeometryInstance3D.gi_mode].
+ [b]Baking:[/b] The signed distance field texture can be baked by selecting the [GPUParticlesCollisionSDF3D] node in the editor, then clicking [b]Bake SDF[/b] at the top of the 3D viewport. Any [i]visible[/i] [MeshInstance3D]s within the [member size] will be taken into account for baking, regardless of their [member GeometryInstance3D.gi_mode].
[b]Note:[/b] Baking a [GPUParticlesCollisionSDF3D]'s [member texture] is only possible within the editor, as there is no bake method exposed for use in exported projects. However, it's still possible to load pre-baked [Texture3D]s into its [member texture] property in an exported project.
[b]Note:[/b] [member ParticleProcessMaterial.collision_mode] must be [constant ParticleProcessMaterial.COLLISION_RIGID] or [constant ParticleProcessMaterial.COLLISION_HIDE_ON_CONTACT] on the [GPUParticles3D]'s process material for collision to work.
[b]Note:[/b] Particle collision only affects [GPUParticles3D], not [CPUParticles3D].
@@ -34,12 +34,12 @@
<member name="bake_mask" type="int" setter="set_bake_mask" getter="get_bake_mask" default="4294967295">
The visual layers to account for when baking the particle collision SDF. Only [MeshInstance3D]s whose [member VisualInstance3D.layers] match with this [member bake_mask] will be included in the generated particle collision SDF. By default, all objects are taken into account for the particle collision SDF baking.
</member>
- <member name="extents" type="Vector3" setter="set_extents" getter="get_extents" default="Vector3(1, 1, 1)">
- The collision SDF's extents in 3D units. To improve SDF quality, the [member extents] should be set as small as possible while covering the parts of the scene you need.
- </member>
<member name="resolution" type="int" setter="set_resolution" getter="get_resolution" enum="GPUParticlesCollisionSDF3D.Resolution" default="2">
The bake resolution to use for the signed distance field [member texture]. The texture must be baked again for changes to the [member resolution] property to be effective. Higher resolutions have a greater performance cost and take more time to bake. Higher resolutions also result in larger baked textures, leading to increased VRAM and storage space requirements. To improve performance and reduce bake times, use the lowest resolution possible for the object you're representing the collision of.
</member>
+ <member name="size" type="Vector3" setter="set_size" getter="get_size" default="Vector3(2, 2, 2)">
+ The collision SDF's size in 3D units. To improve SDF quality, the [member size] should be set as small as possible while covering the parts of the scene you need.
+ </member>
<member name="texture" type="Texture3D" setter="set_texture" getter="get_texture">
The 3D texture representing the signed distance field.
</member>
diff --git a/doc/classes/Geometry2D.xml b/doc/classes/Geometry2D.xml
index 0142018f1a..f015026bc1 100644
--- a/doc/classes/Geometry2D.xml
+++ b/doc/classes/Geometry2D.xml
@@ -160,14 +160,13 @@
var polygon = PackedVector2Array([Vector2(0, 0), Vector2(100, 0), Vector2(100, 100), Vector2(0, 100)])
var offset = Vector2(50, 50)
polygon = Transform2D(0, offset) * polygon
- print(polygon) # prints [Vector2(50, 50), Vector2(150, 50), Vector2(150, 150), Vector2(50, 150)]
+ print(polygon) # prints [(50, 50), (150, 50), (150, 150), (50, 150)]
[/gdscript]
[csharp]
var polygon = new Vector2[] { new Vector2(0, 0), new Vector2(100, 0), new Vector2(100, 100), new Vector2(0, 100) };
var offset = new Vector2(50, 50);
- // TODO: This code is not valid right now. Ping @aaronfranke about it before Godot 4.0 is out.
- //polygon = (Vector2[]) new Transform2D(0, offset).Xform(polygon);
- //GD.Print(polygon); // prints [Vector2(50, 50), Vector2(150, 50), Vector2(150, 150), Vector2(50, 150)]
+ polygon = new Transform2D(0, offset) * polygon;
+ GD.Print((Variant)polygon); // prints [(50, 50), (150, 50), (150, 150), (50, 150)]
[/csharp]
[/codeblocks]
</description>
diff --git a/doc/classes/GeometryInstance3D.xml b/doc/classes/GeometryInstance3D.xml
index 90a983d28b..127c5daf95 100644
--- a/doc/classes/GeometryInstance3D.xml
+++ b/doc/classes/GeometryInstance3D.xml
@@ -16,19 +16,15 @@
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" />
<param index="1" name="value" type="Variant" />
<description>
- Set the value of a shader parameter for this instance only.
+ Set the value of a shader uniform for this instance only ([url=$DOCS_URL/tutorials/shaders/shader_reference/shading_language.html#per-instance-uniforms]per-instance uniform[/url]). See also [method ShaderMaterial.set_shader_parameter] to assign a uniform on all instances using the same [ShaderMaterial].
+ [b]Note:[/b] For a shader uniform to be assignable on a per-instance basis, it [i]must[/i] be defined with [code]instance uniform ...[/code] rather than [code]uniform ...[/code] in the shader code.
+ [b]Note:[/b] [param name] is case-sensitive and must match the name of the uniform in the code exactly (not the capitalized name in the inspector).
+ [b]Note:[/b] Per-instance shader uniforms are currently only available in 3D, so there is no 2D equivalent of this method.
</description>
</method>
</methods>
@@ -36,6 +32,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/GraphEdit.xml b/doc/classes/GraphEdit.xml
index ea4e4b53ba..490637374d 100644
--- a/doc/classes/GraphEdit.xml
+++ b/doc/classes/GraphEdit.xml
@@ -72,8 +72,9 @@
return from != to
[/gdscript]
[csharp]
- public override bool _IsNodeHoverValid(String from, int fromSlot, String to, int toSlot) {
- return from != to;
+ public override bool _IsNodeHoverValid(StringName fromNode, int fromPort, StringName toNode, int toPort)
+ {
+ return fromNode != toNode;
}
[/csharp]
[/codeblocks]
diff --git a/doc/classes/GraphNode.xml b/doc/classes/GraphNode.xml
index 16386ff81b..3f0080ac15 100644
--- a/doc/classes/GraphNode.xml
+++ b/doc/classes/GraphNode.xml
@@ -280,11 +280,6 @@
Emitted when the GraphNode is requested to be closed. Happens on clicking the close button (see [member show_close]).
</description>
</signal>
- <signal name="deselected">
- <description>
- Emitted when the GraphNode is deselected.
- </description>
- </signal>
<signal name="dragged">
<param index="0" name="from" type="Vector2" />
<param index="1" name="to" type="Vector2" />
@@ -292,6 +287,16 @@
Emitted when the GraphNode is dragged.
</description>
</signal>
+ <signal name="node_deselected">
+ <description>
+ Emitted when the GraphNode is deselected.
+ </description>
+ </signal>
+ <signal name="node_selected">
+ <description>
+ Emitted when the GraphNode is selected.
+ </description>
+ </signal>
<signal name="position_offset_changed">
<description>
Emitted when the GraphNode is moved.
@@ -308,11 +313,6 @@
Emitted when the GraphNode is requested to be resized. Happens on dragging the resizer handle (see [member resizable]).
</description>
</signal>
- <signal name="selected">
- <description>
- Emitted when the GraphNode is selected.
- </description>
- </signal>
<signal name="slot_updated">
<param index="0" name="idx" type="int" />
<description>
diff --git a/doc/classes/HMACContext.xml b/doc/classes/HMACContext.xml
index 706ee30963..fbdc6b5e64 100644
--- a/doc/classes/HMACContext.xml
+++ b/doc/classes/HMACContext.xml
@@ -26,25 +26,24 @@
[/gdscript]
[csharp]
using Godot;
- using System;
using System.Diagnostics;
- public class CryptoNode : Node
+ public partial class MyNode : Node
{
- private HMACContext ctx = new HMACContext();
+ private HmacContext _ctx = new HmacContext();
public override void _Ready()
{
- byte[] key = "supersecret".ToUTF8();
- Error err = ctx.Start(HashingContext.HashType.Sha256, key);
+ byte[] key = "supersecret".ToUtf8();
+ Error err = _ctx.Start(HashingContext.HashType.Sha256, key);
Debug.Assert(err == Error.Ok);
- byte[] msg1 = "this is ".ToUTF8();
- byte[] msg2 = "super duper secret".ToUTF8();
- err = ctx.Update(msg1);
+ byte[] msg1 = "this is ".ToUtf8();
+ byte[] msg2 = "super duper secret".ToUtf8();
+ err = _ctx.Update(msg1);
Debug.Assert(err == Error.Ok);
- err = ctx.Update(msg2);
+ err = _ctx.Update(msg2);
Debug.Assert(err == Error.Ok);
- byte[] hmac = ctx.Finish();
+ byte[] hmac = _ctx.Finish();
GD.Print(hmac.HexEncode());
}
}
diff --git a/doc/classes/HTTPClient.xml b/doc/classes/HTTPClient.xml
index b3ed38d250..4973f3fddf 100644
--- a/doc/classes/HTTPClient.xml
+++ b/doc/classes/HTTPClient.xml
@@ -30,13 +30,10 @@
<return type="int" enum="Error" />
<param index="0" name="host" type="String" />
<param index="1" name="port" type="int" default="-1" />
- <param index="2" name="use_tls" type="bool" default="false" />
- <param index="3" name="verify_host" type="bool" default="true" />
+ <param index="2" name="tls_options" type="TLSOptions" default="null" />
<description>
Connects to a host. This needs to be done before any requests are sent.
- The host should not have http:// prepended but will strip the protocol identifier if provided.
- If no [param port] is specified (or [code]-1[/code] is used), it is automatically set to 80 for HTTP and 443 for HTTPS (if [param use_tls] is enabled).
- [param verify_host] will check the TLS identity of the host if set to [code]true[/code].
+ If no [param port] is specified (or [code]-1[/code] is used), it is automatically set to 80 for HTTP and 443 for HTTPS. You can pass the optional [param tls_options] parameter to customize the trusted certification authorities, or the common name verification when using HTTPS. See [method TLSOptions.client] and [method TLSOptions.client_unsafe].
</description>
</method>
<method name="get_response_body_length" qualifiers="const">
@@ -108,7 +105,7 @@
[/gdscript]
[csharp]
var fields = new Godot.Collections.Dictionary { { "username", "user" }, { "password", "pass" } };
- string queryString = new HTTPClient().QueryStringFromDict(fields);
+ string queryString = httpClient.QueryStringFromDict(fields);
// Returns "username=user&amp;password=pass"
[/csharp]
[/codeblocks]
@@ -120,8 +117,13 @@
# Returns "single=123&amp;not_valued&amp;multiple=22&amp;multiple=33&amp;multiple=44"
[/gdscript]
[csharp]
- var fields = new Godot.Collections.Dictionary{{"single", 123}, {"notValued", null}, {"multiple", new Godot.Collections.Array{22, 33, 44}}};
- string queryString = new HTTPClient().QueryStringFromDict(fields);
+ var fields = new Godot.Collections.Dictionary
+ {
+ { "single", 123 },
+ { "notValued", default },
+ { "multiple", new Godot.Collections.Array { 22, 33, 44 } },
+ };
+ string queryString = httpClient.QueryStringFromDict(fields);
// Returns "single=123&amp;not_valued&amp;multiple=22&amp;multiple=33&amp;multiple=44"
[/csharp]
[/codeblocks]
@@ -154,7 +156,7 @@
[csharp]
var fields = new Godot.Collections.Dictionary { { "username", "user" }, { "password", "pass" } };
string queryString = new HTTPClient().QueryStringFromDict(fields);
- string[] headers = {"Content-Type: application/x-www-form-urlencoded", "Content-Length: " + queryString.Length};
+ string[] headers = { "Content-Type: application/x-www-form-urlencoded", $"Content-Length: {queryString.Length}" };
var result = new HTTPClient().Request(HTTPClient.Method.Post, "index.php", headers, queryString);
[/csharp]
[/codeblocks]
diff --git a/doc/classes/HTTPRequest.xml b/doc/classes/HTTPRequest.xml
index c504e26d58..5a0b12e198 100644
--- a/doc/classes/HTTPRequest.xml
+++ b/doc/classes/HTTPRequest.xml
@@ -57,7 +57,7 @@
// Perform a POST request. The URL below returns JSON as of writing.
// Note: Don't make simultaneous requests using a single HTTPRequest node.
// The snippet below is provided for reference only.
- string body = new JSON().Stringify(new Godot.Collections.Dictionary
+ string body = new Json().Stringify(new Godot.Collections.Dictionary
{
{ "name", "Godette" }
});
@@ -69,14 +69,14 @@
}
// Called when the HTTP request is completed.
- private void HttpRequestCompleted(int result, int response_code, string[] headers, byte[] body)
+ private void HttpRequestCompleted(long result, long responseCode, string[] headers, byte[] body)
{
- var json = new JSON();
- json.Parse(body.GetStringFromUTF8());
- var response = json.GetData() as Godot.Collections.Dictionary;
+ var json = new Json();
+ json.Parse(body.GetStringFromUtf8());
+ var response = json.GetData().AsGodotDictionary();
// Will print the user agent string used by the HTTPRequest node (as recognized by httpbin.org).
- GD.Print((response["headers"] as Godot.Collections.Dictionary)["User-Agent"]);
+ GD.Print((response["headers"].AsGodotDictionary())["User-Agent"]);
}
[/csharp]
[/codeblocks]
@@ -128,9 +128,9 @@
}
// Called when the HTTP request is completed.
- private void HttpRequestCompleted(int result, int response_code, string[] headers, byte[] body)
+ private void HttpRequestCompleted(long result, long responseCode, string[] headers, byte[] body)
{
- if (result != (int)HTTPRequest.Result.Success)
+ if (result != (long)HTTPRequest.Result.Success)
{
GD.PushError("Image couldn't be downloaded. Try a different image.");
}
@@ -187,9 +187,8 @@
<return type="int" enum="Error" />
<param index="0" name="url" type="String" />
<param index="1" name="custom_headers" type="PackedStringArray" default="PackedStringArray()" />
- <param index="2" name="tls_validate_domain" type="bool" default="true" />
- <param index="3" name="method" type="int" enum="HTTPClient.Method" default="0" />
- <param index="4" name="request_data" type="String" default="&quot;&quot;" />
+ <param index="2" name="method" type="int" enum="HTTPClient.Method" default="0" />
+ <param index="3" name="request_data" type="String" default="&quot;&quot;" />
<description>
Creates request on the underlying [HTTPClient]. If there is no configuration errors, it tries to connect using [method HTTPClient.connect_to_host] and passes parameters onto [method HTTPClient.request].
Returns [constant OK] if request is successfully created. (Does not imply that the server has responded), [constant ERR_UNCONFIGURED] if not in the tree, [constant ERR_BUSY] if still processing previous request, [constant ERR_INVALID_PARAMETER] if given string is not a valid URL format, or [constant ERR_CANT_CONNECT] if not using thread and the [HTTPClient] cannot connect to host.
@@ -201,9 +200,8 @@
<return type="int" enum="Error" />
<param index="0" name="url" type="String" />
<param index="1" name="custom_headers" type="PackedStringArray" default="PackedStringArray()" />
- <param index="2" name="tls_validate_domain" type="bool" default="true" />
- <param index="3" name="method" type="int" enum="HTTPClient.Method" default="0" />
- <param index="4" name="request_data_raw" type="PackedByteArray" default="PackedByteArray()" />
+ <param index="2" name="method" type="int" enum="HTTPClient.Method" default="0" />
+ <param index="3" name="request_data_raw" type="PackedByteArray" default="PackedByteArray()" />
<description>
Creates request on the underlying [HTTPClient] using a raw array of bytes for the request body. If there is no configuration errors, it tries to connect using [method HTTPClient.connect_to_host] and passes parameters onto [method HTTPClient.request].
Returns [constant OK] if request is successfully created. (Does not imply that the server has responded), [constant ERR_UNCONFIGURED] if not in the tree, [constant ERR_BUSY] if still processing previous request, [constant ERR_INVALID_PARAMETER] if given string is not a valid URL format, or [constant ERR_CANT_CONNECT] if not using thread and the [HTTPClient] cannot connect to host.
@@ -227,6 +225,13 @@
The proxy server is unset if [param host] is empty or [param port] is -1.
</description>
</method>
+ <method name="set_tls_options">
+ <return type="void" />
+ <param index="0" name="client_options" type="TLSOptions" />
+ <description>
+ Sets the [TLSOptions] to be used when connecting to an HTTPS server. See [method TLSOptions.client].
+ </description>
+ </method>
</methods>
<members>
<member name="accept_gzip" type="bool" setter="set_accept_gzip" getter="is_accepting_gzip" default="true">
diff --git a/doc/classes/HashingContext.xml b/doc/classes/HashingContext.xml
index 6e3092e618..5223cbf52f 100644
--- a/doc/classes/HashingContext.xml
+++ b/doc/classes/HashingContext.xml
@@ -8,18 +8,17 @@
The [enum HashType] enum shows the supported hashing algorithms.
[codeblocks]
[gdscript]
- const CHUNK_SIZE = 102
+ const CHUNK_SIZE = 1024
func hash_file(path):
- var ctx = HashingContext.new()
- var file = File.new()
- # Start a SHA-256 context.
- ctx.start(HashingContext.HASH_SHA256)
# Check that file exists.
- if not file.file_exists(path):
+ if not FileAccess.file_exists(path):
return
+ # Start a SHA-256 context.
+ var ctx = HashingContext.new()
+ ctx.start(HashingContext.HASH_SHA256)
# Open the file to hash.
- file.open(path, File.READ)
+ var file = FileAccess.open(path, FileAccess.READ)
# Update the context after reading each chunk.
while not file.eof_reached():
ctx.update(file.get_buffer(CHUNK_SIZE))
@@ -33,17 +32,16 @@
public void HashFile(string path)
{
- var ctx = new HashingContext();
- var file = new File();
- // Start a SHA-256 context.
- ctx.Start(HashingContext.HashType.Sha256);
// Check that file exists.
- if (!file.FileExists(path))
+ if (!FileAccess.FileExists(path))
{
return;
}
+ // Start a SHA-256 context.
+ var ctx = new HashingContext();
+ ctx.Start(HashingContext.HashType.Sha256);
// Open the file to hash.
- file.Open(path, File.ModeFlags.Read);
+ using var file = FileAccess.Open(path, FileAccess.ModeFlags.Read);
// Update the context after reading each chunk.
while (!file.EofReached())
{
@@ -52,8 +50,7 @@
// Get the computed hash.
byte[] res = ctx.Finish();
// Print the result as hex string and array.
-
- GD.PrintT(res.HexEncode(), res);
+ GD.PrintT(res.HexEncode(), (Variant)res);
}
[/csharp]
[/codeblocks]
diff --git a/doc/classes/HeightMapShape3D.xml b/doc/classes/HeightMapShape3D.xml
index 206981e547..f34870c500 100644
--- a/doc/classes/HeightMapShape3D.xml
+++ b/doc/classes/HeightMapShape3D.xml
@@ -14,10 +14,10 @@
Height map data, pool array must be of [member map_width] * [member map_depth] size.
</member>
<member name="map_depth" type="int" setter="set_map_depth" getter="get_map_depth" default="2">
- Depth of the height map data. Changing this will resize the [member map_data].
+ Number of vertices in the depth of the height map. Changing this will resize the [member map_data].
</member>
<member name="map_width" type="int" setter="set_map_width" getter="get_map_width" default="2">
- Width of the height map data. Changing this will resize the [member map_data].
+ Number of vertices in the width of the height map. Changing this will resize the [member map_data].
</member>
</members>
</class>
diff --git a/doc/classes/Image.xml b/doc/classes/Image.xml
index be66b8a7b9..5b07124b91 100644
--- a/doc/classes/Image.xml
+++ b/doc/classes/Image.xml
@@ -75,17 +75,22 @@
<return type="int" enum="Error" />
<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="2" 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.
+ For ASTC compression, the [param astc_format] parameter must be supplied.
</description>
</method>
<method name="compress_from_channels">
<return type="int" enum="Error" />
<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="2" 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.
+ For ASTC compression, the [param astc_format] parameter must be supplied.
</description>
</method>
<method name="compute_image_metrics">
@@ -480,7 +485,7 @@
var img = Image.new()
img.create(img_width, img_height, false, Image.FORMAT_RGBA8)
- img.set_pixel(1, 2, Color.red) # Sets the color at (1, 2) to red.
+ img.set_pixel(1, 2, Color.RED) # Sets the color at (1, 2) to red.
[/gdscript]
[csharp]
int imgWidth = 10;
@@ -508,7 +513,7 @@
var img = Image.new()
img.create(img_width, img_height, false, Image.FORMAT_RGBA8)
- img.set_pixelv(Vector2i(1, 2), Color.red) # Sets the color at (1, 2) to red.
+ img.set_pixelv(Vector2i(1, 2), Color.RED) # Sets the color at (1, 2) to red.
[/gdscript]
[csharp]
int imgWidth = 10;
@@ -516,7 +521,7 @@
var img = new Image();
img.Create(imgWidth, imgHeight, false, Image.Format.Rgba8);
- img.SetPixelv(new Vector2i(1, 2), Colors.Red); // Sets the color at (1, 2) to red.
+ img.SetPixelv(new Vector2I(1, 2), Colors.Red); // Sets the color at (1, 2) to red.
[/csharp]
[/codeblocks]
This is the same as [method set_pixel], but with a [Vector2i] argument instead of two integer arguments.
@@ -658,7 +663,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 +739,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/ImporterMesh.xml b/doc/classes/ImporterMesh.xml
index b80857a7bf..10479dfcfe 100644
--- a/doc/classes/ImporterMesh.xml
+++ b/doc/classes/ImporterMesh.xml
@@ -27,9 +27,13 @@
<param index="5" name="name" type="String" default="&quot;&quot;" />
<param index="6" name="flags" type="int" default="0" />
<description>
- Creates a new surface, analogous to [method ArrayMesh.add_surface_from_arrays].
- Surfaces are created to be rendered using a [param primitive], which may be any of the types defined in [enum Mesh.PrimitiveType]. (As a note, when using indices, it is recommended to only use points, lines, or triangles.) [method Mesh.get_surface_count] will become the [code]surf_idx[/code] for this new surface.
- The [param arrays] argument is an array of arrays. See [enum Mesh.ArrayType] for the values used in this array. For example, [code]arrays[0][/code] is the array of vertices. That first vertex sub-array is always required; the others are optional. Adding an index array puts this function into "index mode" where the vertex and other arrays become the sources of data and the index array defines the vertex order. All sub-arrays must have the same length as the vertex array (or be an exact multiple of the vertex array's length, when multiple elements of a sub-array correspond to a single vertex) or be empty, except for [constant Mesh.ARRAY_INDEX] if it is used.
+ Creates a new surface. [method Mesh.get_surface_count] will become the [code]surf_idx[/code] for this new surface.
+ Surfaces are created to be rendered using a [param primitive], which may be any of the values defined in [enum Mesh.PrimitiveType].
+ The [param arrays] argument is an array of arrays. Each of the [constant Mesh.ARRAY_MAX] elements contains an array with some of the mesh data for this surface as described by the corresponding member of [enum Mesh.ArrayType] or [code]null[/code] if it is not used by the surface. For example, [code]arrays[0][/code] is the array of vertices. That first vertex sub-array is always required; the others are optional. Adding an index array puts this surface into "index mode" where the vertex and other arrays become the sources of data and the index array defines the vertex order. All sub-arrays must have the same length as the vertex array (or be an exact multiple of the vertex array's length, when multiple elements of a sub-array correspond to a single vertex) or be empty, except for [constant Mesh.ARRAY_INDEX] if it is used.
+ The [param blend_shapes] argument is an array of vertex data for each blend shape. Each element is an array of the same structure as [param arrays], but [constant Mesh.ARRAY_VERTEX], [constant Mesh.ARRAY_NORMAL], and [constant Mesh.ARRAY_TANGENT] are set if and only if they are set in [param arrays] and all other entries are [code]null[/code].
+ The [param lods] argument is a dictionary with [float] keys and [PackedInt32Array] values. Each entry in the dictionary represents a LOD level of the surface, where the value is the [constant Mesh.ARRAY_INDEX] array to use for the LOD level and the key is roughly proportional to the distance at which the LOD stats being used. I.e., increasing the key of a LOD also increases the distance that the objects has to be from the camera before the LOD is used.
+ The [param flags] argument is the bitwise or of, as required: One value of [enum Mesh.ArrayCustomFormat] left shifted by [code]ARRAY_FORMAT_CUSTOMn_SHIFT[/code] for each custom channel in use, [constant Mesh.ARRAY_FLAG_USE_DYNAMIC_UPDATE], [constant Mesh.ARRAY_FLAG_USE_8_BONE_WEIGHTS], or [constant Mesh.ARRAY_FLAG_USES_EMPTY_VERTEX_ARRAY].
+ [b]Note:[/b] When using indices, it is recommended to only use points, lines, or triangles.
</description>
</method>
<method name="clear">
diff --git a/doc/classes/Input.xml b/doc/classes/Input.xml
index d246e64251..70e629974d 100644
--- a/doc/classes/Input.xml
+++ b/doc/classes/Input.xml
@@ -155,7 +155,7 @@
</description>
</method>
<method name="get_mouse_button_mask" qualifiers="const">
- <return type="int" enum="MouseButton" />
+ <return type="int" enum="MouseButtonMask" />
<description>
Returns mouse buttons as a bitmask. If multiple mouse buttons are pressed at the same time, the bits are added together. Equivalent to [method DisplayServer.mouse_get_button_state].
</description>
@@ -224,11 +224,18 @@
Returns [code]true[/code] if the system knows the specified device. This means that it sets all button and axis indices. Unknown joypads are not expected to match these constants, but you can still retrieve events from them.
</description>
</method>
+ <method name="is_key_label_pressed" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="keycode" type="int" enum="Key" />
+ <description>
+ Returns [code]true[/code] if you are pressing the key with the [param keycode] printed on it. You can pass a [enum Key] constant or any Unicode character code.
+ </description>
+ </method>
<method name="is_key_pressed" qualifiers="const">
<return type="bool" />
<param index="0" name="keycode" type="int" enum="Key" />
<description>
- Returns [code]true[/code] if you are pressing the key in the current keyboard layout. You can pass a [enum Key] constant.
+ Returns [code]true[/code] if you are pressing the Latin key in the current keyboard layout. You can pass a [enum Key] constant.
[method is_key_pressed] is only recommended over [method is_physical_key_pressed] in non-game applications. This ensures that shortcut keys behave as expected depending on the user's keyboard layout, as keyboard shortcuts are generally dependent on the keyboard layout in non-game applications. If in doubt, use [method is_physical_key_pressed].
[b]Note:[/b] Due to keyboard ghosting, [method is_key_pressed] may return [code]false[/code] even if one of the action's keys is pressed. See [url=$DOCS_URL/tutorials/inputs/input_examples.html#keyboard-events]Input examples[/url] in the documentation for more information.
</description>
@@ -297,6 +304,7 @@
[param hotspot] must be within [param image]'s size.
[b]Note:[/b] [AnimatedTexture]s aren't supported as custom mouse cursors. If using an [AnimatedTexture], only the first frame will be displayed.
[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or [b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] compression mode can't be used for custom cursors.
+ [b]Note:[/b] On the web platform, the maximum allowed cursor image size is 128×128. Cursor images larger than 32×32 will also only be displayed if the mouse cursor image is entirely located within the page for [url=https://chromestatus.com/feature/5825971391299584]security reasons[/url].
</description>
</method>
<method name="set_default_cursor_shape">
@@ -339,7 +347,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 +355,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">
@@ -367,6 +375,7 @@
<description>
Sets the mouse position to the specified vector, provided in pixels and relative to an origin at the upper left corner of the currently focused Window Manager game window.
Mouse position is clipped to the limits of the screen resolution, or to the limits of the game window if [enum MouseMode] is set to [constant MOUSE_MODE_CONFINED] or [constant MOUSE_MODE_CONFINED_HIDDEN].
+ [b]Note:[/b] [method warp_mouse] is only supported on Windows, macOS and Linux. It has no effect on Android, iOS and Web.
</description>
</method>
</methods>
@@ -397,7 +406,7 @@
Makes the mouse cursor hidden if it is visible.
</constant>
<constant name="MOUSE_MODE_CAPTURED" value="2" enum="MouseMode">
- Captures the mouse. The mouse will be hidden and its position locked at the center of the screen.
+ Captures the mouse. The mouse will be hidden and its position locked at the center of the window manager's window.
[b]Note:[/b] If you want to process the mouse's movement in this mode, you need to use [member InputEventMouseMotion.relative].
</constant>
<constant name="MOUSE_MODE_CONFINED" value="3" enum="MouseMode">
diff --git a/doc/classes/InputEventAction.xml b/doc/classes/InputEventAction.xml
index 87e2b8ea20..3816847804 100644
--- a/doc/classes/InputEventAction.xml
+++ b/doc/classes/InputEventAction.xml
@@ -5,6 +5,7 @@
</brief_description>
<description>
Contains a generic action which can be targeted from several types of inputs. Actions can be created from the [b]Input Map[/b] tab in the [b]Project &gt; Project Settings[/b] menu. See [method Node._input].
+ [b]Note:[/b] Unlike the other [InputEvent] subclasses which map to unique physical events, this virtual one is not emitted by the engine. This class is useful to emit actions manually with [method Input.parse_input_event], which are then received in [method Node._input]. To check if a physical event matches an action from the Input Map, use [method InputEvent.is_action] and [method InputEvent.is_action_pressed].
</description>
<tutorials>
<link title="InputEvent: Actions">$DOCS_URL/tutorials/inputs/inputevent.html#actions</link>
diff --git a/doc/classes/InputEventKey.xml b/doc/classes/InputEventKey.xml
index c3d682de9e..4d10a183d4 100644
--- a/doc/classes/InputEventKey.xml
+++ b/doc/classes/InputEventKey.xml
@@ -5,15 +5,42 @@
</brief_description>
<description>
Stores key presses on the keyboard. Supports key presses, key releases and [member echo] events.
+ [b]Note:[/b] Events received from the keyboard usually have all properties set. Event mappings should have only one of the [member keycode], [member physical_keycode] or [member unicode] set.
+ When events are compared, properties are checked in the following priority - [member keycode], [member physical_keycode] and [member unicode], events with the first matching value will be considered equal.
</description>
<tutorials>
<link title="InputEvent">$DOCS_URL/tutorials/inputs/inputevent.html</link>
</tutorials>
<methods>
+ <method name="as_text_key_label" qualifiers="const">
+ <return type="String" />
+ <description>
+ Returns a [String] representation of the event's [member key_label] and modifiers.
+ </description>
+ </method>
+ <method name="as_text_keycode" qualifiers="const">
+ <return type="String" />
+ <description>
+ Returns a [String] representation of the event's [member keycode] and modifiers.
+ </description>
+ </method>
+ <method name="as_text_physical_keycode" qualifiers="const">
+ <return type="String" />
+ <description>
+ Returns a [String] representation of the event's [member physical_keycode] and modifiers.
+ </description>
+ </method>
+ <method name="get_key_label_with_modifiers" qualifiers="const">
+ <return type="int" enum="Key" />
+ <description>
+ Returns the localized key label combined with modifier keys such as [kbd]Shift[/kbd] or [kbd]Alt[/kbd]. See also [InputEventWithModifiers].
+ To get a human-readable representation of the [InputEventKey] with modifiers, use [code]OS.get_keycode_string(event.get_key_label_with_modifiers())[/code] where [code]event[/code] is the [InputEventKey].
+ </description>
+ </method>
<method name="get_keycode_with_modifiers" qualifiers="const">
<return type="int" enum="Key" />
<description>
- Returns the keycode combined with modifier keys such as [kbd]Shift[/kbd] or [kbd]Alt[/kbd]. See also [InputEventWithModifiers].
+ Returns the Latin keycode combined with modifier keys such as [kbd]Shift[/kbd] or [kbd]Alt[/kbd]. See also [InputEventWithModifiers].
To get a human-readable representation of the [InputEventKey] with modifiers, use [code]OS.get_keycode_string(event.get_keycode_with_modifiers())[/code] where [code]event[/code] is the [InputEventKey].
</description>
</method>
@@ -29,19 +56,36 @@
<member name="echo" type="bool" setter="set_echo" getter="is_echo" default="false">
If [code]true[/code], the key was already pressed before this event. It means the user is holding the key down.
</member>
+ <member name="key_label" type="int" setter="set_key_label" getter="get_key_label" enum="Key" default="0">
+ Represents the localized label printed on the key in the current keyboard layout, which corresponds to one of the [enum Key] constants or any valid Unicode character.
+ For keyboard layouts with a single label on the key, it is equivalent to [member keycode].
+ To get a human-readable representation of the [InputEventKey], use [code]OS.get_keycode_string(event.key_label)[/code] where [code]event[/code] is the [InputEventKey].
+ [codeblock]
+ +-----+ +-----+
+ | Q | | Q | - "Q" - keycode
+ | Й | | ض | - "Й" and "ض" - key_label
+ +-----+ +-----+
+ [/codeblock]
+ </member>
<member name="keycode" type="int" setter="set_keycode" getter="get_keycode" enum="Key" default="0">
- The key keycode, which corresponds to one of the [enum Key] constants. Represent key in the current keyboard layout.
+ Latin label printed on the key in the current keyboard layout, which corresponds to one of the [enum Key] constants.
To get a human-readable representation of the [InputEventKey], use [code]OS.get_keycode_string(event.keycode)[/code] where [code]event[/code] is the [InputEventKey].
+ [codeblock]
+ +-----+ +-----+
+ | Q | | Q | - "Q" - keycode
+ | Й | | ض | - "Й" and "ض" - key_label
+ +-----+ +-----+
+ [/codeblock]
</member>
<member name="physical_keycode" type="int" setter="set_physical_keycode" getter="get_physical_keycode" enum="Key" default="0">
- Key physical keycode, which corresponds to one of the [enum Key] constants. Represent the physical location of a key on the 101/102-key US QWERTY keyboard.
+ Represents the physical location of a key on the 101/102-key US QWERTY keyboard, which corresponds to one of the [enum Key] constants.
To get a human-readable representation of the [InputEventKey], use [code]OS.get_keycode_string(event.keycode)[/code] where [code]event[/code] is the [InputEventKey].
</member>
<member name="pressed" type="bool" setter="set_pressed" getter="is_pressed" default="false">
If [code]true[/code], the key's state is pressed. If [code]false[/code], the key's state is released.
</member>
<member name="unicode" type="int" setter="set_unicode" getter="get_unicode" default="0">
- The key Unicode identifier (when relevant). Unicode identifiers for the composite characters and complex scripts may not be available unless IME input mode is active. See [method Window.set_ime_active] for more information.
+ The key Unicode character code (when relevant), shifted by modifier keys. Unicode character codes for composite characters and complex scripts may not be available unless IME input mode is active. See [method Window.set_ime_active] for more information.
</member>
</members>
</class>
diff --git a/doc/classes/InputEventMIDI.xml b/doc/classes/InputEventMIDI.xml
index 67e7ced2e8..e4ba380741 100644
--- a/doc/classes/InputEventMIDI.xml
+++ b/doc/classes/InputEventMIDI.xml
@@ -35,9 +35,9 @@
GD.Print(OS.GetConnectedMidiInputs());
}
- public override void _Input(InputEvent inputEvent)
+ public override void _Input(InputEvent @event)
{
- if (inputEvent is InputEventMIDI midiEvent)
+ if (@event is InputEventMIDI midiEvent)
{
PrintMIDIInfo(midiEvent);
}
@@ -46,14 +46,14 @@
private void PrintMIDIInfo(InputEventMIDI midiEvent)
{
GD.Print(midiEvent);
- GD.Print("Channel " + midiEvent.Channel);
- GD.Print("Message " + midiEvent.Message);
- GD.Print("Pitch " + midiEvent.Pitch);
- GD.Print("Velocity " + midiEvent.Velocity);
- GD.Print("Instrument " + midiEvent.Instrument);
- GD.Print("Pressure " + midiEvent.Pressure);
- GD.Print("Controller number: " + midiEvent.ControllerNumber);
- GD.Print("Controller value: " + midiEvent.ControllerValue);
+ GD.Print($"Channel {midiEvent.Channel}");
+ GD.Print($"Message {midiEvent.Message}");
+ GD.Print($"Pitch {midiEvent.Pitch}");
+ GD.Print($"Velocity {midiEvent.Velocity}");
+ GD.Print($"Instrument {midiEvent.Instrument}");
+ GD.Print($"Pressure {midiEvent.Pressure}");
+ GD.Print($"Controller number: {midiEvent.ControllerNumber}");
+ GD.Print($"Controller value: {midiEvent.ControllerValue}");
}
[/csharp]
[/codeblocks]
diff --git a/doc/classes/InputEventMouse.xml b/doc/classes/InputEventMouse.xml
index 889329d97e..0a1f3d2c1a 100644
--- a/doc/classes/InputEventMouse.xml
+++ b/doc/classes/InputEventMouse.xml
@@ -10,7 +10,7 @@
<link title="InputEvent">$DOCS_URL/tutorials/inputs/inputevent.html</link>
</tutorials>
<members>
- <member name="button_mask" type="int" setter="set_button_mask" getter="get_button_mask" enum="MouseButton" default="0">
+ <member name="button_mask" type="int" setter="set_button_mask" getter="get_button_mask" enum="MouseButtonMask" default="0">
The mouse button mask identifier, one of or a bitwise combination of the [enum MouseButton] button masks.
</member>
<member name="global_position" type="Vector2" setter="set_global_position" getter="get_global_position" default="Vector2(0, 0)">
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/InputEventWithModifiers.xml b/doc/classes/InputEventWithModifiers.xml
index c6311d780c..26b88e6ff2 100644
--- a/doc/classes/InputEventWithModifiers.xml
+++ b/doc/classes/InputEventWithModifiers.xml
@@ -10,6 +10,12 @@
<link title="InputEvent">$DOCS_URL/tutorials/inputs/inputevent.html</link>
</tutorials>
<methods>
+ <method name="get_modifiers_mask" qualifiers="const">
+ <return type="int" enum="KeyModifierMask" />
+ <description>
+ Returns the keycode combination of modifier keys.
+ </description>
+ </method>
<method name="is_command_or_control_pressed" qualifiers="const">
<return type="bool" />
<description>
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/JSON.xml b/doc/classes/JSON.xml
index 93731cf553..6fe53dfaac 100644
--- a/doc/classes/JSON.xml
+++ b/doc/classes/JSON.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<class name="JSON" inherits="RefCounted" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+<class name="JSON" inherits="Resource" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
Helper class for creating and parsing JSON data.
</brief_description>
@@ -49,13 +49,21 @@
Returns an empty string if the last call to [method parse] was successful, or the error message if it failed.
</description>
</method>
+ <method name="get_parsed_text" qualifiers="const">
+ <return type="String" />
+ <description>
+ Return the text parsed by [method parse] as long as the function is instructed to keep it.
+ </description>
+ </method>
<method name="parse">
<return type="int" enum="Error" />
- <param index="0" name="json_string" type="String" />
+ <param index="0" name="json_text" type="String" />
+ <param index="1" name="keep_text" type="bool" default="false" />
<description>
- Attempts to parse the [param json_string] provided.
+ Attempts to parse the [param json_text] provided.
Returns an [enum Error]. If the parse was successful, it returns [constant OK] and the result can be retrieved using [member data]. If unsuccessful, use [method get_error_line] and [method get_error_message] for identifying the source of the failure.
Non-static variant of [method parse_string], if you want custom error handling.
+ The optional [param keep_text] argument instructs the parser to keep a copy of the original text. This text can be obtained later by using the [method get_parsed_text] function and is used when saving the resource (instead of generating new text from [member data]).
</description>
</method>
<method name="parse_string" qualifiers="static">
diff --git a/doc/classes/JavaScriptBridge.xml b/doc/classes/JavaScriptBridge.xml
index 5e36b5cc80..f79c11b334 100644
--- a/doc/classes/JavaScriptBridge.xml
+++ b/doc/classes/JavaScriptBridge.xml
@@ -5,7 +5,7 @@
</brief_description>
<description>
The JavaScriptBridge singleton is implemented only in the Web export. It's used to access the browser's JavaScript context. This allows interaction with embedding pages or calling third-party JavaScript APIs.
- [b]Note:[/b] This singleton can be disabled at build-time to improve security. By default, the JavaScriptBridge singleton is enabled. Official export templates also have the JavaScriptBridge singleton enabled. See [url=$DOCS_URL/development/compiling/compiling_for_web.html]Compiling for the Web[/url] in the documentation for more information.
+ [b]Note:[/b] This singleton can be disabled at build-time to improve security. By default, the JavaScriptBridge singleton is enabled. Official export templates also have the JavaScriptBridge singleton enabled. See [url=$DOCS_URL/contributing/development/compiling/compiling_for_web.html]Compiling for the Web[/url] in the documentation for more information.
</description>
<tutorials>
<link title="Exporting for the Web: Calling JavaScript from script">$DOCS_URL/tutorials/export/exporting_for_web.html#calling-javascript-from-script</link>
@@ -46,6 +46,13 @@
If [param use_global_execution_context] is [code]true[/code], the code will be evaluated in the global execution context. Otherwise, it is evaluated in the execution context of a function within the engine's runtime environment.
</description>
</method>
+ <method name="force_fs_sync">
+ <return type="void" />
+ <description>
+ Force synchronization of the persistent file system (when enabled).
+ [b]Note:[/b] This is only useful for modules or extensions that can't use [FileAccess] to write files.
+ </description>
+ </method>
<method name="get_interface">
<return type="JavaScriptObject" />
<param index="0" name="interface" type="String" />
diff --git a/doc/classes/Label.xml b/doc/classes/Label.xml
index cd87b4558f..a14856b9b2 100644
--- a/doc/classes/Label.xml
+++ b/doc/classes/Label.xml
@@ -62,7 +62,7 @@
Limits the lines of text the node shows on screen.
</member>
<member name="mouse_filter" type="int" setter="set_mouse_filter" getter="get_mouse_filter" overrides="Control" enum="Control.MouseFilter" default="2" />
- <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" default="4" />
+ <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" enum="Control.SizeFlags" default="4" />
<member name="structured_text_bidi_override" type="int" setter="set_structured_text_bidi_override" getter="get_structured_text_bidi_override" enum="TextServer.StructuredTextParser" default="0">
Set BiDi algorithm override for the structured text.
</member>
@@ -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/Label3D.xml b/doc/classes/Label3D.xml
index 0cbca2224e..cfb47ff4c3 100644
--- a/doc/classes/Label3D.xml
+++ b/doc/classes/Label3D.xml
@@ -32,9 +32,18 @@
</method>
</methods>
<members>
+ <member name="alpha_antialiasing_edge" type="float" setter="set_alpha_antialiasing_edge" getter="get_alpha_antialiasing_edge" default="0.0">
+ Threshold at which antialiasing will be applied on the alpha channel.
+ </member>
+ <member name="alpha_antialiasing_mode" type="int" setter="set_alpha_antialiasing" getter="get_alpha_antialiasing" enum="BaseMaterial3D.AlphaAntiAliasing" default="0">
+ The type of alpha antialiasing to apply. See [enum BaseMaterial3D.AlphaAntiAliasing].
+ </member>
<member name="alpha_cut" type="int" setter="set_alpha_cut_mode" getter="get_alpha_cut_mode" enum="Label3D.AlphaCutMode" default="0">
The alpha cutting mode to use for the sprite. See [enum AlphaCutMode] for possible values.
</member>
+ <member name="alpha_hash_scale" type="float" setter="set_alpha_hash_scale" getter="get_alpha_hash_scale" default="1.0">
+ The hashing scale for Alpha Hash. Recommended values between [code]0[/code] and [code]2[/code].
+ </member>
<member name="alpha_scissor_threshold" type="float" setter="set_alpha_scissor_threshold" getter="get_alpha_scissor_threshold" default="0.5">
Threshold at which the alpha scissor will discard values.
</member>
@@ -152,5 +161,8 @@
This mode draws fully opaque pixels in the depth prepass. This is slower than [constant ALPHA_CUT_DISABLED] or [constant ALPHA_CUT_DISCARD], but it allows displaying translucent areas and smooth edges while using proper sorting.
[b]Note:[/b] When using text with overlapping glyphs (e.g., cursive scripts), this mode might have transparency sorting issues between the main text and the outline.
</constant>
+ <constant name="ALPHA_CUT_HASH" value="3" enum="AlphaCutMode">
+ This mode draws cuts off all values below a spatially-deterministic threshold, the rest will remain opaque.
+ </constant>
</constants>
</class>
diff --git a/doc/classes/Light3D.xml b/doc/classes/Light3D.xml
index fe7756faaf..95c39d535e 100644
--- a/doc/classes/Light3D.xml
+++ b/doc/classes/Light3D.xml
@@ -80,7 +80,7 @@
A typical household lightbulb can range from around 600 lumens to 1,200 lumens, a candle is about 13 lumens, while a streetlight can be approximately 60,000 lumens.
</member>
<member name="light_intensity_lux" type="float" setter="set_param" getter="get_param">
- Used by [DirectionalLight3D]s when [member ProjectSettings.rendering/lights_and_shadows/use_physical_light_units] is [code]true[/code]. Sets the intensity of the light source measured in Lux. Lux is a measure pf luminous flux per unit area, it is equal to one lumen per square metre. Lux is the measure of how much light hits a surface at a given time.
+ Used by [DirectionalLight3D]s when [member ProjectSettings.rendering/lights_and_shadows/use_physical_light_units] is [code]true[/code]. Sets the intensity of the light source measured in Lux. Lux is a measure of luminous flux per unit area, it is equal to one lumen per square meter. Lux is the measure of how much light hits a surface at a given time.
On a clear sunny day a surface in direct sunlight may be approximately 100,000 lux, a typical room in a home may be approximately 50 lux, while the moonlit ground may be approximately 0.1 lux.
</member>
<member name="light_negative" type="bool" setter="set_negative" getter="is_negative" default="false">
diff --git a/doc/classes/LightmapGI.xml b/doc/classes/LightmapGI.xml
index 53dae1a8e6..723e6bbf21 100644
--- a/doc/classes/LightmapGI.xml
+++ b/doc/classes/LightmapGI.xml
@@ -93,22 +93,28 @@
<constant name="BAKE_ERROR_OK" value="0" enum="BakeError">
Lightmap baking was successful.
</constant>
- <constant name="BAKE_ERROR_NO_LIGHTMAPPER" value="1" enum="BakeError">
+ <constant name="BAKE_ERROR_NO_SCENE_ROOT" value="1" enum="BakeError">
+ Lightmap baking failed because the root node for the edited scene could not be accessed.
+ </constant>
+ <constant name="BAKE_ERROR_FOREIGN_DATA" value="2" enum="BakeError">
+ Lightmap baking failed as the lightmap data resource is embedded in a foreign resource.
+ </constant>
+ <constant name="BAKE_ERROR_NO_LIGHTMAPPER" value="3" enum="BakeError">
Lightmap baking failed as there is no lightmapper available in this Godot build.
</constant>
- <constant name="BAKE_ERROR_NO_SAVE_PATH" value="2" enum="BakeError">
+ <constant name="BAKE_ERROR_NO_SAVE_PATH" value="4" enum="BakeError">
Lightmap baking failed as the [LightmapGIData] save path isn't configured in the resource.
</constant>
- <constant name="BAKE_ERROR_NO_MESHES" value="3" enum="BakeError">
+ <constant name="BAKE_ERROR_NO_MESHES" value="5" enum="BakeError">
Lightmap baking failed as there are no meshes whose [member GeometryInstance3D.gi_mode] is [constant GeometryInstance3D.GI_MODE_STATIC] and with valid UV2 mapping in the current scene. You may need to select 3D scenes in the Import dock and change their global illumination mode accordingly.
</constant>
- <constant name="BAKE_ERROR_MESHES_INVALID" value="4" enum="BakeError">
+ <constant name="BAKE_ERROR_MESHES_INVALID" value="6" enum="BakeError">
Lightmap baking failed as the lightmapper failed to analyze some of the meshes marked as static for baking.
</constant>
- <constant name="BAKE_ERROR_CANT_CREATE_IMAGE" value="5" enum="BakeError">
+ <constant name="BAKE_ERROR_CANT_CREATE_IMAGE" value="7" enum="BakeError">
Lightmap baking failed as the resulting image couldn't be saved or imported by Godot after it was saved.
</constant>
- <constant name="BAKE_ERROR_USER_ABORTED" value="6" enum="BakeError">
+ <constant name="BAKE_ERROR_USER_ABORTED" value="8" enum="BakeError">
The user aborted the lightmap baking operation (typically by clicking the [b]Cancel[/b] button in the progress dialog).
</constant>
<constant name="ENVIRONMENT_MODE_DISABLED" value="0" enum="EnvironmentMode">
diff --git a/doc/classes/LineEdit.xml b/doc/classes/LineEdit.xml
index e57cc68b36..8ed8622030 100644
--- a/doc/classes/LineEdit.xml
+++ b/doc/classes/LineEdit.xml
@@ -61,6 +61,45 @@
<return type="PopupMenu" />
<description>
Returns the [PopupMenu] of this [LineEdit]. By default, this menu is displayed when right-clicking on the [LineEdit].
+ You can add custom menu items or remove standard ones. Make sure your IDs don't conflict with the standard ones (see [enum MenuItems]). For example:
+ [codeblocks]
+ [gdscript]
+ func _ready():
+ var menu = get_menu()
+ # Remove all items after "Redo".
+ menu.item_count = menu.get_item_index(MENU_REDO) + 1
+ # Add custom items.
+ menu.add_separator()
+ menu.add_item("Insert Date", MENU_MAX + 1)
+ # Connect callback.
+ menu.id_pressed.connect(_on_item_pressed)
+
+ func _on_item_pressed(id):
+ if id == MENU_MAX + 1:
+ insert_text_at_caret(Time.get_date_string_from_system())
+ [/gdscript]
+ [csharp]
+ public override void _Ready()
+ {
+ var menu = GetMenu();
+ // Remove all items after "Redo".
+ menu.ItemCount = menu.GetItemIndex(LineEdit.MenuItems.Redo) + 1;
+ // Add custom items.
+ menu.AddSeparator();
+ menu.AddItem("Insert Date", LineEdit.MenuItems.Max + 1);
+ // Add event handler.
+ menu.IdPressed += OnItemPressed;
+ }
+
+ public void OnItemPressed(int id)
+ {
+ if (id == LineEdit.MenuItems.Max + 1)
+ {
+ InsertTextAtCaret(Time.GetDateStringFromSystem());
+ }
+ }
+ [/csharp]
+ [/codeblocks]
[b]Warning:[/b] This is a required internal node, removing and freeing it may cause a crash. If you wish to hide it or any of its children, use their [member Window.visible] property.
</description>
</method>
@@ -296,70 +335,76 @@
<constant name="MENU_REDO" value="6" enum="MenuItems">
Reverse the last undo action.
</constant>
- <constant name="MENU_DIR_INHERITED" value="7" enum="MenuItems">
+ <constant name="MENU_SUBMENU_TEXT_DIR" value="7" enum="MenuItems">
+ ID of "Text Writing Direction" submenu.
+ </constant>
+ <constant name="MENU_DIR_INHERITED" value="8" enum="MenuItems">
Sets text direction to inherited.
</constant>
- <constant name="MENU_DIR_AUTO" value="8" enum="MenuItems">
+ <constant name="MENU_DIR_AUTO" value="9" enum="MenuItems">
Sets text direction to automatic.
</constant>
- <constant name="MENU_DIR_LTR" value="9" enum="MenuItems">
+ <constant name="MENU_DIR_LTR" value="10" enum="MenuItems">
Sets text direction to left-to-right.
</constant>
- <constant name="MENU_DIR_RTL" value="10" enum="MenuItems">
+ <constant name="MENU_DIR_RTL" value="11" enum="MenuItems">
Sets text direction to right-to-left.
</constant>
- <constant name="MENU_DISPLAY_UCC" value="11" enum="MenuItems">
+ <constant name="MENU_DISPLAY_UCC" value="12" enum="MenuItems">
Toggles control character display.
</constant>
- <constant name="MENU_INSERT_LRM" value="12" enum="MenuItems">
+ <constant name="MENU_SUBMENU_INSERT_UCC" value="13" enum="MenuItems">
+ ID of "Insert Control Character" submenu.
+ </constant>
+ <constant name="MENU_INSERT_LRM" value="14" enum="MenuItems">
Inserts left-to-right mark (LRM) character.
</constant>
- <constant name="MENU_INSERT_RLM" value="13" enum="MenuItems">
+ <constant name="MENU_INSERT_RLM" value="15" enum="MenuItems">
Inserts right-to-left mark (RLM) character.
</constant>
- <constant name="MENU_INSERT_LRE" value="14" enum="MenuItems">
+ <constant name="MENU_INSERT_LRE" value="16" enum="MenuItems">
Inserts start of left-to-right embedding (LRE) character.
</constant>
- <constant name="MENU_INSERT_RLE" value="15" enum="MenuItems">
+ <constant name="MENU_INSERT_RLE" value="17" enum="MenuItems">
Inserts start of right-to-left embedding (RLE) character.
</constant>
- <constant name="MENU_INSERT_LRO" value="16" enum="MenuItems">
+ <constant name="MENU_INSERT_LRO" value="18" enum="MenuItems">
Inserts start of left-to-right override (LRO) character.
</constant>
- <constant name="MENU_INSERT_RLO" value="17" enum="MenuItems">
+ <constant name="MENU_INSERT_RLO" value="19" enum="MenuItems">
Inserts start of right-to-left override (RLO) character.
</constant>
- <constant name="MENU_INSERT_PDF" value="18" enum="MenuItems">
+ <constant name="MENU_INSERT_PDF" value="20" enum="MenuItems">
Inserts pop direction formatting (PDF) character.
</constant>
- <constant name="MENU_INSERT_ALM" value="19" enum="MenuItems">
+ <constant name="MENU_INSERT_ALM" value="21" enum="MenuItems">
Inserts Arabic letter mark (ALM) character.
</constant>
- <constant name="MENU_INSERT_LRI" value="20" enum="MenuItems">
+ <constant name="MENU_INSERT_LRI" value="22" enum="MenuItems">
Inserts left-to-right isolate (LRI) character.
</constant>
- <constant name="MENU_INSERT_RLI" value="21" enum="MenuItems">
+ <constant name="MENU_INSERT_RLI" value="23" enum="MenuItems">
Inserts right-to-left isolate (RLI) character.
</constant>
- <constant name="MENU_INSERT_FSI" value="22" enum="MenuItems">
+ <constant name="MENU_INSERT_FSI" value="24" enum="MenuItems">
Inserts first strong isolate (FSI) character.
</constant>
- <constant name="MENU_INSERT_PDI" value="23" enum="MenuItems">
+ <constant name="MENU_INSERT_PDI" value="25" enum="MenuItems">
Inserts pop direction isolate (PDI) character.
</constant>
- <constant name="MENU_INSERT_ZWJ" value="24" enum="MenuItems">
+ <constant name="MENU_INSERT_ZWJ" value="26" enum="MenuItems">
Inserts zero width joiner (ZWJ) character.
</constant>
- <constant name="MENU_INSERT_ZWNJ" value="25" enum="MenuItems">
+ <constant name="MENU_INSERT_ZWNJ" value="27" enum="MenuItems">
Inserts zero width non-joiner (ZWNJ) character.
</constant>
- <constant name="MENU_INSERT_WJ" value="26" enum="MenuItems">
+ <constant name="MENU_INSERT_WJ" value="28" enum="MenuItems">
Inserts word joiner (WJ) character.
</constant>
- <constant name="MENU_INSERT_SHY" value="27" enum="MenuItems">
+ <constant name="MENU_INSERT_SHY" value="29" enum="MenuItems">
Inserts soft hyphen (SHY) character.
</constant>
- <constant name="MENU_MAX" value="28" enum="MenuItems">
+ <constant name="MENU_MAX" value="30" enum="MenuItems">
Represents the size of the [enum MenuItems] enum.
</constant>
<constant name="KEYBOARD_TYPE_DEFAULT" value="0" enum="VirtualKeyboardType">
@@ -424,6 +469,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/MainLoop.xml b/doc/classes/MainLoop.xml
index 674adb1772..260efb0eab 100644
--- a/doc/classes/MainLoop.xml
+++ b/doc/classes/MainLoop.xml
@@ -29,29 +29,28 @@
[/gdscript]
[csharp]
using Godot;
- using System;
- public class CustomMainLoop : MainLoop
+ public partial class CustomMainLoop : MainLoop
{
- public float TimeElapsed = 0;
+ private double _timeElapsed = 0;
public override void _Initialize()
{
GD.Print("Initialized:");
- GD.Print($" Starting Time: {TimeElapsed}");
+ GD.Print($" Starting Time: {_timeElapsed}");
}
- public override bool _Process(float delta)
+ public override bool _Process(double delta)
{
- TimeElapsed += delta;
+ _timeElapsed += delta;
// Return true to end the main loop.
- return Input.GetMouseButtonMask() != 0 || Input.IsKeyPressed((int)KeyList.Escape);
+ return Input.GetMouseButtonMask() != 0 || Input.IsKeyPressed(Key.Escape);
}
private void _Finalize()
{
GD.Print("Finalized:");
- GD.Print($" End Time: {TimeElapsed}");
+ GD.Print($" End Time: {_timeElapsed}");
}
}
[/csharp]
diff --git a/doc/classes/Marshalls.xml b/doc/classes/Marshalls.xml
index 102e4b75ed..1eeb0be7ce 100644
--- a/doc/classes/Marshalls.xml
+++ b/doc/classes/Marshalls.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="Marshalls" inherits="Object" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
- Data transformation (marshalling) and encoding helpers.
+ Data transformation (marshaling) and encoding helpers.
</brief_description>
<description>
Provides data transformation and encoding utility functions.
diff --git a/doc/classes/Material.xml b/doc/classes/Material.xml
index c5d567c1fe..bdd5cee797 100644
--- a/doc/classes/Material.xml
+++ b/doc/classes/Material.xml
@@ -31,6 +31,12 @@
<description>
</description>
</method>
+ <method name="create_placeholder" qualifiers="const">
+ <return type="Resource" />
+ <description>
+ Creates a placeholder version of this resource ([PlaceholderMaterial]).
+ </description>
+ </method>
<method name="inspect_native_shader_code">
<return type="void" />
<description>
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/Mesh.xml b/doc/classes/Mesh.xml
index 4d3fb7ed5c..ece3199aab 100644
--- a/doc/classes/Mesh.xml
+++ b/doc/classes/Mesh.xml
@@ -114,6 +114,12 @@
[b]Note:[/b] This method typically returns the vertices in reverse order (e.g. clockwise to counterclockwise).
</description>
</method>
+ <method name="create_placeholder" qualifiers="const">
+ <return type="Resource" />
+ <description>
+ Creates a placeholder version of this resource ([PlaceholderMesh]).
+ </description>
+ </method>
<method name="create_trimesh_shape" qualifiers="const">
<return type="ConcavePolygonShape3D" />
<description>
@@ -227,10 +233,10 @@
Contains custom color channel 3. [PackedByteArray] if [code](format &gt;&gt; [constant ARRAY_FORMAT_CUSTOM3_SHIFT]) &amp; [constant ARRAY_FORMAT_CUSTOM_MASK])[/code] is [constant ARRAY_CUSTOM_RGBA8_UNORM], [constant ARRAY_CUSTOM_RGBA8_UNORM], [constant ARRAY_CUSTOM_RG_HALF] or [constant ARRAY_CUSTOM_RGBA_HALF]. [PackedFloat32Array] otherwise.
</constant>
<constant name="ARRAY_BONES" value="10" enum="ArrayType">
- [PackedFloat32Array] or [PackedInt32Array] of bone indices. Each element is a group of 4 numbers.
+ [PackedFloat32Array] or [PackedInt32Array] of bone indices. Contains either 4 or 8 numbers per vertex depending on the presence of the [constant ARRAY_FLAG_USE_8_BONE_WEIGHTS] flag.
</constant>
<constant name="ARRAY_WEIGHTS" value="11" enum="ArrayType">
- [PackedFloat32Array] of bone weights. Each element in groups of 4 floats.
+ [PackedFloat32Array] or [PackedFloat64Array] of bone weights in the range [code]0.0[/code] to [code]1.0[/code] (inclusive). Contains either 4 or 8 numbers per vertex depending on the presence of the [constant ARRAY_FLAG_USE_8_BONE_WEIGHTS] flag.
</constant>
<constant name="ARRAY_INDEX" value="12" enum="ArrayType">
[PackedInt32Array] of integers used as indices referencing vertices, colors, normals, tangents, and textures. All of those arrays must have the same number of elements as the vertex array. No index can be beyond the vertex array size. When this index array is present, it puts the function into "index mode," where the index selects the *i*'th vertex, normal, tangent, color, UV, etc. This means if you want to have different normals or colors along an edge, you have to duplicate the vertices.
@@ -266,81 +272,84 @@
<constant name="ARRAY_CUSTOM_MAX" value="8" enum="ArrayCustomFormat">
Represents the size of the [enum ArrayCustomFormat] enum.
</constant>
- <constant name="ARRAY_FORMAT_VERTEX" value="1" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_VERTEX" value="1" enum="ArrayFormat" is_bitfield="true">
Mesh array contains vertices. All meshes require a vertex array so this should always be present.
</constant>
- <constant name="ARRAY_FORMAT_NORMAL" value="2" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_NORMAL" value="2" enum="ArrayFormat" is_bitfield="true">
Mesh array contains normals.
</constant>
- <constant name="ARRAY_FORMAT_TANGENT" value="4" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_TANGENT" value="4" enum="ArrayFormat" is_bitfield="true">
Mesh array contains tangents.
</constant>
- <constant name="ARRAY_FORMAT_COLOR" value="8" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_COLOR" value="8" enum="ArrayFormat" is_bitfield="true">
Mesh array contains colors.
</constant>
- <constant name="ARRAY_FORMAT_TEX_UV" value="16" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_TEX_UV" value="16" enum="ArrayFormat" is_bitfield="true">
Mesh array contains UVs.
</constant>
- <constant name="ARRAY_FORMAT_TEX_UV2" value="32" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_TEX_UV2" value="32" enum="ArrayFormat" is_bitfield="true">
Mesh array contains second UV.
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM0" value="64" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM0" value="64" enum="ArrayFormat" is_bitfield="true">
Mesh array contains custom channel index 0.
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM1" value="128" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM1" value="128" enum="ArrayFormat" is_bitfield="true">
Mesh array contains custom channel index 1.
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM2" value="256" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM2" value="256" enum="ArrayFormat" is_bitfield="true">
Mesh array contains custom channel index 2.
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM3" value="512" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM3" value="512" enum="ArrayFormat" is_bitfield="true">
Mesh array contains custom channel index 3.
</constant>
- <constant name="ARRAY_FORMAT_BONES" value="1024" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_BONES" value="1024" enum="ArrayFormat" is_bitfield="true">
Mesh array contains bones.
</constant>
- <constant name="ARRAY_FORMAT_WEIGHTS" value="2048" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_WEIGHTS" value="2048" enum="ArrayFormat" is_bitfield="true">
Mesh array contains bone weights.
</constant>
- <constant name="ARRAY_FORMAT_INDEX" value="4096" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_INDEX" value="4096" enum="ArrayFormat" is_bitfield="true">
Mesh array uses indices.
</constant>
- <constant name="ARRAY_FORMAT_BLEND_SHAPE_MASK" value="7" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_BLEND_SHAPE_MASK" value="7" enum="ArrayFormat" is_bitfield="true">
Mask of mesh channels permitted in blend shapes.
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM_BASE" value="13" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM_BASE" value="13" enum="ArrayFormat" is_bitfield="true">
Shift of first custom channel.
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM_BITS" value="3" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM_BITS" value="3" enum="ArrayFormat" is_bitfield="true">
Number of format bits per custom channel. See [enum ArrayCustomFormat].
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM0_SHIFT" value="13" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM0_SHIFT" value="13" enum="ArrayFormat" is_bitfield="true">
Amount to shift [enum ArrayCustomFormat] for custom channel index 0.
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM1_SHIFT" value="16" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM1_SHIFT" value="16" enum="ArrayFormat" is_bitfield="true">
Amount to shift [enum ArrayCustomFormat] for custom channel index 1.
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM2_SHIFT" value="19" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM2_SHIFT" value="19" enum="ArrayFormat" is_bitfield="true">
Amount to shift [enum ArrayCustomFormat] for custom channel index 2.
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM3_SHIFT" value="22" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM3_SHIFT" value="22" enum="ArrayFormat" is_bitfield="true">
Amount to shift [enum ArrayCustomFormat] for custom channel index 3.
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM_MASK" value="7" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM_MASK" value="7" enum="ArrayFormat" is_bitfield="true">
Mask of custom format bits per custom channel. Must be shifted by one of the SHIFT constants. See [enum ArrayCustomFormat].
</constant>
- <constant name="ARRAY_COMPRESS_FLAGS_BASE" value="25" enum="ArrayFormat">
+ <constant name="ARRAY_COMPRESS_FLAGS_BASE" value="25" enum="ArrayFormat" is_bitfield="true">
Shift of first compress flag. Compress flags should be passed to [method ArrayMesh.add_surface_from_arrays] and [method SurfaceTool.commit].
</constant>
- <constant name="ARRAY_FLAG_USE_2D_VERTICES" value="33554432" enum="ArrayFormat">
+ <constant name="ARRAY_FLAG_USE_2D_VERTICES" value="33554432" enum="ArrayFormat" is_bitfield="true">
Flag used to mark that the array contains 2D vertices.
</constant>
- <constant name="ARRAY_FLAG_USE_DYNAMIC_UPDATE" value="67108864" enum="ArrayFormat">
+ <constant name="ARRAY_FLAG_USE_DYNAMIC_UPDATE" value="67108864" enum="ArrayFormat" is_bitfield="true">
Flag indices that the mesh data will use [code]GL_DYNAMIC_DRAW[/code] on GLES. Unused on Vulkan.
</constant>
- <constant name="ARRAY_FLAG_USE_8_BONE_WEIGHTS" value="134217728" enum="ArrayFormat">
+ <constant name="ARRAY_FLAG_USE_8_BONE_WEIGHTS" value="134217728" enum="ArrayFormat" is_bitfield="true">
Flag used to mark that the mesh contains up to 8 bone influences per vertex. This flag indicates that [constant ARRAY_BONES] and [constant ARRAY_WEIGHTS] elements will have double length.
</constant>
+ <constant name="ARRAY_FLAG_USES_EMPTY_VERTEX_ARRAY" value="268435456" enum="ArrayFormat" is_bitfield="true">
+ Flag used to mark that the mesh intentionally contains no vertex array.
+ </constant>
<constant name="BLEND_SHAPE_MODE_NORMALIZED" value="0" enum="BlendShapeMode">
Blend shapes are normalized.
</constant>
diff --git a/doc/classes/MeshInstance2D.xml b/doc/classes/MeshInstance2D.xml
index e9666337a1..7bb33fc46d 100644
--- a/doc/classes/MeshInstance2D.xml
+++ b/doc/classes/MeshInstance2D.xml
@@ -13,10 +13,6 @@
<member name="mesh" type="Mesh" setter="set_mesh" getter="get_mesh">
The [Mesh] that will be drawn by the [MeshInstance2D].
</member>
- <member name="normal_map" type="Texture2D" setter="set_normal_map" getter="get_normal_map">
- The normal map that will be used if using the default [CanvasItemMaterial].
- [b]Note:[/b] Godot expects the normal map to use X+, Y+, and Z+ coordinates. See [url=http://wiki.polycount.com/wiki/Normal_Map_Technical_Details#Common_Swizzle_Coordinates]this page[/url] for a comparison of normal map coordinates expected by popular engines.
- </member>
<member name="texture" type="Texture2D" setter="set_texture" getter="get_texture">
The [Texture2D] that will be used if using the default [CanvasItemMaterial]. Can be accessed as [code]TEXTURE[/code] in CanvasItem shader.
</member>
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/MultiMeshInstance2D.xml b/doc/classes/MultiMeshInstance2D.xml
index daf5ef6287..16c0f6070e 100644
--- a/doc/classes/MultiMeshInstance2D.xml
+++ b/doc/classes/MultiMeshInstance2D.xml
@@ -13,10 +13,6 @@
<member name="multimesh" type="MultiMesh" setter="set_multimesh" getter="get_multimesh">
The [MultiMesh] that will be drawn by the [MultiMeshInstance2D].
</member>
- <member name="normal_map" type="Texture2D" setter="set_normal_map" getter="get_normal_map">
- The normal map that will be used if using the default [CanvasItemMaterial].
- [b]Note:[/b] Godot expects the normal map to use X+, Y+, and Z+ coordinates. See [url=http://wiki.polycount.com/wiki/Normal_Map_Technical_Details#Common_Swizzle_Coordinates]this page[/url] for a comparison of normal map coordinates expected by popular engines.
- </member>
<member name="texture" type="Texture2D" setter="set_texture" getter="get_texture">
The [Texture2D] that will be used if using the default [CanvasItemMaterial]. Can be accessed as [code]TEXTURE[/code] in CanvasItem shader.
</member>
diff --git a/doc/classes/MultiplayerAPI.xml b/doc/classes/MultiplayerAPI.xml
index 3ce6ce41b4..020ce4f468 100644
--- a/doc/classes/MultiplayerAPI.xml
+++ b/doc/classes/MultiplayerAPI.xml
@@ -138,10 +138,10 @@
Used with [method Node.rpc_config] to disable a method or property for all RPC calls, making it unavailable. Default for all methods.
</constant>
<constant name="RPC_MODE_ANY_PEER" value="1" enum="RPCMode">
- Used with [method Node.rpc_config] to set a method to be callable remotely by any peer. Analogous to the [code]@rpc(any)[/code] annotation. Calls are accepted from all remote peers, no matter if they are node's authority or not.
+ Used with [method Node.rpc_config] to set a method to be callable remotely by any peer. Analogous to the [code]@rpc("any")[/code] annotation. Calls are accepted from all remote peers, no matter if they are node's authority or not.
</constant>
<constant name="RPC_MODE_AUTHORITY" value="2" enum="RPCMode">
- Used with [method Node.rpc_config] to set a method to be callable remotely only by the current multiplayer authority (which is the server by default). Analogous to the [code]@rpc(authority)[/code] annotation. See [method Node.set_multiplayer_authority].
+ Used with [method Node.rpc_config] to set a method to be callable remotely only by the current multiplayer authority (which is the server by default). Analogous to the [code]@rpc("authority")[/code] annotation. See [method Node.set_multiplayer_authority].
</constant>
</constants>
</class>
diff --git a/doc/classes/MultiplayerAPIExtension.xml b/doc/classes/MultiplayerAPIExtension.xml
index c4012a920a..b853c32407 100644
--- a/doc/classes/MultiplayerAPIExtension.xml
+++ b/doc/classes/MultiplayerAPIExtension.xml
@@ -99,7 +99,7 @@
</description>
</method>
<method name="_object_configuration_add" qualifiers="virtual">
- <return type="int" />
+ <return type="int" enum="Error" />
<param index="0" name="object" type="Object" />
<param index="1" name="configuration" type="Variant" />
<description>
@@ -107,7 +107,7 @@
</description>
</method>
<method name="_object_configuration_remove" qualifiers="virtual">
- <return type="int" />
+ <return type="int" enum="Error" />
<param index="0" name="object" type="Object" />
<param index="1" name="configuration" type="Variant" />
<description>
@@ -115,13 +115,13 @@
</description>
</method>
<method name="_poll" qualifiers="virtual">
- <return type="int" />
+ <return type="int" enum="Error" />
<description>
Callback for [method MultiplayerAPI.poll].
</description>
</method>
<method name="_rpc" qualifiers="virtual">
- <return type="int" />
+ <return type="int" enum="Error" />
<param index="0" name="peer" type="int" />
<param index="1" name="object" type="Object" />
<param index="2" name="method" type="StringName" />
diff --git a/doc/classes/Mutex.xml b/doc/classes/Mutex.xml
index 74f29bdc48..78694ce813 100644
--- a/doc/classes/Mutex.xml
+++ b/doc/classes/Mutex.xml
@@ -18,9 +18,9 @@
</description>
</method>
<method name="try_lock">
- <return type="int" enum="Error" />
+ <return type="bool" />
<description>
- Tries locking this [Mutex], but does not block. Returns [constant OK] on success, [constant ERR_BUSY] otherwise.
+ Tries locking this [Mutex], but does not block. Returns [code]true[/code] on success, [code]false[/code] otherwise.
[b]Note:[/b] This function returns [constant OK] if the thread already has ownership of the mutex.
</description>
</method>
diff --git a/doc/classes/NavigationAgent2D.xml b/doc/classes/NavigationAgent2D.xml
index 8cf7824ff7..92fd8bcc6a 100644
--- a/doc/classes/NavigationAgent2D.xml
+++ b/doc/classes/NavigationAgent2D.xml
@@ -1,39 +1,46 @@
<?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>
<description>
- 2D Agent that is used in navigation to reach a location while avoiding static and dynamic obstacles. The dynamic obstacles are avoided using RVO collision avoidance. The agent needs navigation data to work correctly. [NavigationAgent2D] is physics safe.
- [b]Note:[/b] After setting [member target_location] it is required to use the [method get_next_location] function once every physics frame to update the internal path logic of the NavigationAgent. The returned vector position from this function should be used as the next movement position for the agent's parent Node.
+ 2D Agent that is used in navigation to reach a position while avoiding static and dynamic obstacles. The dynamic obstacles are avoided using RVO collision avoidance. The agent needs navigation data to work correctly. [NavigationAgent2D] is physics safe.
+ [b]Note:[/b] After setting [member target_position] it is required to use the [method get_next_path_position] function once every physics frame to update the internal path logic of the NavigationAgent. The returned vector position from this function should be used as the next movement position for the agent's parent Node.
</description>
<tutorials>
+ <link title="Using NavigationAgents">$DOCS_URL/tutorials/navigation/navigation_using_navigationagents.html</link>
</tutorials>
<methods>
<method name="distance_to_target" qualifiers="const">
<return type="float" />
<description>
- 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.
+ Returns the distance to the target position, using the agent's global position. The user must set [member target_position] 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.
+ Returns this agent's current path from start to finish in global coordinates. The path only updates when the target position 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_path_position] 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_position">
+ <return type="Vector2" />
+ <description>
+ Returns the reachable final position 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" />
@@ -47,10 +54,10 @@
Returns the [RID] of the navigation map for this NavigationAgent node. This function returns always the map set on the NavigationAgent node and not the map of the abstract agent on the NavigationServer. If the agent map is changed directly with the NavigationServer API the NavigationAgent node will not be aware of the map change. Use [method set_navigation_map] to change the navigation map for the NavigationAgent and also update the agent on the NavigationServer.
</description>
</method>
- <method name="get_next_location">
+ <method name="get_next_path_position">
<return type="Vector2" />
<description>
- Returns the next location in global coordinates that can be moved to, making sure that there are no static objects in the way. If the agent does not have a navigation path, it will return the position of the agent's parent. The use of this function once every physics frame is required to update the internal path logic of the NavigationAgent.
+ Returns the next position in global coordinates that can be moved to, making sure that there are no static objects in the way. If the agent does not have a navigation path, it will return the position of the agent's parent. The use of this function once every physics frame is required to update the internal path logic of the NavigationAgent.
</description>
</method>
<method name="get_rid" qualifiers="const">
@@ -62,19 +69,19 @@
<method name="is_navigation_finished">
<return type="bool" />
<description>
- Returns true if the navigation path's final location has been reached.
+ Returns true if the navigation path's final position has been reached.
</description>
</method>
<method name="is_target_reachable">
<return type="bool" />
<description>
- Returns true if [member target_location] is reachable.
+ Returns true if [member target_position] is reachable.
</description>
</method>
<method name="is_target_reached" qualifiers="const">
<return type="bool" />
<description>
- Returns true if [member target_location] is reached. It may not always be possible to reach the target location. It should always be possible to reach the final location though. See [method get_final_location].
+ Returns true if [member target_position] is reached. It may not always be possible to reach the target position. It should always be possible to reach the final position though. See [method get_final_position].
</description>
</method>
<method name="set_navigation_layer_value">
@@ -104,10 +111,25 @@
<member name="avoidance_enabled" type="bool" setter="set_avoidance_enabled" getter="get_avoidance_enabled" default="false">
If [code]true[/code] the agent is registered for an RVO avoidance callback on the [NavigationServer2D]. When [method NavigationAgent2D.set_velocity] is used and the processing is completed a [code]safe_velocity[/code] Vector2 is received with a signal connection to [signal velocity_computed]. Avoidance processing with many registered agents has a significant performance cost and should only be enabled on agents that currently require it.
</member>
+ <member name="debug_enabled" type="bool" setter="set_debug_enabled" getter="get_debug_enabled" default="false">
+ If [code]true[/code] shows debug visuals for this agent.
+ </member>
+ <member name="debug_path_custom_color" type="Color" setter="set_debug_path_custom_color" getter="get_debug_path_custom_color" default="Color(1, 1, 1, 1)">
+ If [member debug_use_custom] is [code]true[/code] uses this color for this agent instead of global color.
+ </member>
+ <member name="debug_path_custom_line_width" type="float" setter="set_debug_path_custom_line_width" getter="get_debug_path_custom_line_width" default="1.0">
+ If [member debug_use_custom] is [code]true[/code] uses this line width for rendering paths for this agent instead of global line width.
+ </member>
+ <member name="debug_path_custom_point_size" type="float" setter="set_debug_path_custom_point_size" getter="get_debug_path_custom_point_size" default="4.0">
+ If [member debug_use_custom] is [code]true[/code] uses this rasterized point size for rendering path points for this agent instead of global point size.
+ </member>
+ <member name="debug_use_custom" type="bool" setter="set_debug_use_custom" getter="get_debug_use_custom" default="false">
+ If [code]true[/code] uses the defined [member debug_path_custom_color] for this agent instead of global color.
+ </member>
<member name="max_neighbors" type="int" setter="set_max_neighbors" getter="get_max_neighbors" default="10">
The maximum number of neighbors for the agent to consider.
</member>
- <member name="max_speed" type="float" setter="set_max_speed" getter="get_max_speed" default="200.0">
+ <member name="max_speed" type="float" setter="set_max_speed" getter="get_max_speed" default="100.0">
The maximum speed that an agent can move.
</member>
<member name="navigation_layers" type="int" setter="set_navigation_layers" getter="get_navigation_layers" default="1">
@@ -116,30 +138,44 @@
<member name="neighbor_distance" type="float" setter="set_neighbor_distance" getter="get_neighbor_distance" default="500.0">
The distance to search for other agents.
</member>
- <member name="path_desired_distance" type="float" setter="set_path_desired_distance" getter="get_path_desired_distance" default="1.0">
+ <member name="path_desired_distance" type="float" setter="set_path_desired_distance" getter="get_path_desired_distance" default="20.0">
The distance threshold before a path point is considered to be reached. This will allow an agent to not have to hit a path point on the path exactly, but in the area. If this value is set to high the NavigationAgent will skip points on the path which can lead to leaving the navigation mesh. If this value is set to low the NavigationAgent will be stuck in a repath loop cause it will constantly overshoot or undershoot the distance to the next point on each physics frame update.
</member>
- <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 name="path_max_distance" type="float" setter="set_path_max_distance" getter="get_path_max_distance" default="100.0">
+ The maximum distance the agent is allowed away from the ideal path to the final position. 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.
</member>
- <member name="target_desired_distance" type="float" setter="set_target_desired_distance" getter="get_target_desired_distance" default="1.0">
+ <member name="target_desired_distance" type="float" setter="set_target_desired_distance" getter="get_target_desired_distance" default="10.0">
The distance threshold before the final target point is considered to be reached. This will allow an agent to not have to hit the point of the final target exactly, but only the area. If this value is set to low the NavigationAgent will be stuck in a repath loop cause it will constantly overshoot or undershoot the distance to the final target point on each physics frame update.
</member>
- <member name="target_location" type="Vector2" setter="set_target_location" getter="get_target_location" default="Vector2(0, 0)">
- The user-defined target location. Setting this property will clear the current navigation path.
+ <member name="target_position" type="Vector2" setter="set_target_position" getter="get_target_position" default="Vector2(0, 0)">
+ The user-defined target position. Setting this property will clear the current navigation path.
</member>
- <member name="time_horizon" type="float" setter="set_time_horizon" getter="get_time_horizon" default="20.0">
+ <member name="time_horizon" type="float" setter="set_time_horizon" getter="get_time_horizon" default="1.0">
The minimal amount of time for which this agent's velocities, that are computed with the collision avoidance algorithm, are safe with respect to other agents. The larger the number, the sooner the agent will respond to other agents, but less freedom in choosing its velocities. Must be positive.
</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]position[/code]: The start position 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.
+ Notifies when the final position is reached.
</description>
</signal>
<signal name="path_changed">
@@ -149,7 +185,7 @@
</signal>
<signal name="target_reached">
<description>
- Notifies when the player-defined [member target_location] is reached.
+ Notifies when the player-defined [member target_position] is reached.
</description>
</signal>
<signal name="velocity_computed">
@@ -158,5 +194,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]position[/code]: The position 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..0ed11bc477 100644
--- a/doc/classes/NavigationAgent3D.xml
+++ b/doc/classes/NavigationAgent3D.xml
@@ -1,39 +1,46 @@
<?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>
<description>
- 3D Agent that is used in navigation to reach a location while avoiding static and dynamic obstacles. The dynamic obstacles are avoided using RVO collision avoidance. The agent needs navigation data to work correctly. [NavigationAgent3D] is physics safe.
- [b]Note:[/b] After setting [member target_location] it is required to use the [method get_next_location] function once every physics frame to update the internal path logic of the NavigationAgent. The returned vector position from this function should be used as the next movement position for the agent's parent Node.
+ 3D Agent that is used in navigation to reach a position while avoiding static and dynamic obstacles. The dynamic obstacles are avoided using RVO collision avoidance. The agent needs navigation data to work correctly. [NavigationAgent3D] is physics safe.
+ [b]Note:[/b] After setting [member target_position] it is required to use the [method get_next_path_position] function once every physics frame to update the internal path logic of the NavigationAgent. The returned vector position from this function should be used as the next movement position for the agent's parent Node.
</description>
<tutorials>
+ <link title="Using NavigationAgents">$DOCS_URL/tutorials/navigation/navigation_using_navigationagents.html</link>
</tutorials>
<methods>
<method name="distance_to_target" qualifiers="const">
<return type="float" />
<description>
- 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.
+ Returns the distance to the target position, using the agent's global position. The user must set [member target_position] 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.
+ Returns this agent's current path from start to finish in global coordinates. The path only updates when the target position 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_path_position] 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_position">
+ <return type="Vector3" />
+ <description>
+ Returns the reachable final position 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" />
@@ -47,10 +54,10 @@
Returns the [RID] of the navigation map for this NavigationAgent node. This function returns always the map set on the NavigationAgent node and not the map of the abstract agent on the NavigationServer. If the agent map is changed directly with the NavigationServer API the NavigationAgent node will not be aware of the map change. Use [method set_navigation_map] to change the navigation map for the NavigationAgent and also update the agent on the NavigationServer.
</description>
</method>
- <method name="get_next_location">
+ <method name="get_next_path_position">
<return type="Vector3" />
<description>
- Returns the next location in global coordinates that can be moved to, making sure that there are no static objects in the way. If the agent does not have a navigation path, it will return the position of the agent's parent. The use of this function once every physics frame is required to update the internal path logic of the NavigationAgent.
+ Returns the next position in global coordinates that can be moved to, making sure that there are no static objects in the way. If the agent does not have a navigation path, it will return the position of the agent's parent. The use of this function once every physics frame is required to update the internal path logic of the NavigationAgent.
</description>
</method>
<method name="get_rid" qualifiers="const">
@@ -62,19 +69,19 @@
<method name="is_navigation_finished">
<return type="bool" />
<description>
- Returns true if the navigation path's final location has been reached.
+ Returns true if the navigation path's final position has been reached.
</description>
</method>
<method name="is_target_reachable">
<return type="bool" />
<description>
- Returns true if [member target_location] is reachable.
+ Returns true if [member target_position] is reachable.
</description>
</method>
<method name="is_target_reached" qualifiers="const">
<return type="bool" />
<description>
- Returns true if [member target_location] is reached. It may not always be possible to reach the target location. It should always be possible to reach the final location though. See [method get_final_location].
+ Returns true if [member target_position] is reached. It may not always be possible to reach the target position. It should always be possible to reach the final position though. See [method get_final_position].
</description>
</method>
<method name="set_navigation_layer_value">
@@ -107,6 +114,18 @@
<member name="avoidance_enabled" type="bool" setter="set_avoidance_enabled" getter="get_avoidance_enabled" default="false">
If [code]true[/code] the agent is registered for an RVO avoidance callback on the [NavigationServer3D]. When [method NavigationAgent3D.set_velocity] is used and the processing is completed a [code]safe_velocity[/code] Vector3 is received with a signal connection to [signal velocity_computed]. Avoidance processing with many registered agents has a significant performance cost and should only be enabled on agents that currently require it.
</member>
+ <member name="debug_enabled" type="bool" setter="set_debug_enabled" getter="get_debug_enabled" default="false">
+ If [code]true[/code] shows debug visuals for this agent.
+ </member>
+ <member name="debug_path_custom_color" type="Color" setter="set_debug_path_custom_color" getter="get_debug_path_custom_color" default="Color(1, 1, 1, 1)">
+ If [member debug_use_custom] is [code]true[/code] uses this color for this agent instead of global color.
+ </member>
+ <member name="debug_path_custom_point_size" type="float" setter="set_debug_path_custom_point_size" getter="get_debug_path_custom_point_size" default="4.0">
+ If [member debug_use_custom] is [code]true[/code] uses this rasterized point size for rendering path points for this agent instead of global point size.
+ </member>
+ <member name="debug_use_custom" type="bool" setter="set_debug_use_custom" getter="get_debug_use_custom" default="false">
+ If [code]true[/code] uses the defined [member debug_path_custom_color] for this agent instead of global color.
+ </member>
<member name="ignore_y" type="bool" setter="set_ignore_y" getter="get_ignore_y" default="true">
Ignores collisions on the Y axis. Must be true to move on a horizontal plane.
</member>
@@ -126,7 +145,10 @@
The distance threshold before a path point is considered to be reached. This will allow an agent to not have to hit a path point on the path exactly, but in the area. If this value is set to high the NavigationAgent will skip points on the path which can lead to leaving the navigation mesh. If this value is set to low the NavigationAgent will be stuck in a repath loop cause it will constantly overshoot or undershoot the distance to the next point on each physics frame update.
</member>
<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.
+ The maximum distance the agent is allowed away from the ideal path to the final position. 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]).
@@ -135,17 +157,28 @@
<member name="target_desired_distance" type="float" setter="set_target_desired_distance" getter="get_target_desired_distance" default="1.0">
The distance threshold before the final target point is considered to be reached. This will allow an agent to not have to hit the point of the final target exactly, but only the area. If this value is set to low the NavigationAgent will be stuck in a repath loop cause it will constantly overshoot or undershoot the distance to the final target point on each physics frame update.
</member>
- <member name="target_location" type="Vector3" setter="set_target_location" getter="get_target_location" default="Vector3(0, 0, 0)">
- The user-defined target location. Setting this property will clear the current navigation path.
+ <member name="target_position" type="Vector3" setter="set_target_position" getter="get_target_position" default="Vector3(0, 0, 0)">
+ The user-defined target position. Setting this property will clear the current navigation path.
</member>
<member name="time_horizon" type="float" setter="set_time_horizon" getter="get_time_horizon" default="5.0">
The minimal amount of time for which this agent's velocities, that are computed with the collision avoidance algorithm, are safe with respect to other agents. The larger the number, the sooner the agent will respond to other agents, but less freedom in choosing its velocities. Must be positive.
</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]position[/code]: The start position 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.
+ Notifies when the final position is reached.
</description>
</signal>
<signal name="path_changed">
@@ -155,7 +188,7 @@
</signal>
<signal name="target_reached">
<description>
- Notifies when the player-defined [member target_location] is reached.
+ Notifies when the player-defined [member target_position] is reached.
</description>
</signal>
<signal name="velocity_computed">
@@ -164,5 +197,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]position[/code]: The position 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..b3f4367675 100644
--- a/doc/classes/NavigationLink2D.xml
+++ b/doc/classes/NavigationLink2D.xml
@@ -1,12 +1,13 @@
<?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.
+ Creates a link between two positions that [NavigationServer2D] can route agents through.
</brief_description>
<description>
- Creates a link between two locations that [NavigationServer2D] can route agents through. Links can be used to express navigation methods that aren't just traveling along the surface of the navigation mesh, like zip-lines, teleporters, or jumping across gaps.
+ Creates a link between two positions that [NavigationServer2D] can route agents through. Links can be used to express navigation methods that aren't just traveling along the surface of the navigation mesh, like zip-lines, teleporters, or jumping across gaps.
</description>
<tutorials>
+ <link title="Using NavigationLinks">$DOCS_URL/tutorials/navigation/navigation_using_navigationlinks.html</link>
</tutorials>
<methods>
<method name="get_navigation_layer_value" qualifiers="const">
@@ -27,23 +28,23 @@
</methods>
<members>
<member name="bidirectional" type="bool" setter="set_bidirectional" getter="is_bidirectional" default="true">
- Whether this link can be traveled in both directions or only from [member start_location] to [member end_location].
+ Whether this link can be traveled in both directions or only from [member start_position] to [member end_position].
</member>
<member name="enabled" type="bool" setter="set_enabled" getter="is_enabled" default="true">
Whether this link is currently active. If [code]false[/code], [method NavigationServer2D.map_get_path] will ignore this link.
</member>
- <member name="end_location" type="Vector2" setter="set_end_location" getter="get_end_location" default="Vector2(0, 0)">
+ <member name="end_position" type="Vector2" setter="set_end_position" getter="get_end_position" default="Vector2(0, 0)">
Ending position of the link.
This position will search out the nearest polygon in the navigation mesh to attach to.
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].
</member>
- <member name="start_location" type="Vector2" setter="set_start_location" getter="get_start_location" default="Vector2(0, 0)">
+ <member name="start_position" type="Vector2" setter="set_start_position" getter="get_start_position" default="Vector2(0, 0)">
Starting position of the link.
This position will search out the nearest polygon in the navigation mesh to attach to.
The distance the link will search is controlled by [method NavigationServer2D.map_set_link_connection_radius].
diff --git a/doc/classes/NavigationLink3D.xml b/doc/classes/NavigationLink3D.xml
index 4d5d81bec5..4dff226042 100644
--- a/doc/classes/NavigationLink3D.xml
+++ b/doc/classes/NavigationLink3D.xml
@@ -1,12 +1,13 @@
<?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.
+ Creates a link between two positions that [NavigationServer3D] can route agents through.
</brief_description>
<description>
- Creates a link between two locations that [NavigationServer3D] can route agents through. Links can be used to express navigation methods that aren't just traveling along the surface of the navigation mesh, like zip-lines, teleporters, or jumping across gaps.
+ Creates a link between two positions that [NavigationServer3D] can route agents through. Links can be used to express navigation methods that aren't just traveling along the surface of the navigation mesh, like zip-lines, teleporters, or jumping across gaps.
</description>
<tutorials>
+ <link title="Using NavigationLinks">$DOCS_URL/tutorials/navigation/navigation_using_navigationlinks.html</link>
</tutorials>
<methods>
<method name="get_navigation_layer_value" qualifiers="const">
@@ -27,23 +28,23 @@
</methods>
<members>
<member name="bidirectional" type="bool" setter="set_bidirectional" getter="is_bidirectional" default="true">
- Whether this link can be traveled in both directions or only from [member start_location] to [member end_location].
+ Whether this link can be traveled in both directions or only from [member start_position] to [member end_position].
</member>
<member name="enabled" type="bool" setter="set_enabled" getter="is_enabled" default="true">
Whether this link is currently active. If [code]false[/code], [method NavigationServer3D.map_get_path] will ignore this link.
</member>
- <member name="end_location" type="Vector3" setter="set_end_location" getter="get_end_location" default="Vector3(0, 0, 0)">
+ <member name="end_position" type="Vector3" setter="set_end_position" getter="get_end_position" default="Vector3(0, 0, 0)">
Ending position of the link.
This position will search out the nearest polygon in the navigation mesh to attach to.
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].
</member>
- <member name="start_location" type="Vector3" setter="set_start_location" getter="get_start_location" default="Vector3(0, 0, 0)">
+ <member name="start_position" type="Vector3" setter="set_start_position" getter="get_start_position" default="Vector3(0, 0, 0)">
Starting position of the link.
This position will search out the nearest polygon in the navigation mesh to attach to.
The distance the link will search is controlled by [method NavigationServer3D.map_set_link_connection_radius].
diff --git a/doc/classes/NavigationMesh.xml b/doc/classes/NavigationMesh.xml
index c86bc47e04..85af44a13e 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>
@@ -8,6 +8,7 @@
</description>
<tutorials>
<link title="3D Navmesh Demo">https://godotengine.org/asset-library/asset/124</link>
+ <link title="Using NavigationMeshes">$DOCS_URL/tutorials/navigation/navigation_using_navigationmeshes.html</link>
</tutorials>
<methods>
<method name="add_polygon">
@@ -133,13 +134,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 +149,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 +178,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..0d4c083eb0 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>
@@ -11,21 +11,22 @@
[b]Note:[/b] Using meshes to not only define walkable surfaces but also obstruct navigation baking does not always work. The navigation baking has no concept of what is a geometry "inside" when dealing with mesh source geometry and this is intentional. Depending on current baking parameters, as soon as the obstructing mesh is large enough to fit a navigation mesh area inside, the baking will generate navigation mesh areas that are inside the obstructing source geometry mesh.
</description>
<tutorials>
+ <link title="Using NavigationMeshes">$DOCS_URL/tutorials/navigation/navigation_using_navigationmeshes.html</link>
</tutorials>
<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..7d391bfa99 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>
@@ -8,6 +8,7 @@
Obstacles [b]don't[/b] change the resulting path from the pathfinding, they only affect the navigation agent movement in a radius. Therefore, using obstacles for the static walls in your level won't work because those walls don't exist in the pathfinding. The navigation agent will be pushed in a semi-random direction away while moving inside that radius. Obstacles are intended as a last resort option for constantly moving objects that cannot be (re)baked to a navigation mesh efficiently.
</description>
<tutorials>
+ <link title="Using NavigationObstacles">$DOCS_URL/tutorials/navigation/navigation_using_navigationobstacles.html</link>
</tutorials>
<methods>
<method name="get_navigation_map" qualifiers="const">
diff --git a/doc/classes/NavigationObstacle3D.xml b/doc/classes/NavigationObstacle3D.xml
index 90eb55887f..ce24d2bb0e 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>
@@ -8,6 +8,7 @@
Obstacles [b]don't[/b] change the resulting path from the pathfinding, they only affect the navigation agent movement in a radius. Therefore, using obstacles for the static walls in your level won't work because those walls don't exist in the pathfinding. The navigation agent will be pushed in a semi-random direction away while moving inside that radius. Obstacles are intended as a last resort option for constantly moving objects that cannot be (re)baked to a navigation mesh efficiently.
</description>
<tutorials>
+ <link title="Using NavigationObstacles">$DOCS_URL/tutorials/navigation/navigation_using_navigationobstacles.html</link>
</tutorials>
<methods>
<method name="get_navigation_map" qualifiers="const">
diff --git a/doc/classes/NavigationPathQueryParameters2D.xml b/doc/classes/NavigationPathQueryParameters2D.xml
index 397ca8b713..05d7e9f918 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>
@@ -7,11 +7,15 @@
This class contains the start and target position and other parameters to be used with [method NavigationServer2D.query_path].
</description>
<tutorials>
+ <link title="Using NavigationPathQueryObjects">$DOCS_URL/tutorials/navigation/navigation_using_navigationpathqueryobjects.html</link>
</tutorials>
<members>
<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 +37,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..690d74ab70 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>
@@ -7,11 +7,15 @@
This class contains the start and target position and other parameters to be used with [method NavigationServer3D.query_path].
</description>
<tutorials>
+ <link title="Using NavigationPathQueryObjects">$DOCS_URL/tutorials/navigation/navigation_using_navigationpathqueryobjects.html</link>
</tutorials>
<members>
<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 +37,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..7bc588619d 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>
@@ -7,6 +7,7 @@
This class contains the result of a navigation path query from [method NavigationServer2D.query_path].
</description>
<tutorials>
+ <link title="Using NavigationPathQueryObjects">$DOCS_URL/tutorials/navigation/navigation_using_navigationpathqueryobjects.html</link>
</tutorials>
<methods>
<method name="reset">
@@ -20,5 +21,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..118a597b6c 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>
@@ -7,6 +7,7 @@
This class contains the result of a navigation path query from [method NavigationServer3D.query_path].
</description>
<tutorials>
+ <link title="Using NavigationPathQueryObjects">$DOCS_URL/tutorials/navigation/navigation_using_navigationpathqueryobjects.html</link>
</tutorials>
<methods>
<method name="reset">
@@ -20,5 +21,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..c223f88d6d 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,12 +38,13 @@
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>
<tutorials>
<link title="2D Navigation Demo">https://godotengine.org/asset-library/asset/117</link>
+ <link title="Using NavigationMeshes">$DOCS_URL/tutorials/navigation/navigation_using_navigationmeshes.html</link>
</tutorials>
<methods>
<method name="add_outline">
@@ -80,10 +81,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..5d0fe9dae4 100644
--- a/doc/classes/NavigationRegion2D.xml
+++ b/doc/classes/NavigationRegion2D.xml
@@ -1,18 +1,19 @@
<?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.
[b]Note:[/b] This node caches changes to its properties, so if you make changes to the underlying region [RID] in [NavigationServer2D], they will not be reflected in this node's properties.
</description>
<tutorials>
+ <link title="Using NavigationRegions">$DOCS_URL/tutorials/navigation/navigation_using_navigationregions.html</link>
</tutorials>
<methods>
<method name="get_navigation_layer_value" qualifiers="const">
@@ -42,16 +43,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..c3e554e7d6 100644
--- a/doc/classes/NavigationRegion3D.xml
+++ b/doc/classes/NavigationRegion3D.xml
@@ -1,18 +1,19 @@
<?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.
[b]Note:[/b] This node caches changes to its properties, so if you make changes to the underlying region [RID] in [NavigationServer3D], they will not be reflected in this node's properties.
</description>
<tutorials>
+ <link title="Using NavigationRegions">$DOCS_URL/tutorials/navigation/navigation_using_navigationregions.html</link>
</tutorials>
<methods>
<method name="bake_navigation_mesh">
@@ -49,16 +50,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 230e58a12a..7270a19b4d 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>
@@ -15,9 +15,10 @@
</description>
<tutorials>
<link title="2D Navigation Demo">https://godotengine.org/asset-library/asset/117</link>
+ <link title="Using NavigationServer">$DOCS_URL/tutorials/navigation/navigation_using_navigationservers.html</link>
</tutorials>
<methods>
- <method name="agent_create" qualifiers="const">
+ <method name="agent_create">
<return type="RID" />
<description>
Creates the agent.
@@ -37,18 +38,16 @@
Returns true if the map got changed the previous frame.
</description>
</method>
- <method name="agent_set_callback" qualifiers="const">
+ <method name="agent_set_callback">
<return type="void" />
<param index="0" name="agent" type="RID" />
- <param index="1" name="object_id" type="int" />
- <param index="2" name="method" type="StringName" />
- <param index="3" name="userdata" type="Variant" default="null" />
+ <param index="1" name="callback" type="Callable" />
<description>
- 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].
+ Sets the callback that gets called after each avoidance processing step for the [param agent]. The calculated [code]safe_velocity[/code] will be passed as the first parameter 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 an empty [Callable].
</description>
</method>
- <method name="agent_set_map" qualifiers="const">
+ <method name="agent_set_map">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="map" type="RID" />
@@ -56,7 +55,7 @@
Puts the agent in the map.
</description>
</method>
- <method name="agent_set_max_neighbors" qualifiers="const">
+ <method name="agent_set_max_neighbors">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="count" type="int" />
@@ -64,7 +63,7 @@
Sets the maximum number of other agents the agent takes into account in the navigation. The larger this number, the longer the running time of the simulation. If the number is too low, the simulation will not be safe.
</description>
</method>
- <method name="agent_set_max_speed" qualifiers="const">
+ <method name="agent_set_max_speed">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="max_speed" type="float" />
@@ -72,7 +71,7 @@
Sets the maximum speed of the agent. Must be positive.
</description>
</method>
- <method name="agent_set_neighbor_distance" qualifiers="const">
+ <method name="agent_set_neighbor_distance">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="distance" type="float" />
@@ -80,7 +79,7 @@
Sets the maximum distance to other agents this agent takes into account in the navigation. The larger this number, the longer the running time of the simulation. If the number is too low, the simulation will not be safe.
</description>
</method>
- <method name="agent_set_position" qualifiers="const">
+ <method name="agent_set_position">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="position" type="Vector2" />
@@ -88,7 +87,7 @@
Sets the position of the agent in world space.
</description>
</method>
- <method name="agent_set_radius" qualifiers="const">
+ <method name="agent_set_radius">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="radius" type="float" />
@@ -96,7 +95,7 @@
Sets the radius of the agent.
</description>
</method>
- <method name="agent_set_target_velocity" qualifiers="const">
+ <method name="agent_set_target_velocity">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="target_velocity" type="Vector2" />
@@ -104,7 +103,7 @@
Sets the new target velocity.
</description>
</method>
- <method name="agent_set_time_horizon" qualifiers="const">
+ <method name="agent_set_time_horizon">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="time" type="float" />
@@ -112,7 +111,7 @@
The minimal amount of time for which the agent's velocities that are computed by the simulation are safe with respect to other agents. The larger this number, the sooner this agent will respond to the presence of other agents, but the less freedom this agent has in choosing its velocities. Must be positive.
</description>
</method>
- <method name="agent_set_velocity" qualifiers="const">
+ <method name="agent_set_velocity">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="velocity" type="Vector2" />
@@ -120,7 +119,7 @@
Sets the current velocity of the agent.
</description>
</method>
- <method name="free_rid" qualifiers="const">
+ <method name="free_rid">
<return type="void" />
<param index="0" name="rid" type="RID" />
<description>
@@ -133,17 +132,17 @@
Returns all created navigation map [RID]s on the NavigationServer. This returns both 2D and 3D created navigation maps as there is technically no distinction between them.
</description>
</method>
- <method name="link_create" qualifiers="const">
+ <method name="link_create">
<return type="RID" />
<description>
- Create a new link between two locations on a map.
+ Create a new link between two positions on a map.
</description>
</method>
- <method name="link_get_end_location" qualifiers="const">
+ <method name="link_get_end_position" qualifiers="const">
<return type="Vector2" />
<param index="0" name="link" type="RID" />
<description>
- Returns the ending location of this [code]link[/code].
+ Returns the ending position of this [code]link[/code].
</description>
</method>
<method name="link_get_enter_cost" qualifiers="const">
@@ -174,11 +173,11 @@
Returns the [code]ObjectID[/code] of the object which manages this link.
</description>
</method>
- <method name="link_get_start_location" qualifiers="const">
+ <method name="link_get_start_position" qualifiers="const">
<return type="Vector2" />
<param index="0" name="link" type="RID" />
<description>
- Returns the starting location of this [code]link[/code].
+ Returns the starting position of this [code]link[/code].
</description>
</method>
<method name="link_get_travel_cost" qualifiers="const">
@@ -195,7 +194,7 @@
Returns whether this [code]link[/code] can be travelled in both directions.
</description>
</method>
- <method name="link_set_bidirectional" qualifiers="const">
+ <method name="link_set_bidirectional">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="bidirectional" type="bool" />
@@ -203,15 +202,15 @@
Sets whether this [code]link[/code] can be travelled in both directions.
</description>
</method>
- <method name="link_set_end_location" qualifiers="const">
+ <method name="link_set_end_position">
<return type="void" />
<param index="0" name="link" type="RID" />
- <param index="1" name="location" type="Vector2" />
+ <param index="1" name="position" type="Vector2" />
<description>
- Sets the exit location for the [code]link[/code].
+ Sets the exit position for the [code]link[/code].
</description>
</method>
- <method name="link_set_enter_cost" qualifiers="const">
+ <method name="link_set_enter_cost">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="enter_cost" type="float" />
@@ -219,7 +218,7 @@
Sets the [code]enter_cost[/code] for this [code]link[/code].
</description>
</method>
- <method name="link_set_map" qualifiers="const">
+ <method name="link_set_map">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="map" type="RID" />
@@ -227,7 +226,7 @@
Sets the navigation map [RID] for the link.
</description>
</method>
- <method name="link_set_navigation_layers" qualifiers="const">
+ <method name="link_set_navigation_layers">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="navigation_layers" type="int" />
@@ -235,7 +234,7 @@
Set the links's navigation layers. This allows selecting links from a path request (when using [method NavigationServer2D.map_get_path]).
</description>
</method>
- <method name="link_set_owner_id" qualifiers="const">
+ <method name="link_set_owner_id">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="owner_id" type="int" />
@@ -243,15 +242,15 @@
Set the [code]ObjectID[/code] of the object which manages this link.
</description>
</method>
- <method name="link_set_start_location" qualifiers="const">
+ <method name="link_set_start_position">
<return type="void" />
<param index="0" name="link" type="RID" />
- <param index="1" name="location" type="Vector2" />
+ <param index="1" name="position" type="Vector2" />
<description>
- Sets the entry location for this [code]link[/code].
+ Sets the entry position for this [code]link[/code].
</description>
</method>
- <method name="link_set_travel_cost" qualifiers="const">
+ <method name="link_set_travel_cost">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="travel_cost" type="float" />
@@ -259,7 +258,7 @@
Sets the [code]travel_cost[/code] for this [code]link[/code].
</description>
</method>
- <method name="map_create" qualifiers="const">
+ <method name="map_create">
<return type="RID" />
<description>
Create a new map.
@@ -351,7 +350,7 @@
Returns true if the map is active.
</description>
</method>
- <method name="map_set_active" qualifiers="const">
+ <method name="map_set_active">
<return type="void" />
<param index="0" name="map" type="RID" />
<param index="1" name="active" type="bool" />
@@ -359,7 +358,7 @@
Sets the map active.
</description>
</method>
- <method name="map_set_cell_size" qualifiers="const">
+ <method name="map_set_cell_size">
<return type="void" />
<param index="0" name="map" type="RID" />
<param index="1" name="cell_size" type="float" />
@@ -367,7 +366,7 @@
Set the map cell size used to weld the navigation mesh polygons.
</description>
</method>
- <method name="map_set_edge_connection_margin" qualifiers="const">
+ <method name="map_set_edge_connection_margin">
<return type="void" />
<param index="0" name="map" type="RID" />
<param index="1" name="margin" type="float" />
@@ -375,7 +374,7 @@
Set the map edge connection margin used to weld the compatible region edges.
</description>
</method>
- <method name="map_set_link_connection_radius" qualifiers="const">
+ <method name="map_set_link_connection_radius">
<return type="void" />
<param index="0" name="map" type="RID" />
<param index="1" name="radius" type="float" />
@@ -391,7 +390,7 @@
Queries a path in a given navigation map. Start and target position and other parameters are defined through [NavigationPathQueryParameters2D]. Updates the provided [NavigationPathQueryResult2D] result object with the path among other results requested by the query.
</description>
</method>
- <method name="region_create" qualifiers="const">
+ <method name="region_create">
<return type="RID" />
<description>
Creates a new region.
@@ -465,7 +464,7 @@
[b]Note:[/b] If navigation meshes from different navigation regions overlap (which should be avoided in general) the result might not be what is expected.
</description>
</method>
- <method name="region_set_enter_cost" qualifiers="const">
+ <method name="region_set_enter_cost">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="enter_cost" type="float" />
@@ -473,7 +472,7 @@
Sets the [param enter_cost] for this [param region].
</description>
</method>
- <method name="region_set_map" qualifiers="const">
+ <method name="region_set_map">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="map" type="RID" />
@@ -481,7 +480,7 @@
Sets the map for the region.
</description>
</method>
- <method name="region_set_navigation_layers" qualifiers="const">
+ <method name="region_set_navigation_layers">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="navigation_layers" type="int" />
@@ -489,15 +488,15 @@
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">
<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">
+ <method name="region_set_owner_id">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="owner_id" type="int" />
@@ -505,7 +504,7 @@
Set the [code]ObjectID[/code] of the object which manages this region.
</description>
</method>
- <method name="region_set_transform" qualifiers="const">
+ <method name="region_set_transform">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="transform" type="Transform2D" />
@@ -513,7 +512,7 @@
Sets the global transformation for the region.
</description>
</method>
- <method name="region_set_travel_cost" qualifiers="const">
+ <method name="region_set_travel_cost">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="travel_cost" type="float" />
@@ -529,5 +528,10 @@
Emitted when a navigation map is updated, when a region moves or is modified.
</description>
</signal>
+ <signal name="navigation_debug_changed">
+ <description>
+ Emitted when navigation debug settings are changed. Only available in debug builds.
+ </description>
+ </signal>
</signals>
</class>
diff --git a/doc/classes/NavigationServer3D.xml b/doc/classes/NavigationServer3D.xml
index c7da3b7b5b..340821d41e 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>
@@ -15,9 +15,10 @@
</description>
<tutorials>
<link title="3D Navmesh Demo">https://godotengine.org/asset-library/asset/124</link>
+ <link title="Using NavigationServer">$DOCS_URL/tutorials/navigation/navigation_using_navigationservers.html</link>
</tutorials>
<methods>
- <method name="agent_create" qualifiers="const">
+ <method name="agent_create">
<return type="RID" />
<description>
Creates the agent.
@@ -37,18 +38,16 @@
Returns true if the map got changed the previous frame.
</description>
</method>
- <method name="agent_set_callback" qualifiers="const">
+ <method name="agent_set_callback">
<return type="void" />
<param index="0" name="agent" type="RID" />
- <param index="1" name="object_id" type="int" />
- <param index="2" name="method" type="StringName" />
- <param index="3" name="userdata" type="Variant" default="null" />
+ <param index="1" name="callback" type="Callable" />
<description>
- 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].
+ Sets the callback that gets called after each avoidance processing step for the [param agent]. The calculated [code]safe_velocity[/code] will be passed as the first parameter 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 an empty [Callable].
</description>
</method>
- <method name="agent_set_map" qualifiers="const">
+ <method name="agent_set_map">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="map" type="RID" />
@@ -56,7 +55,7 @@
Puts the agent in the map.
</description>
</method>
- <method name="agent_set_max_neighbors" qualifiers="const">
+ <method name="agent_set_max_neighbors">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="count" type="int" />
@@ -64,7 +63,7 @@
Sets the maximum number of other agents the agent takes into account in the navigation. The larger this number, the longer the running time of the simulation. If the number is too low, the simulation will not be safe.
</description>
</method>
- <method name="agent_set_max_speed" qualifiers="const">
+ <method name="agent_set_max_speed">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="max_speed" type="float" />
@@ -72,7 +71,7 @@
Sets the maximum speed of the agent. Must be positive.
</description>
</method>
- <method name="agent_set_neighbor_distance" qualifiers="const">
+ <method name="agent_set_neighbor_distance">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="distance" type="float" />
@@ -80,7 +79,7 @@
Sets the maximum distance to other agents this agent takes into account in the navigation. The larger this number, the longer the running time of the simulation. If the number is too low, the simulation will not be safe.
</description>
</method>
- <method name="agent_set_position" qualifiers="const">
+ <method name="agent_set_position">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="position" type="Vector3" />
@@ -88,7 +87,7 @@
Sets the position of the agent in world space.
</description>
</method>
- <method name="agent_set_radius" qualifiers="const">
+ <method name="agent_set_radius">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="radius" type="float" />
@@ -96,7 +95,7 @@
Sets the radius of the agent.
</description>
</method>
- <method name="agent_set_target_velocity" qualifiers="const">
+ <method name="agent_set_target_velocity">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="target_velocity" type="Vector3" />
@@ -104,7 +103,7 @@
Sets the new target velocity.
</description>
</method>
- <method name="agent_set_time_horizon" qualifiers="const">
+ <method name="agent_set_time_horizon">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="time" type="float" />
@@ -112,7 +111,7 @@
The minimal amount of time for which the agent's velocities that are computed by the simulation are safe with respect to other agents. The larger this number, the sooner this agent will respond to the presence of other agents, but the less freedom this agent has in choosing its velocities. Must be positive.
</description>
</method>
- <method name="agent_set_velocity" qualifiers="const">
+ <method name="agent_set_velocity">
<return type="void" />
<param index="0" name="agent" type="RID" />
<param index="1" name="velocity" type="Vector3" />
@@ -120,7 +119,7 @@
Sets the current velocity of the agent.
</description>
</method>
- <method name="free_rid" qualifiers="const">
+ <method name="free_rid">
<return type="void" />
<param index="0" name="rid" type="RID" />
<description>
@@ -133,17 +132,24 @@
Returns all created navigation map [RID]s on the NavigationServer. This returns both 2D and 3D created navigation maps as there is technically no distinction between them.
</description>
</method>
- <method name="link_create" qualifiers="const">
+ <method name="get_process_info" qualifiers="const">
+ <return type="int" />
+ <param index="0" name="process_info" type="int" enum="NavigationServer3D.ProcessInfo" />
+ <description>
+ Returns information about the current state of the NavigationServer. See [enum ProcessInfo] for a list of available states.
+ </description>
+ </method>
+ <method name="link_create">
<return type="RID" />
<description>
- Create a new link between two locations on a map.
+ Create a new link between two positions on a map.
</description>
</method>
- <method name="link_get_end_location" qualifiers="const">
+ <method name="link_get_end_position" qualifiers="const">
<return type="Vector3" />
<param index="0" name="link" type="RID" />
<description>
- Returns the ending location of this [code]link[/code].
+ Returns the ending position of this [code]link[/code].
</description>
</method>
<method name="link_get_enter_cost" qualifiers="const">
@@ -174,11 +180,11 @@
Returns the [code]ObjectID[/code] of the object which manages this link.
</description>
</method>
- <method name="link_get_start_location" qualifiers="const">
+ <method name="link_get_start_position" qualifiers="const">
<return type="Vector3" />
<param index="0" name="link" type="RID" />
<description>
- Returns the starting location of this [code]link[/code].
+ Returns the starting position of this [code]link[/code].
</description>
</method>
<method name="link_get_travel_cost" qualifiers="const">
@@ -195,7 +201,7 @@
Returns whether this [code]link[/code] can be travelled in both directions.
</description>
</method>
- <method name="link_set_bidirectional" qualifiers="const">
+ <method name="link_set_bidirectional">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="bidirectional" type="bool" />
@@ -203,15 +209,15 @@
Sets whether this [code]link[/code] can be travelled in both directions.
</description>
</method>
- <method name="link_set_end_location" qualifiers="const">
+ <method name="link_set_end_position">
<return type="void" />
<param index="0" name="link" type="RID" />
- <param index="1" name="location" type="Vector3" />
+ <param index="1" name="position" type="Vector3" />
<description>
- Sets the exit location for the [code]link[/code].
+ Sets the exit position for the [code]link[/code].
</description>
</method>
- <method name="link_set_enter_cost" qualifiers="const">
+ <method name="link_set_enter_cost">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="enter_cost" type="float" />
@@ -219,7 +225,7 @@
Sets the [code]enter_cost[/code] for this [code]link[/code].
</description>
</method>
- <method name="link_set_map" qualifiers="const">
+ <method name="link_set_map">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="map" type="RID" />
@@ -227,7 +233,7 @@
Sets the navigation map [RID] for the link.
</description>
</method>
- <method name="link_set_navigation_layers" qualifiers="const">
+ <method name="link_set_navigation_layers">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="navigation_layers" type="int" />
@@ -235,7 +241,7 @@
Set the links's navigation layers. This allows selecting links from a path request (when using [method NavigationServer3D.map_get_path]).
</description>
</method>
- <method name="link_set_owner_id" qualifiers="const">
+ <method name="link_set_owner_id">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="owner_id" type="int" />
@@ -243,15 +249,15 @@
Set the [code]ObjectID[/code] of the object which manages this link.
</description>
</method>
- <method name="link_set_start_location" qualifiers="const">
+ <method name="link_set_start_position">
<return type="void" />
<param index="0" name="link" type="RID" />
- <param index="1" name="location" type="Vector3" />
+ <param index="1" name="position" type="Vector3" />
<description>
- Sets the entry location for this [code]link[/code].
+ Sets the entry position for this [code]link[/code].
</description>
</method>
- <method name="link_set_travel_cost" qualifiers="const">
+ <method name="link_set_travel_cost">
<return type="void" />
<param index="0" name="link" type="RID" />
<param index="1" name="travel_cost" type="float" />
@@ -259,7 +265,7 @@
Sets the [code]travel_cost[/code] for this [code]link[/code].
</description>
</method>
- <method name="map_create" qualifiers="const">
+ <method name="map_create">
<return type="RID" />
<description>
Create a new map.
@@ -376,7 +382,7 @@
Returns true if the map is active.
</description>
</method>
- <method name="map_set_active" qualifiers="const">
+ <method name="map_set_active">
<return type="void" />
<param index="0" name="map" type="RID" />
<param index="1" name="active" type="bool" />
@@ -384,7 +390,7 @@
Sets the map active.
</description>
</method>
- <method name="map_set_cell_size" qualifiers="const">
+ <method name="map_set_cell_size">
<return type="void" />
<param index="0" name="map" type="RID" />
<param index="1" name="cell_size" type="float" />
@@ -392,7 +398,7 @@
Set the map cell size used to weld the navigation mesh polygons.
</description>
</method>
- <method name="map_set_edge_connection_margin" qualifiers="const">
+ <method name="map_set_edge_connection_margin">
<return type="void" />
<param index="0" name="map" type="RID" />
<param index="1" name="margin" type="float" />
@@ -400,7 +406,7 @@
Set the map edge connection margin used to weld the compatible region edges.
</description>
</method>
- <method name="map_set_link_connection_radius" qualifiers="const">
+ <method name="map_set_link_connection_radius">
<return type="void" />
<param index="0" name="map" type="RID" />
<param index="1" name="radius" type="float" />
@@ -408,7 +414,7 @@
Set the map's link connection radius used to connect links to navigation polygons.
</description>
</method>
- <method name="map_set_up" qualifiers="const">
+ <method name="map_set_up">
<return type="void" />
<param index="0" name="map" type="RID" />
<param index="1" name="up" type="Vector3" />
@@ -433,15 +439,15 @@
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">
<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">
+ <method name="region_create">
<return type="RID" />
<description>
Creates a new region.
@@ -515,7 +521,7 @@
[b]Note:[/b] If navigation meshes from different navigation regions overlap (which should be avoided in general) the result might not be what is expected.
</description>
</method>
- <method name="region_set_enter_cost" qualifiers="const">
+ <method name="region_set_enter_cost">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="enter_cost" type="float" />
@@ -523,7 +529,7 @@
Sets the [param enter_cost] for this [param region].
</description>
</method>
- <method name="region_set_map" qualifiers="const">
+ <method name="region_set_map">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="map" type="RID" />
@@ -531,7 +537,7 @@
Sets the map for the region.
</description>
</method>
- <method name="region_set_navigation_layers" qualifiers="const">
+ <method name="region_set_navigation_layers">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="navigation_layers" type="int" />
@@ -539,15 +545,15 @@
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">
<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>
</method>
- <method name="region_set_owner_id" qualifiers="const">
+ <method name="region_set_owner_id">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="owner_id" type="int" />
@@ -555,7 +561,7 @@
Set the [code]ObjectID[/code] of the object which manages this region.
</description>
</method>
- <method name="region_set_transform" qualifiers="const">
+ <method name="region_set_transform">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="transform" type="Transform3D" />
@@ -563,7 +569,7 @@
Sets the global transformation for the region.
</description>
</method>
- <method name="region_set_travel_cost" qualifiers="const">
+ <method name="region_set_travel_cost">
<return type="void" />
<param index="0" name="region" type="RID" />
<param index="1" name="travel_cost" type="float" />
@@ -571,7 +577,7 @@
Sets the [param travel_cost] for this [param region].
</description>
</method>
- <method name="set_active" qualifiers="const">
+ <method name="set_active">
<return type="void" />
<param index="0" name="active" type="bool" />
<description>
@@ -592,4 +598,33 @@
</description>
</signal>
</signals>
+ <constants>
+ <constant name="INFO_ACTIVE_MAPS" value="0" enum="ProcessInfo">
+ Constant to get the number of active navigation maps.
+ </constant>
+ <constant name="INFO_REGION_COUNT" value="1" enum="ProcessInfo">
+ Constant to get the number of active navigation regions.
+ </constant>
+ <constant name="INFO_AGENT_COUNT" value="2" enum="ProcessInfo">
+ Constant to get the number of active navigation agents processing avoidance.
+ </constant>
+ <constant name="INFO_LINK_COUNT" value="3" enum="ProcessInfo">
+ Constant to get the number of active navigation links.
+ </constant>
+ <constant name="INFO_POLYGON_COUNT" value="4" enum="ProcessInfo">
+ Constant to get the number of navigation mesh polygons.
+ </constant>
+ <constant name="INFO_EDGE_COUNT" value="5" enum="ProcessInfo">
+ Constant to get the number of navigation mesh polygon edges.
+ </constant>
+ <constant name="INFO_EDGE_MERGE_COUNT" value="6" enum="ProcessInfo">
+ Constant to get the number of navigation mesh polygon edges that were merged due to edge key overlap.
+ </constant>
+ <constant name="INFO_EDGE_CONNECTION_COUNT" value="7" enum="ProcessInfo">
+ Constant to get the number of navigation mesh polygon edges that are considered connected by edge proximity.
+ </constant>
+ <constant name="INFO_EDGE_FREE_COUNT" value="8" enum="ProcessInfo">
+ Constant to get the number of navigation mesh polygon edges that could not be merged but may be still connected by edge proximity or with links.
+ </constant>
+ </constants>
</class>
diff --git a/doc/classes/Node.xml b/doc/classes/Node.xml
index 24df5977f9..7c40c189c0 100644
--- a/doc/classes/Node.xml
+++ b/doc/classes/Node.xml
@@ -421,6 +421,12 @@
Returns the node's [Viewport].
</description>
</method>
+ <method name="get_window" qualifiers="const">
+ <return type="Window" />
+ <description>
+ Returns the [Window] that contains this node. If the node is in the main window, this is equivalent to getting the root node ([code]get_tree().get_root()[/code]).
+ </description>
+ </method>
<method name="has_node" qualifiers="const">
<return type="bool" />
<param index="0" name="path" type="NodePath" />
@@ -612,6 +618,15 @@
Removes a node from the [param group]. Does nothing if the node is not in the [param group]. See notes in the description, and the group methods in [SceneTree].
</description>
</method>
+ <method name="reparent">
+ <return type="void" />
+ <param index="0" name="new_parent" type="Node" />
+ <param index="1" name="keep_global_transform" type="bool" default="true" />
+ <description>
+ Changes the parent of this [Node] to the [param new_parent]. The node needs to already have a parent.
+ If [param keep_global_transform] is [code]true[/code], the node's global transform will be preserved if supported. [Node2D], [Node3D] and [Control] support this argument (but [Control] keeps only position).
+ </description>
+ </method>
<method name="replace_by">
<return type="void" />
<param index="0" name="node" type="Node" />
@@ -651,7 +666,7 @@
channel = 0,
}
[/codeblock]
- See [enum MultiplayerAPI.RPCMode] and [enum MultiplayerPeer.TransferMode]. An alternative is annotating methods and properties with the corresponding annotation ([code]@rpc(any)[/code], [code]@rpc(authority)[/code]). By default, methods are not exposed to networking (and RPCs).
+ See [enum MultiplayerAPI.RPCMode] and [enum MultiplayerPeer.TransferMode]. An alternative is annotating methods and properties with the corresponding annotation ([code]@rpc("any")[/code], [code]@rpc("authority")[/code]). By default, methods are not exposed to networking (and RPCs).
</description>
</method>
<method name="rpc_id" qualifiers="vararg">
@@ -894,6 +909,9 @@
<constant name="NOTIFICATION_ENABLED" value="29">
Notification received when the node is enabled again after being disabled. See [constant PROCESS_MODE_DISABLED].
</constant>
+ <constant name="NOTIFICATION_NODE_RECACHE_REQUESTED" value="30">
+ Notification received when other nodes in the tree may have been removed/replaced and node pointers may require re-caching.
+ </constant>
<constant name="NOTIFICATION_EDITOR_PRE_SAVE" value="9001">
Notification received right before the scene with the node is saved in the editor. This notification is only sent in the Godot editor and will not occur in exported projects.
</constant>
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..04895c28a8 100644
--- a/doc/classes/OS.xml
+++ b/doc/classes/OS.xml
@@ -498,7 +498,7 @@
<description>
Returns [code]true[/code] if the Godot binary used to run the project is a [i]debug[/i] export template, or when running in the editor.
Returns [code]false[/code] if the Godot binary used to run the project is a [i]release[/i] export template.
- To check whether the Godot binary used to run the project is an export template (debug or release), use [code]OS.has_feature("standalone")[/code] instead.
+ To check whether the Godot binary used to run the project is an export template (debug or release), use [code]OS.has_feature("template")[/code] instead.
</description>
</method>
<method name="is_keycode_unicode" qualifiers="const">
@@ -566,16 +566,15 @@
<method name="open_midi_inputs">
<return type="void" />
<description>
- Initialises the singleton for the system MIDI driver.
+ Initializes the singleton for the system MIDI driver.
[b]Note:[/b] This method is implemented on Linux, macOS and Windows.
</description>
</method>
<method name="read_string_from_stdin">
<return type="String" />
- <param index="0" name="block" type="bool" default="true" />
<description>
- Reads a user input string from the standard input (usually the terminal).
- [b]Note:[/b] This method is implemented on Linux, macOS and Windows. Non-blocking reads are not currently supported on any platform.
+ Reads a user input string from the standard input (usually the terminal). This operation is [i]blocking[/i], which causes the window to freeze if [method read_string_from_stdin] is called on the main thread. The thread calling [method read_string_from_stdin] will block until the program receives a line break in standard input (usually by the user pressing [kbd]Enter[/kbd]).
+ [b]Note:[/b] This method is implemented on Linux, macOS and Windows.
</description>
</method>
<method name="request_permission">
@@ -593,12 +592,12 @@
</description>
</method>
<method name="set_environment" qualifiers="const">
- <return type="bool" />
+ <return type="void" />
<param index="0" name="variable" type="String" />
<param index="1" name="value" type="String" />
<description>
Sets the value of the environment variable [param variable] to [param value]. The environment variable will be set for the Godot process and any process executed with [method execute] after running [method set_environment]. The environment variable will [i]not[/i] persist to processes run after the Godot process was terminated.
- [b]Note:[/b] Double-check the casing of [param variable]. Environment variable names are case-sensitive on all platforms except Windows.
+ [b]Note:[/b] Environment variable names are case-sensitive on all platforms except Windows. The [param variable] name cannot be empty or include the [code]=[/code] character. On Windows, there is a 32767 characters limit for the combined length of [param variable], [param value], and the [code]=[/code] and null terminator characters that will be registered in the environment block.
</description>
</method>
<method name="set_restart_on_exit">
@@ -638,6 +637,14 @@
[b]Note:[/b] This method is implemented on Android, iOS, Web, Linux, macOS and Windows.
</description>
</method>
+ <method name="unset_environment" qualifiers="const">
+ <return type="void" />
+ <param index="0" name="variable" type="String" />
+ <description>
+ Removes the environment [param variable] from the current environment, if it exists. The environment variable will be removed for the Godot process and any process executed with [method execute] after running [method unset_environment]. The removal of the environment variable will [i]not[/i] persist to processes run after the Godot process was terminated.
+ [b]Note:[/b] Environment variable names are case-sensitive on all platforms except Windows. The [param variable] name cannot be empty or include the [code]=[/code] character.
+ </description>
+ </method>
</methods>
<members>
<member name="low_processor_usage_mode" type="bool" setter="set_low_processor_usage_mode" getter="is_in_low_processor_usage_mode" default="false">
@@ -654,63 +661,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 e015bec134..e30ff6be19 100644
--- a/doc/classes/Object.xml
+++ b/doc/classes/Object.xml
@@ -24,6 +24,7 @@
[b]Note:[/b] The [code]script[/code] is not exposed like most properties. To set or get an object's [Script] in code, use [method set_script] and [method get_script], respectively.
</description>
<tutorials>
+ <link title="Object class introduction">$DOCS_URL/contributing/development/core_and_modules/object_class.html</link>
<link title="When and how to avoid using nodes for everything">$DOCS_URL/tutorials/best_practices/node_alternatives.html</link>
<link title="Object notifications">$DOCS_URL/tutorials/best_practices/godot_notifications.html</link>
</tutorials>
@@ -109,7 +110,7 @@
[/gdscript]
[csharp]
[Tool]
- public class MyNode2D : Node2D
+ public partial class MyNode2D : Node2D
{
private bool _holdingHammer;
@@ -304,7 +305,7 @@
[/gdscript]
[csharp]
var node = new Node3D();
- node.Call("rotate", new Vector3(1f, 0f, 0f), 1.571f);
+ node.Call(Node3D.MethodName.Rotate, new Vector3(1f, 0f, 0f), 1.571f);
[/csharp]
[/codeblocks]
[b]Note:[/b] In C#, [param method] must be in snake_case when referring to built-in Godot methods. Prefer using the names exposed in the [code]MethodName[/code] class to avoid allocating a new [StringName] on each call.
@@ -322,7 +323,7 @@
[/gdscript]
[csharp]
var node = new Node3D();
- node.CallDeferred("rotate", new Vector3(1f, 0f, 0f), 1.571f);
+ node.CallDeferred(Node3D.MethodName.Rotate, new Vector3(1f, 0f, 0f), 1.571f);
[/csharp]
[/codeblocks]
[b]Note:[/b] In C#, [param method] must be in snake_case when referring to built-in Godot methods. Prefer using the names exposed in the [code]MethodName[/code] class to avoid allocating a new [StringName] on each call.
@@ -341,7 +342,7 @@
[/gdscript]
[csharp]
var node = new Node3D();
- node.Callv("rotate", new Godot.Collections.Array { new Vector3(1f, 0f, 0f), 1.571f });
+ node.Callv(Node3D.MethodName.Rotate, new Godot.Collections.Array { new Vector3(1f, 0f, 0f), 1.571f });
[/csharp]
[/codeblocks]
[b]Note:[/b] In C#, [param method] must be in snake_case when referring to built-in Godot methods. Prefer using the names exposed in the [code]MethodName[/code] class to avoid allocating a new [StringName] on each call
@@ -393,8 +394,8 @@
// This assumes that a `Player` class exists, which defines a `Hit` signal.
var player = new Player();
- // Signals as events (`player.Hit += OnPlayerHit;`) do not support argument binding. You have to use:
- player.Hit.Connect(OnPlayerHit, new Godot.Collections.Array {"sword", 100 });
+ // We can use lambdas when we need to bind additional parameters.
+ player.Hit += () =&gt; OnPlayerHit("sword", 100);
}
private void OnButtonDown()
@@ -404,7 +405,7 @@
private void OnPlayerHit(string weaponType, int damage)
{
- GD.Print(String.Format("Hit with weapon {0} for {1} damage.", weaponType, damage));
+ GD.Print($"Hit with weapon {weaponType} for {damage} damage.");
}
[/csharp]
[/codeblocks]
@@ -430,16 +431,12 @@
public override void _Ready()
{
var button = new Button();
- // Option 1: Object.Connect() with an implicit Callable for the defined function.
- button.Connect("button_down", OnButtonDown);
- // Option 2: Object.connect() with a constructed Callable using a target object and method name.
- button.Connect("button_down", new Callable(self, nameof(OnButtonDown)));
- // Option 3: Signal.connect() with an implicit Callable for the defined function.
- button.ButtonDown.Connect(OnButtonDown);
- // Option 3b: In C#, we can use signals as events and connect with this more idiomatic syntax:
+ // Option 1: In C#, we can use signals as events and connect with this idiomatic syntax:
button.ButtonDown += OnButtonDown;
- // Option 4: Signal.connect() with a constructed Callable using a target object and method name.
- button.ButtonDown.Connect(new Callable(self, nameof(OnButtonDown)));
+ // Option 2: GodotObject.Connect() with a constructed Callable from a method group.
+ button.Connect(Button.SignalName.ButtonDown, Callable.From(OnButtonDown));
+ // Option 3: GodotObject.Connect() with a constructed Callable using a target object and method name.
+ button.Connect(Button.SignalName.ButtonDown, new Callable(this, MethodName.OnButtonDown));
}
private void OnButtonDown()
@@ -457,6 +454,7 @@
func _ready():
# This assumes that a `Player` class exists, which defines a `hit` signal.
var player = Player.new()
+ # Using Callable.bind().
player.hit.connect(_on_player_hit.bind("sword", 100))
# Parameters added when emitting the signal are passed first.
@@ -472,20 +470,19 @@
{
// This assumes that a `Player` class exists, which defines a `Hit` signal.
var player = new Player();
- // Option 1: Using Callable.Bind(). This way we can still use signals as events.
- player.Hit += OnPlayerHit.Bind("sword", 100);
- // Option 2: Using a `binds` Array in Signal.Connect().
- player.Hit.Connect(OnPlayerHit, new Godot.Collections.Array{ "sword", 100 });
+ // Using lambda expressions that create a closure that captures the additional parameters.
+ // The lambda only receives the parameters defined by the signal's delegate.
+ player.Hit += (hitBy, level) =&gt; OnPlayerHit(hitBy, level, "sword", 100);
// Parameters added when emitting the signal are passed first.
- player.EmitSignal("hit", "Dark lord", 5);
+ player.EmitSignal(SignalName.Hit, "Dark lord", 5);
}
// We pass two arguments when emitting (`hit_by`, `level`),
// and bind two more arguments when connecting (`weapon_type`, `damage`).
private void OnPlayerHit(string hitBy, int level, string weaponType, int damage)
{
- GD.Print(String.Format("Hit by {0} (level {1}) with weapon {2} for {3} damage.", hitBy, level, weaponType, damage));
+ GD.Print($"Hit by {hitBy} (level {level}) with weapon {weaponType} for {damage} damage.");
}
[/csharp]
[/codeblocks]
@@ -511,8 +508,8 @@
emit_signal("game_over")
[/gdscript]
[csharp]
- EmitSignal("Hit", "sword", 100);
- EmitSignal("GameOver");
+ EmitSignal(SignalName.Hit, "sword", 100);
+ EmitSignal(SignalName.GameOver);
[/csharp]
[/codeblocks]
[b]Note:[/b] In C#, [param signal] must be in snake_case when referring to built-in Godot signals. Prefer using the names exposed in the [code]SignalName[/code] class to avoid allocating a new [StringName] on each call.
@@ -580,7 +577,7 @@
var b = node.GetIndexed("position:y"); // b is -10
[/csharp]
[/codeblocks]
- [b]Note:[/b] In C#, [param property_path] must be in snake_case when referring to built-in Godot properties.
+ [b]Note:[/b] In C#, [param property_path] must be in snake_case when referring to built-in Godot properties. Prefer using the names exposed in the [code]PropertyName[/code] class to avoid allocating a new [StringName] on each call.
[b]Note:[/b] This method does not support actual paths to nodes in the [SceneTree], only sub-property paths. In the context of nodes, use [method Node.get_node_and_resource] instead.
</description>
</method>
@@ -703,10 +700,10 @@
sprite2d.is_class("Node3D") # Returns false
[/gdscript]
[csharp]
- var sprite2d = new Sprite2D();
- sprite2d.IsClass("Sprite2D"); // Returns true
- sprite2d.IsClass("Node"); // Returns true
- sprite2d.IsClass("Node3D"); // Returns false
+ var sprite2D = new Sprite2D();
+ sprite2D.IsClass("Sprite2D"); // Returns true
+ sprite2D.IsClass("Node"); // Returns true
+ sprite2D.IsClass("Node3D"); // Returns false
[/csharp]
[/codeblocks]
[b]Note:[/b] This method ignores [code]class_name[/code] declarations in the object's script.
@@ -750,10 +747,10 @@
player.SetScript(GD.Load("res://player.gd"));
player.Notification(NotificationEnterTree);
- // The call order is Object -&gt; Node -&gt; Node2D -&gt; player.gd.
+ // The call order is GodotObject -&gt; Node -&gt; Node2D -&gt; player.gd.
- player.notification(NotificationEnterTree, true);
- // The call order is player.gd -&gt; Node2D -&gt; Node -&gt; Object.
+ player.Notification(NotificationEnterTree, true);
+ // The call order is player.gd -&gt; Node2D -&gt; Node -&gt; GodotObject.
[/csharp]
[/codeblocks]
</description>
@@ -867,7 +864,7 @@
GD.Print(node.Position); // Prints (42, -10)
[/csharp]
[/codeblocks]
- [b]Note:[/b] In C#, [param property_path] must be in snake_case when referring to built-in Godot properties.
+ [b]Note:[/b] In C#, [param property_path] must be in snake_case when referring to built-in Godot properties. Prefer using the names exposed in the [code]PropertyName[/code] class to avoid allocating a new [StringName] on each call.
</description>
</method>
<method name="set_message_translation">
@@ -882,7 +879,7 @@
<param index="0" name="name" type="StringName" />
<param index="1" name="value" type="Variant" />
<description>
- Adds or changes the entry [param name] inside the object's metadata. The metadata [param value] can be any [Variant], although some types cannot be serialised correctly.
+ Adds or changes the entry [param name] inside the object's metadata. The metadata [param value] can be any [Variant], although some types cannot be serialized correctly.
If [param value] is [code]null[/code], the entry is removed. This is the equivalent of using [method remove_meta]. See also [method has_meta] and [method get_meta].
[b]Note:[/b] Metadata that has a [param name] starting with an underscore ([code]_[/code]) is considered editor-only. Editor-only metadata is not displayed in the Inspector dock and should not be edited.
</description>
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/PackedScene.xml b/doc/classes/PackedScene.xml
index 7ca1d5d60d..493fc9e2a8 100644
--- a/doc/classes/PackedScene.xml
+++ b/doc/classes/PackedScene.xml
@@ -104,7 +104,7 @@
</method>
</methods>
<members>
- <member name="_bundled" type="Dictionary" setter="_set_bundled_scene" getter="_get_bundled_scene" default="{ &quot;conn_count&quot;: 0, &quot;conns&quot;: PackedInt32Array(), &quot;editable_instances&quot;: [], &quot;names&quot;: PackedStringArray(), &quot;node_count&quot;: 0, &quot;node_paths&quot;: [], &quot;nodes&quot;: PackedInt32Array(), &quot;variants&quot;: [], &quot;version&quot;: 2 }">
+ <member name="_bundled" type="Dictionary" setter="_set_bundled_scene" getter="_get_bundled_scene" default="{ &quot;conn_count&quot;: 0, &quot;conns&quot;: PackedInt32Array(), &quot;editable_instances&quot;: [], &quot;names&quot;: PackedStringArray(), &quot;node_count&quot;: 0, &quot;node_paths&quot;: [], &quot;nodes&quot;: PackedInt32Array(), &quot;variants&quot;: [], &quot;version&quot;: 3 }">
A dictionary representation of the scene contents.
Available keys include "rnames" and "variants" for resources, "node_count", "nodes", "node_paths" for nodes, "editable_instances" for base scene children overrides, "conn_count" and "conns" for signal connections, and "version" for the format style of the PackedScene.
</member>
diff --git a/doc/classes/PacketPeerDTLS.xml b/doc/classes/PacketPeerDTLS.xml
index db8403a56b..19c5d0e287 100644
--- a/doc/classes/PacketPeerDTLS.xml
+++ b/doc/classes/PacketPeerDTLS.xml
@@ -14,11 +14,10 @@
<method name="connect_to_peer">
<return type="int" enum="Error" />
<param index="0" name="packet_peer" type="PacketPeerUDP" />
- <param index="1" name="validate_certs" type="bool" default="true" />
- <param index="2" name="for_hostname" type="String" default="&quot;&quot;" />
- <param index="3" name="valid_certificate" type="X509Certificate" default="null" />
+ <param index="1" name="hostname" type="String" />
+ <param index="2" name="client_options" type="TLSOptions" default="null" />
<description>
- Connects a [param packet_peer] beginning the DTLS handshake using the underlying [PacketPeerUDP] which must be connected (see [method PacketPeerUDP.connect_to_host]). If [param validate_certs] is [code]true[/code], [PacketPeerDTLS] will validate that the certificate presented by the remote peer and match it with the [param for_hostname] argument. You can specify a custom [X509Certificate] to use for validation via the [param valid_certificate] argument.
+ Connects a [param packet_peer] beginning the DTLS handshake using the underlying [PacketPeerUDP] which must be connected (see [method PacketPeerUDP.connect_to_host]). You can optionally specify the [param client_options] to be used while verifying the TLS connections. See [method TLSOptions.client] and [method TLSOptions.client_unsafe].
</description>
</method>
<method name="disconnect_from_peer">
diff --git a/doc/classes/ParticleProcessMaterial.xml b/doc/classes/ParticleProcessMaterial.xml
index d4050e3bd1..d046d52ed1 100644
--- a/doc/classes/ParticleProcessMaterial.xml
+++ b/doc/classes/ParticleProcessMaterial.xml
@@ -123,7 +123,8 @@
</member>
<member name="collision_mode" type="int" setter="set_collision_mode" getter="get_collision_mode" enum="ParticleProcessMaterial.CollisionMode" default="0">
The particles' collision mode.
- [b]Note:[/b] Particles can only collide with [GPUParticlesCollision3D] nodes, not [PhysicsBody3D] nodes. To make particles collide with various objects, you can add [GPUParticlesCollision3D] nodes as children of [PhysicsBody3D] nodes.
+ [b]Note:[/b] 3D Particles can only collide with [GPUParticlesCollision3D] nodes, not [PhysicsBody3D] nodes. To make particles collide with various objects, you can add [GPUParticlesCollision3D] nodes as children of [PhysicsBody3D] nodes.
+ [b]Note:[/b] 2D Particles can only collide with [LightOccluder2D] nodes, not [PhysicsBody2D] nodes.
</member>
<member name="collision_use_scale" type="bool" setter="set_collision_use_scale" getter="is_collision_using_scale" default="false">
Should collision take scale into account.
diff --git a/doc/classes/Performance.xml b/doc/classes/Performance.xml
index 381fa3e9ef..493af8aff2 100644
--- a/doc/classes/Performance.xml
+++ b/doc/classes/Performance.xml
@@ -45,7 +45,7 @@
[csharp]
public override void _Ready()
{
- var monitorValue = new Callable(this, nameof(GetMonitorValue));
+ var monitorValue = new Callable(this, MethodName.GetMonitorValue);
// Adds monitor with name "MyName" to category "MyCategory".
Performance.AddCustomMonitor("MyCategory/MyMonitor", monitorValue);
@@ -131,67 +131,97 @@
<constant name="TIME_PHYSICS_PROCESS" value="2" enum="Monitor">
Time it took to complete one physics frame, in seconds. [i]Lower is better.[/i]
</constant>
- <constant name="MEMORY_STATIC" value="3" enum="Monitor">
+ <constant name="TIME_NAVIGATION_PROCESS" value="3" enum="Monitor">
+ Time it took to complete one navigation step, in seconds. This includes navigation map updates as well as agent avoidance calculations. [i]Lower is better.[/i]
+ </constant>
+ <constant name="MEMORY_STATIC" value="4" enum="Monitor">
Static memory currently used, in bytes. Not available in release builds. [i]Lower is better.[/i]
</constant>
- <constant name="MEMORY_STATIC_MAX" value="4" enum="Monitor">
+ <constant name="MEMORY_STATIC_MAX" value="5" enum="Monitor">
Available static memory. Not available in release builds. [i]Lower is better.[/i]
</constant>
- <constant name="MEMORY_MESSAGE_BUFFER_MAX" value="5" enum="Monitor">
+ <constant name="MEMORY_MESSAGE_BUFFER_MAX" value="6" enum="Monitor">
Largest amount of memory the message queue buffer has used, in bytes. The message queue is used for deferred functions calls and notifications. [i]Lower is better.[/i]
</constant>
- <constant name="OBJECT_COUNT" value="6" enum="Monitor">
+ <constant name="OBJECT_COUNT" value="7" enum="Monitor">
Number of objects currently instantiated (including nodes). [i]Lower is better.[/i]
</constant>
- <constant name="OBJECT_RESOURCE_COUNT" value="7" enum="Monitor">
+ <constant name="OBJECT_RESOURCE_COUNT" value="8" enum="Monitor">
Number of resources currently used. [i]Lower is better.[/i]
</constant>
- <constant name="OBJECT_NODE_COUNT" value="8" enum="Monitor">
+ <constant name="OBJECT_NODE_COUNT" value="9" enum="Monitor">
Number of nodes currently instantiated in the scene tree. This also includes the root node. [i]Lower is better.[/i]
</constant>
- <constant name="OBJECT_ORPHAN_NODE_COUNT" value="9" enum="Monitor">
+ <constant name="OBJECT_ORPHAN_NODE_COUNT" value="10" enum="Monitor">
Number of orphan nodes, i.e. nodes which are not parented to a node of the scene tree. [i]Lower is better.[/i]
</constant>
- <constant name="RENDER_TOTAL_OBJECTS_IN_FRAME" value="10" enum="Monitor">
+ <constant name="RENDER_TOTAL_OBJECTS_IN_FRAME" value="11" enum="Monitor">
The total number of objects in the last rendered frame. This metric doesn't include culled objects (either via hiding nodes, frustum culling or occlusion culling). [i]Lower is better.[/i]
</constant>
- <constant name="RENDER_TOTAL_PRIMITIVES_IN_FRAME" value="11" enum="Monitor">
+ <constant name="RENDER_TOTAL_PRIMITIVES_IN_FRAME" value="12" enum="Monitor">
The total number of vertices or indices rendered in the last rendered frame. This metric doesn't include primitives from culled objects (either via hiding nodes, frustum culling or occlusion culling). Due to the depth prepass and shadow passes, the number of primitives is always higher than the actual number of vertices in the scene (typically double or triple the original vertex count). [i]Lower is better.[/i]
</constant>
- <constant name="RENDER_TOTAL_DRAW_CALLS_IN_FRAME" value="12" enum="Monitor">
+ <constant name="RENDER_TOTAL_DRAW_CALLS_IN_FRAME" value="13" enum="Monitor">
The total number of draw calls performed in the last rendered frame. This metric doesn't include culled objects (either via hiding nodes, frustum culling or occlusion culling), since they do not result in draw calls. [i]Lower is better.[/i]
</constant>
- <constant name="RENDER_VIDEO_MEM_USED" value="13" enum="Monitor">
+ <constant name="RENDER_VIDEO_MEM_USED" value="14" enum="Monitor">
The amount of video memory used (texture and vertex memory combined, in bytes). Since this metric also includes miscellaneous allocations, this value is always greater than the sum of [constant RENDER_TEXTURE_MEM_USED] and [constant RENDER_BUFFER_MEM_USED]. [i]Lower is better.[/i]
</constant>
- <constant name="RENDER_TEXTURE_MEM_USED" value="14" enum="Monitor">
+ <constant name="RENDER_TEXTURE_MEM_USED" value="15" enum="Monitor">
The amount of texture memory used (in bytes). [i]Lower is better.[/i]
</constant>
- <constant name="RENDER_BUFFER_MEM_USED" value="15" enum="Monitor">
+ <constant name="RENDER_BUFFER_MEM_USED" value="16" enum="Monitor">
The amount of render buffer memory used (in bytes). [i]Lower is better.[/i]
</constant>
- <constant name="PHYSICS_2D_ACTIVE_OBJECTS" value="16" enum="Monitor">
+ <constant name="PHYSICS_2D_ACTIVE_OBJECTS" value="17" enum="Monitor">
Number of active [RigidBody2D] nodes in the game. [i]Lower is better.[/i]
</constant>
- <constant name="PHYSICS_2D_COLLISION_PAIRS" value="17" enum="Monitor">
+ <constant name="PHYSICS_2D_COLLISION_PAIRS" value="18" enum="Monitor">
Number of collision pairs in the 2D physics engine. [i]Lower is better.[/i]
</constant>
- <constant name="PHYSICS_2D_ISLAND_COUNT" value="18" enum="Monitor">
+ <constant name="PHYSICS_2D_ISLAND_COUNT" value="19" enum="Monitor">
Number of islands in the 2D physics engine. [i]Lower is better.[/i]
</constant>
- <constant name="PHYSICS_3D_ACTIVE_OBJECTS" value="19" enum="Monitor">
+ <constant name="PHYSICS_3D_ACTIVE_OBJECTS" value="20" enum="Monitor">
Number of active [RigidBody3D] and [VehicleBody3D] nodes in the game. [i]Lower is better.[/i]
</constant>
- <constant name="PHYSICS_3D_COLLISION_PAIRS" value="20" enum="Monitor">
+ <constant name="PHYSICS_3D_COLLISION_PAIRS" value="21" enum="Monitor">
Number of collision pairs in the 3D physics engine. [i]Lower is better.[/i]
</constant>
- <constant name="PHYSICS_3D_ISLAND_COUNT" value="21" enum="Monitor">
+ <constant name="PHYSICS_3D_ISLAND_COUNT" value="22" enum="Monitor">
Number of islands in the 3D physics engine. [i]Lower is better.[/i]
</constant>
- <constant name="AUDIO_OUTPUT_LATENCY" value="22" enum="Monitor">
+ <constant name="AUDIO_OUTPUT_LATENCY" value="23" enum="Monitor">
Output latency of the [AudioServer]. [i]Lower is better.[/i]
</constant>
- <constant name="MONITOR_MAX" value="23" enum="Monitor">
+ <constant name="NAVIGATION_ACTIVE_MAPS" value="24" enum="Monitor">
+ Number of active navigation maps in the [NavigationServer3D]. This also includes the two empty default navigation maps created by World2D and World3D.
+ </constant>
+ <constant name="NAVIGATION_REGION_COUNT" value="25" enum="Monitor">
+ Number of active navigation regions in the [NavigationServer3D].
+ </constant>
+ <constant name="NAVIGATION_AGENT_COUNT" value="26" enum="Monitor">
+ Number of active navigation agents processing avoidance in the [NavigationServer3D].
+ </constant>
+ <constant name="NAVIGATION_LINK_COUNT" value="27" enum="Monitor">
+ Number of active navigation links in the [NavigationServer3D].
+ </constant>
+ <constant name="NAVIGATION_POLYGON_COUNT" value="28" enum="Monitor">
+ Number of navigation mesh polygons in the [NavigationServer3D].
+ </constant>
+ <constant name="NAVIGATION_EDGE_COUNT" value="29" enum="Monitor">
+ Number of navigation mesh polygon edges in the [NavigationServer3D].
+ </constant>
+ <constant name="NAVIGATION_EDGE_MERGE_COUNT" value="30" enum="Monitor">
+ Number of navigation mesh polygon edges that were merged due to edge key overlap in the [NavigationServer3D].
+ </constant>
+ <constant name="NAVIGATION_EDGE_CONNECTION_COUNT" value="31" enum="Monitor">
+ Number of polygon edges that are considered connected by edge proximity [NavigationServer3D].
+ </constant>
+ <constant name="NAVIGATION_EDGE_FREE_COUNT" value="32" enum="Monitor">
+ Number of navigation mesh polygon edges that could not be merged in the [NavigationServer3D]. The edges still may be connected by edge proximity or with links.
+ </constant>
+ <constant name="MONITOR_MAX" value="33" enum="Monitor">
Represents the size of the [enum Monitor] enum.
</constant>
</constants>
diff --git a/doc/classes/PhysicalBone3D.xml b/doc/classes/PhysicalBone3D.xml
index 0768df31cc..f38130fe0c 100644
--- a/doc/classes/PhysicalBone3D.xml
+++ b/doc/classes/PhysicalBone3D.xml
@@ -3,6 +3,7 @@
<brief_description>
</brief_description>
<description>
+ [b]Warning:[/b] With a non-uniform scale this node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change the size(s) of its collision shape(s) instead.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/PhysicsBody3D.xml b/doc/classes/PhysicsBody3D.xml
index 2ef54683f2..3e100e3280 100644
--- a/doc/classes/PhysicsBody3D.xml
+++ b/doc/classes/PhysicsBody3D.xml
@@ -4,7 +4,8 @@
Base class for all objects affected by physics in 3D space.
</brief_description>
<description>
- PhysicsBody3D is an abstract base class for implementing a physics body. All *Body types inherit from it.
+ PhysicsBody3D is an abstract base class for implementing a physics body. All *Body3D types inherit from it.
+ [b]Warning:[/b] With a non-uniform scale this node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change the size(s) of its collision shape(s) instead.
</description>
<tutorials>
<link title="Physics introduction">$DOCS_URL/tutorials/physics/physics_introduction.html</link>
diff --git a/doc/classes/PhysicsDirectBodyState2D.xml b/doc/classes/PhysicsDirectBodyState2D.xml
index eca6a1cbc7..a46de4c189 100644
--- a/doc/classes/PhysicsDirectBodyState2D.xml
+++ b/doc/classes/PhysicsDirectBodyState2D.xml
@@ -151,6 +151,13 @@
[b]Note:[/b] By default, this returns 0 unless bodies are configured to monitor contacts. See [member RigidBody2D.contact_monitor].
</description>
</method>
+ <method name="get_contact_impulse" qualifiers="const">
+ <return type="Vector2" />
+ <param index="0" name="contact_idx" type="int" />
+ <description>
+ Returns the impulse created by the contact.
+ </description>
+ </method>
<method name="get_contact_local_normal" qualifiers="const">
<return type="Vector2" />
<param index="0" name="contact_idx" type="int" />
diff --git a/doc/classes/PhysicsDirectBodyState2DExtension.xml b/doc/classes/PhysicsDirectBodyState2DExtension.xml
index 8fd34c1243..496cbf9136 100644
--- a/doc/classes/PhysicsDirectBodyState2DExtension.xml
+++ b/doc/classes/PhysicsDirectBodyState2DExtension.xml
@@ -130,6 +130,12 @@
<description>
</description>
</method>
+ <method name="_get_contact_impulse" qualifiers="virtual const">
+ <return type="Vector2" />
+ <param index="0" name="contact_idx" type="int" />
+ <description>
+ </description>
+ </method>
<method name="_get_contact_local_normal" qualifiers="virtual const">
<return type="Vector2" />
<param index="0" name="contact_idx" type="int" />
diff --git a/doc/classes/PhysicsDirectBodyState3D.xml b/doc/classes/PhysicsDirectBodyState3D.xml
index a809384642..edd219e66e 100644
--- a/doc/classes/PhysicsDirectBodyState3D.xml
+++ b/doc/classes/PhysicsDirectBodyState3D.xml
@@ -152,10 +152,10 @@
</description>
</method>
<method name="get_contact_impulse" qualifiers="const">
- <return type="float" />
+ <return type="Vector3" />
<param index="0" name="contact_idx" type="int" />
<description>
- Impulse created by the contact. Only implemented for Bullet physics.
+ Impulse created by the contact.
</description>
</method>
<method name="get_contact_local_normal" qualifiers="const">
diff --git a/doc/classes/PhysicsDirectBodyState3DExtension.xml b/doc/classes/PhysicsDirectBodyState3DExtension.xml
index 4432f89b9d..35cf4d4dd5 100644
--- a/doc/classes/PhysicsDirectBodyState3DExtension.xml
+++ b/doc/classes/PhysicsDirectBodyState3DExtension.xml
@@ -131,7 +131,7 @@
</description>
</method>
<method name="_get_contact_impulse" qualifiers="virtual const">
- <return type="float" />
+ <return type="Vector3" />
<param index="0" name="contact_idx" type="int" />
<description>
</description>
diff --git a/doc/classes/PhysicsDirectSpaceState2DExtension.xml b/doc/classes/PhysicsDirectSpaceState2DExtension.xml
index 3235793853..fbbb98a959 100644
--- a/doc/classes/PhysicsDirectSpaceState2DExtension.xml
+++ b/doc/classes/PhysicsDirectSpaceState2DExtension.xml
@@ -87,5 +87,11 @@
<description>
</description>
</method>
+ <method name="is_body_excluded_from_query" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="body" type="RID" />
+ <description>
+ </description>
+ </method>
</methods>
</class>
diff --git a/doc/classes/PhysicsDirectSpaceState3DExtension.xml b/doc/classes/PhysicsDirectSpaceState3DExtension.xml
index 98593012db..4297846e53 100644
--- a/doc/classes/PhysicsDirectSpaceState3DExtension.xml
+++ b/doc/classes/PhysicsDirectSpaceState3DExtension.xml
@@ -95,5 +95,11 @@
<description>
</description>
</method>
+ <method name="is_body_excluded_from_query" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="body" type="RID" />
+ <description>
+ </description>
+ </method>
</methods>
</class>
diff --git a/doc/classes/PhysicsPointQueryParameters2D.xml b/doc/classes/PhysicsPointQueryParameters2D.xml
index 76dc816dab..15102830f8 100644
--- a/doc/classes/PhysicsPointQueryParameters2D.xml
+++ b/doc/classes/PhysicsPointQueryParameters2D.xml
@@ -11,6 +11,7 @@
<members>
<member name="canvas_instance_id" type="int" setter="set_canvas_instance_id" getter="get_canvas_instance_id" default="0">
If different from [code]0[/code], restricts the query to a specific canvas layer specified by its instance ID. See [method Object.get_instance_id].
+ If [code]0[/code], restricts the query to the Viewport's default canvas layer.
</member>
<member name="collide_with_areas" type="bool" setter="set_collide_with_areas" getter="is_collide_with_areas_enabled" default="false">
If [code]true[/code], the query will take [Area2D]s into account.
diff --git a/doc/classes/PhysicsServer2D.xml b/doc/classes/PhysicsServer2D.xml
index 18ac8a11df..93e88347d4 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>
@@ -952,25 +984,23 @@
<constant name="AREA_PARAM_GRAVITY_IS_POINT" value="3" enum="AreaParameter">
Constant to set/get whether the gravity vector of an area is a direction, or a center point.
</constant>
- <constant name="AREA_PARAM_GRAVITY_DISTANCE_SCALE" value="4" enum="AreaParameter">
- Constant to set/get the falloff factor for point gravity of an area. The greater this value is, the faster the strength of gravity decreases with the square of distance.
- </constant>
- <constant name="AREA_PARAM_GRAVITY_POINT_ATTENUATION" value="5" enum="AreaParameter">
- This constant was used to set/get the falloff factor for point gravity. It has been superseded by [constant AREA_PARAM_GRAVITY_DISTANCE_SCALE].
+ <constant name="AREA_PARAM_GRAVITY_POINT_UNIT_DISTANCE" value="4" enum="AreaParameter">
+ Constant to set/get the distance at which the gravity strength is equal to the gravity controlled by [constant AREA_PARAM_GRAVITY]. For example, on a planet 100 pixels in radius with a surface gravity of 4.0 px/s², set the gravity to 4.0 and the unit distance to 100.0. The gravity will have falloff according to the inverse square law, so in the example, at 200 pixels from the center the gravity will be 1.0 px/s² (twice the distance, 1/4th the gravity), at 50 pixels it will be 16.0 px/s² (half the distance, 4x the gravity), and so on.
+ The above is true only when the unit distance is a positive number. When the unit distance is set to 0.0, the gravity will be constant regardless of distance.
</constant>
- <constant name="AREA_PARAM_LINEAR_DAMP_OVERRIDE_MODE" value="6" enum="AreaParameter">
+ <constant name="AREA_PARAM_LINEAR_DAMP_OVERRIDE_MODE" value="5" enum="AreaParameter">
Constant to set/get linear damping override mode in an area. See [enum AreaSpaceOverrideMode] for possible values.
</constant>
- <constant name="AREA_PARAM_LINEAR_DAMP" value="7" enum="AreaParameter">
+ <constant name="AREA_PARAM_LINEAR_DAMP" value="6" enum="AreaParameter">
Constant to set/get the linear damping factor of an area.
</constant>
- <constant name="AREA_PARAM_ANGULAR_DAMP_OVERRIDE_MODE" value="8" enum="AreaParameter">
+ <constant name="AREA_PARAM_ANGULAR_DAMP_OVERRIDE_MODE" value="7" enum="AreaParameter">
Constant to set/get angular damping override mode in an area. See [enum AreaSpaceOverrideMode] for possible values.
</constant>
- <constant name="AREA_PARAM_ANGULAR_DAMP" value="9" enum="AreaParameter">
+ <constant name="AREA_PARAM_ANGULAR_DAMP" value="8" enum="AreaParameter">
Constant to set/get the angular damping factor of an area.
</constant>
- <constant name="AREA_PARAM_PRIORITY" value="10" enum="AreaParameter">
+ <constant name="AREA_PARAM_PRIORITY" value="9" enum="AreaParameter">
Constant to set/get the priority (order of processing) of an area.
</constant>
<constant name="AREA_SPACE_OVERRIDE_DISABLED" value="0" enum="AreaSpaceOverrideMode">
diff --git a/doc/classes/PhysicsServer2DExtension.xml b/doc/classes/PhysicsServer2DExtension.xml
index 9bb11e0d89..7ae27c3f32 100644
--- a/doc/classes/PhysicsServer2DExtension.xml
+++ b/doc/classes/PhysicsServer2DExtension.xml
@@ -933,5 +933,17 @@
<description>
</description>
</method>
+ <method name="body_test_motion_is_excluding_body" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="body" type="RID" />
+ <description>
+ </description>
+ </method>
+ <method name="body_test_motion_is_excluding_object" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="object" type="int" />
+ <description>
+ </description>
+ </method>
</methods>
</class>
diff --git a/doc/classes/PhysicsServer3D.xml b/doc/classes/PhysicsServer3D.xml
index 95f7fb69a2..5b261d8414 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" />
@@ -1300,37 +1315,35 @@
<constant name="AREA_PARAM_GRAVITY_IS_POINT" value="3" enum="AreaParameter">
Constant to set/get whether the gravity vector of an area is a direction, or a center point.
</constant>
- <constant name="AREA_PARAM_GRAVITY_DISTANCE_SCALE" value="4" enum="AreaParameter">
- Constant to set/get the falloff factor for point gravity of an area. The greater this value is, the faster the strength of gravity decreases with the square of distance.
- </constant>
- <constant name="AREA_PARAM_GRAVITY_POINT_ATTENUATION" value="5" enum="AreaParameter">
- This constant was used to set/get the falloff factor for point gravity. It has been superseded by [constant AREA_PARAM_GRAVITY_DISTANCE_SCALE].
+ <constant name="AREA_PARAM_GRAVITY_POINT_UNIT_DISTANCE" value="4" enum="AreaParameter">
+ Constant to set/get the distance at which the gravity strength is equal to the gravity controlled by [constant AREA_PARAM_GRAVITY]. For example, on a planet 100 meters in radius with a surface gravity of 4.0 m/s², set the gravity to 4.0 and the unit distance to 100.0. The gravity will have falloff according to the inverse square law, so in the example, at 200 meters from the center the gravity will be 1.0 m/s² (twice the distance, 1/4th the gravity), at 50 meters it will be 16.0 m/s² (half the distance, 4x the gravity), and so on.
+ The above is true only when the unit distance is a positive number. When this is set to 0.0, the gravity will be constant regardless of distance.
</constant>
- <constant name="AREA_PARAM_LINEAR_DAMP_OVERRIDE_MODE" value="6" enum="AreaParameter">
+ <constant name="AREA_PARAM_LINEAR_DAMP_OVERRIDE_MODE" value="5" enum="AreaParameter">
Constant to set/get linear damping override mode in an area. See [enum AreaSpaceOverrideMode] for possible values.
</constant>
- <constant name="AREA_PARAM_LINEAR_DAMP" value="7" enum="AreaParameter">
+ <constant name="AREA_PARAM_LINEAR_DAMP" value="6" enum="AreaParameter">
Constant to set/get the linear damping factor of an area.
</constant>
- <constant name="AREA_PARAM_ANGULAR_DAMP_OVERRIDE_MODE" value="8" enum="AreaParameter">
+ <constant name="AREA_PARAM_ANGULAR_DAMP_OVERRIDE_MODE" value="7" enum="AreaParameter">
Constant to set/get angular damping override mode in an area. See [enum AreaSpaceOverrideMode] for possible values.
</constant>
- <constant name="AREA_PARAM_ANGULAR_DAMP" value="9" enum="AreaParameter">
+ <constant name="AREA_PARAM_ANGULAR_DAMP" value="8" enum="AreaParameter">
Constant to set/get the angular damping factor of an area.
</constant>
- <constant name="AREA_PARAM_PRIORITY" value="10" enum="AreaParameter">
+ <constant name="AREA_PARAM_PRIORITY" value="9" enum="AreaParameter">
Constant to set/get the priority (order of processing) of an area.
</constant>
- <constant name="AREA_PARAM_WIND_FORCE_MAGNITUDE" value="11" enum="AreaParameter">
+ <constant name="AREA_PARAM_WIND_FORCE_MAGNITUDE" value="10" enum="AreaParameter">
Constant to set/get the magnitude of area-specific wind force.
</constant>
- <constant name="AREA_PARAM_WIND_SOURCE" value="12" enum="AreaParameter">
+ <constant name="AREA_PARAM_WIND_SOURCE" value="11" enum="AreaParameter">
Constant to set/get the 3D vector that specifies the origin from which an area-specific wind blows.
</constant>
- <constant name="AREA_PARAM_WIND_DIRECTION" value="13" enum="AreaParameter">
+ <constant name="AREA_PARAM_WIND_DIRECTION" value="12" enum="AreaParameter">
Constant to set/get the 3D vector that specifies the direction in which an area-specific wind blows.
</constant>
- <constant name="AREA_PARAM_WIND_ATTENUATION_FACTOR" value="14" enum="AreaParameter">
+ <constant name="AREA_PARAM_WIND_ATTENUATION_FACTOR" value="13" enum="AreaParameter">
Constant to set/get the exponential rate at which wind force decreases with distance from its origin.
</constant>
<constant name="AREA_SPACE_OVERRIDE_DISABLED" value="0" enum="AreaSpaceOverrideMode">
diff --git a/doc/classes/PhysicsServer3DExtension.xml b/doc/classes/PhysicsServer3DExtension.xml
index 1e9df54de5..5fe616b948 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" />
@@ -1271,5 +1284,17 @@
<description>
</description>
</method>
+ <method name="body_test_motion_is_excluding_body" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="body" type="RID" />
+ <description>
+ </description>
+ </method>
+ <method name="body_test_motion_is_excluding_object" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="object" type="int" />
+ <description>
+ </description>
+ </method>
</methods>
</class>
diff --git a/doc/classes/PhysicsServer3DManager.xml b/doc/classes/PhysicsServer3DManager.xml
index 3ec03fede4..4d789ceb3f 100644
--- a/doc/classes/PhysicsServer3DManager.xml
+++ b/doc/classes/PhysicsServer3DManager.xml
@@ -15,7 +15,7 @@
<param index="0" name="name" type="String" />
<param index="1" name="create_callback" type="Callable" />
<description>
- Register a [PhysicsServer3D] implementation by passing a [param name] and a [Callable] that returns a [PhysicsServer2D] object.
+ Register a [PhysicsServer3D] implementation by passing a [param name] and a [Callable] that returns a [PhysicsServer3D] object.
</description>
</method>
<method name="set_default_server">
diff --git a/doc/classes/Plane.xml b/doc/classes/Plane.xml
index fbe8afa8d1..aa09081e3e 100644
--- a/doc/classes/Plane.xml
+++ b/doc/classes/Plane.xml
@@ -38,6 +38,7 @@
<param index="0" name="normal" type="Vector3" />
<description>
Creates a plane from the normal vector. The plane will intersect the origin.
+ The [param normal] of the plane must be a unit vector.
</description>
</constructor>
<constructor name="Plane">
@@ -46,6 +47,7 @@
<param index="1" name="d" type="float" />
<description>
Creates a plane from the normal vector and the plane's distance from the origin.
+ The [param normal] of the plane must be a unit vector.
</description>
</constructor>
<constructor name="Plane">
@@ -54,6 +56,7 @@
<param index="1" name="point" type="Vector3" />
<description>
Creates a plane from the normal vector and a point on the plane.
+ The [param normal] of the plane must be a unit vector.
</description>
</constructor>
<constructor name="Plane">
@@ -67,12 +70,6 @@
</constructor>
</constructors>
<methods>
- <method name="center" qualifiers="const">
- <return type="Vector3" />
- <description>
- Returns the center of the plane.
- </description>
- </method>
<method name="distance_to" qualifiers="const">
<return type="float" />
<param index="0" name="point" type="Vector3" />
@@ -80,6 +77,12 @@
Returns the shortest distance from the plane to the position [param point]. If the point is above the plane, the distance will be positive. If below, the distance will be negative.
</description>
</method>
+ <method name="get_center" qualifiers="const">
+ <return type="Vector3" />
+ <description>
+ Returns the center of the plane.
+ </description>
+ </method>
<method name="has_point" qualifiers="const">
<return type="bool" />
<param index="0" name="point" type="Vector3" />
@@ -152,7 +155,7 @@
In the scalar equation of the plane [code]ax + by + cz = d[/code], this is [code]d[/code], while the [code](a, b, c)[/code] coordinates are represented by the [member normal] property.
</member>
<member name="normal" type="Vector3" setter="" getter="" default="Vector3(0, 0, 0)">
- The normal of the plane, which must be normalized.
+ The normal of the plane, which must be a unit vector.
In the scalar equation of the plane [code]ax + by + cz = d[/code], this is the vector [code](a, b, c)[/code], where [code]d[/code] is the [member d] property.
</member>
<member name="x" type="float" setter="" getter="" default="0.0">
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 72f9a0e32f..e429759e93 100644
--- a/doc/classes/ProjectSettings.xml
+++ b/doc/classes/ProjectSettings.xml
@@ -70,17 +70,39 @@
<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]
+ [b]Note:[/b] This method doesn't take potential feature overrides into account automatically. Use [method get_setting_with_override] to handle seamlessly.
+ </description>
+ </method>
+ <method name="get_setting_with_override" qualifiers="const">
+ <return type="Variant" />
+ <param index="0" name="name" type="StringName" />
+ <description>
+ Similar to [method get_setting], but applies feature tag overrides if any exists and is valid.
+ [b]Example:[/b]
+ If the following setting override exists "application/config/name.windows", and the following code is executed:
+ [codeblocks]
+ [gdscript]
+ print(ProjectSettings.get_setting_with_override("application/config/name"))
+ [/gdscript]
+ [csharp]
+ GD.Print(ProjectSettings.GetSettingWithOverride("application/config/name"));
+ [/csharp]
+ [/codeblocks]
+ Then the overridden setting will be returned instead if the project is running on the [i]Windows[/i] operating system.
</description>
</method>
<method name="globalize_path" qualifiers="const">
@@ -344,9 +366,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>
@@ -365,6 +384,9 @@
<member name="debug/gdscript/warnings/assert_always_true" type="int" setter="" getter="" default="1">
When set to [code]warn[/code] or [code]error[/code], produces a warning or an error respectively when an [code]assert[/code] call always evaluates to true.
</member>
+ <member name="debug/gdscript/warnings/confusable_identifier" type="int" setter="" getter="" default="1">
+ When set to [code]warn[/code] or [code]error[/code], produces a warning or an error respectively when an identifier contains characters that can be confused with something else, like when mixing different alphabets.
+ </member>
<member name="debug/gdscript/warnings/constant_used_as_function" 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 constant is used as a function.
</member>
@@ -386,8 +408,11 @@
<member name="debug/gdscript/warnings/incompatible_ternary" 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 ternary operator may emit values with incompatible types.
</member>
- <member name="debug/gdscript/warnings/int_assigned_to_enum" type="int" setter="" getter="" default="1">
- When set to [code]warn[/code] or [code]error[/code], produces a warning or an error respectively when trying to assign an integer to a variable that expects an enum value.
+ <member name="debug/gdscript/warnings/int_as_enum_without_cast" type="int" setter="" getter="" default="1">
+ When set to [code]warn[/code] or [code]error[/code], produces a warning or an error respectively when trying to use an integer as an enum without an explicit cast.
+ </member>
+ <member name="debug/gdscript/warnings/int_as_enum_without_match" type="int" setter="" getter="" default="1">
+ When set to [code]warn[/code] or [code]error[/code], produces a warning or an error respectively when trying to use an integer as an enum when there is no matching enum member for that numeric value.
</member>
<member name="debug/gdscript/warnings/integer_division" type="int" setter="" getter="" default="1">
When set to [code]warn[/code] or [code]error[/code], produces a warning or an error respectively when dividing an integer by another integer (the decimal part will be discarded).
@@ -401,6 +426,9 @@
<member name="debug/gdscript/warnings/redundant_await" 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 function that is not a coroutine is called with await.
</member>
+ <member name="debug/gdscript/warnings/renamed_in_godot_4_hint" type="bool" setter="" getter="" default="1">
+ When enabled, using a property, enum, or function that was renamed since Godot 3 will produce a hint if an error occurs.
+ </member>
<member name="debug/gdscript/warnings/return_value_discarded" type="int" setter="" getter="" default="0">
When set to [code]warn[/code] or [code]error[/code], produces a warning or an error respectively when calling a function without using its return value (by assigning it to a variable or using it as a function argument). Such return values are sometimes used to denote possible errors using the [enum Error] enum.
</member>
@@ -449,6 +477,9 @@
<member name="debug/gdscript/warnings/unsafe_property_access" type="int" setter="" getter="" default="0">
When set to [code]warn[/code] or [code]error[/code], produces a warning or an error respectively when accessing a property whose presence is not guaranteed at compile-time in the class.
</member>
+ <member name="debug/gdscript/warnings/unsafe_void_return" type="int" setter="" getter="" default="0">
+ When set to [code]warn[/code] or [code]error[/code], produces a warning or an error respectively when returning a call from a [code]void[/code] function when such call cannot be guaranteed to be also [code]void[/code].
+ </member>
<member name="debug/gdscript/warnings/unused_local_constant" 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 constant is never used.
</member>
@@ -464,9 +495,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>
@@ -500,9 +528,21 @@
<member name="debug/shapes/collision/shape_color" type="Color" setter="" getter="" default="Color(0, 0.6, 0.7, 0.42)">
Color of the collision shapes, visible when "Visible Collision Shapes" is enabled in the Debug menu.
</member>
+ <member name="debug/shapes/navigation/agent_path_color" type="Color" setter="" getter="" default="Color(1, 0, 0, 1)">
+ Color to display enabled navigation agent paths when an agent has debug enabled.
+ </member>
+ <member name="debug/shapes/navigation/agent_path_point_size" type="float" setter="" getter="" default="4.0">
+ Rasterized size (pixel) used to render navigation agent path points when an agent has debug enabled.
+ </member>
<member name="debug/shapes/navigation/edge_connection_color" type="Color" setter="" getter="" default="Color(1, 0, 1, 1)">
Color to display edge connections between navigation regions, visible when "Visible Navigation" is enabled in the Debug menu.
</member>
+ <member name="debug/shapes/navigation/enable_agent_paths" type="bool" setter="" getter="" default="true">
+ If enabled, displays navigation agent paths when an agent has debug enabled.
+ </member>
+ <member name="debug/shapes/navigation/enable_agent_paths_xray" type="bool" setter="" getter="" default="true">
+ If enabled, displays navigation agent paths through geometry when an agent has debug enabled.
+ </member>
<member name="debug/shapes/navigation/enable_edge_connections" type="bool" setter="" getter="" default="true">
If enabled, displays edge connections between navigation regions when "Visible Navigation" is enabled in the Debug menu.
</member>
@@ -585,7 +625,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.
@@ -599,6 +639,18 @@
Main window content is expanded to the full size of the window. Unlike a borderless window, the frame is left intact and can be used to resize the window, and the title bar is transparent, but has minimize/maximize/close buttons.
[b]Note:[/b] This setting is implemented only on macOS.
</member>
+ <member name="display/window/size/initial_position" type="Vector2i" setter="" getter="" default="Vector2i(0, 0)">
+ Main window initial position (in virtual desktop coordinates), this settings is used only if [member display/window/size/initial_position_type] is set to "Absolute" ([code]0[/code]).
+ </member>
+ <member name="display/window/size/initial_position_type" type="int" setter="" getter="" default="1">
+ Main window initial position.
+ [code]0[/code] - "Absolute", [member display/window/size/initial_position] is used to set window position.
+ [code]1[/code] - "Primary Screen Center".
+ [code]2[/code] - "Other Screen Center", [member display/window/size/initial_screen] is used to set window position.
+ </member>
+ <member name="display/window/size/initial_screen" type="int" setter="" getter="" default="0">
+ Main window initial screen, this settings is used only if [member display/window/size/initial_position_type] is set to "Other Screen Center" ([code]2[/code]).
+ </member>
<member name="display/window/size/mode" type="int" setter="" getter="" default="0">
Main window mode. See [enum DisplayServer.WindowMode] for possible values and how each mode behaves.
</member>
@@ -610,7 +662,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>
@@ -631,7 +683,15 @@
<member name="display/window/vsync/vsync_mode" type="int" setter="" getter="" default="1">
Sets the V-Sync mode for the main game window.
See [enum DisplayServer.VSyncMode] for possible values and how they affect the behavior of your application.
- Depending on the platform and used renderer, the engine will fall back to [code]Enabled[/code], if the desired mode is not supported.
+ Depending on the platform and used renderer, the engine will fall back to [code]Enabled[/code] if the desired mode is not supported.
+ [b]Note:[/b] This property is only read when the project starts. To change the V-Sync mode at runtime, call [method DisplayServer.window_set_vsync_mode] instead.
+ </member>
+ <member name="dotnet/project/assembly_name" type="String" setter="" getter="" default="&quot;&quot;">
+ Name of the .NET assembly. This name is used as the name of the [code].csproj[/code] and [code].sln[/code] files. By default, it's set to the name of the project ([member application/config/name]) allowing to change it in the future without affecting the .NET assembly.
+ </member>
+ <member name="dotnet/project/solution_directory" type="String" setter="" getter="" default="&quot;&quot;">
+ Directory that contains the [code].sln[/code] file. By default, the [code].sln[/code] files is in the root of the project directory, next to the [code]project.godot[/code] and [code].csproj[/code] files.
+ Changing this value allows setting up a multi-project scenario where there are multiple [code].csproj[/code]. Keep in mind that the Godot project is considered one of the C# projects in the workspace and it's root directory should contain the [code]project.godot[/code] and [code].csproj[/code] next to each other.
</member>
<member name="editor/movie_writer/disable_vsync" type="bool" setter="" getter="" default="false">
If [code]true[/code], requests V-Sync to be disabled when writing a movie (similar to setting [member display/window/vsync/vsync_mode] to [b]Disabled[/b]). This can speed up video writing if the hardware is fast enough to render, encode and save the video at a framerate higher than the monitor's refresh rate.
@@ -659,10 +719,16 @@
<member name="editor/movie_writer/speaker_mode" type="int" setter="" getter="" default="0">
The speaker mode to use in the recorded audio when writing a movie. See [enum AudioServer.SpeakerMode] for possible values.
</member>
- <member name="editor/node_naming/name_casing" type="int" setter="" getter="" default="0">
+ <member name="editor/naming/default_signal_callback_name" type="String" setter="" getter="" default="&quot;_on_{node_name}_{signal_name}&quot;">
+ The format of the default signal callback name (in the Signal Connection Dialog). The following substitutions are available: [code]{NodeName}[/code], [code]{nodeName}[/code], [code]{node_name}[/code], [code]{SignalName}[/code], [code]{signalName}[/code], and [code]{signal_name}[/code].
+ </member>
+ <member name="editor/naming/default_signal_callback_to_self_name" type="String" setter="" getter="" default="&quot;_on_{signal_name}&quot;">
+ The format of the default signal callback name when a signal connects to the same node that emits it (in the Signal Connection Dialog). The following substitutions are available: [code]{NodeName}[/code], [code]{nodeName}[/code], [code]{node_name}[/code], [code]{SignalName}[/code], [code]{signalName}[/code], and [code]{signal_name}[/code].
+ </member>
+ <member name="editor/naming/node_name_casing" type="int" setter="" getter="" default="0">
When creating node names automatically, set the type of casing in this project. This is mostly an editor setting.
</member>
- <member name="editor/node_naming/name_num_separator" type="int" setter="" getter="" default="0">
+ <member name="editor/naming/node_name_num_separator" type="int" setter="" getter="" default="0">
What to use to separate node name from number. This is mostly an editor setting.
</member>
<member name="editor/run/main_run_args" type="String" setter="" getter="" default="&quot;&quot;">
@@ -741,6 +807,9 @@
<member name="gui/theme/lcd_subpixel_layout" type="int" setter="" getter="" default="1">
LCD subpixel layout used for font anti-aliasing. See [enum TextServer.FontLCDSubpixelLayout].
</member>
+ <member name="gui/timers/button_shortcut_feedback_highlight_time" type="float" setter="" getter="" default="0.2">
+ When [member BaseButton.shortcut_feedback] is enabled, this is the time the [BaseButton] will remain highlighted after a shortcut.
+ </member>
<member name="gui/timers/incremental_search_max_interval_msec" type="int" setter="" getter="" default="2000">
Timer setting for incremental search in [Tree], [ItemList], etc. controls (in milliseconds).
</member>
@@ -1686,7 +1755,7 @@
[/gdscript]
[csharp]
// Set the default gravity strength to 980.
- PhysicsServer2D.AreaSetParam(GetViewport().FindWorld2d().Space, PhysicsServer2D.AreaParameter.Gravity, 980);
+ PhysicsServer2D.AreaSetParam(GetViewport().FindWorld2D().Space, PhysicsServer2D.AreaParameter.Gravity, 980);
[/csharp]
[/codeblocks]
</member>
@@ -1700,7 +1769,7 @@
[/gdscript]
[csharp]
// Set the default gravity direction to `Vector2(0, 1)`.
- PhysicsServer2D.AreaSetParam(GetViewport().FindWorld2d().Space, PhysicsServer2D.AreaParameter.GravityVector, Vector2.Down)
+ PhysicsServer2D.AreaSetParam(GetViewport().FindWorld2D().Space, PhysicsServer2D.AreaParameter.GravityVector, Vector2.Down)
[/csharp]
[/codeblocks]
</member>
@@ -2234,20 +2303,12 @@
<member name="rendering/textures/lossless_compression/force_png" type="bool" setter="" getter="" default="false">
If [code]true[/code], the texture importer will import lossless textures using the PNG format. Otherwise, it will default to using WebP.
</member>
- <member name="rendering/textures/vram_compression/import_bptc" type="bool" setter="" getter="" default="false">
- If [code]true[/code], the texture importer will import VRAM-compressed textures using the BPTC algorithm. This texture compression algorithm is only supported on desktop platforms, and only when using the Vulkan renderer.
- [b]Note:[/b] Changing this setting does [i]not[/i] impact textures that were already imported before. To make this setting apply to textures that were already imported, exit the editor, remove the [code].godot/imported/[/code] folder located inside the project folder then restart the editor (see [member application/config/use_hidden_project_data_directory]).
- </member>
- <member name="rendering/textures/vram_compression/import_etc" type="bool" setter="" getter="" default="false">
- If [code]true[/code], the texture importer will import VRAM-compressed textures using the Ericsson Texture Compression algorithm. This algorithm doesn't support alpha channels in textures.
- [b]Note:[/b] Changing this setting does [i]not[/i] impact textures that were already imported before. To make this setting apply to textures that were already imported, exit the editor, remove the [code].godot/imported/[/code] folder located inside the project folder then restart the editor (see [member application/config/use_hidden_project_data_directory]).
- </member>
- <member name="rendering/textures/vram_compression/import_etc2" type="bool" setter="" getter="" default="true">
- If [code]true[/code], the texture importer will import VRAM-compressed textures using the Ericsson Texture Compression 2 algorithm. This texture compression algorithm is only supported when using the Vulkan renderer.
+ <member name="rendering/textures/vram_compression/import_etc2_astc" type="bool" setter="" getter="" default="false">
+ If [code]true[/code], the texture importer will import VRAM-compressed textures using the Ericsson Texture Compression 2 algorithm for lower quality textures and normalmaps and Adaptable Scalable Texture Compression algorithm for high quality textures (in 4x4 block size).
[b]Note:[/b] Changing this setting does [i]not[/i] impact textures that were already imported before. To make this setting apply to textures that were already imported, exit the editor, remove the [code].godot/imported/[/code] folder located inside the project folder then restart the editor (see [member application/config/use_hidden_project_data_directory]).
</member>
- <member name="rendering/textures/vram_compression/import_s3tc" type="bool" setter="" getter="" default="true">
- If [code]true[/code], the texture importer will import VRAM-compressed textures using the S3 Texture Compression algorithm. This algorithm is only supported on desktop platforms and consoles.
+ <member name="rendering/textures/vram_compression/import_s3tc_bptc" type="bool" setter="" getter="" default="true">
+ If [code]true[/code], the texture importer will import VRAM-compressed textures using the S3 Texture Compression algorithm (DXT1-5) for lower quality textures and the the BPTC algorithm (BC6H and BC7) for high quality textures. This algorithm is only supported on PC desktop platforms and consoles.
[b]Note:[/b] Changing this setting does [i]not[/i] impact textures that were already imported before. To make this setting apply to textures that were already imported, exit the editor, remove the [code].godot/imported/[/code] folder located inside the project folder then restart the editor (see [member application/config/use_hidden_project_data_directory]).
</member>
<member name="rendering/textures/webp_compression/compression_method" type="int" setter="" getter="" default="2">
@@ -2256,7 +2317,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/Projection.xml b/doc/classes/Projection.xml
index 602833bca5..99e3f1725f 100644
--- a/doc/classes/Projection.xml
+++ b/doc/classes/Projection.xml
@@ -149,7 +149,7 @@
<param index="4" name="flip_fov" type="bool" />
<param index="5" name="eye" type="int" />
<param index="6" name="intraocular_dist" type="float" />
- <param index="7" name=" convergence_dist" type="float" />
+ <param index="7" name="convergence_dist" type="float" />
<description>
Creates a new [Projection] that projects positions using a perspective projection with the given Y-axis field of view (in degrees), X:Y aspect ratio, and clipping distances. The projection is adjusted for a head-mounted display with the given distance between eyes and distance to a point that can be focused on.
[param eye] creates the projection for the left eye when set to 1, or the right eye when set to 2.
diff --git a/doc/classes/Range.xml b/doc/classes/Range.xml
index 2dcfc90955..4803ea9bfb 100644
--- a/doc/classes/Range.xml
+++ b/doc/classes/Range.xml
@@ -62,7 +62,7 @@
<member name="rounded" type="bool" setter="set_use_rounded_values" getter="is_using_rounded_values" default="false">
If [code]true[/code], [code]value[/code] will always be rounded to the nearest integer.
</member>
- <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" default="0" />
+ <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" enum="Control.SizeFlags" default="0" />
<member name="step" type="float" setter="set_step" getter="get_step" default="0.01">
If greater than 0, [code]value[/code] will always be rounded to a multiple of [code]step[/code]. If [code]rounded[/code] is also [code]true[/code], [code]value[/code] will first be rounded to a multiple of [code]step[/code] then rounded to the nearest integer.
</member>
diff --git a/doc/classes/Rect2i.xml b/doc/classes/Rect2i.xml
index 325ead0cfa..80a9b40605 100644
--- a/doc/classes/Rect2i.xml
+++ b/doc/classes/Rect2i.xml
@@ -80,9 +80,9 @@
[/gdscript]
[csharp]
// position (-3, 2), size (1, 1)
- var rect = new Rect2i(new Vector2i(-3, 2), new Vector2i(1, 1));
- // position (-3, -1), size (3, 4), so we fit both rect and Vector2i(0, -1)
- var rect2 = rect.Expand(new Vector2i(0, -1));
+ var rect = new Rect2I(new Vector2I(-3, 2), new Vector2I(1, 1));
+ // position (-3, -1), size (3, 4), so we fit both rect and Vector2I(0, -1)
+ var rect2 = rect.Expand(new Vector2I(0, -1));
[/csharp]
[/codeblocks]
</description>
diff --git a/doc/classes/ReflectionProbe.xml b/doc/classes/ReflectionProbe.xml
index fee48dd246..fa0b1ab00b 100644
--- a/doc/classes/ReflectionProbe.xml
+++ b/doc/classes/ReflectionProbe.xml
@@ -13,13 +13,13 @@
</tutorials>
<members>
<member name="ambient_color" type="Color" setter="set_ambient_color" getter="get_ambient_color" default="Color(0, 0, 0, 1)">
- The custom ambient color to use within the [ReflectionProbe]'s [member extents]. Only effective if [member ambient_mode] is [constant AMBIENT_COLOR].
+ The custom ambient color to use within the [ReflectionProbe]'s [member size]. Only effective if [member ambient_mode] is [constant AMBIENT_COLOR].
</member>
<member name="ambient_color_energy" type="float" setter="set_ambient_color_energy" getter="get_ambient_color_energy" default="1.0">
- The custom ambient color energy to use within the [ReflectionProbe]'s [member extents]. Only effective if [member ambient_mode] is [constant AMBIENT_COLOR].
+ The custom ambient color energy to use within the [ReflectionProbe]'s [member size]. Only effective if [member ambient_mode] is [constant AMBIENT_COLOR].
</member>
<member name="ambient_mode" type="int" setter="set_ambient_mode" getter="get_ambient_mode" enum="ReflectionProbe.AmbientMode" default="1">
- The ambient color to use within the [ReflectionProbe]'s [member extents]. The ambient color will smoothly blend with other [ReflectionProbe]s and the rest of the scene (outside the [ReflectionProbe]'s [member extents]).
+ The ambient color to use within the [ReflectionProbe]'s [member size]. The ambient color will smoothly blend with other [ReflectionProbe]s and the rest of the scene (outside the [ReflectionProbe]'s [member size]).
</member>
<member name="box_projection" type="bool" setter="set_enable_box_projection" getter="is_box_projection_enabled" default="false">
If [code]true[/code], enables box projection. This makes reflections look more correct in rectangle-shaped rooms by offsetting the reflection center depending on the camera's location.
@@ -31,10 +31,6 @@
<member name="enable_shadows" type="bool" setter="set_enable_shadows" getter="are_shadows_enabled" default="false">
If [code]true[/code], computes shadows in the reflection probe. This makes the reflection probe slower to render; you may want to disable this if using the [constant UPDATE_ALWAYS] [member update_mode].
</member>
- <member name="extents" type="Vector3" setter="set_extents" getter="get_extents" default="Vector3(10, 10, 10)">
- The size of the reflection probe. The larger the extents, the more space covered by the probe, which will lower the perceived resolution. It is best to keep the extents only as large as you need them.
- [b]Note:[/b] To better fit areas that are not aligned to the grid, you can rotate the [ReflectionProbe] node.
- </member>
<member name="intensity" type="float" setter="set_intensity" getter="get_intensity" default="1.0">
Defines the reflection intensity. Intensity modulates the strength of the reflection.
</member>
@@ -43,7 +39,7 @@
</member>
<member name="max_distance" type="float" setter="set_max_distance" getter="get_max_distance" default="0.0">
The maximum distance away from the [ReflectionProbe] an object can be before it is culled. Decrease this to improve performance, especially when using the [constant UPDATE_ALWAYS] [member update_mode].
- [b]Note:[/b] The maximum reflection distance is always at least equal to the [member extents]. This means that decreasing [member max_distance] will not always cull objects from reflections, especially if the reflection probe's [member extents] are already large.
+ [b]Note:[/b] The maximum reflection distance is always at least equal to the probe's extents. This means that decreasing [member max_distance] will not always cull objects from reflections, especially if the reflection probe's [member size] is already large.
</member>
<member name="mesh_lod_threshold" type="float" setter="set_mesh_lod_threshold" getter="get_mesh_lod_threshold" default="1.0">
The automatic LOD bias to use for meshes rendered within the [ReflectionProbe] (this is analog to [member Viewport.mesh_lod_threshold]). Higher values will use less detailed versions of meshes that have LOD variations generated. If set to [code]0.0[/code], automatic LOD is disabled. Increase [member mesh_lod_threshold] to improve performance at the cost of geometry detail, especially when using the [constant UPDATE_ALWAYS] [member update_mode].
@@ -52,6 +48,10 @@
<member name="origin_offset" type="Vector3" setter="set_origin_offset" getter="get_origin_offset" default="Vector3(0, 0, 0)">
Sets the origin offset to be used when this [ReflectionProbe] is in [member box_projection] mode. This can be set to a non-zero value to ensure a reflection fits a rectangle-shaped room, while reducing the number of objects that "get in the way" of the reflection.
</member>
+ <member name="size" type="Vector3" setter="set_size" getter="get_size" default="Vector3(20, 20, 20)">
+ The size of the reflection probe. The larger the size, the more space covered by the probe, which will lower the perceived resolution. It is best to keep the size only as large as you need it.
+ [b]Note:[/b] To better fit areas that are not aligned to the grid, you can rotate the [ReflectionProbe] node.
+ </member>
<member name="update_mode" type="int" setter="set_update_mode" getter="get_update_mode" enum="ReflectionProbe.UpdateMode" default="0">
Sets how frequently the [ReflectionProbe] is updated. Can be [constant UPDATE_ONCE] or [constant UPDATE_ALWAYS].
</member>
@@ -64,13 +64,13 @@
Update the probe every frame. This provides better results for fast-moving dynamic objects (such as cars). However, it has a significant performance cost. Due to the cost, it's recommended to only use one ReflectionProbe with [constant UPDATE_ALWAYS] at most per scene. For all other use cases, use [constant UPDATE_ONCE].
</constant>
<constant name="AMBIENT_DISABLED" value="0" enum="AmbientMode">
- Do not apply any ambient lighting inside the [ReflectionProbe]'s [member extents].
+ Do not apply any ambient lighting inside the [ReflectionProbe]'s [member size].
</constant>
<constant name="AMBIENT_ENVIRONMENT" value="1" enum="AmbientMode">
- Apply automatically-sourced environment lighting inside the [ReflectionProbe]'s [member extents].
+ Apply automatically-sourced environment lighting inside the [ReflectionProbe]'s [member size].
</constant>
<constant name="AMBIENT_COLOR" value="2" enum="AmbientMode">
- Apply custom ambient lighting inside the [ReflectionProbe]'s [member extents]. See [member ambient_color] and [member ambient_color_energy].
+ Apply custom ambient lighting inside the [ReflectionProbe]'s [member size]. See [member ambient_color] and [member ambient_color_energy].
</constant>
</constants>
</class>
diff --git a/doc/classes/RemoteTransform2D.xml b/doc/classes/RemoteTransform2D.xml
index 20fa41a3f0..6f100541be 100644
--- a/doc/classes/RemoteTransform2D.xml
+++ b/doc/classes/RemoteTransform2D.xml
@@ -1,11 +1,11 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="RemoteTransform2D" inherits="Node2D" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
- RemoteTransform2D pushes its own [Transform2D] to another [CanvasItem] derived Node in the scene.
+ RemoteTransform2D pushes its own [Transform2D] to another [Node2D] derived node in the scene.
</brief_description>
<description>
- RemoteTransform2D pushes its own [Transform2D] to another [CanvasItem] derived Node (called the remote node) in the scene.
- It can be set to update another Node's position, rotation and/or scale. It can use either global or local coordinates.
+ RemoteTransform2D pushes its own [Transform2D] to another [Node2D] derived node (called the remote node) in the scene.
+ It can be set to update another node's position, rotation and/or scale. It can use either global or local coordinates.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/RenderingDevice.xml b/doc/classes/RenderingDevice.xml
index f318430611..82a2871949 100644
--- a/doc/classes/RenderingDevice.xml
+++ b/doc/classes/RenderingDevice.xml
@@ -1,8 +1,14 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="RenderingDevice" inherits="Object" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ Abstraction for working with modern low-level graphics APIs.
</brief_description>
<description>
+ [RenderingDevice] is an abstraction for working with modern low-level graphics APIs such as Vulkan.
+ On startup, Godot creates a global [RenderingDevice] which can be retrieved using [method RenderingServer.get_rendering_device]. This global RenderingDevice performs drawing to the screen.
+ Internally, [RenderingDevice] is used in Godot to provide support for several modern low-level graphics APIs while reducing the amount of code duplication required.
+ [b]Local RenderingDevices:[/b] Using [method RenderingServer.create_local_rendering_device], you can create "secondary" rendering devices to perform drawing and GPU compute operations on separate threads.
+ [b]Note:[/b] [RenderingDevice] is not available when running in headless mode or when using the OpenGL renderer.
</description>
<tutorials>
</tutorials>
@@ -1162,20 +1168,28 @@
<constant name="BARRIER_MASK_NO_BARRIER" value="8" enum="BarrierMask" is_bitfield="true">
</constant>
<constant name="TEXTURE_TYPE_1D" value="0" enum="TextureType">
+ 1-dimensional texture.
</constant>
<constant name="TEXTURE_TYPE_2D" value="1" enum="TextureType">
+ 2-dimensional texture.
</constant>
<constant name="TEXTURE_TYPE_3D" value="2" enum="TextureType">
+ 3-dimensional texture.
</constant>
<constant name="TEXTURE_TYPE_CUBE" value="3" enum="TextureType">
+ [Cubemap] texture.
</constant>
<constant name="TEXTURE_TYPE_1D_ARRAY" value="4" enum="TextureType">
+ Array of 1-dimensional textures.
</constant>
<constant name="TEXTURE_TYPE_2D_ARRAY" value="5" enum="TextureType">
+ Array of 2-dimensional textures.
</constant>
<constant name="TEXTURE_TYPE_CUBE_ARRAY" value="6" enum="TextureType">
+ Array of [Cubemap] textures.
</constant>
<constant name="TEXTURE_TYPE_MAX" value="7" enum="TextureType">
+ Represents the size of the [enum TextureType] enum.
</constant>
<constant name="TEXTURE_SAMPLES_1" value="0" enum="TextureSamples">
</constant>
@@ -1192,6 +1206,7 @@
<constant name="TEXTURE_SAMPLES_64" value="6" enum="TextureSamples">
</constant>
<constant name="TEXTURE_SAMPLES_MAX" value="7" enum="TextureSamples">
+ Represents the size of the [enum TextureSamples] enum.
</constant>
<constant name="TEXTURE_USAGE_SAMPLING_BIT" value="1" enum="TextureUsageBits" is_bitfield="true">
</constant>
@@ -1236,8 +1251,10 @@
<constant name="TEXTURE_SLICE_3D" value="2" enum="TextureSliceType">
</constant>
<constant name="SAMPLER_FILTER_NEAREST" value="0" enum="SamplerFilter">
+ Nearest-neighbor sampler filtering. Sampling at higher resolutions than the source will result in a pixelated look.
</constant>
<constant name="SAMPLER_FILTER_LINEAR" value="1" enum="SamplerFilter">
+ Bilinear sampler filtering. Sampling at higher resolutions than the source will result in a blurry look.
</constant>
<constant name="SAMPLER_REPEAT_MODE_REPEAT" value="0" enum="SamplerRepeatMode">
</constant>
@@ -1298,8 +1315,10 @@
<constant name="UNIFORM_TYPE_MAX" value="10" enum="UniformType">
</constant>
<constant name="RENDER_PRIMITIVE_POINTS" value="0" enum="RenderPrimitive">
+ Point rendering primitive (with constant size, regardless of distance from camera).
</constant>
<constant name="RENDER_PRIMITIVE_LINES" value="1" enum="RenderPrimitive">
+ Line rendering primitive.
</constant>
<constant name="RENDER_PRIMITIVE_LINES_WITH_ADJACENCY" value="2" enum="RenderPrimitive">
</constant>
@@ -1380,6 +1399,7 @@
<constant name="LOGIC_OP_NO_OP" value="5" enum="LogicOperation">
</constant>
<constant name="LOGIC_OP_XOR" value="6" enum="LogicOperation">
+ Exclusive or (XOR) logic operation.
</constant>
<constant name="LOGIC_OP_OR" value="7" enum="LogicOperation">
</constant>
@@ -1442,16 +1462,22 @@
<constant name="BLEND_FACTOR_MAX" value="19" enum="BlendFactor">
</constant>
<constant name="BLEND_OP_ADD" value="0" enum="BlendOperation">
+ Additive blending operation ([code]source + destination[/code]).
</constant>
<constant name="BLEND_OP_SUBTRACT" value="1" enum="BlendOperation">
+ Subtractive blending operation ([code]source - destination[/code]).
</constant>
<constant name="BLEND_OP_REVERSE_SUBTRACT" value="2" enum="BlendOperation">
+ Reverse subtractive blending operation ([code]destination - source[/code]).
</constant>
<constant name="BLEND_OP_MINIMUM" value="3" enum="BlendOperation">
+ Minimum blending operation (keep the lowest value of the two).
</constant>
<constant name="BLEND_OP_MAXIMUM" value="4" enum="BlendOperation">
+ Maximum blending operation (keep the highest value of the two).
</constant>
<constant name="BLEND_OP_MAX" value="5" enum="BlendOperation">
+ Represents the size of the [enum BlendOperation] enum.
</constant>
<constant name="DYNAMIC_STATE_LINE_WIDTH" value="1" enum="PipelineDynamicStateFlags" is_bitfield="true">
</constant>
@@ -1544,12 +1570,16 @@
<constant name="LIMIT_MAX_TEXTURE_ARRAY_LAYERS" value="10" enum="Limit">
</constant>
<constant name="LIMIT_MAX_TEXTURE_SIZE_1D" value="11" enum="Limit">
+ Maximum supported 1-dimensional texture size (in pixels on a single axis).
</constant>
<constant name="LIMIT_MAX_TEXTURE_SIZE_2D" value="12" enum="Limit">
+ Maximum supported 2-dimensional texture size (in pixels on a single axis).
</constant>
<constant name="LIMIT_MAX_TEXTURE_SIZE_3D" value="13" enum="Limit">
+ Maximum supported 3-dimensional texture size (in pixels on a single axis).
</constant>
<constant name="LIMIT_MAX_TEXTURE_SIZE_CUBE" value="14" enum="Limit">
+ Maximum supported cubemap texture size (in pixels on a single axis of a single face).
</constant>
<constant name="LIMIT_MAX_TEXTURES_PER_SHADER_STAGE" value="15" enum="Limit">
</constant>
@@ -1596,14 +1626,19 @@
<constant name="LIMIT_MAX_VIEWPORT_DIMENSIONS_Y" value="36" enum="Limit">
</constant>
<constant name="MEMORY_TEXTURES" value="0" enum="MemoryType">
+ Memory taken by textures.
</constant>
<constant name="MEMORY_BUFFERS" value="1" enum="MemoryType">
+ Memory taken by buffers.
</constant>
<constant name="MEMORY_TOTAL" value="2" enum="MemoryType">
+ Total memory taken. This is greater than the sum of [constant MEMORY_TEXTURES] and [constant MEMORY_BUFFERS], as it also includes miscellaneous memory usage.
</constant>
<constant name="INVALID_ID" value="-1">
+ Returned by functions that return an ID if a value is invalid.
</constant>
<constant name="INVALID_FORMAT_ID" value="-1">
+ Returned by functions that return a format ID if a value is invalid.
</constant>
</constants>
</class>
diff --git a/doc/classes/RenderingServer.xml b/doc/classes/RenderingServer.xml
index 7a9a380032..f92ea255cc 100644
--- a/doc/classes/RenderingServer.xml
+++ b/doc/classes/RenderingServer.xml
@@ -4,10 +4,10 @@
Server for anything visible.
</brief_description>
<description>
- Server for anything visible. The rendering server is the API backend for everything visible. The whole scene system mounts on it to display.
+ The rendering server is the API backend for everything visible. The whole scene system mounts on it to display.
The rendering server is completely opaque, the internals are entirely implementation specific and cannot be accessed.
- The rendering server can be used to bypass the scene system entirely.
- Resources are created using the [code]*_create[/code] functions.
+ The rendering server can be used to bypass the scene/[Node] system entirely.
+ Resources are created using the [code]*_create[/code] functions. These functions return [RID]s which are not references to the objects themselves, but opaque [i]pointers[/i] towards these objects.
All objects are drawn to a viewport. You can use the [Viewport] attached to the [SceneTree] or you can create one yourself with [method viewport_create]. When using a custom scenario or canvas, the scenario or canvas needs to be attached to the viewport using [method viewport_set_scenario] or [method viewport_attach_canvas].
In 3D, all visual objects must be associated with a scenario. The scenario is a visual representation of the world. If accessing the rendering server from a running game, the scenario can be accessed from the scene tree from any [Node3D] node with [method Node3D.get_world_3d]. Otherwise, a scenario can be created with [method scenario_create].
Similarly, in 2D, a canvas is needed to draw all canvas items.
@@ -25,6 +25,7 @@
<param index="1" name="material_overrides" type="RID[]" />
<param index="2" name="image_size" type="Vector2i" />
<description>
+ Bakes the material data of the Mesh passed in the [param base] parameter with optional [param material_overrides] to a set of [Image]s of size [param image_size]. Returns an array of [Image]s containing material properties as specified in [enum BakeChannels].
</description>
</method>
<method name="camera_attributes_create">
@@ -43,6 +44,7 @@
<param index="4" name="speed" type="float" />
<param index="5" name="scale" type="float" />
<description>
+ Sets the parameters to use with the auto-exposure effect. These parameters take on the same meaning as their counterparts in [CameraAttributes] and [CameraAttributesPractical].
</description>
</method>
<method name="camera_attributes_set_dof_blur">
@@ -56,12 +58,14 @@
<param index="6" name="near_transition" type="float" />
<param index="7" name="amount" type="float" />
<description>
+ Sets the parameters to use with the dof blur effect. These parameters take on the same meaning as their counterparts in [CameraAttributesPractical].
</description>
</method>
<method name="camera_attributes_set_dof_blur_bokeh_shape">
<return type="void" />
<param index="0" name="shape" type="int" enum="RenderingServer.DOFBokehShape" />
<description>
+ Sets the shape of the dof bokeh pattern. Different shapes may be used to acheive artistic effect, or to meet performance targets. For more detail on available options see [enum DOFBokehShape].
</description>
</method>
<method name="camera_attributes_set_dof_blur_quality">
@@ -69,6 +73,7 @@
<param index="0" name="quality" type="int" enum="RenderingServer.DOFBlurQuality" />
<param index="1" name="use_jitter" type="bool" />
<description>
+ Sets the quality level of the dof blur effect to one of the options in [enum DOFBlurQuality]. [param use_jitter] can be used to jitter samples taken during the blur pass to hide artifacts at the cost of looking more fuzzy.
</description>
</method>
<method name="camera_attributes_set_exposure">
@@ -102,6 +107,7 @@
<param index="0" name="camera" type="RID" />
<param index="1" name="effects" type="RID" />
<description>
+ Sets the camera_attributes created with [method camera_attributes_create] to the given camera.
</description>
</method>
<method name="camera_set_cull_mask">
@@ -192,6 +198,7 @@
<param index="2" name="radius" type="float" />
<param index="3" name="color" type="Color" />
<description>
+ Draws a circle on the [CanvasItem] pointed to by the [param item] [RID]. See also [method CanvasItem.draw_circle].
</description>
</method>
<method name="canvas_item_add_clip_ignore">
@@ -199,6 +206,7 @@
<param index="0" name="item" type="RID" />
<param index="1" name="ignore" type="bool" />
<description>
+ If [param ignore] is [code]true[/code], ignore clipping on items drawn with this canvas item until this is called again with [param ignore] set to false.
</description>
</method>
<method name="canvas_item_add_lcd_texture_rect_region">
@@ -209,6 +217,7 @@
<param index="3" name="src_rect" type="Rect2" />
<param index="4" name="modulate" type="Color" />
<description>
+ See also [method CanvasItem.draw_lcd_texture_rect_region].
</description>
</method>
<method name="canvas_item_add_line">
@@ -217,9 +226,10 @@
<param index="1" name="from" type="Vector2" />
<param index="2" name="to" type="Vector2" />
<param index="3" name="color" type="Color" />
- <param index="4" name="width" type="float" default="1.0" />
+ <param index="4" name="width" type="float" default="-1.0" />
<param index="5" name="antialiased" type="bool" default="false" />
<description>
+ Draws a line on the [CanvasItem] pointed to by the [param item] [RID]. See also [method CanvasItem.draw_line].
</description>
</method>
<method name="canvas_item_add_mesh">
@@ -230,6 +240,7 @@
<param index="3" name="modulate" type="Color" default="Color(1, 1, 1, 1)" />
<param index="4" name="texture" type="RID" />
<description>
+ Draws a mesh created with [method mesh_create] with given [param transform], [param modulate] color, and [param texture]. This is used internally by [MeshInstance2D].
</description>
</method>
<method name="canvas_item_add_msdf_texture_rect_region">
@@ -241,7 +252,9 @@
<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>
+ See also [method CanvasItem.draw_msdf_texture_rect_region].
</description>
</method>
<method name="canvas_item_add_multimesh">
@@ -250,6 +263,7 @@
<param index="1" name="mesh" type="RID" />
<param index="2" name="texture" type="RID" />
<description>
+ Draws a 2D [MultiMesh] on the [CanvasItem] pointed to by the [param item] [RID]. See also [method CanvasItem.draw_multimesh].
</description>
</method>
<method name="canvas_item_add_nine_patch">
@@ -265,6 +279,7 @@
<param index="8" name="draw_center" type="bool" default="true" />
<param index="9" name="modulate" type="Color" default="Color(1, 1, 1, 1)" />
<description>
+ Draws a nine-patch rectangle on the [CanvasItem] pointed to by the [param item] [RID].
</description>
</method>
<method name="canvas_item_add_particles">
@@ -273,6 +288,7 @@
<param index="1" name="particles" type="RID" />
<param index="2" name="texture" type="RID" />
<description>
+ Draws particles on the [CanvasItem] pointed to by the [param item] [RID].
</description>
</method>
<method name="canvas_item_add_polygon">
@@ -283,6 +299,7 @@
<param index="3" name="uvs" type="PackedVector2Array" default="PackedVector2Array()" />
<param index="4" name="texture" type="RID" />
<description>
+ Draws a 2D polygon on the [CanvasItem] pointed to by the [param item] [RID]. See also [method CanvasItem.draw_polygon].
</description>
</method>
<method name="canvas_item_add_polyline">
@@ -290,9 +307,10 @@
<param index="0" name="item" type="RID" />
<param index="1" name="points" type="PackedVector2Array" />
<param index="2" name="colors" type="PackedColorArray" />
- <param index="3" name="width" type="float" default="1.0" />
+ <param index="3" name="width" type="float" default="-1.0" />
<param index="4" name="antialiased" type="bool" default="false" />
<description>
+ Draws a 2D polyline on the [CanvasItem] pointed to by the [param item] [RID]. See also [method CanvasItem.draw_polyline].
</description>
</method>
<method name="canvas_item_add_primitive">
@@ -302,8 +320,8 @@
<param index="2" name="colors" type="PackedColorArray" />
<param index="3" name="uvs" type="PackedVector2Array" />
<param index="4" name="texture" type="RID" />
- <param index="5" name="width" type="float" default="1.0" />
<description>
+ Draws a 2D primitive on the [CanvasItem] pointed to by the [param item] [RID]. See also [method CanvasItem.draw_primitive].
</description>
</method>
<method name="canvas_item_add_rect">
@@ -312,6 +330,7 @@
<param index="1" name="rect" type="Rect2" />
<param index="2" name="color" type="Color" />
<description>
+ Draws a rectangle on the [CanvasItem] pointed to by the [param item] [RID]. See also [method CanvasItem.draw_rect].
</description>
</method>
<method name="canvas_item_add_set_transform">
@@ -319,6 +338,7 @@
<param index="0" name="item" type="RID" />
<param index="1" name="transform" type="Transform2D" />
<description>
+ Sets a [Transform2D] that will be used to transform subsequent canvas item commands.
</description>
</method>
<method name="canvas_item_add_texture_rect">
@@ -368,6 +388,7 @@
<method name="canvas_item_create">
<return type="RID" />
<description>
+ Creates a new [CanvasItem] instance and returns its [RID].
</description>
</method>
<method name="canvas_item_set_canvas_group_mode">
@@ -877,13 +898,6 @@
<description>
</description>
</method>
- <method name="decal_set_extents">
- <return type="void" />
- <param index="0" name="decal" type="RID" />
- <param index="1" name="extents" type="Vector3" />
- <description>
- </description>
- </method>
<method name="decal_set_fade">
<return type="void" />
<param index="0" name="decal" type="RID" />
@@ -906,6 +920,13 @@
<description>
</description>
</method>
+ <method name="decal_set_size">
+ <return type="void" />
+ <param index="0" name="decal" type="RID" />
+ <param index="1" name="size" type="Vector3" />
+ <description>
+ </description>
+ </method>
<method name="decal_set_texture">
<return type="void" />
<param index="0" name="decal" type="RID" />
@@ -1218,14 +1239,6 @@
Creates a new fog volume and allocates an RID.
</description>
</method>
- <method name="fog_volume_set_extents">
- <return type="void" />
- <param index="0" name="fog_volume" type="RID" />
- <param index="1" name="extents" type="Vector3" />
- <description>
- Sets the size of the fog volume when shape is [constant RenderingServer.FOG_VOLUME_SHAPE_ELLIPSOID], [constant RenderingServer.FOG_VOLUME_SHAPE_CONE], [constant RenderingServer.FOG_VOLUME_SHAPE_CYLINDER] or [constant RenderingServer.FOG_VOLUME_SHAPE_BOX].
- </description>
- </method>
<method name="fog_volume_set_material">
<return type="void" />
<param index="0" name="fog_volume" type="RID" />
@@ -1242,6 +1255,14 @@
Sets the shape of the fog volume to either [constant RenderingServer.FOG_VOLUME_SHAPE_ELLIPSOID], [constant RenderingServer.FOG_VOLUME_SHAPE_CONE], [constant RenderingServer.FOG_VOLUME_SHAPE_CYLINDER], [constant RenderingServer.FOG_VOLUME_SHAPE_BOX] or [constant RenderingServer.FOG_VOLUME_SHAPE_WORLD].
</description>
</method>
+ <method name="fog_volume_set_size">
+ <return type="void" />
+ <param index="0" name="fog_volume" type="RID" />
+ <param index="1" name="size" type="Vector3" />
+ <description>
+ Sets the size of the fog volume when shape is [constant RenderingServer.FOG_VOLUME_SHAPE_ELLIPSOID], [constant RenderingServer.FOG_VOLUME_SHAPE_CONE], [constant RenderingServer.FOG_VOLUME_SHAPE_CYLINDER] or [constant RenderingServer.FOG_VOLUME_SHAPE_BOX].
+ </description>
+ </method>
<method name="force_draw">
<return type="void" />
<param index="0" name="swap_buffers" type="bool" default="true" />
@@ -1261,6 +1282,12 @@
Tries to free an object in the RenderingServer.
</description>
</method>
+ <method name="get_default_clear_color">
+ <return type="Color" />
+ <description>
+ Returns the default clear color which is used when a specific clear color has not been selected.
+ </description>
+ </method>
<method name="get_frame_setup_time_cpu" qualifiers="const">
<return type="float" />
<description>
@@ -1559,7 +1586,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">
@@ -1585,6 +1612,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" />
@@ -1777,6 +1813,7 @@
<method name="lightmap_create">
<return type="RID" />
<description>
+ Creates a new [LightmapGI] instance.
</description>
</method>
<method name="lightmap_get_probe_capture_bsp_tree" qualifiers="const">
@@ -1920,7 +1957,7 @@
<param index="2" name="arrays" type="Array" />
<param index="3" name="blend_shapes" type="Array" default="[]" />
<param index="4" name="lods" type="Dictionary" default="{}" />
- <param index="5" name="compress_format" type="int" default="0" />
+ <param index="5" name="compress_format" type="int" enum="RenderingServer.ArrayFormat" default="0" />
<description>
</description>
</method>
@@ -2022,14 +2059,14 @@
</method>
<method name="mesh_surface_get_format_attribute_stride" qualifiers="const">
<return type="int" />
- <param index="0" name="format" type="int" />
+ <param index="0" name="format" type="int" enum="RenderingServer.ArrayFormat" />
<param index="1" name="vertex_count" type="int" />
<description>
</description>
</method>
<method name="mesh_surface_get_format_offset" qualifiers="const">
<return type="int" />
- <param index="0" name="format" type="int" />
+ <param index="0" name="format" type="int" enum="RenderingServer.ArrayFormat" />
<param index="1" name="vertex_count" type="int" />
<param index="2" name="array_index" type="int" />
<description>
@@ -2037,14 +2074,14 @@
</method>
<method name="mesh_surface_get_format_skin_stride" qualifiers="const">
<return type="int" />
- <param index="0" name="format" type="int" />
+ <param index="0" name="format" type="int" enum="RenderingServer.ArrayFormat" />
<param index="1" name="vertex_count" type="int" />
<description>
</description>
</method>
<method name="mesh_surface_get_format_vertex_stride" qualifiers="const">
<return type="int" />
- <param index="0" name="format" type="int" />
+ <param index="0" name="format" type="int" enum="RenderingServer.ArrayFormat" />
<param index="1" name="vertex_count" type="int" />
<description>
</description>
@@ -2640,14 +2677,6 @@
If [code]true[/code], computes shadows in the reflection probe. This makes the reflection much slower to compute. Equivalent to [member ReflectionProbe.enable_shadows].
</description>
</method>
- <method name="reflection_probe_set_extents">
- <return type="void" />
- <param index="0" name="probe" type="RID" />
- <param index="1" name="extents" type="Vector3" />
- <description>
- Sets the size of the area that the reflection probe will capture. Equivalent to [member ReflectionProbe.extents].
- </description>
- </method>
<method name="reflection_probe_set_intensity">
<return type="void" />
<param index="0" name="probe" type="RID" />
@@ -2686,6 +2715,14 @@
<description>
</description>
</method>
+ <method name="reflection_probe_set_size">
+ <return type="void" />
+ <param index="0" name="probe" type="RID" />
+ <param index="1" name="size" type="Vector3" />
+ <description>
+ Sets the size of the area that the reflection probe will capture. Equivalent to [member ReflectionProbe.size].
+ </description>
+ </method>
<method name="reflection_probe_set_update_mode">
<return type="void" />
<param index="0" name="probe" type="RID" />
@@ -3230,12 +3267,12 @@
<description>
</description>
</method>
- <method name="viewport_set_disable_environment">
+ <method name="viewport_set_environment_mode">
<return type="void" />
<param index="0" name="viewport" type="RID" />
- <param index="1" name="disabled" type="bool" />
+ <param index="1" name="mode" type="int" enum="RenderingServer.ViewportEnvironmentMode" />
<description>
- If [code]true[/code], rendering of a viewport's environment is disabled.
+ Sets the viewport's environment mode which allows enabling or disabling rendering of 3D environment over 2D canvas. When disabled, 2D will not be affected by the environment. When enabled, 2D will be affected by the environment if the environment background mode is [constant ENV_BG_CANVAS]. The default behaviour is to inherit the setting from the viewport's parent. If the topmost parent is also set to [constant VIEWPORT_ENVIRONMENT_INHERIT], then the behavior will be the same as if it was set to [constant VIEWPORT_ENVIRONMENT_ENABLED].
</description>
</method>
<method name="viewport_set_fsr_sharpness">
@@ -3321,7 +3358,7 @@
<param index="0" name="viewport" type="RID" />
<param index="1" name="enabled" type="bool" />
<description>
- If [code]true[/code], render the contents of the viewport directly to screen. This allows a low-level optimization where you can skip drawing a viewport to the root viewport. While this optimization can result in a significant increase in speed (especially on older devices), it comes at a cost of usability. When this is enabled, you cannot read from the viewport or from the [code]SCREEN_TEXTURE[/code]. You also lose the benefit of certain window settings, such as the various stretch modes. Another consequence to be aware of is that in 2D the rendering happens in window coordinates, so if you have a viewport that is double the size of the window, and you set this, then only the portion that fits within the window will be drawn, no automatic scaling is possible, even if your game scene is significantly larger than the window size.
+ If [code]true[/code], render the contents of the viewport directly to screen. This allows a low-level optimization where you can skip drawing a viewport to the root viewport. While this optimization can result in a significant increase in speed (especially on older devices), it comes at a cost of usability. When this is enabled, you cannot read from the viewport or from the screen_texture. You also lose the benefit of certain window settings, such as the various stretch modes. Another consequence to be aware of is that in 2D the rendering happens in window coordinates, so if you have a viewport that is double the size of the window, and you set this, then only the portion that fits within the window will be drawn, no automatic scaling is possible, even if your game scene is significantly larger than the window size.
</description>
</method>
<method name="viewport_set_scaling_3d_mode">
@@ -3735,65 +3772,67 @@
</constant>
<constant name="ARRAY_CUSTOM_MAX" value="8" enum="ArrayCustomFormat">
</constant>
- <constant name="ARRAY_FORMAT_VERTEX" value="1" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_VERTEX" value="1" enum="ArrayFormat" is_bitfield="true">
Flag used to mark a vertex array.
</constant>
- <constant name="ARRAY_FORMAT_NORMAL" value="2" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_NORMAL" value="2" enum="ArrayFormat" is_bitfield="true">
Flag used to mark a normal array.
</constant>
- <constant name="ARRAY_FORMAT_TANGENT" value="4" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_TANGENT" value="4" enum="ArrayFormat" is_bitfield="true">
Flag used to mark a tangent array.
</constant>
- <constant name="ARRAY_FORMAT_COLOR" value="8" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_COLOR" value="8" enum="ArrayFormat" is_bitfield="true">
Flag used to mark a color array.
</constant>
- <constant name="ARRAY_FORMAT_TEX_UV" value="16" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_TEX_UV" value="16" enum="ArrayFormat" is_bitfield="true">
Flag used to mark an UV coordinates array.
</constant>
- <constant name="ARRAY_FORMAT_TEX_UV2" value="32" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_TEX_UV2" value="32" enum="ArrayFormat" is_bitfield="true">
Flag used to mark an UV coordinates array for the second UV coordinates.
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM0" value="64" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM0" value="64" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM1" value="128" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM1" value="128" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM2" value="256" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM2" value="256" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM3" value="512" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM3" value="512" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FORMAT_BONES" value="1024" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_BONES" value="1024" enum="ArrayFormat" is_bitfield="true">
Flag used to mark a bone information array.
</constant>
- <constant name="ARRAY_FORMAT_WEIGHTS" value="2048" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_WEIGHTS" value="2048" enum="ArrayFormat" is_bitfield="true">
Flag used to mark a weights array.
</constant>
- <constant name="ARRAY_FORMAT_INDEX" value="4096" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_INDEX" value="4096" enum="ArrayFormat" is_bitfield="true">
Flag used to mark an index array.
</constant>
- <constant name="ARRAY_FORMAT_BLEND_SHAPE_MASK" value="7" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_BLEND_SHAPE_MASK" value="7" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM_BASE" value="13" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM_BASE" value="13" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM_BITS" value="3" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM_BITS" value="3" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM0_SHIFT" value="13" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM0_SHIFT" value="13" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM1_SHIFT" value="16" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM1_SHIFT" value="16" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM2_SHIFT" value="19" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM2_SHIFT" value="19" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM3_SHIFT" value="22" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM3_SHIFT" value="22" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FORMAT_CUSTOM_MASK" value="7" enum="ArrayFormat">
+ <constant name="ARRAY_FORMAT_CUSTOM_MASK" value="7" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_COMPRESS_FLAGS_BASE" value="25" enum="ArrayFormat">
+ <constant name="ARRAY_COMPRESS_FLAGS_BASE" value="25" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FLAG_USE_2D_VERTICES" value="33554432" enum="ArrayFormat">
+ <constant name="ARRAY_FLAG_USE_2D_VERTICES" value="33554432" enum="ArrayFormat" is_bitfield="true">
Flag used to mark that the array contains 2D vertices.
</constant>
- <constant name="ARRAY_FLAG_USE_DYNAMIC_UPDATE" value="67108864" enum="ArrayFormat">
+ <constant name="ARRAY_FLAG_USE_DYNAMIC_UPDATE" value="67108864" enum="ArrayFormat" is_bitfield="true">
+ </constant>
+ <constant name="ARRAY_FLAG_USE_8_BONE_WEIGHTS" value="134217728" enum="ArrayFormat" is_bitfield="true">
</constant>
- <constant name="ARRAY_FLAG_USE_8_BONE_WEIGHTS" value="134217728" enum="ArrayFormat">
+ <constant name="ARRAY_FLAG_USES_EMPTY_VERTEX_ARRAY" value="268435456" enum="ArrayFormat" is_bitfield="true">
</constant>
<constant name="PRIMITIVE_POINTS" value="0" enum="PrimitiveType">
Primitive to draw consists of points.
@@ -4074,10 +4113,10 @@
[FogVolume] will be shaped like an ellipsoid (stretched sphere).
</constant>
<constant name="FOG_VOLUME_SHAPE_CONE" value="1" enum="FogVolumeShape">
- [FogVolume] will be shaped like a cone pointing upwards (in local coordinates). The cone's angle is set automatically to fill the extents. The cone will be adjusted to fit within the extents. Rotate the [FogVolume] node to reorient the cone. Non-uniform scaling via extents is not supported (scale the [FogVolume] node instead).
+ [FogVolume] will be shaped like a cone pointing upwards (in local coordinates). The cone's angle is set automatically to fill the size. The cone will be adjusted to fit within the size. Rotate the [FogVolume] node to reorient the cone. Non-uniform scaling via size is not supported (scale the [FogVolume] node instead).
</constant>
<constant name="FOG_VOLUME_SHAPE_CYLINDER" value="2" enum="FogVolumeShape">
- [FogVolume] will be shaped like an upright cylinder (in local coordinates). Rotate the [FogVolume] node to reorient the cylinder. The cylinder will be adjusted to fit within the extents. Non-uniform scaling via extents is not supported (scale the [FogVolume] node instead).
+ [FogVolume] will be shaped like an upright cylinder (in local coordinates). Rotate the [FogVolume] node to reorient the cylinder. The cylinder will be adjusted to fit within the size. Non-uniform scaling via size is not supported (scale the [FogVolume] node instead).
</constant>
<constant name="FOG_VOLUME_SHAPE_BOX" value="3" enum="FogVolumeShape">
[FogVolume] will be shaped like a box.
@@ -4118,6 +4157,18 @@
<constant name="VIEWPORT_CLEAR_ONLY_NEXT_FRAME" value="2" enum="ViewportClearMode">
The viewport is cleared once, then the clear mode is set to [constant VIEWPORT_CLEAR_NEVER].
</constant>
+ <constant name="VIEWPORT_ENVIRONMENT_DISABLED" value="0" enum="ViewportEnvironmentMode">
+ Disable rendering of 3D environment over 2D canvas.
+ </constant>
+ <constant name="VIEWPORT_ENVIRONMENT_ENABLED" value="1" enum="ViewportEnvironmentMode">
+ Enable rendering of 3D environment over 2D canvas.
+ </constant>
+ <constant name="VIEWPORT_ENVIRONMENT_INHERIT" value="2" enum="ViewportEnvironmentMode">
+ Inherit enable/disable value from parent. If topmost parent is also set to inherit, then this has the same behavior as [constant VIEWPORT_ENVIRONMENT_ENABLED].
+ </constant>
+ <constant name="VIEWPORT_ENVIRONMENT_MAX" value="3" enum="ViewportEnvironmentMode">
+ Max value of [enum ViewportEnvironmentMode] enum.
+ </constant>
<constant name="VIEWPORT_SDF_OVERSIZE_100_PERCENT" value="0" enum="ViewportSDFOversize">
</constant>
<constant name="VIEWPORT_SDF_OVERSIZE_120_PERCENT" value="1" enum="ViewportSDFOversize">
@@ -4536,12 +4587,16 @@
Fade-in the given instance's dependencies when reaching its visibility range limits.
</constant>
<constant name="BAKE_CHANNEL_ALBEDO_ALPHA" value="0" enum="BakeChannels">
+ Index of [Image] in array of [Image]s returned by [method bake_render_uv2]. Image uses [constant Image.FORMAT_RGBA8] and contains albedo color in the [code].rgb[/code] channels and alpha in the [code].a[/code] channel.
</constant>
<constant name="BAKE_CHANNEL_NORMAL" value="1" enum="BakeChannels">
+ Index of [Image] in array of [Image]s returned by [method bake_render_uv2]. Image uses [constant Image.FORMAT_RGBA8] and contains the per-pixel normal of the object in the [code].rgb[/code] channels and nothing in the [code].a[/code] channel. The per-pixel normal is encoded as [code]normal * 0.5 + 0.5[/code].
</constant>
<constant name="BAKE_CHANNEL_ORM" value="2" enum="BakeChannels">
+ Index of [Image] in array of [Image]s returned by [method bake_render_uv2]. Image uses [constant Image.FORMAT_RGBA8] and contains ambient occlusion (from material and decals only) in the [code].r[/code] channel, roughness in the [code].g[/code] channel, metallic in the [code].b[/code] channel and sub surface scattering amount in the [code].a[/code] channel.
</constant>
<constant name="BAKE_CHANNEL_EMISSION" value="3" enum="BakeChannels">
+ Index of [Image] in array of [Image]s returned by [method bake_render_uv2]. Image uses [constant Image.FORMAT_RGBAH] and contains emission color in the [code].rgb[/code] channels and nothing in the [code].a[/code] channel.
</constant>
<constant name="CANVAS_TEXTURE_CHANNEL_DIFFUSE" value="0" enum="CanvasTextureChannel">
</constant>
diff --git a/doc/classes/Resource.xml b/doc/classes/Resource.xml
index e533fc1e32..67f466ad4c 100644
--- a/doc/classes/Resource.xml
+++ b/doc/classes/Resource.xml
@@ -24,7 +24,8 @@
<param index="0" name="subresources" type="bool" default="false" />
<description>
Duplicates this resource, returning a new resource with its [code]export[/code]ed or [constant PROPERTY_USAGE_STORAGE] properties copied from the original.
- If [param subresources] is [code]false[/code], a shallow copy is returned. Nested resources within subresources are not duplicated and are shared from the original resource. This behavior can be overridden by the [constant PROPERTY_USAGE_DO_NOT_SHARE_ON_DUPLICATE] flag.
+ If [param subresources] is [code]false[/code], a shallow copy is returned; nested resources within subresources are not duplicated and are shared from the original resource. If [param subresources] is [code]true[/code], a deep copy is returned; nested subresources will be duplicated and are not shared.
+ Subresource properties with the [constant PROPERTY_USAGE_ALWAYS_DUPLICATE] flag are always duplicated even with [param subresources] set to [code]false[/code], and properties with the [constant PROPERTY_USAGE_NEVER_DUPLICATE] flag are never duplicated even with [param subresources] set to [code]true[/code].
[b]Note:[/b] For custom resources, this method will fail if [method Object._init] has been defined with required parameters.
</description>
</method>
diff --git a/doc/classes/ResourceFormatLoader.xml b/doc/classes/ResourceFormatLoader.xml
index 2b6376f2cd..1d509d2938 100644
--- a/doc/classes/ResourceFormatLoader.xml
+++ b/doc/classes/ResourceFormatLoader.xml
@@ -38,6 +38,13 @@
Gets the list of extensions for files this loader is able to read.
</description>
</method>
+ <method name="_get_resource_script_class" qualifiers="virtual const">
+ <return type="String" />
+ <param index="0" name="path" type="String" />
+ <description>
+ Returns the script class name associated with the [Resource] under the given [param path]. If the resource has no script or the script isn't a named class, it should return [code]""[/code].
+ </description>
+ </method>
<method name="_get_resource_type" qualifiers="virtual const">
<return type="String" />
<param index="0" name="path" type="String" />
@@ -81,7 +88,7 @@
</description>
</method>
<method name="_rename_dependencies" qualifiers="virtual const">
- <return type="int" />
+ <return type="int" enum="Error" />
<param index="0" name="path" type="String" />
<param index="1" name="renames" type="Dictionary" />
<description>
diff --git a/doc/classes/ResourceFormatSaver.xml b/doc/classes/ResourceFormatSaver.xml
index 1f2af6d157..7e8e2ec67d 100644
--- a/doc/classes/ResourceFormatSaver.xml
+++ b/doc/classes/ResourceFormatSaver.xml
@@ -34,7 +34,7 @@
</description>
</method>
<method name="_save" qualifiers="virtual">
- <return type="int" />
+ <return type="int" enum="Error" />
<param index="0" name="resource" type="Resource" />
<param index="1" name="path" type="String" />
<param index="2" name="flags" type="int" />
@@ -43,5 +43,13 @@
Returns [constant OK] on success, or an [enum Error] constant in case of failure.
</description>
</method>
+ <method name="_set_uid" qualifiers="virtual">
+ <return type="int" enum="Error" />
+ <param index="0" name="path" type="String" />
+ <param index="1" name="uid" type="int" />
+ <description>
+ Sets a new UID for the resource at the given [param path]. Returns [constant OK] on success, or an [enum Error] constant in case of failure.
+ </description>
+ </method>
</methods>
</class>
diff --git a/doc/classes/ResourcePreloader.xml b/doc/classes/ResourcePreloader.xml
index 17904697e6..5c0079f408 100644
--- a/doc/classes/ResourcePreloader.xml
+++ b/doc/classes/ResourcePreloader.xml
@@ -1,10 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="ResourcePreloader" inherits="Node" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
- Resource Preloader Node.
+ Preloads a list of resources inside a scene.
</brief_description>
<description>
- This node is used to preload sub-resources inside a scene, so when the scene is loaded, all the resources are ready to use and can be retrieved from the preloader.
+ This node is used to preload sub-resources inside a scene, so when the scene is loaded, all the resources are ready to use and can be retrieved from the preloader. You can add the resources using the ResourcePreloader tab when the node is selected.
GDScript has a simplified [method @GDScript.preload] built-in method which can be used in most situations, leaving the use of [ResourcePreloader] for more advanced scenarios.
</description>
<tutorials>
diff --git a/doc/classes/RichTextEffect.xml b/doc/classes/RichTextEffect.xml
index c01546524d..333d34d1b7 100644
--- a/doc/classes/RichTextEffect.xml
+++ b/doc/classes/RichTextEffect.xml
@@ -13,7 +13,7 @@
[/gdscript]
[csharp]
// The RichTextEffect will be usable like this: `[example]Some text[/example]`
- public string bbcode = "example";
+ string bbcode = "example";
[/csharp]
[/codeblocks]
[b]Note:[/b] As soon as a [RichTextLabel] contains at least one [RichTextEffect], it will continuously process the effect unless the project is paused. This may impact battery life negatively.
diff --git a/doc/classes/RichTextLabel.xml b/doc/classes/RichTextLabel.xml
index e222894647..1ecc8a1d4e 100644
--- a/doc/classes/RichTextLabel.xml
+++ b/doc/classes/RichTextLabel.xml
@@ -8,7 +8,7 @@
[b]Note:[/b] Assignments to [member text] clear the tag stack and reconstruct it from the property's contents. Any edits made to [member text] will erase previous edits made from other manual sources such as [method append_text] and the [code]push_*[/code] / [method pop] methods.
[b]Note:[/b] RichTextLabel doesn't support entangled BBCode tags. For example, instead of using [code][b]bold[i]bold italic[/b]italic[/i][/code], use [code][b]bold[i]bold italic[/i][/b][i]italic[/i][/code].
[b]Note:[/b] [code]push_*/pop[/code] functions won't affect BBCode.
- [b]Note:[/b] Unlike [Label], RichTextLabel doesn't have a [i]property[/i] to horizontally align text to the center. Instead, enable [member bbcode_enabled] and surround the text in a [code][center][/code] tag as follows: [code][center]Example[/center][/code]. There is currently no built-in way to vertically align text either, but this can be emulated by relying on anchors/containers and the [member fit_content_height] property.
+ [b]Note:[/b] Unlike [Label], RichTextLabel doesn't have a [i]property[/i] to horizontally align text to the center. Instead, enable [member bbcode_enabled] and surround the text in a [code][center][/code] tag as follows: [code][center]Example[/center][/code]. There is currently no built-in way to vertically align text either, but this can be emulated by relying on anchors/containers and the [member fit_content] property.
</description>
<tutorials>
<link title="BBCode in RichTextLabel">$DOCS_URL/tutorials/ui/bbcode_in_richtextlabel.html</link>
@@ -251,6 +251,14 @@
Adds a [code][color][/code] tag to the tag stack.
</description>
</method>
+ <method name="push_customfx">
+ <return type="void" />
+ <param index="0" name="effect" type="RichTextEffect" />
+ <param index="1" name="env" type="Dictionary" />
+ <description>
+ Adds a custom effect tag to the tag stack. The effect does not need to be in [member custom_effects]. The environment is directly passed to the effect.
+ </description>
+ </method>
<method name="push_dropcap">
<return type="void" />
<param index="0" name="string" type="String" />
@@ -283,6 +291,7 @@
<return type="void" />
<param index="0" name="font_size" type="int" />
<description>
+ Adds a [code][font_size][/code] tag to the tag stack. Overrides default font size for its duration.
</description>
</method>
<method name="push_hint">
@@ -367,6 +376,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 +387,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">
@@ -472,9 +482,8 @@
<member name="deselect_on_focus_loss_enabled" type="bool" setter="set_deselect_on_focus_loss_enabled" getter="is_deselect_on_focus_loss_enabled" default="true">
If [code]true[/code], the selected text will be deselected when focus is lost.
</member>
- <member name="fit_content_height" type="bool" setter="set_fit_content_height" getter="is_fit_content_height_enabled" default="false">
- If [code]true[/code], the label's height will be automatically updated to fit its content.
- [b]Note:[/b] This property is used as a workaround to fix issues with [RichTextLabel] in [Container]s, but it's unreliable in some cases and will be removed in future versions.
+ <member name="fit_content" type="bool" setter="set_fit_content" getter="is_fit_content_enabled" default="false">
+ If [code]true[/code], the label's minimum size will be automatically updated to fit its content, matching the behavior of [Label].
</member>
<member name="hint_underlined" type="bool" setter="set_hint_underline" getter="is_hint_underlined" default="true">
If [code]true[/code], the label underlines hint tags such as [code][hint=description]{text}[/hint][/code].
@@ -655,6 +664,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/RigidBody3D.xml b/doc/classes/RigidBody3D.xml
index 8380d56de3..148cdf96ee 100644
--- a/doc/classes/RigidBody3D.xml
+++ b/doc/classes/RigidBody3D.xml
@@ -8,6 +8,7 @@
You can switch the body's behavior using [member lock_rotation], [member freeze], and [member freeze_mode].
[b]Note:[/b] Don't change a RigidBody3D's position every frame or very often. Sporadic changes work fine, but physics runs at a different granularity (fixed Hz) than usual rendering (process callback) and maybe even in a separate thread, so changing this from a process loop may result in strange behavior. If you need to directly affect the body's state, use [method _integrate_forces], which allows you to directly access the physics state.
If you need to override the default physics behavior, you can write a custom force integration function. See [member custom_integrator].
+ [b]Warning:[/b] With a non-uniform scale this node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change the size(s) of its collision shape(s) instead.
</description>
<tutorials>
<link title="Physics introduction">$DOCS_URL/tutorials/physics/physics_introduction.html</link>
diff --git a/doc/classes/SceneTree.xml b/doc/classes/SceneTree.xml
index bd5b656e1a..6adb37a3f7 100644
--- a/doc/classes/SceneTree.xml
+++ b/doc/classes/SceneTree.xml
@@ -42,15 +42,15 @@
<description>
Changes the running scene to the one at the given [param path], after loading it into a [PackedScene] and creating a new instance.
Returns [constant OK] on success, [constant ERR_CANT_OPEN] if the [param path] cannot be loaded into a [PackedScene], or [constant ERR_CANT_CREATE] if that scene cannot be instantiated.
- [b]Note:[/b] The scene change is deferred, which means that the new scene node is added on the next idle frame. You won't be able to access it immediately after the [method change_scene_to_file] call.
+ [b]Note:[/b] The scene change is deferred, which means that the new scene node is added on the next idle frame. This ensures that both scenes are never loaded at the same time, which can exhaust system resources if the scenes are too large or if running in a memory constrained environment. As such, you won't be able to access the loaded scene immediately after the [method change_scene_to_file] call.
</description>
</method>
<method name="change_scene_to_packed">
<return type="int" enum="Error" />
<param index="0" name="packed_scene" type="PackedScene" />
<description>
- Changes the running scene to a new instance of the given [PackedScene].
- Returns [constant OK] on success or [constant ERR_CANT_CREATE] if the scene cannot be instantiated.
+ Changes the running scene to a new instance of the given [PackedScene] (which must be valid).
+ Returns [constant OK] on success, [constant ERR_CANT_CREATE] if the scene cannot be instantiated, or [constant ERR_INVALID_PARAMETER] if the scene is invalid.
[b]Note:[/b] The scene change is deferred, which means that the new scene node is added on the next idle frame. You won't be able to access it immediately after the [method change_scene_to_packed] call.
</description>
</method>
@@ -74,10 +74,10 @@
print("end")
[/gdscript]
[csharp]
- public async void SomeFunction()
+ public async Task SomeFunction()
{
GD.Print("start");
- await ToSignal(GetTree().CreateTimer(1.0f), "timeout");
+ await ToSignal(GetTree().CreateTimer(1.0f), SceneTreeTimer.SignalName.Timeout);
GD.Print("end");
}
[/csharp]
@@ -209,6 +209,12 @@
Sets a custom [MultiplayerAPI] with the given [param root_path] (controlling also the relative subpaths), or override the default one if [param root_path] is empty.
</description>
</method>
+ <method name="unload_current_scene">
+ <return type="void" />
+ <description>
+ If a current scene is loaded, calling this method will unload it.
+ </description>
+ </method>
</methods>
<members>
<member name="auto_accept_quit" type="bool" setter="set_auto_accept_quit" getter="is_auto_accept_quit" default="true">
diff --git a/doc/classes/SceneTreeTimer.xml b/doc/classes/SceneTreeTimer.xml
index f28e65c5bf..42b070d7d9 100644
--- a/doc/classes/SceneTreeTimer.xml
+++ b/doc/classes/SceneTreeTimer.xml
@@ -14,10 +14,10 @@
print("Timer ended.")
[/gdscript]
[csharp]
- public async void SomeFunction()
+ public async Task SomeFunction()
{
GD.Print("Timer started.");
- await ToSignal(GetTree().CreateTimer(1.0f), "timeout");
+ await ToSignal(GetTree().CreateTimer(1.0f), SceneTreeTimer.SignalName.Timeout);
GD.Print("Timer ended.");
}
[/csharp]
diff --git a/doc/classes/Semaphore.xml b/doc/classes/Semaphore.xml
index 6b2007363e..d1d126c5cb 100644
--- a/doc/classes/Semaphore.xml
+++ b/doc/classes/Semaphore.xml
@@ -17,9 +17,9 @@
</description>
</method>
<method name="try_wait">
- <return type="int" enum="Error" />
+ <return type="bool" />
<description>
- Like [method wait], but won't block, so if the value is zero, fails immediately and returns [constant ERR_BUSY]. If non-zero, it returns [constant OK] to report success.
+ Like [method wait], but won't block, so if the value is zero, fails immediately and returns [code]false[/code]. If non-zero, it returns [code]true[/code] to report success.
</description>
</method>
<method name="wait">
diff --git a/doc/classes/Shader.xml b/doc/classes/Shader.xml
index 75f835260a..c472ab647e 100644
--- a/doc/classes/Shader.xml
+++ b/doc/classes/Shader.xml
@@ -26,12 +26,12 @@
Returns the shader mode for the shader, either [constant MODE_CANVAS_ITEM], [constant MODE_SPATIAL] or [constant MODE_PARTICLES].
</description>
</method>
- <method name="has_parameter" qualifiers="const">
- <return type="bool" />
- <param index="0" name="name" type="StringName" />
+ <method name="get_shader_uniform_list">
+ <return type="Array" />
+ <param index="0" name="get_groups" type="bool" default="false" />
<description>
- Returns [code]true[/code] if the shader has this param defined as a uniform in its code.
- [b]Note:[/b] [param name] must match the name of the uniform in the code exactly.
+ Get the list of shader uniforms that can be assigned to a [ShaderMaterial], for use with [method ShaderMaterial.set_shader_parameter] and [method ShaderMaterial.get_shader_parameter]. The parameters returned are contained in dictionaries in a similar format to the ones returned by [method Object.get_property_list].
+ If argument [param get_groups] is true, parameter grouping hints will be provided.
</description>
</method>
<method name="set_default_texture_parameter">
diff --git a/doc/classes/ShaderMaterial.xml b/doc/classes/ShaderMaterial.xml
index 1af7ac4fc5..a2346822e5 100644
--- a/doc/classes/ShaderMaterial.xml
+++ b/doc/classes/ShaderMaterial.xml
@@ -23,7 +23,8 @@
<param index="1" name="value" type="Variant" />
<description>
Changes the value set for this material of a uniform in the shader.
- [b]Note:[/b] [param param] must match the name of the uniform in the code exactly.
+ [b]Note:[/b] [param param] is case-sensitive and must match the name of the uniform in the code exactly (not the capitalized name in the inspector).
+ [b]Note:[/b] Changes to the shader uniform will be effective on all instances using this [ShaderMaterial]. To prevent this, use per-instance uniforms with [method GeometryInstance3D.set_instance_shader_parameter] or duplicate the [ShaderMaterial] resource using [method Resource.duplicate]. Per-instance uniforms allow for better shader reuse and are therefore faster, so they should be preferred over duplicating the [ShaderMaterial] when possible.
</description>
</method>
</methods>
diff --git a/doc/classes/Signal.xml b/doc/classes/Signal.xml
index 3412cd2140..71905e8b2e 100644
--- a/doc/classes/Signal.xml
+++ b/doc/classes/Signal.xml
@@ -16,12 +16,12 @@
[/gdscript]
[csharp]
[Signal]
- delegate void Attacked();
+ delegate void AttackedEventHandler();
// Additional arguments may be declared.
// These arguments must be passed when the signal is emitted.
[Signal]
- delegate void ItemDropped(itemName: string, amount: int);
+ delegate void ItemDroppedEventHandler(string itemName, int amount);
[/csharp]
[/codeblocks]
</description>
diff --git a/doc/classes/Skeleton2D.xml b/doc/classes/Skeleton2D.xml
index 808f93b491..39bdc5c796 100644
--- a/doc/classes/Skeleton2D.xml
+++ b/doc/classes/Skeleton2D.xml
@@ -16,7 +16,7 @@
<param index="0" name="delta" type="float" />
<param index="1" name="execution_mode" type="int" />
<description>
- Executes all the modifications on the [SkeletonModificationStack2D], if the Skeleton3D has one assigned.
+ Executes all the modifications on the [SkeletonModificationStack2D], if the Skeleton2D has one assigned.
</description>
</method>
<method name="get_bone">
diff --git a/doc/classes/Skeleton3D.xml b/doc/classes/Skeleton3D.xml
index 3bd0e04b92..70986ba06a 100644
--- a/doc/classes/Skeleton3D.xml
+++ b/doc/classes/Skeleton3D.xml
@@ -7,6 +7,7 @@
Skeleton3D provides a hierarchical interface for managing bones, including pose, rest and animation (see [Animation]). It can also use ragdoll physics.
The overall transform of a bone with respect to the skeleton is determined by the following hierarchical order: rest pose, custom pose and pose.
Note that "global pose" below refers to the overall transform of the bone with respect to skeleton, so it not the actual global/world transform of the bone.
+ To setup different types of inverse kinematics, consider using [SkeletonIK3D], or add a custom IK implementation in [method Node._process] as a child node.
</description>
<tutorials>
<link title="3D Inverse Kinematics Demo">https://godotengine.org/asset-library/asset/523</link>
@@ -32,26 +33,11 @@
Removes the global pose override on all bones in the skeleton.
</description>
</method>
- <method name="clear_bones_local_pose_override" is_deprecated="true">
- <return type="void" />
- <description>
- Deprecated. Local pose overrides will be removed.
- Removes the local pose override on all bones in the skeleton.
- </description>
- </method>
<method name="create_skin_from_rest_transforms">
<return type="Skin" />
<description>
</description>
</method>
- <method name="execute_modifications" is_deprecated="true">
- <return type="void" />
- <param index="0" name="delta" type="float" />
- <param index="1" name="execution_mode" type="int" />
- <description>
- Executes all the modifications on the [SkeletonModificationStack3D], if the Skeleton3D has one assigned.
- </description>
- </method>
<method name="find_bone" qualifiers="const">
<return type="int" />
<param index="0" name="name" type="String" />
@@ -113,13 +99,6 @@
Returns the global rest transform for [param bone_idx].
</description>
</method>
- <method name="get_bone_local_pose_override" qualifiers="const">
- <return type="Transform3D" />
- <param index="0" name="bone_idx" type="int" />
- <description>
- Returns the local pose override transform for [param bone_idx].
- </description>
- </method>
<method name="get_bone_name" qualifiers="const">
<return type="String" />
<param index="0" name="bone_idx" type="int" />
@@ -167,43 +146,18 @@
Returns the rest transform for a bone [param bone_idx].
</description>
</method>
- <method name="get_modification_stack" is_deprecated="true">
- <return type="SkeletonModificationStack3D" />
- <description>
- Returns the modification stack attached to this skeleton, if one exists.
- </description>
- </method>
<method name="get_parentless_bones" qualifiers="const">
<return type="PackedInt32Array" />
<description>
Returns an array with all of the bones that are parentless. Another way to look at this is that it returns the indexes of all the bones that are not dependent or modified by other bones in the Skeleton.
</description>
</method>
- <method name="global_pose_to_local_pose" is_deprecated="true">
- <return type="Transform3D" />
- <param index="0" name="bone_idx" type="int" />
- <param index="1" name="global_pose" type="Transform3D" />
- <description>
- Takes the passed-in global pose and converts it to local pose transform.
- This can be used to easily convert a global pose from [method get_bone_global_pose] to a global transform in [method set_bone_local_pose_override].
- </description>
- </method>
- <method name="global_pose_to_world_transform" is_deprecated="true">
- <return type="Transform3D" />
- <param index="0" name="global_pose" type="Transform3D" />
- <description>
- Deprecated. Use [Node3D] apis instead.
- Takes the passed-in global pose and converts it to a world transform.
- This can be used to easily convert a global pose from [method get_bone_global_pose] to a global transform usable with a node's transform, like [member Node3D.global_transform] for example.
- </description>
- </method>
- <method name="global_pose_z_forward_to_bone_forward" is_deprecated="true">
- <return type="Basis" />
- <param index="0" name="bone_idx" type="int" />
- <param index="1" name="basis" type="Basis" />
+ <method name="get_version" qualifiers="const">
+ <return type="int" />
<description>
- Rotates the given [Basis] so that the forward axis of the Basis is facing in the forward direction of the bone at [param bone_idx].
- This is helper function to make using [method Transform3D.looking_at] easier with bone poses.
+ Returns the number of times the bone hierarchy has changed within this skeleton, including renames.
+ The Skeleton version is not serialized: only use within a single instance of Skeleton3D.
+ Use for invalidating caches in IK solvers and other nodes which process bones.
</description>
</method>
<method name="is_bone_enabled" qualifiers="const">
@@ -213,15 +167,6 @@
Returns whether the bone pose for the bone at [param bone_idx] is enabled.
</description>
</method>
- <method name="local_pose_to_global_pose" is_deprecated="true">
- <return type="Transform3D" />
- <param index="0" name="bone_idx" type="int" />
- <param index="1" name="local_pose" type="Transform3D" />
- <description>
- Converts the passed-in local pose to a global pose relative to the inputted bone, [param bone_idx].
- This could be used to convert [method get_bone_pose] for use with the [method set_bone_global_pose_override] function.
- </description>
- </method>
<method name="localize_rests">
<return type="void" />
<description>
@@ -298,19 +243,6 @@
[b]Note:[/b] The pose transform needs to be a global pose! To convert a world transform from a [Node3D] to a global bone pose, multiply the [method Transform3D.affine_inverse] of the node's [member Node3D.global_transform] by the desired world transform
</description>
</method>
- <method name="set_bone_local_pose_override" is_deprecated="true">
- <return type="void" />
- <param index="0" name="bone_idx" type="int" />
- <param index="1" name="pose" type="Transform3D" />
- <param index="2" name="amount" type="float" />
- <param index="3" name="persistent" type="bool" default="false" />
- <description>
- Deprecated. Local pose overrides will be removed.
- Sets the local pose transform, [param pose], for the bone at [param bone_idx].
- [param amount] is the interpolation strength that will be used when applying the pose, and [param persistent] determines if the applied pose will remain.
- [b]Note:[/b] The pose transform needs to be a local pose! Use [method global_pose_to_local_pose] to convert a global pose to a local pose.
- </description>
- </method>
<method name="set_bone_name">
<return type="void" />
<param index="0" name="bone_idx" type="int" />
@@ -356,13 +288,6 @@
Sets the rest transform for bone [param bone_idx].
</description>
</method>
- <method name="set_modification_stack" is_deprecated="true">
- <return type="void" />
- <param index="0" name="modification_stack" type="SkeletonModificationStack3D" />
- <description>
- Sets the modification stack for this skeleton to the passed-in modification stack, [param modification_stack].
- </description>
- </method>
<method name="unparent_bone_and_rest">
<return type="void" />
<param index="0" name="bone_idx" type="int" />
@@ -370,15 +295,6 @@
Unparents the bone at [param bone_idx] and sets its rest position to that of its parent prior to being reset.
</description>
</method>
- <method name="world_transform_to_global_pose" is_deprecated="true">
- <return type="Transform3D" />
- <param index="0" name="world_transform" type="Transform3D" />
- <description>
- Deprecated. Use [Node3D] apis instead.
- Takes the passed-in global transform and converts it to a global pose.
- This can be used to easily convert a global transform from [member Node3D.global_transform] to a global pose usable with [method set_bone_global_pose_override], for example.
- </description>
- </method>
</methods>
<members>
<member name="animate_physical_bones" type="bool" setter="set_animate_physical_bones" getter="get_animate_physical_bones" default="true">
diff --git a/doc/classes/SkeletonModification2D.xml b/doc/classes/SkeletonModification2D.xml
index 77aaf0213b..3a78f13bff 100644
--- a/doc/classes/SkeletonModification2D.xml
+++ b/doc/classes/SkeletonModification2D.xml
@@ -56,7 +56,7 @@
<method name="get_modification_stack">
<return type="SkeletonModificationStack2D" />
<description>
- Returns the [SkeletonModificationStack2D] that this modification is bound to. Through the modification stack, you can access the Skeleton3D the modification is operating on.
+ Returns the [SkeletonModificationStack2D] that this modification is bound to. Through the modification stack, you can access the Skeleton2D the modification is operating on.
</description>
</method>
<method name="set_editor_draw_gizmo">
diff --git a/doc/classes/SkeletonModification3D.xml b/doc/classes/SkeletonModification3D.xml
deleted file mode 100644
index 25431ea96f..0000000000
--- a/doc/classes/SkeletonModification3D.xml
+++ /dev/null
@@ -1,66 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<class name="SkeletonModification3D" inherits="Resource" is_deprecated="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
- <brief_description>
- A resource that operates on bones in a [Skeleton3D].
- </brief_description>
- <description>
- This resource provides an interface that can be expanded so code that operates on bones in a [Skeleton3D] can be mixed and matched together to create complex interactions.
- This is used to provide Godot with a flexible and powerful Inverse Kinematics solution that can be adapted for many different uses.
- </description>
- <tutorials>
- </tutorials>
- <methods>
- <method name="_execute" qualifiers="virtual">
- <return type="void" />
- <param index="0" name="delta" type="float" />
- <description>
- Executes the given modification. This is where the modification performs whatever function it is designed to do.
- </description>
- </method>
- <method name="_setup_modification" qualifiers="virtual">
- <return type="void" />
- <param index="0" name="modification_stack" type="SkeletonModificationStack3D" />
- <description>
- Sets up the modification so it can be executed. This function should be called automatically by the [SkeletonModificationStack3D] containing this modification.
- If you need to initialize a modification before use, this is the place to do it!
- </description>
- </method>
- <method name="clamp_angle">
- <return type="float" />
- <param index="0" name="angle" type="float" />
- <param index="1" name="min" type="float" />
- <param index="2" name="max" type="float" />
- <param index="3" name="invert" type="bool" />
- <description>
- Takes a angle and clamps it so it is within the passed-in [param min] and [param max] range. [param invert] will inversely clamp the angle, clamping it to the range outside of the given bounds.
- </description>
- </method>
- <method name="get_is_setup" qualifiers="const">
- <return type="bool" />
- <description>
- Returns whether this modification has been successfully setup or not.
- </description>
- </method>
- <method name="get_modification_stack">
- <return type="SkeletonModificationStack3D" />
- <description>
- Returns the [SkeletonModificationStack3D] that this modification is bound to. Through the modification stack, you can access the Skeleton3D the modification is operating on.
- </description>
- </method>
- <method name="set_is_setup">
- <return type="void" />
- <param index="0" name="is_setup" type="bool" />
- <description>
- Manually allows you to set the setup state of the modification. This function should only rarely be used, as the [SkeletonModificationStack3D] the modification is bound to should handle setting the modification up.
- </description>
- </method>
- </methods>
- <members>
- <member name="enabled" type="bool" setter="set_enabled" getter="get_enabled" default="true">
- When true, the modification's [method _execute] function will be called by the [SkeletonModificationStack3D].
- </member>
- <member name="execution_mode" type="int" setter="set_execution_mode" getter="get_execution_mode" default="0">
- The execution mode for the modification. This tells the modification stack when to execute the modification. Some modifications have settings that are only available in certain execution modes.
- </member>
- </members>
-</class>
diff --git a/doc/classes/SkeletonModification3DCCDIK.xml b/doc/classes/SkeletonModification3DCCDIK.xml
deleted file mode 100644
index 90b2e78449..0000000000
--- a/doc/classes/SkeletonModification3DCCDIK.xml
+++ /dev/null
@@ -1,136 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<class name="SkeletonModification3DCCDIK" inherits="SkeletonModification3D" is_deprecated="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
- <brief_description>
- A modification that uses CCDIK to manipulate a series of bones to reach a target.
- </brief_description>
- <description>
- This [SkeletonModification3D] uses an algorithm called Cyclic Coordinate Descent Inverse Kinematics, or CCDIK, to manipulate a chain of bones in a Skeleton so it reaches a defined target.
- CCDIK works by rotating a set of bones, typically called a "bone chain", on a single axis. Each bone is rotated to face the target from the tip (by default), which over a chain of bones allow it to rotate properly to reach the target. Because the bones only rotate on a single axis, CCDIK [i]can[/i] look more robotic than other IK solvers.
- [b]Note:[/b] The CCDIK modifier has [code]ccdik_joints[/code], which are the data objects that hold the data for each joint in the CCDIK chain. This is different from a bone! CCDIK joints hold the data needed for each bone in the bone chain used by CCDIK.
- CCDIK also fully supports angle constraints, allowing for more control over how a solution is met.
- </description>
- <tutorials>
- </tutorials>
- <methods>
- <method name="get_ccdik_joint_bone_index" qualifiers="const">
- <return type="int" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the bone index of the bone assigned to the CCDIK joint at [param joint_idx].
- </description>
- </method>
- <method name="get_ccdik_joint_bone_name" qualifiers="const">
- <return type="String" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the name of the bone that is assigned to the CCDIK joint at [param joint_idx].
- </description>
- </method>
- <method name="get_ccdik_joint_ccdik_axis" qualifiers="const">
- <return type="int" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the integer representing the joint axis of the CCDIK joint at [param joint_idx].
- </description>
- </method>
- <method name="get_ccdik_joint_constraint_angle_max" qualifiers="const">
- <return type="float" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the maximum angle constraint for the joint at [param joint_idx]. [b]Note:[/b] This angle is in degrees!
- </description>
- </method>
- <method name="get_ccdik_joint_constraint_angle_min" qualifiers="const">
- <return type="float" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the minimum angle constraint for the joint at [param joint_idx]. [b]Note:[/b] This angle is in degrees!
- </description>
- </method>
- <method name="get_ccdik_joint_constraint_invert" qualifiers="const">
- <return type="bool" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns whether the CCDIK joint at [param joint_idx] uses an inverted joint constraint. See [method set_ccdik_joint_constraint_invert] for details.
- </description>
- </method>
- <method name="get_ccdik_joint_enable_joint_constraint" qualifiers="const">
- <return type="bool" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Enables angle constraints to the CCDIK joint at [param joint_idx].
- </description>
- </method>
- <method name="set_ccdik_joint_bone_index">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="bone_index" type="int" />
- <description>
- Sets the bone index, [param bone_index], of the CCDIK joint at [param joint_idx]. When possible, this will also update the [code]bone_name[/code] of the CCDIK joint based on data provided by the linked skeleton.
- </description>
- </method>
- <method name="set_ccdik_joint_bone_name">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="bone_name" type="String" />
- <description>
- Sets the bone name, [param bone_name], of the CCDIK joint at [param joint_idx]. When possible, this will also update the [code]bone_index[/code] of the CCDIK joint based on data provided by the linked skeleton.
- </description>
- </method>
- <method name="set_ccdik_joint_ccdik_axis">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="axis" type="int" />
- <description>
- Sets the joint axis of the CCDIK joint at [param joint_idx] to the passed-in joint axis, [param axis].
- </description>
- </method>
- <method name="set_ccdik_joint_constraint_angle_max">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="max_angle" type="float" />
- <description>
- Sets the maximum angle constraint for the joint at [param joint_idx]. [b]Note:[/b] This angle must be in radians!
- </description>
- </method>
- <method name="set_ccdik_joint_constraint_angle_min">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="min_angle" type="float" />
- <description>
- Sets the minimum angle constraint for the joint at [param joint_idx]. [b]Note:[/b] This angle must be in radians!
- </description>
- </method>
- <method name="set_ccdik_joint_constraint_invert">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="invert" type="bool" />
- <description>
- Sets whether the CCDIK joint at [param joint_idx] uses an inverted joint constraint.
- An inverted joint constraint only constraints the CCDIK joint to the angles [i]outside of[/i] the inputted minimum and maximum angles. For this reason, it is referred to as an inverted joint constraint, as it constraints the joint to the outside of the inputted values.
- </description>
- </method>
- <method name="set_ccdik_joint_enable_joint_constraint">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="enable" type="bool" />
- <description>
- Sets whether joint constraints are enabled for the CCDIK joint at [param joint_idx].
- </description>
- </method>
- </methods>
- <members>
- <member name="ccdik_data_chain_length" type="int" setter="set_ccdik_data_chain_length" getter="get_ccdik_data_chain_length" default="0">
- The number of CCDIK joints in the CCDIK modification.
- </member>
- <member name="high_quality_solve" type="bool" setter="set_use_high_quality_solve" getter="get_use_high_quality_solve" default="true">
- When true, the CCDIK algorithm will perform a higher quality solve that returns more natural results. A high quality solve requires more computation power to solve though, and therefore can be disabled to save performance.
- </member>
- <member name="target_nodepath" type="NodePath" setter="set_target_node" getter="get_target_node" default="NodePath(&quot;&quot;)">
- The NodePath to the node that is the target for the CCDIK modification. This node is what the CCDIK chain will attempt to rotate the bone chain to.
- </member>
- <member name="tip_nodepath" type="NodePath" setter="set_tip_node" getter="get_tip_node" default="NodePath(&quot;&quot;)">
- The end position of the CCDIK chain. Typically, this should be a child of a [BoneAttachment3D] node attached to the final bone in the CCDIK chain, where the child node is offset so it is at the end of the final bone.
- </member>
- </members>
-</class>
diff --git a/doc/classes/SkeletonModification3DFABRIK.xml b/doc/classes/SkeletonModification3DFABRIK.xml
deleted file mode 100644
index a2bec2b559..0000000000
--- a/doc/classes/SkeletonModification3DFABRIK.xml
+++ /dev/null
@@ -1,161 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<class name="SkeletonModification3DFABRIK" inherits="SkeletonModification3D" is_deprecated="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
- <brief_description>
- A modification that uses FABRIK to manipulate a series of bones to reach a target.
- </brief_description>
- <description>
- This [SkeletonModification3D] uses an algorithm called Forward And Backward Reaching Inverse Kinematics, or FABRIK, to rotate a bone chain so that it reaches a target.
- FABRIK works by knowing the positions and lengths of a series of bones, typically called a "bone chain". It first starts by running a forward pass, which places the final bone at the target's position. Then all other bones are moved towards the tip bone, so they stay at the defined bone length away. Then a backwards pass is performed, where the root/first bone in the FABRIK chain is placed back at the origin. then all other bones are moved so they stay at the defined bone length away. This positions the bone chain so that it reaches the target when possible, but all of the bones stay the correct length away from each other.
- Because of how FABRIK works, it often gives more natural results than those seen in [SkeletonModification3DCCDIK], though FABRIK currently does not support joint constraints.
- [b]Note:[/b] The FABRIK modifier has [code]fabrik_joints[/code], which are the data objects that hold the data for each joint in the FABRIK chain. This is different from a bone! FABRIK joints hold the data needed for each bone in the bone chain used by FABRIK.
- To help control how the FABRIK joints move, a magnet vector can be passed, which can nudge the bones in a certain direction prior to solving, giving a level of control over the final result.
- </description>
- <tutorials>
- </tutorials>
- <methods>
- <method name="fabrik_joint_auto_calculate_length">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Will attempt to automatically calculate the length of the bone assigned to the FABRIK joint at [param joint_idx].
- </description>
- </method>
- <method name="get_fabrik_joint_auto_calculate_length" qualifiers="const">
- <return type="bool" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns a boolean that indicates whether this modification will attempt to autocalculate the length of the bone assigned to the FABRIK joint at [param joint_idx].
- </description>
- </method>
- <method name="get_fabrik_joint_bone_index" qualifiers="const">
- <return type="int" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the bone index of the bone assigned to the FABRIK joint at [param joint_idx].
- </description>
- </method>
- <method name="get_fabrik_joint_bone_name" qualifiers="const">
- <return type="String" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the name of the bone that is assigned to the FABRIK joint at [param joint_idx].
- </description>
- </method>
- <method name="get_fabrik_joint_length" qualifiers="const">
- <return type="float" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the length of the FABRIK joint at [param joint_idx].
- </description>
- </method>
- <method name="get_fabrik_joint_magnet" qualifiers="const">
- <return type="Vector3" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the magnet vector of the FABRIK joint at [param joint_idx].
- </description>
- </method>
- <method name="get_fabrik_joint_tip_node" qualifiers="const">
- <return type="NodePath" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the [Node3D]-based node placed at the tip of the FABRIK joint at [param joint_idx], if one has been set.
- </description>
- </method>
- <method name="get_fabrik_joint_use_target_basis" qualifiers="const">
- <return type="bool" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns a boolean indicating whether the FABRIK joint uses the target's [Basis] for its rotation.
- [b]Note:[/b] This option is only available for the final bone in the FABRIK chain, with this setting being ignored for all other bones.
- </description>
- </method>
- <method name="get_fabrik_joint_use_tip_node" qualifiers="const">
- <return type="bool" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Sets the [Node3D]-based node that will be used as the tip of the FABRIK joint at [param joint_idx].
- </description>
- </method>
- <method name="set_fabrik_joint_auto_calculate_length">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="auto_calculate_length" type="bool" />
- <description>
- When [code]true[/code], this modification will attempt to automatically calculate the length of the bone for the FABRIK joint at [param joint_idx]. It does this by either using the tip node assigned, if there is one assigned, or the distance the of the bone's children, if the bone has any. If the bone has no children and no tip node is assigned, then the modification [b]cannot[/b] autocalculate the joint's length. In this case, the joint length should be entered manually or a tip node assigned.
- </description>
- </method>
- <method name="set_fabrik_joint_bone_index">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="bone_index" type="int" />
- <description>
- Sets the bone index, [param bone_index], of the FABRIK joint at [param joint_idx]. When possible, this will also update the [code]bone_name[/code] of the FABRIK joint based on data provided by the [Skeleton3D].
- </description>
- </method>
- <method name="set_fabrik_joint_bone_name">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="bone_name" type="String" />
- <description>
- Sets the bone name, [param bone_name], of the FABRIK joint at [param joint_idx]. When possible, this will also update the [code]bone_index[/code] of the FABRIK joint based on data provided by the [Skeleton3D].
- </description>
- </method>
- <method name="set_fabrik_joint_length">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="length" type="float" />
- <description>
- Sets the joint length, [param length], of the FABRIK joint at [param joint_idx].
- </description>
- </method>
- <method name="set_fabrik_joint_magnet">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="magnet_position" type="Vector3" />
- <description>
- Sets the magenet position to [param magnet_position] for the joint at [param joint_idx]. The magnet position is used to nudge the joint in that direction when solving, which gives some control over how that joint will bend when being solved.
- </description>
- </method>
- <method name="set_fabrik_joint_tip_node">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="tip_node" type="NodePath" />
- <description>
- Sets the nodepath of the FARIK joint at [param joint_idx] to [param tip_node]. The tip node is used to calculate the length of the FABRIK joint when set to automatically calculate joint length.
- [b]Note:[/b] The tip node should generally be a child node of a [BoneAttachment3D] node attached to the bone that this FABRIK joint operates on, with the child node being offset so it is at the end of the bone.
- </description>
- </method>
- <method name="set_fabrik_joint_use_target_basis">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="use_target_basis" type="bool" />
- <description>
- Sets whether the FABRIK joint at [param joint_idx] uses the target's [Basis] for its rotation.
- [b]Note:[/b] This option is only available for the final bone in the FABRIK chain, with this setting being ignored for all other bones.
- </description>
- </method>
- <method name="set_fabrik_joint_use_tip_node">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="use_tip_node" type="bool" />
- <description>
- Sets whether the tip node should be used when autocalculating the joint length for the FABRIK joint at [param joint_idx]. This will only work if there is a node assigned to the tip nodepath for this joint.
- </description>
- </method>
- </methods>
- <members>
- <member name="chain_max_iterations" type="int" setter="set_chain_max_iterations" getter="get_chain_max_iterations" default="10">
- The number of times FABRIK will try to solve each time the [code]execute[/code] function is called. Setting this value to a lower number will be result in better performance, but this can also result in harsher movements and slower solves.
- </member>
- <member name="chain_tolerance" type="float" setter="set_chain_tolerance" getter="get_chain_tolerance" default="0.01">
- The minimum distance the target has to be from the tip of the final bone in the bone chain. Setting this value to a higher number allows for greater performance, but less accurate solves.
- </member>
- <member name="fabrik_data_chain_length" type="int" setter="set_fabrik_data_chain_length" getter="get_fabrik_data_chain_length" default="0">
- The amount of FABRIK joints in the FABRIK modification.
- </member>
- <member name="target_nodepath" type="NodePath" setter="set_target_node" getter="get_target_node" default="NodePath(&quot;&quot;)">
- The NodePath to the node that is the target for the FABRIK modification. This node is what the FABRIK chain will attempt to rotate the bone chain to.
- </member>
- </members>
-</class>
diff --git a/doc/classes/SkeletonModification3DJiggle.xml b/doc/classes/SkeletonModification3DJiggle.xml
deleted file mode 100644
index 304f08bb20..0000000000
--- a/doc/classes/SkeletonModification3DJiggle.xml
+++ /dev/null
@@ -1,199 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<class name="SkeletonModification3DJiggle" inherits="SkeletonModification3D" is_deprecated="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
- <brief_description>
- A modification that jiggles bones as they move towards a target.
- </brief_description>
- <description>
- This modification moves a series of bones, typically called a bone chain, towards a target. What makes this modification special is that it calculates the velocity and acceleration for each bone in the bone chain, and runs a very light physics-like calculation using the inputted values. This allows the bones to overshoot the target and "jiggle" around. It can be configured to act more like a spring, or sway around like cloth might.
- This modification is useful for adding additional motion to things like hair, the edges of clothing, and more. It has several settings to that allow control over how the joint moves when the target moves.
- [b]Note:[/b] The Jiggle modifier has [code]jiggle_joints[/code], which are the data objects that hold the data for each joint in the Jiggle chain. This is different from a bone! Jiggle joints hold the data needed for each bone in the bone chain used by the Jiggle modification.
- </description>
- <tutorials>
- </tutorials>
- <methods>
- <method name="get_collision_mask" qualifiers="const">
- <return type="int" />
- <description>
- Returns the collision mask that the Jiggle modifier will take into account when performing physics calculations.
- </description>
- </method>
- <method name="get_jiggle_joint_bone_index" qualifiers="const">
- <return type="int" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the bone index of the bone assigned to the Jiggle joint at [param joint_idx].
- </description>
- </method>
- <method name="get_jiggle_joint_bone_name" qualifiers="const">
- <return type="String" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the name of the bone that is assigned to the Jiggle joint at [param joint_idx].
- </description>
- </method>
- <method name="get_jiggle_joint_damping" qualifiers="const">
- <return type="float" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the amount of dampening of the Jiggle joint at [param joint_idx].
- </description>
- </method>
- <method name="get_jiggle_joint_gravity" qualifiers="const">
- <return type="Vector3" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns a [Vector3] representign the amount of gravity the Jiggle joint at [param joint_idx] is influenced by.
- </description>
- </method>
- <method name="get_jiggle_joint_mass" qualifiers="const">
- <return type="float" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the amount of mass of the Jiggle joint at [param joint_idx].
- </description>
- </method>
- <method name="get_jiggle_joint_override" qualifiers="const">
- <return type="bool" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns a boolean that indicates whether the joint at [param joint_idx] is overriding the default jiggle joint data defined in the modification.
- </description>
- </method>
- <method name="get_jiggle_joint_roll" qualifiers="const">
- <return type="float" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the amount of roll/twist applied to the bone that the Jiggle joint is applied to.
- </description>
- </method>
- <method name="get_jiggle_joint_stiffness" qualifiers="const">
- <return type="float" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns the stiffness of the Jiggle joint at [param joint_idx].
- </description>
- </method>
- <method name="get_jiggle_joint_use_gravity" qualifiers="const">
- <return type="bool" />
- <param index="0" name="joint_idx" type="int" />
- <description>
- Returns a boolean that indicates whether the joint at [param joint_idx] is using gravity or not.
- </description>
- </method>
- <method name="get_use_colliders" qualifiers="const">
- <return type="bool" />
- <description>
- Returns whether the Jiggle modifier is taking physics colliders into account when solving.
- </description>
- </method>
- <method name="set_collision_mask">
- <return type="void" />
- <param index="0" name="mask" type="int" />
- <description>
- Sets the collision mask that the Jiggle modifier takes into account when performing physics calculations.
- </description>
- </method>
- <method name="set_jiggle_joint_bone_index">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="bone_idx" type="int" />
- <description>
- Sets the bone index, [param bone_idx], of the Jiggle joint at [param joint_idx]. When possible, this will also update the [code]bone_name[/code] of the Jiggle joint based on data provided by the [Skeleton3D].
- </description>
- </method>
- <method name="set_jiggle_joint_bone_name">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="name" type="String" />
- <description>
- Sets the bone name, [param name], of the Jiggle joint at [param joint_idx]. When possible, this will also update the [code]bone_index[/code] of the Jiggle joint based on data provided by the [Skeleton3D].
- </description>
- </method>
- <method name="set_jiggle_joint_damping">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="damping" type="float" />
- <description>
- Sets the amount of dampening of the Jiggle joint at [param joint_idx].
- </description>
- </method>
- <method name="set_jiggle_joint_gravity">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="gravity" type="Vector3" />
- <description>
- Sets the gravity vector of the Jiggle joint at [param joint_idx].
- </description>
- </method>
- <method name="set_jiggle_joint_mass">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="mass" type="float" />
- <description>
- Sets the of mass of the Jiggle joint at [param joint_idx].
- </description>
- </method>
- <method name="set_jiggle_joint_override">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="override" type="bool" />
- <description>
- Sets whether the Jiggle joint at [param joint_idx] should override the default Jiggle joint settings. Setting this to true will make the joint use its own settings rather than the default ones attached to the modification.
- </description>
- </method>
- <method name="set_jiggle_joint_roll">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="roll" type="float" />
- <description>
- Sets the amount of roll/twist on the bone the Jiggle joint is attached to.
- </description>
- </method>
- <method name="set_jiggle_joint_stiffness">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="stiffness" type="float" />
- <description>
- Sets the of stiffness of the Jiggle joint at [param joint_idx].
- </description>
- </method>
- <method name="set_jiggle_joint_use_gravity">
- <return type="void" />
- <param index="0" name="joint_idx" type="int" />
- <param index="1" name="use_gravity" type="bool" />
- <description>
- Sets whether the Jiggle joint at [param joint_idx] should use gravity.
- </description>
- </method>
- <method name="set_use_colliders">
- <return type="void" />
- <param index="0" name="use_colliders" type="bool" />
- <description>
- When [code]true[/code], the Jiggle modifier will use raycasting to prevent the Jiggle joints from rotating themselves into collision objects when solving.
- </description>
- </method>
- </methods>
- <members>
- <member name="damping" type="float" setter="set_damping" getter="get_damping" default="0.75">
- The default amount of dampening applied to the Jiggle joints, if they are not overridden. Higher values lead to more of the calculated velocity being applied.
- </member>
- <member name="gravity" type="Vector3" setter="set_gravity" getter="get_gravity" default="Vector3(0, -6, 0)">
- The default amount of gravity applied to the Jiggle joints, if they are not overridden.
- </member>
- <member name="jiggle_data_chain_length" type="int" setter="set_jiggle_data_chain_length" getter="get_jiggle_data_chain_length" default="0">
- The amount of Jiggle joints in the Jiggle modification.
- </member>
- <member name="mass" type="float" setter="set_mass" getter="get_mass" default="0.75">
- The default amount of mass assigned to the Jiggle joints, if they are not overridden. Higher values lead to faster movements and more overshooting.
- </member>
- <member name="stiffness" type="float" setter="set_stiffness" getter="get_stiffness" default="3.0">
- The default amount of stiffness assigned to the Jiggle joints, if they are not overridden. Higher values act more like springs, quickly moving into the correct position.
- </member>
- <member name="target_nodepath" type="NodePath" setter="set_target_node" getter="get_target_node" default="NodePath(&quot;&quot;)">
- The NodePath to the node that is the target for the Jiggle modification. This node is what the Jiggle chain will attempt to rotate the bone chain to.
- </member>
- <member name="use_gravity" type="bool" setter="set_use_gravity" getter="get_use_gravity" default="false">
- Whether the gravity vector, [member gravity], should be applied to the Jiggle joints, assuming they are not overriding the default settings.
- </member>
- </members>
-</class>
diff --git a/doc/classes/SkeletonModification3DLookAt.xml b/doc/classes/SkeletonModification3DLookAt.xml
deleted file mode 100644
index aeed953ca9..0000000000
--- a/doc/classes/SkeletonModification3DLookAt.xml
+++ /dev/null
@@ -1,64 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<class name="SkeletonModification3DLookAt" inherits="SkeletonModification3D" is_deprecated="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
- <brief_description>
- A modification that rotates a bone to look at a target.
- </brief_description>
- <description>
- This [SkeletonModification3D] rotates a bone to look a target. This is extremely helpful for moving character's heads to look at the player, rotating a turret to look at a target, or any other case where you want to make a bone rotate towards something quickly and easily.
- </description>
- <tutorials>
- </tutorials>
- <methods>
- <method name="get_additional_rotation" qualifiers="const">
- <return type="Vector3" />
- <description>
- Returns the amount of extra rotation that is applied to the bone after the LookAt modification executes.
- </description>
- </method>
- <method name="get_lock_rotation_plane" qualifiers="const">
- <return type="int" />
- <description>
- Returns the plane that the LookAt modification is limiting rotation to.
- </description>
- </method>
- <method name="get_lock_rotation_to_plane" qualifiers="const">
- <return type="bool" />
- <description>
- Returns whether the LookAt modification is limiting rotation to a single plane in 3D space.
- </description>
- </method>
- <method name="set_additional_rotation">
- <return type="void" />
- <param index="0" name="additional_rotation" type="Vector3" />
- <description>
- Sets the amount of extra rotation to be applied after the LookAt modification executes. This allows you to adjust the finished result.
- </description>
- </method>
- <method name="set_lock_rotation_plane">
- <return type="void" />
- <param index="0" name="plane" type="int" />
- <description>
- </description>
- </method>
- <method name="set_lock_rotation_to_plane">
- <return type="void" />
- <param index="0" name="lock_to_plane" type="bool" />
- <description>
- When [code]true[/code], the LookAt modification will limit its rotation to a single plane in 3D space. The plane used can be configured using the [code]set_lock_rotation_plane[/code] function.
- </description>
- </method>
- </methods>
- <members>
- <member name="bone_index" type="int" setter="set_bone_index" getter="get_bone_index" default="-2">
- The bone index of the bone that should be operated on by this modification.
- When possible, this will also update the [member bone_name] based on data provided by the [Skeleton3D].
- </member>
- <member name="bone_name" type="String" setter="set_bone_name" getter="get_bone_name" default="&quot;&quot;">
- The name of the bone that should be operated on by this modification.
- When possible, this will also update the [member bone_index] based on data provided by the [Skeleton3D].
- </member>
- <member name="target_nodepath" type="NodePath" setter="set_target_node" getter="get_target_node" default="NodePath(&quot;&quot;)">
- The NodePath to the node that is the target for the modification.
- </member>
- </members>
-</class>
diff --git a/doc/classes/SkeletonModification3DStackHolder.xml b/doc/classes/SkeletonModification3DStackHolder.xml
deleted file mode 100644
index 9448e2c783..0000000000
--- a/doc/classes/SkeletonModification3DStackHolder.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<class name="SkeletonModification3DStackHolder" inherits="SkeletonModification3D" is_deprecated="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
- <brief_description>
- A modification that holds and executes a [SkeletonModificationStack3D].
- </brief_description>
- <description>
- This [SkeletonModification3D] holds a reference to a [SkeletonModificationStack3D], allowing you to use multiple modification stacks on a single [Skeleton3D].
- [b]Note:[/b] The modifications in the held [SkeletonModificationStack3D] will only be executed if their execution mode matches the execution mode of the SkeletonModification3DStackHolder.
- </description>
- <tutorials>
- </tutorials>
- <methods>
- <method name="get_held_modification_stack" qualifiers="const">
- <return type="SkeletonModificationStack3D" />
- <description>
- Returns the [SkeletonModificationStack3D] that this modification is holding.
- </description>
- </method>
- <method name="set_held_modification_stack">
- <return type="void" />
- <param index="0" name="held_modification_stack" type="SkeletonModificationStack3D" />
- <description>
- Sets the [SkeletonModificationStack3D] that this modification is holding. This modification stack will then be executed when this modification is executed.
- </description>
- </method>
- </methods>
-</class>
diff --git a/doc/classes/SkeletonModification3DTwoBoneIK.xml b/doc/classes/SkeletonModification3DTwoBoneIK.xml
deleted file mode 100644
index 0e7ffd5c80..0000000000
--- a/doc/classes/SkeletonModification3DTwoBoneIK.xml
+++ /dev/null
@@ -1,191 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<class name="SkeletonModification3DTwoBoneIK" inherits="SkeletonModification3D" is_deprecated="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
- <brief_description>
- A modification that moves two bones to reach the target.
- </brief_description>
- <description>
- This [SkeletonModification3D] uses an algorithm typically called TwoBoneIK. This algorithm works by leveraging the law of cosigns and the lengths of the bones to figure out what rotation the bones currently have, and what rotation they need to make a complete triangle, where the first bone, the second bone, and the target form the three vertices of the triangle. Because the algorithm works by making a triangle, it can only operate on two bones.
- TwoBoneIK is great for arms, legs, and really any joints that can be represented by just two bones that bend to reach a target. This solver is more lightweight than [SkeletonModification3DFABRIK], but gives similar, natural looking results.
- A [Node3D]-based node can be used to define the pole, or bend direction, allowing control over which direction the joint takes when bending to reach the target when the target is within reach.
- </description>
- <tutorials>
- </tutorials>
- <methods>
- <method name="get_auto_calculate_joint_length" qualifiers="const">
- <return type="bool" />
- <description>
- Returns whether the TwoBoneIK modification will attempt to autocalculate the lengths of the two bones.
- </description>
- </method>
- <method name="get_joint_one_bone_idx" qualifiers="const">
- <return type="int" />
- <description>
- Returns the bone index of the first bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="get_joint_one_bone_name" qualifiers="const">
- <return type="String" />
- <description>
- Returns the name of the first bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="get_joint_one_length" qualifiers="const">
- <return type="float" />
- <description>
- Returns the length of the first bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="get_joint_one_roll" qualifiers="const">
- <return type="float" />
- <description>
- Returns the amount of roll/twist applied to the first bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="get_joint_two_bone_idx" qualifiers="const">
- <return type="int" />
- <description>
- Returns the bone index of the second bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="get_joint_two_bone_name" qualifiers="const">
- <return type="String" />
- <description>
- Returns the name of the second bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="get_joint_two_length" qualifiers="const">
- <return type="float" />
- <description>
- Returns the length of the second bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="get_joint_two_roll" qualifiers="const">
- <return type="float" />
- <description>
- Returns the amount of roll/twist applied to the second bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="get_pole_node" qualifiers="const">
- <return type="NodePath" />
- <description>
- Returns the node that is being used as the pole node for the TwoBoneIK modification, if a pole node has been set.
- </description>
- </method>
- <method name="get_tip_node" qualifiers="const">
- <return type="NodePath" />
- <description>
- Returns the node that is being used to calculate the tip position of the second bone in the TwoBoneIK modification, if a tip node has been set.
- </description>
- </method>
- <method name="get_use_pole_node" qualifiers="const">
- <return type="bool" />
- <description>
- Returns whether the TwoBoneIK modification will attempt to use the pole node to figure out which direction to bend, if a pole node has been set.
- </description>
- </method>
- <method name="get_use_tip_node" qualifiers="const">
- <return type="bool" />
- <description>
- Returns whether the TwoBoneIK modification will attempt to use the tip node to figure out the length and position of the tip of the second bone.
- </description>
- </method>
- <method name="set_auto_calculate_joint_length">
- <return type="void" />
- <param index="0" name="auto_calculate_joint_length" type="bool" />
- <description>
- If true, the TwoBoneIK modification will attempt to autocalculate the lengths of the bones being used. The first bone will be calculated by using the distance from the origin of the first bone to the origin of the second bone.
- The second bone will be calculated either using the tip node if that setting is enabled, or by using the distances of the second bone's children. If the tip node is not enabled and the bone has no children, then the length cannot be autocalculated. In this case, the length will either have to be manually inputted or a tip node used to calculate the length.
- </description>
- </method>
- <method name="set_joint_one_bone_idx">
- <return type="void" />
- <param index="0" name="bone_idx" type="int" />
- <description>
- Sets the bone index, [param bone_idx], of the first bone. When possible, this will also update the [code]bone_name[/code] of the first bone based on data provided by the [Skeleton3D].
- </description>
- </method>
- <method name="set_joint_one_bone_name">
- <return type="void" />
- <param index="0" name="bone_name" type="String" />
- <description>
- Sets the bone name, [param bone_name], of the first bone. When possible, this will also update the [code]bone_index[/code] of the first bone based on data provided by the [Skeleton3D].
- </description>
- </method>
- <method name="set_joint_one_length">
- <return type="void" />
- <param index="0" name="bone_length" type="float" />
- <description>
- Sets the length of the first bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="set_joint_one_roll">
- <return type="void" />
- <param index="0" name="roll" type="float" />
- <description>
- Sets the amount of roll/twist applied to the first bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="set_joint_two_bone_idx">
- <return type="void" />
- <param index="0" name="bone_idx" type="int" />
- <description>
- Sets the bone index, [param bone_idx], of the second bone. When possible, this will also update the [code]bone_name[/code] of the second bone based on data provided by the [Skeleton3D].
- </description>
- </method>
- <method name="set_joint_two_bone_name">
- <return type="void" />
- <param index="0" name="bone_name" type="String" />
- <description>
- Sets the bone name, [param bone_name], of the second bone. When possible, this will also update the [code]bone_index[/code] of the second bone based on data provided by the [Skeleton3D].
- </description>
- </method>
- <method name="set_joint_two_length">
- <return type="void" />
- <param index="0" name="bone_length" type="float" />
- <description>
- Sets the length of the second bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="set_joint_two_roll">
- <return type="void" />
- <param index="0" name="roll" type="float" />
- <description>
- Sets the amount of roll/twist applied to the second bone in the TwoBoneIK modification.
- </description>
- </method>
- <method name="set_pole_node">
- <return type="void" />
- <param index="0" name="pole_nodepath" type="NodePath" />
- <description>
- Sets the node to be used as the for the pole of the TwoBoneIK. When a node is set and the modification is set to use the pole node, the TwoBoneIK modification will bend the nodes in the direction towards this node when the bones need to bend.
- </description>
- </method>
- <method name="set_tip_node">
- <return type="void" />
- <param index="0" name="tip_nodepath" type="NodePath" />
- <description>
- Sets the node to be used as the tip for the second bone. This is used to calculate the length and position of the end of the second bone in the TwoBoneIK modification.
- [b]Note:[/b] The tip node should generally be a child node of a [BoneAttachment3D] node attached to the second bone, with the child node being offset so it is at the end of the bone.
- </description>
- </method>
- <method name="set_use_pole_node">
- <return type="void" />
- <param index="0" name="use_pole_node" type="bool" />
- <description>
- When [code]true[/code], the TwoBoneIK modification will bend the bones towards the pole node, if one has been set. This gives control over the direction the TwoBoneIK solver will bend, which is helpful for joints like elbows that only bend in certain directions.
- </description>
- </method>
- <method name="set_use_tip_node">
- <return type="void" />
- <param index="0" name="use_tip_node" type="bool" />
- <description>
- When [code]true[/code], the TwoBoneIK modification will use the tip node to calculate the distance and position of the end/tip of the second bone. This is the most stable solution for knowing the tip position and length of the second bone.
- </description>
- </method>
- </methods>
- <members>
- <member name="target_nodepath" type="NodePath" setter="set_target_node" getter="get_target_node" default="NodePath(&quot;&quot;)">
- The NodePath to the node that is the target for the TwoBoneIK modification. This node is what the modification will attempt to rotate the bones to reach.
- </member>
- </members>
-</class>
diff --git a/doc/classes/SkeletonModificationStack3D.xml b/doc/classes/SkeletonModificationStack3D.xml
deleted file mode 100644
index 9eaeeefd8e..0000000000
--- a/doc/classes/SkeletonModificationStack3D.xml
+++ /dev/null
@@ -1,88 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<class name="SkeletonModificationStack3D" inherits="Resource" is_deprecated="true" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
- <brief_description>
- A resource that holds a stack of [SkeletonModification3D]s.
- </brief_description>
- <description>
- This resource is used by the Skeleton and holds a stack of [SkeletonModification3D]s. The SkeletonModificationStack3D controls the order of the modifications, which controls how they are applied. Modification order is especially important for full-body IK setups, as you need to execute the modifications in the correct order to get the desired results. For example, you want to execute a modification on the spine [i]before[/i] the arms on a humanoid skeleton.
- Additionally, the SkeletonModificationStack3D also controls how strongly the modifications are applied to the [Skeleton3D] node.
- </description>
- <tutorials>
- </tutorials>
- <methods>
- <method name="add_modification">
- <return type="void" />
- <param index="0" name="modification" type="SkeletonModification3D" />
- <description>
- Adds the passed-in [SkeletonModification3D] to the stack.
- </description>
- </method>
- <method name="delete_modification">
- <return type="void" />
- <param index="0" name="mod_idx" type="int" />
- <description>
- Deletes the [SkeletonModification3D] at the index position [param mod_idx], if it exists.
- </description>
- </method>
- <method name="enable_all_modifications">
- <return type="void" />
- <param index="0" name="enabled" type="bool" />
- <description>
- Enables all [SkeletonModification3D]s in the stack.
- </description>
- </method>
- <method name="execute">
- <return type="void" />
- <param index="0" name="delta" type="float" />
- <param index="1" name="execution_mode" type="int" />
- <description>
- Executes all of the [SkeletonModification3D]s in the stack that use the same execution mode as the passed-in [param execution_mode], starting from index [code]0[/code] to [member modification_count].
- [b]Note:[/b] The order of the modifications can matter depending on the modifications. For example, modifications on a spine should operate before modifications on the arms in order to get proper results.
- </description>
- </method>
- <method name="get_is_setup" qualifiers="const">
- <return type="bool" />
- <description>
- Returns a boolean that indicates whether the modification stack is setup and can execute.
- </description>
- </method>
- <method name="get_modification" qualifiers="const">
- <return type="SkeletonModification3D" />
- <param index="0" name="mod_idx" type="int" />
- <description>
- Returns the [SkeletonModification3D] at the passed-in index, [param mod_idx].
- </description>
- </method>
- <method name="get_skeleton" qualifiers="const">
- <return type="Skeleton3D" />
- <description>
- Returns the [Skeleton3D] node that the SkeletonModificationStack3D is bound to.
- </description>
- </method>
- <method name="set_modification">
- <return type="void" />
- <param index="0" name="mod_idx" type="int" />
- <param index="1" name="modification" type="SkeletonModification3D" />
- <description>
- Sets the modification at [param mod_idx] to the passed-in modification, [param modification].
- </description>
- </method>
- <method name="setup">
- <return type="void" />
- <description>
- Sets up the modification stack so it can execute. This function should be called by [Skeleton3D] and shouldn't be called unless you know what you are doing.
- </description>
- </method>
- </methods>
- <members>
- <member name="enabled" type="bool" setter="set_enabled" getter="get_enabled" default="false">
- When true, the modification's in the stack will be called. This is handled automatically through the [Skeleton3D] node.
- </member>
- <member name="modification_count" type="int" setter="set_modification_count" getter="get_modification_count" default="0">
- The number of modifications in the stack.
- </member>
- <member name="strength" type="float" setter="set_strength" getter="get_strength" default="1.0">
- The interpolation strength of the modifications in stack. A value of [code]0[/code] will make it where the modifications are not applied, a strength of [code]0.5[/code] will be half applied, and a strength of [code]1[/code] will allow the modifications to be fully applied and override the skeleton bone poses.
- </member>
- </members>
-</class>
diff --git a/doc/classes/SkeletonProfile.xml b/doc/classes/SkeletonProfile.xml
index 57bdd52d9e..6fb311bcee 100644
--- a/doc/classes/SkeletonProfile.xml
+++ b/doc/classes/SkeletonProfile.xml
@@ -5,6 +5,7 @@
</brief_description>
<description>
This resource is used in [EditorScenePostImport]. Some parameters are referring to bones in [Skeleton3D], [Skin], [Animation], and some other nodes are rewritten based on the parameters of [SkeletonProfile].
+ [b]Note:[/b] These parameters need to be set only when creating a custom profile. In [SkeletonProfileHumanoid], they are defined internally as read-only values.
</description>
<tutorials>
<link title="Retargeting 3D Skeletons">$DOCS_URL/tutorials/assets_pipeline/retargeting_3d_skeletons.html</link>
@@ -160,16 +161,18 @@
</methods>
<members>
<member name="bone_size" type="int" setter="set_bone_size" getter="get_bone_size" default="0">
+ The amount of bones in retargeting section's [BoneMap] editor. For example, [SkeletonProfileHumanoid] has 56 bones.
+ The size of elements in [BoneMap] updates when changing this property in it's assigned [SkeletonProfile].
</member>
<member name="group_size" type="int" setter="set_group_size" getter="get_group_size" default="0">
+ The amount of groups of bones in retargeting section's [BoneMap] editor. For example, [SkeletonProfileHumanoid] has 4 groups.
+ This property exists to separate the bone list into several sections in the editor.
</member>
<member name="root_bone" type="StringName" setter="set_root_bone" getter="get_root_bone" default="&amp;&quot;&quot;">
- A name of bone that will be used as the root bone in [AnimationTree].
- [b]Note:[/b] In most cases, it is the bone of the parent of the hips that exists at the world origin in the humanoid model.
+ A bone name that will be used as the root bone in [AnimationTree]. This should be the bone of the parent of hips that exists at the world origin.
</member>
<member name="scale_base_bone" type="StringName" setter="set_scale_base_bone" getter="get_scale_base_bone" default="&amp;&quot;&quot;">
- A name of bone which height will be used as the coefficient for normalization.
- [b]Note:[/b] In most cases, it is hips in the humanoid model.
+ A bone name which will use model's height as the coefficient for normalization. For example, [SkeletonProfileHumanoid] defines it as [code]Hips[/code].
</member>
</members>
<signals>
diff --git a/doc/classes/SkeletonProfileHumanoid.xml b/doc/classes/SkeletonProfileHumanoid.xml
index 0dbd66d8d6..7445272ccc 100644
--- a/doc/classes/SkeletonProfileHumanoid.xml
+++ b/doc/classes/SkeletonProfileHumanoid.xml
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="SkeletonProfileHumanoid" inherits="SkeletonProfile" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A humanoid [SkeletonProfile] preset.
</brief_description>
<description>
A [SkeletonProfile] as a preset that is optimized for the human form. This exists for standardization, so all parameters are read-only.
diff --git a/doc/classes/SpinBox.xml b/doc/classes/SpinBox.xml
index 7d63747bd2..e2db2166ed 100644
--- a/doc/classes/SpinBox.xml
+++ b/doc/classes/SpinBox.xml
@@ -60,7 +60,7 @@
<member name="select_all_on_focus" type="bool" setter="set_select_all_on_focus" getter="is_select_all_on_focus" default="false">
If [code]true[/code], the [SpinBox] will select the whole text when the [LineEdit] gains focus. Clicking the up and down arrows won't trigger this behavior.
</member>
- <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" default="1" />
+ <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" enum="Control.SizeFlags" default="1" />
<member name="step" type="float" setter="set_step" getter="get_step" overrides="Range" default="1.0" />
<member name="suffix" type="String" setter="set_suffix" getter="get_suffix" default="&quot;&quot;">
Adds the specified [code]suffix[/code] string after the numerical value of the [SpinBox].
diff --git a/doc/classes/Sprite2D.xml b/doc/classes/Sprite2D.xml
index 235fef0bdd..033dbf51f3 100644
--- a/doc/classes/Sprite2D.xml
+++ b/doc/classes/Sprite2D.xml
@@ -23,11 +23,11 @@
print("A click!")
[/gdscript]
[csharp]
- public override void _Input(InputEvent inputEvent)
+ public override void _Input(InputEvent @event)
{
- if (inputEvent is InputEventMouseButton inputEventMouse)
+ if (@event is InputEventMouseButton inputEventMouse)
{
- if (inputEventMouse.Pressed &amp;&amp; inputEventMouse.ButtonIndex == (int)ButtonList.Left)
+ if (inputEventMouse.Pressed &amp;&amp; inputEventMouse.ButtonIndex == MouseButton.Left)
{
if (GetRect().HasPoint(ToLocal(inputEventMouse.Position)))
{
diff --git a/doc/classes/SpriteBase3D.xml b/doc/classes/SpriteBase3D.xml
index 5fa984e7a0..e1f3a52a1d 100644
--- a/doc/classes/SpriteBase3D.xml
+++ b/doc/classes/SpriteBase3D.xml
@@ -38,9 +38,21 @@
</method>
</methods>
<members>
+ <member name="alpha_antialiasing_edge" type="float" setter="set_alpha_antialiasing_edge" getter="get_alpha_antialiasing_edge" default="0.0">
+ Threshold at which antialiasing will be applied on the alpha channel.
+ </member>
+ <member name="alpha_antialiasing_mode" type="int" setter="set_alpha_antialiasing" getter="get_alpha_antialiasing" enum="BaseMaterial3D.AlphaAntiAliasing" default="0">
+ The type of alpha antialiasing to apply. See [enum BaseMaterial3D.AlphaAntiAliasing].
+ </member>
<member name="alpha_cut" type="int" setter="set_alpha_cut_mode" getter="get_alpha_cut_mode" enum="SpriteBase3D.AlphaCutMode" default="0">
The alpha cutting mode to use for the sprite. See [enum AlphaCutMode] for possible values.
</member>
+ <member name="alpha_hash_scale" type="float" setter="set_alpha_hash_scale" getter="get_alpha_hash_scale" default="1.0">
+ The hashing scale for Alpha Hash. Recommended values between [code]0[/code] and [code]2[/code].
+ </member>
+ <member name="alpha_scissor_threshold" type="float" setter="set_alpha_scissor_threshold" getter="get_alpha_scissor_threshold" default="0.5">
+ Threshold at which the alpha scissor will discard values.
+ </member>
<member name="axis" type="int" setter="set_axis" getter="get_axis" enum="Vector3.Axis" default="2">
The direction in which the front of the texture faces.
</member>
@@ -118,5 +130,8 @@
<constant name="ALPHA_CUT_OPAQUE_PREPASS" value="2" enum="AlphaCutMode">
This mode draws fully opaque pixels in the depth prepass. This is slower than [constant ALPHA_CUT_DISABLED] or [constant ALPHA_CUT_DISCARD], but it allows displaying translucent areas and smooth edges while using proper sorting.
</constant>
+ <constant name="ALPHA_CUT_HASH" value="3" enum="AlphaCutMode">
+ This mode draws cuts off all values below a spatially-deterministic threshold, the rest will remain opaque.
+ </constant>
</constants>
</class>
diff --git a/doc/classes/SpriteFrames.xml b/doc/classes/SpriteFrames.xml
index e9721495dd..195f3598d5 100644
--- a/doc/classes/SpriteFrames.xml
+++ b/doc/classes/SpriteFrames.xml
@@ -5,7 +5,6 @@
</brief_description>
<description>
Sprite frame library for an [AnimatedSprite2D] or [AnimatedSprite3D] node. Contains frames and animation data for playback.
- [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>
</tutorials>
@@ -14,29 +13,30 @@
<return type="void" />
<param index="0" name="anim" type="StringName" />
<description>
- Adds a new animation to the library.
+ Adds a new [param anim] animation to the library.
</description>
</method>
<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.
+ Adds a frame to the [param anim] animation. If [param at_position] is [code]-1[/code], the frame will be added to the end of the animation.
</description>
</method>
<method name="clear">
<return type="void" />
<param index="0" name="anim" type="StringName" />
<description>
- Removes all frames from the given animation.
+ Removes all frames from the [param anim] animation.
</description>
</method>
<method name="clear_all">
<return type="void" />
<description>
- Removes all animations. A "default" animation will be created.
+ Removes all animations. An empty [code]default[/code] animation will be created.
</description>
</method>
<method name="get_animation_loop" qualifiers="const">
@@ -56,36 +56,48 @@
<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">
<return type="bool" />
<param index="0" name="anim" type="StringName" />
<description>
- If [code]true[/code], the named animation exists.
+ Returns [code]true[/code] if the [param anim] animation exists.
</description>
</method>
<method name="remove_animation">
<return type="void" />
<param index="0" name="anim" type="StringName" />
<description>
- Removes the given animation.
+ Removes the [param anim] animation.
</description>
</method>
<method name="remove_frame">
@@ -93,7 +105,7 @@
<param index="0" name="anim" type="StringName" />
<param index="1" name="idx" type="int" />
<description>
- Removes the animation's selected frame.
+ Removes the [param anim] animation's frame [param idx].
</description>
</method>
<method name="rename_animation">
@@ -101,7 +113,7 @@
<param index="0" name="anim" type="StringName" />
<param index="1" name="newname" type="StringName" />
<description>
- Changes the animation's name to [param newname].
+ Changes the [param anim] animation's name to [param newname].
</description>
</method>
<method name="set_animation_loop">
@@ -109,24 +121,25 @@
<param index="0" name="anim" type="StringName" />
<param index="1" name="loop" type="bool" />
<description>
- If [code]true[/code], the animation will loop.
+ If [param loop] is [code]true[/code], the [param anim] animation will loop when it reaches the end, or the start if it is played in reverse.
</description>
</method>
<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 [param texture] and the [param duration] of the frame [param idx] in the [param anim] animation.
</description>
</method>
</methods>
diff --git a/doc/classes/StaticBody3D.xml b/doc/classes/StaticBody3D.xml
index 0beaa6bb52..7bebd46004 100644
--- a/doc/classes/StaticBody3D.xml
+++ b/doc/classes/StaticBody3D.xml
@@ -7,8 +7,9 @@
Static body for 3D physics.
A static body is a simple body that doesn't move under physics simulation, i.e. it can't be moved by external forces or contacts but its transformation can still be updated manually by the user. It is ideal for implementing objects in the environment, such as walls or platforms. In contrast to [RigidBody3D], it doesn't consume any CPU resources as long as they don't move.
They have extra functionalities to move and affect other bodies:
- [b]Static transform change:[/b] Static bodies can be moved by animation or script. In this case, they are just teleported and don't affect other bodies on their path.
- [b]Constant velocity:[/b] When [member constant_linear_velocity] or [member constant_angular_velocity] is set, static bodies don't move themselves but affect touching bodies as if they were moving. This is useful for simulating conveyor belts or conveyor wheels.
+ [i]Static transform change:[/i] Static bodies can be moved by animation or script. In this case, they are just teleported and don't affect other bodies on their path.
+ [i]Constant velocity:[/i] When [member constant_linear_velocity] or [member constant_angular_velocity] is set, static bodies don't move themselves but affect touching bodies as if they were moving. This is useful for simulating conveyor belts or conveyor wheels.
+ [b]Warning:[/b] With a non-uniform scale this node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change the size(s) of its collision shape(s) instead.
</description>
<tutorials>
<link title="3D Physics Tests Demo">https://godotengine.org/asset-library/asset/675</link>
diff --git a/doc/classes/StreamPeer.xml b/doc/classes/StreamPeer.xml
index f05b5f7dbf..969cbac57d 100644
--- a/doc/classes/StreamPeer.xml
+++ b/doc/classes/StreamPeer.xml
@@ -223,7 +223,7 @@
put_data("Hello world".to_utf8())
[/gdscript]
[csharp]
- PutData("Hello World".ToUTF8());
+ PutData("Hello World".ToUtf8());
[/csharp]
[/codeblocks]
</description>
diff --git a/doc/classes/StreamPeerTLS.xml b/doc/classes/StreamPeerTLS.xml
index d1ddb3d441..9e16dc8914 100644
--- a/doc/classes/StreamPeerTLS.xml
+++ b/doc/classes/StreamPeerTLS.xml
@@ -14,22 +14,18 @@
<method name="accept_stream">
<return type="int" enum="Error" />
<param index="0" name="stream" type="StreamPeer" />
- <param index="1" name="private_key" type="CryptoKey" />
- <param index="2" name="certificate" type="X509Certificate" />
- <param index="3" name="chain" type="X509Certificate" default="null" />
+ <param index="1" name="server_options" type="TLSOptions" />
<description>
- Accepts a peer connection as a server using the given [param private_key] and providing the given [param certificate] to the client. You can pass the optional [param chain] parameter to provide additional CA chain information along with the certificate.
+ Accepts a peer connection as a server using the given [param server_options]. See [method TLSOptions.server].
</description>
</method>
<method name="connect_to_stream">
<return type="int" enum="Error" />
<param index="0" name="stream" type="StreamPeer" />
- <param index="1" name="validate_certs" type="bool" default="false" />
- <param index="2" name="for_hostname" type="String" default="&quot;&quot;" />
- <param index="3" name="valid_certificate" type="X509Certificate" default="null" />
+ <param index="1" name="common_name" type="String" />
+ <param index="2" name="client_options" type="TLSOptions" default="null" />
<description>
- Connects to a peer using an underlying [StreamPeer] [param stream]. If [param validate_certs] is [code]true[/code], [StreamPeerTLS] will validate that the certificate presented by the peer matches the [param for_hostname].
- [b]Note:[/b] Specifying a custom [param valid_certificate] is not supported in Web exports due to browsers restrictions.
+ Connects to a peer using an underlying [StreamPeer] [param stream] and verifying the remote certificate is correctly signed for the given [param common_name]. You can pass the optional [param client_options] parameter to customize the trusted certification authorities, or disable the common name verification. See [method TLSOptions.client] and [method TLSOptions.client_unsafe].
</description>
</method>
<method name="disconnect_from_stream">
@@ -57,10 +53,6 @@
</description>
</method>
</methods>
- <members>
- <member name="blocking_handshake" type="bool" setter="set_blocking_handshake_enabled" getter="is_blocking_handshake_enabled" default="true">
- </member>
- </members>
<constants>
<constant name="STATUS_DISCONNECTED" value="0" enum="Status">
A status representing a [StreamPeerTLS] that is disconnected.
diff --git a/doc/classes/String.xml b/doc/classes/String.xml
index 97466e7860..143e1f23e9 100644
--- a/doc/classes/String.xml
+++ b/doc/classes/String.xml
@@ -1002,10 +1002,16 @@
[/codeblocks]
</description>
</method>
+ <method name="validate_filename" qualifiers="const">
+ <return type="String" />
+ <description>
+ Returns a copy of the string with all characters that are not allowed in [method is_valid_filename] replaced with underscores.
+ </description>
+ </method>
<method name="validate_node_name" qualifiers="const">
<return type="String" />
<description>
- Removes all characters that are not allowed in [member Node.name] from the string ([code].[/code] [code]:[/code] [code]@[/code] [code]/[/code] [code]"[/code] [code]%[/code]).
+ Returns a copy of the string with all characters that are not allowed in [member Node.name] removed ([code].[/code] [code]:[/code] [code]@[/code] [code]/[/code] [code]"[/code] [code]%[/code]).
</description>
</method>
<method name="xml_escape" qualifiers="const">
diff --git a/doc/classes/StringName.xml b/doc/classes/StringName.xml
index b46e39b8d7..c103fb2287 100644
--- a/doc/classes/StringName.xml
+++ b/doc/classes/StringName.xml
@@ -909,10 +909,16 @@
[/codeblocks]
</description>
</method>
+ <method name="validate_filename" qualifiers="const">
+ <return type="String" />
+ <description>
+ Returns a copy of the string with all characters that are not allowed in [method is_valid_filename] replaced with underscores.
+ </description>
+ </method>
<method name="validate_node_name" qualifiers="const">
<return type="String" />
<description>
- Removes all characters that are not allowed in [member Node.name] from the string ([code].[/code] [code]:[/code] [code]@[/code] [code]/[/code] [code]"[/code] [code]%[/code]).
+ Returns a copy of the string with all characters that are not allowed in [member Node.name] removed ([code].[/code] [code]:[/code] [code]@[/code] [code]/[/code] [code]"[/code] [code]%[/code]).
</description>
</method>
<method name="xml_escape" qualifiers="const">
diff --git a/doc/classes/StyleBox.xml b/doc/classes/StyleBox.xml
index ff6d4d8821..4a63f4488c 100644
--- a/doc/classes/StyleBox.xml
+++ b/doc/classes/StyleBox.xml
@@ -17,21 +17,16 @@
<description>
</description>
</method>
- <method name="_get_center_size" qualifiers="virtual const">
- <return type="Vector2" />
- <description>
- </description>
- </method>
<method name="_get_draw_rect" qualifiers="virtual const">
<return type="Rect2" />
<param index="0" name="rect" type="Rect2" />
<description>
</description>
</method>
- <method name="_get_style_margin" qualifiers="virtual const">
- <return type="float" />
- <param index="0" name="side" type="int" enum="Side" />
+ <method name="_get_minimum_size" qualifiers="virtual const">
+ <return type="Vector2" />
<description>
+ Virtual method to be implemented by the user. Returns a custom minimum size that the stylebox must respect when drawing. By default [method get_minimum_size] only takes content margins into account. This method can be overridden to add another size restriction. A combination of the default behavior and the output of this method will be used, to account for both sizes.
</description>
</method>
<method name="_test_mask" qualifiers="virtual const">
@@ -50,10 +45,11 @@
The [RID] value can either be the result of [method CanvasItem.get_canvas_item] called on an existing [CanvasItem]-derived node, or directly from creating a canvas item in the [RenderingServer] with [method RenderingServer.canvas_item_create].
</description>
</method>
- <method name="get_center_size" qualifiers="const">
- <return type="Vector2" />
+ <method name="get_content_margin" qualifiers="const">
+ <return type="float" />
+ <param index="0" name="margin" type="int" enum="Side" />
<description>
- Returns the size of this [StyleBox] without the margins.
+ Returns the default margin of the specified [enum Side].
</description>
</method>
<method name="get_current_item_drawn" qualifiers="const">
@@ -62,13 +58,6 @@
Returns the [CanvasItem] that handles its [constant CanvasItem.NOTIFICATION_DRAW] or [method CanvasItem._draw] callback at this moment.
</description>
</method>
- <method name="get_default_margin" qualifiers="const">
- <return type="float" />
- <param index="0" name="margin" type="int" enum="Side" />
- <description>
- Returns the default margin of the specified [enum Side].
- </description>
- </method>
<method name="get_margin" qualifiers="const">
<return type="float" />
<param index="0" name="margin" type="int" enum="Side" />
@@ -89,7 +78,7 @@
Returns the "offset" of a stylebox. This helper function returns a value equivalent to [code]Vector2(style.get_margin(MARGIN_LEFT), style.get_margin(MARGIN_TOP))[/code].
</description>
</method>
- <method name="set_default_margin">
+ <method name="set_content_margin">
<return type="void" />
<param index="0" name="margin" type="int" enum="Side" />
<param index="1" name="offset" type="float" />
@@ -97,7 +86,7 @@
Sets the default value of the specified [enum Side] to [param offset] pixels.
</description>
</method>
- <method name="set_default_margin_all">
+ <method name="set_content_margin_all">
<return type="void" />
<param index="0" name="offset" type="float" />
<description>
@@ -114,21 +103,21 @@
</method>
</methods>
<members>
- <member name="content_margin_bottom" type="float" setter="set_default_margin" getter="get_default_margin" default="-1.0">
+ <member name="content_margin_bottom" type="float" setter="set_content_margin" getter="get_content_margin" default="-1.0">
The bottom margin for the contents of this style box. Increasing this value reduces the space available to the contents from the bottom.
If this value is negative, it is ignored and a child-specific margin is used instead. For example for [StyleBoxFlat] the border thickness (if any) is used instead.
It is up to the code using this style box to decide what these contents are: for example, a [Button] respects this content margin for the textual contents of the button.
[method get_margin] should be used to fetch this value as consumer instead of reading these properties directly. This is because it correctly respects negative values and the fallback mentioned above.
</member>
- <member name="content_margin_left" type="float" setter="set_default_margin" getter="get_default_margin" default="-1.0">
+ <member name="content_margin_left" type="float" setter="set_content_margin" getter="get_content_margin" default="-1.0">
The left margin for the contents of this style box. Increasing this value reduces the space available to the contents from the left.
Refer to [member content_margin_bottom] for extra considerations.
</member>
- <member name="content_margin_right" type="float" setter="set_default_margin" getter="get_default_margin" default="-1.0">
+ <member name="content_margin_right" type="float" setter="set_content_margin" getter="get_content_margin" default="-1.0">
The right margin for the contents of this style box. Increasing this value reduces the space available to the contents from the right.
Refer to [member content_margin_bottom] for extra considerations.
</member>
- <member name="content_margin_top" type="float" setter="set_default_margin" getter="get_default_margin" default="-1.0">
+ <member name="content_margin_top" type="float" setter="set_content_margin" getter="get_content_margin" default="-1.0">
The top margin for the contents of this style box. Increasing this value reduces the space available to the contents from the top.
Refer to [member content_margin_bottom] for extra considerations.
</member>
diff --git a/doc/classes/StyleBoxTexture.xml b/doc/classes/StyleBoxTexture.xml
index aeba777b43..f2f6e59a9e 100644
--- a/doc/classes/StyleBoxTexture.xml
+++ b/doc/classes/StyleBoxTexture.xml
@@ -9,36 +9,36 @@
<tutorials>
</tutorials>
<methods>
- <method name="get_expand_margin_size" qualifiers="const">
+ <method name="get_expand_margin" qualifiers="const">
<return type="float" />
<param index="0" name="margin" type="int" enum="Side" />
<description>
Returns the expand margin size of the specified [enum Side].
</description>
</method>
- <method name="get_margin_size" qualifiers="const">
+ <method name="get_texture_margin" qualifiers="const">
<return type="float" />
<param index="0" name="margin" type="int" enum="Side" />
<description>
Returns the margin size of the specified [enum Side].
</description>
</method>
- <method name="set_expand_margin_all">
+ <method name="set_expand_margin">
<return type="void" />
- <param index="0" name="size" type="float" />
+ <param index="0" name="margin" type="int" enum="Side" />
+ <param index="1" name="size" type="float" />
<description>
- Sets the expand margin to [param size] pixels for all margins.
+ Sets the expand margin to [param size] pixels for the specified [enum Side].
</description>
</method>
- <method name="set_expand_margin_size">
+ <method name="set_expand_margin_all">
<return type="void" />
- <param index="0" name="margin" type="int" enum="Side" />
- <param index="1" name="size" type="float" />
+ <param index="0" name="size" type="float" />
<description>
- Sets the expand margin to [param size] pixels for the specified [enum Side].
+ Sets the expand margin to [param size] pixels for all margins.
</description>
</method>
- <method name="set_margin_size">
+ <method name="set_texture_margin">
<return type="void" />
<param index="0" name="margin" type="int" enum="Side" />
<param index="1" name="size" type="float" />
@@ -46,7 +46,7 @@
Sets the margin to [param size] pixels for the specified [enum Side].
</description>
</method>
- <method name="set_margin_size_all">
+ <method name="set_texture_margin_all">
<return type="void" />
<param index="0" name="size" type="float" />
<description>
@@ -64,48 +64,49 @@
<member name="draw_center" type="bool" setter="set_draw_center" getter="is_draw_center_enabled" default="true">
If [code]true[/code], the nine-patch texture's center tile will be drawn.
</member>
- <member name="expand_margin_bottom" type="float" setter="set_expand_margin_size" getter="get_expand_margin_size" default="0.0">
+ <member name="expand_margin_bottom" type="float" setter="set_expand_margin" getter="get_expand_margin" default="0.0">
Expands the bottom margin of this style box when drawing, causing it to be drawn larger than requested.
</member>
- <member name="expand_margin_left" type="float" setter="set_expand_margin_size" getter="get_expand_margin_size" default="0.0">
+ <member name="expand_margin_left" type="float" setter="set_expand_margin" getter="get_expand_margin" default="0.0">
Expands the left margin of this style box when drawing, causing it to be drawn larger than requested.
</member>
- <member name="expand_margin_right" type="float" setter="set_expand_margin_size" getter="get_expand_margin_size" default="0.0">
+ <member name="expand_margin_right" type="float" setter="set_expand_margin" getter="get_expand_margin" default="0.0">
Expands the right margin of this style box when drawing, causing it to be drawn larger than requested.
</member>
- <member name="expand_margin_top" type="float" setter="set_expand_margin_size" getter="get_expand_margin_size" default="0.0">
+ <member name="expand_margin_top" type="float" setter="set_expand_margin" getter="get_expand_margin" default="0.0">
Expands the top margin of this style box when drawing, causing it to be drawn larger than requested.
</member>
- <member name="margin_bottom" type="float" setter="set_margin_size" getter="get_margin_size" default="0.0">
+ <member name="modulate_color" type="Color" setter="set_modulate" getter="get_modulate" default="Color(1, 1, 1, 1)">
+ Modulates the color of the texture when this style box is drawn.
+ </member>
+ <member name="region_rect" type="Rect2" setter="set_region_rect" getter="get_region_rect" default="Rect2(0, 0, 0, 0)">
+ Species a sub-region of the texture to use.
+ This is equivalent to first wrapping the texture in an [AtlasTexture] with the same region.
+ If empty ([code]Rect2(0, 0, 0, 0)[/code]), the whole texture will be used.
+ </member>
+ <member name="texture" type="Texture2D" setter="set_texture" getter="get_texture">
+ The texture to use when drawing this style box.
+ </member>
+ <member name="texture_margin_bottom" type="float" setter="set_texture_margin" getter="get_texture_margin" default="0.0">
Increases the bottom margin of the 3×3 texture box.
A higher value means more of the source texture is considered to be part of the bottom border of the 3×3 box.
This is also the value used as fallback for [member StyleBox.content_margin_bottom] if it is negative.
</member>
- <member name="margin_left" type="float" setter="set_margin_size" getter="get_margin_size" default="0.0">
+ <member name="texture_margin_left" type="float" setter="set_texture_margin" getter="get_texture_margin" default="0.0">
Increases the left margin of the 3×3 texture box.
A higher value means more of the source texture is considered to be part of the left border of the 3×3 box.
This is also the value used as fallback for [member StyleBox.content_margin_left] if it is negative.
</member>
- <member name="margin_right" type="float" setter="set_margin_size" getter="get_margin_size" default="0.0">
+ <member name="texture_margin_right" type="float" setter="set_texture_margin" getter="get_texture_margin" default="0.0">
Increases the right margin of the 3×3 texture box.
A higher value means more of the source texture is considered to be part of the right border of the 3×3 box.
This is also the value used as fallback for [member StyleBox.content_margin_right] if it is negative.
</member>
- <member name="margin_top" type="float" setter="set_margin_size" getter="get_margin_size" default="0.0">
+ <member name="texture_margin_top" type="float" setter="set_texture_margin" getter="get_texture_margin" default="0.0">
Increases the top margin of the 3×3 texture box.
A higher value means more of the source texture is considered to be part of the top border of the 3×3 box.
This is also the value used as fallback for [member StyleBox.content_margin_top] if it is negative.
</member>
- <member name="modulate_color" type="Color" setter="set_modulate" getter="get_modulate" default="Color(1, 1, 1, 1)">
- Modulates the color of the texture when this style box is drawn.
- </member>
- <member name="region_rect" type="Rect2" setter="set_region_rect" getter="get_region_rect" default="Rect2(0, 0, 0, 0)">
- Species a sub-region of the texture to use.
- This is equivalent to first wrapping the texture in an [AtlasTexture] with the same region.
- </member>
- <member name="texture" type="Texture2D" setter="set_texture" getter="get_texture">
- The texture to use when drawing this style box.
- </member>
</members>
<constants>
<constant name="AXIS_STRETCH_MODE_STRETCH" value="0" enum="AxisStretchMode">
diff --git a/doc/classes/SubViewport.xml b/doc/classes/SubViewport.xml
index 7020cae1de..bb76a82ef3 100644
--- a/doc/classes/SubViewport.xml
+++ b/doc/classes/SubViewport.xml
@@ -26,6 +26,7 @@
</member>
<member name="size" type="Vector2i" setter="set_size" getter="get_size" default="Vector2i(512, 512)">
The width and height of the sub-viewport. Must be set to a value greater than or equal to 2 pixels on both dimensions. Otherwise, nothing will be displayed.
+ [b]Note:[/b] If the parent node is a [SubViewportContainer] and its [member SubViewportContainer.stretch] is [code]true[/code], the viewport size cannot be changed manually.
</member>
<member name="size_2d_override" type="Vector2i" setter="set_size_2d_override" getter="get_size_2d_override" default="Vector2i(0, 0)">
The 2D size override of the sub-viewport. If either the width or height is [code]0[/code], the override is disabled.
diff --git a/doc/classes/SubViewportContainer.xml b/doc/classes/SubViewportContainer.xml
index 77aa7e3ff4..11137222a9 100644
--- a/doc/classes/SubViewportContainer.xml
+++ b/doc/classes/SubViewportContainer.xml
@@ -13,6 +13,7 @@
<members>
<member name="stretch" type="bool" setter="set_stretch" getter="is_stretch_enabled" default="false">
If [code]true[/code], the sub-viewport will be automatically resized to the control's size.
+ [b]Note:[/b] If [code]true[/code], this will prohibit changing [member SubViewport.size] of its children manually.
</member>
<member name="stretch_shrink" type="int" setter="set_stretch_shrink" getter="get_stretch_shrink" default="1">
Divides the sub-viewport's effective resolution by this value while preserving its scale. This can be used to speed up rendering.
diff --git a/doc/classes/SurfaceTool.xml b/doc/classes/SurfaceTool.xml
index 9d73e9fb39..5b567dbc28 100644
--- a/doc/classes/SurfaceTool.xml
+++ b/doc/classes/SurfaceTool.xml
@@ -133,7 +133,7 @@
<description>
Generates normals from vertices so you do not have to do it manually. If [param flip] is [code]true[/code], the resulting normals will be inverted. [method generate_normals] should be called [i]after[/i] generating geometry and [i]before[/i] committing the mesh using [method commit] or [method commit_to_arrays]. For correct display of normal-mapped surfaces, you will also have to generate tangents using [method generate_tangents].
[b]Note:[/b] [method generate_normals] only works if the primitive type to be set to [constant Mesh.PRIMITIVE_TRIANGLES].
- [b]Note:[/b] [method generate_normals] takes smooth groups into account. If you don't specify any smooth group for each vertex, [method generate_normals] will smooth normals for you.
+ [b]Note:[/b] [method generate_normals] takes smooth groups into account. To generate smooth normals, set the smooth group to a value greater than or equal to [code]0[/code] using [method set_smooth_group] or leave the smooth group at the default of [code]0[/code]. To generate flat normals, set the smooth group to [code]-1[/code] using [method set_smooth_group] prior to adding vertices.
</description>
</method>
<method name="generate_tangents">
@@ -241,7 +241,7 @@
<return type="void" />
<param index="0" name="index" type="int" />
<description>
- Specifies whether the current vertex (if using only vertex arrays) or current index (if also using index arrays) should use smooth normals for normal calculation.
+ Specifies the smooth group to use for the [i]next[/i] vertex. If this is never called, all vertices will have the default smooth group of [code]0[/code] and will be smoothed with adjacent vertices of the same group. To produce a mesh with flat normals, set the smooth group to [code]-1[/code].
</description>
</method>
<method name="set_tangent">
diff --git a/doc/classes/SystemFont.xml b/doc/classes/SystemFont.xml
index 20bfd0d8ae..5e7b79ae97 100644
--- a/doc/classes/SystemFont.xml
+++ b/doc/classes/SystemFont.xml
@@ -43,6 +43,12 @@
<member name="hinting" type="int" setter="set_hinting" getter="get_hinting" enum="TextServer.Hinting" default="1">
Font hinting mode.
</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. 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. 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.
</member>
diff --git a/doc/classes/TLSOptions.xml b/doc/classes/TLSOptions.xml
new file mode 100644
index 0000000000..0917bd9bce
--- /dev/null
+++ b/doc/classes/TLSOptions.xml
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="TLSOptions" inherits="RefCounted" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+ <brief_description>
+ TLS configuration for clients and servers.
+ </brief_description>
+ <description>
+ TLSOptions abstracts the configuration options for the [StreamPeerTLS] and [PacketPeerDTLS] classes.
+ Objects of this class cannot be instantiated directly, and one of the static methods [method client], [method client_unsafe], or [method server] should be used instead.
+ [codeblocks]
+ [gdscript]
+ # Create a TLS client configuration which uses our custom trusted CA chain.
+ var client_trusted_cas = load("res://my_trusted_cas.crt")
+ var client_tls_options = TLSOptions.client(client_trusted_cas)
+
+ # Create a TLS server configuration.
+ var server_certs = load("res://my_server_cas.crt")
+ var server_key = load("res://my_server_key.key")
+ var server_tls_options = TLSOptions.server(server_certs, server_key)
+ [/gdscript]
+ [/codeblocks]
+ </description>
+ <tutorials>
+ </tutorials>
+ <methods>
+ <method name="client" qualifiers="static">
+ <return type="TLSOptions" />
+ <param index="0" name="trusted_chain" type="X509Certificate" default="null" />
+ <param index="1" name="common_name_override" type="String" default="&quot;&quot;" />
+ <description>
+ Creates a TLS client configuration which validates certificates and their common names (fully qualified domain names).
+ You can specify a custom [param trusted_chain] of certification authorities (the default CA list will be used if [code]null[/code]), and optionally provide a [param common_name_override] if you expect the certificate to have a common name other then the server FQDN.
+ Note: On the Web plafrom, TLS verification is always enforced against the CA list of the web browser. This is considered a security feature.
+ </description>
+ </method>
+ <method name="client_unsafe" qualifiers="static">
+ <return type="TLSOptions" />
+ <param index="0" name="trusted_chain" type="X509Certificate" default="null" />
+ <description>
+ Creates an [b]unsafe[/b] TLS client configuration where certificate validation is optional. You can optionally provide a valid [param trusted_chain], but the common name of the certififcates will never be checked. Using this configuration for purposes other than testing [b]is not recommended[/b].
+ Note: On the Web plafrom, TLS verification is always enforced against the CA list of the web browser. This is considered a security feature.
+ </description>
+ </method>
+ <method name="server" qualifiers="static">
+ <return type="TLSOptions" />
+ <param index="0" name="key" type="CryptoKey" />
+ <param index="1" name="certificate" type="X509Certificate" />
+ <description>
+ Creates a TLS server configuration using the provided [param key] and [param certificate].
+ Note: The [param certificate] should include the full certificate chain up to the signing CA (certificates file can be concatenated using a general purpose text editor).
+ </description>
+ </method>
+ </methods>
+</class>
diff --git a/doc/classes/TabBar.xml b/doc/classes/TabBar.xml
index 713c016651..3c7191392a 100644
--- a/doc/classes/TabBar.xml
+++ b/doc/classes/TabBar.xml
@@ -17,6 +17,12 @@
Adds a new tab.
</description>
</method>
+ <method name="clear_tabs">
+ <return type="void" />
+ <description>
+ Clears all tabs.
+ </description>
+ </method>
<method name="ensure_tab_visible">
<return type="void" />
<param index="0" name="idx" type="int" />
@@ -319,6 +325,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..c309026aaa 100644
--- a/doc/classes/TextEdit.xml
+++ b/doc/classes/TextEdit.xml
@@ -390,6 +390,45 @@
<return type="PopupMenu" />
<description>
Returns the [PopupMenu] of this [TextEdit]. By default, this menu is displayed when right-clicking on the [TextEdit].
+ You can add custom menu items or remove standard ones. Make sure your IDs don't conflict with the standard ones (see [enum MenuItems]). For example:
+ [codeblocks]
+ [gdscript]
+ func _ready():
+ var menu = get_menu()
+ # Remove all items after "Redo".
+ menu.item_count = menu.get_item_index(MENU_REDO) + 1
+ # Add custom items.
+ menu.add_separator()
+ menu.add_item("Insert Date", MENU_MAX + 1)
+ # Connect callback.
+ menu.id_pressed.connect(_on_item_pressed)
+
+ func _on_item_pressed(id):
+ if id == MENU_MAX + 1:
+ insert_text_at_caret(Time.get_date_string_from_system())
+ [/gdscript]
+ [csharp]
+ public override void _Ready()
+ {
+ var menu = GetMenu();
+ // Remove all items after "Redo".
+ menu.ItemCount = menu.GetItemIndex(TextEdit.MenuItems.Redo) + 1;
+ // Add custom items.
+ menu.AddSeparator();
+ menu.AddItem("Insert Date", TextEdit.MenuItems.Max + 1);
+ // Add event handler.
+ menu.IdPressed += OnItemPressed;
+ }
+
+ public void OnItemPressed(int id)
+ {
+ if (id == TextEdit.MenuItems.Max + 1)
+ {
+ InsertTextAtCaret(Time.GetDateStringFromSystem());
+ }
+ }
+ [/csharp]
+ [/codeblocks]
[b]Warning:[/b] This is a required internal node, removing and freeing it may cause a crash. If you wish to hide it or any of its children, use their [member Window.visible] property.
</description>
</method>
@@ -682,7 +721,7 @@
<return type="void" />
<param index="0" name="option" type="int" />
<description>
- Triggers a right-click menu action by the specified index. See [enum MenuItems] for a list of available indexes.
+ Executes a given action as defined in the [enum MenuItems] enum.
</description>
</method>
<method name="merge_gutters">
@@ -696,7 +735,7 @@
<method name="merge_overlapping_carets">
<return type="void" />
<description>
- Merges any overlapping carets. Will favour the newest caret, or the caret with a selection.
+ Merges any overlapping carets. Will favor the newest caret, or the caret with a selection.
[b]Note:[/b] This is not called when a caret changes position but after certain actions, so it is possible to get into a state where carets overlap.
</description>
</method>
@@ -764,18 +803,18 @@
[codeblocks]
[gdscript]
var result = search("print", SEARCH_WHOLE_WORDS, 0, 0)
- if result.x != -1:
+ if result.x != -1:
# Result found.
var line_number = result.y
var column_number = result.x
[/gdscript]
[csharp]
- Vector2i result = Search("print", (uint)TextEdit.SearchFlags.WholeWords, 0, 0);
- if (result.Length &gt; 0)
+ Vector2I result = Search("print", (uint)TextEdit.SearchFlags.WholeWords, 0, 0);
+ if (result.X != -1)
{
// Result found.
- int lineNumber = result.y;
- int columnNumber = result.x;
+ int lineNumber = result.Y;
+ int columnNumber = result.X;
}
[/csharp]
[/codeblocks]
@@ -1224,70 +1263,76 @@
<constant name="MENU_REDO" value="6" enum="MenuItems">
Redoes the previous action.
</constant>
- <constant name="MENU_DIR_INHERITED" value="7" enum="MenuItems">
+ <constant name="MENU_SUBMENU_TEXT_DIR" value="7" enum="MenuItems">
+ ID of "Text Writing Direction" submenu.
+ </constant>
+ <constant name="MENU_DIR_INHERITED" value="8" enum="MenuItems">
Sets text direction to inherited.
</constant>
- <constant name="MENU_DIR_AUTO" value="8" enum="MenuItems">
+ <constant name="MENU_DIR_AUTO" value="9" enum="MenuItems">
Sets text direction to automatic.
</constant>
- <constant name="MENU_DIR_LTR" value="9" enum="MenuItems">
+ <constant name="MENU_DIR_LTR" value="10" enum="MenuItems">
Sets text direction to left-to-right.
</constant>
- <constant name="MENU_DIR_RTL" value="10" enum="MenuItems">
+ <constant name="MENU_DIR_RTL" value="11" enum="MenuItems">
Sets text direction to right-to-left.
</constant>
- <constant name="MENU_DISPLAY_UCC" value="11" enum="MenuItems">
+ <constant name="MENU_DISPLAY_UCC" value="12" enum="MenuItems">
Toggles control character display.
</constant>
- <constant name="MENU_INSERT_LRM" value="12" enum="MenuItems">
+ <constant name="MENU_SUBMENU_INSERT_UCC" value="13" enum="MenuItems">
+ ID of "Insert Control Character" submenu.
+ </constant>
+ <constant name="MENU_INSERT_LRM" value="14" enum="MenuItems">
Inserts left-to-right mark (LRM) character.
</constant>
- <constant name="MENU_INSERT_RLM" value="13" enum="MenuItems">
+ <constant name="MENU_INSERT_RLM" value="15" enum="MenuItems">
Inserts right-to-left mark (RLM) character.
</constant>
- <constant name="MENU_INSERT_LRE" value="14" enum="MenuItems">
+ <constant name="MENU_INSERT_LRE" value="16" enum="MenuItems">
Inserts start of left-to-right embedding (LRE) character.
</constant>
- <constant name="MENU_INSERT_RLE" value="15" enum="MenuItems">
+ <constant name="MENU_INSERT_RLE" value="17" enum="MenuItems">
Inserts start of right-to-left embedding (RLE) character.
</constant>
- <constant name="MENU_INSERT_LRO" value="16" enum="MenuItems">
+ <constant name="MENU_INSERT_LRO" value="18" enum="MenuItems">
Inserts start of left-to-right override (LRO) character.
</constant>
- <constant name="MENU_INSERT_RLO" value="17" enum="MenuItems">
+ <constant name="MENU_INSERT_RLO" value="19" enum="MenuItems">
Inserts start of right-to-left override (RLO) character.
</constant>
- <constant name="MENU_INSERT_PDF" value="18" enum="MenuItems">
+ <constant name="MENU_INSERT_PDF" value="20" enum="MenuItems">
Inserts pop direction formatting (PDF) character.
</constant>
- <constant name="MENU_INSERT_ALM" value="19" enum="MenuItems">
+ <constant name="MENU_INSERT_ALM" value="21" enum="MenuItems">
Inserts Arabic letter mark (ALM) character.
</constant>
- <constant name="MENU_INSERT_LRI" value="20" enum="MenuItems">
+ <constant name="MENU_INSERT_LRI" value="22" enum="MenuItems">
Inserts left-to-right isolate (LRI) character.
</constant>
- <constant name="MENU_INSERT_RLI" value="21" enum="MenuItems">
+ <constant name="MENU_INSERT_RLI" value="23" enum="MenuItems">
Inserts right-to-left isolate (RLI) character.
</constant>
- <constant name="MENU_INSERT_FSI" value="22" enum="MenuItems">
+ <constant name="MENU_INSERT_FSI" value="24" enum="MenuItems">
Inserts first strong isolate (FSI) character.
</constant>
- <constant name="MENU_INSERT_PDI" value="23" enum="MenuItems">
+ <constant name="MENU_INSERT_PDI" value="25" enum="MenuItems">
Inserts pop direction isolate (PDI) character.
</constant>
- <constant name="MENU_INSERT_ZWJ" value="24" enum="MenuItems">
+ <constant name="MENU_INSERT_ZWJ" value="26" enum="MenuItems">
Inserts zero width joiner (ZWJ) character.
</constant>
- <constant name="MENU_INSERT_ZWNJ" value="25" enum="MenuItems">
+ <constant name="MENU_INSERT_ZWNJ" value="27" enum="MenuItems">
Inserts zero width non-joiner (ZWNJ) character.
</constant>
- <constant name="MENU_INSERT_WJ" value="26" enum="MenuItems">
+ <constant name="MENU_INSERT_WJ" value="28" enum="MenuItems">
Inserts word joiner (WJ) character.
</constant>
- <constant name="MENU_INSERT_SHY" value="27" enum="MenuItems">
+ <constant name="MENU_INSERT_SHY" value="29" enum="MenuItems">
Inserts soft hyphen (SHY) character.
</constant>
- <constant name="MENU_MAX" value="28" enum="MenuItems">
+ <constant name="MENU_MAX" value="30" enum="MenuItems">
Represents the size of the [enum MenuItems] enum.
</constant>
<constant name="ACTION_NONE" value="0" enum="EditAction">
@@ -1396,6 +1441,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..711fb89217 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">
@@ -1041,7 +1042,7 @@
</description>
</method>
<method name="parse_structured_text" qualifiers="const">
- <return type="Vector2i[]" />
+ <return type="Vector3i[]" />
<param index="0" name="parser_type" type="int" enum="TextServer.StructuredTextParser" />
<param index="1" name="args" type="Array" />
<param index="2" name="text" type="String" />
@@ -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;" />
+ <param index="2" name="chars_per_line" type="int" default="0" />
<description>
- Returns array of the word break character offsets.
+ 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">
@@ -1624,6 +1634,9 @@
<constant name="DIRECTION_RTL" value="2" enum="Direction">
Text is written from right to left.
</constant>
+ <constant name="DIRECTION_INHERITED" value="3" enum="Direction">
+ Text writing direction is the same as base string writing direction. Used for BiDi override only.
+ </constant>
<constant name="ORIENTATION_HORIZONTAL" value="0" enum="Orientation">
Text is written horizontally.
</constant>
@@ -1871,7 +1884,7 @@
Font have fixed-width characters.
</constant>
<constant name="STRUCTURED_TEXT_DEFAULT" value="0" enum="StructuredTextParser">
- Use default behavior. Same as [constant STRUCTURED_TEXT_NONE] unless specified otherwise in the control description.
+ Use default Unicode BiDi algorithm.
</constant>
<constant name="STRUCTURED_TEXT_URI" value="1" enum="StructuredTextParser">
BiDi override for URI.
@@ -1886,8 +1899,8 @@
BiDi override for lists.
Structured text options: list separator [code]String[/code].
</constant>
- <constant name="STRUCTURED_TEXT_NONE" value="5" enum="StructuredTextParser">
- Use default Unicode BiDi algorithm.
+ <constant name="STRUCTURED_TEXT_GDSCRIPT" value="5" enum="StructuredTextParser">
+ BiDi override for GDScript.
</constant>
<constant name="STRUCTURED_TEXT_CUSTOM" value="6" enum="StructuredTextParser">
User defined structured text BiDi override function.
diff --git a/doc/classes/TextServerExtension.xml b/doc/classes/TextServerExtension.xml
index 4c9817fcd4..f4b306cf96 100644
--- a/doc/classes/TextServerExtension.xml
+++ b/doc/classes/TextServerExtension.xml
@@ -896,7 +896,7 @@
</description>
</method>
<method name="_parse_structured_text" qualifiers="virtual const">
- <return type="Vector2i[]" />
+ <return type="Vector3i[]" />
<param index="0" name="parser_type" type="int" enum="TextServer.StructuredTextParser" />
<param index="1" name="args" type="Array" />
<param index="2" name="text" type="String" />
@@ -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/Texture2D.xml b/doc/classes/Texture2D.xml
index aac197090a..7329ebb868 100644
--- a/doc/classes/Texture2D.xml
+++ b/doc/classes/Texture2D.xml
@@ -74,6 +74,12 @@
Called when a pixel's opaque state in the [Texture2D] is queried at the specified [code](x, y)[/code] position.
</description>
</method>
+ <method name="create_placeholder" qualifiers="const">
+ <return type="Resource" />
+ <description>
+ Creates a placeholder version of this resource ([PlaceholderTexture2D]).
+ </description>
+ </method>
<method name="draw" qualifiers="const">
<return type="void" />
<param index="0" name="canvas_item" type="RID" />
diff --git a/doc/classes/Texture2DArray.xml b/doc/classes/Texture2DArray.xml
index ec00198db1..6c9fb55bef 100644
--- a/doc/classes/Texture2DArray.xml
+++ b/doc/classes/Texture2DArray.xml
@@ -10,4 +10,12 @@
</description>
<tutorials>
</tutorials>
+ <methods>
+ <method name="create_placeholder" qualifiers="const">
+ <return type="Resource" />
+ <description>
+ Creates a placeholder version of this resource ([PlaceholderTexture2DArray]).
+ </description>
+ </method>
+ </methods>
</class>
diff --git a/doc/classes/Texture3D.xml b/doc/classes/Texture3D.xml
index 1a66932d62..d2df82a74d 100644
--- a/doc/classes/Texture3D.xml
+++ b/doc/classes/Texture3D.xml
@@ -47,6 +47,12 @@
Called when the presence of mipmaps in the [Texture3D] is queried.
</description>
</method>
+ <method name="create_placeholder" qualifiers="const">
+ <return type="Resource" />
+ <description>
+ Creates a placeholder version of this resource ([PlaceholderTexture3D]).
+ </description>
+ </method>
<method name="get_data" qualifiers="const">
<return type="Image[]" />
<description>
diff --git a/doc/classes/TextureProgressBar.xml b/doc/classes/TextureProgressBar.xml
index d7a9d06a15..f381ee771e 100644
--- a/doc/classes/TextureProgressBar.xml
+++ b/doc/classes/TextureProgressBar.xml
@@ -43,7 +43,7 @@
<member name="radial_initial_angle" type="float" setter="set_radial_initial_angle" getter="get_radial_initial_angle" default="0.0">
Starting angle for the fill of [member texture_progress] if [member fill_mode] is [constant FILL_CLOCKWISE] or [constant FILL_COUNTER_CLOCKWISE]. When the node's [code]value[/code] is equal to its [code]min_value[/code], the texture doesn't show up at all. When the [code]value[/code] increases, the texture fills and tends towards [member radial_fill_degrees].
</member>
- <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" default="1" />
+ <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" enum="Control.SizeFlags" default="1" />
<member name="step" type="float" setter="set_step" getter="get_step" overrides="Range" default="1.0" />
<member name="stretch_margin_bottom" type="int" setter="set_stretch_margin" getter="get_stretch_margin" default="0">
The height of the 9-patch's bottom row. A margin of 16 means the 9-slice's bottom corners and side will have a height of 16 pixels. You can set all 4 margin values individually to create panels with non-uniform borders.
diff --git a/doc/classes/TextureRect.xml b/doc/classes/TextureRect.xml
index 348b4a5837..460ffbbb80 100644
--- a/doc/classes/TextureRect.xml
+++ b/doc/classes/TextureRect.xml
@@ -10,15 +10,15 @@
<link title="3D Voxel Demo">https://godotengine.org/asset-library/asset/676</link>
</tutorials>
<members>
+ <member name="expand_mode" type="int" setter="set_expand_mode" getter="get_expand_mode" enum="TextureRect.ExpandMode" default="0">
+ Defines how minimum size is determined based on the texture's size. See [enum ExpandMode] for options.
+ </member>
<member name="flip_h" type="bool" setter="set_flip_h" getter="is_flipped_h" default="false">
If [code]true[/code], texture is flipped horizontally.
</member>
<member name="flip_v" type="bool" setter="set_flip_v" getter="is_flipped_v" default="false">
If [code]true[/code], texture is flipped vertically.
</member>
- <member name="ignore_texture_size" type="bool" setter="set_ignore_texture_size" getter="get_ignore_texture_size" default="false">
- If [code]true[/code], the size of the texture won't be considered for minimum size calculation, so the [TextureRect] can be shrunk down past the texture size. Useful for preventing [TextureRect]s from breaking GUI layout regardless of their texture size.
- </member>
<member name="mouse_filter" type="int" setter="set_mouse_filter" getter="get_mouse_filter" overrides="Control" enum="Control.MouseFilter" default="1" />
<member name="stretch_mode" type="int" setter="set_stretch_mode" getter="get_stretch_mode" enum="TextureRect.StretchMode" default="0">
Controls the texture's behavior when resizing the node's bounding rectangle. See [enum StretchMode].
@@ -28,6 +28,24 @@
</member>
</members>
<constants>
+ <constant name="EXPAND_KEEP_SIZE" value="0" enum="ExpandMode">
+ The minimum size will be equal to texture size, i.e. [TextureRect] can't be smaller than the texture.
+ </constant>
+ <constant name="EXPAND_IGNORE_SIZE" value="1" enum="ExpandMode">
+ The size of the texture won't be considered for minimum size calculation, so the [TextureRect] can be shrunk down past the texture size.
+ </constant>
+ <constant name="EXPAND_FIT_WIDTH" value="2" enum="ExpandMode">
+ The height of the texture will be ignored. Minimum width will be equal to the current height. Useful for horizontal layouts, e.g. inside [HBoxContainer].
+ </constant>
+ <constant name="EXPAND_FIT_WIDTH_PROPORTIONAL" value="3" enum="ExpandMode">
+ Same as [constant EXPAND_FIT_WIDTH], but keeps texture's aspect ratio.
+ </constant>
+ <constant name="EXPAND_FIT_HEIGHT" value="4" enum="ExpandMode">
+ The width of the texture will be ignored. Minimum height will be equal to the current width. Useful for vertical layouts, e.g. inside [VBoxContainer].
+ </constant>
+ <constant name="EXPAND_FIT_HEIGHT_PROPORTIONAL" value="5" enum="ExpandMode">
+ Same as [constant EXPAND_FIT_HEIGHT], but keeps texture's aspect ratio.
+ </constant>
<constant name="STRETCH_SCALE" value="0" enum="StretchMode">
Scale to fit the node's bounding rectangle.
</constant>
diff --git a/doc/classes/TileData.xml b/doc/classes/TileData.xml
index f815b8d0c3..bedc52abd1 100644
--- a/doc/classes/TileData.xml
+++ b/doc/classes/TileData.xml
@@ -218,7 +218,7 @@
<member name="terrain_set" type="int" setter="set_terrain_set" getter="get_terrain_set" default="-1">
ID of the terrain set that the tile uses.
</member>
- <member name="texture_offset" type="Vector2i" setter="set_texture_offset" getter="get_texture_offset" default="Vector2i(0, 0)">
+ <member name="texture_origin" type="Vector2i" setter="set_texture_origin" getter="get_texture_origin" default="Vector2i(0, 0)">
Offsets the position of where the tile is drawn.
</member>
<member name="transpose" type="bool" setter="set_transpose" getter="get_transpose" default="false">
diff --git a/doc/classes/TileMap.xml b/doc/classes/TileMap.xml
index 8b537545bc..c387bd435b 100644
--- a/doc/classes/TileMap.xml
+++ b/doc/classes/TileMap.xml
@@ -104,7 +104,8 @@
<param index="1" name="coords" type="Vector2i" />
<param index="2" name="use_proxies" type="bool" default="false" />
<description>
- Returns the tile source ID of the cell on layer [param layer] at coordinates [param coords]. If [param use_proxies] is [code]false[/code], ignores the [TileSet]'s tile proxies, returning the raw alternative identifier. See [method TileSet.map_tile_proxy].
+ Returns the tile source ID of the cell on layer [param layer] at coordinates [param coords]. Returns [code]-1[/code] if the cell does not exist.
+ If [param use_proxies] is [code]false[/code], ignores the [TileSet]'s tile proxies, returning the raw alternative identifier. See [method TileSet.map_tile_proxy].
</description>
</method>
<method name="get_cell_tile_data" qualifiers="const">
@@ -113,8 +114,17 @@
<param index="1" name="coords" type="Vector2i" />
<param index="2" name="use_proxies" type="bool" default="false" />
<description>
- Returns the [TileData] object associated with the given cell, or [code]null[/code] if the cell is not a [TileSetAtlasSource].
+ Returns the [TileData] object associated with the given cell, or [code]null[/code] if the cell does not exist or is not a [TileSetAtlasSource].
If [param use_proxies] is [code]false[/code], ignores the [TileSet]'s tile proxies, returning the raw alternative identifier. See [method TileSet.map_tile_proxy].
+ [codeblock]
+ func get_clicked_tile_power():
+ var clicked_cell = tile_map.local_to_map(tile_map.get_local_mouse_position())
+ var data = tile_map.get_cell_tile_data(0, clicked_cell)
+ if data:
+ return data.get_custom_data("power")
+ else:
+ return 0
+ [/codeblock]
</description>
</method>
<method name="get_coords_for_body_rid">
@@ -185,7 +195,19 @@
<return type="Vector2i[]" />
<param index="0" name="layer" type="int" />
<description>
- Returns a [Vector2] array with the positions of all cells containing a tile in the given layer. A cell is considered empty if its source identifier equals -1, its atlas coordinates identifiers is [code]Vector2(-1, -1)[/code] and its alternative identifier is -1.
+ Returns a [Vector2i] array with the positions of all cells containing a tile in the given layer. A cell is considered empty if its source identifier equals -1, its atlas coordinates identifiers is [code]Vector2(-1, -1)[/code] and its alternative identifier is -1.
+ </description>
+ </method>
+ <method name="get_used_cells_by_id" qualifiers="const">
+ <return type="Vector2i[]" />
+ <param index="0" name="layer" type="int" />
+ <param index="1" name="source_id" type="int" default="-1" />
+ <param index="2" name="atlas_coords" type="Vector2i" default="Vector2i(-1, -1)" />
+ <param index="3" name="alternative_tile" type="int" default="-1" />
+ <description>
+ Returns a [Vector2i] array with the positions of all cells containing a tile in the given layer. Tiles may be filtered according to their source ([param source_id]), their atlas coordinates ([param atlas_coords]) or alternative id ([param source_id]).
+ If a parameter has it's value set to the default one, this parameter is not used to filter a cell. Thus, if all parameters have their respective default value, this method returns the same result as [method get_used_cells].
+ A cell is considered empty if its source identifier equals -1, its atlas coordinates identifiers is [code]Vector2(-1, -1)[/code] and its alternative identifier is -1.
</description>
</method>
<method name="get_used_rect">
@@ -229,7 +251,7 @@
<param index="0" name="map_position" type="Vector2i" />
<description>
Returns the centered position of a cell in the TileMap's local coordinate space. To convert the returned value into global coordinates, use [method Node2D.to_global]. See also [method local_to_map].
- [b]Note:[/b] This may not correspond to the visual position of the tile, i.e. it ignores the [member TileData.texture_offset] property of individual tiles.
+ [b]Note:[/b] This may not correspond to the visual position of the tile, i.e. it ignores the [member TileData.texture_origin] property of individual tiles.
</description>
</method>
<method name="move_layer">
@@ -321,7 +343,7 @@
<param index="1" name="y_sort_enabled" type="bool" />
<description>
Enables or disables a layer's Y-sorting. If a layer is Y-sorted, the layer will behave as a CanvasItem node where each of its tile gets Y-sorted.
- Y-sorted layers should usually be on different Z-index values than not Y-sorted layers, otherwise, each of those layer will be Y-sorted as whole with the Y-sorted one. This is usually an undesired behvaior.
+ Y-sorted layers should usually be on different Z-index values than not Y-sorted layers, otherwise, each of those layer will be Y-sorted as whole with the Y-sorted one. This is usually an undesired behavior.
If [code]layer[/code] is negative, the layers are accessed from the last one.
</description>
</method>
diff --git a/doc/classes/TileSet.xml b/doc/classes/TileSet.xml
index 7fc6ba8161..a39a43be4c 100644
--- a/doc/classes/TileSet.xml
+++ b/doc/classes/TileSet.xml
@@ -143,6 +143,14 @@
Returns the custom data layers count.
</description>
</method>
+ <method name="get_navigation_layer_layer_value" qualifiers="const">
+ <return type="bool" />
+ <param index="0" name="layer_index" type="int" />
+ <param index="1" name="layer_number" type="int" />
+ <description>
+ Returns whether or not the specified navigation layer of the TileSet navigation data layer identified by the given [param layer_index] is enabled, given a navigation_layers [param layer_number] between 1 and 32.
+ </description>
+ </method>
<method name="get_navigation_layer_layers" qualifiers="const">
<return type="int" />
<param index="0" name="layer_index" type="int" />
@@ -500,6 +508,15 @@
Sets the type of the custom data layer identified by the given index.
</description>
</method>
+ <method name="set_navigation_layer_layer_value">
+ <return type="void" />
+ <param index="0" name="layer_index" type="int" />
+ <param index="1" name="layer_number" type="int" />
+ <param index="2" name="value" type="bool" />
+ <description>
+ Based on [param value], enables or disables the specified navigation layer of the TileSet navigation data layer identified by the given [param layer_index], given a navigation_layers [param layer_number] between 1 and 32.
+ </description>
+ </method>
<method name="set_navigation_layer_layers">
<return type="void" />
<param index="0" name="layer_index" type="int" />
@@ -589,7 +606,7 @@
<param index="0" name="terrain_set" type="int" />
<param index="1" name="mode" type="int" enum="TileSet.TerrainMode" />
<description>
- Sets a terrain mode. Each mode determines which bits of a tile shape is used to match the neighbouring tiles' terrains.
+ Sets a terrain mode. Each mode determines which bits of a tile shape is used to match the neighboring tiles' terrains.
</description>
</method>
</methods>
diff --git a/doc/classes/Timer.xml b/doc/classes/Timer.xml
index d171797e80..1b6c05284e 100644
--- a/doc/classes/Timer.xml
+++ b/doc/classes/Timer.xml
@@ -48,7 +48,7 @@
</member>
<member name="time_left" type="float" setter="" getter="get_time_left">
The timer's remaining time in seconds. Returns 0 if the timer is inactive.
- [b]Note:[/b] You cannot set this value. To change the timer's remaining time, use [method start].
+ [b]Note:[/b] This value is read-only and cannot be set. It is based on [member wait_time], which can be set using [method start].
</member>
<member name="wait_time" type="float" setter="set_wait_time" getter="get_wait_time" default="1.0">
The wait time in seconds.
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/Transform3D.xml b/doc/classes/Transform3D.xml
index b3145ea022..90c10e3664 100644
--- a/doc/classes/Transform3D.xml
+++ b/doc/classes/Transform3D.xml
@@ -41,6 +41,7 @@
<return type="Transform3D" />
<param index="0" name="from" type="Projection" />
<description>
+ Constructs a Transform3D from a [Projection] by trimming the last row of the projection matrix ([code]from.x.w[/code], [code]from.y.w[/code], [code]from.z.w[/code], and [code]from.w.w[/code] are not copied over).
</description>
</constructor>
<constructor name="Transform3D">
diff --git a/doc/classes/Tree.xml b/doc/classes/Tree.xml
index 629c271417..02a2789ea5 100644
--- a/doc/classes/Tree.xml
+++ b/doc/classes/Tree.xml
@@ -45,11 +45,17 @@
<method name="create_item">
<return type="TreeItem" />
<param index="0" name="parent" type="TreeItem" default="null" />
- <param index="1" name="idx" type="int" default="-1" />
+ <param index="1" name="index" type="int" default="-1" />
<description>
Creates an item in the tree and adds it as a child of [param parent], which can be either a valid [TreeItem] or [code]null[/code].
If [param parent] is [code]null[/code], the root item will be the parent, or the new item will be the root itself if the tree is empty.
- The new item will be the [param idx]th child of parent, or it will be the last child if there are not enough siblings.
+ The new item will be the [param index]-th child of parent, or it will be the last child if there are not enough siblings.
+ </description>
+ </method>
+ <method name="deselect_all">
+ <return type="void" />
+ <description>
+ Deselects all tree items (rows and columns). In [constant SELECT_MULTI] mode also removes selection cursor.
</description>
</method>
<method name="edit_selected">
@@ -395,7 +401,7 @@
</signal>
<signal name="item_activated">
<description>
- Emitted when an item's label is double-clicked.
+ Emitted when an item is double-clicked, or selected with a [code]ui_accept[/code] input event (e.g. using [kbd]Enter[/kbd] or [kbd]Space[/kbd] on the keyboard).
</description>
</signal>
<signal name="item_collapsed">
@@ -404,19 +410,14 @@
Emitted when an item is collapsed by a click on the folding arrow.
</description>
</signal>
- <signal name="item_custom_button_pressed">
- <description>
- Emitted when a custom button is pressed (i.e. in a [constant TreeItem.CELL_MODE_CUSTOM] mode cell).
- </description>
- </signal>
- <signal name="item_double_clicked">
+ <signal name="item_edited">
<description>
- Emitted when an item's icon is double-clicked.
+ Emitted when an item is edited.
</description>
</signal>
- <signal name="item_edited">
+ <signal name="item_icon_double_clicked">
<description>
- Emitted when an item is edited.
+ Emitted when an item's icon is double-clicked. For a signal that emits when any part of the item is double-clicked, see [signal item_activated].
</description>
</signal>
<signal name="item_mouse_selected">
@@ -522,6 +523,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/TreeItem.xml b/doc/classes/TreeItem.xml
index ec6b166e57..91248092d9 100644
--- a/doc/classes/TreeItem.xml
+++ b/doc/classes/TreeItem.xml
@@ -18,7 +18,7 @@
<param index="3" name="disabled" type="bool" default="false" />
<param index="4" name="tooltip_text" type="String" default="&quot;&quot;" />
<description>
- Adds a button with [Texture2D] [param button] at column [param column]. The [param id] is used to identify the button. If not specified, the next available index is used, which may be retrieved by calling [method get_button_count] immediately before this method. Optionally, the button can be [param disabled] and have a [param tooltip_text].
+ Adds a button with [Texture2D] [param button] at column [param column]. The [param id] is used to identify the button in the according [signal Tree.button_clicked] signal and can be different from the buttons index. If not specified, the next available index is used, which may be retrieved by calling [method get_button_count] immediately before this method. Optionally, the button can be [param disabled] and have a [param tooltip_text].
</description>
</method>
<method name="call_recursive" qualifiers="vararg">
@@ -44,10 +44,10 @@
</method>
<method name="create_child">
<return type="TreeItem" />
- <param index="0" name="idx" type="int" default="-1" />
+ <param index="0" name="index" type="int" default="-1" />
<description>
Creates an item and adds it as a child.
- The new item will be inserted as position [param idx] (the default value [code]-1[/code] means the last position), or it will be the last child if [param idx] is higher than the child count.
+ The new item will be inserted as position [param index] (the default value [code]-1[/code] means the last position), or it will be the last child if [param index] is higher than the child count.
</description>
</method>
<method name="deselect">
@@ -60,17 +60,17 @@
<method name="erase_button">
<return type="void" />
<param index="0" name="column" type="int" />
- <param index="1" name="button_idx" type="int" />
+ <param index="1" name="button_index" type="int" />
<description>
- Removes the button at index [param button_idx] in column [param column].
+ Removes the button at index [param button_index] in column [param column].
</description>
</method>
<method name="get_button" qualifiers="const">
<return type="Texture2D" />
<param index="0" name="column" type="int" />
- <param index="1" name="button_idx" type="int" />
+ <param index="1" name="button_index" type="int" />
<description>
- Returns the [Texture2D] of the button at index [param button_idx] in column [param column].
+ Returns the [Texture2D] of the button at index [param button_index] in column [param column].
</description>
</method>
<method name="get_button_by_id" qualifiers="const">
@@ -91,17 +91,17 @@
<method name="get_button_id" qualifiers="const">
<return type="int" />
<param index="0" name="column" type="int" />
- <param index="1" name="button_idx" type="int" />
+ <param index="1" name="button_index" type="int" />
<description>
- Returns the ID for the button at index [param button_idx] in column [param column].
+ Returns the ID for the button at index [param button_index] in column [param column].
</description>
</method>
<method name="get_button_tooltip_text" qualifiers="const">
<return type="String" />
<param index="0" name="column" type="int" />
- <param index="1" name="button_idx" type="int" />
+ <param index="1" name="button_index" type="int" />
<description>
- Returns the tooltip text for the button at index [param button_idx] in column [param column].
+ Returns the tooltip text for the button at index [param button_index] in column [param column].
</description>
</method>
<method name="get_cell_mode" qualifiers="const">
@@ -113,9 +113,9 @@
</method>
<method name="get_child">
<return type="TreeItem" />
- <param index="0" name="idx" type="int" />
+ <param index="0" name="index" type="int" />
<description>
- Returns a child item by its index (see [method get_child_count]). This method is often used for iterating all children of an item.
+ Returns a child item by its [param index] (see [method get_child_count]). This method is often used for iterating all children of an item.
Negative indices access the children from the last one.
</description>
</method>
@@ -332,9 +332,9 @@
<method name="is_button_disabled" qualifiers="const">
<return type="bool" />
<param index="0" name="column" type="int" />
- <param index="1" name="button_idx" type="int" />
+ <param index="1" name="button_index" type="int" />
<description>
- Returns [code]true[/code] if the button at index [param button_idx] for the given [param column] is disabled.
+ Returns [code]true[/code] if the button at index [param button_index] for the given [param column] is disabled.
</description>
</method>
<method name="is_checked" qualifiers="const">
@@ -419,28 +419,28 @@
<method name="set_button">
<return type="void" />
<param index="0" name="column" type="int" />
- <param index="1" name="button_idx" type="int" />
+ <param index="1" name="button_index" type="int" />
<param index="2" name="button" type="Texture2D" />
<description>
- Sets the given column's button [Texture2D] at index [param button_idx] to [param button].
+ Sets the given column's button [Texture2D] at index [param button_index] to [param button].
</description>
</method>
<method name="set_button_color">
<return type="void" />
<param index="0" name="column" type="int" />
- <param index="1" name="button_idx" type="int" />
+ <param index="1" name="button_index" type="int" />
<param index="2" name="color" type="Color" />
<description>
- Sets the given column's button color at index [param button_idx] to [param color].
+ Sets the given column's button color at index [param button_index] to [param color].
</description>
</method>
<method name="set_button_disabled">
<return type="void" />
<param index="0" name="column" type="int" />
- <param index="1" name="button_idx" type="int" />
+ <param index="1" name="button_index" type="int" />
<param index="2" name="disabled" type="bool" />
<description>
- If [code]true[/code], disables the button at index [param button_idx] in the given [param column].
+ If [code]true[/code], disables the button at index [param button_index] in the given [param column].
</description>
</method>
<method name="set_cell_mode">
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/Tween.xml b/doc/classes/Tween.xml
index eef35049e5..16e4ce3714 100644
--- a/doc/classes/Tween.xml
+++ b/doc/classes/Tween.xml
@@ -11,7 +11,7 @@
[codeblocks]
[gdscript]
var tween = get_tree().create_tween()
- tween.tween_property($Sprite, "modulate", Color.red, 1)
+ tween.tween_property($Sprite, "modulate", Color.RED, 1)
tween.tween_property($Sprite, "scale", Vector2(), 1)
tween.tween_callback($Sprite.queue_free)
[/gdscript]
@@ -19,7 +19,7 @@
Tween tween = GetTree().CreateTween();
tween.TweenProperty(GetNode("Sprite"), "modulate", Colors.Red, 1.0f);
tween.TweenProperty(GetNode("Sprite"), "scale", Vector2.Zero, 1.0f);
- tween.TweenCallback(new Callable(GetNode("Sprite").QueueFree));
+ tween.TweenCallback(Callable.From(GetNode("Sprite").QueueFree));
[/csharp]
[/codeblocks]
This sequence will make the [code]$Sprite[/code] node turn red, then shrink, before finally calling [method Node.queue_free] to free the sprite. [Tweener]s are executed one after another by default. This behavior can be changed using [method parallel] and [method set_parallel].
@@ -27,7 +27,7 @@
[codeblocks]
[gdscript]
var tween = get_tree().create_tween()
- tween.tween_property($Sprite, "modulate", Color.red, 1).set_trans(Tween.TRANS_SINE)
+ tween.tween_property($Sprite, "modulate", Color.RED, 1).set_trans(Tween.TRANS_SINE)
tween.tween_property($Sprite, "scale", Vector2(), 1).set_trans(Tween.TRANS_BOUNCE)
tween.tween_callback($Sprite.queue_free)
[/gdscript]
@@ -35,14 +35,14 @@
Tween tween = GetTree().CreateTween();
tween.TweenProperty(GetNode("Sprite"), "modulate", Colors.Red, 1.0f).SetTrans(Tween.TransitionType.Sine);
tween.TweenProperty(GetNode("Sprite"), "scale", Vector2.Zero, 1.0f).SetTrans(Tween.TransitionType.Bounce);
- tween.TweenCallback(new Callable(GetNode("Sprite").QueueFree));
+ tween.TweenCallback(Callable.From(GetNode("Sprite").QueueFree));
[/csharp]
[/codeblocks]
Most of the [Tween] methods can be chained this way too. In the following example the [Tween] is bound to the running script's node and a default transition is set for its [Tweener]s:
[codeblocks]
[gdscript]
var tween = get_tree().create_tween().bind_node(self).set_trans(Tween.TRANS_ELASTIC)
- tween.tween_property($Sprite, "modulate", Color.red, 1)
+ tween.tween_property($Sprite, "modulate", Color.RED, 1)
tween.tween_property($Sprite, "scale", Vector2(), 1)
tween.tween_callback($Sprite.queue_free)
[/gdscript]
@@ -50,7 +50,7 @@
var tween = GetTree().CreateTween().BindNode(this).SetTrans(Tween.TransitionType.Elastic);
tween.TweenProperty(GetNode("Sprite"), "modulate", Colors.Red, 1.0f);
tween.TweenProperty(GetNode("Sprite"), "scale", Vector2.Zero, 1.0f);
- tween.TweenCallback(new Callable(GetNode("Sprite").QueueFree));
+ tween.TweenCallback(Callable.From(GetNode("Sprite").QueueFree));
[/csharp]
[/codeblocks]
Another interesting use for [Tween]s is animating arbitrary sets of objects:
@@ -77,13 +77,13 @@
tween = create_tween()
[/gdscript]
[csharp]
- private Tween tween;
+ private Tween _tween;
public void Animate()
{
- if (tween != null)
- tween.Kill(); // Abort the previous animation
- tween = CreateTween();
+ if (_tween != null)
+ _tween.Kill(); // Abort the previous animation
+ _tween = CreateTween();
}
[/csharp]
[/codeblocks]
@@ -281,21 +281,21 @@
[/gdscript]
[csharp]
Tween tween = GetTree().CreateTween().SetLoops();
- tween.TweenCallback(new Callable(Shoot)).SetDelay(1.0f);
+ tween.TweenCallback(Callable.From(Shoot)).SetDelay(1.0f);
[/csharp]
[/codeblocks]
[b]Example:[/b] Turning a sprite red and then blue, with 2 second delay:
[codeblocks]
[gdscript]
var tween = get_tree().create_tween()
- tween.tween_callback($Sprite.set_modulate.bind(Color.red)).set_delay(2)
- tween.tween_callback($Sprite.set_modulate.bind(Color.blue)).set_delay(2)
+ tween.tween_callback($Sprite.set_modulate.bind(Color.RED)).set_delay(2)
+ tween.tween_callback($Sprite.set_modulate.bind(Color.BLUE)).set_delay(2)
[/gdscript]
[csharp]
Tween tween = GetTree().CreateTween();
Sprite2D sprite = GetNode&lt;Sprite2D&gt;("Sprite");
- tween.TweenCallback(new Callable(() =&gt; sprite.Modulate = Colors.Red)).SetDelay(2.0f);
- tween.TweenCallback(new Callable(() =&gt; sprite.Modulate = Colors.Blue)).SetDelay(2.0f);
+ tween.TweenCallback(Callable.From(() =&gt; sprite.Modulate = Colors.Red)).SetDelay(2.0f);
+ tween.TweenCallback(Callable.From(() =&gt; sprite.Modulate = Colors.Blue)).SetDelay(2.0f);
[/csharp]
[/codeblocks]
</description>
@@ -332,10 +332,10 @@
[csharp]
Tween tween = CreateTween().SetLoops();
tween.TweenProperty(GetNode("Sprite"), "position:x", 200.0f, 1.0f).AsRelative();
- tween.TweenCallback(new Callable(Jump));
+ tween.TweenCallback(Callable.From(Jump));
tween.TweenInterval(2.0f);
tween.TweenProperty(GetNode("Sprite"), "position:x", -200.0f, 1.0f).AsRelative();
- tween.TweenCallback(new Callable(Jump));
+ tween.TweenCallback(Callable.From(Jump));
tween.TweenInterval(2.0f);
[/csharp]
[/codeblocks]
@@ -357,7 +357,7 @@
[/gdscript]
[csharp]
Tween tween = CreateTween();
- tween.TweenMethod(new Callable(() =&gt; LookAt(Vector3.Up)), new Vector3(-1.0f, 0.0f, -1.0f), new Vector3(1.0f, 0.0f, -1.0f), 1.0f); // The LookAt() method takes up vector as second argument.
+ tween.TweenMethod(Callable.From(() =&gt; LookAt(Vector3.Up)), new Vector3(-1.0f, 0.0f, -1.0f), new Vector3(1.0f, 0.0f, -1.0f), 1.0f); // The LookAt() method takes up vector as second argument.
[/csharp]
[/codeblocks]
[b]Example:[/b] Setting the text of a [Label], using an intermediate method and after a delay:
@@ -376,7 +376,7 @@
base._Ready();
Tween tween = CreateTween();
- tween.TweenMethod(new Callable(SetLabelText), 0.0f, 10.0f, 1.0f).SetDelay(1.0f);
+ tween.TweenMethod(Callable.From&lt;int&gt;(SetLabelText), 0.0f, 10.0f, 1.0f).SetDelay(1.0f);
}
private void SetLabelText(int value)
diff --git a/doc/classes/UDPServer.xml b/doc/classes/UDPServer.xml
index c3a3a49a80..8151ecb625 100644
--- a/doc/classes/UDPServer.xml
+++ b/doc/classes/UDPServer.xml
@@ -9,7 +9,8 @@
Below a small example of how it can be used:
[codeblocks]
[gdscript]
- class_name Server
+ # server_node.gd
+ class_name ServerNode
extends Node
var server := UDPServer.new()
@@ -34,35 +35,35 @@
pass # Do something with the connected peers.
[/gdscript]
[csharp]
+ // ServerNode.cs
using Godot;
- using System;
using System.Collections.Generic;
- public class Server : Node
+ public partial class ServerNode : Node
{
- public UDPServer Server = new UDPServer();
- public List&lt;PacketPeerUDP&gt; Peers = new List&lt;PacketPeerUDP&gt;();
+ private UdpServer _server = new UdpServer();
+ private List&lt;PacketPeerUdp&gt; _peers = new List&lt;PacketPeerUdp&gt;();
public override void _Ready()
{
- Server.Listen(4242);
+ _server.Listen(4242);
}
- public override void _Process(float delta)
+ public override void _Process(double delta)
{
- Server.Poll(); // Important!
- if (Server.IsConnectionAvailable())
+ _server.Poll(); // Important!
+ if (_server.IsConnectionAvailable())
{
- PacketPeerUDP peer = Server.TakeConnection();
+ PacketPeerUdp peer = _server.TakeConnection();
byte[] packet = peer.GetPacket();
- GD.Print($"Accepted Peer: {peer.GetPacketIp()}:{peer.GetPacketPort()}");
- GD.Print($"Received Data: {packet.GetStringFromUTF8()}");
+ GD.Print($"Accepted Peer: {peer.GetPacketIP()}:{peer.GetPacketPort()}");
+ GD.Print($"Received Data: {packet.GetStringFromUtf8()}");
// Reply so it knows we received the message.
peer.PutPacket(packet);
// Keep a reference so we can keep contacting the remote peer.
- Peers.Add(peer);
+ _peers.Add(peer);
}
- foreach (var peer in Peers)
+ foreach (var peer in _peers)
{
// Do something with the peers.
}
@@ -72,7 +73,8 @@
[/codeblocks]
[codeblocks]
[gdscript]
- class_name Client
+ # client_node.gd
+ class_name ClientNode
extends Node
var udp := PacketPeerUDP.new()
@@ -90,30 +92,30 @@
connected = true
[/gdscript]
[csharp]
+ // ClientNode.cs
using Godot;
- using System;
- public class Client : Node
+ public partial class ClientNode : Node
{
- public PacketPeerUDP Udp = new PacketPeerUDP();
- public bool Connected = false;
+ private PacketPeerUdp _udp = new PacketPeerUdp();
+ private bool _connected = false;
public override void _Ready()
{
- Udp.ConnectToHost("127.0.0.1", 4242);
+ _udp.ConnectToHost("127.0.0.1", 4242);
}
- public override void _Process(float delta)
+ public override void _Process(double delta)
{
- if (!Connected)
+ if (!_connected)
{
// Try to contact server
- Udp.PutPacket("The Answer Is..42!".ToUTF8());
+ _udp.PutPacket("The Answer Is..42!".ToUtf8());
}
- if (Udp.GetAvailablePacketCount() &gt; 0)
+ if (_udp.GetAvailablePacketCount() &gt; 0)
{
- GD.Print($"Connected: {Udp.GetPacket().GetStringFromUTF8()}");
- Connected = true;
+ GD.Print($"Connected: {_udp.GetPacket().GetStringFromUtf8()}");
+ _connected = true;
}
}
}
diff --git a/doc/classes/UndoRedo.xml b/doc/classes/UndoRedo.xml
index 7258efbdda..e43bceb941 100644
--- a/doc/classes/UndoRedo.xml
+++ b/doc/classes/UndoRedo.xml
@@ -17,7 +17,7 @@
func undo_something():
pass # Put here the code that reverts what's done by "do_something()".
- func _on_MyButton_pressed():
+ func _on_my_button_pressed():
var node = get_node("MyNode2D")
undo_redo.create_action("Move the node")
undo_redo.add_do_method(self, "do_something")
@@ -27,11 +27,11 @@
undo_redo.commit_action()
[/gdscript]
[csharp]
- public UndoRedo UndoRedo;
+ private UndoRedo _undoRedo;
public override void _Ready()
{
- UndoRedo = GetUndoRedo(); // Method of EditorPlugin.
+ _undoRedo = GetUndoRedo(); // Method of EditorPlugin.
}
public void DoSomething()
@@ -47,12 +47,12 @@
private void OnMyButtonPressed()
{
var node = GetNode&lt;Node2D&gt;("MyNode2D");
- UndoRedo.CreateAction("Move the node");
- UndoRedo.AddDoMethod(this, nameof(DoSomething));
- UndoRedo.AddUndoMethod(this, nameof(UndoSomething));
- UndoRedo.AddDoProperty(node, "position", new Vector2(100, 100));
- UndoRedo.AddUndoProperty(node, "position", node.Position);
- UndoRedo.CommitAction();
+ _undoRedo.CreateAction("Move the node");
+ _undoRedo.AddDoMethod(new Callable(this, MethodName.DoSomething));
+ _undoRedo.AddUndoMethod(new Callable(this, MethodName.UndoSomething));
+ _undoRedo.AddDoProperty(node, "position", new Vector2(100, 100));
+ _undoRedo.AddUndoProperty(node, "position", node.Position);
+ _undoRedo.CommitAction();
}
[/csharp]
[/codeblocks]
diff --git a/doc/classes/VScrollBar.xml b/doc/classes/VScrollBar.xml
index f9baf194b7..41a87ba886 100644
--- a/doc/classes/VScrollBar.xml
+++ b/doc/classes/VScrollBar.xml
@@ -9,8 +9,8 @@
<tutorials>
</tutorials>
<members>
- <member name="size_flags_horizontal" type="int" setter="set_h_size_flags" getter="get_h_size_flags" overrides="Control" default="0" />
- <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" default="1" />
+ <member name="size_flags_horizontal" type="int" setter="set_h_size_flags" getter="get_h_size_flags" overrides="Control" enum="Control.SizeFlags" default="0" />
+ <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" enum="Control.SizeFlags" default="1" />
</members>
<theme_items>
<theme_item name="decrement" data_type="icon" type="Texture2D">
diff --git a/doc/classes/VSlider.xml b/doc/classes/VSlider.xml
index 4bc98dea6f..2a5b5c1e0a 100644
--- a/doc/classes/VSlider.xml
+++ b/doc/classes/VSlider.xml
@@ -10,8 +10,8 @@
<tutorials>
</tutorials>
<members>
- <member name="size_flags_horizontal" type="int" setter="set_h_size_flags" getter="get_h_size_flags" overrides="Control" default="0" />
- <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" default="1" />
+ <member name="size_flags_horizontal" type="int" setter="set_h_size_flags" getter="get_h_size_flags" overrides="Control" enum="Control.SizeFlags" default="0" />
+ <member name="size_flags_vertical" type="int" setter="set_v_size_flags" getter="get_v_size_flags" overrides="Control" enum="Control.SizeFlags" default="1" />
</members>
<theme_items>
<theme_item name="grabber_offset" data_type="constant" type="int" default="0">
diff --git a/doc/classes/Variant.xml b/doc/classes/Variant.xml
index 6b384d6a77..5416468ab6 100644
--- a/doc/classes/Variant.xml
+++ b/doc/classes/Variant.xml
@@ -38,7 +38,7 @@
# To get the name of the underlying Object type, you need the `get_class()` method.
print("foo is a(n) %s" % foo.get_class()) # inject the class name into a formatted string.
# Note also that there is not yet any way to get a script's `class_name` string easily.
- # To fetch that value, you need to dig deeply into a hidden ProjectSettings setting: an Array of Dictionaries called "_global_script_classes".
+ # To fetch that value, you can parse the [code]res://.godot/global_script_class_cache.cfg[/code] file with the [ConfigFile] API.
# Open your project.godot file to see it up close.
[/gdscript]
[csharp]
@@ -70,6 +70,6 @@
Modifications to a container will modify all references to it. A [Mutex] should be created to lock it if multi-threaded access is desired.
</description>
<tutorials>
- <link title="Variant class">$DOCS_URL/development/cpp/variant_class.html</link>
+ <link title="Variant class introduction">$DOCS_URL/contributing/development/core_and_modules/variant_class.html</link>
</tutorials>
</class>
diff --git a/doc/classes/VehicleBody3D.xml b/doc/classes/VehicleBody3D.xml
index e1689133de..9f905c0ec5 100644
--- a/doc/classes/VehicleBody3D.xml
+++ b/doc/classes/VehicleBody3D.xml
@@ -7,6 +7,7 @@
This node implements all the physics logic needed to simulate a car. It is based on the raycast vehicle system commonly found in physics engines. You will need to add a [CollisionShape3D] for the main body of your vehicle and add [VehicleWheel3D] nodes for the wheels. You should also add a [MeshInstance3D] to this node for the 3D model of your car but this model should not include meshes for the wheels. You should control the vehicle by using the [member brake], [member engine_force], and [member steering] properties and not change the position or orientation of this node directly.
[b]Note:[/b] The origin point of your VehicleBody3D will determine the center of gravity of your vehicle so it is better to keep this low and move the [CollisionShape3D] and [MeshInstance3D] upwards.
[b]Note:[/b] This class has known issues and isn't designed to provide realistic 3D vehicle physics. If you want advanced vehicle physics, you will probably have to write your own physics integration using another [PhysicsBody3D] class.
+ [b]Warning:[/b] With a non-uniform scale this node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change the size(s) of its collision shape(s) instead.
</description>
<tutorials>
<link title="3D Truck Town Demo">https://godotengine.org/asset-library/asset/524</link>
diff --git a/doc/classes/VideoStream.xml b/doc/classes/VideoStream.xml
index 2797ad3513..648c3edd73 100644
--- a/doc/classes/VideoStream.xml
+++ b/doc/classes/VideoStream.xml
@@ -8,4 +8,18 @@
</description>
<tutorials>
</tutorials>
+ <methods>
+ <method name="_instantiate_playback" qualifiers="virtual">
+ <return type="VideoStreamPlayback" />
+ <description>
+ Called when the video starts playing, to initialize and return a subclass of [VideoStreamPlayback].
+ </description>
+ </method>
+ </methods>
+ <members>
+ <member name="file" type="String" setter="set_file" getter="get_file" default="&quot;&quot;">
+ The video file path or URI that this [VideoStream] resource handles.
+ For [VideoStreamTheora], this filename should be an Ogg Theora video file with the [code].ogv[/code] extension.
+ </member>
+ </members>
</class>
diff --git a/doc/classes/VideoStreamPlayback.xml b/doc/classes/VideoStreamPlayback.xml
new file mode 100644
index 0000000000..8d8b4fe5b1
--- /dev/null
+++ b/doc/classes/VideoStreamPlayback.xml
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="VideoStreamPlayback" inherits="Resource" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+ <brief_description>
+ Internal class used by [VideoStream] to manage playback state when played from a [VideoStreamPlayer].
+ </brief_description>
+ <description>
+ This class is intended to be overridden by video decoder extensions with custom implementations of [VideoStream].
+ </description>
+ <tutorials>
+ </tutorials>
+ <methods>
+ <method name="_get_channels" qualifiers="virtual const">
+ <return type="int" />
+ <description>
+ Returns the number of audio channels.
+ </description>
+ </method>
+ <method name="_get_length" qualifiers="virtual const">
+ <return type="float" />
+ <description>
+ Returns the video duration in seconds, if known, or 0 if unknown.
+ </description>
+ </method>
+ <method name="_get_mix_rate" qualifiers="virtual const">
+ <return type="int" />
+ <description>
+ Returns the audio sample rate used for mixing.
+ </description>
+ </method>
+ <method name="_get_playback_position" qualifiers="virtual const">
+ <return type="float" />
+ <description>
+ Return the current playback timestamp. Called in response to the [member VideoStreamPlayer.stream_position] getter.
+ </description>
+ </method>
+ <method name="_get_texture" qualifiers="virtual const">
+ <return type="Texture2D" />
+ <description>
+ Allocates a [Texture2D] in which decoded video frames will be drawn.
+ </description>
+ </method>
+ <method name="_is_paused" qualifiers="virtual const">
+ <return type="bool" />
+ <description>
+ Returns the paused status, as set by [method _set_paused].
+ </description>
+ </method>
+ <method name="_is_playing" qualifiers="virtual const">
+ <return type="bool" />
+ <description>
+ Returns the playback state, as determined by calls to [method _play] and [method _stop].
+ </description>
+ </method>
+ <method name="_play" qualifiers="virtual">
+ <return type="void" />
+ <description>
+ Called in response to [member VideoStreamPlayer.autoplay] or [method VideoStreamPlayer.play]. Note that manual playback may also invoke [method _stop] multiple times before this method is called. [method _is_playing] should return true once playing.
+ </description>
+ </method>
+ <method name="_seek" qualifiers="virtual">
+ <return type="void" />
+ <param index="0" name="time" type="float" />
+ <description>
+ Seeks to [code]time[/code] seconds. Called in response to the [member VideoStreamPlayer.stream_position] setter.
+ </description>
+ </method>
+ <method name="_set_audio_track" qualifiers="virtual">
+ <return type="void" />
+ <param index="0" name="idx" type="int" />
+ <description>
+ Select the audio track [code]idx[/code]. Called when playback starts, and in response to the [member VideoStreamPlayer.audio_track] setter.
+ </description>
+ </method>
+ <method name="_set_paused" qualifiers="virtual">
+ <return type="void" />
+ <param index="0" name="paused" type="bool" />
+ <description>
+ Set the paused status of video playback. [method _is_paused] must return [code]paused[/code]. Called in response to the [member VideoStreamPlayer.paused] setter.
+ </description>
+ </method>
+ <method name="_stop" qualifiers="virtual">
+ <return type="void" />
+ <description>
+ Stops playback. May be called multiple times before [method _play], or in response to [method VideoStreamPlayer.stop]. [method _is_playing] should return false once stopped.
+ </description>
+ </method>
+ <method name="_update" qualifiers="virtual">
+ <return type="void" />
+ <param index="0" name="delta" type="float" />
+ <description>
+ Ticks video playback for [code]delta[/code] seconds. Called every frame as long as [method _is_paused] and [method _is_playing] return true.
+ </description>
+ </method>
+ <method name="mix_audio">
+ <return type="int" />
+ <param index="0" name="num_frames" type="int" />
+ <param index="1" name="buffer" type="PackedFloat32Array" default="PackedFloat32Array()" />
+ <param index="2" name="offset" type="int" default="0" />
+ <description>
+ Render [code]num_frames[/code] audio frames (of [method _get_channels] floats each) from [code]buffer[/code], starting from index [code]offset[/code] in the array. Returns the number of audio frames rendered, or -1 on error.
+ </description>
+ </method>
+ </methods>
+</class>
diff --git a/doc/classes/Viewport.xml b/doc/classes/Viewport.xml
index 236d34383f..ab2de14638 100644
--- a/doc/classes/Viewport.xml
+++ b/doc/classes/Viewport.xml
@@ -55,7 +55,7 @@
<method name="get_final_transform" qualifiers="const">
<return type="Transform2D" />
<description>
- Returns the total transform of the viewport.
+ Returns the transform from the viewport's coordinate system to the embedder's coordinate system.
</description>
</method>
<method name="get_mouse_position" qualifiers="const">
@@ -210,6 +210,7 @@
<param index="0" name="position" type="Vector2" />
<description>
Moves the mouse pointer to the specified position in this [Viewport] using the coordinate system of this [Viewport].
+ [b]Note:[/b] [method warp_mouse] is only supported on Windows, macOS and Linux. It has no effect on Android, iOS and Web.
</description>
</method>
</methods>
diff --git a/doc/classes/VisualInstance3D.xml b/doc/classes/VisualInstance3D.xml
index 31811f817b..3781045c02 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">
+ 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..6bffcdef36 100644
--- a/doc/classes/VisualShader.xml
+++ b/doc/classes/VisualShader.xml
@@ -26,6 +26,7 @@
<param index="1" name="mode" type="int" enum="VisualShader.VaryingMode" />
<param index="2" name="type" type="int" enum="VisualShader.VaryingType" />
<description>
+ Adds a new varying value node to the shader.
</description>
</method>
<method name="can_connect_nodes" qualifiers="const">
@@ -106,12 +107,14 @@
<return type="int" />
<param index="0" name="type" type="int" enum="VisualShader.Type" />
<description>
+ Returns next valid node ID that can be added to the shader graph.
</description>
</method>
<method name="has_varying" qualifiers="const">
<return type="bool" />
<param index="0" name="name" type="String" />
<description>
+ Returns [code]true[/code] if the shader has a varying with the given [param name].
</description>
</method>
<method name="is_node_connection" qualifiers="const">
@@ -137,6 +140,7 @@
<return type="void" />
<param index="0" name="name" type="String" />
<description>
+ Removes a varying value node with the given [param name]. Prints an error if a node with this name is not found.
</description>
</method>
<method name="replace_node">
@@ -181,16 +185,22 @@
A shader for light calculations.
</constant>
<constant name="TYPE_START" value="3" enum="Type">
+ A function for the "start" stage of particle shader.
</constant>
<constant name="TYPE_PROCESS" value="4" enum="Type">
+ A function for the "process" stage of particle shader.
</constant>
<constant name="TYPE_COLLIDE" value="5" enum="Type">
+ A function for the "collide" stage (particle collision handler) of particle shader.
</constant>
<constant name="TYPE_START_CUSTOM" value="6" enum="Type">
+ A function for the "start" stage of particle shader, with customized output.
</constant>
<constant name="TYPE_PROCESS_CUSTOM" value="7" enum="Type">
+ A function for the "process" stage of particle shader, with customized output.
</constant>
<constant name="TYPE_SKY" value="8" enum="Type">
+ A shader for 3D environment's sky.
</constant>
<constant name="TYPE_FOG" value="9" enum="Type">
A compute shader that runs for each froxel of the volumetric fog map.
@@ -199,30 +209,46 @@
Represents the size of the [enum Type] enum.
</constant>
<constant name="VARYING_MODE_VERTEX_TO_FRAG_LIGHT" value="0" enum="VaryingMode">
+ Varying is passed from [code]Vertex[/code] function to [code]Fragment[/code] and [code]Light[/code] functions.
</constant>
<constant name="VARYING_MODE_FRAG_TO_LIGHT" value="1" enum="VaryingMode">
+ Varying is passed from [code]Fragment[/code] function to [code]Light[/code] function.
</constant>
<constant name="VARYING_MODE_MAX" value="2" enum="VaryingMode">
+ Represents the size of the [enum VaryingMode] enum.
</constant>
<constant name="VARYING_TYPE_FLOAT" value="0" enum="VaryingType">
+ Varying is of type [float].
</constant>
<constant name="VARYING_TYPE_INT" value="1" enum="VaryingType">
+ Varying is of type [int].
</constant>
- <constant name="VARYING_TYPE_VECTOR_2D" value="2" enum="VaryingType">
+ <constant name="VARYING_TYPE_UINT" value="2" enum="VaryingType">
+ Varying is of type unsigned [int].
</constant>
- <constant name="VARYING_TYPE_VECTOR_3D" value="3" enum="VaryingType">
+ <constant name="VARYING_TYPE_VECTOR_2D" value="3" enum="VaryingType">
+ Varying is of type [Vector2].
</constant>
- <constant name="VARYING_TYPE_VECTOR_4D" value="4" enum="VaryingType">
+ <constant name="VARYING_TYPE_VECTOR_3D" value="4" enum="VaryingType">
+ Varying is of type [Vector3].
</constant>
- <constant name="VARYING_TYPE_BOOLEAN" value="5" enum="VaryingType">
+ <constant name="VARYING_TYPE_VECTOR_4D" value="5" enum="VaryingType">
+ Varying is of type [Vector4].
</constant>
- <constant name="VARYING_TYPE_TRANSFORM" value="6" enum="VaryingType">
+ <constant name="VARYING_TYPE_BOOLEAN" value="6" enum="VaryingType">
+ Varying is of type [bool].
</constant>
- <constant name="VARYING_TYPE_MAX" value="7" enum="VaryingType">
+ <constant name="VARYING_TYPE_TRANSFORM" value="7" enum="VaryingType">
+ Varying is of type [Transform3D].
+ </constant>
+ <constant name="VARYING_TYPE_MAX" value="8" enum="VaryingType">
+ Represents the size of the [enum VaryingType] enum.
</constant>
<constant name="NODE_ID_INVALID" value="-1">
+ Denotes invalid [VisualShader] node.
</constant>
<constant name="NODE_ID_OUTPUT" value="0">
+ Denotes output node of [VisualShader].
</constant>
</constants>
</class>
diff --git a/doc/classes/VisualShaderNode.xml b/doc/classes/VisualShaderNode.xml
index 1f3397f39c..685f5d5eef 100644
--- a/doc/classes/VisualShaderNode.xml
+++ b/doc/classes/VisualShaderNode.xml
@@ -58,13 +58,6 @@
Sets the output port index which will be showed for preview. If set to [code]-1[/code] no port will be open for preview.
</member>
</members>
- <signals>
- <signal name="editor_refresh_request">
- <description>
- Emitted when the node requests an editor refresh. Currently called only in setter of [member VisualShaderNodeTexture.source], [VisualShaderNodeTexture], and [VisualShaderNodeCubemap] (and their derivatives).
- </description>
- </signal>
- </signals>
<constants>
<constant name="PORT_TYPE_SCALAR" value="0" enum="PortType">
Floating-point scalar. Translated to [code]float[/code] type in shader code.
@@ -72,25 +65,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/VisualShaderNodeConstant.xml b/doc/classes/VisualShaderNodeConstant.xml
index 213ab664ad..23b97a78c7 100644
--- a/doc/classes/VisualShaderNodeConstant.xml
+++ b/doc/classes/VisualShaderNodeConstant.xml
@@ -4,6 +4,7 @@
A base type for the constants within the visual shader graph.
</brief_description>
<description>
+ This is an abstract class. See the derived types for descriptions of the possible values.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeCustom.xml b/doc/classes/VisualShaderNodeCustom.xml
index d96969b383..279295a434 100644
--- a/doc/classes/VisualShaderNodeCustom.xml
+++ b/doc/classes/VisualShaderNodeCustom.xml
@@ -81,7 +81,7 @@
</description>
</method>
<method name="_get_input_port_type" qualifiers="virtual const">
- <return type="int" />
+ <return type="int" enum="VisualShaderNode.PortType" />
<param index="0" name="port" type="int" />
<description>
Override this method to define the returned type of each input port of the associated custom node (see [enum VisualShaderNode.PortType] for possible types).
@@ -111,7 +111,7 @@
</description>
</method>
<method name="_get_output_port_type" qualifiers="virtual const">
- <return type="int" />
+ <return type="int" enum="VisualShaderNode.PortType" />
<param index="0" name="port" type="int" />
<description>
Override this method to define the returned type of each output port of the associated custom node (see [enum VisualShaderNode.PortType] for possible types).
@@ -119,7 +119,7 @@
</description>
</method>
<method name="_get_return_icon_type" qualifiers="virtual const">
- <return type="int" />
+ <return type="int" enum="VisualShaderNode.PortType" />
<description>
Override this method to define the return icon of the associated custom node in the Visual Shader Editor's members dialog.
Defining this method is [b]optional[/b]. If not overridden, no return icon is shown.
diff --git a/doc/classes/VisualShaderNodeDerivativeFunc.xml b/doc/classes/VisualShaderNodeDerivativeFunc.xml
index 9a1ad53394..4a31969171 100644
--- a/doc/classes/VisualShaderNodeDerivativeFunc.xml
+++ b/doc/classes/VisualShaderNodeDerivativeFunc.xml
@@ -15,6 +15,9 @@
<member name="op_type" type="int" setter="set_op_type" getter="get_op_type" enum="VisualShaderNodeDerivativeFunc.OpType" default="0">
A type of operands and returned value. See [enum OpType] for options.
</member>
+ <member name="precision" type="int" setter="set_precision" getter="get_precision" enum="VisualShaderNodeDerivativeFunc.Precision" default="0">
+ Sets the level of precision to use for the derivative function. See [enum Precision] for options. When using the GL_Compatibility renderer, this setting has no effect.
+ </member>
</members>
<constants>
<constant name="OP_TYPE_SCALAR" value="0" enum="OpType">
@@ -44,5 +47,17 @@
<constant name="FUNC_MAX" value="3" enum="Function">
Represents the size of the [enum Function] enum.
</constant>
+ <constant name="PRECISION_NONE" value="0" enum="Precision">
+ No precision is specified, the GPU driver is allowed to use whatever level of precision it chooses. This is the default option and is equivalent to using [code]dFdx()[/code] or [code]dFdy()[/code] in text shaders.
+ </constant>
+ <constant name="PRECISION_COARSE" value="1" enum="Precision">
+ The derivative will be calculated using the current fragment's neighbors (which may not include the current fragment). This tends to be faster than using [constant PRECISION_FINE], but may not be suitable when more precision is needed. This is equivalent to using [code]dFdxCoarse()[/code] or [code]dFdyCoarse()[/code] in text shaders.
+ </constant>
+ <constant name="PRECISION_FINE" value="2" enum="Precision">
+ The derivative will be calculated using the current fragment and its immediate neighbors. This tends to be slower than using [constant PRECISION_COARSE], but may be necessary when more precision is needed. This is equivalent to using [code]dFdxFine()[/code] or [code]dFdyFine()[/code] in text shaders.
+ </constant>
+ <constant name="PRECISION_MAX" value="3" enum="Precision">
+ Represents the size of the [enum Precision] enum.
+ </constant>
</constants>
</class>
diff --git a/doc/classes/VisualShaderNodeDistanceFade.xml b/doc/classes/VisualShaderNodeDistanceFade.xml
index 8ea0857776..c707035253 100644
--- a/doc/classes/VisualShaderNodeDistanceFade.xml
+++ b/doc/classes/VisualShaderNodeDistanceFade.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeDistanceFade" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node representing distance fade effect.
</brief_description>
<description>
+ The distance fade effect fades out each pixel based on its distance to another object.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeIntParameter.xml b/doc/classes/VisualShaderNodeIntParameter.xml
index 70335b0c77..1ee7e3f217 100644
--- a/doc/classes/VisualShaderNodeIntParameter.xml
+++ b/doc/classes/VisualShaderNodeIntParameter.xml
@@ -1,33 +1,45 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeIntParameter" inherits="VisualShaderNodeParameter" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node for shader parameter (uniform) of type [int].
</brief_description>
<description>
+ A [VisualShaderNodeParameter] of type [int]. Offers additional customization for range of accepted values.
</description>
<tutorials>
</tutorials>
<members>
<member name="default_value" type="int" setter="set_default_value" getter="get_default_value" default="0">
+ Default value of this parameter, which will be used if not set externally. [member default_value_enabled] must be enabled; defaults to [code]0[/code] otherwise.
</member>
<member name="default_value_enabled" type="bool" setter="set_default_value_enabled" getter="is_default_value_enabled" default="false">
+ If [code]true[/code], the node will have a custom default value.
</member>
<member name="hint" type="int" setter="set_hint" getter="get_hint" enum="VisualShaderNodeIntParameter.Hint" default="0">
+ Range hint of this node. Use it to customize valid parameter range.
</member>
<member name="max" type="int" setter="set_max" getter="get_max" default="100">
+ The maximum value this parameter can take. [member hint] must be either [constant HINT_RANGE] or [constant HINT_RANGE_STEP] for this to take effect.
</member>
<member name="min" type="int" setter="set_min" getter="get_min" default="0">
+ The minimum value this parameter can take. [member hint] must be either [constant HINT_RANGE] or [constant HINT_RANGE_STEP] for this to take effect.
</member>
<member name="step" type="int" setter="set_step" getter="get_step" default="1">
+ The step between parameter's values. Forces the parameter to be a multiple of the given value. [member hint] must be [constant HINT_RANGE_STEP] for this to take effect.
</member>
</members>
<constants>
<constant name="HINT_NONE" value="0" enum="Hint">
+ The parameter will not constrain its value.
</constant>
<constant name="HINT_RANGE" value="1" enum="Hint">
+ The parameter's value must be within the specified [member min]/[member max] range.
</constant>
<constant name="HINT_RANGE_STEP" value="2" enum="Hint">
+ The parameter's value must be within the specified range, with the given [member step] between values.
</constant>
<constant name="HINT_MAX" value="3" enum="Hint">
+ Represents the size of the [enum Hint] enum.
</constant>
</constants>
</class>
diff --git a/doc/classes/VisualShaderNodeLinearSceneDepth.xml b/doc/classes/VisualShaderNodeLinearSceneDepth.xml
index fa8c01ac0a..0dff2d780d 100644
--- a/doc/classes/VisualShaderNodeLinearSceneDepth.xml
+++ b/doc/classes/VisualShaderNodeLinearSceneDepth.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeLinearSceneDepth" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that returns the depth value of the DEPTH_TEXTURE node in a linear space.
</brief_description>
<description>
+ This node can be used in fragment shaders.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeParameter.xml b/doc/classes/VisualShaderNodeParameter.xml
index 55b10ac810..acc180a7ca 100644
--- a/doc/classes/VisualShaderNodeParameter.xml
+++ b/doc/classes/VisualShaderNodeParameter.xml
@@ -13,14 +13,18 @@
Name of the parameter, by which it can be accessed through the [ShaderMaterial] properties.
</member>
<member name="qualifier" type="int" setter="set_qualifier" getter="get_qualifier" enum="VisualShaderNodeParameter.Qualifier" default="0">
+ Defines the scope of the parameter.
</member>
</members>
<constants>
<constant name="QUAL_NONE" value="0" enum="Qualifier">
+ The parameter will be tied to the [ShaderMaterial] using this shader.
</constant>
<constant name="QUAL_GLOBAL" value="1" enum="Qualifier">
+ The parameter will use a global value, defined in Project Settings.
</constant>
<constant name="QUAL_INSTANCE" value="2" enum="Qualifier">
+ The parameter will be tied to the node with attached [ShaderMaterial] using this shader.
</constant>
<constant name="QUAL_MAX" value="3" enum="Qualifier">
Represents the size of the [enum Qualifier] enum.
diff --git a/doc/classes/VisualShaderNodeParticleAccelerator.xml b/doc/classes/VisualShaderNodeParticleAccelerator.xml
index f26362b336..7a197dd8cb 100644
--- a/doc/classes/VisualShaderNodeParticleAccelerator.xml
+++ b/doc/classes/VisualShaderNodeParticleAccelerator.xml
@@ -1,21 +1,27 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeParticleAccelerator" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that accelerates particles.
</brief_description>
<description>
+ Particle accelerator can be used in "process" step of particle shader. It will accelerate the particles. Connect it to the Velocity output port.
</description>
<tutorials>
</tutorials>
<members>
<member name="mode" type="int" setter="set_mode" getter="get_mode" enum="VisualShaderNodeParticleAccelerator.Mode" default="0">
+ Defines in what manner the particles will be accelerated.
</member>
</members>
<constants>
<constant name="MODE_LINEAR" value="0" enum="Mode">
+ The particles will be accelerated based on their velocity.
</constant>
<constant name="MODE_RADIAL" value="1" enum="Mode">
+ The particles will be accelerated towards or away from the center.
</constant>
<constant name="MODE_TANGENTIAL" value="2" enum="Mode">
+ The particles will be accelerated tangentially to the radius vector from center to their position.
</constant>
<constant name="MODE_MAX" value="3" enum="Mode">
Represents the size of the [enum Mode] enum.
diff --git a/doc/classes/VisualShaderNodeParticleBoxEmitter.xml b/doc/classes/VisualShaderNodeParticleBoxEmitter.xml
index dbef4b806d..1bdb9d15bc 100644
--- a/doc/classes/VisualShaderNodeParticleBoxEmitter.xml
+++ b/doc/classes/VisualShaderNodeParticleBoxEmitter.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeParticleBoxEmitter" inherits="VisualShaderNodeParticleEmitter" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that makes particles emitted in a box shape.
</brief_description>
<description>
+ [VisualShaderNodeParticleEmitter] that makes the particles emitted in box shape with the specified extents.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeParticleConeVelocity.xml b/doc/classes/VisualShaderNodeParticleConeVelocity.xml
index c3b3621fbc..48da5b874b 100644
--- a/doc/classes/VisualShaderNodeParticleConeVelocity.xml
+++ b/doc/classes/VisualShaderNodeParticleConeVelocity.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeParticleConeVelocity" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that makes particles move in a cone shape.
</brief_description>
<description>
+ This node can be used in "start" step of particle shader. It defines the initial velocity of the particles, making them move in cone shape starting from the center, with a given spread.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeParticleEmit.xml b/doc/classes/VisualShaderNodeParticleEmit.xml
index c5e9d25ca1..3e52a74aed 100644
--- a/doc/classes/VisualShaderNodeParticleEmit.xml
+++ b/doc/classes/VisualShaderNodeParticleEmit.xml
@@ -1,25 +1,33 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeParticleEmit" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that forces to emit a particle from a sub-emitter.
</brief_description>
<description>
+ This node internally calls [code]emit_subparticle[/code] shader method. It will emit a particle from the configured sub-emitter and also allows to customize how its emitted. Requires a sub-emitter assigned to the particles node with this shader.
</description>
<tutorials>
</tutorials>
<members>
<member name="flags" type="int" setter="set_flags" getter="get_flags" enum="VisualShaderNodeParticleEmit.EmitFlags" default="31">
+ Flags used to override the properties defined in the sub-emitter's process material.
</member>
</members>
<constants>
<constant name="EMIT_FLAG_POSITION" value="1" enum="EmitFlags">
+ If enabled, the particle starts with the position defined by this node.
</constant>
<constant name="EMIT_FLAG_ROT_SCALE" value="2" enum="EmitFlags">
+ If enabled, the particle starts with the rotation and scale defined by this node.
</constant>
<constant name="EMIT_FLAG_VELOCITY" value="4" enum="EmitFlags">
+ If enabled,the particle starts with the velocity defined by this node.
</constant>
<constant name="EMIT_FLAG_COLOR" value="8" enum="EmitFlags">
+ If enabled, the particle starts with the color defined by this node.
</constant>
<constant name="EMIT_FLAG_CUSTOM" value="16" enum="EmitFlags">
+ If enabled, the particle starts with the [code]CUSTOM[/code] data defined by this node.
</constant>
</constants>
</class>
diff --git a/doc/classes/VisualShaderNodeParticleEmitter.xml b/doc/classes/VisualShaderNodeParticleEmitter.xml
index ddfd410708..abb5528d5f 100644
--- a/doc/classes/VisualShaderNodeParticleEmitter.xml
+++ b/doc/classes/VisualShaderNodeParticleEmitter.xml
@@ -4,6 +4,7 @@
A base class for particle emitters.
</brief_description>
<description>
+ Particle emitter nodes can be used in "start" step of particle shaders and they define the starting position of the particles. Connect them to the Position output port.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeParticleMeshEmitter.xml b/doc/classes/VisualShaderNodeParticleMeshEmitter.xml
index 25dd925112..59dc74690e 100644
--- a/doc/classes/VisualShaderNodeParticleMeshEmitter.xml
+++ b/doc/classes/VisualShaderNodeParticleMeshEmitter.xml
@@ -1,17 +1,22 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeParticleMeshEmitter" inherits="VisualShaderNodeParticleEmitter" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that makes particles emitted in a shape defined by a [Mesh].
</brief_description>
<description>
+ [VisualShaderNodeParticleEmitter] that makes the particles emitted in a shape of the assigned [member mesh]. It will emit from the mesh's surfaces, either all or only the specified one.
</description>
<tutorials>
</tutorials>
<members>
<member name="mesh" type="Mesh" setter="set_mesh" getter="get_mesh">
+ The [Mesh] that defines emission shape.
</member>
<member name="surface_index" type="int" setter="set_surface_index" getter="get_surface_index" default="0">
+ Index of the surface that emits particles. [member use_all_surfaces] must be [code]false[/code] for this to take effect.
</member>
<member name="use_all_surfaces" type="bool" setter="set_use_all_surfaces" getter="is_use_all_surfaces" default="true">
+ If [code]true[/code], the particles will emit from all surfaces of the mesh.
</member>
</members>
</class>
diff --git a/doc/classes/VisualShaderNodeParticleMultiplyByAxisAngle.xml b/doc/classes/VisualShaderNodeParticleMultiplyByAxisAngle.xml
index a911dbf3b4..95d031807b 100644
--- a/doc/classes/VisualShaderNodeParticleMultiplyByAxisAngle.xml
+++ b/doc/classes/VisualShaderNodeParticleMultiplyByAxisAngle.xml
@@ -1,13 +1,16 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeParticleMultiplyByAxisAngle" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader helper node for multiplying position and rotation of particles.
</brief_description>
<description>
+ This node helps to multiply a position input vector by rotation using specific axis. Intended to work with emitters.
</description>
<tutorials>
</tutorials>
<members>
<member name="degrees_mode" type="bool" setter="set_degrees_mode" getter="is_degrees_mode" default="true">
+ If [code]true[/code], the angle will be interpreted in degrees instead of radians.
</member>
</members>
</class>
diff --git a/doc/classes/VisualShaderNodeParticleOutput.xml b/doc/classes/VisualShaderNodeParticleOutput.xml
index 7542272e61..4a1e61b879 100644
--- a/doc/classes/VisualShaderNodeParticleOutput.xml
+++ b/doc/classes/VisualShaderNodeParticleOutput.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeParticleOutput" inherits="VisualShaderNodeOutput" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ Visual shader node that defines output values for particle emitting.
</brief_description>
<description>
+ This node defines how particles are emitted. It allows to customize e.g. position and velocity. Available ports are different depending on which function this node is inside (start, process, collision) and whether custom data is enabled.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeParticleRandomness.xml b/doc/classes/VisualShaderNodeParticleRandomness.xml
index a1f9ce040a..233e072246 100644
--- a/doc/classes/VisualShaderNodeParticleRandomness.xml
+++ b/doc/classes/VisualShaderNodeParticleRandomness.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeParticleRandomness" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ Visual shader node for randomizing particle values.
</brief_description>
<description>
+ Randomness node will output pseudo-random values of the given type based on the specified minimum and maximum values.
</description>
<tutorials>
</tutorials>
@@ -21,7 +23,10 @@
<constant name="OP_TYPE_VECTOR_3D" value="2" enum="OpType">
A 3D vector type.
</constant>
- <constant name="OP_TYPE_MAX" value="3" enum="OpType">
+ <constant name="OP_TYPE_VECTOR_4D" value="3" enum="OpType">
+ A 4D vector type.
+ </constant>
+ <constant name="OP_TYPE_MAX" value="4" enum="OpType">
Represents the size of the [enum OpType] enum.
</constant>
</constants>
diff --git a/doc/classes/VisualShaderNodeParticleRingEmitter.xml b/doc/classes/VisualShaderNodeParticleRingEmitter.xml
index bebce51d6b..e2ff44ed55 100644
--- a/doc/classes/VisualShaderNodeParticleRingEmitter.xml
+++ b/doc/classes/VisualShaderNodeParticleRingEmitter.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeParticleRingEmitter" inherits="VisualShaderNodeParticleEmitter" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that makes particles emitted in a ring shape.
</brief_description>
<description>
+ [VisualShaderNodeParticleEmitter] that makes the particles emitted in ring shape with the specified inner and outer radii and height.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeParticleSphereEmitter.xml b/doc/classes/VisualShaderNodeParticleSphereEmitter.xml
index ffbd384f1e..3d1e332c97 100644
--- a/doc/classes/VisualShaderNodeParticleSphereEmitter.xml
+++ b/doc/classes/VisualShaderNodeParticleSphereEmitter.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeParticleSphereEmitter" inherits="VisualShaderNodeParticleEmitter" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that makes particles emitted in a sphere shape.
</brief_description>
<description>
+ [VisualShaderNodeParticleEmitter] that makes the particles emitted in sphere shape with the specified inner and outer radii.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeProximityFade.xml b/doc/classes/VisualShaderNodeProximityFade.xml
index 25051eed71..8405fcef36 100644
--- a/doc/classes/VisualShaderNodeProximityFade.xml
+++ b/doc/classes/VisualShaderNodeProximityFade.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeProximityFade" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node representing proximity fade effect.
</brief_description>
<description>
+ The proximity fade effect fades out each pixel based on its distance to another object.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeRandomRange.xml b/doc/classes/VisualShaderNodeRandomRange.xml
index adc83d808c..e1a5e0b266 100644
--- a/doc/classes/VisualShaderNodeRandomRange.xml
+++ b/doc/classes/VisualShaderNodeRandomRange.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeRandomRange" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that generates a pseudo-random scalar.
</brief_description>
<description>
+ Random range node will output a pseudo-random scalar value in the specified range, based on the seed. The value is always the same for the given seed and range, so you should provide a changing input, e.g. by using time.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeRemap.xml b/doc/classes/VisualShaderNodeRemap.xml
index 5a73a76e7f..73512bcb99 100644
--- a/doc/classes/VisualShaderNodeRemap.xml
+++ b/doc/classes/VisualShaderNodeRemap.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeRemap" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node for remap function.
</brief_description>
<description>
+ Remap will transform the input range into output range, e.g. you can change a [code]0..1[/code] value to [code]-2..2[/code] etc. See [method @GlobalScope.remap] for more details.
</description>
<tutorials>
</tutorials>
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/VisualShaderNodeTexture.xml b/doc/classes/VisualShaderNodeTexture.xml
index 72a7fadf1a..38fa98b21e 100644
--- a/doc/classes/VisualShaderNodeTexture.xml
+++ b/doc/classes/VisualShaderNodeTexture.xml
@@ -33,12 +33,18 @@
Use the texture from this shader's normal map built-in.
</constant>
<constant name="SOURCE_DEPTH" value="4" enum="Source">
- Use the depth texture available for this shader.
+ Use the depth texture captured during the depth prepass. Only available when the depth prepass is used (i.e. in spatial shaders and in the forward_plus or gl_compatibility renderers).
</constant>
<constant name="SOURCE_PORT" value="5" enum="Source">
Use the texture provided in the input port for this function.
</constant>
- <constant name="SOURCE_MAX" value="6" enum="Source">
+ <constant name="SOURCE_3D_NORMAL" value="6" enum="Source">
+ Use the normal buffer captured during the depth prepass. Only available when the normal-roughness buffer is available (i.e. in spatial shaders and in the forward_plus renderer).
+ </constant>
+ <constant name="SOURCE_ROUGHNESS" value="7" enum="Source">
+ Use the roughness buffer captured during the depth prepass. Only available when the normal-roughness buffer is available (i.e. in spatial shaders and in the forward_plus renderer).
+ </constant>
+ <constant name="SOURCE_MAX" value="8" enum="Source">
Represents the size of the [enum Source] enum.
</constant>
<constant name="TYPE_DATA" value="0" enum="TextureType">
diff --git a/doc/classes/VisualShaderNodeTexture2DArrayParameter.xml b/doc/classes/VisualShaderNodeTexture2DArrayParameter.xml
index 2afaa8e219..885325bc6c 100644
--- a/doc/classes/VisualShaderNodeTexture2DArrayParameter.xml
+++ b/doc/classes/VisualShaderNodeTexture2DArrayParameter.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeTexture2DArrayParameter" inherits="VisualShaderNodeTextureParameter" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node for shader parameter (uniform) of type [Texture2DArray].
</brief_description>
<description>
+ This parameter allows to provide a collection of textures for the shader. You can use [VisualShaderNodeTexture2DArray] to extract the textures from array.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeTextureParameter.xml b/doc/classes/VisualShaderNodeTextureParameter.xml
index ad21c4e990..8a08bea659 100644
--- a/doc/classes/VisualShaderNodeTextureParameter.xml
+++ b/doc/classes/VisualShaderNodeTextureParameter.xml
@@ -18,6 +18,9 @@
<member name="texture_repeat" type="int" setter="set_texture_repeat" getter="get_texture_repeat" enum="VisualShaderNodeTextureParameter.TextureRepeat" default="0">
Sets the texture repeating mode. See [enum TextureRepeat] for options.
</member>
+ <member name="texture_source" type="int" setter="set_texture_source" getter="get_texture_source" enum="VisualShaderNodeTextureParameter.TextureSource" default="0">
+ Sets the texture source mode. Used for reading from the screen, depth, or normal_roughness texture. see [enum TextureSource] for options.
+ </member>
<member name="texture_type" type="int" setter="set_texture_type" getter="get_texture_type" enum="VisualShaderNodeTextureParameter.TextureType" default="0">
Defines the type of data provided by the source texture. See [enum TextureType] for options.
</member>
@@ -51,30 +54,57 @@
Represents the size of the [enum ColorDefault] enum.
</constant>
<constant name="FILTER_DEFAULT" value="0" enum="TextureFilter">
+ Sample the texture using the filter determined by the node this shader is attached to.
</constant>
<constant name="FILTER_NEAREST" value="1" enum="TextureFilter">
+ The texture filter reads from the nearest pixel only. The simplest and fastest method of filtering, but the texture will look pixelized.
</constant>
<constant name="FILTER_LINEAR" value="2" enum="TextureFilter">
+ The texture filter blends between the nearest four pixels. Use this for most cases where you want to avoid a pixelated style.
</constant>
<constant name="FILTER_NEAREST_MIPMAP" value="3" enum="TextureFilter">
+ The texture filter reads from the nearest pixel in the nearest mipmap. This is the fastest way to read from textures with mipmaps.
</constant>
<constant name="FILTER_LINEAR_MIPMAP" value="4" enum="TextureFilter">
+ The texture filter blends between the nearest 4 pixels and between the nearest 2 mipmaps. Use this for non-pixel art textures that may be viewed at a low scale (e.g. due to [Camera2D] zoom), as mipmaps are important to smooth out pixels that are smaller than on-screen pixels.
</constant>
<constant name="FILTER_NEAREST_MIPMAP_ANISOTROPIC" value="5" enum="TextureFilter">
+ The texture filter reads from the nearest pixel, but selects a mipmap based on the angle between the surface and the camera view. This reduces artifacts on surfaces that are almost in line with the camera. The anisotropic filtering level can be changed by adjusting [member ProjectSettings.rendering/textures/default_filters/anisotropic_filtering_level].
+ [b]Note:[/b] This texture filter is rarely useful in 2D projects. [constant FILTER_LINEAR_MIPMAP] is usually more appropriate.
</constant>
<constant name="FILTER_LINEAR_MIPMAP_ANISOTROPIC" value="6" enum="TextureFilter">
+ The texture filter blends between the nearest 4 pixels and selects a mipmap based on the angle between the surface and the camera view. This reduces artifacts on surfaces that are almost in line with the camera. This is the slowest of the filtering options, but results in the highest quality texturing. The anisotropic filtering level can be changed by adjusting [member ProjectSettings.rendering/textures/default_filters/anisotropic_filtering_level].
+ [b]Note:[/b] This texture filter is rarely useful in 2D projects. [constant FILTER_LINEAR_MIPMAP] is usually more appropriate.
</constant>
<constant name="FILTER_MAX" value="7" enum="TextureFilter">
Represents the size of the [enum TextureFilter] enum.
</constant>
<constant name="REPEAT_DEFAULT" value="0" enum="TextureRepeat">
+ Sample the texture using the repeat mode determined by the node this shader is attached to.
</constant>
<constant name="REPEAT_ENABLED" value="1" enum="TextureRepeat">
+ Texture will repeat normally.
</constant>
<constant name="REPEAT_DISABLED" value="2" enum="TextureRepeat">
+ Texture will not repeat.
</constant>
<constant name="REPEAT_MAX" value="3" enum="TextureRepeat">
Represents the size of the [enum TextureRepeat] enum.
</constant>
+ <constant name="SOURCE_NONE" value="0" enum="TextureSource">
+ The texture source is not specified in the shader.
+ </constant>
+ <constant name="SOURCE_SCREEN" value="1" enum="TextureSource">
+ The texture source is the screen texture which captures all opaque objects drawn this frame.
+ </constant>
+ <constant name="SOURCE_DEPTH" value="2" enum="TextureSource">
+ The texture source is the depth texture from the depth prepass.
+ </constant>
+ <constant name="SOURCE_NORMAL_ROUGHNESS" value="3" enum="TextureSource">
+ The texture source is the normal-roughness buffer from the depth prepass.
+ </constant>
+ <constant name="SOURCE_MAX" value="4" enum="TextureSource">
+ Represents the size of the [enum TextureSource] enum.
+ </constant>
</constants>
</class>
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..4c95e58962
--- /dev/null
+++ b/doc/classes/VisualShaderNodeUIntParameter.xml
@@ -0,0 +1,19 @@
+<?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>
+ A visual shader node for shader parameter (uniform) of type unsigned [int].
+ </brief_description>
+ <description>
+ A [VisualShaderNodeParameter] of type unsigned [int]. Offers additional customization for range of accepted values.
+ </description>
+ <tutorials>
+ </tutorials>
+ <members>
+ <member name="default_value" type="int" setter="set_default_value" getter="get_default_value" default="0">
+ Default value of this parameter, which will be used if not set externally. [member default_value_enabled] must be enabled; defaults to [code]0[/code] otherwise.
+ </member>
+ <member name="default_value_enabled" type="bool" setter="set_default_value_enabled" getter="is_default_value_enabled" default="false">
+ If [code]true[/code], the node will have a custom default value.
+ </member>
+ </members>
+</class>
diff --git a/doc/classes/VisualShaderNodeUVFunc.xml b/doc/classes/VisualShaderNodeUVFunc.xml
index 541991b790..b5143b647c 100644
--- a/doc/classes/VisualShaderNodeUVFunc.xml
+++ b/doc/classes/VisualShaderNodeUVFunc.xml
@@ -4,6 +4,7 @@
Contains functions to modify texture coordinates ([code]uv[/code]) to be used within the visual shader graph.
</brief_description>
<description>
+ UV functions are similar to [Vector2] functions, but the input port of this node uses the shader's UV value by default.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeUVPolarCoord.xml b/doc/classes/VisualShaderNodeUVPolarCoord.xml
index 8582939db3..49f7f52bc1 100644
--- a/doc/classes/VisualShaderNodeUVPolarCoord.xml
+++ b/doc/classes/VisualShaderNodeUVPolarCoord.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeUVPolarCoord" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that modifies the texture UV using polar coordinates.
</brief_description>
<description>
+ UV polar coord node will transform UV values into polar coordinates, with specified scale, zoom strength and repeat parameters. It can be used to create various swirl distortions.
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeVarying.xml b/doc/classes/VisualShaderNodeVarying.xml
index 0dbbd61f3a..0a5c5a70af 100644
--- a/doc/classes/VisualShaderNodeVarying.xml
+++ b/doc/classes/VisualShaderNodeVarying.xml
@@ -1,15 +1,19 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeVarying" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that represents a "varying" shader value.
</brief_description>
<description>
+ Varying values are shader variables that can be passed between shader functions, e.g. from Vertex shader to Fragment shader.
</description>
<tutorials>
</tutorials>
<members>
<member name="varying_name" type="String" setter="set_varying_name" getter="get_varying_name" default="&quot;[None]&quot;">
+ Name of the variable. Must be unique.
</member>
<member name="varying_type" type="int" setter="set_varying_type" getter="get_varying_type" enum="VisualShader.VaryingType" default="0">
+ Type of the variable. Determines where the variable can be accessed.
</member>
</members>
</class>
diff --git a/doc/classes/VisualShaderNodeVaryingGetter.xml b/doc/classes/VisualShaderNodeVaryingGetter.xml
index de30b18d67..dea47ed3c1 100644
--- a/doc/classes/VisualShaderNodeVaryingGetter.xml
+++ b/doc/classes/VisualShaderNodeVaryingGetter.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeVaryingGetter" inherits="VisualShaderNodeVarying" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that gets a value of a varying.
</brief_description>
<description>
+ Outputs a value of a varying defined in the shader. You need to first create a varying that can be used in the given function, e.g. varying getter in Fragment shader requires a varying with mode set to [constant VisualShader.VARYING_MODE_VERTEX_TO_FRAG_LIGHT].
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeVaryingSetter.xml b/doc/classes/VisualShaderNodeVaryingSetter.xml
index 57ead3d82b..b305fdd3ef 100644
--- a/doc/classes/VisualShaderNodeVaryingSetter.xml
+++ b/doc/classes/VisualShaderNodeVaryingSetter.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeVaryingSetter" inherits="VisualShaderNodeVarying" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
+ A visual shader node that sets a value of a varying.
</brief_description>
<description>
+ Inputs a value to a varying defined in the shader. You need to first create a varying that can be used in the given function, e.g. varying setter in Fragment shader requires a varying with mode set to [constant VisualShader.VARYING_MODE_FRAG_TO_LIGHT].
</description>
<tutorials>
</tutorials>
diff --git a/doc/classes/VisualShaderNodeVectorBase.xml b/doc/classes/VisualShaderNodeVectorBase.xml
index d9c9f2d79c..68cf00e819 100644
--- a/doc/classes/VisualShaderNodeVectorBase.xml
+++ b/doc/classes/VisualShaderNodeVectorBase.xml
@@ -1,15 +1,16 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VisualShaderNodeVectorBase" inherits="VisualShaderNode" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
- A base type for the nodes using different vector types within the visual shader graph.
+ A base type for the nodes that perform vector operations within the visual shader graph.
</brief_description>
<description>
+ This is an abstract class. See the derived types for descriptions of the possible operations.
</description>
<tutorials>
</tutorials>
<members>
<member name="op_type" type="int" setter="set_op_type" getter="get_op_type" enum="VisualShaderNodeVectorBase.OpType" default="1">
- A base type.
+ A vector type that this operation is performed on.
</member>
</members>
<constants>
diff --git a/doc/classes/VoxelGI.xml b/doc/classes/VoxelGI.xml
index 394611b78f..4347c5845f 100644
--- a/doc/classes/VoxelGI.xml
+++ b/doc/classes/VoxelGI.xml
@@ -38,9 +38,9 @@
<member name="data" type="VoxelGIData" setter="set_probe_data" getter="get_probe_data">
The [VoxelGIData] resource that holds the data for this [VoxelGI].
</member>
- <member name="extents" type="Vector3" setter="set_extents" getter="get_extents" default="Vector3(10, 10, 10)">
- The size of the area covered by the [VoxelGI]. If you make the extents larger without increasing the subdivisions with [member subdiv], the size of each cell will increase and result in lower detailed lighting.
- [b]Note:[/b] Extents are clamped to 1.0 unit or more on each axis.
+ <member name="size" type="Vector3" setter="set_size" getter="get_size" default="Vector3(20, 20, 20)">
+ The size of the area covered by the [VoxelGI]. If you make the size larger without increasing the subdivisions with [member subdiv], the size of each cell will increase and result in lower detailed lighting.
+ [b]Note:[/b] Size is clamped to 1.0 unit or more on each axis.
</member>
<member name="subdiv" type="int" setter="set_subdiv" getter="get_subdiv" enum="VoxelGI.Subdiv" default="1">
Number of times to subdivide the grid that the [VoxelGI] operates on. A higher number results in finer detail and thus higher visual quality, while lower numbers result in better performance.
diff --git a/doc/classes/VoxelGIData.xml b/doc/classes/VoxelGIData.xml
index bd9df18394..541a3bc4a6 100644
--- a/doc/classes/VoxelGIData.xml
+++ b/doc/classes/VoxelGIData.xml
@@ -26,8 +26,8 @@
<method name="get_bounds" qualifiers="const">
<return type="AABB" />
<description>
- Returns the bounds of the baked voxel data as an [AABB], which should match [member VoxelGI.extents] after being baked (which only contains the size as a [Vector3]).
- [b]Note:[/b] If the extents were modified without baking the VoxelGI data, then the value of [method get_bounds] and [member VoxelGI.extents] will not match.
+ Returns the bounds of the baked voxel data as an [AABB], which should match [member VoxelGI.size] after being baked (which only contains the size as a [Vector3]).
+ [b]Note:[/b] If the size was modified without baking the VoxelGI data, then the value of [method get_bounds] and [member VoxelGI.size] will not match.
</description>
</method>
<method name="get_data_cells" qualifiers="const">
diff --git a/doc/classes/Window.xml b/doc/classes/Window.xml
index 16ca486e4a..14e705a7e6 100644
--- a/doc/classes/Window.xml
+++ b/doc/classes/Window.xml
@@ -503,7 +503,7 @@
<member name="content_scale_size" type="Vector2i" setter="set_content_scale_size" getter="get_content_scale_size" default="Vector2i(0, 0)">
Base size of the content (i.e. nodes that are drawn inside the window). If non-zero, [Window]'s content will be scaled when the window is resized to a different size.
</member>
- <member name="current_screen" type="int" setter="set_current_screen" getter="get_current_screen" default="0">
+ <member name="current_screen" type="int" setter="set_current_screen" getter="get_current_screen">
The screen the window is currently on.
</member>
<member name="exclusive" type="bool" setter="set_exclusive" getter="is_exclusive" default="false">
@@ -513,6 +513,8 @@
<member name="extend_to_title" type="bool" setter="set_flag" getter="get_flag" default="false">
If [code]true[/code], the [Window] contents is expanded to the full size of the window, window title bar is transparent.
</member>
+ <member name="initial_position" type="int" setter="set_initial_position" getter="get_initial_position" enum="Window.WindowInitialPosition" default="0">
+ </member>
<member name="max_size" type="Vector2i" setter="set_max_size" getter="get_max_size" default="Vector2i(0, 0)">
If non-zero, the [Window] can't be resized to be bigger than this size.
[b]Note:[/b] This property will be ignored if the value is lower than [member min_size].
@@ -525,6 +527,39 @@
Set's the window's current mode.
[b]Note:[/b] Fullscreen mode is not exclusive full screen on Windows and Linux.
</member>
+ <member name="mouse_passthrough" type="bool" setter="set_flag" getter="get_flag" default="false">
+ If [code]true[/code], all mouse event as passed to the underlying window of the same application. See also [member mouse_passthrough_polygon].
+ [b]Note:[/b] This property is implemented on Linux (X11), macOS and Windows.
+ </member>
+ <member name="mouse_passthrough_polygon" type="PackedVector2Array" setter="set_mouse_passthrough_polygon" getter="get_mouse_passthrough_polygon" default="PackedVector2Array()">
+ Sets a polygonal region of the window which accepts mouse events. Mouse events outside the region will be passed through.
+ Passing an empty array will disable passthrough support (all mouse events will be intercepted by the window, which is the default behavior).
+ [codeblocks]
+ [gdscript]
+ # Set region, using Path2D node.
+ $Window.mouse_passthrough_polygon = $Path2D.curve.get_baked_points()
+
+ # Set region, using Polygon2D node.
+ $Window.mouse_passthrough_polygon = $Polygon2D.polygon
+
+ # Reset region to default.
+ $Window.mouse_passthrough_polygon = []
+ [/gdscript]
+ [csharp]
+ // Set region, using Path2D node.
+ GetNode&lt;Window&gt;("Window").MousePassthrough = GetNode&lt;Path2D&gt;("Path2D").Curve.GetBakedPoints();
+
+ // Set region, using Polygon2D node.
+ GetNode&lt;Window&gt;("Window").MousePassthrough = GetNode&lt;Polygon2D&gt;("Polygon2D").Polygon;
+
+ // Reset region to default.
+ GetNode&lt;Window&gt;("Window").MousePassthrough = new Vector2[] {};
+ [/csharp]
+ [/codeblocks]
+ [b]Note:[/b] This property is ignored if [member mouse_passthrough] is set to [code]true[/code].
+ [b]Note:[/b] On Windows, the portion of a window that lies outside the region is not drawn, while on Linux (X11) and macOS it is.
+ [b]Note:[/b] This property is implemented on Linux (X11), macOS and Windows.
+ </member>
<member name="popup_window" type="bool" setter="set_flag" getter="get_flag" default="false">
If [code]true[/code], the [Window] will be considered a popup. Popups are sub-windows that don't show as separate windows in system's window manager's window list and will send close request when anything is clicked outside of them (unless [member exclusive] is enabled).
</member>
@@ -579,6 +614,12 @@
This signal can be used to handle window closing, e.g. by connecting it to [method hide].
</description>
</signal>
+ <signal name="dpi_changed">
+ <description>
+ Emitted when the [Window]'s DPI changes as a result of OS-level changes (e.g. moving the window from a Retina display to a lower resolution one).
+ [b]Note:[/b] Only implemented on macOS.
+ </description>
+ </signal>
<signal name="files_dropped">
<param index="0" name="files" type="PackedStringArray" />
<description>
@@ -693,7 +734,10 @@
Window content is expanded to the full size of the window. Unlike borderless window, the frame is left intact and can be used to resize the window, title bar is transparent, but have minimize/maximize/close buttons. Set with [member extend_to_title].
[b]Note:[/b] This flag is implemented on macOS.
</constant>
- <constant name="FLAG_MAX" value="7" enum="Flags">
+ <constant name="FLAG_MOUSE_PASSTHROUGH" value="7" enum="Flags">
+ All mouse events are passed to the underlying window of the same application.
+ </constant>
+ <constant name="FLAG_MAX" value="8" enum="Flags">
Max value of the [enum Flags].
</constant>
<constant name="CONTENT_SCALE_MODE_DISABLED" value="0" enum="ContentScaleMode">
@@ -732,6 +776,18 @@
<constant name="LAYOUT_DIRECTION_RTL" value="3" enum="LayoutDirection">
Right-to-left layout direction.
</constant>
+ <constant name="WINDOW_INITIAL_POSITION_ABSOLUTE" value="0" enum="WindowInitialPosition">
+ Initial window position is determined by [member position].
+ </constant>
+ <constant name="WINDOW_INITIAL_POSITION_CENTER_PRIMARY_SCREEN" value="1" enum="WindowInitialPosition">
+ Initial window position is a center of the primary screen.
+ </constant>
+ <constant name="WINDOW_INITIAL_POSITION_CENTER_MAIN_WINDOW_SCREEN" value="2" enum="WindowInitialPosition">
+ Initial window position is a center of the main window screen.
+ </constant>
+ <constant name="WINDOW_INITIAL_POSITION_CENTER_OTHER_SCREEN" value="3" enum="WindowInitialPosition">
+ Initial window position is a center of [member current_screen] screen.
+ </constant>
</constants>
<theme_items>
<theme_item name="title_color" data_type="color" type="Color" default="Color(0.875, 0.875, 0.875, 1)">
diff --git a/doc/classes/XRController3D.xml b/doc/classes/XRController3D.xml
index 9e192177e5..0b21002893 100644
--- a/doc/classes/XRController3D.xml
+++ b/doc/classes/XRController3D.xml
@@ -13,11 +13,18 @@
<link title="XR documentation index">$DOCS_URL/tutorials/xr/index.html</link>
</tutorials>
<methods>
- <method name="get_axis" qualifiers="const">
- <return type="Vector2" />
+ <method name="get_float" qualifiers="const">
+ <return type="float" />
<param index="0" name="name" type="StringName" />
<description>
- Returns a [Vector2] for the input with the given [param name]. This is used for thumbsticks and thumbpads found on many controllers.
+ Returns a numeric value for the input with the given [param name]. This is used for triggers and grip sensors.
+ </description>
+ </method>
+ <method name="get_input" qualifiers="const">
+ <return type="Variant" />
+ <param index="0" name="name" type="StringName" />
+ <description>
+ Returns a [Variant] for the input with the given [param name]. This works for any input type, the variant will be typed according to the actions configuration.
</description>
</method>
<method name="get_tracker_hand" qualifiers="const">
@@ -26,11 +33,11 @@
Returns the hand holding this controller, if known. See [enum XRPositionalTracker.TrackerHand].
</description>
</method>
- <method name="get_value" qualifiers="const">
- <return type="float" />
+ <method name="get_vector2" qualifiers="const">
+ <return type="Vector2" />
<param index="0" name="name" type="StringName" />
<description>
- Returns a numeric value for the input with the given [param name]. This is used for triggers and grip sensors.
+ Returns a [Vector2] for the input with the given [param name]. This is used for thumbsticks and thumbpads found on many controllers.
</description>
</method>
<method name="is_button_pressed" qualifiers="const">
@@ -54,18 +61,18 @@
Emitted when a button on this controller is released.
</description>
</signal>
- <signal name="input_axis_changed">
+ <signal name="input_float_changed">
<param index="0" name="name" type="String" />
- <param index="1" name="value" type="Vector2" />
+ <param index="1" name="value" type="float" />
<description>
- Emitted when a thumbstick or thumbpad on this controller is moved.
+ Emitted when a trigger or similar input on this controller changes value.
</description>
</signal>
- <signal name="input_value_changed">
+ <signal name="input_vector2_changed">
<param index="0" name="name" type="String" />
- <param index="1" name="value" type="float" />
+ <param index="1" name="value" type="Vector2" />
<description>
- Emitted when a trigger or similar input on this controller changes value.
+ Emitted when a thumbstick or thumbpad on this controller is moved.
</description>
</signal>
</signals>
diff --git a/doc/classes/XRInterfaceExtension.xml b/doc/classes/XRInterfaceExtension.xml
index 5ad67a7ea9..b74ac1e469 100644
--- a/doc/classes/XRInterfaceExtension.xml
+++ b/doc/classes/XRInterfaceExtension.xml
@@ -64,7 +64,7 @@
</description>
</method>
<method name="_get_play_area_mode" qualifiers="virtual const">
- <return type="int" />
+ <return type="int" enum="XRInterface.PlayAreaMode" />
<description>
Returns the [enum XRInterface.PlayAreaMode] that sets up our play area.
</description>
@@ -99,7 +99,7 @@
</description>
</method>
<method name="_get_tracking_status" qualifiers="virtual const">
- <return type="int" />
+ <return type="int" enum="XRInterface.TrackingStatus" />
<description>
Returns a [enum XRInterface.TrackingStatus] specifying the current status of our tracking.
</description>
@@ -177,7 +177,7 @@
</method>
<method name="_set_play_area_mode" qualifiers="virtual const">
<return type="bool" />
- <param index="0" name="mode" type="int" />
+ <param index="0" name="mode" type="int" enum="XRInterface.PlayAreaMode" />
<description>
Set the play area mode for this interface.
</description>
diff --git a/doc/classes/XRPositionalTracker.xml b/doc/classes/XRPositionalTracker.xml
index db2910f25e..93e6a5497c 100644
--- a/doc/classes/XRPositionalTracker.xml
+++ b/doc/classes/XRPositionalTracker.xml
@@ -92,18 +92,18 @@
Emitted when a button on this tracker is released.
</description>
</signal>
- <signal name="input_axis_changed">
+ <signal name="input_float_changed">
<param index="0" name="name" type="String" />
- <param index="1" name="vector" type="Vector2" />
+ <param index="1" name="value" type="float" />
<description>
- Emitted when a thumbstick or thumbpad on this tracker moves.
+ Emitted when a trigger or similar input on this tracker changes value.
</description>
</signal>
- <signal name="input_value_changed">
+ <signal name="input_vector2_changed">
<param index="0" name="name" type="String" />
- <param index="1" name="value" type="float" />
+ <param index="1" name="vector" type="Vector2" />
<description>
- Emitted when a trigger or similar input on this tracker changes value.
+ Emitted when a thumbstick or thumbpad on this tracker moves.
</description>
</signal>
<signal name="pose_changed">
diff --git a/doc/classes/bool.xml b/doc/classes/bool.xml
index d0ef664281..e1a98f0ea4 100644
--- a/doc/classes/bool.xml
+++ b/doc/classes/bool.xml
@@ -60,7 +60,7 @@
_can_shoot = false
_cool_down.start()
- func _on_CoolDownTimer_timeout():
+ func _on_cool_down_timer_timeout():
_can_shoot = true
[/gdscript]
[csharp]
diff --git a/doc/translations/ar.po b/doc/translations/ar.po
index 751017b573..eb8e6dc7b6 100644
--- a/doc/translations/ar.po
+++ b/doc/translations/ar.po
@@ -30107,7 +30107,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/ca.po b/doc/translations/ca.po
index 1552c15271..cce60f13ac 100644
--- a/doc/translations/ca.po
+++ b/doc/translations/ca.po
@@ -30023,7 +30023,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/classes.pot b/doc/translations/classes.pot
index 40ab5e3413..3c793335e2 100644
--- a/doc/translations/classes.pot
+++ b/doc/translations/classes.pot
@@ -1,6 +1,6 @@
# LANGUAGE translation of the Godot Engine class reference.
-# Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur.
-# Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md).
+# Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md).
+# Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.
# This file is distributed under the same license as the Godot source code.
#
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
@@ -29900,7 +29900,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/cs.po b/doc/translations/cs.po
index 1bd920e19b..b2072217a1 100644
--- a/doc/translations/cs.po
+++ b/doc/translations/cs.po
@@ -30498,7 +30498,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/de.po b/doc/translations/de.po
index 1533aa651d..14d2291f8c 100644
--- a/doc/translations/de.po
+++ b/doc/translations/de.po
@@ -33701,7 +33701,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/el.po b/doc/translations/el.po
index 13c4fbfe68..63ddea8f7b 100644
--- a/doc/translations/el.po
+++ b/doc/translations/el.po
@@ -29951,7 +29951,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/es.po b/doc/translations/es.po
index 8ed223238d..9462004570 100644
--- a/doc/translations/es.po
+++ b/doc/translations/es.po
@@ -39,12 +39,13 @@
# Keyla Arroyos <keylaarroyos@protonmail.com>, 2022.
# Victor Stancioiu <victorstancioiu@gmail.com>, 2022.
# yohanger <yohangerariel@gmail.com>, 2022.
+# Mateo <mfdez920@gmail.com>, 2023.
msgid ""
msgstr ""
"Project-Id-Version: Godot Engine class reference\n"
"Report-Msgid-Bugs-To: https://github.com/godotengine/godot\n"
-"PO-Revision-Date: 2022-11-29 20:23+0000\n"
-"Last-Translator: yohanger <yohangerariel@gmail.com>\n"
+"PO-Revision-Date: 2023-01-12 06:06+0000\n"
+"Last-Translator: Mateo <mfdez920@gmail.com>\n"
"Language-Team: Spanish <https://hosted.weblate.org/projects/godot-engine/"
"godot-class-reference/es/>\n"
"Language: es\n"
@@ -52,7 +53,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8-bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
-"X-Generator: Weblate 4.15-dev\n"
+"X-Generator: Weblate 4.15.1-dev\n"
#: doc/tools/make_rst.py
msgid "Description"
@@ -751,7 +752,6 @@ msgstr ""
"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
-#, fuzzy
msgid ""
"Returns an array of dictionaries representing the current call stack. See "
"also [method print_stack].\n"
@@ -776,7 +776,7 @@ msgid ""
"projects exported in debug mode if not connected to a debugging server."
msgstr ""
"Devuelve un conjunto de diccionarios que representan la pila de llamadas "
-"actual.\n"
+"actual. Véase también [method print_stack].\n"
"[codeblock]\n"
"func _ready():\n"
" foo()\n"
@@ -39560,6 +39560,7 @@ msgid ""
msgstr ""
#: doc/classes/Input.xml
+#, fuzzy
msgid ""
"Sets a custom mouse cursor image, which is only visible inside the game "
"window. The hotspot can also be specified. Passing [code]null[/code] to the "
@@ -39571,7 +39572,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
"Establece una imagen personalizada del cursor del ratón, que sólo es visible "
"dentro de la ventana del juego. También se puede especificar el punto de "
diff --git a/doc/translations/et.po b/doc/translations/et.po
index 7f92671d8f..b7512b6ae5 100644
--- a/doc/translations/et.po
+++ b/doc/translations/et.po
@@ -29913,7 +29913,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/extract.py b/doc/translations/extract.py
index ce645436d9..79c121245e 100644
--- a/doc/translations/extract.py
+++ b/doc/translations/extract.py
@@ -8,8 +8,8 @@ from collections import OrderedDict
EXTRACT_TAGS = ["description", "brief_description", "member", "constant", "theme_item", "link"]
HEADER = """\
# LANGUAGE translation of the Godot Engine class reference.
-# Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur.
-# Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md).
+# Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md).
+# Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.
# This file is distributed under the same license as the Godot source code.
#
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
diff --git a/doc/translations/fa.po b/doc/translations/fa.po
index 787c7ff937..ce5dd6b0c2 100644
--- a/doc/translations/fa.po
+++ b/doc/translations/fa.po
@@ -30352,7 +30352,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/fi.po b/doc/translations/fi.po
index fc517a6ff5..0f19296424 100644
--- a/doc/translations/fi.po
+++ b/doc/translations/fi.po
@@ -30034,7 +30034,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/fil.po b/doc/translations/fil.po
index 749fea9ef9..bfa8c75c7a 100644
--- a/doc/translations/fil.po
+++ b/doc/translations/fil.po
@@ -29919,7 +29919,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/fr.po b/doc/translations/fr.po
index 2898e9ec19..a57c138429 100644
--- a/doc/translations/fr.po
+++ b/doc/translations/fr.po
@@ -60,13 +60,14 @@
# Augustin Ambiehl <ambiehlaugustin@gmail.com>, 2022.
# Landry Simo <landrysimo99@gmail.com>, 2022.
# Alexis Coudert <coudert.alex@gmail.com>, 2022.
+# Callim Ethee <callimethee@gmail.com>, 2023.
msgid ""
msgstr ""
"Project-Id-Version: Godot Engine class reference\n"
"Report-Msgid-Bugs-To: https://github.com/godotengine/godot\n"
"POT-Creation-Date: \n"
-"PO-Revision-Date: 2022-12-03 00:47+0000\n"
-"Last-Translator: Alexis Coudert <coudert.alex@gmail.com>\n"
+"PO-Revision-Date: 2023-01-01 02:51+0000\n"
+"Last-Translator: Callim Ethee <callimethee@gmail.com>\n"
"Language-Team: French <https://hosted.weblate.org/projects/godot-engine/"
"godot-class-reference/fr/>\n"
"Language: fr\n"
@@ -74,7 +75,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n > 1;\n"
-"X-Generator: Weblate 4.15-dev\n"
+"X-Generator: Weblate 4.15.1-dev\n"
#: doc/tools/make_rst.py
msgid "Description"
@@ -137,9 +138,8 @@ msgid "Default"
msgstr "Défaut"
#: doc/tools/make_rst.py
-#, fuzzy
msgid "Setter"
-msgstr "Setter"
+msgstr "Donneur"
#: doc/tools/make_rst.py
msgid "value"
@@ -39456,7 +39456,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/gl.po b/doc/translations/gl.po
index 67bd7d902f..9b3ea41370 100644
--- a/doc/translations/gl.po
+++ b/doc/translations/gl.po
@@ -29908,7 +29908,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/hi.po b/doc/translations/hi.po
index 75318a4554..ca1ba04874 100644
--- a/doc/translations/hi.po
+++ b/doc/translations/hi.po
@@ -29907,7 +29907,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/hu.po b/doc/translations/hu.po
index e99babd548..f5a053dfc9 100644
--- a/doc/translations/hu.po
+++ b/doc/translations/hu.po
@@ -29927,7 +29927,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/id.po b/doc/translations/id.po
index ad63a828e5..8a1e757105 100644
--- a/doc/translations/id.po
+++ b/doc/translations/id.po
@@ -30324,7 +30324,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/is.po b/doc/translations/is.po
index 6bf49858f4..0afd2be589 100644
--- a/doc/translations/is.po
+++ b/doc/translations/is.po
@@ -29907,7 +29907,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/it.po b/doc/translations/it.po
index 37488c9ebd..35ff1ac6f3 100644
--- a/doc/translations/it.po
+++ b/doc/translations/it.po
@@ -31127,7 +31127,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/ja.po b/doc/translations/ja.po
index cabf1da54a..2798995dfa 100644
--- a/doc/translations/ja.po
+++ b/doc/translations/ja.po
@@ -33191,7 +33191,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/ko.po b/doc/translations/ko.po
index 72a7780a4c..3b3137f849 100644
--- a/doc/translations/ko.po
+++ b/doc/translations/ko.po
@@ -19,12 +19,13 @@
# ì´ì§€ë¯¼ <jiminaleejung@gmail.com>, 2022.
# nulltable <un5450@naver.com>, 2022.
# Godoto <aicompose@gmail.com>, 2022.
+# 오지훈 <jule1130@naver.com>, 2023.
msgid ""
msgstr ""
"Project-Id-Version: Godot Engine class reference\n"
"Report-Msgid-Bugs-To: https://github.com/godotengine/godot\n"
-"PO-Revision-Date: 2022-10-18 18:00+0000\n"
-"Last-Translator: Godoto <aicompose@gmail.com>\n"
+"PO-Revision-Date: 2023-01-19 14:47+0000\n"
+"Last-Translator: 오지훈 <jule1130@naver.com>\n"
"Language-Team: Korean <https://hosted.weblate.org/projects/godot-engine/"
"godot-class-reference/ko/>\n"
"Language: ko\n"
@@ -32,11 +33,11 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8-bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
-"X-Generator: Weblate 4.15-dev\n"
+"X-Generator: Weblate 4.15.1\n"
#: doc/tools/make_rst.py
msgid "Description"
-msgstr "서술"
+msgstr "설명"
#: doc/tools/make_rst.py
msgid "Tutorials"
@@ -30234,7 +30235,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/lt.po b/doc/translations/lt.po
index 1cf0ffef48..c52d238af9 100644
--- a/doc/translations/lt.po
+++ b/doc/translations/lt.po
@@ -29917,7 +29917,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/lv.po b/doc/translations/lv.po
index fd9ddf6f51..bf5aa78341 100644
--- a/doc/translations/lv.po
+++ b/doc/translations/lv.po
@@ -29925,7 +29925,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/mr.po b/doc/translations/mr.po
index 19db2e5f94..71013cc0e7 100644
--- a/doc/translations/mr.po
+++ b/doc/translations/mr.po
@@ -29905,7 +29905,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/nb.po b/doc/translations/nb.po
index 3b7f482e48..6431d1756d 100644
--- a/doc/translations/nb.po
+++ b/doc/translations/nb.po
@@ -29917,7 +29917,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/ne.po b/doc/translations/ne.po
index c616f7b4e1..b043d7c5af 100644
--- a/doc/translations/ne.po
+++ b/doc/translations/ne.po
@@ -29905,7 +29905,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/nl.po b/doc/translations/nl.po
index cf40d032cf..de3a4a7497 100644
--- a/doc/translations/nl.po
+++ b/doc/translations/nl.po
@@ -29978,7 +29978,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/pl.po b/doc/translations/pl.po
index cd2bedd302..a5c59f489b 100644
--- a/doc/translations/pl.po
+++ b/doc/translations/pl.po
@@ -30529,7 +30529,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/pt.po b/doc/translations/pt.po
index d3d9b9aadf..0f7b9f54e3 100644
--- a/doc/translations/pt.po
+++ b/doc/translations/pt.po
@@ -4,7 +4,7 @@
# This file is distributed under the same license as the Godot source code.
#
# Reubens Sanders <reubensst@protonmail.com>, 2021.
-# ssantos <ssantos@web.de>, 2022.
+# ssantos <ssantos@web.de>, 2022, 2023.
# Felipe SiFa <felipe@logus.digital>, 2022.
# Renu <ifpilucas@gmail.com>, 2022.
# Diogo Gomes <dgomes@graphnode.com>, 2022.
@@ -18,7 +18,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Godot Engine class reference\n"
"Report-Msgid-Bugs-To: https://github.com/godotengine/godot\n"
-"PO-Revision-Date: 2022-11-18 16:48+0000\n"
+"PO-Revision-Date: 2023-01-11 16:51+0000\n"
"Last-Translator: ssantos <ssantos@web.de>\n"
"Language-Team: Portuguese <https://hosted.weblate.org/projects/godot-engine/"
"godot-class-reference/pt/>\n"
@@ -27,7 +27,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8-bit\n"
"Plural-Forms: nplurals=2; plural=n > 1;\n"
-"X-Generator: Weblate 4.15-dev\n"
+"X-Generator: Weblate 4.15.1-dev\n"
#: doc/tools/make_rst.py
msgid "Description"
@@ -394,8 +394,8 @@ msgid ""
"[/codeblock]\n"
"This is the inverse of [method ord]."
msgstr ""
-"Retorna um caractere como uma String de um dado code point Unicode (que é "
-"compatível com ASCII code);\n"
+"Retorna um caractere como uma cadeia de caracteres de um dado code point "
+"Unicode (compatível com ASCII code);\n"
"[codeblock]\n"
"a = char(65) # a é \"A\"\n"
"a = char(65 + 32) # a é \"a\"\n"
@@ -517,15 +517,15 @@ msgid ""
"want a true content-aware comparison, you have to use [code]deep_equal[/"
"code]."
msgstr ""
-"Compara dois valores verificando seu conteúdo real, por meio de recursão em "
-"um [Array] ou [Dictionary] em todos os seus níveis.\n"
-"Esta função se asemelha ou difere de [code]==[/code] de diversas maneiras:\n"
+"Compara dois valores verificando o conteúdo real deles, por meio de recursão "
+"em um [Array] ou [Dictionary] em todos os seus níveis.\n"
+"Esta função compara a [code]==[/code] de diversas maneiras:\n"
"- Para [code]null[/code], [code]int[/code], [code]float[/code], "
"[code]String[/code], [code]Object[/code] e [code] RID[/code] tanto "
"[code]deep_equal[/code] quanto [code]==[/code] funcionam da mesma forma.\n"
"- Para [code]Dictionary[/code], [code]==[/code] considera-se igual se, e "
"somente se, ambas as variáveis apontarem para o mesmo [code]Dictionary[/"
-"code], sem recursão ou checagem de seu conteúdo.\n"
+"code], sem recursão ou checagem do seu conteúdo.\n"
"- Para [code]Array[/code], [code]==[/code] considera igual se, e somente se, "
"cada item no primeiro [code]Array[/code] for igual ao seu homólogo no "
"segundo [ code]Array[/code], conforme informado pelo próprio [code]==[/"
@@ -928,7 +928,7 @@ msgid ""
"[/codeblock]"
msgstr ""
"Retorna o comprimento da Variant [code]var[/code]. Comprimento é a contagem "
-"de caracteres de uma String, contagem de elementos de uma Array, o tamanho "
+"de caracteres de uma cadeia, contagem de elementos de uma Array, o tamanho "
"de um Dicionario, etc.\n"
"[b]Note:[/b] Gera um erro fatal se Variant não puder retornar um "
"comprimento.\n"
@@ -1361,7 +1361,7 @@ msgid ""
"distinguishes them from print messages used for debugging purposes, while "
"also displaying a stack trace when an error or warning is printed."
msgstr ""
-"Converte um ou mais argumentos de qualquer tipo para string da melhor "
+"Converte um ou mais argumentos de qualquer tipo para cadeia da melhor "
"maneira possível e imprime no console\n"
"[codeblock]\n"
"a = [1, 2, 3]\n"
@@ -1370,7 +1370,7 @@ msgstr ""
"[b]Nota:[/b] Considere usar [method push_error] e [method push_warning] para "
"imprimir mensagens de erro e aviso ao invés de [method print]. Isso os "
"distinguirá de impressões com propósito de depuração e também mostrará um "
-"rastreamento de pilha quando um erro ou aviso é impresso ."
+"rastreamento de pilha quando um erro ou aviso é impresso."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -1890,7 +1890,7 @@ msgid ""
"len(b) # Returns 12\n"
"[/codeblock]"
msgstr ""
-"Converte um ou mais argumentos de quaisquer tipos para string na melhor "
+"Converte um ou mais argumentos de quaisquer tipos para cadeia na melhor "
"maneira possível.\n"
"[codeblock]\n"
"var a = [10, 20, 30]\n"
@@ -1909,7 +1909,7 @@ msgid ""
"print(b[\"a\"]) # Prints 1\n"
"[/codeblock]"
msgstr ""
-"Converte um string formatado que foi retornado por [method var2str] para o "
+"Converte uma cadeia formatada que foi retornada por [method var2str] para o "
"valor original.\n"
"[codeblock]\n"
"a = '{ \"a\": 1, \"b\": 2 }'\n"
@@ -2025,8 +2025,8 @@ msgid ""
" push_error(\"Invalid JSON: \" + v)\n"
"[/codeblock]"
msgstr ""
-"Verifica se [code]json[/code] contém dados JSON válidos. Retorna um String "
-"vazio se válido, ou uma mensagem de erro caso contrário.\n"
+"Verifica se [code]json[/code] contém dados JSON válidos. Retorna uma cadeia "
+"vazia se for válida ou uma mensagem de erro caso contrário.\n"
"[codeblock]\n"
"j = to_json([1, 2, 3])\n"
"v = validate_json(j)\n"
@@ -2062,8 +2062,8 @@ msgid ""
"}\n"
"[/codeblock]"
msgstr ""
-"Converte uma Variant [code]var[/code] para um string formatado que pode ser "
-"convertido de volta com [method str2var].\n"
+"Converte uma Variant [code]var[/code] para uma cadeia formatada que pode ser "
+"convertida de volta com [method str2var].\n"
"[codeblock]\n"
"a = { \"a\": 1, \"b\": 2 }\n"
"print(var2str(a))\n"
@@ -3555,59 +3555,59 @@ msgstr "Máscara da tecla Group Switch."
#: doc/classes/@GlobalScope.xml
msgid "Left mouse button."
-msgstr "Botão esquerdo do mouse."
+msgstr "Botão esquerdo do rato."
#: doc/classes/@GlobalScope.xml
msgid "Right mouse button."
-msgstr "Botão direito do mouse."
+msgstr "Botão direito do rato."
#: doc/classes/@GlobalScope.xml
msgid "Middle mouse button."
-msgstr "Botão central do mouse."
+msgstr "Botão central do rato."
#: doc/classes/@GlobalScope.xml
msgid "Extra mouse button 1 (only present on some mice)."
-msgstr "Primeiro botão extra do mouse (disponível em apenas alguns mouses)."
+msgstr "Primeiro botão extra do rato (disponível em apenas alguns ratos)."
#: doc/classes/@GlobalScope.xml
msgid "Extra mouse button 2 (only present on some mice)."
-msgstr "Segundo botão extra do mouse (disponível em apenas alguns mouses)."
+msgstr "Segundo botão extra do rato (disponível em apenas alguns ratos)."
#: doc/classes/@GlobalScope.xml
msgid "Mouse wheel up."
-msgstr "Roda do mouse para cima."
+msgstr "Roda do rato para cima."
#: doc/classes/@GlobalScope.xml
msgid "Mouse wheel down."
-msgstr "Roda do mouse para baixo."
+msgstr "Roda do rato para baixo."
#: doc/classes/@GlobalScope.xml
msgid "Mouse wheel left button (only present on some mice)."
-msgstr "Botão esquerdo da roda do mouse (disponível em apenas alguns mouses)."
+msgstr "Botão esquerdo da roda do rato (disponível em apenas alguns ratos)."
#: doc/classes/@GlobalScope.xml
msgid "Mouse wheel right button (only present on some mice)."
-msgstr "Botão direito da roda do mouse (disponível em apenas alguns mouses)."
+msgstr "Botão direito da roda do rato (disponível em apenas alguns ratos)."
#: doc/classes/@GlobalScope.xml
msgid "Left mouse button mask."
-msgstr "Máscara do botão esquerdo do mouse."
+msgstr "Máscara do botão esquerdo do rato."
#: doc/classes/@GlobalScope.xml
msgid "Right mouse button mask."
-msgstr "Máscara do botão direito do mouse."
+msgstr "Máscara do botão direito do rato."
#: doc/classes/@GlobalScope.xml
msgid "Middle mouse button mask."
-msgstr "Máscara do botão central do mouse."
+msgstr "Máscara do botão central do rato."
#: doc/classes/@GlobalScope.xml
msgid "Extra mouse button 1 mask."
-msgstr "Máscara do primeiro botão extra do mouse."
+msgstr "Máscara do primeiro botão extra do rato."
#: doc/classes/@GlobalScope.xml
msgid "Extra mouse button 2 mask."
-msgstr "Máscara do segundo botão extra do mouse."
+msgstr "Máscara do segundo botão extra do rato."
#: doc/classes/@GlobalScope.xml
msgid "Invalid button or axis."
@@ -4354,7 +4354,6 @@ msgid ""
msgstr ""
#: doc/classes/@GlobalScope.xml
-#, fuzzy
msgid ""
"Hints that a float property should be edited via an exponential easing "
"function. The hint string can include [code]\"attenuation\"[/code] to flip "
@@ -4362,9 +4361,9 @@ msgid ""
"easing."
msgstr ""
"Sugere que uma propriedade float deve ser editada através de uma função de "
-"suavização. A string de sugestão pode incluir [code]\"attenuation\"[/code] "
-"para virar a curva horizontalmente e/ou [code]\"inout\"[/code] para incluir "
-"também a suavização in/out."
+"flexibilização. A cadeia de sugestão pode incluir [code]\"attenuation\"[/"
+"code] para virar a curva horizontalmente e/ou [code]\"inout\"[/code] para "
+"incluir também a flexibilização in/out."
#: doc/classes/@GlobalScope.xml
msgid "Deprecated hint, unused."
@@ -17844,11 +17843,11 @@ msgstr ""
#: doc/classes/Control.xml
msgid "Sent when the mouse pointer enters the node."
-msgstr "Enviado quando o ponteiro do mouse entra no nó."
+msgstr "Enviado quando o ponteiro do rato entra no nó."
#: doc/classes/Control.xml
msgid "Sent when the mouse pointer exits the node."
-msgstr "Enviado quando o ponteiro do mouse sai do nó."
+msgstr "Enviado quando o ponteiro do rato sai do nó."
#: doc/classes/Control.xml
msgid "Sent when the node grabs focus."
@@ -30979,7 +30978,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
@@ -37028,7 +37031,7 @@ msgstr ""
#: doc/classes/Navigation2DServer.xml doc/classes/NavigationServer.xml
#, fuzzy
msgid "Sets the position of the agent in world space."
-msgstr "Retorna a posição global do mouse."
+msgstr "Retorna a posição global do rato."
#: doc/classes/Navigation2DServer.xml doc/classes/NavigationServer.xml
#, fuzzy
@@ -37256,7 +37259,7 @@ msgstr ""
#: doc/classes/Navigation2DServer.xml doc/classes/NavigationServer.xml
#, fuzzy
msgid "Sets the global transformation for the region."
-msgstr "Retorna a posição global do mouse."
+msgstr "Retorna a posição global do rato."
#: doc/classes/Navigation2DServer.xml doc/classes/NavigationServer.xml
#, fuzzy
@@ -65291,11 +65294,11 @@ msgstr "Emitido quando um item é editado."
#: doc/classes/Tree.xml
msgid "Emitted when an item is edited using the right mouse button."
-msgstr "Emitido quando um item é editado com botão direito do mouse."
+msgstr "Emitido quando um item é editado com botão direito do rato."
#: doc/classes/Tree.xml
msgid "Emitted when an item is selected with the right mouse button."
-msgstr "Emitido quando um item é selecionado com o botão direito do mouse."
+msgstr "Emitido quando um item é selecionado com o botão direito do rato."
#: doc/classes/Tree.xml
msgid "Emitted when an item is selected."
@@ -65310,7 +65313,7 @@ msgstr ""
#: doc/classes/Tree.xml
msgid "Emitted when a left mouse button click does not select any item."
msgstr ""
-"Emitido quando um clique com o botão esquerdo do mouse não seleciona nenhum "
+"Emitido quando um clique com o botão esquerdo do rato não seleciona nenhum "
"item."
#: doc/classes/Tree.xml
diff --git a/doc/translations/pt_BR.po b/doc/translations/pt_BR.po
index 463bc9c957..687566bef1 100644
--- a/doc/translations/pt_BR.po
+++ b/doc/translations/pt_BR.po
@@ -45,12 +45,13 @@
# Mr.Albino <ricmorsoleto@gmail.com>, 2022.
# Zer0-Zer0 <dankmemerson@tutanota.com>, 2022.
# Julio Yagami <juliohenrique31501234@hotmail.com>, 2022.
+# Andrey Gonçalves <kaptaryd@gmail.com>, 2023.
msgid ""
msgstr ""
"Project-Id-Version: Godot Engine class reference\n"
"Report-Msgid-Bugs-To: https://github.com/godotengine/godot\n"
-"PO-Revision-Date: 2022-12-09 19:48+0000\n"
-"Last-Translator: Julio Yagami <juliohenrique31501234@hotmail.com>\n"
+"PO-Revision-Date: 2023-01-09 20:42+0000\n"
+"Last-Translator: Andrey Gonçalves <kaptaryd@gmail.com>\n"
"Language-Team: Portuguese (Brazil) <https://hosted.weblate.org/projects/"
"godot-engine/godot-class-reference/pt_BR/>\n"
"Language: pt_BR\n"
@@ -58,7 +59,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8-bit\n"
"Plural-Forms: nplurals=2; plural=n > 1;\n"
-"X-Generator: Weblate 4.15-dev\n"
+"X-Generator: Weblate 4.15.1-dev\n"
#: doc/tools/make_rst.py
msgid "Description"
@@ -860,7 +861,6 @@ msgstr ""
"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
-#, fuzzy
msgid ""
"Returns an interpolation or extrapolation factor considering the range "
"specified in [code]from[/code] and [code]to[/code], and the interpolated "
@@ -883,8 +883,26 @@ msgid ""
"See also [method lerp] which performs the reverse of this operation, and "
"[method range_lerp] to map a continuous series of values to another."
msgstr ""
-"Retornar a interpolação ou extrapolação do fator considerando o ranger "
-"específico [code ]para[/code]"
+"Retorna o fator de interpolação ou extrapolação considerando o intervalo "
+"especificado no [code]de[/code] e [code]para[/code], e o valor interpolado "
+"especificado no [code]peso[/code]. O valor retornado irá ser entre "
+"[code]0.0[/code] e [code]1.0[/code] se [code]peso[/code] for entre [code]de[/"
+"code] e [code]para[/code] (inclusivo). Se [code]peso[/code] está fora do "
+"intervalo especificado, então um fator de extrapolação será retornado "
+"(retorna valor menor que [code]0.0[/code] ou maior que [code]1.0[/code]). "
+"Use [method clamp] no resultado do [method inverse_lerp] se isso não for o "
+"desejado.\n"
+"[codeblock]\n"
+"# A razão da interpolação no uso do `lerp()` abaixo é 0.75.\n"
+"var meio = lerp(20, 30, 0.75)\n"
+"#`meio` agora é 27.5.\n"
+"# Agora, vamos fingir que esquecemos a razão original e o queremos de "
+"volta.\n"
+"var razao = inverse_lerp(20, 30, 27.5)\n"
+"#`razao` agora é 0.75.\n"
+"[/codeblock]\n"
+"Veja também o [method lerp] que faz o inverso desta operação, e [method "
+"range_lerp] para mapear uma série contínua de valores uns aos outros."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -1423,6 +1441,17 @@ msgid ""
"print_stack] will not work in projects exported in release mode, or in "
"projects exported in debug mode if not connected to a debugging server."
msgstr ""
+"Imprime um rastreamento de pilha no local do código atual. Veja também "
+"[method get_stack]\n"
+"A saída no console seria mais ou menos assim:\n"
+"[codeblock]\n"
+"Frame 0 - res://test.gd:16 in function '_process'\n"
+"[/codeblock]\n"
+"[b]Nota:[/b] [method print_stack] só funciona se a instância em execução "
+"estiver conectada a um servidor de depuração (ou seja, uma instância do "
+"editor). [method print_stack] não funcionará em projetos exportados no modo "
+"de lançamento ou em projetos exportados no modo de depuração se não estiver "
+"conectado a um servidor de depuração."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -4070,74 +4099,105 @@ msgid ""
"down on the key after it \"bottoms out\". This message is different from "
"polyphonic after-touch as it indicates the highest pressure across all keys."
msgstr ""
+"Mensagem de pressão do canal MIDI. Esta mensagem geralmente é enviada ao "
+"pressionar a tecla após ela \"ir de dentro pra fora\". Essa mensagem é "
+"diferente do pós-toque polifônico, pois indica a pressão mais alta em todas "
+"as teclas."
#: doc/classes/@GlobalScope.xml
msgid ""
"MIDI pitch bend message. This message is sent to indicate a change in the "
"pitch bender (wheel or lever, typically)."
msgstr ""
+"Mensagem MIDI de dobra de tom (pitch bend). Esta mensagem é enviada para "
+"indicar uma mudança no dobrador de tom (roda ou alavanca, tipicamente)."
#: doc/classes/@GlobalScope.xml
msgid ""
"MIDI system exclusive message. This has behavior exclusive to the device "
"you're receiving input from. Getting this data is not implemented in Godot."
msgstr ""
+"Mensagem exclusiva do sistema MIDI. Isso tem um comportamento exclusivo do "
+"dispositivo do qual você está recebendo entrada. A obtenção desses dados não "
+"está implementada no Godot."
#: doc/classes/@GlobalScope.xml
msgid ""
"MIDI quarter frame message. Contains timing information that is used to "
"synchronize MIDI devices. Getting this data is not implemented in Godot."
msgstr ""
+"Mensagem MIDI de um quarto de quadro. Contém informações de tempo usadas "
+"para sincronizar dispositivos MIDI. A obtenção desses dados não está "
+"implementada no Godot."
#: doc/classes/@GlobalScope.xml
msgid ""
"MIDI song position pointer message. Gives the number of 16th notes since the "
"start of the song. Getting this data is not implemented in Godot."
msgstr ""
+"Mensagem de ponteiro de posição de música MIDI. Dá o número de semicolcheias "
+"(cada 16ª nota) desde o início da música. A obtenção desses dados não está "
+"implementada no Godot."
#: doc/classes/@GlobalScope.xml
msgid ""
"MIDI song select message. Specifies which sequence or song is to be played. "
"Getting this data is not implemented in Godot."
msgstr ""
+"Mensagem MIDI de seleção de música. Especifica qual sequência ou música será "
+"tocada. A obtenção desses dados não está implementada no Godot."
#: doc/classes/@GlobalScope.xml
msgid ""
"MIDI tune request message. Upon receiving a tune request, all analog "
"synthesizers should tune their oscillators."
msgstr ""
+"Mensagem de solicitação de sintonia MIDI. Ao receber uma solicitação de "
+"sintonia, todos os sintetizadores analógicos devem sintonizar seus "
+"osciladores."
#: doc/classes/@GlobalScope.xml
msgid ""
"MIDI timing clock message. Sent 24 times per quarter note when "
"synchronization is required."
msgstr ""
+"Mensagem de relógio de tempo MIDI. Enviado 24 vezes por semínima quando a "
+"sincronização é necessária."
#: doc/classes/@GlobalScope.xml
msgid ""
"MIDI start message. Start the current sequence playing. This message will be "
"followed with Timing Clocks."
msgstr ""
+"mensagem de início MIDI. Inicie a reprodução da sequência atual. Esta "
+"mensagem será seguida de relógios de temporização."
#: doc/classes/@GlobalScope.xml
msgid "MIDI continue message. Continue at the point the sequence was stopped."
msgstr ""
+"Mensagem de continuação MIDI. Continue no ponto em que a sequência foi "
+"interrompida."
#: doc/classes/@GlobalScope.xml
msgid "MIDI stop message. Stop the current sequence."
-msgstr ""
+msgstr "Mensagem de parada MIDI. Pare a sequência atual."
#: doc/classes/@GlobalScope.xml
msgid ""
"MIDI active sensing message. This message is intended to be sent repeatedly "
"to tell the receiver that a connection is alive."
msgstr ""
+"Mensagem de detecção ativa de MIDI. Esta mensagem deve ser enviada "
+"repetidamente para informar ao receptor que uma conexão está ativa."
#: doc/classes/@GlobalScope.xml
msgid ""
"MIDI system reset message. Reset all receivers in the system to power-up "
"status. It should not be sent on power-up itself."
msgstr ""
+"Mensagem de reinicialização do sistema MIDI. Redefina todos os receptores no "
+"sistema para o status de inicialização. Ele não deve ser enviado no próprio "
+"power-up."
#: doc/classes/@GlobalScope.xml
msgid ""
@@ -31205,7 +31265,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/ro.po b/doc/translations/ro.po
index dd88e8d66b..94c966c61c 100644
--- a/doc/translations/ro.po
+++ b/doc/translations/ro.po
@@ -29940,7 +29940,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/ru.po b/doc/translations/ru.po
index 9d569d7760..b76873e4f1 100644
--- a/doc/translations/ru.po
+++ b/doc/translations/ru.po
@@ -57,12 +57,14 @@
# Handsless coder <yfintktajy1@gmail.com>, 2022.
# Evgeniy Khramov <thejenjagamertjg@gmail.com>, 2022.
# Григорий <bolon667@gmail.com>, 2022.
+# Artur Leonov (Depish) <depish.eskry@yandex.ru>, 2022.
+# Patrik <avdmur@gmail.com>, 2022.
msgid ""
msgstr ""
"Project-Id-Version: Godot Engine class reference\n"
"Report-Msgid-Bugs-To: https://github.com/godotengine/godot\n"
-"PO-Revision-Date: 2022-12-06 11:48+0000\n"
-"Last-Translator: Григорий <bolon667@gmail.com>\n"
+"PO-Revision-Date: 2022-12-23 10:00+0000\n"
+"Last-Translator: Patrik <avdmur@gmail.com>\n"
"Language-Team: Russian <https://hosted.weblate.org/projects/godot-engine/"
"godot-class-reference/ru/>\n"
"Language: ru\n"
@@ -71,7 +73,7 @@ msgstr ""
"Content-Transfer-Encoding: 8-bit\n"
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && "
"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
-"X-Generator: Weblate 4.15-dev\n"
+"X-Generator: Weblate 4.15.1-dev\n"
#: doc/tools/make_rst.py
msgid "Description"
@@ -127,7 +129,7 @@ msgstr "УнаÑледовано:"
#: doc/tools/make_rst.py
msgid "(overrides %s)"
-msgstr "(переназначает %s)"
+msgstr "(переопределÑет %s)"
#: doc/tools/make_rst.py
msgid "Default"
@@ -461,9 +463,9 @@ msgstr ""
"Ограничивает [code]value[/code], Ð²Ð¾Ð·Ð²Ñ€Ð°Ñ‰Ð°Ñ Ð·Ð½Ð°Ñ‡ÐµÐ½Ð¸Ðµ не меньше [code]min[/"
"code] и не больше [code]max[/code].\n"
"[codeblock]\n"
-"a = clamp(1000, 1, 20) # a будет 20\n"
-"a = clamp(-10, 1, 20) # a будет 1\n"
-"a = clamp(15, 1, 20) # a будет 15\n"
+"a = clamp(1000, 1, 20) # вернёт 20\n"
+"a = clamp(-10, 1, 20) # вернёт 1\n"
+"a = clamp(15, 1, 20) # вернёт 15\n"
"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
@@ -534,12 +536,12 @@ msgid ""
"a = dectime(60, 10, 0.1)) # a is 59.0\n"
"[/codeblock]"
msgstr ""
-"[b]Примечание:[/b] [code]dectime[/code] был уÑтаревшим и будет удален в "
-"Godot 4.0, пожалуйÑта, иÑпользуйте [метод move_toward] вмеÑто него.\n"
+"[b]Примечание:[/b] [code]dectime[/code] уÑтарел и будет удален в Godot 4.0, "
+"пожалуйÑта, иÑпользуйте [method move_toward] вмеÑто него.\n"
"Возвращает результат [code]value[/code], уменьшенный на [code]step[/code] * "
"[code]amount[/code].\n"
"[codeblock]\n"
-"a = dectime(60, 10, 0.1)) # a равно 59.0\n"
+"a = dectime(60, 10, 0.1)) # вернёт59.0\n"
"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
@@ -635,7 +637,7 @@ msgstr ""
"[/codeblock]\n"
"[url=https://raw.githubusercontent.com/godotengine/godot-docs/3.4/img/"
"ease_cheatsheet.png]ease() шпаргалка значений кривой[/url]\n"
-"См. также [метод smoothstep]. ЕÑли вам нужно выполнить более Ñложные "
+"См. также [method smoothstep]. ЕÑли вам нужно выполнить более Ñложные "
"переходы, иÑпользуйте [Tween] или [AnimationPlayer]."
#: modules/gdscript/doc_classes/@GDScript.xml
@@ -766,7 +768,6 @@ msgstr ""
"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
-#, fuzzy
msgid ""
"Returns an array of dictionaries representing the current call stack. See "
"also [method print_stack].\n"
@@ -790,22 +791,27 @@ msgid ""
"get_stack] will not work in projects exported in release mode, or in "
"projects exported in debug mode if not connected to a debugging server."
msgstr ""
-"Возвращает маÑÑив Ñловарей, предÑтавлÑющий текущий Ñтек вызовов.\n"
+"Возвращает маÑÑив Ñловарей, предÑтавлÑющий текущий Ñтек вызовов. См. также "
+"[method print_stack].\n"
"[codeblock]\n"
"func _ready():\n"
-" foo()\n"
+"\tfoo()\n"
"\n"
"func foo():\n"
-" bar()\n"
+"\tbar()\n"
"\n"
"func bar():\n"
-" print(get_stack())\n"
+"\tprint(get_stack())\n"
"[/codeblock]\n"
"выведет\n"
"[codeblock]\n"
"[{function:bar, line:12, source:res://script.gd}, {function:foo, line:9, "
"source:res://script.gd}, {function:_ready, line:6, source:res://script.gd}]\n"
-"[/codeblock]"
+"[/codeblock]\n"
+"[b]Примечание:[/b] [method get_stack] работает только при подключенном "
+"Ñервере отладки (например в редакторе). [method get_stack] не будет работать "
+"в проектах, ÑкÑпортированных в режиме release или в проектах "
+"ÑкÑпортированных в режиме debug, еÑли они не подключены к Ñерверу отладки."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -914,7 +920,8 @@ msgstr ""
"var ratio = inverse_lerp(20, 30, 27.5)\n"
"# `ratio` теперь 0.75.\n"
"[/codeblock]\n"
-"Смотрите также [метод lerp], который выполнÑет обратную Ñтой операцию."
+"Смотрите также [method lerp], который выполнÑет обратную операцию и [method "
+"range_lerp] Ð´Ð»Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶ÐµÐ½Ð¸Ñ Ð¿Ð¾Ñледовательного Ñ€Ñда значений в другом."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -1048,23 +1055,23 @@ msgid ""
msgstr ""
"Ð›Ð¸Ð½ÐµÐ¹Ð½Ð°Ñ Ð¸Ð½Ñ‚ÐµÑ€Ð¿Ð¾Ð»ÑÑ†Ð¸Ñ Ð¼ÐµÐ¶Ð´Ñƒ Ð´Ð²ÑƒÐ¼Ñ ÑƒÐ³Ð»Ð°Ð¼Ð¸ (в радианах) по нормализованному "
"значению.\n"
-"Ðналогично [методу lerp], но корректно интерполируетÑÑ, когда углы "
-"оборачивают вокруг [конÑтанты @GDScript.TAU]. Чтобы выполнить упрощенную "
-"интерполÑцию Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ [метода lerp_angle], объедините его Ñ [методом ease] "
-"или [методом smoothstep].\n"
+"Ðналогично [method lerp], но корректно интерполируетÑÑ, когда углы "
+"оборачивают вокруг [constant @GDScript.TAU]. Чтобы выполнить упрощенную "
+"интерполÑцию Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ [method lerp_angle], объедините его Ñ [method ease] "
+"или [method smoothstep].\n"
"[codeblock]\n"
"extends Sprite\n"
"var elapsed = 0.0\n"
"func _process(delta):\n"
-" var min_angle = deg2rad(0.0)\n"
-" var max_angle = deg2rad(90.0)\n"
-" rotation = lerp_angle(min_angle, max_angle, elapsed)\n"
-" elapsed += delta\n"
+"\tvar min_angle = deg2rad(0.0)\n"
+"\tvar max_angle = deg2rad(90.0)\n"
+"\trotation = lerp_angle(min_angle, max_angle, elapsed)\n"
+"\telapsed += delta\n"
"[/codeblock]\n"
"[b]Примечание:[/b] Этот метод проходит через кратчайший путь между "
"[code]from[/code] и [code]to[/code]. Тем не менее, еÑли разница между Ñтими "
-"Ð´Ð²ÑƒÐ¼Ñ ÑƒÐ³Ð»Ð°Ð¼Ð¸ и любым целым чиÑлом [code]k[/code] приблизительно [code]PI + "
-"k * TAU[/code], неочевидно в какую Ñторону [/code]из-за ошибок в точноÑти "
+"Ð´Ð²ÑƒÐ¼Ñ ÑƒÐ³Ð»Ð°Ð¼Ð¸ и любым целым чиÑлом [code]k[/code] приблизительно [code]PI + k "
+"* TAU[/code], неочевидно в какую Ñторону [/code]из-за ошибок в точноÑти "
"чиÑел Ñ Ð¿Ð»Ð°Ð²Ð°ÑŽÑ‰ÐµÐ¹ точкой. Ðапример, [code]lerp_angle(0, PI, weight)[/code] "
"оборачиваетÑÑ Ð¿Ñ€Ð¾Ñ‚Ð¸Ð² чаÑовой Ñтрелки, а [code]lerp_angle(0, PI + 5 * TAU, "
"weight)[/code] оборачиваетÑÑ Ð¿Ð¾ чаÑовой."
@@ -1098,6 +1105,7 @@ msgstr ""
"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
+#, fuzzy
msgid ""
"Loads a resource from the filesystem located at [code]path[/code]. The "
"resource is loaded on the method call (unless it's referenced already "
@@ -1124,19 +1132,19 @@ msgstr ""
"ÑÑылаютÑÑ Ð² другом меÑте, например, в другом Ñкрипте или в Ñцене), что может "
"вызвать небольшую задержку, оÑобенно при загрузке Ñцен. Чтобы избежать "
"ненужных задержек при многократной загрузке чего-либо, либо Ñохраните реÑÑƒÑ€Ñ "
-"в переменной, либо иÑпользуйте [метод preload].\n"
+"в переменной, либо иÑпользуйте [method preload].\n"
"[b]Примечание: [/b] Пути к реÑурÑам можно получить, щёлкнув правой кнопкой "
"мыши на реÑурÑе в панели Â«Ð¤Ð°Ð¹Ð»Ð¾Ð²Ð°Ñ ÑиÑтема» и выбрав \"Копировать путь\" или "
"перетащив файл из панели Â«Ð¤Ð°Ð¹Ð»Ð¾Ð²Ð°Ñ ÑиÑтема» в Ñценарий.\n"
"[codeblock]\n"
"# Load a scene called main located in the root of the project directory and "
"cache it in a variable.\n"
-"var main = load(\"res://main.tscn\") # main will contain a PackedScene "
-"resource.\n"
+"var main = load(\"res://main.tscn\") # main будет Ñодержать объект "
+"PackedScene.\n"
"[/codeblock]\n"
"[b]Важно:[/b] Путь должен быть абÑолютным, локальный путь проÑто вернет "
"[code]null[/code].\n"
-"Этот метод предÑтавлÑет Ñобой упрощенную верÑию [метода ResourceLoader."
+"Этот метод предÑтавлÑет Ñобой упрощенную верÑию [method ResourceLoader."
"load], который можно иÑпользовать Ð´Ð»Ñ Ð±Ð¾Ð»ÐµÐµ Ñложных Ñценариев."
#: modules/gdscript/doc_classes/@GDScript.xml
@@ -1449,6 +1457,16 @@ msgid ""
"print_stack] will not work in projects exported in release mode, or in "
"projects exported in debug mode if not connected to a debugging server."
msgstr ""
+"Выводит Ñтек вызовов из текущей функции. Смотрите также: [method "
+"get_stack].\n"
+"Вывод в конÑоли будет примерно таким:\n"
+"[codeblock]\n"
+"Frame 0 - res://test.gd:16 in function '_process'\n"
+"[/codeblock]\n"
+"[b]Примечание:[/b] [method print_stack] работает только при подключенном "
+"Ñервере отладки (например в редакторе). [method print_stack] не будет "
+"работать в проектах, ÑкÑпортированных в режиме release или в проектах "
+"ÑкÑпортированных в режиме debug, еÑли они не подключены к Ñерверу отладки."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -1687,7 +1705,7 @@ msgid ""
"3\n"
"[/codeblock]"
msgstr ""
-"Возвращает маÑÑив Ñ Ð·Ð°Ð´Ð°Ð½Ð½Ñ‹Ð¼ диапазоном. [метод range] может быть вызван "
+"Возвращает маÑÑив Ñ Ð·Ð°Ð´Ð°Ð½Ð½Ñ‹Ð¼ диапазоном. [method range] может быть вызван "
"Ñ‚Ñ€ÐµÐ¼Ñ ÑпоÑобами:\n"
"[code]range(n: int)[/code]: ÐачинаетÑÑ Ñ 0, увеличиваетÑÑ Ñ ÑˆÐ°Ð³Ð¾Ð¼ в 1 и "
"оÑтанавливаетÑÑ [i]перед[/i] [code]n[/code]. Ðргумент [code]n[/code] Ñто "
@@ -1702,16 +1720,16 @@ msgstr ""
"[b]инклюзив[/b] и [b]ÑкÑклюзив[/b], ÑоответÑтвенно. Ðргумент [code]s[/code] "
"[b]может[/b] быть негативным, но не [code]0[/code]. ЕÑли [code]s[/code] Ñто "
"[code]0[/code], будет выведено Ñообщение об ошибке.\n"
-"[метод range] преобразует вÑе аргументы в [int] перед обработкой.\n"
+"[method range] преобразует вÑе аргументы в [int] перед обработкой.\n"
"[b]Примечание:[/b] Возвращает пуÑтой маÑÑив, еÑли ни одно значение не "
"удовлетворÑет ограничению на значение (e.g. [code]range(2, 5, -1)[/code] или "
"[code]range(5, 5, 1)[/code]).\n"
"Примеры:\n"
"[codeblock]\n"
-"print(range(4)) # Prints [0, 1, 2, 3]\n"
-"print(range(2, 5)) # Prints [2, 3, 4]\n"
-"print(range(0, 6, 2)) # Prints [0, 2, 4]\n"
-"print(range(4, 1, -1)) # Prints [4, 3, 2]\n"
+"print(range(4)) # Выведет [0, 1, 2, 3]\n"
+"print(range(2, 5)) # Выведет [2, 3, 4]\n"
+"print(range(0, 6, 2)) # Выведет [0, 2, 4]\n"
+"print(range(4, 1, -1)) # Выведет [4, 3, 2]\n"
"[/codeblock]\n"
"Чтобы выполнить итерацию по [Array] в обратном порÑдке, иÑпользуйте:\n"
"[codeblock]\n"
@@ -1739,6 +1757,18 @@ msgid ""
"For complex use cases where you need multiple ranges, consider using [Curve] "
"or [Gradient] instead."
msgstr ""
+"Ограничивает [code]значение[/code] из диапазона [code][istart, istop][/code] "
+"до диапазона [code][ostart, ostop][/code]. Смотрите также [method lerp] и "
+"[method inverse_lerp]. ЕÑли [code]значение[/code] за пределами [code]"
+"[istart, istop][/code], тогда, выходное значение тоже будет за пределами "
+"[code][ostart, ostop][/code]. ИÑпользуйте [method clamp] Ñо значением "
+"полученным от [method range_lerp] еÑли не хотите выходить за пределы.[/"
+"code]\n"
+"[codeblock]\n"
+"range_lerp(75, 0, 100, -1, 1) # Возвращает 0.5\n"
+"[/codeblock]\n"
+"Ð”Ð»Ñ Ñлучаев где вам нужно неÑколько диапазонов, иÑпользуйте [Curve] или "
+"[Gradient]."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -1755,10 +1785,10 @@ msgstr ""
"в большую Ñторону.\n"
"[codeblock]\n"
"a = round(2.49) # Возвращает 2.0\n"
-"a = round(2.5) # Возвращает 3.0\n"
+"a = round(2.5)\t# Возвращает 3.0\n"
"a = round(2.51) # Возвращает 3.0\n"
"[/codeblock]\n"
-"См. также[метод floor], [метод ceil], [метод stepify], и [int]."
+"См. также[method floor], [method ceil], [method stepify], и [int]."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -1852,14 +1882,15 @@ msgstr ""
"S-образной кривой, ÐºÐ¾Ñ‚Ð¾Ñ€Ð°Ñ ÑоответÑтвует значению [code]s[/code] между "
"[code]0[/code] и [code]1[/code].\n"
"S-Ð¾Ð±Ñ€Ð°Ð·Ð½Ð°Ñ ÐºÑ€Ð¸Ð²Ð°Ñ ÑвлÑетÑÑ ÐºÑƒÐ±Ð¸Ñ‡ÐµÑким Ñрмитовым Ñплайном, заданным функцией "
-"[code]f(s) = 3*s^2 - 2*s^3[/code].\n"
+"[code]f(y) = 3*y^2 - 2*y^3[/code], где [code]y = (x-from) / (to-from)[/"
+"code].\n"
"[codeblock]\n"
"smoothstep(0, 2, -5.0) # Возвращает 0.0\n"
"smoothstep(0, 2, 0.5) # Возвращает 0.15625\n"
"smoothstep(0, 2, 1.0) # Возвращает 0.5\n"
"smoothstep(0, 2, 2.0) # Возвращает 1.0\n"
"[/codeblock]\n"
-"Ð’ Ñравнении Ñ [method ease] Ñо значение кривой [code]-1.6521[/code], [метод "
+"Ð’ Ñравнении Ñ [method ease] Ñо значение кривой [code]-1.6521[/code], [method "
"smoothstep] возвращает наиболее плавную кривую без внезапных изменений "
"производной. ЕÑли вам нужно выполнить более продвинутые перемещениÑ, "
"иÑпользуйте [Tween] или [AnimationPlayer].\n"
@@ -1956,8 +1987,8 @@ msgid ""
"print(b[\"a\"]) # Prints 1\n"
"[/codeblock]"
msgstr ""
-"Преобразует форматированную Ñтроку, ÐºÐ¾Ñ‚Ð¾Ñ€Ð°Ñ Ð±Ñ‹Ð»Ð° возвращена [методом "
-"var2str] в иÑходное значение.\n"
+"Преобразует форматированную Ñтроку, ÐºÐ¾Ñ‚Ð¾Ñ€Ð°Ñ Ð±Ñ‹Ð»Ð° возвращена [method var2str] "
+"в иÑходное значение.\n"
"[codeblock]\n"
"a = '{ \"a\": 1, \"b\": 2 }'\n"
"b = str2var(a)\n"
@@ -2265,7 +2296,7 @@ msgid ""
msgstr ""
"ОÑтанавливает выполнение функции и возвращает текущее приоÑтановленное "
"ÑоÑтоÑние вызывающей функции.\n"
-"Ð’Ñ‹Ð·Ñ‹Ð²Ð°ÑŽÑ‰Ð°Ñ Ñ„ÑƒÐ½ÐºÑ†Ð¸Ñ Ð´Ð¾Ð»Ð¶Ð½Ð° вызвать [метод GDScriptFunctionState.resume] на "
+"Ð’Ñ‹Ð·Ñ‹Ð²Ð°ÑŽÑ‰Ð°Ñ Ñ„ÑƒÐ½ÐºÑ†Ð¸Ñ Ð´Ð¾Ð»Ð¶Ð½Ð° вызвать [method GDScriptFunctionState.resume] на "
"ÑоÑтоÑнии Ð´Ð»Ñ Ð²Ð¾Ð·Ð¾Ð±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ñ Ð²Ñ‹Ð¿Ð¾Ð»Ð½ÐµÐ½Ð¸Ñ. Это аннулирует ÑоÑтоÑние. Внутри "
"возобновленной функции [code]yield()[/code] возвращает вÑе, что было "
"передано в вызов функции [code]resume()[/code].\n"
@@ -2278,21 +2309,21 @@ msgstr ""
"работы функции:\n"
"[codeblock].\n"
"func _ready():\n"
-" yield(countdown(), \"completed\") # ожидание Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð¸Ñ Ñ„ÑƒÐ½ÐºÑ†Ð¸Ð¸ "
+"\tyield(countdown(), \"completed\") # ожидание Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð¸Ñ Ñ„ÑƒÐ½ÐºÑ†Ð¸Ð¸ "
"countdown()\n"
-" print('Ready')\n"
+"\tprint('Ready')\n"
"\n"
"func countdown():\n"
-" yield(get_tree(), \"idle_frame\") # возвращает объект "
+"\tyield(get_tree(), \"idle_frame\") # возвращает объект "
"GDScriptFunctionState Ð´Ð»Ñ Ñ„ÑƒÐ½ÐºÑ†Ð¸Ð¸ _ready()\n"
-" print(3)\n"
-" yield(get_tree().create_timer(1.0), \"timeout\")\n"
-" print(2)\n"
-" yield(get_tree().create_timer(1.0), \"timeout\")\n"
-" print(1)\n"
-" yield(get_tree().create_timer(1.0), \"timeout\")\n"
+"\tprint(3)\n"
+"\tyield(get_tree().create_timer(1.0), \"timeout\")\n"
+"\tprint(2)\n"
+"\tyield(get_tree().create_timer(1.0), \"timeout\")\n"
+"\tprint(1)\n"
+"\tyield(get_tree().create_timer(1.0), \"timeout\")\n"
"\n"
-"# печатает:\n"
+"# выведет:\n"
"# 3\n"
"# 2\n"
"# 1\n"
@@ -13808,6 +13839,7 @@ msgid "Camera node for 2D scenes."
msgstr ""
#: doc/classes/Camera2D.xml
+#, fuzzy
msgid ""
"Camera node for 2D scenes. It forces the screen (current layer) to scroll "
"following this node. This makes it easier (and faster) to program scrollable "
@@ -13836,7 +13868,7 @@ msgstr ""
"Обратите внимание, что положение узла [Camera2D] [code][/code] не отражает "
"фактичеÑкое положение Ñкрана, которое может отличатьÑÑ Ð¸Ð·-за примененного "
"ÑÐ³Ð»Ð°Ð¶Ð¸Ð²Ð°Ð½Ð¸Ñ Ð¸Ð»Ð¸ ограничений. Ð”Ð»Ñ Ð¿Ð¾Ð»ÑƒÑ‡ÐµÐ½Ð¸Ñ Ñ€ÐµÐ°Ð»ÑŒÐ½Ð¾Ð³Ð¾ Ð¿Ð¾Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ Ð¼Ð¾Ð¶Ð½Ð¾ "
-"иÑпользовать [метод get_camera_screen_center]."
+"иÑпользовать [method get_camera_screen_center]."
#: doc/classes/Camera2D.xml doc/classes/TileMap.xml doc/classes/TileSet.xml
msgid "2D Isometric Demo"
@@ -16052,11 +16084,11 @@ msgstr ""
"ÑвойÑтва (например, CanvasItem.modulate) могут принимать Ð·Ð½Ð°Ñ‡ÐµÐ½Ð¸Ñ Ð±Ð¾Ð»ÑŒÑˆÐµ 1 "
"(переÑвет или цвета HDR).\n"
"Ð’Ñ‹ также можете Ñоздать цвет из Ñтандартизированных имен цветов Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ "
-"[метода @GDScript.ColorN] или непоÑредÑтвенно иÑÐ¿Ð¾Ð»ÑŒÐ·ÑƒÑ Ð¾Ð¿Ñ€ÐµÐ´ÐµÐ»ÐµÐ½Ð½Ñ‹Ðµ здеÑÑŒ "
+"[method @GDScript.ColorN] или непоÑредÑтвенно иÑÐ¿Ð¾Ð»ÑŒÐ·ÑƒÑ Ð¾Ð¿Ñ€ÐµÐ´ÐµÐ»ÐµÐ½Ð½Ñ‹Ðµ здеÑÑŒ "
"цветовые конÑтанты. Стандартизированный набор цветов оÑнован на [url=https://"
"en.wikipedia.org/wiki/X11_color_names]именах цветов X11[/url].\n"
"ЕÑли вы хотите задать Ð·Ð½Ð°Ñ‡ÐµÐ½Ð¸Ñ Ð² диапазоне от 0 до 255, вам Ñледует "
-"иÑпользовать [метод @GDScript.Color8].\n"
+"иÑпользовать [method @GDScript.Color8].\n"
"[b]Примечание:[/b] Ð’ булевом контекÑте значение Color будет равно "
"[code]false[/code], еÑли оно равно [code]Color(0, 0, 0, 0, 1)[/code] "
"(непрозрачный черный). Ð’ противном Ñлучае значение Color вÑегда будет равно "
@@ -17703,24 +17735,24 @@ msgid ""
msgstr ""
"Виртуальный метод, который должен быть реализован пользователем. ИÑпользуйте "
"Ñтот метод Ð´Ð»Ñ Ð¾Ð±Ñ€Ð°Ð±Ð¾Ñ‚ÐºÐ¸ и приема входных данных на Ñлементах "
-"пользовательÑкого интерфейÑа. См. [метод accept_event].\n"
+"пользовательÑкого интерфейÑа. См. [method accept_event].\n"
"Пример: щелчок по Ñлементу управлениÑ.\n"
"[codeblock].\n"
"func _gui_input(event):\n"
-" if event is InputEventMouseButton:\n"
-" if event.button_index == BUTTON_LEFT and event.pressed:\n"
-" print(\"Ðа Ð¼ÐµÐ½Ñ Ð½Ð°Ð¶Ð°Ð»Ð¸ D:\")\n"
+"\tif event is InputEventMouseButton:\n"
+"\t\tif event.button_index == BUTTON_LEFT and event.pressed:\n"
+"\t\t\tprint(\"Ðа Ð¼ÐµÐ½Ñ Ð½Ð°Ð¶Ð°Ð»Ð¸ D:\")\n"
"[/codeblock].\n"
"Событие не Ñработает, еÑли:\n"
-"* щелчок вне Ñлемента ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ (Ñм. [метод has_point]);\n"
+"* щелчок вне Ñлемента ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ (Ñм. [method has_point]);\n"
"* у Ñлемента ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ [member mouse_filter] уÑтановлено значение [constant "
"MOUSE_FILTER_IGNORE];\n"
"* Ñлемент ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð·Ð°Ð³Ð¾Ñ€Ð¾Ð¶ÐµÐ½ другим [Control] Ñверху, у которого [member "
"mouse_filter] не уÑтановлен на [constant MOUSE_FILTER_IGNORE];\n"
"* родитель Ñлемента ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð¸Ð¼ÐµÐµÑ‚ [member mouse_filter], уÑтановленный на "
"[constant MOUSE_FILTER_STOP] или принÑл Ñобытие;\n"
-"* Ñобытие проиÑходит вне прÑмоугольника родителÑ, и у Ñ€Ð¾Ð´Ð¸Ñ‚ÐµÐ»Ñ Ð²ÐºÐ»ÑŽÑ‡ÐµÐ½ [член "
-"rect_clip_content] или [метод _clips_input].\n"
+"* Ñобытие проиÑходит вне прÑмоугольника родителÑ, и у Ñ€Ð¾Ð´Ð¸Ñ‚ÐµÐ»Ñ Ð²ÐºÐ»ÑŽÑ‡ÐµÐ½ "
+"[member rect_clip_content] или [method _clips_input].\n"
"[b]Примечание:[/b] Положение ÑÐ¾Ð±Ñ‹Ñ‚Ð¸Ñ Ð¾Ñ‚Ð½Ð¾Ñительно начала Ñлемента управлениÑ."
#: doc/classes/Control.xml
@@ -17852,7 +17884,7 @@ msgstr ""
"получении Ñлементов темы Ð´Ð»Ñ Ñлемента управлениÑ.\n"
"[b]Примечание:[/b] Переопределение можно удалить, приÑвоив ему значение "
"[code]null[/code]. Это поведение уÑтарело и будет удалено в верÑии 4.0, "
-"иÑпользуйте [метод remove_stylebox_override] вмеÑто Ñтого.\n"
+"иÑпользуйте [method remove_stylebox_override] вмеÑто Ñтого.\n"
"См. также [метод get_stylebox].\n"
"[b]Пример Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ ÑвойÑтва в StyleBox путем его дублированиÑ:[/b]\n"
"[codeblock]\n"
@@ -17867,7 +17899,7 @@ msgstr ""
"$MyButton.add_stylebox_override(\"normal\", new_stylebox_normal)\n"
"# Удалите переопределение Ñтилей.\n"
"$MyButton.add_stylebox_override(\"normal\", null)\n"
-"[/codeblock]."
+"[/codeblock]"
#: doc/classes/Control.xml
msgid ""
@@ -18583,7 +18615,7 @@ msgstr ""
"необходимое Ð´Ð»Ñ Ð¿Ð¾ÑÐ²Ð»ÐµÐ½Ð¸Ñ Ð²Ñплывающей подÑказки Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ опции [code]gui/"
"timers/tooltip_delay_sec[/code] в ÐаÑтройках проекта.\n"
"Ð’ÑÐ¿Ð»Ñ‹Ð²Ð°ÑŽÑ‰Ð°Ñ Ð¿Ð¾Ð´Ñказка будет иÑпользовать либо реализацию по умолчанию, либо "
-"пользовательÑкую, которую вы можете Ñоздать, переопределив [метод "
+"пользовательÑкую, которую вы можете Ñоздать, переопределив [method "
"_make_custom_tooltip]. Ð’ÑÐ¿Ð»Ñ‹Ð²Ð°ÑŽÑ‰Ð°Ñ Ð¿Ð¾Ð´Ñказка по умолчанию включает "
"[PopupPanel] и [Label], ÑвойÑтва темы которых можно наÑтроить Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ "
"методов [Theme] Ñ [code]\"TooltipPanel\"[/code] и [code]\"TooltipLabel\"[/"
@@ -23673,17 +23705,17 @@ msgstr ""
"ÑоÑтоÑние можно было воÑÑтановить при возврате на вкладку). Эти данные "
"автоматичеÑки ÑохранÑÑŽÑ‚ÑÑ Ð´Ð»Ñ ÐºÐ°Ð¶Ð´Ð¾Ð¹ Ñцены в файле [code]editstate[/code] в "
"папке метаданных редактора. ЕÑли вы хотите Ñохранить глобальные (незавиÑимые "
-"от Ñцены) данные редактора Ð´Ð»Ñ Ð²Ð°ÑˆÐµÐ³Ð¾ плагина, вы можете иÑпользовать [метод "
-"get_window_layout] вмеÑто Ñтого.\n"
+"от Ñцены) данные редактора Ð´Ð»Ñ Ð²Ð°ÑˆÐµÐ³Ð¾ плагина, вы можете иÑпользовать "
+"[method get_window_layout] вмеÑто Ñтого.\n"
"ИÑпользуйте [method set_state] Ð´Ð»Ñ Ð²Ð¾ÑÑÑ‚Ð°Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ñ Ñохраненного ÑоÑтоÑниÑ.\n"
"[b]Примечание:[/b] Этот метод не Ñледует иÑпользовать Ð´Ð»Ñ ÑÐ¾Ñ…Ñ€Ð°Ð½ÐµÐ½Ð¸Ñ Ð²Ð°Ð¶Ð½Ñ‹Ñ… "
"наÑтроек, которые должны ÑохранÑÑ‚ÑŒÑÑ Ð² проекте.\n"
"[b]Примечание:[/b] Ð”Ð»Ñ ÐºÐ¾Ñ€Ñ€ÐµÐºÑ‚Ð½Ð¾Ð³Ð¾ ÑÐ¾Ñ…Ñ€Ð°Ð½ÐµÐ½Ð¸Ñ Ð¸ воÑÑÑ‚Ð°Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ñ ÑоÑтоÑÐ½Ð¸Ñ "
-"необходимо реализовать [метод get_plugin_name].\n"
+"необходимо реализовать [method get_plugin_name].\n"
"[codeblock].\n"
"func get_state():\n"
-" var state = {\"zoom\": zoom, \"preferred_color\": my_color}\n"
-" return state\n"
+"\tvar state = {\"zoom\": zoom, \"preferred_color\": my_color}\n"
+"\treturn state\n"
"[/codeblock]"
#: doc/classes/EditorPlugin.xml
@@ -27854,7 +27886,7 @@ msgstr ""
"Вершины каждого многоугольника будут округлены в ÑоответÑтвии Ñ Ñ‚Ð¸Ð¿Ð¾Ð¼ "
"[code]join_type[/code], Ñм. [enum PolyJoinType].\n"
"В результате операции может быть получен внешний многоугольник (граница) и "
-"внутренний многоугольник (отверÑтие), которые можно отличить, вызвав [метод "
+"внутренний многоугольник (отверÑтие), которые можно отличить, вызвав [method "
"is_polygon_clockwise].\n"
"[b]Примечание:[/b] Ð”Ð»Ñ Ñпециального перевода вершин многоугольника "
"иÑпользуйте метод [method Transform2D.xform]:\n"
@@ -28261,9 +28293,9 @@ msgstr ""
"занимает от 5 до 20 Ñекунд в большинÑтве Ñцен. Уменьшение [member subdiv] "
"может уÑкорить запекание.\n"
"[b]Примечание:[/b] [GeometryInstance]Ñ‹ и [Light]Ñ‹ должны быть полноÑтью "
-"готовы до вызова [метода bake]. ЕÑли вы Ñоздаете их процедурно и некоторые "
+"готовы до вызова [method bake]. ЕÑли вы Ñоздаете их процедурно и некоторые "
"Ñетки или оÑвещение отÑутÑтвуют в вашем запекаемом [GIProbe], иÑпользуйте "
-"[code]call_deferred(\"bake\")[/code] вмеÑто прÑмого вызова [метода bake]."
+"[code]call_deferred(\"bake\")[/code] вмеÑто прÑмого вызова [method bake]."
#: doc/classes/GIProbe.xml
msgid "Calls [method bake] with [code]create_visual_debug[/code] enabled."
@@ -30899,14 +30931,14 @@ msgid ""
"in the URL. See [method String.http_escape] for an example."
msgstr ""
"Создает Ð·Ð°Ð¿Ñ€Ð¾Ñ Ð½Ð° базовом [HTTPClient]. ЕÑли нет ошибок конфигурации, "
-"пытаетÑÑ Ð¿Ð¾Ð´ÐºÐ»ÑŽÑ‡Ð¸Ñ‚ÑŒÑÑ, иÑÐ¿Ð¾Ð»ÑŒÐ·ÑƒÑ [метод HTTPClient.connect_to_host] и "
-"передает параметры в [метод HTTPClient.request].\n"
+"пытаетÑÑ Ð¿Ð¾Ð´ÐºÐ»ÑŽÑ‡Ð¸Ñ‚ÑŒÑÑ, иÑÐ¿Ð¾Ð»ÑŒÐ·ÑƒÑ [method HTTPClient.connect_to_host] и "
+"передает параметры в [method HTTPClient.request].\n"
"Возвращает [constant OK], еÑли Ð·Ð°Ð¿Ñ€Ð¾Ñ ÑƒÑпешно Ñоздан. (Это не означает, что "
-"Ñервер ответил), [конÑтанта ERR_UNCONFIGURED], еÑли не находитÑÑ Ð² дереве, "
-"[конÑтанта ERR_BUSY], еÑли вÑе еще обрабатывает предыдущий запроÑ, "
-"[конÑтанта ERR_INVALID_PARAMETER], еÑли Ð·Ð°Ð´Ð°Ð½Ð½Ð°Ñ Ñтрока не ÑвлÑетÑÑ "
-"правильным форматом URL, или [конÑтанта ERR_CANT_CONNECT], еÑли не "
-"иÑпользуетÑÑ Ð¿Ð¾Ñ‚Ð¾Ðº и [HTTPClient] не может ÑоединитьÑÑ Ñ Ñ…Ð¾Ñтом.\n"
+"Ñервер ответил), [constant ERR_UNCONFIGURED], еÑли не находитÑÑ Ð² дереве, "
+"[constant ERR_BUSY], еÑли вÑе еще обрабатывает предыдущий запроÑ, [constant "
+"ERR_INVALID_PARAMETER], еÑли Ð·Ð°Ð´Ð°Ð½Ð½Ð°Ñ Ñтрока не ÑвлÑетÑÑ Ð¿Ñ€Ð°Ð²Ð¸Ð»ÑŒÐ½Ñ‹Ð¼ форматом "
+"URL, или [constant ERR_CANT_CONNECT], еÑли не иÑпользуетÑÑ Ð¿Ð¾Ñ‚Ð¾Ðº и "
+"[HTTPClient] не может ÑоединитьÑÑ Ñ Ñ…Ð¾Ñтом.\n"
"[b]Примечание:[/b] ЕÑли [code]метод[/code] ÑвлÑетÑÑ [constant HTTPClient."
"METHOD_GET], Ð¿Ð¾Ð»ÐµÐ·Ð½Ð°Ñ Ð½Ð°Ð³Ñ€ÑƒÐ·ÐºÐ°, Ð¾Ñ‚Ð¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð½Ð°Ñ Ñ‡ÐµÑ€ÐµÐ· [code]request_data[/"
"code], может быть проигнорирована Ñервером или даже привеÑти к отклонению "
@@ -32299,7 +32331,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
@@ -34067,38 +34103,38 @@ msgid ""
"[b]Note:[/b] Only available in the HTML5 platform."
msgstr ""
"JavaScriptObject иÑпользуетÑÑ Ð´Ð»Ñ Ð²Ð·Ð°Ð¸Ð¼Ð¾Ð´ÐµÐ¹ÑÑ‚Ð²Ð¸Ñ Ñ Ð¾Ð±ÑŠÐµÐºÑ‚Ð°Ð¼Ð¸ JavaScript, "
-"полученными или Ñозданными Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ [метода JavaScript.get_interface], "
-"[метода JavaScript.create_object] или [метода JavaScript.create_callback].\n"
+"полученными или Ñозданными Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ [method JavaScript.get_interface], "
+"[method JavaScript.create_object] или [method JavaScript.create_callback].\n"
"Пример:\n"
"[codeblock]\n"
-"раÑширÑет Node\n"
+"extends Node\n"
"\n"
"var _my_js_callback = JavaScript.create_callback(self, \"myCallback\") # Эта "
"ÑÑылка должна быть Ñохранена\n"
"var console = JavaScript.get_interface(\"console\")\n"
"\n"
"func _init():\n"
-" var buf = JavaScript.create_object(\"ArrayBuffer\", 10) # новый "
+"\tvar buf = JavaScript.create_object(\"ArrayBuffer\", 10) # новый "
"ArrayBuffer(10)\n"
-" print(buf) # печатает [JavaScriptObject:OBJECT_ID]\n"
-" var uint8arr = JavaScript.create_object(\"Uint8Array\", buf) # новый "
+"\tprint(buf) # печатает [JavaScriptObject:OBJECT_ID]\n"
+"\tvar uint8arr = JavaScript.create_object(\"Uint8Array\", buf) # новый "
"Uint8Array(buf)\n"
-" uint8arr[1] = 255\n"
-" prints(uint8arr[1], uint8arr.byteLength) # печатает 255 10\n"
-" console.log(uint8arr) # печатает в конÑоли браузера \"Uint8Array(10) "
-"[ 0, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]\"\n"
+"\tuint8arr[1] = 255\n"
+"\tprints(uint8arr[1], uint8arr.byteLength) # печатает 255 10\n"
+"\tconsole.log(uint8arr) # печатает в конÑоли браузера \"Uint8Array(10) [ 0, "
+"255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]\"\n"
"\n"
-" # Эквивалент JavaScript: Array.from(uint8arr).forEach(myCallback)\n"
-" JavaScript.get_interface(\"Array\").from(uint8arr)."
+"\t# Эквивалент JavaScript: Array.from(uint8arr).forEach(myCallback)\n"
+"\tJavaScript.get_interface(\"Array\").from(uint8arr)."
"forEach(_my_js_callback)\n"
"\n"
"func myCallback(args):\n"
-" # Будет вызван Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð°Ð¼Ð¸, переданными в обратный вызов \"forEach\".\n"
-" # [0, 0, [JavaScriptObject:1173]]\n"
-" # [255, 1, [JavaScriptObject:1173]]\n"
-" # ...\n"
-" # [0, 9, [JavaScriptObject:1180]]\n"
-" print(args)\n"
+"\t# Будет вызван Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð°Ð¼Ð¸, переданными в обратный вызов \"forEach\".\n"
+"\t# [0, 0, [JavaScriptObject:1173]]\n"
+"\t# [255, 1, [JavaScriptObject:1173]]\n"
+"\t# ...\n"
+"\t# [0, 9, [JavaScriptObject:1180]]\n"
+"\tprint(args)\n"
"[/codeblock].\n"
"[b]Примечание:[/b] ДоÑтупно только в платформе HTML5."
@@ -39775,7 +39811,7 @@ msgstr "Возвращает значение задержки данного к
msgid ""
"Returns the normal for the point returned by [method map_get_closest_point]."
msgstr ""
-"Возвращает нормаль Ð´Ð»Ñ Ñ‚Ð¾Ñ‡ÐºÐ¸, возвращенной [методом map_get_closest_point]."
+"Возвращает нормаль Ð´Ð»Ñ Ñ‚Ð¾Ñ‡ÐºÐ¸, возвращенной [method map_get_closest_point]."
#: doc/classes/NavigationServer.xml
msgid ""
@@ -39976,10 +40012,10 @@ msgstr ""
"пирами, чтобы гарантировать, что пропуÑÐºÐ½Ð°Ñ ÑпоÑобноÑÑ‚ÑŒ пиров не будет "
"превышена. Параметры пропуÑкной ÑпоÑобноÑти также определÑÑŽÑ‚ размер окна "
"ÑоединениÑ, которое ограничивает количеÑтво надежных пакетов, которые могут "
-"находитьÑÑ Ð² пути в любой момент времени. Возвращает [конÑтанту OK], еÑли "
-"клиент был Ñоздан, [конÑтанту ERR_ALREADY_IN_USE], еÑли данный ÑкземплÑÑ€ "
+"находитьÑÑ Ð² пути в любой момент времени. Возвращает [constant OK], еÑли "
+"клиент был Ñоздан, [constant ERR_ALREADY_IN_USE], еÑли данный ÑкземплÑÑ€ "
"NetworkedMultiplayerENet уже имеет открытое Ñоединение (в Ñтом Ñлучае "
-"необходимо Ñначала вызвать [метод close_connection]) или [конÑтанту "
+"необходимо Ñначала вызвать [method close_connection]) или [constant "
"ERR_CANT_CREATE], еÑли клиент не может быть Ñоздан. ЕÑли указано "
"[code]client_port[/code], клиент также будет Ñлушать указанный порт; Ñто "
"полезно Ð´Ð»Ñ Ð½ÐµÐºÐ¾Ñ‚Ð¾Ñ€Ñ‹Ñ… методов обхода NAT."
@@ -75012,23 +75048,24 @@ msgid ""
"viewport_set_render_direct_to_screen]."
msgstr ""
"Копирует видовой Ñкран в облаÑÑ‚ÑŒ Ñкрана, указанную [code]rect[/code]. ЕÑли "
-"[член Viewport.render_direct_to_screen] равен [code]true[/code], то вьюпорт "
-"не иÑпользует фреймбуфер и Ñодержимое вьюпорта выводитÑÑ Ð½ÐµÐ¿Ð¾ÑредÑтвенно на "
-"Ñкран. Однако обратите внимание, что корневой видовой Ñкран риÑуетÑÑ "
-"поÑледним, поÑтому он будет риÑоватьÑÑ Ð¿Ð¾Ð²ÐµÑ€Ñ… Ñкрана. СоответÑтвенно, вы "
-"должны уÑтановить корневой видовой Ñкран на облаÑÑ‚ÑŒ, ÐºÐ¾Ñ‚Ð¾Ñ€Ð°Ñ Ð½Ðµ покрывает "
-"облаÑÑ‚ÑŒ, к которой вы прикрепили Ñтот видовой Ñкран.\n"
+"[member Viewport.render_direct_to_screen] равен [code]true[/code], то "
+"вьюпорт не иÑпользует фреймбуфер и Ñодержимое вьюпорта выводитÑÑ "
+"непоÑредÑтвенно на Ñкран. Однако обратите внимание, что корневой видовой "
+"Ñкран риÑуетÑÑ Ð¿Ð¾Ñледним, поÑтому он будет риÑоватьÑÑ Ð¿Ð¾Ð²ÐµÑ€Ñ… Ñкрана. "
+"СоответÑтвенно, вы должны уÑтановить корневой видовой Ñкран на облаÑÑ‚ÑŒ, "
+"ÐºÐ¾Ñ‚Ð¾Ñ€Ð°Ñ Ð½Ðµ покрывает облаÑÑ‚ÑŒ, к которой вы прикрепили Ñтот видовой Ñкран.\n"
"Ðапример, вы можете уÑтановить корневой видовой Ñкран так, чтобы он вообще "
"не отриÑовывалÑÑ, иÑÐ¿Ð¾Ð»ÑŒÐ·ÑƒÑ Ñледующий код:\n"
"[codeblock].\n"
"func _ready():\n"
-" get_viewport().set_attach_to_screen_rect(Rect2())\n"
-" $Viewport.set_attach_to_screen_rect(Rect2(0, 0, 600, 600))\n"
+"\tget_viewport().set_attach_to_screen_rect(Rect2())\n"
+"\t$Viewport.set_attach_to_screen_rect(Rect2(0, 0, 600, 600))\n"
"[/codeblock].\n"
"ИÑпользование Ñтого метода может привеÑти к значительной оптимизации, "
"оÑобенно на уÑтройÑтвах низкого клаÑÑа. Однако за Ñто приходитÑÑ "
"раÑплачиватьÑÑ Ð½ÐµÐ¾Ð±Ñ…Ð¾Ð´Ð¸Ð¼Ð¾Ñтью управлÑÑ‚ÑŒ видовыми Ñкранами вручную. Ð”Ð»Ñ "
-"дальнейшей оптимизации Ñмотрите [метод viewport_set_render_direct_to_screen]."
+"дальнейшей оптимизации Ñмотрите [method "
+"viewport_set_render_direct_to_screen]."
#: doc/classes/VisualServer.xml
msgid ""
diff --git a/doc/translations/sk.po b/doc/translations/sk.po
index 3a58e3f2a9..d82d0b12ee 100644
--- a/doc/translations/sk.po
+++ b/doc/translations/sk.po
@@ -29911,7 +29911,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/sr_Cyrl.po b/doc/translations/sr_Cyrl.po
index 2846de07bb..2fccf2bef4 100644
--- a/doc/translations/sr_Cyrl.po
+++ b/doc/translations/sr_Cyrl.po
@@ -29922,7 +29922,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/sv.po b/doc/translations/sv.po
index 65cad9bf8a..b4ec51f179 100644
--- a/doc/translations/sv.po
+++ b/doc/translations/sv.po
@@ -29909,7 +29909,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/th.po b/doc/translations/th.po
index 54fbdbfe27..0ca308df1c 100644
--- a/doc/translations/th.po
+++ b/doc/translations/th.po
@@ -30049,7 +30049,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/tl.po b/doc/translations/tl.po
index a9b6a9e2a9..a3d46e6b1d 100644
--- a/doc/translations/tl.po
+++ b/doc/translations/tl.po
@@ -29997,7 +29997,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/tr.po b/doc/translations/tr.po
index 5d8f2afe29..a41bb69483 100644
--- a/doc/translations/tr.po
+++ b/doc/translations/tr.po
@@ -30744,7 +30744,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/uk.po b/doc/translations/uk.po
index 3714c11d88..6c071cee85 100644
--- a/doc/translations/uk.po
+++ b/doc/translations/uk.po
@@ -20,8 +20,8 @@ msgid ""
msgstr ""
"Project-Id-Version: Godot Engine class reference\n"
"Report-Msgid-Bugs-To: https://github.com/godotengine/godot\n"
-"PO-Revision-Date: 2022-11-25 12:13+0000\n"
-"Last-Translator: Лев ДворÑкий <ne3r0n@gmail.com>\n"
+"PO-Revision-Date: 2022-12-28 14:08+0000\n"
+"Last-Translator: KazanskiyMaks <kazanskiy.maks@gmail.com>\n"
"Language-Team: Ukrainian <https://hosted.weblate.org/projects/godot-engine/"
"godot-class-reference/uk/>\n"
"Language: uk\n"
@@ -30,7 +30,7 @@ msgstr ""
"Content-Transfer-Encoding: 8-bit\n"
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && "
"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
-"X-Generator: Weblate 4.15-dev\n"
+"X-Generator: Weblate 4.15.1-dev\n"
#: doc/tools/make_rst.py
msgid "Description"
@@ -106,13 +106,11 @@ msgid "Getter"
msgstr "Отримувач"
#: doc/tools/make_rst.py
-#, fuzzy
msgid ""
"This method should typically be overridden by the user to have any effect."
msgstr "Зазвичай, цей метод перевизначаєтьÑÑ ÐºÐ¾Ñ€Ð¸Ñтувачем, щоб він мав вплив."
#: doc/tools/make_rst.py
-#, fuzzy
msgid ""
"This method has no side effects. It doesn't modify any of the instance's "
"member variables."
@@ -120,13 +118,11 @@ msgstr ""
"Цей метод не має побічних ефектів. Ðе змінює ніÑку змінну екземплÑра об'єкта."
#: doc/tools/make_rst.py
-#, fuzzy
msgid ""
"This method accepts any number of arguments after the ones described here."
msgstr "Цей метод приймає будь-Ñке чиÑло аргументів піÑÐ»Ñ Ð¾Ð¿Ð¸Ñаних тут."
#: doc/tools/make_rst.py
-#, fuzzy
msgid "This method is used to construct a type."
msgstr "Цей метод викориÑтовуєтьÑÑ Ð´Ð»Ñ Ð¿Ð¾Ð±ÑƒÐ´Ð¾Ð²Ð¸ типів."
@@ -136,8 +132,8 @@ msgid ""
"This method doesn't need an instance to be called, so it can be called "
"directly using the class name."
msgstr ""
-"Ð”Ð»Ñ Ð²Ð¸ÐºÐ¾Ñ€Ð¸ÑтаннÑ, цей метод не потребує ÑÑ‚Ð²Ð¾Ñ€ÐµÐ½Ð½Ñ Ð¾Ð±'єкта, тому він може "
-"бути викликаним напрÑму вказавши назву клаÑу."
+"Ð”Ð»Ñ Ð²Ð¸ÐºÐ»Ð¸ÐºÑƒ, метод не потребує ÑÑ‚Ð²Ð¾Ñ€ÐµÐ½Ð½Ñ Ð¾Ð±'єкта, тому він може бути "
+"викориÑтаним проÑто вказавши назву клаÑу."
#: doc/tools/make_rst.py
msgid ""
@@ -285,22 +281,22 @@ msgid ""
"[/codeblock]"
msgstr ""
"ПеревірÑÑ”, чи [code]condition[/code] дорівнює [code]true[/code]. Якщо "
-"[code]condition[/code] дорівнює [code]false[/code], буде згенеровано "
-"помилку. Якщо виконуєтьÑÑ Ñƒ редакторі, проєкт буде також призупинено, поки "
-"ви не продовжите його. Може бути викориÑтано, Ñк більш дієва форма [method "
-"push_error] Ð´Ð»Ñ Ð·Ð²Ñ–Ñ‚ÑƒÐ²Ð°Ð½Ð½Ñ Ð¿Ð¾Ð¼Ð¸Ð»Ð¾Ðº розробникам проєкту, або допоміжним "
-"кориÑтувачам.\n"
+"[code]condition[/code] дорівнює [code]false[/code], буде Ñтворено помилку. "
+"Якщо виконуєтьÑÑ Ð² редакторі, проєкт також буде призупинено, поки ви не "
+"відновите його роботу. Можна викориÑтати, Ñк більш дієву форму [method "
+"push_error] Ð´Ð»Ñ Ð·Ð²Ñ–Ñ‚ÑƒÐ²Ð°Ð½Ð½Ñ Ð¿Ð¾Ð¼Ð¸Ð»Ð¾Ðº розробникам проєкту, або кориÑтувачам "
+"Ð´Ð¾Ð¿Ð¾Ð²Ð½ÐµÐ½Ð½Ñ (add-on).\n"
"[b]Ðотатка:[/b] З міркувань продуктивноÑÑ‚Ñ–, код вÑередині [method assert] "
-"виконуєтьÑÑ Ñ‚Ñ–Ð»ÑŒÐºÐ¸ у діагноÑтичних збірках, або коли проєкт виконуєтьÑÑ Ñƒ "
-"редакторі. Ðе викориÑтовуйте код, Ñкий негативно впливає на Ð²Ð¸ÐºÐ¾Ð½Ð°Ð½Ð½Ñ "
-"[method assert]. Інакше, проєкт буде поводити Ñебе інакше, Ñкщо він буде "
-"екÑпортованим у режимі публікації.\n"
+"виконуєтьÑÑ Ñ‚Ñ–Ð»ÑŒÐºÐ¸ у діагноÑтичних збірках, або коли проєкт виконуєтьÑÑ Ð² "
+"редакторі. Ðе включайте в код, де викориÑÑ‚Ð°Ð½Ð½Ñ [method assert] призведе до "
+"побічних ефектів. У противному разі, проєкт буде поводити Ñебе інакше, Ñкщо "
+"він буде екÑпортованим у режимі публікації.\n"
"Якщо задано необов'Ñзковий аргумент [code]message[/code], то він буде "
"показаний у додаток до Ð¿Ð¾Ð²Ñ–Ð´Ð¾Ð¼Ð»ÐµÐ½Ð½Ñ \"Assertion failed\". Ви можете "
-"ÑкориÑтатиÑÑ Ñ†Ð¸Ð¼ Ð´Ð»Ñ Ð½Ð°Ð´Ð°Ð½Ð½Ñ Ð´Ð¾Ð´Ð°Ñ‚ÐºÐ¾Ð²Ð¸Ñ… відомоÑтей щодо того, чому перевірку "
-"не було пройдено.\n"
+"ÑкориÑтатиÑÑ Ñ†Ð¸Ð¼ Ð´Ð»Ñ Ð½Ð°Ð´Ð°Ð½Ð½Ñ Ð´Ð¾Ð´Ð°Ñ‚ÐºÐ¾Ð²Ð¸Ñ… відомоÑтей щодо причини провалу "
+"перевірки.\n"
"[codeblock]\n"
-"# ПрипуÑтимо, що ви хочете, щоб швидкіÑÑ‚ÑŒ (speed) була у межах від 0 до 20.\n"
+"# ПрипуÑтимо, ви хочете, щоб швидкіÑÑ‚ÑŒ (speed) була у межах від 0 до 20.\n"
"var speed = -10\n"
"assert(speed < 20) # ІÑтина, програма продовжить виконаннÑ\n"
"assert(speed >= 0) # Хиба, програму буде зупинено\n"
@@ -375,6 +371,7 @@ msgstr ""
"полÑрну ÑиÑтему (відÑтань до початку координат та кут)."
#: modules/gdscript/doc_classes/@GDScript.xml
+#, fuzzy
msgid ""
"Rounds [code]s[/code] upward (towards positive infinity), returning the "
"smallest whole number that is not less than [code]s[/code].\n"
@@ -384,6 +381,13 @@ msgid ""
"[/codeblock]\n"
"See also [method floor], [method round], [method stepify], and [int]."
msgstr ""
+"Заокруглює [code]s[/code] вгору (до додатної неÑкінченноÑÑ‚Ñ–), повертаючи "
+"найменше чиÑло, ще не менше за [code]s[/code].\n"
+"[codeblock]\n"
+"a = ceil(1.45) # a дорівнює 2.0\n"
+"a = ceil(1.001) # a дорівнює 2.0\n"
+"[/codeblock]\n"
+"Також переглÑньте [method floor], [method round], [method stepify] та [int]."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -396,6 +400,13 @@ msgid ""
"[/codeblock]\n"
"This is the inverse of [method ord]."
msgstr ""
+"Повертає Ñимвол, Ñк РÑдок з даного Юнікод коду(що ÑуміÑний з ASCII кодом).\n"
+"[codeblock]\n"
+"a = char(65) # a дорівнює \"A\"\n"
+"a = char(65 + 32) # a дорівнює \"a\"\n"
+"a = char(8364) # a дорівнює \"€\"\n"
+"[/codeblock]\n"
+"Це протилежніÑÑ‚ÑŒ до [method ord]."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -407,6 +418,13 @@ msgid ""
"a = clamp(15, 1, 20) # a is 15\n"
"[/codeblock]"
msgstr ""
+"ЗатиÑкує [code]value[/code] та повертає значеннÑ, що не менше за [code]min[/"
+"code] і не більше за [code]max[/code].\n"
+"[codeblock]\n"
+"a = clamp(1000, 1, 20) # a дорівнює 20\n"
+"a = clamp(-10, 1, 20) # a дорівнює 1\n"
+"a = clamp(15, 1, 20) # a дорівнює 15\n"
+"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -421,6 +439,16 @@ msgid ""
"print(a.length())\n"
"[/codeblock]"
msgstr ""
+"Конвертує один тип в інший у найкращий ÑпоÑіб. Параметр [code]type[/code] "
+"викориÑтовує Ð·Ð½Ð°Ñ‡ÐµÐ½Ð½Ñ Ð· [enum Variant.Type].\n"
+"[codeblock]\n"
+"a = Vector2(1, 0)\n"
+"# Виводить 1\n"
+"print(a.length())\n"
+"a = convert(a, TYPE_STRING)\n"
+"# Виводить 6, бо Ñ€Ñдок \"(1, 0)\" ÑкладаєтьÑÑ Ð· 6 Ñимволів\n"
+"print(a.length())\n"
+"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
#, fuzzy
@@ -431,11 +459,10 @@ msgid ""
"a = cos(PI) # a is -1.0\n"
"[/codeblock]"
msgstr ""
-"Повертає абÑолютне Ð·Ð½Ð°Ñ‡ÐµÐ½Ð½Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ñƒ [code]s[/code] (тобто Ð·Ð½Ð°Ñ‡ÐµÐ½Ð½Ñ Ð±ÐµÐ· "
-"знака, працює Ð´Ð»Ñ Ñ†Ñ–Ð»Ð¸Ñ… чиÑел Ñ– чиÑел із рухомою крапкою).\n"
+"Повертає коÑÐ¸Ð½ÑƒÑ ÐºÑƒÑ‚Ð° [code]s[/code] в радіанах.\n"
"[codeblock]\n"
-"# a дорівнює 1\n"
-"a = abs(-1)\n"
+"a = cos(TAU) # a дорівнює 1.0\n"
+"a = cos(PI) # a дорівнює -1.0\n"
"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
@@ -452,11 +479,11 @@ msgstr ""
#: modules/gdscript/doc_classes/@GDScript.xml
msgid "Converts from decibels to linear energy (audio)."
-msgstr ""
+msgstr "Перетворює з децибел в лінійну енергію (аудіо)."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid "Deprecated alias for [method step_decimals]."
-msgstr ""
+msgstr "ЗаÑтарілий пÑевдонім Ð´Ð»Ñ [method step_decimals]."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -468,6 +495,13 @@ msgid ""
"a = dectime(60, 10, 0.1)) # a is 59.0\n"
"[/codeblock]"
msgstr ""
+"[b]Ðотатка:[/b] [code]dectime[/code] заÑтарілий Ñ– буде вилучений в Godot "
+"4.0, натоміÑÑ‚ÑŒ краще викориÑтовуйте [method move_toward].\n"
+"Повертає результат [code]value[/code] зменшений на [code]step[/code] * "
+"[code]amount[/code].\n"
+"[codeblock]\n"
+"a = dectime(60, 10, 0.1)) # a дорівнює 59.0\n"
+"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -489,6 +523,23 @@ msgid ""
"want a true content-aware comparison, you have to use [code]deep_equal[/"
"code]."
msgstr ""
+"Порівнює два значеннÑ, шлÑхом порівнÑÐ½Ð½Ñ Ñ—Ñ… реального вміÑту, рекурÑивно Ð´Ð»Ñ "
+"будь-Ñкого [Array] чи [Dictionary] аж до найглибшого рівнÑ.\n"
+"Порівнюючи з [code]==[/code], відмітимо:\n"
+"- Ð”Ð»Ñ [code]null[/code], [code]int[/code], [code]float[/code], [code]String[/"
+"code], [code]Object[/code] та [code]RID[/code] що [code]deep_equal[/code], "
+"що [code]==[/code] працюють однаково.\n"
+"- Ð”Ð»Ñ [code]Dictionary[/code], [code]==[/code] виÑвлÑÑ” рівніÑÑ‚ÑŒ тоді й "
+"тільки тоді, коли йде порівнÑÐ½Ð½Ñ Ð· цим Ñамим [code]Dictionary[/code], без "
+"рекурÑÑ–Ñ— чи будь-Ñкого Ð²Ñ€Ð°Ñ…ÑƒÐ²Ð°Ð½Ð½Ñ Ð²Ð¼Ñ–Ñту.\n"
+"- Ð”Ð»Ñ [code]Array[/code], [code]==[/code] виÑвлÑÑ” рівніÑÑ‚ÑŒ тоді й тільки "
+"тоді, коли кожний елемент у першому [code]Array[/code] дорівнює відповідному "
+"елементу в другому [code]Array[/code], де порівнÑÐ½Ð½Ñ Ð¿Ñ€Ð¾Ñ…Ð¾Ð´Ð¸Ñ‚ÑŒ через "
+"[code]==[/code]. Це означає, що [code]==[/code] рекурÑивно порівнює "
+"[code]Array[/code], але не [code]Dictionary[/code].\n"
+"Загалом, Ñкщо у Ð²Ð°Ñ Ð¿Ð¾Ñ‚ÐµÐ½Ñ†Ñ–Ð¹Ð½Ð¾ викориÑтовуєтьÑÑ [code]Dictionary[/code], Ñ– "
+"вам потрібно порівнÑÐ½Ð½Ñ Ð· урахуваннÑм вміÑту, викориÑтовуйте "
+"[code]deep_equal[/code]."
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -30098,7 +30149,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/vi.po b/doc/translations/vi.po
index 962440bfab..36ef54b096 100644
--- a/doc/translations/vi.po
+++ b/doc/translations/vi.po
@@ -30410,7 +30410,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
diff --git a/doc/translations/zh_CN.po b/doc/translations/zh_CN.po
index 966ec9b0f9..773dda130e 100644
--- a/doc/translations/zh_CN.po
+++ b/doc/translations/zh_CN.po
@@ -3,7 +3,7 @@
# Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md).
# This file is distributed under the same license as the Godot source code.
#
-# Haoyu Qiu <timothyqiu32@gmail.com>, 2020, 2021, 2022.
+# Haoyu Qiu <timothyqiu32@gmail.com>, 2020, 2021, 2022, 2023.
# fangxvan <2661712415@qq.com>, 2020.
# yzt <834950797@qq.com>, 2020.
# 懵逼Kitty <m1330586660@163.com>, 2020, 2021.
@@ -37,7 +37,7 @@
# Juer Genie Whang <2695996944@qq.com>, 2021.
# SimonChang <simon_chang@foxmail.com>, 2021.
# zeng haochen <m18621006730@163.com>, 2021.
-# suplife <2634557184@qq.com>, 2021.
+# suplife <2634557184@qq.com>, 2021, 2023.
# Magian <magian1127@gmail.com>, 2021, 2022.
# ji233 <27987772@qq.com>, 2021.
# 沈士超 <shenshichao920@hotmail.com>, 2021.
@@ -64,7 +64,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Godot Engine class reference\n"
"Report-Msgid-Bugs-To: https://github.com/godotengine/godot\n"
-"PO-Revision-Date: 2022-12-12 06:48+0000\n"
+"PO-Revision-Date: 2023-01-09 20:42+0000\n"
"Last-Translator: Haoyu Qiu <timothyqiu32@gmail.com>\n"
"Language-Team: Chinese (Simplified) <https://hosted.weblate.org/projects/"
"godot-engine/godot-class-reference/zh_Hans/>\n"
@@ -73,7 +73,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8-bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-"X-Generator: Weblate 4.15-dev\n"
+"X-Generator: Weblate 4.15.1-dev\n"
#: doc/tools/make_rst.py
msgid "Description"
@@ -730,7 +730,6 @@ msgstr ""
"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
-#, fuzzy
msgid ""
"Returns an array of dictionaries representing the current call stack. See "
"also [method print_stack].\n"
@@ -754,7 +753,7 @@ msgid ""
"get_stack] will not work in projects exported in release mode, or in "
"projects exported in debug mode if not connected to a debugging server."
msgstr ""
-"返回一个表示当å‰è°ƒç”¨å †æ ˆçš„字典数组。\n"
+"返回一个表示当å‰è°ƒç”¨å †æ ˆçš„字典数组。å¦è¯·å‚阅 [method print_stack]。\n"
"[codeblock]\n"
"func _ready():\n"
" foo()\n"
@@ -769,7 +768,11 @@ msgstr ""
"[codeblock]\n"
"[{function:bar, line:12, source:res://script.gd}, {function:foo, line:9, "
"source:res://script.gd}, {function:_ready, line:6, source:res://script.gd}]\n"
-"[/codeblock]"
+"[/codeblock]\n"
+"[b]注æ„:[/b]è¿è¡Œä¸­çš„实例连接到调试æœåŠ¡å™¨ï¼ˆä¾‹å¦‚编辑器实例)åŽï¼Œ[method "
+"get_stack] æ‰èƒ½æ­£å¸¸å·¥ä½œã€‚[method get_stack] 无法在使用å‘布模å¼å¯¼å‡ºçš„项目中正"
+"常工作。使用调试模å¼å¯¼å‡ºçš„项目如果没有连接到调试æœåŠ¡å™¨ï¼Œåˆ™è¯¥å‡½æ•°ä¹Ÿæ— æ³•æ­£å¸¸å·¥"
+"作。"
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -1367,6 +1370,15 @@ msgid ""
"print_stack] will not work in projects exported in release mode, or in "
"projects exported in debug mode if not connected to a debugging server."
msgstr ""
+"输出当å‰ä»£ç ä½ç½®çš„栈追踪。å¦è¯·å‚阅 [method get_stack]。\n"
+"控制å°ä¸­çš„输出是类似这样的:\n"
+"[codeblock]\n"
+"Frame 0 - res://test.gd:16 in function '_process'\n"
+"[/codeblock]\n"
+"[b]注æ„:[/b]è¿è¡Œä¸­çš„实例连接到调试æœåŠ¡å™¨ï¼ˆä¾‹å¦‚编辑器实例)åŽï¼Œ[method "
+"print_stack] æ‰èƒ½æ­£å¸¸å·¥ä½œã€‚[method print_stack] 无法在使用å‘布模å¼å¯¼å‡ºçš„项目"
+"中正常工作。使用调试模å¼å¯¼å‡ºçš„项目如果没有连接到调试æœåŠ¡å™¨ï¼Œåˆ™è¯¥å‡½æ•°ä¹Ÿæ— æ³•æ­£"
+"常工作。"
#: modules/gdscript/doc_classes/@GDScript.xml
msgid ""
@@ -4407,6 +4419,18 @@ msgid ""
"[b]Note:[/b] The final colon is required to specify for properly detecting "
"built-in types."
msgstr ""
+"æ示一个属性代表特定的类型。如果属性为 [constant TYPE_STRING],则å¯ä»¥é€šè¿‡åˆ›å»º"
+"对è¯æ¡†è®¾ç½®å…¶ç±»åž‹ã€‚如果你需è¦åˆ›å»ºä¸€ä¸ª [Array] æ¥æ”¾ç½®ç‰¹å®šç±»åž‹çš„元素,则 "
+"[code]hint_string[/code] 必须使用 [code]\":\"[/code] æ¥ç¼–ç åµŒå¥—类型,使用 "
+"[code]\"/\"[/code] æ¥æŒ‡å®š [Resource] 类型。例如:\n"
+"[codeblock]\n"
+"hint_string = \"%s:\" % [TYPE_INT] # 整数数组。\n"
+"hint_string = \"%s:%s:\" % [TYPE_ARRAY, TYPE_REAL] # 浮点数二维数组。\n"
+"hint_string = \"%s/%s:Resource\" % [TYPE_OBJECT, TYPE_OBJECT] # 资æºæ•°ç»„。\n"
+"hint_string = \"%s:%s/%s:Resource\" % [TYPE_ARRAY, TYPE_OBJECT, TYPE_OBJECT] "
+"# 资æºäºŒç»´æ•°ç»„。\n"
+"[/codeblock]\n"
+"[b]注æ„:[/b]最åŽçš„冒å·æ˜¯å¿…须的,å¦åˆ™æ— æ³•æ­£ç¡®æ£€æµ‹å†…置类型。"
#: doc/classes/@GlobalScope.xml
msgid "The property is serialized and saved in the scene file (default)."
@@ -8808,7 +8832,6 @@ msgstr ""
"较慢。这是因为所有放置在删除元素之åŽçš„元素都必须é‡æ–°ç´¢å¼•ã€‚"
#: doc/classes/Array.xml
-#, fuzzy
msgid ""
"Assigns the given value to all elements in the array. This can typically be "
"used together with [method resize] to create an array with a given size and "
@@ -8828,7 +8851,9 @@ msgstr ""
"var array = []\n"
"array.resize(10)\n"
"array.fill(0) # å°† 10 个元素都åˆå§‹åŒ–为 0。\n"
-"[/codeblock]"
+"[/codeblock]\n"
+"[b]注æ„:[/b]如果 [code]value[/code] 为引用类型(派生自 [Object]ã€[Array]ã€"
+"[Dictionary] 等),那么会用åŒä¸€ä¸ªå¯¹è±¡çš„引用填充该数组,å³ä¸ä¼šåˆ›å»ºå‰¯æœ¬ã€‚"
#: doc/classes/Array.xml doc/classes/PoolByteArray.xml
#: doc/classes/PoolColorArray.xml doc/classes/PoolIntArray.xml
@@ -9076,7 +9101,6 @@ msgstr ""
"索引之间的å˜åŒ–。"
#: doc/classes/Array.xml
-#, fuzzy
msgid ""
"Sorts the array.\n"
"[b]Note:[/b] The sorting algorithm used is not [url=https://en.wikipedia.org/"
@@ -9092,6 +9116,9 @@ msgid ""
"[/codeblock]"
msgstr ""
"对数组进行排åºã€‚\n"
+"[b]注æ„:[/b]排åºæ‰€ä½¿ç”¨çš„算法并ä¸[url=https://zh.wikipedia.org/wiki/"
+"%E6%8E%92%E5%BA%8F%E7%AE%97%E6%B3%95#%E7%A9%A9%E5%AE%9A%E6%80%A7]稳定[/url]。"
+"也就是说,使用 [method sort] 时相等的值之间的顺åºå¯èƒ½ä¼šæ”¹å˜ã€‚\n"
"[b]注æ„:[/b]字符串按字æ¯é¡ºåºæŽ’åºï¼ˆä¸Žè‡ªç„¶é¡ºåºç›¸å)。当对一个以数字åºåˆ—结尾的"
"字符串数组进行排åºæ—¶ï¼Œè¿™å¯èƒ½ä¼šå¯¼è‡´æ„外的行为。请看下é¢çš„例å­ã€‚\n"
"[codeblock]\n"
@@ -9101,7 +9128,6 @@ msgstr ""
"[/codeblock]"
#: doc/classes/Array.xml
-#, fuzzy
msgid ""
"Sorts the array using a custom method. The arguments are an object that "
"holds the method and the name of such method. The custom method receives two "
@@ -9135,8 +9161,11 @@ msgstr ""
"对于两个元素 [code]a[/code] 和 [code]b[/code],如果给定的方法返回 "
"[code]true[/code],数组中的元素 [code]b[/code] 将排在元素 [code]a[/code] 之"
"åŽã€‚\n"
-"[b]注æ„:[/b]ä½ ä¸èƒ½éšæœºåŒ–返回值,因为堆排åºç®—法期望一个确定的结果。而这样åšä¼š"
-"导致æ„外的行为。\n"
+"[b]注æ„:[/b]排åºæ‰€ä½¿ç”¨çš„算法并ä¸[url=https://zh.wikipedia.org/wiki/"
+"%E6%8E%92%E5%BA%8F%E7%AE%97%E6%B3%95#%E7%A9%A9%E5%AE%9A%E6%80%A7]稳定[/url]。"
+"也就是说,使用 [method sort] 时相等的值之间的顺åºå¯èƒ½ä¼šæ”¹å˜ã€‚\n"
+"[b]注æ„:[/b]ä¸èƒ½éšæœºè¿”回一个值,因为堆排åºç®—法期望确定的结果。éšæœºè¿”回一个值"
+"会导致æ„外的行为。\n"
"[codeblock]\n"
"class MyCustomSorter:\n"
" static func sort_ascending(a, b):\n"
@@ -9787,7 +9816,7 @@ msgid ""
"However, at this point in time only one interface can render to an HMD."
msgstr ""
"调用这个æ¥åˆå§‹åŒ–这个接å£ã€‚第一个被åˆå§‹åŒ–的接å£ç¡®å®šä¸ºä¸»æŽ¥å£ï¼Œç”¨äºŽæ¸²æŸ“输出。\n"
-"在åˆå§‹åŒ–了接å£ä¹‹åŽï¼Œéœ€è¦å¯ç”¨è§†çª—çš„ AR/VR 模å¼ï¼Œå°†å¼€å§‹æ¸²æŸ“。\n"
+"在åˆå§‹åŒ–了接å£ä¹‹åŽï¼Œéœ€è¦å¯ç”¨è§†å£çš„ AR/VR 模å¼ï¼Œå°†å¼€å§‹æ¸²æŸ“。\n"
"[b]注æ„:[/b]对于任何使用 Godot 主输出的设备,如移动 VR,你必须在主视å£ä¸Šå¯"
"用 AR/VR 模å¼ã€‚\n"
"如果你为一个处ç†è‡ªå·±è¾“出的平å°è¿™æ ·åšï¼ˆå¦‚ OpenVR),Godot 就会在å±å¹•ä¸Šåªæ˜¾ç¤ºä¸€"
@@ -9844,9 +9873,9 @@ msgid ""
"[method get_render_targetsize]). Using a separate viewport node frees up the "
"main viewport for other purposes."
msgstr ""
-"这个接å£è¾“出到一个外部设备。如果使用主视区,å±å¹•ä¸Šçš„输出是一个未ç»ä¿®æ”¹çš„左眼"
-"或å³çœ¼çš„缓冲区,如果没有将视窗尺寸更改为 [method get_render_targetsize] 的相"
-"åŒé•¿å®½æ¯”,则被拉伸。使用一个å•ç‹¬çš„视窗节点å¯ä»¥é‡Šæ”¾å‡ºä¸»è§†åŒºï¼Œç”¨äºŽå…¶ä»–用途。"
+"这个接å£è¾“出到一个外部设备。如果使用主视å£ï¼Œå±å¹•ä¸Šçš„输出是一个未ç»ä¿®æ”¹çš„左眼"
+"或å³çœ¼çš„缓冲区,如果没有将视å£å°ºå¯¸æ›´æ”¹ä¸º [method get_render_targetsize] 的相"
+"åŒé•¿å®½æ¯”,则被拉伸。使用一个å•ç‹¬çš„视å£èŠ‚点å¯ä»¥é‡Šæ”¾å‡ºä¸»è§†å£ï¼Œç”¨äºŽå…¶ä»–用途。"
#: doc/classes/ARVRInterface.xml
msgid ""
@@ -12402,14 +12431,13 @@ msgid "Clears the audio sample data buffer."
msgstr "清除音频样本数æ®ç¼“冲区。"
#: doc/classes/AudioStreamGeneratorPlayback.xml
-#, fuzzy
msgid ""
"Returns the number of frames that can be pushed to the audio sample data "
"buffer without overflowing it. If the result is [code]0[/code], the buffer "
"is full."
msgstr ""
-"如果å¯ä»¥å°†å¤§å°ä¸º [code]amount[/code] 的缓冲区推é€åˆ°éŸ³é¢‘采样数æ®ç¼“冲区而ä¸ä½¿å…¶"
-"溢出,则返回 [code]true[/code],å¦åˆ™è¿”回 [code]false[/code]。"
+"返回能够推é€åˆ°éŸ³é¢‘采样数æ®ç¼“冲区而ä¸ä½¿å…¶æº¢å‡ºçš„帧数。如果结果为 [code]0[/"
+"code],则缓冲区已满。"
#: doc/classes/AudioStreamGeneratorPlayback.xml
msgid ""
@@ -13042,7 +13070,6 @@ msgstr ""
"[code]texture(SCREEN_TEXTURE, ...)[/code] 函数在ç€è‰²å™¨è„šæœ¬ä¸­å¯¹å…¶è¿›è¡Œè®¿é—®ã€‚"
#: doc/classes/BackBufferCopy.xml
-#, fuzzy
msgid ""
"Node for back-buffering the currently-displayed screen. The region defined "
"in the [BackBufferCopy] node is buffered with the content of the screen it "
@@ -13055,44 +13082,40 @@ msgid ""
"derived nodes as [i]siblings[/i] to the [BackBufferCopy] node instead of "
"adding them as children."
msgstr ""
-"用于对当å‰å±å¹•æ˜¾ç¤ºè¿›è¡ŒåŽå°ç¼“冲的节点。BackBufferCopy 节点中定义的区域与其覆盖"
-"å±å¹•çš„内容一起缓冲,或者根æ®æ‹·è´æ¨¡å¼è®¾ç½®çš„整个å±å¹•è¿›è¡Œç¼“冲。在ç€è‰²å™¨è„šæœ¬ä¸­ä½¿"
-"用 [code]texture(SCREEN_TEXTURE, ...)[/code] 函数æ¥è®¿é—®ç¼“冲区。\n"
+"用于对当å‰æ˜¾ç¤ºçš„å±å¹•è¿›è¡ŒåŽå°ç¼“冲的节点。[BackBufferCopy] 节点中定义的区域与其"
+"覆盖å±å¹•çš„内容一起缓冲,或者根æ®æ‹·è´æ¨¡å¼è®¾ç½®çš„整个å±å¹•è¿›è¡Œç¼“冲。在ç€è‰²å™¨è„šæœ¬"
+"中使用 [code]texture(SCREEN_TEXTURE, ...)[/code] 函数æ¥è®¿é—®ç¼“冲区。\n"
"[b]注æ„:[/b]由于该节点继承自 [Node2D] è€Œéž [Control],锚点和边è·å°†ä¸ä¼šåº”用于"
"从 [Control] 派生的å­èŠ‚点。这在调整窗å£å¤§å°æ—¶å¯èƒ½ä¼šå‡ºçŽ°é—®é¢˜ã€‚为é¿å…è¿™ç§æƒ…况,"
-"请将 [Control] 派生节点添加为 BackBufferCopy 节点的[i]åŒçº§[/i],ä¸è¦å°†å®ƒä»¬æ·»"
-"加为其å­èŠ‚点。"
+"请将 [Control] 派生节点添加为 [BackBufferCopy] 节点的[i]åŒçº§[/i],ä¸è¦å°†å®ƒä»¬"
+"添加为其å­èŠ‚点。"
#: doc/classes/BackBufferCopy.xml
msgid "Buffer mode. See [enum CopyMode] constants."
msgstr "缓冲区模å¼ã€‚è§ [enum CopyMode] 常é‡ã€‚"
#: doc/classes/BackBufferCopy.xml
-#, fuzzy
msgid ""
"The area covered by the [BackBufferCopy]. Only used if [member copy_mode] is "
"[constant COPY_MODE_RECT]."
msgstr ""
-"BackBufferCopy 覆盖的区域。åªæœ‰å½“ [member copy_mode] 是 [constant "
+"该 [BackBufferCopy] 所覆盖的区域。åªæœ‰å½“ [member copy_mode] 为 [constant "
"COPY_MODE_RECT] æ—¶æ‰ä½¿ç”¨ã€‚"
#: doc/classes/BackBufferCopy.xml
-#, fuzzy
msgid ""
"Disables the buffering mode. This means the [BackBufferCopy] node will "
"directly use the portion of screen it covers."
msgstr ""
-"ç¦ç”¨ç¼“冲模å¼ã€‚è¿™æ„å‘³ç€ BackBufferCopy 节点将直接使用它所覆盖的å±å¹•éƒ¨åˆ†ã€‚"
+"ç¦ç”¨ç¼“冲模å¼ã€‚è¿™æ„味ç€è¯¥ [BackBufferCopy] 节点将直接使用它所覆盖的å±å¹•éƒ¨åˆ†ã€‚"
#: doc/classes/BackBufferCopy.xml
-#, fuzzy
msgid "[BackBufferCopy] buffers a rectangular region."
-msgstr "BackBufferCopy 缓冲一个矩形区域。"
+msgstr "[BackBufferCopy] 缓冲一个矩形区域。"
#: doc/classes/BackBufferCopy.xml
-#, fuzzy
msgid "[BackBufferCopy] buffers the entire screen."
-msgstr "BackBufferCopy 缓冲整个å±å¹•ã€‚"
+msgstr "[BackBufferCopy] 缓冲整个å±å¹•ã€‚"
#: doc/classes/BakedLightmap.xml
msgid "Prerendered indirect light map for a scene."
@@ -14561,9 +14584,9 @@ msgid ""
"[Viewport] (or higher viewports) can't be displayed."
msgstr ""
"相机是一个特殊节点,用于显示从其当å‰ä½ç½®å¯è§çš„内容。相机在最近的 [Viewport] "
-"节点中注册自己(当树上行)。æ¯ä¸ªè§†åŒºåªèƒ½æ¿€æ´»ä¸€ä¸ªç›¸æœºã€‚如果在树上没有å¯ç”¨çš„视"
-"区,相机将在全局视区中注册。æ¢å¥è¯è¯´ï¼Œç›¸æœºåªæ˜¯ä¸º [Viewport] æä¾› 3D 显示能"
-"力,如果没有,则无法显示在该 [Viewport] 或更高视区中注册的场景。"
+"节点中注册自己(当树上行)。æ¯ä¸ªè§†å£åªèƒ½æ¿€æ´»ä¸€ä¸ªç›¸æœºã€‚如果在树上没有å¯ç”¨çš„视"
+"å£ï¼Œç›¸æœºå°†åœ¨å…¨å±€è§†å£ä¸­æ³¨å†Œã€‚æ¢å¥è¯è¯´ï¼Œç›¸æœºåªæ˜¯ä¸º [Viewport] æä¾› 3D 显示能"
+"力,如果没有,则无法显示在该 [Viewport] 或更高视å£ä¸­æ³¨å†Œçš„场景。"
#: doc/classes/Camera.xml
msgid ""
@@ -14720,7 +14743,7 @@ msgid ""
"[/codeblock]"
msgstr ""
"返回 [Viewport] 矩形中的 2D å标,该å标映射到世界空间中给定的 3D 点。\n"
-"[b]注æ„:[/b]当使用它æ¥å®šä½ 3D 视区上的 GUI 元素时,如果 3D 点在相机åŽé¢ï¼Œè¯·"
+"[b]注æ„:[/b]当使用它æ¥å®šä½ 3D 视å£ä¸Šçš„ GUI 元素时,如果 3D 点在相机åŽé¢ï¼Œè¯·"
"使用 [method is_position_behind] æ¥é˜²æ­¢å®ƒä»¬æ˜¾ç¤ºã€‚\n"
"[codeblock]\n"
"# 这个代ç å—是继承自 Spatial 的脚本的一部分。\n"
@@ -14768,7 +14791,7 @@ msgstr ""
"[code]_process[/code] 方法中的å˜åŒ–。多普勒效果åªå¯¹ [member "
"AudioStreamPlayer3D.doppler_tracking] 设置为 [constant AudioStreamPlayer3D."
"DOPPLER_TRACKING_DISABLED] 以外的值的 [AudioStreamPlayer3D] 节点进行模拟。\n"
-"[b]注æ„:[/b]è¦åœ¨ç¼–辑器中切æ¢å¤šæ™®å‹’效果预览,使用 3D 视区左上角的é€è§†èœå•ï¼Œå¹¶"
+"[b]注æ„:[/b]è¦åœ¨ç¼–辑器中切æ¢å¤šæ™®å‹’效果预览,使用 3D 视å£å·¦ä¸Šè§’çš„é€è§†èœå•ï¼Œå¹¶"
"切æ¢ä¸º[b]å¯ç”¨å¤šæ™®å‹’[/b]。"
#: doc/classes/Camera.xml
@@ -14816,7 +14839,7 @@ msgstr ""
#: doc/classes/Camera.xml
msgid "The horizontal (X) offset of the camera viewport."
-msgstr "相机视窗的水平(X)å移é‡ã€‚"
+msgstr "相机视å£çš„水平(X)å移é‡ã€‚"
#: doc/classes/Camera.xml
msgid ""
@@ -14852,7 +14875,7 @@ msgstr ""
#: doc/classes/Camera.xml
msgid "The vertical (Y) offset of the camera viewport."
-msgstr "相机视窗的垂直(Y)å移é‡ã€‚"
+msgstr "相机视å£çš„垂直(Y)å移é‡ã€‚"
#: doc/classes/Camera.xml
msgid ""
@@ -15023,7 +15046,7 @@ msgstr ""
msgid ""
"Make this the current 2D camera for the scene (viewport and layer), in case "
"there are many cameras in the scene."
-msgstr "使之æˆä¸ºè¯¥åœºæ™¯ï¼ˆè§†åŒºå’Œå›¾å±‚ï¼‰çš„å½“å‰ 2D 相机,以防场景中有很多相机。"
+msgstr "使之æˆä¸ºè¯¥åœºæ™¯ï¼ˆè§†å£å’Œå›¾å±‚ï¼‰çš„å½“å‰ 2D 相机,以防场景中有很多相机。"
#: doc/classes/Camera2D.xml
msgid ""
@@ -15070,7 +15093,7 @@ msgid ""
"or not a [Viewport], uses the default viewport instead."
msgstr ""
"连接到 [Camera2D] 的自定义 [Viewport] 节点。如果为 [code]null[/code] 或者ä¸"
-"是 [Viewport],则使用默认的视区。"
+"是 [Viewport],则使用默认的视å£ã€‚"
#: doc/classes/Camera2D.xml
msgid ""
@@ -15883,11 +15906,11 @@ msgstr "返回此项目的å˜æ¢çŸ©é˜µã€‚"
#: doc/classes/CanvasItem.xml
msgid "Returns the viewport's boundaries as a [Rect2]."
-msgstr "以 [Rect2] å½¢å¼è¿”回视区的边界。"
+msgstr "以 [Rect2] å½¢å¼è¿”回视å£çš„边界。"
#: doc/classes/CanvasItem.xml
msgid "Returns this item's transform in relation to the viewport."
-msgstr "返回这个项目相对于视区的å˜æ¢ã€‚"
+msgstr "返回这个项目相对于视å£çš„å˜æ¢ã€‚"
#: doc/classes/CanvasItem.xml
msgid "Returns the [World2D] where this item is in."
@@ -16281,7 +16304,7 @@ msgid ""
"Together with [member follow_viewport_scale] it can be used for a pseudo 3D "
"effect."
msgstr ""
-"å¯ç”¨æ—¶ï¼Œè¯¥ [CanvasLayer] 会使用视区的å˜æ¢ï¼Œæ‰€ä»¥å®ƒä¼šéšç›¸æœºç§»åŠ¨ï¼Œè€Œä¸æ˜¯ä¿æŒåœ¨å±"
+"å¯ç”¨æ—¶ï¼Œè¯¥ [CanvasLayer] 会使用视å£çš„å˜æ¢ï¼Œæ‰€ä»¥å®ƒä¼šéšç›¸æœºç§»åŠ¨ï¼Œè€Œä¸æ˜¯ä¿æŒåœ¨å±"
"幕上的æŸä¸ªå›ºå®šä½ç½®ã€‚\n"
"与 [member follow_viewport_scale] é…åˆå¯ä»¥å®žçŽ°ä¼ª 3D 效果。"
@@ -19193,7 +19216,7 @@ msgid ""
msgstr ""
"加载指定为å‚æ•°çš„é…置文件。解æžæ–‡ä»¶çš„内容并将其加载到调用该方法的 "
"[ConfigFile] 对象中。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆæˆåŠŸæ—¶è¿”回 [code]OK[/code])。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/ConfigFile.xml
msgid ""
@@ -19204,7 +19227,7 @@ msgid ""
msgstr ""
"加载指定为å‚数的加密é…置文件,使用æ供的 [code]key[/code] 对其解密。解æžæ–‡ä»¶"
"的内容并将其加载到调用该方法的 [ConfigFile] 对象中。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆæˆåŠŸæ—¶è¿”回 [code]OK[/code])。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/ConfigFile.xml
msgid ""
@@ -19215,7 +19238,7 @@ msgid ""
msgstr ""
"加载作为å‚数的加密é…置文件,使用æ供的 [code]password[/code] 解密。该文件的内"
"容被解æžå¹¶åŠ è½½åˆ°è°ƒç”¨è¯¥æ–¹æ³•çš„ [ConfigFile] 对象中。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆæˆåŠŸæ—¶è¿”回 [code]OK[/code])。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/ConfigFile.xml
msgid ""
@@ -19225,7 +19248,7 @@ msgid ""
msgstr ""
"将传递的字符串解æžä¸ºé…置文件的内容。该字符串被解æžå¹¶åŠ è½½åˆ°è°ƒç”¨è¯¥æ–¹æ³•çš„ "
"ConfigFile 对象中。\n"
-"返回 [enum Error] 常é‡ä¹‹ä¸€ï¼ŒæˆåŠŸæ—¶è¿”回 [code]OK[/code]。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/ConfigFile.xml
msgid ""
@@ -19235,7 +19258,7 @@ msgid ""
msgstr ""
"å°† [ConfigFile] 对象的内容ä¿å­˜åˆ°æŒ‡å®šä¸ºå‚数的文件中。输出文件使用 INI æ ·å¼çš„结"
"构。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆæˆåŠŸæ—¶è¿”回 [code]OK[/code])。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/ConfigFile.xml
msgid ""
@@ -19246,7 +19269,7 @@ msgid ""
msgstr ""
"使用æ供的 [code]key[/code] å°† [ConfigFile] 对象的内容ä¿å­˜åˆ°ä½œä¸ºå‚数指定的 "
"AES-256 加密文件中。输出文件使用 INI æ ·å¼çš„结构。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆæˆåŠŸæ—¶è¿”回 [code]OK[/code])。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/ConfigFile.xml
msgid ""
@@ -19257,7 +19280,7 @@ msgid ""
msgstr ""
"å°† [ConfigFile] 对象的内容ä¿å­˜åˆ°ä½œä¸ºå‚数指定的 AES-256 加密文件中,使用æä¾›"
"的 [code]password[/code]进行加密。输出文件使用 INI 风格的结构。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆæˆåŠŸæ—¶è¿”回 [code]OK[/code])。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/ConfigFile.xml
msgid ""
@@ -19380,7 +19403,7 @@ msgid ""
"code] methods provided by this class."
msgstr ""
"所有 UI 相关节点的基类。[Control] 具有定义其范围的边界矩形ã€ç›¸å¯¹äºŽå…¶çˆ¶æŽ§ä»¶æˆ–"
-"当å‰è§†çª—的锚点ä½ç½®ä»¥åŠè¡¨ç¤ºé”šç‚¹å移的边è·ã€‚当节点ã€å…¶ä»»ä½•çˆ¶èŠ‚点或å±å¹•å°ºå¯¸å‘生"
+"当å‰è§†å£çš„锚点ä½ç½®ä»¥åŠè¡¨ç¤ºé”šç‚¹å移的边è·ã€‚当节点ã€å…¶ä»»ä½•çˆ¶èŠ‚点或å±å¹•å°ºå¯¸å‘生"
"å˜åŒ–时,边è·ä¼šè‡ªåŠ¨æ›´æ–°ã€‚\n"
"更多关于 Godot çš„ UI 系统ã€é”šç‚¹ã€è¾¹è·å’Œå®¹å™¨çš„ä¿¡æ¯ï¼Œè¯·å‚阅手册中的相关教程。è¦"
"构建çµæ´»çš„ UI,您需è¦æ··åˆä½¿ç”¨ä»Ž [Control] å’Œ [Container] 节点继承的 UI å…ƒ"
@@ -19557,8 +19580,8 @@ msgid ""
"propagating, even to nodes listening to [method Node._unhandled_input] or "
"[method Node._unhandled_key_input]."
msgstr ""
-"将输入事件标记为已处ç†ã€‚一旦接å—输入事件,它就会åœæ­¢ä¼ æ’­ï¼Œç”šè‡³ä¼ æ’­åˆ°æ­£åœ¨ä¾¦å¬"
-"[method Node._unhandled_input]或[method Node._unhandled_key_input]的节点。"
+"将输入事件标记为已处ç†ã€‚一旦接å—输入事件,传播就会åœæ­¢ï¼Œä¸ä¼šå†ä¼ æ’­åˆ°æ­£åœ¨ä¾¦å¬ "
+"[method Node._unhandled_input] 和 [method Node._unhandled_key_input] 的节点。"
#: doc/classes/Control.xml
msgid ""
@@ -20647,7 +20670,7 @@ msgid ""
"handled."
msgstr ""
"关闭模æ€æŽ§ä»¶æ—¶ï¼Œè¾“入是å¦ä¼ æ’­ã€‚\n"
-"如果为 [code]false[/code],事件处ç†å°†åœæ­¢åœ¨è§†åŒºçš„输入事件处ç†ã€‚该视区会先将模"
+"如果为 [code]false[/code],事件处ç†å°†åœæ­¢åœ¨è§†å£çš„输入事件处ç†ã€‚该视å£ä¼šå…ˆå°†æ¨¡"
"æ€æŽ§ä»¶éšè—,然åŽå†å°†è¾“入标记为已处ç†ã€‚"
#: doc/classes/Control.xml
@@ -20800,7 +20823,7 @@ msgstr ""
"这个值进行缩放。\n"
"[b]注æ„:[/b]这个属性主è¦ç”¨äºŽåŠ¨ç”»ç”¨é€”。当控件被缩放时,控件内的文本将看起æ¥æ˜¯"
"åƒç´ åŒ–或模糊的。è¦åœ¨ä½ çš„项目支æŒå¤šç§åˆ†è¾¨çŽ‡ï¼Œè¯·ä½¿ç”¨[url=$DOCS_URL/tutorials/"
-"rendering/multiple_resolutions.html]文档[/url]中æè¿°çš„åˆé€‚的视窗拉伸模å¼ï¼Œè€Œ"
+"rendering/multiple_resolutions.html]文档[/url]中æè¿°çš„åˆé€‚的视å£æ‹‰ä¼¸æ¨¡å¼ï¼Œè€Œ"
"ä¸æ˜¯å•ç‹¬ç¼©æ”¾æŽ§ä»¶ã€‚\n"
"[b]注æ„:[/b]如果控件节点是 [Container] 节点的å­èŠ‚点,当场景实例化时,缩放将"
"被é‡ç½®ä¸º [code]Vector2(1, 1)[/code]。è¦åœ¨å®žä¾‹åŒ–时设置控件的缩放,使用 "
@@ -24076,7 +24099,7 @@ msgstr ""
#: doc/classes/CylinderShape.xml
msgid "Cylinder shape for collisions."
-msgstr "碰撞用的圆柱体形状。"
+msgstr "用于碰撞的圆柱体形状。"
#: doc/classes/CylinderShape.xml
msgid ""
@@ -24085,6 +24108,9 @@ msgid ""
"engine, there are several known bugs with cylinder collision shapes. Using "
"[CapsuleShape] or [BoxShape] instead is recommended."
msgstr ""
+"用于碰撞的圆柱体形状。\n"
+"[b]注æ„:[/b]使用 GodotPhysics 而éžé»˜è®¤çš„ Bullet 物ç†å¼•æ“Žæ—¶ï¼Œåœ†æŸ±ä½“碰撞形状存"
+"在已知的问题。推è使用 [CapsuleShape] 或 [BoxShape] 代替。"
#: doc/classes/CylinderShape.xml
msgid "The cylinder's height."
@@ -24665,7 +24691,7 @@ msgstr ""
"将当å‰æ‰“开的目录改为å‚数传递的目录。å‚æ•°å¯ä»¥æ˜¯ç›¸å¯¹äºŽå½“å‰ç›®å½•çš„(例如 "
"[code]newdir[/code] 或 [code].../newdir[/code]),也å¯ä»¥æ˜¯ç»å¯¹è·¯å¾„(例如 "
"[code]/tmp/newdir[/code] 或 [code]res://somedir/newdir[/code])。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆ[code]OK[/code] æˆåŠŸæ—¶ï¼‰ã€‚"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/Directory.xml
msgid ""
@@ -24677,7 +24703,7 @@ msgid ""
msgstr ""
"å°† [code]from[/code] 文件å¤åˆ¶åˆ° [code]to[/code] 目标ä½ç½®ã€‚两个å‚数都应该是相"
"对或ç»å¯¹æ–‡ä»¶çš„路径。如果目标文件存在且没有访问ä¿æŠ¤ï¼Œåˆ™ä¼šè¢«è¦†ç›–。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆæˆåŠŸæ—¶è¿”回 [code]OK[/code])。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/Directory.xml
msgid ""
@@ -24685,8 +24711,8 @@ msgid ""
"call is a directory ([code].[/code] and [code]..[/code] are considered "
"directories)."
msgstr ""
-"返回上一次 [method get_next] 调用处ç†çš„当å‰é¡¹ç›®æ˜¯å¦ä¸ºç›®å½•ï¼ˆ[code].[/code]å’Œ"
-"[code].[/code]被认为是目录)。"
+"返回上一次 [method get_next] 调用处ç†çš„当å‰é¡¹ç›®æ˜¯å¦ä¸ºç›®å½•ï¼ˆ[code].[/code] å’Œ "
+"[code].[/code] 属于目录)。"
#: doc/classes/Directory.xml
msgid ""
@@ -24707,16 +24733,16 @@ msgid ""
"Returns the absolute path to the currently opened directory (e.g. "
"[code]res://folder[/code] or [code]C:\\tmp\\folder[/code])."
msgstr ""
-"返回当å‰æ‰“开目录的ç»å¯¹è·¯å¾„(例如[code]res://文件夹[/code]或[code]C:\\tmp\\æ–‡"
-"件夹[/code])。"
+"返回当å‰æ‰“开目录的ç»å¯¹è·¯å¾„(例如 [code]res://文件夹[/code] 或 [code]C:"
+"\\tmp\\文件夹[/code])。"
#: doc/classes/Directory.xml
msgid ""
"Returns the currently opened directory's drive index. See [method get_drive] "
"to convert returned index to the name of the drive."
msgstr ""
-"返回当å‰æ‰“开的目录的驱动器索引。请å‚阅[method get_drive]将返回的索引转æ¢ä¸ºé©±"
-"动器的å称。"
+"返回当å‰æ‰“开的目录的驱动器索引。请å‚阅 [method get_drive] 将返回的索引转æ¢ä¸º"
+"驱动器的å称。"
#: doc/classes/Directory.xml
msgid ""
@@ -24757,11 +24783,12 @@ msgid ""
"closes the stream automatically (i.e. [method list_dir_end] would not be "
"mandatory in such a case)."
msgstr ""
-"返回当å‰ç›®å½•ä¸­çš„下一个元素(文件或目录)(包括[code].[/code]å’Œ[code].[/"
-"code],除éž[code]skip_navigational[/code]被赋予[method list_dir_begin])。\n"
+"返回当å‰ç›®å½•ä¸­çš„下一个元素(文件或目录。除éžå°† [code]skip_navigational[/"
+"code] 赋予 [method list_dir_begin],å¦åˆ™åŒ…括 [code].[/code] å’Œ [code].[/"
+"code])。\n"
"返回的是文件或目录的å称(而ä¸æ˜¯å®ƒçš„完整路径)。一旦æµè¢«å®Œå…¨å¤„ç†ï¼Œè¯¥æ–¹æ³•è¿”回"
-"一个空的String,并自动关闭æµï¼ˆå³åœ¨è¿™ç§æƒ…况下,[method list_dir_end]å°†ä¸æ˜¯å¼ºåˆ¶"
-"性的)。"
+"一个空的 String,并自动关闭æµï¼ˆå³åœ¨è¿™ç§æƒ…况下,[method list_dir_end] å°†ä¸æ˜¯å¼º"
+"制性的)。"
#: doc/classes/Directory.xml
msgid ""
@@ -24808,7 +24835,7 @@ msgstr ""
"创建一个目录。å‚æ•°å¯ä»¥æ˜¯å½“å‰ç›®å½•çš„相对路径,也å¯ä»¥æ˜¯ç»å¯¹è·¯å¾„。目标目录应该放"
"置在一个已ç»å­˜åœ¨çš„目录中(如果è¦é€’归创建完整的路径,请å‚阅 [method "
"make_dir_recursive])。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆæˆåŠŸæ—¶è¿”回 [code]OK[/code])。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/Directory.xml
msgid ""
@@ -24817,9 +24844,9 @@ msgid ""
"to the current directory, or an absolute path.\n"
"Returns one of the [enum Error] code constants ([code]OK[/code] on success)."
msgstr ""
-"通过递归调用 [method make_dir]方法,创建一个目标目录和其路径中所有必è¦çš„中间"
+"通过递归调用 [method make_dir] 方法,创建一个目标目录和其路径中所有必è¦çš„中间"
"目录。å‚æ•°å¯ä»¥æ˜¯ç›¸å¯¹äºŽå½“å‰ç›®å½•çš„,也å¯ä»¥æ˜¯ç»å¯¹è·¯å¾„。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆæˆåŠŸæ—¶è¿”回 [code]OK[/code])。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/Directory.xml
msgid ""
@@ -24833,7 +24860,7 @@ msgstr ""
"folder[/code]),用户目录([code]user:// folder[/code])或以下ä½ç½®çš„ç»å¯¹è·¯å¾„"
"内:用户文件系统(例如 [code]/tmp/folder[/code] 或 [code]C:\\tmp\\folder[/"
"code])。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆæˆåŠŸæ—¶è¿”回 [code]OK[/code])。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/Directory.xml
msgid ""
@@ -24847,7 +24874,7 @@ msgstr ""
"永久删除目标文件或空目录。å‚æ•°å¯ä»¥æ˜¯ç›¸å¯¹äºŽå½“å‰ç›®å½•çš„,也å¯ä»¥æ˜¯ç»å¯¹è·¯å¾„。如果"
"目标目录ä¸æ˜¯ç©ºçš„,æ“作将失败。\n"
"如果你ä¸æƒ³æ°¸ä¹…删除该文件/目录,请使用 [method OS.move_to_trash] 代替。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ˆæˆåŠŸæ—¶è¿”回 [code]OK[/code])。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/Directory.xml
msgid ""
@@ -24860,7 +24887,7 @@ msgstr ""
"å°† [code]from[/code] 文件或目录é‡å‘½å且移动到 [code]to[/code] 目标。两个å‚æ•°"
"都应该是文件或目录的相对路径或ç»å¯¹è·¯å¾„。如果目标文件或目录存在且ä¸å—访问ä¿"
"护,它将被覆盖。\n"
-"返回 [enum Error] 代ç å¸¸é‡ä¹‹ä¸€ï¼ŒæˆåŠŸæ—¶è¿”回 [code]OK[/code]。"
+"返回 [enum Error] 错误ç å¸¸é‡ï¼ˆæˆåŠŸæ—¶ä¸º [code]OK[/code])。"
#: doc/classes/DTLSServer.xml
msgid "Helper class to implement a DTLS server."
@@ -25127,7 +25154,7 @@ msgid ""
"This can be a negative number to make the distance between words smaller."
msgstr ""
"空格字符(在 [member extra_spacing_char] 之外)的é¢å¤–é—´è·ï¼Œå•ä½ä¸ºåƒç´ ã€‚\n"
-"è¿™å¯ä»¥æ˜¯è´Ÿæ•°ï¼Œä½¿å­—符之间的è·ç¦»æ›´å°ã€‚"
+"å¯ä»¥æ˜¯è´Ÿæ•°ï¼Œä¼šä½¿å­—符之间的è·ç¦»æ›´å°ã€‚"
#: doc/classes/DynamicFont.xml
msgid "Extra spacing at the top in pixels."
@@ -25166,9 +25193,9 @@ msgid ""
"control whose size changes over time, unless a pixel art aesthetic is "
"desired."
msgstr ""
-"如果为 [code]true[/code],将使用过滤功能。如果字体过度采样被ç¦ç”¨æˆ–无效,这将"
-"使字体在缩放时å˜å¾—模糊,而éžåƒç´ åŒ–。当在尺寸éšæ—¶å˜åŒ–的控件中使用字体时,建议"
-"å¯ç”¨è¿™ä¸ªåŠŸèƒ½ï¼Œé™¤éžæ˜¯åƒç´ è®¾è®¡ã€‚"
+"如果为 [code]true[/code],将使用过滤功能。如果字体过采样被ç¦ç”¨æˆ–无法生效,字"
+"体在缩放时会å˜å¾—模糊,而éžåƒç´ åŒ–。在尺寸会éšæ—¶å˜åŒ–的控件中使用字体时,建议å¯"
+"用这个功能,除éžæƒ³è¦åƒç´ ç”»é£Žæ ¼ã€‚"
#: doc/classes/DynamicFont.xml
msgid ""
@@ -25176,8 +25203,8 @@ msgid ""
"appearance when downscaling it if font oversampling is disabled or "
"ineffective."
msgstr ""
-"如果为 [code]true[/code],将使用 mipmap 多级æ¸è¿œçº¹ç†ã€‚在字体过度采样被ç¦ç”¨æˆ–"
-"无效时,å¯æ”¹å–„字体缩å°æ—¶çš„表现。"
+"如果为 [code]true[/code],将使用 mipmap 多级æ¸è¿œçº¹ç†ã€‚在字体过采样被ç¦ç”¨æˆ–æ— "
+"法生效时,å¯æ”¹å–„字体缩å°æ—¶çš„表现。"
#: doc/classes/DynamicFont.xml
msgid "Spacing at the top."
@@ -25229,7 +25256,7 @@ msgid ""
"and viewport stretch mode."
msgstr ""
"如果设为比 [code]0.0[/code] 大的值,则会覆盖默认的字体过采样,忽略 [member "
-"SceneTree.use_font_oversampling] 的值和视å£æ‹‰ä¼¸æ¨¡å¼ã€‚"
+"SceneTree.use_font_oversampling] 的值和视å£çš„拉伸模å¼ã€‚"
#: doc/classes/DynamicFontData.xml
msgid "Disables font hinting (smoother but less crisp)."
@@ -26338,7 +26365,7 @@ msgstr ""
"新)加载场景,渲染网格预览,检查和编辑资æºå’Œå¯¹è±¡ã€‚它å…许自定义窗å£ï¼Œä¿å­˜å’Œ"
"(é‡æ–°ï¼‰åŠ è½½åœºæ™¯ï¼Œæ¸²æŸ“网格预览,检查和编辑资æºå’Œå¯¹è±¡ï¼Œå¹¶æ供对 "
"[EditorSettings]ã€[EditorFileSystem]ã€[EditorResourcePreview]ã€"
-"[ScriptEditor]ã€ç¼–辑器视窗和场景信æ¯çš„访问。\n"
+"[ScriptEditor]ã€ç¼–辑器视å£å’Œåœºæ™¯ä¿¡æ¯çš„访问。\n"
"[b]注æ„:[/b]这个类ä¸åº”该直接实例化。相å,使用 [method EditorPlugin."
"get_editor_interface] 访问å•ä¾‹ã€‚"
@@ -26414,7 +26441,7 @@ msgid ""
msgstr ""
"返回主编辑器控件。将其作为主å±å¹•çš„父控件。\n"
"[b]注æ„:[/b]这将返回包å«æ•´ä¸ªç¼–辑器的主编辑器控件,而ä¸æ˜¯å…·ä½“çš„ 2D或 3D 视"
-"窗。\n"
+"å£ã€‚\n"
"[b]警告:[/b]删除和释放这个节点将使编辑器的一部分失去作用,并å¯èƒ½å¯¼è‡´å´©æºƒã€‚"
#: doc/classes/EditorInterface.xml
@@ -26734,7 +26761,7 @@ msgid ""
"custom gizmos to the 3D preview viewport for a [Spatial].\n"
"See [method add_inspector_plugin] for an example of how to register a plugin."
msgstr ""
-"注册一个新的 [EditorSpatialGizmoPlugin]。å°å·¥å…·æ’件å¯ä»¥åœ¨ 3D 预览视区中为 "
+"注册一个新的 [EditorSpatialGizmoPlugin]。å°å·¥å…·æ’件å¯ä»¥åœ¨ 3D 预览视å£ä¸­ä¸º "
"[Spatial] 添加自定义的å°å·¥å…·ã€‚\n"
"注册æ’ä»¶çš„ç¤ºä¾‹è§ [method add_inspector_plugin]。"
@@ -26830,8 +26857,8 @@ msgid ""
" return false\n"
"[/codeblock]"
msgstr ""
-"引擎会在 2D 编辑器的视区å‘生更新时调用。使用 [code]overlay[/code] [Control] "
-"进行绘制。你å¯ä»¥é€šè¿‡è°ƒç”¨ [method update_overlays] 手动更新视窗。\n"
+"引擎会在 2D 编辑器的视å£å‘生更新时调用。使用 [code]overlay[/code] [Control] "
+"进行绘制。你å¯ä»¥é€šè¿‡è°ƒç”¨ [method update_overlays] 手动更新视å£ã€‚\n"
"[codeblock]\n"
"func forward_canvas_draw_over_viewport(overlay):\n"
" # 在光标ä½ç½®ç”»ä¸€ä¸ªåœ†ã€‚\n"
@@ -26840,7 +26867,7 @@ msgstr ""
"\n"
"func forward_canvas_gui_input(event):\n"
" if event is InputEventMouseMotion:\n"
-" # 当光标被移动时,é‡ç»˜è§†çª—。\n"
+" # 当光标被移动时,é‡ç»˜è§†å£ã€‚\n"
" update_overlays()\n"
" return true\n"
" return false\n"
@@ -26883,7 +26910,7 @@ msgid ""
" return forward\n"
"[/codeblock]"
msgstr ""
-"当当å‰ç¼–辑场景中有一个根节点时被调用,[method handles]实现,在2D视窗中å‘生按"
+"当当å‰ç¼–辑场景中有一个根节点时被调用,[method handles]实现,在2D视å£ä¸­å‘生按"
"键输入[InputEvent]。拦截按键输入[InputEvent],如果[code]return true[/code] "
"[EditorPlugin]消耗键值[code]event[/code],å¦åˆ™å°†é”®å€¼[code]event[/code]转å‘ç»™"
"其他Editor类。例å­:\n"
@@ -26922,9 +26949,9 @@ msgid ""
" return false\n"
"[/codeblock]"
msgstr ""
-"引擎会在 3D 编辑器的视区å‘生更新时调用。使用 [code]overlay[/code] 控件 "
+"引擎会在 3D 编辑器的视å£å‘生更新时调用。使用 [code]overlay[/code] 控件 "
"[Control] 进行绘制。你å¯ä»¥é€šè¿‡è°ƒç”¨ [method update_overlays] 更新覆盖手动更新"
-"视窗。\n"
+"视å£ã€‚\n"
"[codeblock]\n"
"func forward_spatial_draw_over_viewport(overlay):\n"
" # 在光标ä½ç½®ç”»ä¸€ä¸ªåœ†ã€‚\n"
@@ -26932,7 +26959,7 @@ msgstr ""
"\n"
"func forward_spatial_gui_input(camera, event):\n"
" if event is InputEventMouseMotion:\n"
-" # 当光标被移动时,é‡ç»˜è§†çª—。\n"
+" # 当光标被移动时,é‡ç»˜è§†å£ã€‚\n"
" update_overlays()\n"
" return true\n"
" return false\n"
@@ -26975,7 +27002,7 @@ msgid ""
" return forward\n"
"[/codeblock]"
msgstr ""
-"在当å‰ç¼–辑的场景中存在根节点时调用,实现[method handles]并在3D视窗中å‘生按键"
+"在当å‰ç¼–辑的场景中存在根节点时调用,实现[method handles]并在3D视å£ä¸­å‘生按键"
"输入[InputEvent]。拦截按键输入[InputEvent],如果[code]return true[/code],则"
"[EditorPlugin]会使用键值[code]event[/code],å¦åˆ™å°†é”®å€¼[code]event[/code]转å‘"
"到其他Editor类。例å­ï¼š\n"
@@ -27245,7 +27272,7 @@ msgid ""
"once and it will work permanently for this plugin."
msgstr ""
"å¯ç”¨ 2D 编辑器的 [method forward_canvas_force_draw_over_viewport] å’Œ 3D 编辑"
-"器的 [method forward_spatial_force_draw_over_viewport] 在其视窗更新时的调用。"
+"器的 [method forward_spatial_force_draw_over_viewport] 在其视å£æ›´æ–°æ—¶çš„调用。"
"ä½ åªéœ€è¦è°ƒç”¨è¿™ä¸ªæ–¹æ³•ä¸€æ¬¡ï¼Œå®ƒå°±ä¼šå¯¹è¿™ä¸ªæ’件永久起作用。"
#: doc/classes/EditorPlugin.xml
@@ -27312,7 +27339,7 @@ msgid ""
"forward_spatial_draw_over_viewport] and [method "
"forward_spatial_force_draw_over_viewport] to be called."
msgstr ""
-"更新 2D 和 3D 编辑器视窗的覆盖层。导致方法 [method "
+"æ›´æ–° 2D å’Œ 3D 编辑器视å£çš„覆盖层。导致方法 [method "
"forward_canvas_draw_over_viewport]ã€[method "
"forward_canvas_force_draw_over_viewport]ã€[method "
"forward_spatial_draw_over_viewport] 和 [method "
@@ -27890,7 +27917,6 @@ msgid "Base script that can be used to add extension functions to the editor."
msgstr "å¯ç”¨äºŽä¸ºç¼–辑器添加扩展功能的基础脚本。"
#: doc/classes/EditorScript.xml
-#, fuzzy
msgid ""
"Scripts extending this class and implementing its [method _run] method can "
"be executed from the Script Editor's [b]File > Run[/b] menu option (or by "
@@ -27927,7 +27953,9 @@ msgstr ""
" print(\"Hello from the Godot Editor!\")\n"
"[/codeblock]\n"
"[b]注æ„:[/b]脚本在编辑器上下文中è¿è¡Œï¼Œè¿™æ„味ç€è¾“出在与编辑器一起å¯åŠ¨çš„控制å°"
-"窗å£ï¼ˆstdout),而ä¸æ˜¯é€šå¸¸çš„ Godot [b]输出[/b]é¢æ¿ 。"
+"窗å£ï¼ˆstdout),而ä¸æ˜¯é€šå¸¸çš„ Godot [b]输出[/b]é¢æ¿ 。\n"
+"[b]注æ„:[/b]EditorScript 进行了引用计数,ä¸å†è¢«å¼•ç”¨æ—¶å°±ä¼šè¢«é”€æ¯ã€‚在进行异步"
+"æ“作时,如果ä¸å†å­˜åœ¨å¯¹è¯¥è„šæœ¬çš„引用,就å¯èƒ½é€ æˆé”™è¯¯ã€‚"
#: doc/classes/EditorScript.xml
msgid "This method is executed by the Editor when [b]File > Run[/b] is used."
@@ -37769,6 +37797,7 @@ msgstr ""
"[b]注æ„:[/b]这个值在 Android å’Œ iOS 上å¯ç«‹å³è¢«ç¡¬ä»¶ä¼ æ„Ÿå™¨çš„值所覆盖。"
#: doc/classes/Input.xml
+#, fuzzy
msgid ""
"Sets a custom mouse cursor image, which is only visible inside the game "
"window. The hotspot can also be specified. Passing [code]null[/code] to the "
@@ -37780,7 +37809,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
"设置一个自定义鼠标光标图åƒï¼Œè¯¥å›¾åƒä»…当游æˆçª—å£å†…å¯è§ã€‚还å¯ä»¥æŒ‡å®šçƒ­ç‚¹ã€‚å°† "
"[code]null[/code] 传递给 image å‚æ•°å°†é‡ç½®ä¸ºç³»ç»Ÿå…‰æ ‡ã€‚有关详细信æ¯ï¼Œè¯·å‚阅 "
@@ -37801,7 +37834,7 @@ msgid ""
"[b]Note:[/b] This method generates an [InputEventMouseMotion] to update "
"cursor immediately."
msgstr ""
-"设置该视区中使用的默认光标形状,而ä¸æ˜¯ [constant CURSOR_ARROW]。\n"
+"设置该视å£ä¸­ä½¿ç”¨çš„默认光标形状,而ä¸æ˜¯ [constant CURSOR_ARROW]。\n"
"[b]注æ„:[/b]如果è¦æ›´æ”¹ [Control] 节点的默认光标形状,请改用 [member Control."
"mouse_default_cursor_shape]。\n"
"[b]注æ„:[/b]这个方法会生æˆä¸€ä¸ª [InputEventMouseMotion] 以立å³æ›´æ–°å…‰æ ‡ã€‚"
@@ -41529,7 +41562,6 @@ msgstr ""
"如果为 [code]true[/code],则光线的效果会逆转,使区域å˜æš—并投射明亮的阴影。"
#: doc/classes/Light.xml
-#, fuzzy
msgid ""
"The size of the light in Godot units. Only considered in baked lightmaps and "
"only if [member light_bake_mode] is set to [constant BAKE_ALL]. Increasing "
@@ -41540,7 +41572,9 @@ msgid ""
msgstr ""
"ç¯å…‰çš„大å°ï¼Œä½¿ç”¨ Godot çš„å•ä½ã€‚åªåœ¨çƒ˜ç„™çš„光照贴图中考虑,并且åªåœ¨ [member "
"light_bake_mode] 被设置为 [constant BAKE_ALL] 时考虑。增加这个值会使阴影看起"
-"æ¥æ›´æ¨¡ç³Šã€‚è¿™å¯ä»¥åœ¨ä¸€å®šç¨‹åº¦ä¸Šç”¨äºŽæ¨¡æ‹ŸåŒºåŸŸç¯å…‰ã€‚"
+"æ¥æ›´æ¨¡ç³Šã€‚è¿™å¯ä»¥åœ¨ä¸€å®šç¨‹åº¦ä¸Šç”¨äºŽæ¨¡æ‹ŸåŒºåŸŸç¯å…‰ã€‚\n"
+"[b]注æ„:[/b][member light_size] ä¸å— [member Spatial.scale] çš„å½±å“(无论是该"
+"ç¯å…‰çš„缩放还是其父节点的缩放)。"
#: doc/classes/Light.xml
msgid ""
@@ -44044,7 +44078,7 @@ msgid ""
"MeshInstance2D[/b] at the top of the 2D editor viewport."
msgstr ""
"用于在 2D 中显示 [Mesh] 的节点。å¯ä»¥é€šè¿‡ç¼–辑器工具æ ä¸Šçš„工具从现有的 "
-"[Sprite] 构建。选中 [Sprite] 节点,然åŽåœ¨ 2D 编辑器视区顶部选择[b]ç²¾çµ > 转æ¢"
+"[Sprite] 构建。选中 [Sprite] 节点,然åŽåœ¨ 2D 编辑器视å£é¡¶éƒ¨é€‰æ‹©[b]ç²¾çµ > 转æ¢"
"为 MeshInstance2D[/b]。"
#: doc/classes/MeshInstance2D.xml
@@ -45547,7 +45581,6 @@ msgid "3D agent used in navigation for collision avoidance."
msgstr "在导航中用于防撞的 3D 代ç†ã€‚"
#: doc/classes/NavigationAgent.xml
-#, fuzzy
msgid ""
"3D agent that is used in navigation to reach a location while avoiding "
"static and dynamic obstacles. The dynamic obstacles are avoided using RVO "
@@ -45574,7 +45607,9 @@ msgstr ""
"[NavigationAgent] 是物ç†å®‰å…¨çš„。\n"
"[b]注æ„:[/b]使用 [method set_target_location] 之åŽï¼Œå¿…须在æ¯ä¸ªç‰©ç†å¸§ä½¿ç”¨ä¸€"
"次 [method get_next_location] 函数æ¥æ›´æ–° NavigationAgent 的内部路径逻辑。这个"
-"函数返回的å‘é‡ä½ç½®åº”该用作该代ç†çš„父节点的下一次移动ä½ç½®ã€‚"
+"函数返回的å‘é‡ä½ç½®åº”该用作该代ç†çš„父节点的下一次移动ä½ç½®ã€‚\n"
+"[b]注æ„:[/b]默认情况下,é¿éšœçš„大强度计算是在å•ç‹¬çš„线程中进行的。在ä¸æ”¯æŒå¤šçº¿"
+"程的 HTML5 导出中,则会在主线程中进行,å¯èƒ½å¯¼è‡´æ€§èƒ½é—®é¢˜ã€‚"
#: doc/classes/NavigationAgent.xml doc/classes/NavigationAgent2D.xml
msgid ""
@@ -45867,7 +45902,6 @@ msgid "2D agent used in navigation for collision avoidance."
msgstr "在导航中用于防撞的 2D 代ç†ã€‚"
#: doc/classes/NavigationAgent2D.xml
-#, fuzzy
msgid ""
"2D agent that is used in navigation to reach a location while avoiding "
"static and dynamic obstacles. The dynamic obstacles are avoided using RVO "
@@ -45894,7 +45928,9 @@ msgstr ""
"[NavigationAgent2D] 是物ç†å®‰å…¨çš„。\n"
"[b]注æ„:[/b]使用 [method set_target_location] 之åŽï¼Œå¿…须在æ¯ä¸ªç‰©ç†å¸§ä½¿ç”¨ä¸€"
"次 [method get_next_location] 函数æ¥æ›´æ–° NavigationAgent 的内部路径逻辑。这个"
-"函数返回的å‘é‡ä½ç½®åº”该用作该代ç†çš„父节点的下一次移动ä½ç½®ã€‚"
+"函数返回的å‘é‡ä½ç½®åº”该用作该代ç†çš„父节点的下一次移动ä½ç½®ã€‚\n"
+"[b]注æ„:[/b]默认情况下,é¿éšœçš„大强度计算是在å•ç‹¬çš„线程中进行的。在ä¸æ”¯æŒå¤šçº¿"
+"程的 HTML5 导出中,则会在主线程中进行,å¯èƒ½å¯¼è‡´æ€§èƒ½é—®é¢˜ã€‚"
#: doc/classes/NavigationAgent2D.xml
msgid ""
@@ -46763,7 +46799,6 @@ msgid "Server interface for low-level 3D navigation access."
msgstr "访问底层 3D 导航的æœåŠ¡å™¨æŽ¥å£ã€‚"
#: doc/classes/NavigationServer.xml
-#, fuzzy
msgid ""
"NavigationServer is the server responsible for all 3D navigation. It handles "
"several objects, namely maps, regions and agents.\n"
@@ -46805,6 +46840,8 @@ msgstr ""
"的速度触å‘回调。\n"
"[b]注æ„:[/b]防撞系统会忽略地区。直接使用修正åŽçš„速度å¯èƒ½ä¼šå°†ä»£ç†æŽ¨åˆ°å¯å¯¼èˆªåŒº"
"域之外。这是防撞系统的缺陷,更å¤æ‚的情况å¯èƒ½éœ€è¦ç”¨åˆ°ç‰©ç†å¼•æ“Žã€‚\n"
+"[b]注æ„:[/b]默认情况下,é¿éšœçš„大强度计算是在å•ç‹¬çš„线程中进行的。在ä¸æ”¯æŒå¤šçº¿"
+"程的 HTML5 导出中,则会在主线程中进行,å¯èƒ½å¯¼è‡´æ€§èƒ½é—®é¢˜ã€‚\n"
"æœåŠ¡å™¨ä¼šè®°å½•æ‰€æœ‰çš„调用,在åŒæ­¥é˜¶æ®µç»Ÿä¸€æ‰§è¡Œã€‚è¿™æ„味ç€ä½ å¯ä»¥æ”¾å¿ƒå¤§èƒ†åœ°ä»Žä»»ä½•çº¿"
"程中请求对地图进行任何修改。"
@@ -50536,9 +50573,9 @@ msgstr ""
"[OccluderShape] 是 [Occluder] 节点所使用的资æºï¼Œç”¨äºŽå‡ ä½•é®æŒ¡å‰”除。\n"
"该多边形必须是凸多边形。多边形顶点的创建与删除å¯ä»¥åœ¨ç¼–辑器的检查器中进行,也"
"å¯ä»¥é€šè¿‡è°ƒç”¨ [code]set_polygon_points[/code] 实现。æ¯ä¸€æ¡è¾¹çš„顶点都å¯ä»¥é€šè¿‡åœ¨"
-"编辑器视窗中拖拽手柄设置。\n"
+"编辑器视å£ä¸­æ‹–拽手柄设置。\n"
"å¦å¤–,æ¯ä¸€ä¸ªå¤šè¾¹å½¢é®æŒ¡å™¨éƒ½å¯ä»¥æ”¯æŒå•ä¸ªç©ºæ´žã€‚如果你在编辑器的检查器中为空洞添"
-"加至少三个顶点,就å¯ä»¥åœ¨ç¼–辑器视窗中拖拽空洞边缘顶点的å¥æŸ„。\n"
+"加至少三个顶点,就å¯ä»¥åœ¨ç¼–辑器视å£ä¸­æ‹–拽空洞边缘顶点的å¥æŸ„。\n"
"一般而言,多边形以åŠç©ºæ´žçš„边数越少,è¿è¡Œæ—¶ç³»ç»Ÿçš„处ç†é€Ÿåº¦å°±è¶Šå¿«ï¼Œæ‰€ä»¥åœ¨å¤§å¤šæ•°"
"情况下你都åªä¼šè®¾ç½® 4 个顶点。"
@@ -50632,7 +50669,6 @@ msgstr ""
"光的衰å‡ï¼ˆä¸‹é™ï¼‰æ›²çº¿ã€‚在[b]检查器[/b]中,通过å³é”®ç‚¹å‡»æ›²çº¿ï¼Œå¯ä»¥èŽ·å¾—许多预设。"
#: doc/classes/OmniLight.xml
-#, fuzzy
msgid ""
"The light's radius. Note that the effectively lit area may appear to be "
"smaller depending on the [member omni_attenuation] in use. No matter the "
@@ -50641,9 +50677,11 @@ msgid ""
"[b]Note:[/b] [member omni_range] is not affected by [member Spatial.scale] "
"(the light's scale or its parent's scale)."
msgstr ""
-"光的åŠå¾„。请注æ„,有效的照明区域å¯èƒ½çœ‹èµ·æ¥æ›´å°ï¼Œè¿™å–决于使用的 [member "
-"omni_attenuation]ã€‚æ— è®ºä½¿ç”¨ä½•ç§ [member omni_attenuation],光线都ä¸ä¼šåˆ°è¾¾è¿™ä¸ª"
-"åŠå¾„以外的地方。"
+"该ç¯å…‰çš„åŠå¾„。请注æ„,根æ®ä½¿ç”¨çš„ [member omni_attenuation],有效照明区域å¯èƒ½"
+"看起æ¥æ›´å°ã€‚无论使用 [member omni_attenuation] 为何值,光都ä¸ä¼šåˆ°è¾¾æ­¤èŒƒå›´ä¹‹å¤–"
+"的任何东西。\n"
+"[b]注æ„:[/b][member omni_range] ä¸å— [member Spatial.scale] çš„å½±å“(无论是该"
+"ç¯å…‰çš„缩放还是其父节点的缩放)。"
#: doc/classes/OmniLight.xml
msgid "See [enum ShadowDetail]."
@@ -51297,7 +51335,6 @@ msgid "Returns the audio driver name for the given index."
msgstr "返回给定索引的音频驱动程åºå称。"
#: doc/classes/OS.xml
-#, fuzzy
msgid ""
"Returns the [i]global[/i] cache data directory according to the operating "
"system's standards. On Linux, this path can be overridden by setting the "
@@ -51308,7 +51345,7 @@ msgid ""
"Not to be confused with [method get_user_data_dir], which returns the "
"[i]project-specific[/i] user data path."
msgstr ""
-"æ ¹æ®æ“作系统的标准返回[i]全局[/i]缓存数æ®ç›®å½•ã€‚在桌é¢å¹³å°ä¸Šï¼Œå¯ä»¥é€šè¿‡åœ¨å¯åŠ¨é¡¹"
+"æ ¹æ®æ“作系统的标准返回[i]全局[/i]缓存数æ®ç›®å½•ã€‚在 Linux 上,å¯ä»¥é€šè¿‡åœ¨å¯åŠ¨é¡¹"
"目之å‰è®¾ç½® [code]XDG_CACHE_HOME[/code] 环境å˜é‡æ¥è¦†ç›–此路径。有关更多信æ¯ï¼Œè¯·"
"å‚阅文档中的 [url=$DOCS_URL/tutorials/io/data_paths.html]《Godot 项目中的文件"
"路径》[/url]。å¦è¯·å‚阅 [method get_config_dir] å’Œ [method get_data_dir]。\n"
@@ -51362,7 +51399,6 @@ msgstr ""
"[/codeblock]"
#: doc/classes/OS.xml
-#, fuzzy
msgid ""
"Returns the [i]global[/i] user configuration directory according to the "
"operating system's standards. On Linux, this path can be overridden by "
@@ -51373,7 +51409,7 @@ msgid ""
"Not to be confused with [method get_user_data_dir], which returns the "
"[i]project-specific[/i] user data path."
msgstr ""
-"æ ¹æ®æ“作系统的标准,返回[i]全局[/i]用户é…置目录。在桌é¢å¹³å°ä¸Šï¼Œè¿™ä¸ªè·¯å¾„å¯ä»¥åœ¨"
+"æ ¹æ®æ“作系统的标准,返回[i]全局[/i]用户é…置目录。在 Linux 上,这个路径å¯ä»¥åœ¨"
"å¯åŠ¨é¡¹ç›®å‰é€šè¿‡è®¾ç½®[code]XDG_CONFIG_HOME[/code]环境å˜é‡æ¥è¦†ç›–。更多信æ¯è¯·å‚è§"
"文档中[url=$DOCS_URL/tutorials/io/data_paths.html]《Godot 项目中的文件路径》"
"[/url]。å¦è¯·å‚阅 [method get_cache_dir] å’Œ [method get_data_dir]。\n"
@@ -51398,7 +51434,6 @@ msgid ""
msgstr "返回当å‰ä½¿ç”¨çš„视频驱动程åºï¼Œä½¿ç”¨[enum VideoDriver]中的一个值。"
#: doc/classes/OS.xml
-#, fuzzy
msgid ""
"Returns the [i]global[/i] user data directory according to the operating "
"system's standards. On Linux, this path can be overridden by setting the "
@@ -51409,7 +51444,7 @@ msgid ""
"Not to be confused with [method get_user_data_dir], which returns the "
"[i]project-specific[/i] user data path."
msgstr ""
-"æ ¹æ®æ“作系统的标准,返回[i]全局[/i]用户数æ®ç›®å½•ã€‚在桌é¢å¹³å°ä¸Šï¼Œè¿™ä¸ªè·¯å¾„å¯ä»¥åœ¨"
+"æ ¹æ®æ“作系统的标准,返回[i]全局[/i]用户数æ®ç›®å½•ã€‚在 Linux 上,这个路径å¯ä»¥åœ¨"
"å¯åŠ¨é¡¹ç›®å‰é€šè¿‡è®¾ç½®[code]XDG_DATA_HOME[/code]环境å˜é‡æ¥è¦†ç›–。更多信æ¯è¯·å‚è§æ–‡"
"档中[url=$DOCS_URL/tutorials/io/data_paths.html]《Godot 项目中的文件路径》[/"
"url]。å¦è¯·å‚阅 [method get_cache_dir] å’Œ [method get_config_dir]。\n"
@@ -53698,14 +53733,14 @@ msgstr ""
"使用 [code]process_material[/code] 属性添加 [ParticlesMaterial] æ¥é…置粒å­å¤–"
"观和行为。或者,您å¯ä»¥æ·»åŠ ä¸€ä¸ªå°†åº”用于所有粒å­çš„ [ShaderMaterial]。\n"
"[b]注æ„:[/b][Particles] 仅在使用 GLES3 渲染器时有效。如果使用 GLES2 渲染器,"
-"请改用 [CPUParticles]。您å¯ä»¥é€šè¿‡é€‰æ‹©èŠ‚点,å•å‡» 3D 编辑器视窗顶部的"
+"请改用 [CPUParticles]。您å¯ä»¥é€šè¿‡é€‰æ‹©èŠ‚点,å•å‡» 3D 编辑器视å£é¡¶éƒ¨çš„"
"[b]Particles[/b]èœå•ï¼Œç„¶åŽé€‰æ‹©[b]转æ¢ä¸º CPUParticles[/b],将 [Particles] 转æ¢"
"为 [CPUParticles]。\n"
"[b]注æ„:[/b]在 macOS 上,渲染 [Particles] 比 [CPUParticles] è¦æ…¢ä¸Šå¾ˆå¤šï¼Œå› ä¸º"
"å˜æ¢å馈是在 CPU 上实现的,而ä¸æ˜¯ GPU。以 macOS 为目标时,请考虑使用 "
"[CPUParticles]。\n"
"[b]注æ„:[/b]在处ç†ç²’å­èŠ‚点åŽï¼Œè®°å¾—通过选择它æ¥æ›´æ–°å…¶ [member "
-"visibility_aabb],å•å‡» 3D 编辑器视窗顶部的[b]Particles[/b]èœå•ï¼Œç„¶åŽé€‰æ‹©[b]生"
+"visibility_aabb],å•å‡» 3D 编辑器视å£é¡¶éƒ¨çš„[b]Particles[/b]èœå•ï¼Œç„¶åŽé€‰æ‹©[b]生"
"æˆå¯è§ AABB[/b]。å¦åˆ™ï¼Œç²’å­å¯èƒ½ä¼šç”±äºŽç›¸æœºä½ç½®å’Œè§’度的改å˜çªç„¶æ¶ˆå¤±ã€‚"
#: doc/classes/Particles.xml
@@ -53860,15 +53895,14 @@ msgid "Particle systems (2D)"
msgstr "ç²’å­ç³»ç»Ÿï¼ˆ2D)"
#: doc/classes/Particles2D.xml
-#, fuzzy
msgid "2D Particles Demo"
-msgstr "2D å¹³å°è·³è·ƒæ¼”示"
+msgstr "2D ç²’å­æ¼”示"
#: doc/classes/Particles2D.xml
msgid ""
"2D Dodge The Creeps Demo (uses GPUParticles2D for the trail behind the "
"player)"
-msgstr ""
+msgstr "2D Dodge The Creeps 演示(玩家身åŽçš„拖尾使用的是 GPUParticles2D)"
#: doc/classes/Particles2D.xml
msgid "Returns a rectangle containing the positions of all existing particles."
@@ -58119,7 +58153,7 @@ msgid ""
msgstr ""
"Popup 是基本的 [Control],用于显示对è¯æ¡†å’Œå¼¹å‡ºçª—å£ã€‚默认情况下,它是一个å­çª—"
"å£å’Œæ¨¡æ€ï¼Œå‚阅 [Control],并具有自定义弹出行为的辅助程åºã€‚所有弹出方法都确ä¿"
-"在视窗中正确放置。"
+"在视å£ä¸­æ­£ç¡®æ”¾ç½®ã€‚"
#: doc/classes/Popup.xml
msgid "Popup (show the control in modal form)."
@@ -60422,7 +60456,7 @@ msgid ""
"default window size. Stretch mode settings also use this as a reference when "
"enabled."
msgstr ""
-"设置游æˆçš„主视窗高度。在桌é¢å¹³å°ä¸Šï¼Œè¿™æ˜¯é»˜è®¤çš„窗å£å¤§å°ã€‚当å¯ç”¨æ‹‰ä¼¸æ¨¡å¼è®¾ç½®"
+"设置游æˆçš„主视å£é«˜åº¦ã€‚在桌é¢å¹³å°ä¸Šï¼Œè¿™æ˜¯é»˜è®¤çš„窗å£å¤§å°ã€‚当å¯ç”¨æ‹‰ä¼¸æ¨¡å¼è®¾ç½®"
"时,也使用此å‚数作为å‚考。"
#: doc/classes/ProjectSettings.xml
@@ -60451,7 +60485,7 @@ msgid ""
"default window size. Stretch mode settings also use this as a reference when "
"enabled."
msgstr ""
-"设置游æˆçš„主视窗宽度。在桌é¢å¹³å°ä¸Šï¼Œè¿™æ˜¯é»˜è®¤çš„窗å£å¤§å°ã€‚当å¯ç”¨æ‹‰ä¼¸æ¨¡å¼è®¾ç½®"
+"设置游æˆçš„主视å£å®½åº¦ã€‚在桌é¢å¹³å°ä¸Šï¼Œè¿™æ˜¯é»˜è®¤çš„窗å£å¤§å°ã€‚当å¯ç”¨æ‹‰ä¼¸æ¨¡å¼è®¾ç½®"
"时,也使用此å‚数作为å‚考。"
#: doc/classes/ProjectSettings.xml
@@ -60585,7 +60619,7 @@ msgid ""
"and is the recommended setting."
msgstr ""
"如果已å¯ç”¨ï¼Œåˆ™ä¼šåœ¨å°† [member Viewport.gui_disable_input] 设为 [code]false[/"
-"code] ç¦ç”¨è§†åŒºçš„ GUI 输入时,将当å‰çš„鼠标悬åœåŠèšç„¦ä¸¢å¼ƒã€‚\n"
+"code] ç¦ç”¨è§†å£çš„ GUI 输入时,将当å‰çš„鼠标悬åœåŠèšç„¦ä¸¢å¼ƒã€‚\n"
"这样的行为能够帮助ä¿æŒ GUI 状æ€çš„å¥å£®ï¼Œè¾“å…¥æ¢å¤æ—¶ï¼Œæ— è®ºå½“æ—¶å‘生了什么都ä¸ä¼šäº§"
"生æ„外的结果。\n"
"如果已ç¦ç”¨ï¼Œä¼šä½¿ç”¨æ—§æœ‰è¡Œä¸ºï¼Œé™¤äº†ç¦ç”¨ GUI 输入本身ä¸ä¼šè¿›è¡Œé¢å¤–æ“作。\n"
@@ -60596,8 +60630,8 @@ msgid ""
"If [code]true[/code], swaps OK and Cancel buttons in dialogs on Windows and "
"UWP to follow interface conventions."
msgstr ""
-"如果为 [code]true[/code],在Windowså’ŒUWP的对è¯æ¡†ä¸­äº¤æ¢ç¡®å®šå’Œå–消按钮,以éµå¾ª"
-"ç•Œé¢æƒ¯ä¾‹ã€‚"
+"如果为 [code]true[/code],在 Windows å’Œ UWP 的对è¯æ¡†ä¸­äº¤æ¢ç¡®å®šå’Œå–消按钮,以"
+"éµå¾ªç•Œé¢æƒ¯ä¾‹ã€‚"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60639,9 +60673,9 @@ msgid ""
"necessary for the internal logic of several [Control]s. The events assigned "
"to the action can however be modified."
msgstr ""
-"默认用于确认焦点按钮ã€èœå•æˆ–列表项,或验è¯è¾“入的[InputEventAction]。\n"
-"[b]注æ„:[/b]默认的[code]ui_*[/code]动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª[Control]çš„"
-"内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"默认用于确认焦点按钮ã€èœå•æˆ–列表项,或验è¯è¾“入的 [InputEventAction]。\n"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60650,9 +60684,9 @@ msgid ""
"necessary for the internal logic of several [Control]s. The events assigned "
"to the action can however be modified."
msgstr ""
-"默认放弃一个模æ€æˆ–挂起的输入的[InputEventAction]。\n"
-"[b]注æ„:[/b]默认的[code]ui_*[/code]动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª[Control]çš„"
-"内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"默认用于放弃模æ€æˆ–挂起的输入的 [InputEventAction]。\n"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60661,9 +60695,9 @@ msgid ""
"necessary for the internal logic of several [Control]s. The events assigned "
"to the action can however be modified."
msgstr ""
-"默认在UI中å‘下移动的[InputEventAction]。\n"
-"[b]注æ„:[/b]默认的[code]ui_*[/code]动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª[Control]çš„"
-"内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"默认在 UI 中å‘下移动的 [InputEventAction]。\n"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60676,8 +60710,8 @@ msgid ""
msgstr ""
"默认[InputEventAction]去[Control]的结æŸä½ç½®(例如[ItemList]或[Tree]中的最åŽä¸€"
"项),匹é…典型桌é¢UI系统中[constant KEY_END]的行为。\n"
-"[b]注æ„:[/b]默认的[code]ui_*[/code]动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª[Control]çš„"
-"内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60689,8 +60723,8 @@ msgid ""
msgstr ""
"默认èšç„¦åœºæ™¯ä¸­çš„下一个[Control]çš„[InputEventAction]。焦点行为å¯ä»¥é€šè¿‡[member "
"Control.focus_next]é…置。\n"
-"[b]注æ„:[/b]默认的[code]ui_*[/code]动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª[Control]çš„"
-"内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60702,8 +60736,8 @@ msgid ""
msgstr ""
"默认èšç„¦åœºæ™¯ä¸­çš„å‰ä¸€ä¸ª[Control]çš„[InputEventAction]。焦点行为å¯ä»¥é€šè¿‡[member "
"Control.focus_previous]é…置。\n"
-"[b]注æ„:[/b]默认的[code]ui_*[/code]动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª[Control]çš„"
-"内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60716,8 +60750,8 @@ msgid ""
msgstr ""
"默认的将进入[Control]的起始ä½ç½®ï¼ˆä¾‹å¦‚[ItemList]或[Tree]中的第一个项目)时的"
"[InputEventAction],与典型的桌é¢UI系统中[constant KEY_HOME]的行为相匹é…。\n"
-"[b]注æ„:[/b]默认的[code]ui_*[/code]动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬å¯¹äºŽå‡ ä¸ª[Control]"
-"的内部逻辑是必è¦çš„。然而,分é…给动作的事件å¯ä»¥è¢«ä¿®æ”¹ã€‚"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª "
+"[Control] 的内部逻辑所必需的。然而,分é…给动作的事件å¯ä»¥è¢«ä¿®æ”¹ã€‚"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60726,9 +60760,9 @@ msgid ""
"necessary for the internal logic of several [Control]s. The events assigned "
"to the action can however be modified."
msgstr ""
-"默认在UI中å‘左移动的[InputEventAction]。\n"
-"[b]注æ„:[/b]默认的[code]ui_*[/code]动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª[Control]çš„"
-"内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"默认在 UI 中å‘左移动的[InputEventAction]。\n"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60742,8 +60776,8 @@ msgstr ""
"默认的在 [Control](例如 [ItemList] 或 [Tree])中å‘下翻页的 "
"[InputEventAction]ï¼Œä¸Žå…¸åž‹æ¡Œé¢ UI 系统中 [constant KEY_PAGEDOWN] 的行为相匹"
"é…。\n"
-"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª "
-"[Control] 的内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60757,8 +60791,8 @@ msgstr ""
"默认的在 [Control](例如 [ItemList] 或 [Tree])中å‘上翻页的 "
"[InputEventAction]ï¼Œä¸Žå…¸åž‹æ¡Œé¢ UI 系统中 [constant KEY_PAGEUP] 的行为相匹"
"é…。\n"
-"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª "
-"[Control] 的内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60767,9 +60801,9 @@ msgid ""
"necessary for the internal logic of several [Control]s. The events assigned "
"to the action can however be modified."
msgstr ""
-"默认在UI中å³ç§»çš„[InputEventAction]。\n"
-"[b]注æ„:[/b]默认的[code]ui_*[/code]动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª[Control]çš„"
-"内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"默认在 UI 中å³ç§»çš„[InputEventAction]。\n"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60780,8 +60814,8 @@ msgid ""
"to the action can however be modified."
msgstr ""
"默认选择[Control](例如[ItemList]或[Tree])中的一个项目[InputEventAction]。\n"
-"[b]注æ„:[/b]默认的[code]ui_*[/code]动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª[Control]çš„"
-"内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -60790,9 +60824,9 @@ msgid ""
"necessary for the internal logic of several [Control]s. The events assigned "
"to the action can however be modified."
msgstr ""
-"默认在UI中å‘上移动[InputEventAction]。\n"
-"[b]注æ„:[/b]默认的[code]ui_*[/code]动作ä¸èƒ½è¢«åˆ é™¤ï¼Œå› ä¸ºå®ƒä»¬æ˜¯å‡ ä¸ª[Control]çš„"
-"内部逻辑所必需的。但是,å¯ä»¥ä¿®æ”¹åˆ†é…给该æ“作的事件。"
+"默认在 UI 中å‘上移动[InputEventAction]。\n"
+"[b]注æ„:[/b]默认的 [code]ui_*[/code] 动作是部分 [Control] 的内部逻辑所必需"
+"的,无法删除。但是å¯ä»¥ä¿®æ”¹åˆ†é…给该动作的事件。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -63204,7 +63238,6 @@ msgstr ""
"的值通常会给出最好的结果。å¦è§ [member rendering/quality/filters/use_fxaa]。"
#: doc/classes/ProjectSettings.xml
-#, fuzzy
msgid ""
"If [code]true[/code], uses a fast post-processing filter to make banding "
"significantly less visible in 3D. 2D rendering is [i]not[/i] affected by "
@@ -63224,13 +63257,18 @@ msgid ""
"debanding at run-time, set [member Viewport.debanding] on the root "
"[Viewport] instead."
msgstr ""
-"如果为 [code]true[/code],则使用快速åŽå¤„ç†è¿‡æ»¤å™¨ä½¿æ¡å¸¦æ˜Žæ˜¾ä¸é‚£ä¹ˆæ˜Žæ˜¾ã€‚在æŸäº›"
-"情况下,去带å¯èƒ½ä¼šå¼•å…¥ç¨å¾®æ˜Žæ˜¾çš„抖动模å¼ã€‚建议仅在实际需è¦æ—¶å¯ç”¨åŽ»æ¡å¸¦ï¼Œå› ä¸º"
-"抖动模å¼ä¼šä½¿æ— æŸåŽ‹ç¼©çš„å±å¹•æˆªå›¾æ›´å¤§ã€‚\n"
+"如果为 [code]true[/code],则使用一个快速的åŽæœŸå¤„ç†æ»¤æ³¢å™¨ï¼Œä½¿ 3D 的带状现象明"
+"显å‡å°‘。2D 渲染[i]ä¸å—[/i]去æ¡å¸¦çš„å½±å“ï¼Œé™¤éž [member Environment."
+"background_mode] 为 [constant Environment.BG_CANVAS]。此时 [member rendering/"
+"quality/intended_usage/framebuffer_allocation] 也必须设为 [b]3D[/b]。\n"
+"在æŸäº›æƒ…况下,去带å¯èƒ½ä¼šå¼•å…¥ç¨å¾®æ˜Žæ˜¾çš„抖动模å¼ã€‚建议仅在实际需è¦æ—¶å¯ç”¨åŽ»æ¡"
+"带,因为抖动模å¼ä¼šä½¿æ— æŸåŽ‹ç¼©çš„å±å¹•æˆªå›¾æ›´å¤§ã€‚\n"
"[b]注æ„:[/b]仅在 GLES3 åŽç«¯å¯ç”¨ã€‚[member rendering/quality/depth/hdr] 也必须"
"为 [code]true[/code] æ‰èƒ½ä½¿åŽ»è‰²å¸¦æœ‰æ•ˆã€‚\n"
"[b]注æ„:[/b]已知在移动平å°ä¸Šçš„去色带存在破å渲染的问题。因此,建议在用于移动"
-"å¹³å°æ—¶ç¦ç”¨æ­¤é€‰é¡¹ã€‚"
+"å¹³å°æ—¶ç¦ç”¨æ­¤é€‰é¡¹ã€‚\n"
+"[b]注æ„:[/b]这个属性在项目å¯åŠ¨æ—¶æ˜¯åªè¯»çš„。è¦åœ¨è¿è¡Œæ—¶è®¾ç½®åŽ»æ¡å¸¦ï¼Œè¯·åœ¨æ ¹ "
+"[Viewport] 上设置 [member Viewport.debanding]。"
#: doc/classes/ProjectSettings.xml
msgid ""
@@ -65372,6 +65410,13 @@ msgid ""
"[code]offset[/code], and the character before [code]offset[/code] will be "
"checked for the word boundary [code]\\b[/code]."
msgstr ""
+"在文本中æœç´¢ç¼–译åŽçš„模å¼ã€‚如果找到,则将首个匹é…结果放在 [RegExMatch] 容器中"
+"返回,å¦åˆ™è¿”回 [code]null[/code]。\n"
+"æœç´¢çš„范围å¯ä»¥ç”¨ [code]offset[/code] å’Œ [code]end[/code] 指定。å¯ç”¨äºŽåœ¨ä¸Šä¸€æ¬¡"
+"æˆåŠŸæ‰¾åˆ°åŽå†æ¬¡ä½¿ç”¨ç›¸åŒçš„ [code]subject[/code] 调用这个方法,继续寻找匹é…。设"
+"置这些å‚数和传入缩短åŽçš„字符串是ä¸åŒçš„。例如,起点 [code]^[/code] ä¸ä¼šå— "
+"[code]offset[/code] å½±å“,å•è¯è¾¹ç•Œ [code]\\b[/code] 会检查 [code]offset[/"
+"code] 之å‰çš„字符。"
#: modules/regex/doc_classes/RegEx.xml
msgid ""
@@ -65386,9 +65431,15 @@ msgid ""
"[code]offset[/code], and the character before [code]offset[/code] will be "
"checked for the word boundary [code]\\b[/code]."
msgstr ""
+"在文本中æœç´¢ç¼–译åŽçš„模å¼ã€‚返回 [RegExMatch] 容器的数组,其中包å«çš„是互ä¸é‡å "
+"的匹é…结果。如果没有找到匹é…,则返回空数组。\n"
+"æœç´¢çš„范围å¯ä»¥ç”¨ [code]offset[/code] å’Œ [code]end[/code] 指定。å¯ç”¨äºŽåœ¨ä¸Šä¸€æ¬¡"
+"æˆåŠŸæ‰¾åˆ°åŽå†æ¬¡ä½¿ç”¨ç›¸åŒçš„ [code]subject[/code] 调用这个方法,继续寻找匹é…。设"
+"置这些å‚数和传入缩短åŽçš„字符串是ä¸åŒçš„。例如,起点 [code]^[/code] ä¸ä¼šå— "
+"[code]offset[/code] å½±å“,å•è¯è¾¹ç•Œ [code]\\b[/code] 会检查 [code]offset[/"
+"code] 之å‰çš„字符。"
#: modules/regex/doc_classes/RegEx.xml
-#, fuzzy
msgid ""
"Searches the text for the compiled pattern and replaces it with the "
"specified string. Escapes and backreferences such as [code]$1[/code] and "
@@ -65403,10 +65454,14 @@ msgid ""
"[code]offset[/code], and the character before [code]offset[/code] will be "
"checked for the word boundary [code]\\b[/code]."
msgstr ""
-"æœç´¢æ–‡æœ¬ä¸­çš„编译模å¼ï¼Œå¹¶å°†å…¶æ›¿æ¢ä¸ºæŒ‡å®šçš„字符串。诸如 [code]$1[/code] å’Œ "
+"在文本中æœç´¢ç¼–译åŽçš„模å¼ï¼Œå¹¶å°†å…¶æ›¿æ¢ä¸ºæŒ‡å®šçš„字符串。诸如 [code]$1[/code] å’Œ "
"[code]$name[/code] 等转义和åå‘引用会被展开和解决。默认情况下,åªæœ‰ç¬¬ä¸€ä¸ªå®žä¾‹"
-"被替æ¢ï¼Œä½†å¯ä»¥å¯¹æ‰€æœ‰å®žä¾‹è¿›è¡Œä¿®æ”¹ï¼ˆå…¨å±€æ›¿æ¢ï¼‰ã€‚å¯ä»¥æŒ‡å®šè¦æœç´¢çš„区域,而ä¸éœ€è¦"
-"修改开始和结æŸé”šçš„ä½ç½®ã€‚"
+"被替æ¢ï¼Œä½†å¯ä»¥å¯¹æ‰€æœ‰å®žä¾‹è¿›è¡Œä¿®æ”¹ï¼ˆå…¨å±€æ›¿æ¢ï¼‰ã€‚\n"
+"æœç´¢çš„范围å¯ä»¥ç”¨ [code]offset[/code] å’Œ [code]end[/code] 指定。å¯ç”¨äºŽåœ¨ä¸Šä¸€æ¬¡"
+"æˆåŠŸæ‰¾åˆ°åŽå†æ¬¡ä½¿ç”¨ç›¸åŒçš„ [code]subject[/code] 调用这个方法,继续寻找匹é…。设"
+"置这些å‚数和传入缩短åŽçš„字符串是ä¸åŒçš„。例如,起点 [code]^[/code] ä¸ä¼šå— "
+"[code]offset[/code] å½±å“,å•è¯è¾¹ç•Œ [code]\\b[/code] 会检查 [code]offset[/"
+"code] 之å‰çš„字符。"
#: modules/regex/doc_classes/RegExMatch.xml
msgid "Contains the results of a [RegEx] search."
@@ -65687,7 +65742,7 @@ msgstr ""
"时,这个方法会被调用。它的行为å¯ä»¥é€šè¿‡è¦†ç›–脚本中的 [method "
"_setup_local_to_scene] 进行定制。\n"
"对于大多数资æºï¼Œè¯¥æ–¹æ³•ä¸æ‰§è¡Œä»»ä½•åŸºæœ¬é€»è¾‘。[ViewportTexture] 执行自定义逻辑以"
-"正确设置本地视窗中的代ç†çº¹ç†å’Œæ ‡å¿—。"
+"正确设置本地视å£ä¸­çš„代ç†çº¹ç†å’Œæ ‡å¿—。"
#: doc/classes/Resource.xml
msgid ""
@@ -68854,12 +68909,11 @@ msgid ""
"quality/dynamic_fonts/use_oversampling[/code] in [ProjectSettings]. The "
"property can however be overridden at runtime as needed."
msgstr ""
-"为 [code]true[/code] æ—¶å¯ç”¨å­—体过采样。这æ„味ç€æ ¹æ®è§†çª—的缩放比例ä¸åŒï¼Œ"
-"[DynamicFont] 渲染的大å°ä¼šæ¯”é…置大å°æ›´é«˜æˆ–更低。例如,如果视窗的缩放系数为 "
-"1.5,那么é…置为 14 å·å¤§å°çš„字体将会按照 21 å·å¤§å°æ¸²æŸ“([code]14 * 1.5[/"
-"code])。\n"
-"[b]注æ„:[/b]字体过采样仅在视窗拉伸模å¼ä¸º [constant STRETCH_MODE_VIEWPORT] 且"
-"拉伸比例模å¼ä¸æ˜¯ [constant STRETCH_ASPECT_IGNORE] 时有效。\n"
+"为 [code]true[/code] æ—¶å¯ç”¨å­—体过采样。这æ„味ç€æ ¹æ®è§†å£çš„缩放比例ä¸åŒï¼Œ"
+"[DynamicFont] 渲染的大å°ä¼šæ¯”é…置大å°æ›´é«˜æˆ–更低。例如,视å£çš„缩放系数为 1.5 "
+"时,é…置大å°ä¸º 14 的字体将会当作大å°ä¸º 21 渲染([code]14 * 1.5[/code])。\n"
+"[b]注æ„:[/b]åªæœ‰åœ¨è§†å£æ‹‰ä¼¸æ¨¡å¼ä¸º [constant STRETCH_MODE_VIEWPORT] 且拉伸比例"
+"模å¼ä¸æ˜¯ [constant STRETCH_ASPECT_IGNORE] 时,æ‰ä¼šä½¿ç”¨å­—体过采样。\n"
"[b]注æ„:[/b]项目å¯åŠ¨æ—¶ä¼šä¸ºæ´»åŠ¨çš„ [SceneTree] 自动设置该属性,å–值为 "
"[ProjectSettings] çš„ [code]rendering/quality/dynamic_fonts/use_oversampling[/"
"code]。ä¸è¿‡è¿è¡Œæ—¶å¯ä»¥æ ¹æ®éœ€è¦å¯¹è¯¥å±žæ€§è¿›è¡Œè¦†ç›–。"
@@ -68932,7 +68986,7 @@ msgstr "当节点的é…置更改时å‘出。仅在 [code]tool[/code] 模å¼ä¸‹å
#: doc/classes/SceneTree.xml
msgid "Emitted whenever a node is removed from the [SceneTree]."
-msgstr "当从 [SceneTree] 中删除节点时å‘出。"
+msgstr "当从 [SceneTree] 中移除节点时å‘出。"
#: doc/classes/SceneTree.xml
msgid "Emitted whenever a node is renamed."
@@ -68968,15 +69022,15 @@ msgstr "当 [SceneTree] 层次结构å‘生å˜åŒ–(移动或é‡å‘½åå­é¡¹ç­‰ï¼
#: doc/classes/SceneTree.xml
msgid "Call a group with no flags (default)."
-msgstr "对组进行调用时,ä¸ä½¿ç”¨æ ‡å¿—(默认)。"
+msgstr "对分组进行调用时,ä¸ä½¿ç”¨æ ‡å¿—(默认)。"
#: doc/classes/SceneTree.xml
msgid "Call a group in reverse scene order."
-msgstr "对组进行调用时,使用逆场景åºã€‚"
+msgstr "对分组进行调用时,使用逆场景åºã€‚"
#: doc/classes/SceneTree.xml
msgid "Call a group immediately (calls are normally made on idle)."
-msgstr "对组进行调用时,立å³æ‰§è¡Œï¼ˆæ­£å¸¸æƒ…况下是在空闲时调用的)。"
+msgstr "对分组进行调用时,立å³æ‰§è¡Œï¼ˆæ­£å¸¸æƒ…况下是在空闲时调用的)。"
#: doc/classes/SceneTree.xml
msgid ""
@@ -68985,6 +69039,9 @@ msgid ""
"call is unique or not. Therefore when the same method is called with "
"different arguments, only the first call will be performed."
msgstr ""
+"å³ä¾¿æ‰§è¡Œäº†å¤šæ¬¡è°ƒç”¨ï¼Œä¹Ÿåªå¯¹åˆ†ç»„进行一次调用。\n"
+"[b]注æ„:[/b]确定调用是å¦å”¯ä¸€æ—¶ä¸è€ƒè™‘å‚数。因此,如果使用ä¸åŒçš„å‚数调用了åŒä¸€"
+"个方法,那么åªä¼šæ‰§è¡Œç¬¬ä¸€ä¸ªè°ƒç”¨ã€‚"
#: doc/classes/SceneTree.xml
msgid "No stretching."
@@ -71377,10 +71434,10 @@ msgstr ""
msgid ""
"Rotation part of the local transformation in degrees, specified in terms of "
"YXZ-Euler angles in the format (X angle, Y angle, Z angle)."
-msgstr "旋转部分局部å˜æ¢ä¸ºåº¦ï¼ŒæŒ‰ YXZ-Euler 角格å¼æŒ‡å®šï¼ˆX 角ã€Y 角ã€Z 角)。"
+msgstr ""
+"局部å˜æ¢çš„旋转部分,å•ä½ä¸ºåº¦ï¼Œä»¥ YXZ 欧拉角的形å¼è¡¨ç¤ºï¼ˆX 角ã€Y 角ã€Z 角)。"
#: doc/classes/Spatial.xml
-#, fuzzy
msgid ""
"Scale part of the local transformation.\n"
"[b]Note:[/b] Mixed negative scales in 3D are not decomposable from the "
@@ -71392,7 +71449,9 @@ msgid ""
msgstr ""
"局部å˜æ¢çš„缩放部分。\n"
"[b]注æ„:[/b]3D 中,å˜æ¢çŸ©é˜µæ˜¯æ— æ³•åˆ†è§£å‡ºæ­£è´Ÿæ··åˆçš„缩放的。由于 Godot 中使用å˜"
-"æ¢çŸ©é˜µæ¥è¡¨ç¤ºç¼©æ”¾ï¼Œå¾—到的缩放值è¦ä¹ˆå…¨æ­£ã€è¦ä¹ˆå…¨è´Ÿã€‚"
+"æ¢çŸ©é˜µæ¥è¡¨ç¤ºç¼©æ”¾ï¼Œå¾—到的缩放值è¦ä¹ˆå…¨æ­£ã€è¦ä¹ˆå…¨è´Ÿã€‚\n"
+"[b]注æ„:[/b]并ä¸æ˜¯æ‰€æœ‰èŠ‚点的外观都会被 [member scale] 属性缩放。例如,"
+"[Light] 的外观就ä¸å— [member scale] å½±å“。"
#: doc/classes/Spatial.xml
msgid "Local space [Transform] of this node, with respect to the parent node."
@@ -73038,6 +73097,9 @@ msgid ""
"[b]Note:[/b] [member spot_angle] is not affected by [member Spatial.scale] "
"(the light's scale or its parent's scale)."
msgstr ""
+"èšå…‰ç¯çš„角度,å•ä½ä¸ºåº¦ã€‚\n"
+"[b]注æ„:[/b][member spot_angle] ä¸å— [member Spatial.scale] çš„å½±å“(无论是该"
+"ç¯å…‰çš„缩放还是其父节点的缩放)。"
#: doc/classes/SpotLight.xml
msgid "The spotlight's angular attenuation curve."
@@ -73048,7 +73110,6 @@ msgid "The spotlight's light energy attenuation curve."
msgstr "èšå…‰ç¯çš„å…‰é‡è¡°å‡æ›²çº¿ã€‚"
#: doc/classes/SpotLight.xml
-#, fuzzy
msgid ""
"The maximal range that can be reached by the spotlight. Note that the "
"effectively lit area may appear to be smaller depending on the [member "
@@ -73058,8 +73119,10 @@ msgid ""
"(the light's scale or its parent's scale)."
msgstr ""
"èšå…‰ç¯å¯ä»¥è¾¾åˆ°çš„最大范围。请注æ„,根æ®ä½¿ç”¨çš„ [member spot_attenuation],有效"
-"照明区域å¯èƒ½çœ‹èµ·æ¥æ›´å°ã€‚无论使用[member spot_attenuation],光都ä¸ä¼šåˆ°è¾¾æ­¤èŒƒå›´"
-"之外的任何东西。"
+"照明区域å¯èƒ½çœ‹èµ·æ¥æ›´å°ã€‚无论 [member spot_attenuation] 为何值,光都ä¸ä¼šåˆ°è¾¾æ­¤"
+"范围之外的任何东西。\n"
+"[b]注æ„:[/b][member spot_angle] ä¸å— [member Spatial.scale] çš„å½±å“(无论是该"
+"ç¯å…‰çš„缩放还是其父节点的缩放)。"
#: doc/classes/SpringArm.xml
msgid "A helper node, mostly used in 3rd person cameras."
@@ -76689,7 +76752,7 @@ msgid ""
"Centers the viewport on the line the editing cursor is at. This also resets "
"the [member scroll_horizontal] value to [code]0[/code]."
msgstr ""
-"将视区置于编辑光标所在的行上。这也会将 [member scroll_horizontal] 值é‡ç½®ä¸º "
+"将视å£ç½®äºŽç¼–辑光标所在的行上。这也会将 [member scroll_horizontal] 值é‡ç½®ä¸º "
"[code]0[/code]。"
#: doc/classes/TextEdit.xml
@@ -76723,7 +76786,7 @@ msgid ""
"will center at the cursor position after the move occurs."
msgstr ""
"将光标移动到指定的 [code]column[/code] 索引处。\n"
-"如果 [code]adjust_viewport[/code] 设置为 [code]true[/code],则移动å‘生åŽè§†çª—"
+"如果 [code]adjust_viewport[/code] 设置为 [code]true[/code],则移动å‘生åŽè§†å£"
"将以光标ä½ç½®ä¸ºä¸­å¿ƒã€‚"
#: doc/classes/TextEdit.xml
@@ -76735,7 +76798,7 @@ msgid ""
"[code]line[/code] can be hidden using [method set_line_as_hidden]."
msgstr ""
"在指定的 [code]line[/code] 索引处移动光标。\n"
-"如果 [code]adjust_viewport[/code] 设置为 [code]true[/code],则移动å‘生åŽè§†çª—"
+"如果 [code]adjust_viewport[/code] 设置为 [code]true[/code],则移动å‘生åŽè§†å£"
"将以光标ä½ç½®ä¸ºä¸­å¿ƒã€‚\n"
"如果 [code]can_be_hidden[/code] 设置为 [code]true[/code],则å¯ä»¥ä½¿ç”¨ [method "
"set_line_as_hidden] éšè—指定的 [code]line[/code]。"
@@ -84329,16 +84392,16 @@ msgid ""
"to be upside down. Enabling [member render_target_v_flip] will display the "
"Viewport with the correct orientation."
msgstr ""
-"Viewport 会在å±å¹•ä¸Šåˆ›å»ºä¸åŒçš„视图,或者是å¦ä¸€ä¸ªè§†çª—中的å­è§†å›¾ã€‚å­ä»£ 2D 节点会"
+"Viewport 会在å±å¹•ä¸Šåˆ›å»ºä¸åŒçš„视图,或者是å¦ä¸€ä¸ªè§†å£ä¸­çš„å­è§†å›¾ã€‚å­ä»£ 2D 节点会"
"在其上显示,å­ä»£ 3D æ‘„åƒæœºèŠ‚点也会在其上渲染。\n"
-"å¦å¤–,视窗å¯ä»¥æœ‰è‡ªå·±çš„ 2D 或 3D 世界,所以它们ä¸ä¼šä¸Žå…¶ä»–视窗共享其所绘制的内"
+"å¦å¤–,视å£å¯ä»¥æœ‰è‡ªå·±çš„ 2D 或 3D 世界,所以它们ä¸ä¼šä¸Žå…¶ä»–视å£å…±äº«å…¶æ‰€ç»˜åˆ¶çš„内"
"容。\n"
-"如果视窗是 [ViewportContainer] çš„å­èŠ‚点,它将自动å ç”¨å…¶å¤§å°ï¼Œå¦åˆ™å¿…须手动设"
+"如果视å£æ˜¯ [ViewportContainer] çš„å­èŠ‚点,它将自动å ç”¨å…¶å¤§å°ï¼Œå¦åˆ™å¿…须手动设"
"置。\n"
-"视窗也å¯ä»¥é€‰æ‹©æˆä¸ºéŸ³é¢‘监å¬è€…,会根æ®å®ƒçš„ 2D 或 3D æ‘„åƒæœºçš„å­èŠ‚点æ¥äº§ç”Ÿä½ç½®éŸ³"
+"视å£ä¹Ÿå¯ä»¥é€‰æ‹©æˆä¸ºéŸ³é¢‘监å¬è€…,会根æ®å®ƒçš„ 2D 或 3D æ‘„åƒæœºçš„å­èŠ‚点æ¥äº§ç”Ÿä½ç½®éŸ³"
"频。\n"
-"å¦å¤–,如果设备有多个å±å¹•ï¼Œè§†çª—å¯ä»¥è¢«åˆ†é…到ä¸åŒçš„å±å¹•ã€‚\n"
-"最åŽï¼Œè§†çª—也å¯ä»¥ä½œä¸ºæ¸²æŸ“目标,在这ç§æƒ…况下,除éžç›¸å…³çš„纹ç†è¢«ç”¨äºŽç»˜åˆ¶ï¼Œå¦åˆ™å®ƒ"
+"å¦å¤–,如果设备有多个å±å¹•ï¼Œè§†å£å¯ä»¥è¢«åˆ†é…到ä¸åŒçš„å±å¹•ã€‚\n"
+"最åŽï¼Œè§†å£ä¹Ÿå¯ä»¥ä½œä¸ºæ¸²æŸ“目标,在这ç§æƒ…况下,除éžç›¸å…³çš„纹ç†è¢«ç”¨äºŽç»˜åˆ¶ï¼Œå¦åˆ™å®ƒ"
"们将ä¸å¯è§ã€‚\n"
"[b]注æ„:[/b]默认情况下,Godot 3.x 中新创建的 Viewport 是上下颠倒的。å¯ç”¨ "
"[member render_target_v_flip] å¯ä»¥ä½¿è¯¥ Viewport 使用正确的æœå‘显示。"
@@ -84385,7 +84448,7 @@ msgstr "返回激活的 3D 相机。"
#: doc/classes/Viewport.xml
msgid "Returns the total transform of the viewport."
-msgstr "返回视窗的总的å˜æ¢ã€‚"
+msgstr "返回视å£çš„总的å˜æ¢ã€‚"
#: doc/classes/Viewport.xml
msgid "Returns the topmost modal in the stack."
@@ -84399,7 +84462,7 @@ msgstr "返回该 [Viewport] 中鼠标的ä½ç½®ï¼Œä½¿ç”¨è¯¥ [Viewport] çš„åæ ‡
#: doc/classes/Viewport.xml
msgid "Returns information about the viewport from the rendering pipeline."
-msgstr "返回渲染管é“中关于视窗的信æ¯ã€‚"
+msgstr "返回渲染管é“中关于视å£çš„ä¿¡æ¯ã€‚"
#: doc/classes/Viewport.xml
msgid "Returns the [enum ShadowAtlasQuadrantSubdiv] of the specified quadrant."
@@ -84420,7 +84483,7 @@ msgid ""
"img.flip_y()\n"
"[/codeblock]"
msgstr ""
-"返回该视窗的纹ç†ã€‚\n"
+"返回该视å£çš„纹ç†ã€‚\n"
"[b]注æ„:[/b]由于 OpenGL 的工作方å¼ï¼Œäº§ç”Ÿçš„ [ViewportTexture] 是垂直翻转的。"
"ä½ å¯ä»¥åœ¨ [method Texture.get_data] 的结果上使用 [method Image.flip_y] æ¥å°†å…¶"
"翻转回去,例如:\n"
@@ -84459,7 +84522,7 @@ msgid ""
"Alternative to [constant Node.NOTIFICATION_DRAG_BEGIN] and [constant Node."
"NOTIFICATION_DRAG_END] when you prefer polling the value."
msgstr ""
-"如果该视区目å‰æ­£åœ¨æ‰§è¡Œæ‹–拽æ“作,则返回 [code]true[/code]。\n"
+"如果该视å£ç›®å‰æ­£åœ¨æ‰§è¡Œæ‹–拽æ“作,则返回 [code]true[/code]。\n"
"如果你更倾å‘于对其进行轮询,那么就å¯ä»¥ä½œä¸º [constant Node."
"NOTIFICATION_DRAG_BEGIN] å’Œ [constant Node.NOTIFICATION_DRAG_END] 的替代å“。"
@@ -84540,7 +84603,6 @@ msgstr ""
"全局画布å˜æ¢ã€‚"
#: doc/classes/Viewport.xml
-#, fuzzy
msgid ""
"If [code]true[/code], uses a fast post-processing filter to make banding "
"significantly less visible in 3D. 2D rendering is [i]not[/i] affected by "
@@ -84555,9 +84617,13 @@ msgid ""
"[b]Note:[/b] Only available on the GLES3 backend. [member hdr] must also be "
"[code]true[/code] for debanding to be effective."
msgstr ""
-"如果为 [code]true[/code],则使用一个快速的åŽæœŸå¤„ç†æ»¤æ³¢å™¨ï¼Œä½¿å¸¦çŠ¶çŽ°è±¡æ˜Žæ˜¾å‡"
-"少。在æŸäº›æƒ…况下,去带å¯èƒ½ä¼šå¼•å…¥ç¨å¾®æ˜Žæ˜¾çš„抖动模å¼ã€‚建议åªæœ‰åœ¨å®žé™…需è¦æ—¶æ‰å¯"
-"用去带,因为抖动模å¼ä¼šä½¿æ— æŸåŽ‹ç¼©çš„å±å¹•æˆªå›¾å˜å¤§ã€‚\n"
+"如果为 [code]true[/code],则使用一个快速的åŽæœŸå¤„ç†æ»¤æ³¢å™¨ï¼Œä½¿ 3D 的带状现象明"
+"显å‡å°‘。2D 渲染[i]ä¸å—[/i]去æ¡å¸¦çš„å½±å“ï¼Œé™¤éž [member Environment."
+"background_mode] 为 [constant Environment.BG_CANVAS]。此时 [member usage] 也"
+"必须设为 [constant USAGE_3D]。å¦è¯·å‚阅 [member ProjectSettings.rendering/"
+"quality/filters/use_debanding]。\n"
+"在æŸäº›æƒ…况下,去æ¡å¸¦å¯èƒ½ä¼šå¼•å…¥ç¨å¾®æ˜Žæ˜¾çš„抖动图案。建议åªæœ‰åœ¨å®žé™…需è¦æ—¶æ‰å¯ç”¨"
+"去æ¡å¸¦ï¼Œå› ä¸ºæŠ–动图案会使无æŸåŽ‹ç¼©çš„å±å¹•æˆªå›¾å˜å¤§ã€‚\n"
"[b]注æ„:[/b]仅在 GLES3 åŽç«¯å¯ç”¨ã€‚[member hdr] 也必须是 [code]true[/code] æ‰"
"能使去色带生效。"
@@ -84566,13 +84632,12 @@ msgid "The overlay mode for test rendered geometry in debug purposes."
msgstr "在调试时,用于测试渲染的几何图形的å åŠ æ¨¡å¼ã€‚"
#: doc/classes/Viewport.xml
-#, fuzzy
msgid ""
"If [code]true[/code], the viewport will disable 3D rendering. To actually "
"disable allocation of 3D buffers, set [member usage] instead."
msgstr ""
-"如果为 [code]true[/code],该视å£å°†ç¦ç”¨ 3D 渲染。对于实际ç¦ç”¨ï¼Œä½¿ç”¨ "
-"[code]usage[/code]。"
+"如果为 [code]true[/code],该视å£å°†ç¦ç”¨ 3D 渲染。è¦å®žé™…ç¦ç”¨ 3D 缓冲区的分é…,"
+"请设置 [member usage]。"
#: doc/classes/Viewport.xml
msgid ""
@@ -84616,7 +84681,7 @@ msgid ""
"[b]Note:[/b] Only available on the GLES3 backend."
msgstr ""
"如果为 [code]true[/code],视å£çš„渲染将获益于高动æ€èŒƒå›´ç®—法。高动æ€èŒƒå›´å…许视"
-"窗接收 0-1 范围以外的数值。在 Godot 中 HDR 默认使用åŠç²¾åº¦æµ®ç‚¹æ•°ï¼ˆ16 ä½ï¼‰ã€‚è¦"
+"å£æŽ¥æ”¶ 0-1 范围以外的数值。在 Godot 中 HDR 默认使用åŠç²¾åº¦æµ®ç‚¹æ•°ï¼ˆ16 ä½ï¼‰ã€‚è¦"
"使用全精度浮点数(32 ä½ï¼‰ï¼Œè¯·å¯ç”¨ [member use_32_bpc_depth]。\n"
"[b]注æ„:[/b]需è¦å°† [member usage] 设置为 [constant USAGE_3D] 或 [constant "
"USAGE_3D_NO_EFFECTS],因为 HDR ä¸æ”¯æŒ 2D。\n"
@@ -84635,7 +84700,7 @@ msgid ""
"require input in linear color space!"
msgstr ""
"如果为 [code]true[/code],3D 渲染åŽçš„结果将ä¸ä¼šåº”用线性到 sRGB 的颜色转æ¢ã€‚当"
-"视å£è¢«ç”¨ä½œæ¸²æŸ“目标时,这点很é‡è¦ï¼Œå› ä¸ºæ¸²æŸ“结果会被用作å¦ä¸€ä¸ªè§†çª—中渲染的 3D "
+"视å£è¢«ç”¨ä½œæ¸²æŸ“目标时,这点很é‡è¦ï¼Œå› ä¸ºæ¸²æŸ“结果会被用作å¦ä¸€ä¸ªè§†å£ä¸­æ¸²æŸ“çš„ 3D "
"物体的纹ç†ã€‚如果视å£è¢«ç”¨æ¥åˆ›å»ºä¸åŸºäºŽé¢œè‰²çš„æ•°æ®ï¼Œå™ªå£°ã€é«˜åº¦å›¾ã€é‡‡å›¾ç­‰ï¼Œè¿™ä¹Ÿå¾ˆ"
"é‡è¦ã€‚当视å£è¢«ç”¨ä½œ 2D 对象的纹ç†æ—¶ï¼Œæˆ–者视å£æ˜¯ä½ çš„最终输出时,请ä¸è¦å¯ç”¨è¿™ä¸ª"
"功能。对于 GLES2 驱动æ¥è¯´ï¼Œè¿™å°†æŠŠ sRGB 输出转æ¢ä¸ºçº¿æ€§è¾“出,这应该åªç”¨äºŽéœ€è¦çº¿"
@@ -84725,7 +84790,7 @@ msgid ""
msgstr ""
"阴影图集的分辨率(用于全å‘光和èšå…‰ï¼‰ã€‚该值将四èˆäº”入到最接近的 2 的幂。\n"
"[b]注æ„:[/b]如果设置为 [code]0[/code],点阴影和方å‘阴影[i]都[/i]å°†ä¸å¯è§ã€‚ç”±"
-"于用户创建的视区默认值为 [code]0[/code],因此必须手动将此值设置为大于 "
+"于用户创建的视å£é»˜è®¤å€¼ä¸º [code]0[/code],因此必须手动将此值设置为大于 "
"[code]0[/code](一般至少是 [code]256[/code])。"
#: doc/classes/Viewport.xml
@@ -84736,7 +84801,7 @@ msgid ""
"Values around [code]0.5[/code] generally give the best results. See also "
"[member fxaa]."
msgstr ""
-"如果设置为大于 [code]0.0[/code] 的值,对比度适应性é”化将被应用到3D视窗中。这"
+"如果设置为大于 [code]0.0[/code] 的值,对比度适应性é”化将被应用到3D视å£ä¸­ã€‚è¿™"
"具有较低的性能æˆæœ¬ï¼Œå¯ä»¥ç”¨æ¥æ¢å¤ä½¿ç”¨ FXAA 所æŸå¤±çš„一些é”度。一般æ¥è¯´ï¼Œ"
"[code]0.5[/code] å·¦å³çš„数值å¯ä»¥å¾—到最好的效果。å¦è¯·å‚阅 [member fxaa]。"
@@ -84759,7 +84824,6 @@ msgid ""
msgstr "如果为 [code]true[/code],该视å£åº”使其背景渲染为é€æ˜Žã€‚"
#: doc/classes/Viewport.xml
-#, fuzzy
msgid ""
"The viewport's rendering mode. This controls which buffers are allocated for "
"the viewport (2D only, or 2D + 3D). 2D-only options can reduce memory usage "
@@ -84768,7 +84832,8 @@ msgid ""
"USAGE_2D_NO_SAMPLING], [member hdr] will have no effect when enabled since "
"HDR is not supported for 2D."
msgstr ""
-"视区的渲染模å¼ã€‚\n"
+"该视å£çš„渲染模å¼ã€‚控制的是为该视å£åˆ†é…哪些缓冲区(仅 2D 或者 2D + 3D)。仅 "
+"2D 的选项能够é™ä½Žå†…å­˜å ç”¨ã€ç•¥å¾®æå‡æ€§èƒ½ï¼Œå°¤å…¶æ˜¯åœ¨ä½Žç«¯è®¾å¤‡ä¸Šã€‚\n"
"[b]注æ„:[/b]如果设为 [constant USAGE_2D] 或 [constant "
"USAGE_2D_NO_SAMPLING],则å¯ç”¨ [member hdr] ä¸ä¼šç”Ÿæ•ˆï¼Œå› ä¸º 2D ä¸æ”¯æŒ HDR。"
@@ -84783,7 +84848,7 @@ msgid ""
"enable [member debanding] instead.\n"
"[b]Note:[/b] Only available on the GLES3 backend."
msgstr ""
-"如果为 [code]true[/code],分é…该视窗的帧缓冲时将使用完整浮点数精度(32 ä½ï¼‰è€Œ"
+"如果为 [code]true[/code],分é…该视å£çš„帧缓冲时将使用完整浮点数精度(32 ä½ï¼‰è€Œ"
"ä¸æ˜¯åŠæµ®ç‚¹æ•°ç²¾åº¦ï¼ˆ16 ä½ï¼‰ã€‚仅在åŒæ—¶å¯ç”¨ [member hdr] 时有效。\n"
"[b]注æ„:[/b]å¯ç”¨è¿™ä¸ªè®¾ç½®ä¸ä¼šæå‡æ¸²æŸ“è´¨é‡ã€‚使用完整浮点数精度较慢,一般åªæœ‰è¦"
"求更高精度的高级ç€è‰²å™¨éœ€è¦ä½¿ç”¨ã€‚如果是è¦å‡å°‘æ¡å¸¦æ•ˆåº”,请å¯ç”¨ [member "
@@ -85015,7 +85080,7 @@ msgstr ""
#: doc/classes/ViewportContainer.xml
msgid ""
"If [code]true[/code], the viewport will be scaled to the control's size."
-msgstr "为 [code]true[/code] 时视窗将被缩放到控件的大å°ã€‚"
+msgstr "为 [code]true[/code] 时视å£å°†è¢«ç¼©æ”¾åˆ°æŽ§ä»¶çš„大å°ã€‚"
#: doc/classes/ViewportContainer.xml
msgid ""
@@ -85046,7 +85111,7 @@ msgid ""
msgstr ""
"å°† [Viewport] 节点的内容显示为一个动æ€çš„ [Texture]。å¯ä»¥ç”¨æ¥åœ¨åŒä¸€ä¸ªåœºæ™¯ä¸­æ··"
"åˆæŽ§ä»¶ã€2D å’Œ 3D元素。\n"
-"è¦é€šè¿‡ä»£ç åˆ›å»º ViewportTexture,请使用目标视窗上的 [method Viewport."
+"è¦é€šè¿‡ä»£ç åˆ›å»º ViewportTexture,请使用目标视å£ä¸Šçš„ [method Viewport."
"get_texture] 方法。"
#: doc/classes/ViewportTexture.xml
@@ -85402,6 +85467,8 @@ msgid ""
"value will make the [VisualInstance] reliably draw on top of other "
"[VisualInstance]s that are otherwise positioned at the same spot."
msgstr ""
+"这个 [VisualInstance] 所使用的排åºå移é‡ã€‚调高åŽï¼Œè¯¥ [VisualInstance] 会稳定"
+"地绘制在åŒä¸€ä½ç½®çš„其他 [VisualInstance] 之上。"
#: doc/classes/VisualInstance.xml
msgid ""
@@ -85411,6 +85478,10 @@ msgid ""
"The position based sorting instead allows to better control the drawing "
"order when working with [Particles] and [CPUParticles]."
msgstr ""
+"如果为 [code]true[/code],则该对象会根æ®å…¶ [AABB] 中心点排åºã€‚å¦åˆ™ä¼šæ ¹æ®å…¶å…¨"
+"å±€ä½ç½®æŽ’åºã€‚\n"
+"对 3D æ¨¡åž‹è€Œè¨€ï¼Œæ ¹æ® [AABB] 的中心点排åºä¸€èˆ¬æ›´ä¸ºç²¾ç¡®ã€‚使用 [Particles] å’Œ "
+"[CPUParticles] 时,根æ®ä½ç½®æŽ’åºèƒ½å¤Ÿæ›´å¥½åœ°æŽ§åˆ¶ç»˜åˆ¶é¡ºåºã€‚"
#: modules/visual_script/doc_classes/VisualScript.xml
msgid "A script implemented in the Visual Script programming environment."
@@ -87417,10 +87488,10 @@ msgstr ""
"VisualServer 是完全ä¸é€æ˜Žçš„,它的内部结构的完全的具体实现ä¸èƒ½è¢«è®¿é—®ã€‚\n"
"VisualServer å¯ä»¥ç”¨æ¥å®Œå…¨ç»•è¿‡åœºæ™¯ç³»ç»Ÿã€‚\n"
"å¯ä½¿ç”¨ [code]*_create[/code] 函数创建资æºã€‚\n"
-"所有的对象都被绘制到视窗中。你å¯ä»¥ä½¿ç”¨é™„在 [SceneTree] 上的 [Viewport],或者"
+"所有的对象都被绘制到视å£ä¸­ã€‚ä½ å¯ä»¥ä½¿ç”¨é™„在 [SceneTree] 上的 [Viewport],或者"
"用 [method viewport_create] 自己创建一个。当使用自定义场景或画布时,需è¦ä½¿ç”¨ "
"[method viewport_set_scenario] 或 [method viewport_attach_canvas] 将场景或画"
-"布附加到视窗上。\n"
+"布附加到视å£ä¸Šã€‚\n"
"在 3D 中,所有的视觉对象都必须与一个场景相关è”。场景是世界的一个视觉表现。如"
"果从一个正在è¿è¡Œçš„游æˆä¸­è®¿é—®è§†è§‰æœåŠ¡ï¼Œåœºæ™¯å¯ä»¥é€šè¿‡ [method Spatial."
"get_world] 从场景树中的任何 [Spatial] 节点访问。å¦å¤–,å¯ä»¥ç”¨ [method "
@@ -87431,7 +87502,7 @@ msgstr ""
"一个实例。实例也必须使用 [method instance_set_scenario] 附加到场景中,以便å¯"
"è§ã€‚\n"
"在 2D 中,所有å¯è§å¯¹è±¡éƒ½æ˜¯æŸç§å½¢å¼çš„画布项目。为了å¯è§ï¼Œä¸€ä¸ªç”»å¸ƒé¡¹éœ€è¦æ˜¯è¿žæŽ¥"
-"到视窗的画布的å­é¡¹ï¼Œæˆ–者它需è¦æ˜¯æœ€ç»ˆè¿žæŽ¥åˆ°ç”»å¸ƒçš„å¦ä¸€ä¸ªç”»å¸ƒé¡¹çš„å­é¡¹ã€‚"
+"到视å£çš„画布的å­é¡¹ï¼Œæˆ–者它需è¦æ˜¯æœ€ç»ˆè¿žæŽ¥åˆ°ç”»å¸ƒçš„å¦ä¸€ä¸ªç”»å¸ƒé¡¹çš„å­é¡¹ã€‚"
#: doc/classes/VisualServer.xml
msgid "Sets images to be rendered in the window margin."
@@ -87660,7 +87731,7 @@ msgid ""
"Sets the parent for the [CanvasItem]. The parent can be another canvas item, "
"or it can be the root canvas that is attached to the viewport."
msgstr ""
-"设置[CanvasItem]的父级。父级å¯ä»¥æ˜¯å¦ä¸€ä¸ªç”»å¸ƒé¡¹ç›®ï¼Œä¹Ÿå¯ä»¥æ˜¯è¿žæŽ¥åˆ°è§†çª—的根画"
+"设置[CanvasItem]的父级。父级å¯ä»¥æ˜¯å¦ä¸€ä¸ªç”»å¸ƒé¡¹ç›®ï¼Œä¹Ÿå¯ä»¥æ˜¯è¿žæŽ¥åˆ°è§†å£çš„根画"
"布。"
#: doc/classes/VisualServer.xml
@@ -89743,7 +89814,7 @@ msgid ""
"[/codeblock]"
msgstr ""
"在两个纹ç†ä¹‹é—´åˆ›å»ºæ›´æ–°é“¾ï¼Œä¸Ž [ViewportTexture] 的原ç†ç±»ä¼¼ã€‚基础纹ç†ä¸º "
-"[Viewport] 的纹ç†æ—¶ï¼Œè§†åŒºæ¯æ–°æ¸²æŸ“一帧,代ç†çº¹ç†å°±ä¼šè‡ªåŠ¨æ”¶åˆ°æ›´æ–°ã€‚\n"
+"[Viewport] 的纹ç†æ—¶ï¼Œè§†å£æ¯æ–°æ¸²æŸ“一帧,代ç†çº¹ç†å°±ä¼šè‡ªåŠ¨æ”¶åˆ°æ›´æ–°ã€‚\n"
"例如,此处的代ç ä¼šåˆ©ç”¨ VisualServer API 将一张通用的 [ImageTexture] 链接到 "
"[Viewport] 的纹ç†è¾“出上:\n"
"[codeblock]\n"
@@ -89781,7 +89852,7 @@ msgstr "设置视图的相机。"
#: doc/classes/VisualServer.xml
msgid "Sets a viewport's canvas."
-msgstr "设置视窗的画布。"
+msgstr "设置视å£çš„画布。"
#: doc/classes/VisualServer.xml
msgid ""
@@ -89804,18 +89875,18 @@ msgid ""
"manually. For further optimization, see [method "
"viewport_set_render_direct_to_screen]."
msgstr ""
-"将视窗å¤åˆ¶åˆ°å±å¹•ä¸Šç”± [code]rect[/code] 指定的区域。如果 [member Viewport."
-"render_direct_to_screen] 为 [code]true[/code],那么视窗就ä¸ä¼šä½¿ç”¨å¸§ç¼“冲,视窗"
-"的内容会直接渲染到å±å¹•ä¸Šã€‚然而,请注æ„,根视窗是最åŽç»˜åˆ¶çš„,因此它将在å±å¹•ä¸Š"
-"绘制。相应地,你就必须将根视窗设置为一个ä¸è¦†ç›–你所附加的这个视窗的区域。\n"
-"例如,你å¯ä»¥ç”¨ä»¥ä¸‹ä»£ç å°†æ ¹è§†çª—设置为完全ä¸æ¸²æŸ“。\n"
+"将视å£å¤åˆ¶åˆ°å±å¹•ä¸Šç”± [code]rect[/code] 指定的区域。如果 [member Viewport."
+"render_direct_to_screen] 为 [code]true[/code],那么视å£å°±ä¸ä¼šä½¿ç”¨å¸§ç¼“冲,视å£"
+"的内容会直接渲染到å±å¹•ä¸Šã€‚然而,请注æ„,根视å£æ˜¯æœ€åŽç»˜åˆ¶çš„,因此它将在å±å¹•ä¸Š"
+"绘制。相应地,你就必须将根视å£è®¾ç½®ä¸ºä¸€ä¸ªä¸è¦†ç›–你所附加的这个视å£çš„区域。\n"
+"例如,你å¯ä»¥ç”¨ä»¥ä¸‹ä»£ç å°†æ ¹è§†å£è®¾ç½®ä¸ºå®Œå…¨ä¸æ¸²æŸ“。\n"
"[codeblock]\n"
"func _ready():\n"
" get_viewport().set_attach_to_screen_rect(Rect2())\n"
" $Viewport.set_attach_to_screen_rect(Rect2(0, 0, 600, 600))\n"
"[/codeblock]\n"
"使用这个方法å¯ä»¥å¸¦æ¥æ˜Žæ˜¾çš„优化,特别是在低端设备上。然而,它的代价是必须手动"
-"管ç†ä½ çš„视窗。进一步的优化请å‚阅 [method "
+"管ç†ä½ çš„视å£ã€‚进一步的优化请å‚阅 [method "
"viewport_set_render_direct_to_screen]。"
#: doc/classes/VisualServer.xml
@@ -89826,32 +89897,32 @@ msgid ""
"Once finished with your RID, you will want to free the RID using the "
"VisualServer's [method free_rid] static method."
msgstr ""
-"创建一个空视窗并将其添加到 VisualServer 中。å¯ä»¥ç”¨è¿”回的RIDæ¥è®¿é—®å®ƒã€‚这个RID"
+"创建一个空视å£å¹¶å°†å…¶æ·»åŠ åˆ° VisualServer 中。å¯ä»¥ç”¨è¿”回的RIDæ¥è®¿é—®å®ƒã€‚这个RID"
"将用于所有[code]viewport_*[/code] 的VisualServer函数。\n"
"一旦你用完了RID,你è¦ä½¿ç”¨VisualServerçš„[method free_rid]é™æ€æ–¹æ³•é‡Šæ”¾RID。"
#: doc/classes/VisualServer.xml
msgid "Detaches the viewport from the screen."
-msgstr "将视窗从å±å¹•ä¸Šåˆ†ç¦»ã€‚"
+msgstr "将视å£ä»Žå±å¹•ä¸Šåˆ†ç¦»ã€‚"
#: doc/classes/VisualServer.xml
msgid ""
"Returns a viewport's render information. For options, see the [enum "
"ViewportRenderInfo] constants."
-msgstr "返回视窗的渲染信æ¯ã€‚有关选项,请å‚阅 [enum ViewportRenderInfo] 常é‡ã€‚"
+msgstr "返回视å£çš„渲染信æ¯ã€‚有关选项,请å‚阅 [enum ViewportRenderInfo] 常é‡ã€‚"
#: doc/classes/VisualServer.xml
msgid "Returns the viewport's last rendered frame."
-msgstr "返回视窗的最åŽæ¸²æŸ“帧。"
+msgstr "返回视å£çš„最åŽæ¸²æŸ“帧。"
#: doc/classes/VisualServer.xml
msgid "Detaches a viewport from a canvas and vice versa."
-msgstr "从画布分离视窗,å之亦然。"
+msgstr "从画布分离视å£ï¼Œå之亦然。"
#: doc/classes/VisualServer.xml
msgid "If [code]true[/code], sets the viewport active, else sets it inactive."
msgstr ""
-"如果为 [code]true[/code],则将视窗设置为活动状æ€ï¼Œå¦åˆ™å°†å…¶è®¾ç½®ä¸ºéžæ´»åŠ¨çŠ¶æ€ã€‚"
+"如果为 [code]true[/code],则将视å£è®¾ç½®ä¸ºæ´»åŠ¨çŠ¶æ€ï¼Œå¦åˆ™å°†å…¶è®¾ç½®ä¸ºéžæ´»åŠ¨çŠ¶æ€ã€‚"
#: doc/classes/VisualServer.xml
msgid ""
@@ -89859,37 +89930,37 @@ msgid ""
"[code]layer[/code] is the actual canvas layer, while [code]sublayer[/code] "
"specifies the stacking order of the canvas among those in the same layer."
msgstr ""
-"设置视窗画布的堆å é¡ºåºã€‚\n"
+"设置视å£ç”»å¸ƒçš„å †å é¡ºåºã€‚\n"
"[code]layer[/code] 是实际的画布层,而 [code]sublayer[/code] 则指定画布在åŒä¸€"
"层中的堆å é¡ºåºã€‚"
#: doc/classes/VisualServer.xml
msgid "Sets the transformation of a viewport's canvas."
-msgstr "设置视窗画布的å˜æ¢ã€‚"
+msgstr "设置视å£ç”»å¸ƒçš„å˜æ¢ã€‚"
#: doc/classes/VisualServer.xml
msgid ""
"Sets the clear mode of a viewport. See [enum ViewportClearMode] for options."
-msgstr "设置视窗的清除模å¼ã€‚å¯é€‰é¡¹è§ [enum ViewportClearMode]。"
+msgstr "设置视å£çš„清除模å¼ã€‚å¯é€‰é¡¹è§ [enum ViewportClearMode]。"
#: doc/classes/VisualServer.xml
msgid ""
"Sets the debug draw mode of a viewport. See [enum ViewportDebugDraw] for "
"options."
-msgstr "设置视窗的调试绘图模å¼ã€‚å¯é€‰é¡¹è§ [enum ViewportDebugDraw]。"
+msgstr "设置视å£çš„调试绘图模å¼ã€‚å¯é€‰é¡¹è§ [enum ViewportDebugDraw]。"
#: doc/classes/VisualServer.xml
msgid "If [code]true[/code], a viewport's 3D rendering is disabled."
-msgstr "如果为 [code]true[/code],则视窗的 3D 渲染将ç¦ç”¨ã€‚"
+msgstr "如果为 [code]true[/code],则视å£çš„ 3D 渲染将ç¦ç”¨ã€‚"
#: doc/classes/VisualServer.xml
msgid ""
"If [code]true[/code], rendering of a viewport's environment is disabled."
-msgstr "如果为 [code]true[/code],则ç¦ç”¨è§†çª—环境的渲染。"
+msgstr "如果为 [code]true[/code],则ç¦ç”¨è§†å£çŽ¯å¢ƒçš„渲染。"
#: doc/classes/VisualServer.xml
msgid "Sets the viewport's global transformation matrix."
-msgstr "设置视窗的全局å˜æ¢çŸ©é˜µã€‚"
+msgstr "设置视å£çš„全局å˜æ¢çŸ©é˜µã€‚"
#: doc/classes/VisualServer.xml
msgid ""
@@ -89898,13 +89969,13 @@ msgid ""
"viewport_set_use_32_bpc_depth].\n"
"[b]Note:[/b] Only available on the GLES3 backend."
msgstr ""
-"如果为 [code]true[/code],该视区会渲染至高动æ€èŒƒå›´ï¼ˆHDR)而ä¸æ˜¯æ ‡å‡†åŠ¨æ€èŒƒå›´"
+"如果为 [code]true[/code],该视å£ä¼šæ¸²æŸ“至高动æ€èŒƒå›´ï¼ˆHDR)而ä¸æ˜¯æ ‡å‡†åŠ¨æ€èŒƒå›´"
"(SDR)。å¦è¯·å‚阅 [method viewport_set_use_32_bpc_depth]。\n"
"[b]注æ„:[/b]仅在 GLES3 åŽç«¯å¯ç”¨ã€‚"
#: doc/classes/VisualServer.xml
msgid "If [code]true[/code], the viewport's canvas is not rendered."
-msgstr "如果为 [code]true[/code],则ä¸æ¸²æŸ“视窗的画布。"
+msgstr "如果为 [code]true[/code],则ä¸æ¸²æŸ“视å£çš„画布。"
#: doc/classes/VisualServer.xml
msgid "Currently unimplemented in Godot 3.x."
@@ -89916,7 +89987,7 @@ msgstr "设置抗锯齿模å¼ã€‚å¯é€‰é¡¹è§ [enum ViewportMSAA]。"
#: doc/classes/VisualServer.xml
msgid "Sets the viewport's parent to another viewport."
-msgstr "设置视窗的父视窗到å¦ä¸€ä¸ªè§†çª—。"
+msgstr "设置视å£çš„父视å£åˆ°å¦ä¸€ä¸ªè§†å£ã€‚"
#: doc/classes/VisualServer.xml
msgid ""
@@ -89933,12 +90004,12 @@ msgid ""
"will be drawn, no automatic scaling is possible, even if your game scene is "
"significantly larger than the window size."
msgstr ""
-"如果为 [code]true[/code],直接将视窗的内容渲染到å±å¹•ä¸Šã€‚è¿™å…许一个低级别的优"
-"化,你å¯ä»¥è·³è¿‡ç»˜åˆ¶è§†çª—到根视窗。虽然这ç§ä¼˜åŒ–å¯ä»¥æ˜¾è‘—æ高速度(特别是在旧设备"
-"上),但它是以牺牲å¯ç”¨æ€§ä¸ºä»£ä»·çš„。当å¯ç”¨è¿™ä¸ªåŠŸèƒ½æ—¶ï¼Œä½ ä¸èƒ½ä»Žè§†çª—或"
+"如果为 [code]true[/code],直接将视å£çš„内容渲染到å±å¹•ä¸Šã€‚è¿™å…许一个低级别的优"
+"化,你å¯ä»¥è·³è¿‡ç»˜åˆ¶è§†å£åˆ°æ ¹è§†å£ã€‚虽然这ç§ä¼˜åŒ–å¯ä»¥æ˜¾è‘—æ高速度(特别是在旧设备"
+"上),但它是以牺牲å¯ç”¨æ€§ä¸ºä»£ä»·çš„。当å¯ç”¨è¿™ä¸ªåŠŸèƒ½æ—¶ï¼Œä½ ä¸èƒ½ä»Žè§†å£æˆ–"
"[code]SCREEN_TEXTURE[/code]中读å–。你也会失去æŸäº›çª—å£è®¾ç½®çš„好处,比如å„ç§æ‹‰ä¼¸"
"模å¼ã€‚å¦ä¸€ä¸ªéœ€è¦æ³¨æ„çš„åŽæžœæ˜¯ï¼Œåœ¨2D中,渲染是以窗å£å标进行的,所以如果你有一"
-"个两å€äºŽçª—å£å¤§å°çš„视窗,并且你设置了这个,那么åªæœ‰é€‚åˆçª—å£çš„部分æ‰ä¼šè¢«ç»˜åˆ¶ï¼Œ"
+"个两å€äºŽçª—å£å¤§å°çš„视å£ï¼Œå¹¶ä¸”你设置了这个,那么åªæœ‰é€‚åˆçª—å£çš„部分æ‰ä¼šè¢«ç»˜åˆ¶ï¼Œ"
"没有自动缩放的å¯èƒ½ï¼Œå³ä½¿ä½ çš„游æˆåœºæ™¯æ˜Žæ˜¾å¤§äºŽçª—å£å¤§å°ã€‚"
#: doc/classes/VisualServer.xml
@@ -89947,7 +90018,7 @@ msgid ""
"The scenario contains information about the [enum ScenarioDebugMode], "
"environment information, reflection atlas etc."
msgstr ""
-"设置一个视窗的场景。\n"
+"设置视å£çš„场景。\n"
"åœºæ™¯åŒ…å« [enum ScenarioDebugMode] çš„ä¿¡æ¯ã€çŽ¯å¢ƒä¿¡æ¯ã€å射图集等。"
#: doc/classes/VisualServer.xml
@@ -89971,31 +90042,31 @@ msgid ""
"[code]0.5[/code] generally give the best results. See also [method "
"viewport_set_use_fxaa]."
msgstr ""
-"为视窗[code]viewport[/code]设定é”化强度[code]intensity[/code]。如果设置为大于"
-"[code]0.0[/code]的值,对比度适应性é”化将被应用到3D视窗中。这具有较低的性能æˆ"
+"为视å£[code]viewport[/code]设定é”化强度[code]intensity[/code]。如果设置为大于"
+"[code]0.0[/code]的值,对比度适应性é”化将被应用到3D视å£ä¸­ã€‚这具有较低的性能æˆ"
"本,å¯ä»¥ç”¨æ¥æ¢å¤ä½¿ç”¨FXAAæ—¶æŸå¤±çš„一些é”度。一般æ¥è¯´ï¼Œ[code]0.5[/code]å·¦å³çš„值"
"å¯ä»¥å¾—到最好的效果。å‚阅[method viewport_set_use_fxaa]。"
#: doc/classes/VisualServer.xml
msgid "Sets the viewport's width and height."
-msgstr "设置视窗的宽度和高度。"
+msgstr "设置视å£çš„宽度和高度。"
#: doc/classes/VisualServer.xml
msgid ""
"If [code]true[/code], the viewport renders its background as transparent."
-msgstr "如果为 [code]true[/code],视窗将其背景渲染为é€æ˜Žã€‚"
+msgstr "如果为 [code]true[/code],视å£å°†å…¶èƒŒæ™¯æ¸²æŸ“为é€æ˜Žã€‚"
#: doc/classes/VisualServer.xml
msgid ""
"Sets when the viewport should be updated. See [enum ViewportUpdateMode] "
"constants for options."
-msgstr "设置应更新视窗的时间。å¯é€‰é¡¹è¯·å‚阅 [enum ViewportUpdateMode] 。"
+msgstr "设置应更新视å£çš„时间。å¯é€‰é¡¹è¯·å‚阅 [enum ViewportUpdateMode] 。"
#: doc/classes/VisualServer.xml
msgid ""
"Sets the viewport's 2D/3D mode. See [enum ViewportUsage] constants for "
"options."
-msgstr "设置视窗的 2D/3D 模å¼ã€‚é€‰é¡¹è§ [enum ViewportUsage] 常é‡ã€‚"
+msgstr "设置视å£çš„ 2D/3D 模å¼ã€‚é€‰é¡¹è§ [enum ViewportUsage] 常é‡ã€‚"
#: doc/classes/VisualServer.xml
msgid ""
@@ -90005,7 +90076,7 @@ msgid ""
"on the same [Viewport] to set HDR to [code]true[/code].\n"
"[b]Note:[/b] Only available on the GLES3 backend."
msgstr ""
-"如果为 [code]true[/code],分é…该视区的帧缓冲时将使用完整浮点数精度(32 ä½ï¼‰è€Œ"
+"如果为 [code]true[/code],分é…该视å£çš„帧缓冲时将使用完整浮点数精度(32 ä½ï¼‰è€Œ"
"ä¸æ˜¯åŠæµ®ç‚¹æ•°ç²¾åº¦ï¼ˆ16 ä½ï¼‰ã€‚åªæœ‰åœ¨åŒä¸€ä¸ª [Viewport] 上通过 [method "
"viewport_set_use_32_bpc_depth] 将 HDR 设为 [code]true[/code] 时有效。\n"
"[b]注æ„:[/b]仅在 GLES3 åŽç«¯ä¸­å¯ç”¨ã€‚"
@@ -90015,7 +90086,7 @@ msgid ""
"If [code]true[/code], the viewport uses augmented or virtual reality "
"technologies. See [ARVRInterface]."
msgstr ""
-"如果为 [code]true[/code]ï¼Œåˆ™è§†çª—ä½¿ç”¨å¢žå¼ºæˆ–è™šæ‹ŸçŽ°å®žæŠ€æœ¯ã€‚è§ [ARVRInterface]。"
+"如果为 [code]true[/code],则视å£ä½¿ç”¨å¢žå¼ºæˆ–è™šæ‹ŸçŽ°å®žæŠ€æœ¯ã€‚è§ [ARVRInterface]。"
#: doc/classes/VisualServer.xml
msgid ""
@@ -90042,14 +90113,14 @@ msgid ""
"recovered by enabling contrast-adaptive sharpening (see [method "
"viewport_set_sharpen_intensity])."
msgstr ""
-"å¯ç”¨è¯¥è§†çª—的快速近似抗锯齿。FXAA 是一ç§æµè¡Œçš„å±å¹•ç©ºé—´æŠ—锯齿方法,它速度快,但"
+"å¯ç”¨è¯¥è§†å£çš„快速近似抗锯齿。FXAA 是一ç§æµè¡Œçš„å±å¹•ç©ºé—´æŠ—锯齿方法,它速度快,但"
"会使图åƒçœ‹èµ·æ¥å¾ˆæ¨¡ç³Šï¼Œç‰¹åˆ«æ˜¯åœ¨ä½Žåˆ†è¾¨çŽ‡ä¸‹ã€‚在 1440p å’Œ 4K 等高分辨率下,它ä»ç„¶"
"å¯ä»¥å·¥ä½œå¾—比较好。一些æŸå¤±çš„é”度å¯ä»¥é€šè¿‡å¯ç”¨å¯¹æ¯”度适应性é”化æ¥æ¢å¤ï¼ˆè§ "
"[method viewport_set_sharpen_intensity])。"
#: doc/classes/VisualServer.xml
msgid "If [code]true[/code], the viewport's rendering is flipped vertically."
-msgstr "如果为 [code]true[/code],则视窗的渲染垂直翻转。"
+msgstr "如果为 [code]true[/code],则视å£çš„渲染垂直翻转。"
#: doc/classes/VisualServer.xml
msgid ""
@@ -90440,33 +90511,33 @@ msgstr "优化阴影贴图的使用,æ高有效分辨率。但å¯èƒ½ä¼šå¯¼è‡´
#: doc/classes/VisualServer.xml
msgid "Do not update the viewport."
-msgstr "ä¸è¦æ›´æ–°è§†çª—。"
+msgstr "ä¸è¦æ›´æ–°è§†å£ã€‚"
#: doc/classes/VisualServer.xml
msgid "Update the viewport once then set to disabled."
-msgstr "更新一次视窗,然åŽè®¾ç½®ä¸ºç¦ç”¨ã€‚"
+msgstr "更新一次视å£ï¼Œç„¶åŽè®¾ç½®ä¸ºç¦ç”¨ã€‚"
#: doc/classes/VisualServer.xml
msgid "Update the viewport whenever it is visible."
-msgstr "åªè¦è§†çª—是å¯è§çš„,就更新视窗。"
+msgstr "åªè¦è§†å£æ˜¯å¯è§çš„,就更新视å£ã€‚"
#: doc/classes/VisualServer.xml
msgid "Always update the viewport."
-msgstr "始终更新视窗。"
+msgstr "始终更新视å£ã€‚"
#: doc/classes/VisualServer.xml
msgid "The viewport is always cleared before drawing."
-msgstr "在绘图之å‰ï¼Œè§†çª—总是被清空。"
+msgstr "在绘图之å‰ï¼Œè§†å£æ€»æ˜¯è¢«æ¸…空。"
#: doc/classes/VisualServer.xml
msgid "The viewport is never cleared before drawing."
-msgstr "在绘图之å‰ï¼Œè§†çª—永远ä¸ä¼šè¢«æ¸…空。"
+msgstr "在绘图之å‰ï¼Œè§†å£æ°¸è¿œä¸ä¼šè¢«æ¸…空。"
#: doc/classes/VisualServer.xml
msgid ""
"The viewport is cleared once, then the clear mode is set to [constant "
"VIEWPORT_CLEAR_NEVER]."
-msgstr "视窗被清除一次,然åŽæ¸…除模å¼è®¾ç½®ä¸º [constant VIEWPORT_CLEAR_NEVER]。"
+msgstr "视å£è¢«æ¸…除一次,然åŽæ¸…除模å¼è®¾ç½®ä¸º [constant VIEWPORT_CLEAR_NEVER]。"
#: doc/classes/VisualServer.xml
msgid "Multisample antialiasing is disabled."
@@ -92375,7 +92446,7 @@ msgstr "使用给定的纹ç†ä½œä¸ºæ­¤å‡½æ•°çš„å‚数。"
#: doc/classes/VisualShaderNodeTexture.xml
msgid "Use the current viewport's texture as the source."
-msgstr "使用当å‰è§†çª—的纹ç†ä½œä¸ºæºã€‚"
+msgstr "使用当å‰è§†å£çš„纹ç†ä½œä¸ºæºã€‚"
#: doc/classes/VisualShaderNodeTexture.xml
msgid ""
diff --git a/doc/translations/zh_TW.po b/doc/translations/zh_TW.po
index a64bd25054..a21d110c05 100644
--- a/doc/translations/zh_TW.po
+++ b/doc/translations/zh_TW.po
@@ -15,12 +15,14 @@
# Otis Kao <momoslim@gmail.com>, 2022.
# YuChiang Chang <chiang.c.tw@gmail.com>, 2022.
# Hugel <qihu@nfschina.com>, 2022.
+# Chih Wei Chien <dppss92132@gmail.com>, 2022.
+# Edison Lee <edisonlee@edisonlee55.com>, 2023.
msgid ""
msgstr ""
"Project-Id-Version: Godot Engine class reference\n"
"Report-Msgid-Bugs-To: https://github.com/godotengine/godot\n"
-"PO-Revision-Date: 2022-10-12 06:50+0000\n"
-"Last-Translator: BinotaLIU <me@binota.org>\n"
+"PO-Revision-Date: 2023-01-15 03:49+0000\n"
+"Last-Translator: Edison Lee <edisonlee@edisonlee55.com>\n"
"Language-Team: Chinese (Traditional) <https://hosted.weblate.org/projects/"
"godot-engine/godot-class-reference/zh_Hant/>\n"
"Language: zh_TW\n"
@@ -28,7 +30,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8-bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
-"X-Generator: Weblate 4.15-dev\n"
+"X-Generator: Weblate 4.15.1-dev\n"
#: doc/tools/make_rst.py
msgid "Description"
@@ -84,7 +86,7 @@ msgstr "繼承自:"
#: doc/tools/make_rst.py
msgid "(overrides %s)"
-msgstr ""
+msgstr "(覆寫 %s)"
#: doc/tools/make_rst.py
msgid "Default"
@@ -126,13 +128,13 @@ msgstr "此方法用於建構型別。"
msgid ""
"This method doesn't need an instance to be called, so it can be called "
"directly using the class name."
-msgstr ""
+msgstr "該方法ä¸éœ€è¦ä½¿ç”¨ä¸€å€‹å¯¦é«”來呼å«ï¼Œæ‰€ä»¥ä»–å¯ä»¥ç›´æŽ¥ä½¿ç”¨ class name 呼å«ã€‚"
#: doc/tools/make_rst.py
msgid ""
"This method describes a valid operator to use with this type as left-hand "
"operand."
-msgstr ""
+msgstr "該方法æ述一個有效的é‹ç®—å­ä½¿ç”¨æ­¤åž‹åˆ¥ä½œç‚ºå·¦é‹ç®—值。"
#: modules/gdscript/doc_classes/@GDScript.xml
msgid "Built-in GDScript functions."
@@ -148,7 +150,6 @@ msgstr ""
"供。 (é—œéµå­—:內建ã€å…¨åŸŸå‡½å¼ã€buildinã€build inã€global functions)"
#: modules/gdscript/doc_classes/@GDScript.xml
-#, fuzzy
msgid ""
"Returns a color constructed from integer red, green, blue, and alpha "
"channels. Each channel should have 8 bits of information ranging from 0 to "
@@ -161,12 +162,12 @@ msgid ""
"red = Color8(255, 0, 0)\n"
"[/codeblock]"
msgstr ""
-"回傳以整數紅色ã€ç¶ è‰²ã€è—色與 Alpha 通é“構æˆçš„色彩。æ¯å€‹é€šé“éƒ½æ‡‰åŒ…å« 0 至 255 "
-"çš„ 8 ä½å…ƒè³‡è¨Šã€‚\n"
+"回傳以整數紅色ã€ç¶ è‰²ã€è—色與é€æ˜Žé€šé“構æˆçš„色彩。æ¯å€‹é€šé“éƒ½æ‡‰åŒ…å« 0 至 255 çš„ "
+"8 ä½å…ƒè³‡è¨Šã€‚\n"
"[code]r8[/code] 紅色通é“\n"
"[code]g8[/code] 綠色通é“\n"
"[code]b8[/code] è—色通é“\n"
-"[code]a8[/code] Alpha 通é“\n"
+"[code]a8[/code] é€æ˜Žé€šé“\n"
"[codeblock]\n"
"red = Color8(255, 0, 0)\n"
"[/codeblock]"
@@ -201,7 +202,6 @@ msgstr ""
"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
-#, fuzzy
msgid ""
"Returns the arc cosine of [code]s[/code] in radians. Use to get the angle of "
"cosine [code]s[/code]. [code]s[/code] must be between [code]-1.0[/code] and "
@@ -212,15 +212,15 @@ msgid ""
"c = acos(0.866025)\n"
"[/codeblock]"
msgstr ""
-"回傳以弧度表示的[code]s[/code]çš„å餘弦(cos)值。用於求餘弦(sin)值[code]s[/"
-"code]的夾角。\n"
+"回傳以弧度表示的[code]s[/code]çš„å餘弦(arc cos)值。用於求餘弦(cos)值[code]s[/"
+"code]的夾角。[code]s[/code]必須介於[code]-1.0[/code]與[code]1.0[/code]之間 "
+"(包å«),å¦å‰‡ [method acos] 會回傳 [constant NAN]。\n"
"[codeblock]\n"
-"# c 為0.523599,若以rad2deg(s)æ›ç®—,則為30度\n"
+"# c 為 0.523599,若以 rad2deg(s) æ›ç®—,則為30度\n"
"c = acos(0.866025)\n"
"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
-#, fuzzy
msgid ""
"Returns the arc sine of [code]s[/code] in radians. Use to get the angle of "
"sine [code]s[/code]. [code]s[/code] must be between [code]-1.0[/code] and "
@@ -230,7 +230,14 @@ msgid ""
"# s is 0.523599 or 30 degrees if converted with rad2deg(s)\n"
"s = asin(0.5)\n"
"[/codeblock]"
-msgstr "testing"
+msgstr ""
+"回傳以弧度表示的[code]s[/code]çš„å正弦(arc sin)值。用於求正弦 (sin) 值"
+"[code]s[/code]的夾角。[code]s[/code]必須介於[code]-1.0[/code]與[code]1.0[/"
+"code]之間 (包å«),å¦å‰‡ [method asin] 會回傳 [constant NAN]。\n"
+"[codeblock]\n"
+"# c 為 0.523599,若以 rad2deg(s) æ›ç®—,則為 30 度\n"
+"c = asin(0.5)\n"
+"[/codeblock]"
#: modules/gdscript/doc_classes/@GDScript.xml
#, fuzzy
@@ -30066,7 +30073,11 @@ msgid ""
"using an [AnimatedTexture], only the first frame will be displayed.\n"
"[b]Note:[/b] Only images imported with the [b]Lossless[/b], [b]Lossy[/b] or "
"[b]Uncompressed[/b] compression modes are supported. The [b]Video RAM[/b] "
-"compression mode can't be used for custom cursors."
+"compression mode can't be used for custom cursors.\n"
+"[b]Note:[/b] On the web platform, the maximum allowed cursor image size is "
+"128×128. Cursor images larger than 32×32 will also only be displayed if the "
+"mouse cursor image is entirely located within the page for [url=https://"
+"chromestatus.com/feature/5825971391299584]security reasons[/url]."
msgstr ""
#: doc/classes/Input.xml
@@ -41853,7 +41864,7 @@ msgstr ""
#: doc/classes/OS.xml
msgid "Desktop directory path."
-msgstr ""
+msgstr "æ¡Œé¢è³‡æ–™å¤¾è·¯å¾‘。"
#: doc/classes/OS.xml
msgid "DCIM (Digital Camera Images) directory path."
@@ -41861,27 +41872,27 @@ msgstr ""
#: doc/classes/OS.xml
msgid "Documents directory path."
-msgstr ""
+msgstr "檔案資料夾路徑。"
#: doc/classes/OS.xml
msgid "Downloads directory path."
-msgstr ""
+msgstr "下載資料夾路徑。"
#: doc/classes/OS.xml
msgid "Movies directory path."
-msgstr ""
+msgstr "影片資料夾路徑。"
#: doc/classes/OS.xml
msgid "Music directory path."
-msgstr ""
+msgstr "音樂資料夾路徑。"
#: doc/classes/OS.xml
msgid "Pictures directory path."
-msgstr ""
+msgstr "圖片資料夾路徑。"
#: doc/classes/OS.xml
msgid "Ringtones directory path."
-msgstr ""
+msgstr "鈴è²è³‡æ–™å¤¾è·¯å¾‘。"
#: doc/classes/OS.xml
msgid "Unknown powerstate."