From 4779a1dbdf1d2601c0e2f3376eac3036df386be9 Mon Sep 17 00:00:00 2001 From: Godot Organization Date: Sat, 13 Apr 2024 03:17:16 +0000 Subject: [PATCH] classref: Sync with current master branch (029aade) --- classes/class_@gdscript.rst | 2 +- classes/class_@globalscope.rst | 14 +- classes/class_animatablebody3d.rst | 6 +- classes/class_animatedsprite2d.rst | 2 +- classes/class_animationnodeadd3.rst | 2 +- classes/class_animationnodeanimation.rst | 4 +- classes/class_animationnodeblend2.rst | 4 +- classes/class_animationnodeblendspace2d.rst | 2 +- classes/class_animationnodeoneshot.rst | 2 +- classes/class_animationnodeoutput.rst | 4 +- classes/class_animationnodetimescale.rst | 2 +- classes/class_animationnodetransition.rst | 4 +- classes/class_animationplayer.rst | 2 +- classes/class_animationtree.rst | 2 +- classes/class_area2d.rst | 6 +- classes/class_area3d.rst | 10 +- classes/class_array.rst | 40 +- classes/class_arrayoccluder3d.rst | 4 + classes/class_audioeffect.rst | 2 +- classes/class_audioeffectrecord.rst | 2 +- classes/class_audioeffectreverb.rst | 2 +- classes/class_audioeffectspectrumanalyzer.rst | 2 +- classes/class_audioserver.rst | 6 +- classes/class_audiostream.rst | 6 +- classes/class_audiostreamgenerator.rst | 2 +- .../class_audiostreamgeneratorplayback.rst | 2 +- classes/class_audiostreammp3.rst | 2 + classes/class_audiostreamplayback.rst | 2 +- classes/class_audiostreamplayer.rst | 60 +- classes/class_audiostreamwav.rst | 2 + classes/class_basis.rst | 8 +- classes/class_boxshape3d.rst | 6 +- classes/class_button.rst | 4 +- classes/class_camera2d.rst | 6 +- classes/class_camera3d.rst | 2 +- classes/class_cameraserver.rst | 2 +- classes/class_canvasitem.rst | 10 +- classes/class_canvaslayer.rst | 2 +- classes/class_capsuleshape3d.rst | 2 +- classes/class_characterbody2d.rst | 12 +- classes/class_characterbody3d.rst | 16 +- classes/class_collisionpolygon2d.rst | 2 +- classes/class_collisionpolygon3d.rst | 2 +- classes/class_collisionshape2d.rst | 6 +- classes/class_collisionshape3d.rst | 6 +- classes/class_color.rst | 6 +- classes/class_colorpicker.rst | 2 +- classes/class_colorpickerbutton.rst | 4 +- classes/class_colorrect.rst | 2 +- classes/class_concavepolygonshape2d.rst | 2 + classes/class_concavepolygonshape3d.rst | 2 +- classes/class_configfile.rst | 2 +- classes/class_control.rst | 2 +- classes/class_convexpolygonshape2d.rst | 2 + classes/class_convexpolygonshape3d.rst | 4 +- classes/class_cpuparticles2d.rst | 6 + classes/class_cpuparticles3d.rst | 6 + classes/class_csgpolygon3d.rst | 2 + classes/class_cylindershape3d.rst | 6 +- classes/class_dictionary.rst | 4 +- classes/class_displayserver.rst | 28 +- classes/class_editorexportplatformandroid.rst | 46 +- classes/class_editorexportplatformios.rst | 2 +- classes/class_editorexportplatformmacos.rst | 4 +- classes/class_editorexportplatformpc.rst | 16 + classes/class_editorexportplatformwindows.rst | 9 + classes/class_editorfiledialog.rst | 2 + classes/class_editorpaths.rst | 6 +- classes/class_editorsettings.rst | 4 +- classes/class_environment.rst | 6 +- classes/class_fileaccess.rst | 4 +- classes/class_filedialog.rst | 2 + classes/class_fontfile.rst | 2 + classes/class_gltfmesh.rst | 2 + classes/class_gltfnode.rst | 2 + classes/class_gltfphysicsbody.rst | 2 +- classes/class_gltfphysicsshape.rst | 30 +- classes/class_gltfstate.rst | 4 + classes/class_gpuparticles2d.rst | 20 +- classes/class_gpuparticles3d.rst | 18 +- classes/class_gradient.rst | 12 +- classes/class_gridcontainer.rst | 2 +- classes/class_gridmap.rst | 4 +- classes/class_heightmapshape3d.rst | 2 + classes/class_input.rst | 4 +- classes/class_inputevent.rst | 4 +- classes/class_inputeventaction.rst | 4 +- classes/class_inputeventkey.rst | 4 +- classes/class_inputeventmousemotion.rst | 2 +- classes/class_javaclass.rst | 13 +- classes/class_javaclasswrapper.rst | 15 +- classes/class_joint3d.rst | 2 +- classes/class_jsonrpc.rst | 24 +- classes/class_label.rst | 4 +- classes/class_light3d.rst | 2 +- classes/class_line2d.rst | 6 +- classes/class_material.rst | 4 +- classes/class_mesh.rst | 8 +- classes/class_meshinstance3d.rst | 72 ++- classes/class_meshlibrary.rst | 4 +- classes/class_multimesh.rst | 8 + classes/class_multiplayerpeer.rst | 2 - classes/class_navigationagent2d.rst | 40 ++ classes/class_navigationagent3d.rst | 40 ++ classes/class_navigationmesh.rst | 2 +- classes/class_navigationobstacle2d.rst | 2 + classes/class_navigationobstacle3d.rst | 2 + .../class_navigationpathqueryparameters2d.rst | 40 ++ .../class_navigationpathqueryparameters3d.rst | 40 ++ classes/class_navigationpathqueryresult2d.rst | 6 + classes/class_navigationpathqueryresult3d.rst | 6 + classes/class_navigationpolygon.rst | 4 +- classes/class_navigationserver2d.rst | 20 +- classes/class_navigationserver3d.rst | 20 +- classes/class_node.rst | 24 +- classes/class_nodepath.rst | 2 +- classes/class_object.rst | 4 +- classes/class_occluderpolygon2d.rst | 2 +- classes/class_oggpacketsequence.rst | 2 + classes/class_openxraction.rst | 2 + classes/class_openxrcompositionlayer.rst | 22 +- .../class_openxrextensionwrapperextension.rst | 180 ++++-- classes/class_openxrinterface.rst | 14 + classes/class_openxripbinding.rst | 2 + classes/class_os.rst | 2 +- classes/class_packedbytearray.rst | 2 + classes/class_packedcolorarray.rst | 4 + classes/class_packedfloat32array.rst | 2 + classes/class_packedfloat64array.rst | 4 + classes/class_packedint32array.rst | 2 + classes/class_packedint64array.rst | 4 + classes/class_packedscene.rst | 2 +- classes/class_packedstringarray.rst | 6 +- classes/class_packedvector2array.rst | 6 +- classes/class_packedvector3array.rst | 4 + classes/class_panel.rst | 6 +- classes/class_panelcontainer.rst | 2 +- classes/class_physicalbone3d.rst | 6 +- classes/class_physicsdirectbodystate2d.rst | 2 +- ...lass_physicsdirectbodystate2dextension.rst | 176 ++---- classes/class_physicsdirectbodystate3d.rst | 2 +- classes/class_physicsserver2d.rst | 18 +- classes/class_physicsserver2dextension.rst | 560 +++++------------- classes/class_physicsserver3d.rst | 20 +- classes/class_polygon2d.rst | 6 +- classes/class_polygonoccluder3d.rst | 2 + classes/class_projectsettings.rst | 48 +- classes/class_quadmesh.rst | 4 +- classes/class_quaternion.rst | 2 +- classes/class_raycast2d.rst | 21 + classes/class_raycast3d.rst | 23 +- classes/class_rdframebufferpass.rst | 8 + classes/class_rdshaderspirv.rst | 10 + classes/class_rectangleshape2d.rst | 4 +- classes/class_regexmatch.rst | 2 + classes/class_renderingdevice.rst | 26 +- classes/class_renderingserver.rst | 4 +- .../class_resourceimportercsvtranslation.rst | 2 +- classes/class_resourceimporterimagefont.rst | 4 + classes/class_resourceloader.rst | 4 +- classes/class_richtextlabel.rst | 4 +- classes/class_rigidbody2d.rst | 10 +- classes/class_rigidbody3d.rst | 10 +- classes/class_shapecast2d.rst | 2 + classes/class_shapecast3d.rst | 2 + classes/class_skeleton3d.rst | 4 +- classes/class_skeletonik3d.rst | 7 - classes/class_skeletonprofilehumanoid.rst | 2 +- classes/class_skinreference.rst | 25 +- classes/class_sliderjoint3d.rst | 52 +- classes/class_softbody3d.rst | 2 + classes/class_sphereshape3d.rst | 2 +- classes/class_spotlight3d.rst | 2 +- classes/class_sprite2d.rst | 2 +- classes/class_staticbody3d.rst | 6 +- classes/class_streampeerbuffer.rst | 2 + classes/class_string.rst | 9 + classes/class_styleboxflat.rst | 4 +- classes/class_subviewport.rst | 12 +- classes/class_surfacetool.rst | 2 +- classes/class_systemfont.rst | 2 + classes/class_texturebutton.rst | 2 +- classes/class_texturerect.rst | 2 +- classes/class_thread.rst | 2 +- classes/class_tilemap.rst | 12 +- classes/class_tilemaplayer.rst | 46 +- classes/class_tileset.rst | 12 +- classes/class_timer.rst | 2 +- classes/class_transform2d.rst | 4 +- classes/class_transform3d.rst | 6 +- classes/class_undoredo.rst | 12 +- classes/class_upnpdevice.rst | 4 + classes/class_vboxcontainer.rst | 2 +- classes/class_vector2.rst | 16 +- classes/class_vector3.rst | 16 +- classes/class_vehiclebody3d.rst | 2 +- classes/class_vehiclewheel3d.rst | 2 +- classes/class_viewport.rst | 174 ++---- classes/class_viewporttexture.rst | 18 +- classes/class_visibleonscreennotifier2d.rst | 2 +- classes/class_visualshadernodeframe.rst | 2 + classes/class_voxelgi.rst | 2 +- classes/class_voxelgidata.rst | 2 +- classes/class_websocketmultiplayerpeer.rst | 4 + classes/class_websocketpeer.rst | 4 + classes/class_window.rst | 2 + classes/class_worldenvironment.rst | 6 +- classes/class_xrfacetracker.rst | 2 + 208 files changed, 1532 insertions(+), 1218 deletions(-) diff --git a/classes/class_@gdscript.rst b/classes/class_@gdscript.rst index 6d91468fe..efd80ae5f 100644 --- a/classes/class_@gdscript.rst +++ b/classes/class_@gdscript.rst @@ -1070,7 +1070,7 @@ Returns a :ref:`Resource` from the filesystem located at the abs # Load a scene called "main" located in the root of the project directory and cache it in a variable. var main = load("res://main.tscn") # main will contain a PackedScene resource. -\ **Important:** The path must be absolute. A relative path will always return ``null``. +\ **Important:** Relative paths are *not* relative to the script calling this method, instead it is prefixed with ``"res://"``. Loading from relative paths might not work as expected. This function is a simplified version of :ref:`ResourceLoader.load`, which can be used for more advanced scenarios. diff --git a/classes/class_@globalscope.rst b/classes/class_@globalscope.rst index 282efd7fd..8fa65f006 100644 --- a/classes/class_@globalscope.rst +++ b/classes/class_@globalscope.rst @@ -5715,7 +5715,7 @@ Converts an angle expressed in degrees to radians. Returns an "eased" value of ``x`` based on an easing function defined with ``curve``. This easing function is based on an exponent. The ``curve`` can be any floating-point number, with specific values leading to the following behaviors: -:: +.. code:: text - Lower than -1.0 (exclusive): Ease in-out - 1.0: Linear @@ -5856,9 +5856,9 @@ Returns the floating-point modulus of ``x`` divided by ``y``, wrapping equally i var x = i * 0.5 - 1.5 print("%4.1f %4.1f | %4.1f" % [x, fmod(x, 1.5), fposmod(x, 1.5)]) -Produces: +Prints: -:: +.. code:: text (x) (fmod(x, 1.5)) (fposmod(x, 1.5)) -1.5 -0.0 | 0.0 @@ -6374,9 +6374,9 @@ Returns the integer modulus of ``x`` divided by ``y`` that wraps equally in posi for i in range(-3, 4): print("%2d %2d | %2d" % [i, i % 3, posmod(i, 3)]) -Produces: +Prints: -:: +.. code:: text (i) (i % 3) (posmod(i, 3)) -3 0 | 0 @@ -6523,6 +6523,8 @@ Prints one or more arguments to strings in the best way possible to standard err Prints one or more arguments to strings in the best way possible to the OS terminal. Unlike :ref:`print`, no newline is automatically added at the end. +\ **Note:** The OS terminal is *not* the same as the editor's Output dock. The output sent to the OS terminal can be seen when running Godot from a terminal. On Windows, this requires using the ``console.exe`` executable. + .. tabs:: @@ -7396,7 +7398,7 @@ Converts a :ref:`Variant` ``variable`` to a formatted :ref:`Strin Prints: -:: +.. code:: text { "a": 1, diff --git a/classes/class_animatablebody3d.rst b/classes/class_animatablebody3d.rst index de772ac61..a49d1d641 100644 --- a/classes/class_animatablebody3d.rst +++ b/classes/class_animatablebody3d.rst @@ -28,11 +28,11 @@ When **AnimatableBody3D** is moved, its linear and angular velocity are estimate Tutorials --------- -- `3D Physics Tests Demo `__ +- `3D Physics Tests Demo `__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_animatedsprite2d.rst b/classes/class_animatedsprite2d.rst index fa2086b23..ddaf8317f 100644 --- a/classes/class_animatedsprite2d.rst +++ b/classes/class_animatedsprite2d.rst @@ -28,7 +28,7 @@ Tutorials - :doc:`2D Sprite animation <../tutorials/2d/2d_sprite_animation>` -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_animationnodeadd3.rst b/classes/class_animationnodeadd3.rst index 313bd9123..f77b8f847 100644 --- a/classes/class_animationnodeadd3.rst +++ b/classes/class_animationnodeadd3.rst @@ -38,7 +38,7 @@ Tutorials - :doc:`Using AnimationTree <../tutorials/animation/animation_tree>` -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_animationnodeanimation.rst b/classes/class_animationnodeanimation.rst index cd4cd3431..56d188d0c 100644 --- a/classes/class_animationnodeanimation.rst +++ b/classes/class_animationnodeanimation.rst @@ -28,9 +28,9 @@ Tutorials - :doc:`Using AnimationTree <../tutorials/animation/animation_tree>` -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_animationnodeblend2.rst b/classes/class_animationnodeblend2.rst index ca333217c..53a14c547 100644 --- a/classes/class_animationnodeblend2.rst +++ b/classes/class_animationnodeblend2.rst @@ -30,9 +30,9 @@ Tutorials - :doc:`Using AnimationTree <../tutorials/animation/animation_tree>` -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_animationnodeblendspace2d.rst b/classes/class_animationnodeblendspace2d.rst index 285ec2354..96bcb0e2b 100644 --- a/classes/class_animationnodeblendspace2d.rst +++ b/classes/class_animationnodeblendspace2d.rst @@ -32,7 +32,7 @@ Tutorials - :doc:`Using AnimationTree <../tutorials/animation/animation_tree>` -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_animationnodeoneshot.rst b/classes/class_animationnodeoneshot.rst index 26f194036..2e83fc832 100644 --- a/classes/class_animationnodeoneshot.rst +++ b/classes/class_animationnodeoneshot.rst @@ -79,7 +79,7 @@ Tutorials - :doc:`Using AnimationTree <../tutorials/animation/animation_tree>` -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_animationnodeoutput.rst b/classes/class_animationnodeoutput.rst index 2965cafaf..17f6be4d6 100644 --- a/classes/class_animationnodeoutput.rst +++ b/classes/class_animationnodeoutput.rst @@ -28,9 +28,9 @@ Tutorials - :doc:`Using AnimationTree <../tutorials/animation/animation_tree>` -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_animationnodetimescale.rst b/classes/class_animationnodetimescale.rst index 2f31c725c..7d19d1419 100644 --- a/classes/class_animationnodetimescale.rst +++ b/classes/class_animationnodetimescale.rst @@ -28,7 +28,7 @@ Tutorials - :doc:`Using AnimationTree <../tutorials/animation/animation_tree>` -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_animationnodetransition.rst b/classes/class_animationnodetransition.rst index a8a1d5233..dbb40e868 100644 --- a/classes/class_animationnodetransition.rst +++ b/classes/class_animationnodetransition.rst @@ -65,9 +65,9 @@ Tutorials - :doc:`Using AnimationTree <../tutorials/animation/animation_tree>` -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_animationplayer.rst b/classes/class_animationplayer.rst index 5a1ce0783..51ae0cfc7 100644 --- a/classes/class_animationplayer.rst +++ b/classes/class_animationplayer.rst @@ -36,7 +36,7 @@ Tutorials - :doc:`Animation documentation index <../tutorials/animation/index>` -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_animationtree.rst b/classes/class_animationtree.rst index 63cbe82ca..7091d5ecc 100644 --- a/classes/class_animationtree.rst +++ b/classes/class_animationtree.rst @@ -30,7 +30,7 @@ Tutorials - :doc:`Using AnimationTree <../tutorials/animation/animation_tree>` -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_area2d.rst b/classes/class_area2d.rst index d33554bad..dc4b6f66c 100644 --- a/classes/class_area2d.rst +++ b/classes/class_area2d.rst @@ -35,11 +35,11 @@ Tutorials - :doc:`Using Area2D <../tutorials/physics/using_area_2d>` -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ -- `2D Pong Demo `__ +- `2D Pong Demo `__ -- `2D Platformer Demo `__ +- `2D Platformer Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_area3d.rst b/classes/class_area3d.rst index fdce53bdc..5b35f3e7b 100644 --- a/classes/class_area3d.rst +++ b/classes/class_area3d.rst @@ -37,9 +37,9 @@ Tutorials - :doc:`Using Area2D <../tutorials/physics/using_area_2d>` -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `GUI in 3D Demo `__ +- `GUI in 3D Viewport Demo `__ .. rst-class:: classref-reftable-group @@ -662,6 +662,8 @@ The degree to which this area's reverb is a uniform effect. Ranges from ``0`` to The exponential rate at which wind force decreases with distance from its origin. +\ **Note:** This wind force only applies to :ref:`SoftBody3D` nodes. Other physics bodies are currently not affected by wind. + .. rst-class:: classref-item-separator ---- @@ -679,6 +681,8 @@ The exponential rate at which wind force decreases with distance from its origin The magnitude of area-specific wind force. +\ **Note:** This wind force only applies to :ref:`SoftBody3D` nodes. Other physics bodies are currently not affected by wind. + .. rst-class:: classref-item-separator ---- @@ -696,6 +700,8 @@ The magnitude of area-specific wind force. The :ref:`Node3D` which is used to specify the direction and origin of an area-specific wind force. The direction is opposite to the z-axis of the :ref:`Node3D`'s local transform, and its origin is the origin of the :ref:`Node3D`'s local transform. +\ **Note:** This wind force only applies to :ref:`SoftBody3D` nodes. Other physics bodies are currently not affected by wind. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_array.rst b/classes/class_array.rst index d907755b9..47a156670 100644 --- a/classes/class_array.rst +++ b/classes/class_array.rst @@ -68,6 +68,8 @@ Arrays can be concatenated using the ``+`` operator: \ **Note:** Erasing elements while iterating over arrays is **not** supported and will result in unpredictable behavior. +\ **Differences between packed arrays, typed arrays, and untyped arrays:** Packed arrays are generally faster to iterate on and modify compared to a typed array of the same type (e.g. :ref:`PackedInt64Array` versus ``Array[int]``). Also, packed arrays consume less memory. As a downside, packed arrays are less flexible as they don't offer as many convenience methods such as :ref:`map`. Typed arrays are in turn faster to iterate on and modify than untyped arrays. + .. note:: There are notable differences when using this API with C#. See :ref:`doc_c_sharp_differences` for more information. @@ -259,7 +261,37 @@ Constructs an empty **Array**. :ref:`Array` **Array**\ (\ base\: :ref:`Array`, type\: :ref:`int`, class_name\: :ref:`StringName`, script\: :ref:`Variant`\ ) -Creates a typed array from the ``base`` array. +Creates a typed array from the ``base`` array. All arguments are required. + +- ``type`` is the built-in type as a :ref:`Variant.Type` constant, for example :ref:`@GlobalScope.TYPE_INT`. + +- ``class_name`` is the **native** class name, for example :ref:`Node`. If ``type`` is not :ref:`@GlobalScope.TYPE_OBJECT`, must be an empty string. + +- ``script`` is the associated script. Must be a :ref:`Script` instance or ``null``. + +Examples: + +:: + + class_name MyNode + extends Node + + class MyClass: + pass + + func _ready(): + var a = Array([], TYPE_INT, &"", null) # Array[int] + var b = Array([], TYPE_OBJECT, &"Node", null) # Array[Node] + var c = Array([], TYPE_OBJECT, &"Node", MyNode) # Array[MyNode] + var d = Array([], TYPE_OBJECT, &"RefCounted", MyClass) # Array[MyClass] + +\ **Note:** This constructor can be useful if you want to create a typed array on the fly, but you are not required to use it. In GDScript you can use a temporary variable with the static type you need and then pass it: + +:: + + func _ready(): + var a: Array[int] = [] + some_func(a) .. rst-class:: classref-item-separator @@ -673,7 +705,7 @@ Returns the first element of the array. Prints an error and returns ``null`` if :ref:`int` **get_typed_builtin**\ (\ ) |const| -Returns the :ref:`Variant.Type` constant for a typed array. If the **Array** is not typed, returns :ref:`@GlobalScope.TYPE_NIL`. +Returns the built-in type of the typed array as a :ref:`Variant.Type` constant. If the array is not typed, returns :ref:`@GlobalScope.TYPE_NIL`. .. rst-class:: classref-item-separator @@ -685,7 +717,7 @@ Returns the :ref:`Variant.Type` constant for a t :ref:`StringName` **get_typed_class_name**\ (\ ) |const| -Returns a class name of a typed **Array** of type :ref:`@GlobalScope.TYPE_OBJECT`. +Returns the **native** class name of the typed array if the built-in type is :ref:`@GlobalScope.TYPE_OBJECT`. Otherwise, this method returns an empty string. .. rst-class:: classref-item-separator @@ -697,7 +729,7 @@ Returns a class name of a typed **Array** of type :ref:`@GlobalScope.TYPE_OBJECT :ref:`Variant` **get_typed_script**\ (\ ) |const| -Returns the script associated with a typed array tied to a class name. +Returns the script associated with the typed array. This method returns a :ref:`Script` instance or ``null``. .. rst-class:: classref-item-separator diff --git a/classes/class_arrayoccluder3d.rst b/classes/class_arrayoccluder3d.rst index c9c3c4cf6..a31fc6ba8 100644 --- a/classes/class_arrayoccluder3d.rst +++ b/classes/class_arrayoccluder3d.rst @@ -80,6 +80,8 @@ The occluder's index position. Indices determine which points from the :ref:`ver \ **Note:** The occluder is always updated after setting this value. If creating occluders procedurally, consider using :ref:`set_arrays` instead to avoid updating the occluder twice when it's created. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt32Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -99,6 +101,8 @@ The occluder's vertex positions in local 3D coordinates. \ **Note:** The occluder is always updated after setting this value. If creating occluders procedurally, consider using :ref:`set_arrays` instead to avoid updating the occluder twice when it's created. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector3Array` for more details. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_audioeffect.rst b/classes/class_audioeffect.rst index c0a0ec704..95ce3b496 100644 --- a/classes/class_audioeffect.rst +++ b/classes/class_audioeffect.rst @@ -32,7 +32,7 @@ Tutorials - :doc:`Audio buses <../tutorials/audio/audio_buses>` -- `Audio Mic Record Demo `__ +- `Audio Microphone Record Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_audioeffectrecord.rst b/classes/class_audioeffectrecord.rst index c344f946e..0dc140b54 100644 --- a/classes/class_audioeffectrecord.rst +++ b/classes/class_audioeffectrecord.rst @@ -34,7 +34,7 @@ Tutorials - :doc:`Recording with microphone <../tutorials/audio/recording_with_microphone>` -- `Audio Mic Record Demo `__ +- `Audio Microphone Record Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_audioeffectreverb.rst b/classes/class_audioeffectreverb.rst index a143ad17c..01bf4a045 100644 --- a/classes/class_audioeffectreverb.rst +++ b/classes/class_audioeffectreverb.rst @@ -28,7 +28,7 @@ Tutorials - :doc:`Audio buses <../tutorials/audio/audio_buses>` -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_audioeffectspectrumanalyzer.rst b/classes/class_audioeffectspectrumanalyzer.rst index 8db1a9f7f..35df039c0 100644 --- a/classes/class_audioeffectspectrumanalyzer.rst +++ b/classes/class_audioeffectspectrumanalyzer.rst @@ -28,7 +28,7 @@ See also :ref:`AudioStreamGenerator` for procedurall Tutorials --------- -- `Audio Spectrum Demo `__ +- `Audio Spectrum Visualizer Demo `__ - `Godot 3.2 will get new audio features `__ diff --git a/classes/class_audioserver.rst b/classes/class_audioserver.rst index 7d9405142..4122ffd93 100644 --- a/classes/class_audioserver.rst +++ b/classes/class_audioserver.rst @@ -28,11 +28,11 @@ Tutorials - :doc:`Audio buses <../tutorials/audio/audio_buses>` -- `Audio Device Changer Demo `__ +- `Audio Device Changer Demo `__ -- `Audio Mic Record Demo `__ +- `Audio Microphone Record Demo `__ -- `Audio Spectrum Demo `__ +- `Audio Spectrum Visualizer Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_audiostream.rst b/classes/class_audiostream.rst index 3a3bf0495..04a0bd068 100644 --- a/classes/class_audiostream.rst +++ b/classes/class_audiostream.rst @@ -30,11 +30,11 @@ Tutorials - :doc:`Audio streams <../tutorials/audio/audio_streams>` -- `Audio Generator Demo `__ +- `Audio Generator Demo `__ -- `Audio Mic Record Demo `__ +- `Audio Microphone Record Demo `__ -- `Audio Spectrum Demo `__ +- `Audio Spectrum Visualizer Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_audiostreamgenerator.rst b/classes/class_audiostreamgenerator.rst index 813a97640..d33e1da62 100644 --- a/classes/class_audiostreamgenerator.rst +++ b/classes/class_audiostreamgenerator.rst @@ -91,7 +91,7 @@ See also :ref:`AudioEffectSpectrumAnalyzer` f Tutorials --------- -- `Audio Generator Demo `__ +- `Audio Generator Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_audiostreamgeneratorplayback.rst b/classes/class_audiostreamgeneratorplayback.rst index 809e157ce..d75d9089c 100644 --- a/classes/class_audiostreamgeneratorplayback.rst +++ b/classes/class_audiostreamgeneratorplayback.rst @@ -26,7 +26,7 @@ This class is meant to be used with :ref:`AudioStreamGenerator`__ +- `Audio Generator Demo `__ - `Godot 3.2 will get new audio features `__ diff --git a/classes/class_audiostreammp3.rst b/classes/class_audiostreammp3.rst index ee031252d..15c8caabb 100644 --- a/classes/class_audiostreammp3.rst +++ b/classes/class_audiostreammp3.rst @@ -147,6 +147,8 @@ You can load a file without having to import it beforehand using the code snippe +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedByteArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_audiostreamplayback.rst b/classes/class_audiostreamplayback.rst index 95e9be4a9..eaa3e1cfe 100644 --- a/classes/class_audiostreamplayback.rst +++ b/classes/class_audiostreamplayback.rst @@ -28,7 +28,7 @@ Can play, loop, pause a scroll through audio. See :ref:`AudioStream`__ +- `Audio Generator Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_audiostreamplayer.rst b/classes/class_audiostreamplayer.rst index f6c43302e..856dc0137 100644 --- a/classes/class_audiostreamplayer.rst +++ b/classes/class_audiostreamplayer.rst @@ -15,16 +15,18 @@ AudioStreamPlayer **Inherits:** :ref:`Node` **<** :ref:`Object` -Plays back audio non-positionally. +A node for audio playback. .. rst-class:: classref-introduction-group Description ----------- -Plays an audio stream non-positionally. +The **AudioStreamPlayer** node plays an audio stream non-positionally. It is ideal for user interfaces, menus, or background music. -To play audio positionally, use :ref:`AudioStreamPlayer2D` or :ref:`AudioStreamPlayer3D` instead of **AudioStreamPlayer**. +To use this node, :ref:`stream` needs to be set to a valid :ref:`AudioStream` resource. Playing more than one sound at the time is also supported, see :ref:`max_polyphony`. + +If you need to play audio at a specific position, use :ref:`AudioStreamPlayer2D` or :ref:`AudioStreamPlayer3D` instead. .. rst-class:: classref-introduction-group @@ -33,15 +35,15 @@ Tutorials - :doc:`Audio streams <../tutorials/audio/audio_streams>` -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ -- `Audio Device Changer Demo `__ +- `Audio Device Changer Demo `__ -- `Audio Generator Demo `__ +- `Audio Generator Demo `__ -- `Audio Mic Record Demo `__ +- `Audio Microphone Record Demo `__ -- `Audio Spectrum Demo `__ +- `Audio Spectrum Visualizer Demo `__ .. rst-class:: classref-reftable-group @@ -108,7 +110,7 @@ Signals **finished**\ (\ ) -Emitted when the audio stops playing. +Emitted when a sound finishes playing without interruptions. This signal is *not* emitted when calling :ref:`stop`, or when exiting the tree while sounds are playing. .. rst-class:: classref-section-separator @@ -131,7 +133,7 @@ enum **MixTarget**: :ref:`MixTarget` **MIX_TARGET_STEREO** = ``0`` -The audio will be played only on the first channel. +The audio will be played only on the first channel. This is the default. .. _class_AudioStreamPlayer_constant_MIX_TARGET_SURROUND: @@ -169,7 +171,7 @@ Property Descriptions - |void| **set_autoplay**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **is_autoplay_enabled**\ (\ ) -If ``true``, audio plays when added to scene tree. +If ``true``, this node calls :ref:`play` when entering the tree. .. rst-class:: classref-item-separator @@ -186,9 +188,9 @@ If ``true``, audio plays when added to scene tree. - |void| **set_bus**\ (\ value\: :ref:`StringName`\ ) - :ref:`StringName` **get_bus**\ (\ ) -Bus on which this audio is playing. +The target bus name. All sounds from this node will be playing on this bus. -\ **Note:** When setting this property, keep in mind that no validation is performed to see if the given name matches an existing bus. This is because audio bus layouts might be loaded after this property is set. If this given name can't be resolved at runtime, it will fall back to ``"Master"``. +\ **Note:** At runtime, if no bus with the given name exists, all sounds will fall back on ``"Master"``. See also :ref:`AudioServer.get_bus_name`. .. rst-class:: classref-item-separator @@ -205,7 +207,7 @@ Bus on which this audio is playing. - |void| **set_max_polyphony**\ (\ value\: :ref:`int`\ ) - :ref:`int` **get_max_polyphony**\ (\ ) -The maximum number of sounds this node can play at the same time. Playing additional sounds after this value is reached will cut off the oldest sounds. +The maximum number of sounds this node can play at the same time. Calling :ref:`play` after this value is reached will cut off the oldest sounds. .. rst-class:: classref-item-separator @@ -222,7 +224,7 @@ The maximum number of sounds this node can play at the same time. Playing additi - |void| **set_mix_target**\ (\ value\: :ref:`MixTarget`\ ) - :ref:`MixTarget` **get_mix_target**\ (\ ) -If the audio configuration has more than two speakers, this sets the target channels. See :ref:`MixTarget` constants. +The mix target channels, as one of the :ref:`MixTarget` constants. Has no effect when two speakers or less are detected (see :ref:`SpeakerMode`). .. rst-class:: classref-item-separator @@ -239,7 +241,7 @@ If the audio configuration has more than two speakers, this sets the target chan - |void| **set_pitch_scale**\ (\ value\: :ref:`float`\ ) - :ref:`float` **get_pitch_scale**\ (\ ) -The pitch and the tempo of the audio, as a multiplier of the audio sample's sample rate. +The audio's pitch and tempo, as a multiplier of the :ref:`stream`'s sample rate. A value of ``2.0`` doubles the audio's pitch, while a value of ``0.5`` halves the pitch. .. rst-class:: classref-item-separator @@ -255,7 +257,7 @@ The pitch and the tempo of the audio, as a multiplier of the audio sample's samp - :ref:`bool` **is_playing**\ (\ ) -If ``true``, audio is playing. +If ``true``, this node is playing sounds. Setting this property has the same effect as :ref:`play` and :ref:`stop`. .. rst-class:: classref-item-separator @@ -272,7 +274,7 @@ If ``true``, audio is playing. - |void| **set_stream**\ (\ value\: :ref:`AudioStream`\ ) - :ref:`AudioStream` **get_stream**\ (\ ) -The :ref:`AudioStream` object to be played. +The :ref:`AudioStream` resource to be played. Setting this property stops all currently playing sounds. If left empty, the **AudioStreamPlayer** does not work. .. rst-class:: classref-item-separator @@ -289,7 +291,9 @@ The :ref:`AudioStream` object to be played. - |void| **set_stream_paused**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **get_stream_paused**\ (\ ) -If ``true``, the playback is paused. You can resume it by setting :ref:`stream_paused` to ``false``. +If ``true``, the sounds are paused. Setting :ref:`stream_paused` to ``false`` resumes all sounds. + +\ **Note:** This property is automatically changed when exiting or entering the tree, or this node is paused (see :ref:`Node.process_mode`). .. rst-class:: classref-item-separator @@ -306,7 +310,9 @@ If ``true``, the playback is paused. You can resume it by setting :ref:`stream_p - |void| **set_volume_db**\ (\ value\: :ref:`float`\ ) - :ref:`float` **get_volume_db**\ (\ ) -Volume of sound, in dB. +Volume of sound, in decibel. This is an offset of the :ref:`stream`'s volume. + +\ **Note:** To convert between decibel and linear energy (like most volume sliders do), use :ref:`@GlobalScope.db_to_linear` and :ref:`@GlobalScope.linear_to_db`. .. rst-class:: classref-section-separator @@ -323,7 +329,9 @@ Method Descriptions :ref:`float` **get_playback_position**\ (\ ) -Returns the position in the :ref:`AudioStream` in seconds. +Returns the position in the :ref:`AudioStream` of the latest sound, in seconds. Returns ``0.0`` if no sounds are playing. + +\ **Note:** The position is not always accurate, as the :ref:`AudioServer` does not mix audio every processed frame. To get more accurate results, add :ref:`AudioServer.get_time_since_last_mix` to the returned position. .. rst-class:: classref-item-separator @@ -335,7 +343,7 @@ Returns the position in the :ref:`AudioStream` in seconds. :ref:`AudioStreamPlayback` **get_stream_playback**\ (\ ) -Returns the :ref:`AudioStreamPlayback` object associated with this **AudioStreamPlayer**. +Returns the latest :ref:`AudioStreamPlayback` of this node, usually the most recently created by :ref:`play`. If no sounds are playing, this method fails and returns an empty playback. .. rst-class:: classref-item-separator @@ -347,7 +355,7 @@ Returns the :ref:`AudioStreamPlayback` object associa :ref:`bool` **has_stream_playback**\ (\ ) -Returns whether the **AudioStreamPlayer** can return the :ref:`AudioStreamPlayback` object or not. +Returns ``true`` if any sound is active, even if :ref:`stream_paused` is set to ``true``. See also :ref:`playing` and :ref:`get_stream_playback`. .. rst-class:: classref-item-separator @@ -359,7 +367,7 @@ Returns whether the **AudioStreamPlayer** can return the :ref:`AudioStreamPlayba |void| **play**\ (\ from_position\: :ref:`float` = 0.0\ ) -Plays the audio from the given ``from_position``, in seconds. +Plays a sound from the beginning, or the given ``from_position`` in seconds. .. rst-class:: classref-item-separator @@ -371,7 +379,7 @@ Plays the audio from the given ``from_position``, in seconds. |void| **seek**\ (\ to_position\: :ref:`float`\ ) -Sets the position from which audio will be played, in seconds. +Restarts all sounds to be played from the given ``to_position``, in seconds. Does nothing if no sounds are playing. .. rst-class:: classref-item-separator @@ -383,7 +391,7 @@ Sets the position from which audio will be played, in seconds. |void| **stop**\ (\ ) -Stops the audio. +Stops all sounds from this node. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_audiostreamwav.rst b/classes/class_audiostreamwav.rst index cc90f5658..a17aaa9cc 100644 --- a/classes/class_audiostreamwav.rst +++ b/classes/class_audiostreamwav.rst @@ -171,6 +171,8 @@ Contains the audio data in bytes. \ **Note:** This property expects signed PCM8 data. To convert unsigned PCM8 to signed PCM8, subtract 128 from each byte. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedByteArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_basis.rst b/classes/class_basis.rst index dbec1dabe..623e5ed43 100644 --- a/classes/class_basis.rst +++ b/classes/class_basis.rst @@ -44,13 +44,13 @@ Tutorials - :doc:`Using 3D transforms <../tutorials/3d/using_transforms>` -- `Matrix Transform Demo `__ +- `Matrix Transform Demo `__ -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ -- `2.5D Demo `__ +- `2.5D Game Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_boxshape3d.rst b/classes/class_boxshape3d.rst index 00aecb2cb..7a2d8e954 100644 --- a/classes/class_boxshape3d.rst +++ b/classes/class_boxshape3d.rst @@ -28,11 +28,11 @@ A 3D box shape, intended for use in physics. Usually used to provide a shape for Tutorials --------- -- `3D Physics Tests Demo `__ +- `3D Physics Tests Demo `__ -- `3D Kinematic Character Demo `__ +- `3D Kinematic Character Demo `__ -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_button.rst b/classes/class_button.rst index 64d21a7e2..ea2d846fb 100644 --- a/classes/class_button.rst +++ b/classes/class_button.rst @@ -65,9 +65,9 @@ See also :ref:`BaseButton` which contains common properties an Tutorials --------- -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ -- `OS Test Demo `__ +- `Operating System Testing Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_camera2d.rst b/classes/class_camera2d.rst index 9b02b0534..810348fa9 100644 --- a/classes/class_camera2d.rst +++ b/classes/class_camera2d.rst @@ -32,11 +32,9 @@ Note that the **Camera2D** node's ``position`` doesn't represent the actual posi Tutorials --------- -- `2D Platformer Demo `__ +- `2D Platformer Demo `__ -- `2D Isometric Demo `__ - -- `2D HDR Demo `__ +- `2D Isometric Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_camera3d.rst b/classes/class_camera3d.rst index 9020c3832..dfdde08de 100644 --- a/classes/class_camera3d.rst +++ b/classes/class_camera3d.rst @@ -28,7 +28,7 @@ Description Tutorials --------- -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_cameraserver.rst b/classes/class_cameraserver.rst index dca7797ed..65719ba19 100644 --- a/classes/class_cameraserver.rst +++ b/classes/class_cameraserver.rst @@ -23,7 +23,7 @@ The **CameraServer** keeps track of different cameras accessible in Godot. These It is notably used to provide AR modules with a video feed from the camera. -\ **Note:** This class is currently only implemented on macOS and iOS. On other platforms, no :ref:`CameraFeed`\ s will be available. +\ **Note:** This class is currently only implemented on macOS and iOS. To get a :ref:`CameraFeed` on iOS, the camera plugin from `godot-ios-plugins `__ is required. On other platforms, no :ref:`CameraFeed`\ s will be available. .. rst-class:: classref-reftable-group diff --git a/classes/class_canvasitem.rst b/classes/class_canvasitem.rst index 4b740494b..519ae420a 100644 --- a/classes/class_canvasitem.rst +++ b/classes/class_canvasitem.rst @@ -38,7 +38,7 @@ Tutorials - :doc:`Custom drawing in 2D <../tutorials/2d/custom_drawing_in_2d>` -- `Audio Spectrum Demo `__ +- `Audio Spectrum Visualizer Demo `__ .. rst-class:: classref-reftable-group @@ -733,9 +733,11 @@ If ``true``, this **CanvasItem** is drawn. The node is only visible if all of it - |void| **set_y_sort_enabled**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **is_y_sort_enabled**\ (\ ) -If ``true``, this **CanvasItem** and its **CanvasItem** child nodes are sorted according to the Y position. Nodes with a lower Y position are drawn before those with a higher Y position. If ``false``, Y-sorting is disabled. +If ``true``, this and child **CanvasItem** nodes with a lower Y position are rendered in front of nodes with a higher Y position. If ``false``, this and child **CanvasItem** nodes are rendered normally in scene tree order. -You can nest nodes with Y-sorting. Child Y-sorted nodes are sorted in the same space as the parent Y-sort. This feature allows you to organize a scene better or divide it into multiple ones without changing your scene tree. +With Y-sorting enabled on a parent node ('A') but disabled on a child node ('B'), the child node ('B') is sorted but its children ('C1', 'C2', etc) render together on the same Y position as the child node 'B'. This allows you to organize the render order of a scene without changing the scene tree. + +Nodes sort relative to each other only if they are on the same :ref:`z_index`. .. rst-class:: classref-item-separator @@ -769,7 +771,7 @@ If ``true``, the node's Z index is relative to its parent's Z index. If this nod - |void| **set_z_index**\ (\ value\: :ref:`int`\ ) - :ref:`int` **get_z_index**\ (\ ) -Z index. Controls the order in which the nodes render. A node with a higher Z index will display in front of others. Must be between :ref:`RenderingServer.CANVAS_ITEM_Z_MIN` and :ref:`RenderingServer.CANVAS_ITEM_Z_MAX` (inclusive). +Controls the order in which the nodes render. A node with a higher Z index will display in front of others. Must be between :ref:`RenderingServer.CANVAS_ITEM_Z_MIN` and :ref:`RenderingServer.CANVAS_ITEM_Z_MAX` (inclusive). \ **Note:** Changing the Z index of a :ref:`Control` only affects the drawing order, not the order in which input events are handled. This can be useful to implement certain UI animations, e.g. a menu where hovered items are scaled and should overlap others. diff --git a/classes/class_canvaslayer.rst b/classes/class_canvaslayer.rst index 792e9d304..b98daac1c 100644 --- a/classes/class_canvaslayer.rst +++ b/classes/class_canvaslayer.rst @@ -38,7 +38,7 @@ Tutorials - :doc:`Canvas layers <../tutorials/2d/canvas_layers>` -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_capsuleshape3d.rst b/classes/class_capsuleshape3d.rst index 0bde8e5d1..9e69bcfc2 100644 --- a/classes/class_capsuleshape3d.rst +++ b/classes/class_capsuleshape3d.rst @@ -28,7 +28,7 @@ A 3D capsule shape, intended for use in physics. Usually used to provide a shape Tutorials --------- -- `3D Physics Tests Demo `__ +- `3D Physics Tests Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_characterbody2d.rst b/classes/class_characterbody2d.rst index b18d56195..d48aacf58 100644 --- a/classes/class_characterbody2d.rst +++ b/classes/class_characterbody2d.rst @@ -32,9 +32,9 @@ Tutorials - :doc:`Using CharacterBody2D <../tutorials/physics/using_character_body_2d>` -- `2D Kinematic Character Demo `__ +- `2D Kinematic Character Demo `__ -- `2D Platformer Demo `__ +- `2D Platformer Demo `__ .. rst-class:: classref-reftable-group @@ -498,7 +498,9 @@ Returns the floor's collision angle at the last collision point according to ``u :ref:`Vector2` **get_floor_normal**\ (\ ) |const| -Returns the surface normal of the floor at the last collision point. Only valid after calling :ref:`move_and_slide` and when :ref:`is_on_floor` returns ``true``. +Returns the collision normal of the floor at the last collision point. Only valid after calling :ref:`move_and_slide` and when :ref:`is_on_floor` returns ``true``. + +\ **Warning:** The collision normal is not always the same as the surface normal. .. rst-class:: classref-item-separator @@ -615,7 +617,9 @@ Returns the number of times the body collided and changed direction during the l :ref:`Vector2` **get_wall_normal**\ (\ ) |const| -Returns the surface normal of the wall at the last collision point. Only valid after calling :ref:`move_and_slide` and when :ref:`is_on_wall` returns ``true``. +Returns the collision normal of the wall at the last collision point. Only valid after calling :ref:`move_and_slide` and when :ref:`is_on_wall` returns ``true``. + +\ **Warning:** The collision normal is not always the same as the surface normal. .. rst-class:: classref-item-separator diff --git a/classes/class_characterbody3d.rst b/classes/class_characterbody3d.rst index d9e49bf05..67bc1081f 100644 --- a/classes/class_characterbody3d.rst +++ b/classes/class_characterbody3d.rst @@ -30,13 +30,13 @@ Tutorials - :doc:`Kinematic character (2D) <../tutorials/physics/kinematic_character_2d>` -- `3D Kinematic Character Demo `__ +- `3D Kinematic Character Demo `__ -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group @@ -502,7 +502,9 @@ Returns the floor's collision angle at the last collision point according to ``u :ref:`Vector3` **get_floor_normal**\ (\ ) |const| -Returns the surface normal of the floor at the last collision point. Only valid after calling :ref:`move_and_slide` and when :ref:`is_on_floor` returns ``true``. +Returns the collision normal of the floor at the last collision point. Only valid after calling :ref:`move_and_slide` and when :ref:`is_on_floor` returns ``true``. + +\ **Warning:** The collision normal is not always the same as the surface normal. .. rst-class:: classref-item-separator @@ -610,7 +612,9 @@ Returns the number of times the body collided and changed direction during the l :ref:`Vector3` **get_wall_normal**\ (\ ) |const| -Returns the surface normal of the wall at the last collision point. Only valid after calling :ref:`move_and_slide` and when :ref:`is_on_wall` returns ``true``. +Returns the collision normal of the wall at the last collision point. Only valid after calling :ref:`move_and_slide` and when :ref:`is_on_wall` returns ``true``. + +\ **Warning:** The collision normal is not always the same as the surface normal. .. rst-class:: classref-item-separator diff --git a/classes/class_collisionpolygon2d.rst b/classes/class_collisionpolygon2d.rst index fe0876dda..0275f887f 100644 --- a/classes/class_collisionpolygon2d.rst +++ b/classes/class_collisionpolygon2d.rst @@ -168,7 +168,7 @@ The polygon's list of vertices. Each point will be connected to the next, and th \ **Note:** The returned vertices are in the local coordinate space of the given **CollisionPolygon2D**. -\ **Warning:** The returned value is a clone of the :ref:`PackedVector2Array`, not a reference. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_collisionpolygon3d.rst b/classes/class_collisionpolygon3d.rst index eaba73a58..b5f6d8f3c 100644 --- a/classes/class_collisionpolygon3d.rst +++ b/classes/class_collisionpolygon3d.rst @@ -114,7 +114,7 @@ The collision margin for the generated :ref:`Shape3D`. See :ref:` Array of vertices which define the 2D polygon in the local XY plane. -\ **Note:** The returned value is a copy of the original. Methods which mutate the size or properties of the return value will not impact the original polygon. To change properties of the polygon, assign it to a temporary variable and make changes before reassigning the class property. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_collisionshape2d.rst b/classes/class_collisionshape2d.rst index 47db05510..7ccf4a7cf 100644 --- a/classes/class_collisionshape2d.rst +++ b/classes/class_collisionshape2d.rst @@ -28,11 +28,11 @@ Tutorials - :doc:`Physics introduction <../tutorials/physics/physics_introduction>` -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ -- `2D Pong Demo `__ +- `2D Pong Demo `__ -- `2D Kinematic Character Demo `__ +- `2D Kinematic Character Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_collisionshape3d.rst b/classes/class_collisionshape3d.rst index 8c199da95..16648dc09 100644 --- a/classes/class_collisionshape3d.rst +++ b/classes/class_collisionshape3d.rst @@ -30,11 +30,11 @@ Tutorials - :doc:`Physics introduction <../tutorials/physics/physics_introduction>` -- `3D Kinematic Character Demo `__ +- `3D Kinematic Character Demo `__ -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_color.rst b/classes/class_color.rst index 9398c1b77..91c401a1b 100644 --- a/classes/class_color.rst +++ b/classes/class_color.rst @@ -34,11 +34,11 @@ Colors can be created in various ways: By the various **Color** constructors, by Tutorials --------- -- `2D GD Paint Demo `__ +- `2D GD Paint Demo `__ -- `Tween Demo `__ +- `Tween Interpolation Demo `__ -- `GUI Drag And Drop Demo `__ +- `GUI Drag And Drop Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_colorpicker.rst b/classes/class_colorpicker.rst index d7212ec9e..9748af112 100644 --- a/classes/class_colorpicker.rst +++ b/classes/class_colorpicker.rst @@ -28,7 +28,7 @@ A widget that provides an interface for selecting or modifying a color. It can o Tutorials --------- -- `Tween Demo `__ +- `Tween Interpolation Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_colorpickerbutton.rst b/classes/class_colorpickerbutton.rst index 4d83b4323..73682f8cf 100644 --- a/classes/class_colorpickerbutton.rst +++ b/classes/class_colorpickerbutton.rst @@ -30,9 +30,9 @@ See also :ref:`BaseButton` which contains common properties an Tutorials --------- -- `GUI Drag And Drop Demo `__ +- `2D GD Paint Demo `__ -- `2D GD Paint Demo `__ +- `GUI Drag And Drop Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_colorrect.rst b/classes/class_colorrect.rst index b88adb12d..458a146a2 100644 --- a/classes/class_colorrect.rst +++ b/classes/class_colorrect.rst @@ -26,7 +26,7 @@ Displays a rectangle filled with a solid :ref:`color`__ +- `2D Dodge The Creeps Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_concavepolygonshape2d.rst b/classes/class_concavepolygonshape2d.rst index e97183b52..25ff0a483 100644 --- a/classes/class_concavepolygonshape2d.rst +++ b/classes/class_concavepolygonshape2d.rst @@ -63,6 +63,8 @@ Property Descriptions The array of points that make up the **ConcavePolygonShape2D**'s line segments. The array (of length divisible by two) is naturally divided into pairs (one pair for each segment); each pair consists of the starting point of a segment and the endpoint of a segment. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` diff --git a/classes/class_concavepolygonshape3d.rst b/classes/class_concavepolygonshape3d.rst index 898385d05..1a148478e 100644 --- a/classes/class_concavepolygonshape3d.rst +++ b/classes/class_concavepolygonshape3d.rst @@ -34,7 +34,7 @@ Being just a collection of interconnected triangles, **ConcavePolygonShape3D** i Tutorials --------- -- `3D Physics Tests Demo `__ +- `3D Physics Tests Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_configfile.rst b/classes/class_configfile.rst index 212f0415d..785e4c416 100644 --- a/classes/class_configfile.rst +++ b/classes/class_configfile.rst @@ -21,7 +21,7 @@ Description This helper class can be used to store :ref:`Variant` values on the filesystem using INI-style formatting. The stored values are identified by a section and a key: -:: +.. code:: text [section] some_key=42 diff --git a/classes/class_control.rst b/classes/class_control.rst index 7e9b611d9..c92fb6169 100644 --- a/classes/class_control.rst +++ b/classes/class_control.rst @@ -1319,7 +1319,7 @@ Enables whether rendering of :ref:`CanvasItem` based children - |void| **set_custom_minimum_size**\ (\ value\: :ref:`Vector2`\ ) - :ref:`Vector2` **get_custom_minimum_size**\ (\ ) -The minimum size of the node's bounding rectangle. If you set it to a value greater than (0, 0), the node's bounding rectangle will always have at least this size, even if its content is smaller. If it's set to (0, 0), the node sizes automatically to fit its content, be it a texture or child nodes. +The minimum size of the node's bounding rectangle. If you set it to a value greater than ``(0, 0)``, the node's bounding rectangle will always have at least this size. Note that **Control** nodes have their internal minimum size returned by :ref:`get_minimum_size`. It depends on the control's contents, like text, textures, or style boxes. The actual minimum size is the maximum value of this property and the internal minimum size (see :ref:`get_combined_minimum_size`). .. rst-class:: classref-item-separator diff --git a/classes/class_convexpolygonshape2d.rst b/classes/class_convexpolygonshape2d.rst index 9905ca6d3..54142e269 100644 --- a/classes/class_convexpolygonshape2d.rst +++ b/classes/class_convexpolygonshape2d.rst @@ -75,6 +75,8 @@ The polygon's list of vertices that form a convex hull. Can be in either clockwi \ **Warning:** Only set this property to a list of points that actually form a convex hull. Use :ref:`set_point_cloud` to generate the convex hull of an arbitrary set of points. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_convexpolygonshape3d.rst b/classes/class_convexpolygonshape3d.rst index a87628f3b..5bc1b5db0 100644 --- a/classes/class_convexpolygonshape3d.rst +++ b/classes/class_convexpolygonshape3d.rst @@ -32,7 +32,7 @@ A 3D convex polyhedron shape, intended for use in physics. Usually used to provi Tutorials --------- -- `3D Physics Tests Demo `__ +- `3D Physics Tests Demo `__ .. rst-class:: classref-reftable-group @@ -68,6 +68,8 @@ Property Descriptions The list of 3D points forming the convex polygon shape. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector3Array` for more details. + .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` diff --git a/classes/class_cpuparticles2d.rst b/classes/class_cpuparticles2d.rst index 2a57ce32b..77337f111 100644 --- a/classes/class_cpuparticles2d.rst +++ b/classes/class_cpuparticles2d.rst @@ -851,6 +851,8 @@ Particle draw order. Uses :ref:`DrawOrder` values Sets the :ref:`Color`\ s to modulate particles by when using :ref:`EMISSION_SHAPE_POINTS` or :ref:`EMISSION_SHAPE_DIRECTED_POINTS`. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedColorArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -868,6 +870,8 @@ Sets the :ref:`Color`\ s to modulate particles by when using :ref:` Sets the direction the particles will be emitted in when using :ref:`EMISSION_SHAPE_DIRECTED_POINTS`. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -885,6 +889,8 @@ Sets the direction the particles will be emitted in when using :ref:`EMISSION_SH Sets the initial positions to spawn particles when using :ref:`EMISSION_SHAPE_POINTS` or :ref:`EMISSION_SHAPE_DIRECTED_POINTS`. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_cpuparticles3d.rst b/classes/class_cpuparticles3d.rst index 7b16f0f17..a5c71b3f5 100644 --- a/classes/class_cpuparticles3d.rst +++ b/classes/class_cpuparticles3d.rst @@ -908,6 +908,8 @@ Sets the :ref:`Color`\ s to modulate particles by when using :ref:` \ **Note:** :ref:`emission_colors` multiplies the particle mesh's vertex colors. To have a visible effect on a :ref:`BaseMaterial3D`, :ref:`BaseMaterial3D.vertex_color_use_as_albedo` *must* be ``true``. For a :ref:`ShaderMaterial`, ``ALBEDO *= COLOR.rgb;`` must be inserted in the shader's ``fragment()`` function. Otherwise, :ref:`emission_colors` will have no visible effect. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedColorArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -925,6 +927,8 @@ Sets the :ref:`Color`\ s to modulate particles by when using :ref:` Sets the direction the particles will be emitted in when using :ref:`EMISSION_SHAPE_DIRECTED_POINTS`. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector3Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -942,6 +946,8 @@ Sets the direction the particles will be emitted in when using :ref:`EMISSION_SH Sets the initial positions to spawn particles when using :ref:`EMISSION_SHAPE_POINTS` or :ref:`EMISSION_SHAPE_DIRECTED_POINTS`. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector3Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_csgpolygon3d.rst b/classes/class_csgpolygon3d.rst index 0ac1340d2..d7fb20c7e 100644 --- a/classes/class_csgpolygon3d.rst +++ b/classes/class_csgpolygon3d.rst @@ -403,6 +403,8 @@ The point array that defines the 2D polygon that is extruded. This can be a conv \ **Note:** If only 1 or 2 points are defined in :ref:`polygon`, no mesh will be generated. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_cylindershape3d.rst b/classes/class_cylindershape3d.rst index fa8cd2d32..beefbec09 100644 --- a/classes/class_cylindershape3d.rst +++ b/classes/class_cylindershape3d.rst @@ -30,11 +30,11 @@ A 3D cylinder shape, intended for use in physics. Usually used to provide a shap Tutorials --------- -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ -- `3D Physics Tests Demo `__ +- `3D Physics Tests Demo `__ -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_dictionary.rst b/classes/class_dictionary.rst index b6b0fac41..14d037664 100644 --- a/classes/class_dictionary.rst +++ b/classes/class_dictionary.rst @@ -200,9 +200,9 @@ Tutorials - `GDScript basics: Dictionary <../tutorials/scripting/gdscript/gdscript_basics.html#dictionary>`__ -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ -- `OS Test Demo `__ +- `Operating System Testing Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_displayserver.rst b/classes/class_displayserver.rst index 87f7da92d..f99ce58eb 100644 --- a/classes/class_displayserver.rst +++ b/classes/class_displayserver.rst @@ -1886,7 +1886,7 @@ Returns ``true`` if positions of **OK** and **Cancel** buttons are swapped in di Returns the ID of the window at the specified screen ``position`` (in pixels). On multi-monitor setups, the screen position is relative to the virtual desktop area. On multi-monitor setups with different screen resolutions or orientations, the origin may be located outside any display like this: -:: +.. code:: text * (0, 0) +-------+ | | @@ -1933,7 +1933,7 @@ An ``accelerator`` can optionally be defined, which is a keyboard shortcut that \ **Supported system menu IDs:**\ -:: +.. code:: text "_main" - Main menu (macOS). "_dock" - Dock popup menu (macOS). @@ -1965,7 +1965,7 @@ An ``accelerator`` can optionally be defined, which is a keyboard shortcut that \ **Supported system menu IDs:**\ -:: +.. code:: text "_main" - Main menu (macOS). "_dock" - Dock popup menu (macOS). @@ -1997,7 +1997,7 @@ An ``accelerator`` can optionally be defined, which is a keyboard shortcut that \ **Supported system menu IDs:**\ -:: +.. code:: text "_main" - Main menu (macOS). "_dock" - Dock popup menu (macOS). @@ -2031,7 +2031,7 @@ An ``accelerator`` can optionally be defined, which is a keyboard shortcut that \ **Supported system menu IDs:**\ -:: +.. code:: text "_main" - Main menu (macOS). "_dock" - Dock popup menu (macOS). @@ -2063,7 +2063,7 @@ An ``accelerator`` can optionally be defined, which is a keyboard shortcut that \ **Supported system menu IDs:**\ -:: +.. code:: text "_main" - Main menu (macOS). "_dock" - Dock popup menu (macOS). @@ -2099,7 +2099,7 @@ An ``accelerator`` can optionally be defined, which is a keyboard shortcut that \ **Supported system menu IDs:**\ -:: +.. code:: text "_main" - Main menu (macOS). "_dock" - Dock popup menu (macOS). @@ -2133,7 +2133,7 @@ An ``accelerator`` can optionally be defined, which is a keyboard shortcut that \ **Supported system menu IDs:**\ -:: +.. code:: text "_main" - Main menu (macOS). "_dock" - Dock popup menu (macOS). @@ -2161,7 +2161,7 @@ Returns index of the inserted item, it's not guaranteed to be the same as ``inde \ **Supported system menu IDs:**\ -:: +.. code:: text "_main" - Main menu (macOS). "_dock" - Dock popup menu (macOS). @@ -2189,7 +2189,7 @@ Returns index of the inserted item, it's not guaranteed to be the same as ``inde \ **Supported system menu IDs:**\ -:: +.. code:: text "_main" - Main menu (macOS). "_dock" - Dock popup menu (macOS). @@ -2215,7 +2215,7 @@ Removes all items from the global menu with ID ``menu_root``. \ **Supported system menu IDs:**\ -:: +.. code:: text "_main" - Main menu (macOS). "_dock" - Dock popup menu (macOS). @@ -3135,7 +3135,7 @@ Returns the dots per inch density of the specified screen. If ``screen`` is :ref \ **Note:** On Android devices, the actual screen densities are grouped into six generalized densities: -:: +.. code:: text ldpi - 120 dpi mdpi - 160 dpi @@ -3220,7 +3220,7 @@ Returns color of the display pixel at the ``position``. Returns the screen's top-left corner position in pixels. On multi-monitor setups, the screen position is relative to the virtual desktop area. On multi-monitor setups with different screen resolutions or orientations, the origin may be located outside any display like this: -:: +.. code:: text * (0, 0) +-------+ | | @@ -4222,7 +4222,7 @@ Sets the bounding box of control, or menu item that was used to open the popup w Sets the position of the given window to ``position``. On multi-monitor setups, the screen position is relative to the virtual desktop area. On multi-monitor setups with different screen resolutions or orientations, the origin may be located outside any display like this: -:: +.. code:: text * (0, 0) +-------+ | | diff --git a/classes/class_editorexportplatformandroid.rst b/classes/class_editorexportplatformandroid.rst index e69ffbf74..2afe2440c 100644 --- a/classes/class_editorexportplatformandroid.rst +++ b/classes/class_editorexportplatformandroid.rst @@ -270,6 +270,8 @@ Properties +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`permissions/persistent_activity` | +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`permissions/post_notifications` | + +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`permissions/process_outgoing_calls` | +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`permissions/read_calendar` | @@ -446,9 +448,9 @@ Array of random bytes that the licensing Policy uses to create an `Obfuscator ` **apk_expansion/enable** -If ``true``, project resources are stored in the separate APK expansion file, instead APK. +If ``true``, project resources are stored in the separate APK expansion file, instead of the APK. -\ **Note:** APK expansion should be enabled to use PCK encryption. +\ **Note:** APK expansion should be enabled to use PCK encryption. See `APK Expansion Files `__ .. rst-class:: classref-item-separator @@ -460,7 +462,7 @@ If ``true``, project resources are stored in the separate APK expansion file, in :ref:`String` **apk_expansion/public_key** -Base64 encoded RSA public key for your publisher account, available from the profile page on the "Play Console". +Base64 encoded RSA public key for your publisher account, available from the profile page on the "Google Play Console". .. rst-class:: classref-item-separator @@ -520,7 +522,7 @@ If ``true``, ``x86_64`` binaries are included into exported project. :ref:`String` **command_line/extra_args** -A list of additional command line arguments, exported project will receive when started. +A list of additional command line arguments, separated by space, which the exported project will receive when started. .. rst-class:: classref-item-separator @@ -586,7 +588,7 @@ If ``true``, native libraries are compressed when performing a Gradle build. :ref:`int` **gradle_build/export_format** -Export format for Gradle build. +Application export format (\*.apk or \*.aab). .. rst-class:: classref-item-separator @@ -610,7 +612,7 @@ Path to the Gradle build directory. If left empty, then ``res://android`` will b :ref:`String` **gradle_build/min_sdk** -Minimal Android SDK version for Gradle build. +Minimum Android API level required for the application to run (used during Gradle build). See `android:minSdkVersion `__. .. rst-class:: classref-item-separator @@ -622,7 +624,7 @@ Minimal Android SDK version for Gradle build. :ref:`String` **gradle_build/target_sdk** -Target Android SDK version for Gradle build. +The Android API level on which the application is designed to run (used during Gradle build). See `android:targetSdkVersion `__. .. rst-class:: classref-item-separator @@ -748,7 +750,7 @@ Can be overridden with the environment variable ``GODOT_ANDROID_KEYSTORE_RELEASE :ref:`String` **launcher_icons/adaptive_background_432x432** -Background layer of the application adaptive icon file. +Background layer of the application adaptive icon file. See `Design adaptive icons `__. .. rst-class:: classref-item-separator @@ -760,7 +762,7 @@ Background layer of the application adaptive icon file. :ref:`String` **launcher_icons/adaptive_foreground_432x432** -Foreground layer of the application adaptive icon file. +Foreground layer of the application adaptive icon file. See `Design adaptive icons `__. .. rst-class:: classref-item-separator @@ -784,7 +786,7 @@ Application icon file. If left empty, it will fallback to :ref:`ProjectSettings. :ref:`int` **package/app_category** -Application category for the Play Store. +Application category for the Google Play Store. Only define this if your application fits one of the categories well. See `android:appCategory `__. .. rst-class:: classref-item-separator @@ -796,7 +798,7 @@ Application category for the Play Store. :ref:`bool` **package/exclude_from_recents** -If ``true``, task initiated by main activity will be excluded from the list of recently used applications. +If ``true``, task initiated by main activity will be excluded from the list of recently used applications. See `android:excludeFromRecents `__. .. rst-class:: classref-item-separator @@ -820,7 +822,7 @@ Name of the application. :ref:`bool` **package/retain_data_on_uninstall** -If ``true``, when the user uninstalls an app, a prompt to keep the app's data will be shown. +If ``true``, when the user uninstalls an app, a prompt to keep the app's data will be shown. See `android:hasFragileUserData `__. .. rst-class:: classref-item-separator @@ -1442,6 +1444,8 @@ Allows enabling/disabling location update notifications from the radio. See `CON Array of custom permission strings. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -1874,7 +1878,19 @@ Allows applications to perform I/O operations over NFC. See `NFC ` **permissions/post_notifications** + +Allows an application to post notifications. Added in API level 33. See `Notification runtime permission `__. .. rst-class:: classref-item-separator @@ -2766,9 +2782,7 @@ Application version visible to the user. Falls back to :ref:`ProjectSettings.app :ref:`int` **xr_features/xr_mode** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +The extended reality (XR) mode for this application. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_editorexportplatformios.rst b/classes/class_editorexportplatformios.rst index e58707a4e..6d86e3787 100644 --- a/classes/class_editorexportplatformios.rst +++ b/classes/class_editorexportplatformios.rst @@ -146,7 +146,7 @@ Property Descriptions Additional data added to the root ```` section of the `Info.plist `__ file. The value should be an XML section with pairs of key-value elements, e.g.: -:: +.. code:: text key_name value diff --git a/classes/class_editorexportplatformmacos.rst b/classes/class_editorexportplatformmacos.rst index f8365fded..51d3dd8ef 100644 --- a/classes/class_editorexportplatformmacos.rst +++ b/classes/class_editorexportplatformmacos.rst @@ -232,7 +232,7 @@ Property Descriptions Additional data added to the root ```` section of the `Info.plist `__ file. The value should be an XML section with pairs of key-value elements, e.g.: -:: +.. code:: text key_name value @@ -449,6 +449,8 @@ Tool to use for code signing. Array of the additional command line arguments passed to the code signing tool. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_editorexportplatformpc.rst b/classes/class_editorexportplatformpc.rst index f147dfe99..195276a8d 100644 --- a/classes/class_editorexportplatformpc.rst +++ b/classes/class_editorexportplatformpc.rst @@ -16,6 +16,22 @@ EditorExportPlatformPC Base class for the desktop platform exporter (Windows and Linux/BSD). +.. rst-class:: classref-introduction-group + +Description +----------- + +The base class for the desktop platform exporters. These include Windows and Linux/BSD, but not macOS. See the classes inheriting this one for more details. + +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Exporting for Windows <../tutorials/export/exporting_for_windows>` + +- :doc:`Exporting for Linux <../tutorials/export/exporting_for_linux>` + .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` diff --git a/classes/class_editorexportplatformwindows.rst b/classes/class_editorexportplatformwindows.rst index 007bb4908..a9b220402 100644 --- a/classes/class_editorexportplatformwindows.rst +++ b/classes/class_editorexportplatformwindows.rst @@ -16,6 +16,13 @@ Exporter for Windows. .. rst-class:: classref-introduction-group +Description +----------- + +The Windows exporter customizes how a Windows build is handled. In the editor's "Export" window, it is created when adding a new "Windows" preset. + +.. rst-class:: classref-introduction-group + Tutorials --------- @@ -318,6 +325,8 @@ If ``true``, project resources are embedded into the executable. Array of the additional command line arguments passed to the code signing tool. See `Sign Tool `__. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_editorfiledialog.rst b/classes/class_editorfiledialog.rst index 45b3e54d4..973d393e4 100644 --- a/classes/class_editorfiledialog.rst +++ b/classes/class_editorfiledialog.rst @@ -390,6 +390,8 @@ The dialog's open or save mode, which affects the selection behavior. See :ref:` The available file type filters. For example, this shows only ``.png`` and ``.gd`` files: ``set_filters(PackedStringArray(["*.png ; PNG Images","*.gd ; GDScript Files"]))``. Multiple file types can also be specified in a single filter. ``"*.png, *.jpg, *.jpeg ; Supported Images"`` will show both PNG and JPEG files when selected. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_editorpaths.rst b/classes/class_editorpaths.rst index ce4a559a5..41d5e1b28 100644 --- a/classes/class_editorpaths.rst +++ b/classes/class_editorpaths.rst @@ -73,7 +73,7 @@ Returns the absolute path to the user's cache folder. This folder should be used \ **Default paths per platform:**\ -:: +.. code:: text - Windows: %LOCALAPPDATA%\Godot\ - macOS: ~/Library/Caches/Godot/ @@ -93,7 +93,7 @@ Returns the absolute path to the user's configuration folder. This folder should \ **Default paths per platform:**\ -:: +.. code:: text - Windows: %APPDATA%\Godot\ (same as `get_data_dir()`) - macOS: ~/Library/Application Support/Godot/ (same as `get_data_dir()`) @@ -113,7 +113,7 @@ Returns the absolute path to the user's data folder. This folder should be used \ **Default paths per platform:**\ -:: +.. code:: text - Windows: %APPDATA%\Godot\ (same as `get_config_dir()`) - macOS: ~/Library/Application Support/Godot/ (same as `get_config_dir()`) diff --git a/classes/class_editorsettings.rst b/classes/class_editorsettings.rst index ade1a3f94..7bc0fadc9 100644 --- a/classes/class_editorsettings.rst +++ b/classes/class_editorsettings.rst @@ -2949,6 +2949,8 @@ If ``true``, subresources can be edited in the current inspector view. If the re List of resources that should always be opened in a new inspector view, even if :ref:`interface/inspector/open_resources_in_current_inspector` is ``true``. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -3201,7 +3203,7 @@ The icon and font color scheme to use in the editor. - **Auto** determines the color scheme to use automatically based on :ref:`interface/theme/base_color`. -- **Dark** makes fonts and icons dark (suitable for light themes). Icon colors are automatically converted by the editor following the set of rules defined in `this file `__. +- **Dark** makes fonts and icons dark (suitable for light themes). Icon colors are automatically converted by the editor following the set of rules defined in `this file `__. - **Light** makes fonts and icons light (suitable for dark themes). diff --git a/classes/class_environment.rst b/classes/class_environment.rst index b0eadbef8..51eb56896 100644 --- a/classes/class_environment.rst +++ b/classes/class_environment.rst @@ -38,11 +38,9 @@ Tutorials - :doc:`High dynamic range lighting <../tutorials/3d/high_dynamic_range>` -- `3D Material Testers Demo `__ +- `3D Material Testers Demo `__ -- `2D HDR Demo `__ - -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_fileaccess.rst b/classes/class_fileaccess.rst index 979fa7a7d..f8aa4676a 100644 --- a/classes/class_fileaccess.rst +++ b/classes/class_fileaccess.rst @@ -71,7 +71,7 @@ Tutorials - :doc:`Runtime file loading and saving <../tutorials/io/runtime_file_loading_and_saving>` -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group @@ -606,7 +606,7 @@ Text is interpreted as being UTF-8 encoded. Text values must be enclosed in doub For example, the following CSV lines are valid and will be properly parsed as two strings each: -:: +.. code:: text Alice,"Hello, Bob!" Bob,Alice! What a surprise! diff --git a/classes/class_filedialog.rst b/classes/class_filedialog.rst index 25c3396ac..8bbd4a7b6 100644 --- a/classes/class_filedialog.rst +++ b/classes/class_filedialog.rst @@ -366,6 +366,8 @@ The dialog's open or save mode, which affects the selection behavior. See :ref:` The available file type filters. Each filter string in the array should be formatted like this: ``*.txt,*.doc;Text Files``. The description text of the filter is optional and can be omitted. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_fontfile.rst b/classes/class_fontfile.rst index 10bd5bfd1..32c1bac8b 100644 --- a/classes/class_fontfile.rst +++ b/classes/class_fontfile.rst @@ -313,6 +313,8 @@ Font anti-aliasing mode. Contents of the dynamic font source file. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedByteArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_gltfmesh.rst b/classes/class_gltfmesh.rst index 69d0ef56b..18efec24f 100644 --- a/classes/class_gltfmesh.rst +++ b/classes/class_gltfmesh.rst @@ -82,6 +82,8 @@ Property Descriptions An array of floats representing the blend weights of the mesh. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedFloat32Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_gltfnode.rst b/classes/class_gltfnode.rst index 4ed23efb9..034911765 100644 --- a/classes/class_gltfnode.rst +++ b/classes/class_gltfnode.rst @@ -121,6 +121,8 @@ If this GLTF node is a camera, the index of the :ref:`GLTFCamera`. If this GLTF node has no children, this will be an empty array. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt32Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_gltfphysicsbody.rst b/classes/class_gltfphysicsbody.rst index b34a0c741..0efd97208 100644 --- a/classes/class_gltfphysicsbody.rst +++ b/classes/class_gltfphysicsbody.rst @@ -248,7 +248,7 @@ Creates a new GLTFPhysicsBody instance by parsing the given :ref:`Dictionary` **from_node**\ (\ body_node\: :ref:`CollisionObject3D`\ ) |static| -Create a new GLTFPhysicsBody instance from the given Godot :ref:`CollisionObject3D` node. +Creates a new GLTFPhysicsBody instance from the given Godot :ref:`CollisionObject3D` node. .. rst-class:: classref-item-separator diff --git a/classes/class_gltfphysicsshape.rst b/classes/class_gltfphysicsshape.rst index 50198edaa..229de617e 100644 --- a/classes/class_gltfphysicsshape.rst +++ b/classes/class_gltfphysicsshape.rst @@ -69,10 +69,14 @@ Methods +-------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`GLTFPhysicsShape` | :ref:`from_node`\ (\ shape_node\: :ref:`CollisionShape3D`\ ) |static| | +-------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`GLTFPhysicsShape` | :ref:`from_resource`\ (\ shape_resource\: :ref:`Shape3D`\ ) |static| | + +-------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Dictionary` | :ref:`to_dictionary`\ (\ ) |const| | +-------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`CollisionShape3D` | :ref:`to_node`\ (\ cache_shapes\: :ref:`bool` = false\ ) | +-------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Shape3D` | :ref:`to_resource`\ (\ cache_shapes\: :ref:`bool` = false\ ) | + +-------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -227,7 +231,19 @@ Creates a new GLTFPhysicsShape instance by parsing the given :ref:`Dictionary` **from_node**\ (\ shape_node\: :ref:`CollisionShape3D`\ ) |static| -Create a new GLTFPhysicsShape instance from the given Godot :ref:`CollisionShape3D` node. +Creates a new GLTFPhysicsShape instance from the given Godot :ref:`CollisionShape3D` node. + +.. rst-class:: classref-item-separator + +---- + +.. _class_GLTFPhysicsShape_method_from_resource: + +.. rst-class:: classref-method + +:ref:`GLTFPhysicsShape` **from_resource**\ (\ shape_resource\: :ref:`Shape3D`\ ) |static| + +Creates a new GLTFPhysicsShape instance from the given Godot :ref:`Shape3D` resource. .. rst-class:: classref-item-separator @@ -253,6 +269,18 @@ Serializes this GLTFPhysicsShape instance into a :ref:`Dictionary` node. +.. rst-class:: classref-item-separator + +---- + +.. _class_GLTFPhysicsShape_method_to_resource: + +.. rst-class:: classref-method + +:ref:`Shape3D` **to_resource**\ (\ cache_shapes\: :ref:`bool` = false\ ) + +Converts this GLTFPhysicsShape instance into a Godot :ref:`Shape3D` resource. + .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` diff --git a/classes/class_gltfstate.rst b/classes/class_gltfstate.rst index 8d401d035..27093e608 100644 --- a/classes/class_gltfstate.rst +++ b/classes/class_gltfstate.rst @@ -312,6 +312,8 @@ The file name associated with this GLTF data. If it ends with ``.gltf``, this is The binary buffer attached to a .glb file. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedByteArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -401,6 +403,8 @@ The original raw JSON document corresponding to this GLTFState. The root nodes of the GLTF file. Typically, a GLTF file will only have one scene, and therefore one root node. However, a GLTF file may have multiple scenes and therefore multiple root nodes, which will be generated as siblings of each other and as children of the root node of the generated Godot scene. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt32Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_gpuparticles2d.rst b/classes/class_gpuparticles2d.rst index 356c86bc5..3a81d2b75 100644 --- a/classes/class_gpuparticles2d.rst +++ b/classes/class_gpuparticles2d.rst @@ -32,9 +32,9 @@ Tutorials - :doc:`Particle systems (2D) <../tutorials/2d/particle_systems_2d>` -- `2D Particles Demo `__ +- `2D Particles Demo `__ -- `2D Dodge The Creeps Demo (uses GPUParticles2D for the trail behind the player) `__ +- `2D Dodge The Creeps Demo (uses GPUParticles2D for the trail behind the player) `__ .. rst-class:: classref-reftable-group @@ -127,9 +127,11 @@ Signals **finished**\ (\ ) -Emitted when all active particles have finished processing. When :ref:`one_shot` is disabled, particles will process continuously, so this is never emitted. +Emitted when all active particles have finished processing. To immediately restart the emission cycle, call :ref:`restart`. -\ **Note:** Due to the particles being computed on the GPU there might be a delay before the signal gets emitted. +Never emitted when :ref:`one_shot` is disabled, as particles will be emitted and processed continuously. + +\ **Note:** For :ref:`one_shot` emitters, due to the particles being computed on the GPU, there may be a short period after receiving the signal during which setting :ref:`emitting` to ``true`` will not restart the emission cycle. This delay is avoided by instead calling :ref:`restart`. .. rst-class:: classref-section-separator @@ -314,7 +316,11 @@ Particle draw order. Uses :ref:`DrawOrder` values - |void| **set_emitting**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **is_emitting**\ (\ ) -If ``true``, particles are being emitted. :ref:`emitting` can be used to start and stop particles from emitting. However, if :ref:`one_shot` is ``true`` setting :ref:`emitting` to ``true`` will not restart the emission cycle until after all active particles finish processing. You can use the :ref:`finished` signal to be notified once all active particles finish processing. +If ``true``, particles are being emitted. :ref:`emitting` can be used to start and stop particles from emitting. However, if :ref:`one_shot` is ``true`` setting :ref:`emitting` to ``true`` will not restart the emission cycle unless all active particles have finished processing. Use the :ref:`finished` signal to be notified once all active particles finish processing. + +\ **Note:** For :ref:`one_shot` emitters, due to the particles being computed on the GPU, there may be a short period after receiving the :ref:`finished` signal during which setting this to ``true`` will not restart the emission cycle. + +\ **Tip:** If your :ref:`one_shot` emitter needs to immediately restart emitting particles once :ref:`finished` signal is received, consider calling :ref:`restart` instead of setting :ref:`emitting`. .. rst-class:: classref-item-separator @@ -704,7 +710,9 @@ The default ParticleProcessMaterial will overwrite ``color`` and use the content |void| **restart**\ (\ ) -Restarts all the existing particles. +Restarts the particle emission cycle, clearing existing particles. To avoid particles vanishing from the viewport, wait for the :ref:`finished` signal before calling. + +\ **Note:** The :ref:`finished` signal is only emitted by :ref:`one_shot` emitters. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_gpuparticles3d.rst b/classes/class_gpuparticles3d.rst index 0f1922e00..208b1d9bc 100644 --- a/classes/class_gpuparticles3d.rst +++ b/classes/class_gpuparticles3d.rst @@ -32,7 +32,7 @@ Tutorials - :doc:`Controlling thousands of fish with Particles <../tutorials/performance/vertex_animation/controlling_thousands_of_fish>` -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group @@ -137,9 +137,11 @@ Signals **finished**\ (\ ) -Emitted when all active particles have finished processing. When :ref:`one_shot` is disabled, particles will process continuously, so this is never emitted. +Emitted when all active particles have finished processing. To immediately emit new particles, call :ref:`restart`. -\ **Note:** Due to the particles being computed on the GPU there might be a delay before the signal gets emitted. +Never emitted when :ref:`one_shot` is disabled, as particles will be emitted and processed continuously. + +\ **Note:** For :ref:`one_shot` emitters, due to the particles being computed on the GPU, there may be a short period after receiving the signal during which setting :ref:`emitting` to ``true`` will not restart the emission cycle. This delay is avoided by instead calling :ref:`restart`. .. rst-class:: classref-section-separator @@ -513,7 +515,11 @@ The number of draw passes when rendering particles. - |void| **set_emitting**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **is_emitting**\ (\ ) -If ``true``, particles are being emitted. :ref:`emitting` can be used to start and stop particles from emitting. However, if :ref:`one_shot` is ``true`` setting :ref:`emitting` to ``true`` will not restart the emission cycle until after all active particles finish processing. You can use the :ref:`finished` signal to be notified once all active particles finish processing. +If ``true``, particles are being emitted. :ref:`emitting` can be used to start and stop particles from emitting. However, if :ref:`one_shot` is ``true`` setting :ref:`emitting` to ``true`` will not restart the emission cycle unless all active particles have finished processing. Use the :ref:`finished` signal to be notified once all active particles finish processing. + +\ **Note:** For :ref:`one_shot` emitters, due to the particles being computed on the GPU, there may be a short period after receiving the :ref:`finished` signal during which setting this to ``true`` will not restart the emission cycle. + +\ **Tip:** If your :ref:`one_shot` emitter needs to immediately restart emitting particles once :ref:`finished` signal is received, consider calling :ref:`restart` instead of setting :ref:`emitting`. .. rst-class:: classref-item-separator @@ -883,7 +889,9 @@ Returns the :ref:`Mesh` that is drawn at index ``pass``. |void| **restart**\ (\ ) -Restarts the particle emission, clearing existing particles. +Restarts the particle emission cycle, clearing existing particles. To avoid particles vanishing from the viewport, wait for the :ref:`finished` signal before calling. + +\ **Note:** The :ref:`finished` signal is only emitted by :ref:`one_shot` emitters. .. rst-class:: classref-item-separator diff --git a/classes/class_gradient.rst b/classes/class_gradient.rst index e2860adee..1e9d2c999 100644 --- a/classes/class_gradient.rst +++ b/classes/class_gradient.rst @@ -162,9 +162,11 @@ Property Descriptions - |void| **set_colors**\ (\ value\: :ref:`PackedColorArray`\ ) - :ref:`PackedColorArray` **get_colors**\ (\ ) -Gradient's colors returned as a :ref:`PackedColorArray`. +Gradient's colors as a :ref:`PackedColorArray`. -\ **Note:** This property returns a copy, modifying the return value does not update the gradient. To update the gradient use :ref:`set_color` method (for updating colors individually) or assign to this property directly (for bulk-updating all colors at once). +\ **Note:** Setting this property updates all colors at once. To update any color individually use :ref:`set_color`. + +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedColorArray` for more details. .. rst-class:: classref-item-separator @@ -217,9 +219,11 @@ The algorithm used to interpolate between points of the gradient. See :ref:`Inte - |void| **set_offsets**\ (\ value\: :ref:`PackedFloat32Array`\ ) - :ref:`PackedFloat32Array` **get_offsets**\ (\ ) -Gradient's offsets returned as a :ref:`PackedFloat32Array`. +Gradient's offsets as a :ref:`PackedFloat32Array`. -\ **Note:** This property returns a copy, modifying the return value does not update the gradient. To update the gradient use :ref:`set_offset` method (for updating offsets individually) or assign to this property directly (for bulk-updating all offsets at once). +\ **Note:** Setting this property updates all offsets at once. To update any offset individually use :ref:`set_offset`. + +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedFloat32Array` for more details. .. rst-class:: classref-section-separator diff --git a/classes/class_gridcontainer.rst b/classes/class_gridcontainer.rst index 4aca26777..7cec6808e 100644 --- a/classes/class_gridcontainer.rst +++ b/classes/class_gridcontainer.rst @@ -30,7 +30,7 @@ Tutorials - :doc:`Using Containers <../tutorials/ui/gui_containers>` -- `OS Test Demo `__ +- `Operating System Testing Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_gridmap.rst b/classes/class_gridmap.rst index fae6948cc..c473116b9 100644 --- a/classes/class_gridmap.rst +++ b/classes/class_gridmap.rst @@ -39,9 +39,9 @@ Tutorials - :doc:`Using gridmaps <../tutorials/3d/using_gridmaps>` -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `3D Kinematic Character Demo `__ +- `3D Kinematic Character Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_heightmapshape3d.rst b/classes/class_heightmapshape3d.rst index bd507b0dd..fba539c0f 100644 --- a/classes/class_heightmapshape3d.rst +++ b/classes/class_heightmapshape3d.rst @@ -95,6 +95,8 @@ Property Descriptions Height map data. The array's size must be equal to :ref:`map_width` multiplied by :ref:`map_depth`. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedFloat32Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_input.rst b/classes/class_input.rst index f691eabe9..0a4989244 100644 --- a/classes/class_input.rst +++ b/classes/class_input.rst @@ -30,9 +30,9 @@ Tutorials - :doc:`Inputs documentation index <../tutorials/inputs/index>` -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_inputevent.rst b/classes/class_inputevent.rst index 305d91ed6..6e9dfacae 100644 --- a/classes/class_inputevent.rst +++ b/classes/class_inputevent.rst @@ -32,9 +32,9 @@ Tutorials - :doc:`Viewport and canvas transforms <../tutorials/2d/2d_transforms>` -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_inputeventaction.rst b/classes/class_inputeventaction.rst index a9005655f..d87748430 100644 --- a/classes/class_inputeventaction.rst +++ b/classes/class_inputeventaction.rst @@ -30,9 +30,9 @@ Tutorials - `Using InputEvent: Actions <../tutorials/inputs/inputevent.html#actions>`__ -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_inputeventkey.rst b/classes/class_inputeventkey.rst index abb534036..feeeb1c03 100644 --- a/classes/class_inputeventkey.rst +++ b/classes/class_inputeventkey.rst @@ -123,7 +123,7 @@ For keyboard layouts with a single label on the key, it is equivalent to :ref:`k To get a human-readable representation of the **InputEventKey**, use ``OS.get_keycode_string(event.key_label)`` where ``event`` is the **InputEventKey**. -:: +.. code:: text +-----+ +-----+ | Q | | Q | - "Q" - keycode @@ -149,7 +149,7 @@ Latin label printed on the key in the current keyboard layout, which corresponds To get a human-readable representation of the **InputEventKey**, use ``OS.get_keycode_string(event.keycode)`` where ``event`` is the **InputEventKey**. -:: +.. code:: text +-----+ +-----+ | Q | | Q | - "Q" - keycode diff --git a/classes/class_inputeventmousemotion.rst b/classes/class_inputeventmousemotion.rst index 5cb1f6223..c50e81a72 100644 --- a/classes/class_inputeventmousemotion.rst +++ b/classes/class_inputeventmousemotion.rst @@ -32,7 +32,7 @@ Tutorials - :doc:`Mouse and input coordinates <../tutorials/inputs/mouse_and_input_coordinates>` -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_javaclass.rst b/classes/class_javaclass.rst index 191fc448c..ec46c89bd 100644 --- a/classes/class_javaclass.rst +++ b/classes/class_javaclass.rst @@ -12,9 +12,18 @@ JavaClass **Inherits:** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +Represents an object from the Java Native Interface. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +Represents an object from the Java Native Interface. It is returned from :ref:`JavaClassWrapper.wrap`. + +\ **Note:** This class only works on Android. For any other build, this class does nothing. + +\ **Note:** This class is not to be confused with :ref:`JavaScriptObject`. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_javaclasswrapper.rst b/classes/class_javaclasswrapper.rst index cb0f9c652..05c371a0f 100644 --- a/classes/class_javaclasswrapper.rst +++ b/classes/class_javaclasswrapper.rst @@ -12,9 +12,16 @@ JavaClassWrapper **Inherits:** :ref:`Object` -.. container:: contribute +Provides access to the Java Native Interface. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +The JavaClassWrapper singleton provides a way for the Godot application to send and receive data through the `Java Native Interface `__ (JNI). + +\ **Note:** This singleton is only available in Android builds. .. rst-class:: classref-reftable-group @@ -43,9 +50,9 @@ Method Descriptions :ref:`JavaClass` **wrap**\ (\ name\: :ref:`String`\ ) -.. container:: contribute +Wraps a class defined in Java, and returns it as a :ref:`JavaClass` :ref:`Object` type that Godot can interact with. - There is currently no description for this method. Please help us by :ref:`contributing one `! +\ **Note:** This method only works on Android. On every other platform, this method does nothing and returns an empty :ref:`JavaClass`. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_joint3d.rst b/classes/class_joint3d.rst index b0da45803..54b1bbc6d 100644 --- a/classes/class_joint3d.rst +++ b/classes/class_joint3d.rst @@ -28,7 +28,7 @@ Abstract base class for all joints in 3D physics. 3D joints bind together two ph Tutorials --------- -- `3D Truck Town Demo `__ +- `3D Truck Town Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_jsonrpc.rst b/classes/class_jsonrpc.rst index a3f418ada..9859db027 100644 --- a/classes/class_jsonrpc.rst +++ b/classes/class_jsonrpc.rst @@ -66,11 +66,7 @@ enum **ErrorCode**: :ref:`ErrorCode` **PARSE_ERROR** = ``-32700`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +The request could not be parsed as it was not valid by JSON standard (:ref:`JSON.parse` failed). .. _class_JSONRPC_constant_INVALID_REQUEST: @@ -78,11 +74,7 @@ enum **ErrorCode**: :ref:`ErrorCode` **INVALID_REQUEST** = ``-32600`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +A method call was requested but the request's format is not valid. .. _class_JSONRPC_constant_METHOD_NOT_FOUND: @@ -98,11 +90,7 @@ A method call was requested but no function of that name existed in the JSONRPC :ref:`ErrorCode` **INVALID_PARAMS** = ``-32602`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +A method call was requested but the given method parameters are not valid. Not used by the built-in JSONRPC. .. _class_JSONRPC_constant_INTERNAL_ERROR: @@ -110,11 +98,7 @@ A method call was requested but no function of that name existed in the JSONRPC :ref:`ErrorCode` **INTERNAL_ERROR** = ``-32603`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +An internal error occurred while processing the request. Not used by the built-in JSONRPC. .. rst-class:: classref-section-separator diff --git a/classes/class_label.rst b/classes/class_label.rst index e4b5405b5..6435cb43a 100644 --- a/classes/class_label.rst +++ b/classes/class_label.rst @@ -29,7 +29,7 @@ A control for displaying plain text. It gives you control over the horizontal an Tutorials --------- -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ .. rst-class:: classref-reftable-group @@ -346,6 +346,8 @@ Set additional options for BiDi override. Aligns text to the given tab-stops. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedFloat32Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_light3d.rst b/classes/class_light3d.rst index 56158e345..fda2638d2 100644 --- a/classes/class_light3d.rst +++ b/classes/class_light3d.rst @@ -32,7 +32,7 @@ Tutorials - :doc:`Faking global illumination <../tutorials/3d/global_illumination/faking_global_illumination>` -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_line2d.rst b/classes/class_line2d.rst index 8fadb1298..ebdfae3c3 100644 --- a/classes/class_line2d.rst +++ b/classes/class_line2d.rst @@ -30,9 +30,9 @@ This node draws a 2D polyline, i.e. a shape consisting of several points connect Tutorials --------- -- `Matrix Transform Demo `__ +- `Matrix Transform Demo `__ -- `2.5D Demo `__ +- `2.5D Game Demo `__ .. rst-class:: classref-reftable-group @@ -348,6 +348,8 @@ The style of the connections between segments of the polyline. Use :ref:`LineJoi The points of the polyline, interpreted in local 2D coordinates. Segments are drawn between the adjacent points in this array. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_material.rst b/classes/class_material.rst index 9416e1ad5..cb16e96a8 100644 --- a/classes/class_material.rst +++ b/classes/class_material.rst @@ -30,9 +30,9 @@ Importantly, you can inherit from **Material** to create your own custom materia Tutorials --------- -- `3D Material Testers Demo `__ +- `3D Material Testers Demo `__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_mesh.rst b/classes/class_mesh.rst index 82520076d..da40b5210 100644 --- a/classes/class_mesh.rst +++ b/classes/class_mesh.rst @@ -28,13 +28,13 @@ Mesh is a type of :ref:`Resource` that contains vertex array-bas Tutorials --------- -- `3D Material Testers Demo `__ +- `3D Material Testers Demo `__ -- `3D Kinematic Character Demo `__ +- `3D Kinematic Character Demo `__ -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_meshinstance3d.rst b/classes/class_meshinstance3d.rst index 1cd6607f4..20524788f 100644 --- a/classes/class_meshinstance3d.rst +++ b/classes/class_meshinstance3d.rst @@ -28,13 +28,13 @@ MeshInstance3D is a node that takes a :ref:`Mesh` resource and adds Tutorials --------- -- `3D Material Testers Demo `__ +- `3D Material Testers Demo `__ -- `3D Kinematic Character Demo `__ +- `3D Kinematic Character Demo `__ -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group @@ -60,31 +60,33 @@ Methods .. table:: :widths: auto - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`create_convex_collision`\ (\ clean\: :ref:`bool` = true, simplify\: :ref:`bool` = false\ ) | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`create_debug_tangents`\ (\ ) | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`create_multiple_convex_collisions`\ (\ settings\: :ref:`MeshConvexDecompositionSettings` = null\ ) | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`create_trimesh_collision`\ (\ ) | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`find_blend_shape_by_name`\ (\ name\: :ref:`StringName`\ ) | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Material` | :ref:`get_active_material`\ (\ surface\: :ref:`int`\ ) |const| | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`get_blend_shape_count`\ (\ ) |const| | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`get_blend_shape_value`\ (\ blend_shape_idx\: :ref:`int`\ ) |const| | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Material` | :ref:`get_surface_override_material`\ (\ surface\: :ref:`int`\ ) |const| | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`get_surface_override_material_count`\ (\ ) |const| | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`set_blend_shape_value`\ (\ blend_shape_idx\: :ref:`int`, value\: :ref:`float`\ ) | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`set_surface_override_material`\ (\ surface\: :ref:`int`, material\: :ref:`Material`\ ) | - +---------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`create_convex_collision`\ (\ clean\: :ref:`bool` = true, simplify\: :ref:`bool` = false\ ) | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`create_debug_tangents`\ (\ ) | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`create_multiple_convex_collisions`\ (\ settings\: :ref:`MeshConvexDecompositionSettings` = null\ ) | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`create_trimesh_collision`\ (\ ) | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`find_blend_shape_by_name`\ (\ name\: :ref:`StringName`\ ) | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Material` | :ref:`get_active_material`\ (\ surface\: :ref:`int`\ ) |const| | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`get_blend_shape_count`\ (\ ) |const| | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`get_blend_shape_value`\ (\ blend_shape_idx\: :ref:`int`\ ) |const| | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`SkinReference` | :ref:`get_skin_reference`\ (\ ) |const| | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Material` | :ref:`get_surface_override_material`\ (\ surface\: :ref:`int`\ ) |const| | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`get_surface_override_material_count`\ (\ ) |const| | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`set_blend_shape_value`\ (\ blend_shape_idx\: :ref:`int`, value\: :ref:`float`\ ) | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`set_surface_override_material`\ (\ surface\: :ref:`int`, material\: :ref:`Material`\ ) | + +-------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -253,6 +255,18 @@ Returns the value of the blend shape at the given ``blend_shape_idx``. Returns ` ---- +.. _class_MeshInstance3D_method_get_skin_reference: + +.. rst-class:: classref-method + +:ref:`SkinReference` **get_skin_reference**\ (\ ) |const| + +Returns the internal :ref:`SkinReference` containing the skeleton's :ref:`RID` attached to this RID. See also :ref:`Resource.get_rid`, :ref:`SkinReference.get_skeleton`, and :ref:`RenderingServer.instance_attach_skeleton`. + +.. rst-class:: classref-item-separator + +---- + .. _class_MeshInstance3D_method_get_surface_override_material: .. rst-class:: classref-method diff --git a/classes/class_meshlibrary.rst b/classes/class_meshlibrary.rst index b834c82dc..e494b31f5 100644 --- a/classes/class_meshlibrary.rst +++ b/classes/class_meshlibrary.rst @@ -26,9 +26,9 @@ A library of meshes. Contains a list of :ref:`Mesh` resources, each Tutorials --------- -- `3D Kinematic Character Demo `__ +- `3D Kinematic Character Demo `__ -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_multimesh.rst b/classes/class_multimesh.rst index 9360bd9d8..473860e10 100644 --- a/classes/class_multimesh.rst +++ b/classes/class_multimesh.rst @@ -176,6 +176,8 @@ Property Descriptions Array containing each :ref:`Color` used by all instances of this mesh. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedColorArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -207,6 +209,8 @@ Custom AABB for this MultiMesh resource. Setting this manually prevents costly r Array containing each custom data value used by all instances of this mesh, as a :ref:`PackedColorArray`. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedColorArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -259,6 +263,8 @@ The looks of the individual instances can be modified using :ref:`set_instance_c Array containing each :ref:`Transform2D` value used by all instances of this mesh, as a :ref:`PackedVector2Array`. Each transform is divided into 3 :ref:`Vector2` values corresponding to the transforms' ``x``, ``y``, and ``origin``. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -273,6 +279,8 @@ Array containing each :ref:`Transform2D` value used by all in Array containing each :ref:`Transform3D` value used by all instances of this mesh, as a :ref:`PackedVector3Array`. Each transform is divided into 4 :ref:`Vector3` values corresponding to the transforms' ``x``, ``y``, ``z``, and ``origin``. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector3Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_multiplayerpeer.rst b/classes/class_multiplayerpeer.rst index a15e400ee..9da8b33e1 100644 --- a/classes/class_multiplayerpeer.rst +++ b/classes/class_multiplayerpeer.rst @@ -37,8 +37,6 @@ Tutorials - :doc:`High-level multiplayer <../tutorials/networking/high_level_multiplayer>` -- `WebRTC Signaling Demo `__ - .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationagent2d.rst b/classes/class_navigationagent2d.rst index 13c6cf32d..d8829b453 100644 --- a/classes/class_navigationagent2d.rst +++ b/classes/class_navigationagent2d.rst @@ -81,6 +81,10 @@ Properties +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------------------+ | :ref:`float` | :ref:`radius` | ``10.0`` | +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------------------+ + | :ref:`float` | :ref:`simplify_epsilon` | ``0.0`` | + +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------------------+ + | :ref:`bool` | :ref:`simplify_path` | ``false`` | + +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------------------+ | :ref:`float` | :ref:`target_desired_distance` | ``10.0`` | +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------------------+ | :ref:`Vector2` | :ref:`target_position` | ``Vector2(0, 0)`` | @@ -587,6 +591,42 @@ Does not affect normal pathfinding. To change an actor's pathfinding radius bake ---- +.. _class_NavigationAgent2D_property_simplify_epsilon: + +.. rst-class:: classref-property + +:ref:`float` **simplify_epsilon** = ``0.0`` + +.. rst-class:: classref-property-setget + +- |void| **set_simplify_epsilon**\ (\ value\: :ref:`float`\ ) +- :ref:`float` **get_simplify_epsilon**\ (\ ) + +The path simplification amount in worlds units. + +.. rst-class:: classref-item-separator + +---- + +.. _class_NavigationAgent2D_property_simplify_path: + +.. rst-class:: classref-property + +:ref:`bool` **simplify_path** = ``false`` + +.. rst-class:: classref-property-setget + +- |void| **set_simplify_path**\ (\ value\: :ref:`bool`\ ) +- :ref:`bool` **get_simplify_path**\ (\ ) + +If ``true`` a simplified version of the path will be returned with less critical path points removed. The simplification amount is controlled by :ref:`simplify_epsilon`. The simplification uses a variant of Ramer-Douglas-Peucker algorithm for curve point decimation. + +Path simplification can be helpful to mitigate various path following issues that can arise with certain agent types and script behaviors. E.g. "steering" agents or avoidance in "open fields". + +.. rst-class:: classref-item-separator + +---- + .. _class_NavigationAgent2D_property_target_desired_distance: .. rst-class:: classref-property diff --git a/classes/class_navigationagent3d.rst b/classes/class_navigationagent3d.rst index f863bf9ba..225c7813c 100644 --- a/classes/class_navigationagent3d.rst +++ b/classes/class_navigationagent3d.rst @@ -85,6 +85,10 @@ Properties +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------------------+ | :ref:`float` | :ref:`radius` | ``0.5`` | +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------------------+ + | :ref:`float` | :ref:`simplify_epsilon` | ``0.0`` | + +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------------------+ + | :ref:`bool` | :ref:`simplify_path` | ``false`` | + +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------------------+ | :ref:`float` | :ref:`target_desired_distance` | ``1.0`` | +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------------------+ | :ref:`Vector3` | :ref:`target_position` | ``Vector3(0, 0, 0)`` | @@ -627,6 +631,42 @@ Does not affect normal pathfinding. To change an actor's pathfinding radius bake ---- +.. _class_NavigationAgent3D_property_simplify_epsilon: + +.. rst-class:: classref-property + +:ref:`float` **simplify_epsilon** = ``0.0`` + +.. rst-class:: classref-property-setget + +- |void| **set_simplify_epsilon**\ (\ value\: :ref:`float`\ ) +- :ref:`float` **get_simplify_epsilon**\ (\ ) + +The path simplification amount in worlds units. + +.. rst-class:: classref-item-separator + +---- + +.. _class_NavigationAgent3D_property_simplify_path: + +.. rst-class:: classref-property + +:ref:`bool` **simplify_path** = ``false`` + +.. rst-class:: classref-property-setget + +- |void| **set_simplify_path**\ (\ value\: :ref:`bool`\ ) +- :ref:`bool` **get_simplify_path**\ (\ ) + +If ``true`` a simplified version of the path will be returned with less critical path points removed. The simplification amount is controlled by :ref:`simplify_epsilon`. The simplification uses a variant of Ramer-Douglas-Peucker algorithm for curve point decimation. + +Path simplification can be helpful to mitigate various path following issues that can arise with certain agent types and script behaviors. E.g. "steering" agents or avoidance in "open fields". + +.. rst-class:: classref-item-separator + +---- + .. _class_NavigationAgent3D_property_target_desired_distance: .. rst-class:: classref-property diff --git a/classes/class_navigationmesh.rst b/classes/class_navigationmesh.rst index a41d735ee..d652174bc 100644 --- a/classes/class_navigationmesh.rst +++ b/classes/class_navigationmesh.rst @@ -30,7 +30,7 @@ Tutorials - :doc:`Using NavigationMeshes <../tutorials/navigation/navigation_using_navigationmeshes>` -- `3D Navmesh Demo `__ +- `3D Navigation Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_navigationobstacle2d.rst b/classes/class_navigationobstacle2d.rst index 9e070561b..b4b3599f1 100644 --- a/classes/class_navigationobstacle2d.rst +++ b/classes/class_navigationobstacle2d.rst @@ -206,6 +206,8 @@ Sets the wanted velocity for the obstacle so other agent's can better predict th The outline vertices of the obstacle. If the vertices are winded in clockwise order agents will be pushed in by the obstacle, else they will be pushed out. Outlines can not be crossed or overlap. Should the vertices using obstacle be warped to a new position agent's can not predict this movement and may get trapped inside the obstacle. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_navigationobstacle3d.rst b/classes/class_navigationobstacle3d.rst index d3904f48a..25b55b1f8 100644 --- a/classes/class_navigationobstacle3d.rst +++ b/classes/class_navigationobstacle3d.rst @@ -246,6 +246,8 @@ Sets the wanted velocity for the obstacle so other agent's can better predict th The outline vertices of the obstacle. If the vertices are winded in clockwise order agents will be pushed in by the obstacle, else they will be pushed out. Outlines can not be crossed or overlap. Should the vertices using obstacle be warped to a new position agent's can not predict this movement and may get trapped inside the obstacle. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector3Array` for more details. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_navigationpathqueryparameters2d.rst b/classes/class_navigationpathqueryparameters2d.rst index c8ba2e996..27cb9f229 100644 --- a/classes/class_navigationpathqueryparameters2d.rst +++ b/classes/class_navigationpathqueryparameters2d.rst @@ -49,6 +49,10 @@ Properties +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-------------------+ | :ref:`PathfindingAlgorithm` | :ref:`pathfinding_algorithm` | ``0`` | +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-------------------+ + | :ref:`float` | :ref:`simplify_epsilon` | ``0.0`` | + +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-------------------+ + | :ref:`bool` | :ref:`simplify_path` | ``false`` | + +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-------------------+ | :ref:`Vector2` | :ref:`start_position` | ``Vector2(0, 0)`` | +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-------------------+ | :ref:`Vector2` | :ref:`target_position` | ``Vector2(0, 0)`` | @@ -247,6 +251,42 @@ The pathfinding algorithm used in the path query. ---- +.. _class_NavigationPathQueryParameters2D_property_simplify_epsilon: + +.. rst-class:: classref-property + +:ref:`float` **simplify_epsilon** = ``0.0`` + +.. rst-class:: classref-property-setget + +- |void| **set_simplify_epsilon**\ (\ value\: :ref:`float`\ ) +- :ref:`float` **get_simplify_epsilon**\ (\ ) + +The path simplification amount in worlds units. + +.. rst-class:: classref-item-separator + +---- + +.. _class_NavigationPathQueryParameters2D_property_simplify_path: + +.. rst-class:: classref-property + +:ref:`bool` **simplify_path** = ``false`` + +.. rst-class:: classref-property-setget + +- |void| **set_simplify_path**\ (\ value\: :ref:`bool`\ ) +- :ref:`bool` **get_simplify_path**\ (\ ) + +If ``true`` a simplified version of the path will be returned with less critical path points removed. The simplification amount is controlled by :ref:`simplify_epsilon`. The simplification uses a variant of Ramer-Douglas-Peucker algorithm for curve point decimation. + +Path simplification can be helpful to mitigate various path following issues that can arise with certain agent types and script behaviors. E.g. "steering" agents or avoidance in "open fields". + +.. rst-class:: classref-item-separator + +---- + .. _class_NavigationPathQueryParameters2D_property_start_position: .. rst-class:: classref-property diff --git a/classes/class_navigationpathqueryparameters3d.rst b/classes/class_navigationpathqueryparameters3d.rst index 434aa82c9..1c8c080f1 100644 --- a/classes/class_navigationpathqueryparameters3d.rst +++ b/classes/class_navigationpathqueryparameters3d.rst @@ -49,6 +49,10 @@ Properties +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+----------------------+ | :ref:`PathfindingAlgorithm` | :ref:`pathfinding_algorithm` | ``0`` | +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+----------------------+ + | :ref:`float` | :ref:`simplify_epsilon` | ``0.0`` | + +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+----------------------+ + | :ref:`bool` | :ref:`simplify_path` | ``false`` | + +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+----------------------+ | :ref:`Vector3` | :ref:`start_position` | ``Vector3(0, 0, 0)`` | +------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+----------------------+ | :ref:`Vector3` | :ref:`target_position` | ``Vector3(0, 0, 0)`` | @@ -247,6 +251,42 @@ The pathfinding algorithm used in the path query. ---- +.. _class_NavigationPathQueryParameters3D_property_simplify_epsilon: + +.. rst-class:: classref-property + +:ref:`float` **simplify_epsilon** = ``0.0`` + +.. rst-class:: classref-property-setget + +- |void| **set_simplify_epsilon**\ (\ value\: :ref:`float`\ ) +- :ref:`float` **get_simplify_epsilon**\ (\ ) + +The path simplification amount in worlds units. + +.. rst-class:: classref-item-separator + +---- + +.. _class_NavigationPathQueryParameters3D_property_simplify_path: + +.. rst-class:: classref-property + +:ref:`bool` **simplify_path** = ``false`` + +.. rst-class:: classref-property-setget + +- |void| **set_simplify_path**\ (\ value\: :ref:`bool`\ ) +- :ref:`bool` **get_simplify_path**\ (\ ) + +If ``true`` a simplified version of the path will be returned with less critical path points removed. The simplification amount is controlled by :ref:`simplify_epsilon`. The simplification uses a variant of Ramer-Douglas-Peucker algorithm for curve point decimation. + +Path simplification can be helpful to mitigate various path following issues that can arise with certain agent types and script behaviors. E.g. "steering" agents or avoidance in "open fields". + +.. rst-class:: classref-item-separator + +---- + .. _class_NavigationPathQueryParameters3D_property_start_position: .. rst-class:: classref-property diff --git a/classes/class_navigationpathqueryresult2d.rst b/classes/class_navigationpathqueryresult2d.rst index 36acd5000..9d81187ed 100644 --- a/classes/class_navigationpathqueryresult2d.rst +++ b/classes/class_navigationpathqueryresult2d.rst @@ -113,6 +113,8 @@ Property Descriptions 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 :ref:`NavigationServer2D.map_get_path`. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -130,6 +132,8 @@ The resulting path array from the navigation query. All path array positions are The ``ObjectID``\ s of the :ref:`Object`\ s which manage the regions and links each point of the path goes through. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt64Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -164,6 +168,8 @@ The :ref:`RID`\ s of the regions and links that each point of the pat The type of navigation primitive (region or link) that each point of the path goes through. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt32Array` for more details. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_navigationpathqueryresult3d.rst b/classes/class_navigationpathqueryresult3d.rst index 79ba4bd58..d01fe630b 100644 --- a/classes/class_navigationpathqueryresult3d.rst +++ b/classes/class_navigationpathqueryresult3d.rst @@ -113,6 +113,8 @@ Property Descriptions 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 :ref:`NavigationServer3D.map_get_path`. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector3Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -130,6 +132,8 @@ The resulting path array from the navigation query. All path array positions are The ``ObjectID``\ s of the :ref:`Object`\ s which manage the regions and links each point of the path goes through. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt64Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -164,6 +168,8 @@ The :ref:`RID`\ s of the regions and links that each point of the pat The type of navigation primitive (region or link) that each point of the path goes through. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt32Array` for more details. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_navigationpolygon.rst b/classes/class_navigationpolygon.rst index 4eea55a10..2838b3313 100644 --- a/classes/class_navigationpolygon.rst +++ b/classes/class_navigationpolygon.rst @@ -76,10 +76,10 @@ Adding vertices and polygon indices manually. Tutorials --------- -- `2D Navigation Demo `__ - - :doc:`Using NavigationMeshes <../tutorials/navigation/navigation_using_navigationmeshes>` +- `Navigation Polygon 2D Demo `__ + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationserver2d.rst b/classes/class_navigationserver2d.rst index ed157617c..635e0af56 100644 --- a/classes/class_navigationserver2d.rst +++ b/classes/class_navigationserver2d.rst @@ -42,10 +42,10 @@ This server keeps tracks of any call and executes them during the sync phase. Th Tutorials --------- -- `2D Navigation Demo `__ - - :doc:`Using NavigationServer <../tutorials/navigation/navigation_using_navigationservers>` +- `Navigation Polygon 2D Demo `__ + .. rst-class:: classref-reftable-group Methods @@ -299,6 +299,8 @@ Methods +-----------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | |void| | :ref:`set_debug_enabled`\ (\ enabled\: :ref:`bool`\ ) | +-----------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`PackedVector2Array` | :ref:`simplify_path`\ (\ path\: :ref:`PackedVector2Array`, epsilon\: :ref:`float`\ ) | + +-----------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -1826,6 +1828,20 @@ If ``enabled`` is ``true``, the navigation ``region`` will use edge connections If ``true`` enables debug mode on the NavigationServer. +.. rst-class:: classref-item-separator + +---- + +.. _class_NavigationServer2D_method_simplify_path: + +.. rst-class:: classref-method + +:ref:`PackedVector2Array` **simplify_path**\ (\ path\: :ref:`PackedVector2Array`, epsilon\: :ref:`float`\ ) + +Returns a simplified version of ``path`` with less critical path points removed. The simplification amount is in worlds units and controlled by ``epsilon``. The simplification uses a variant of Ramer-Douglas-Peucker algorithm for curve point decimation. + +Path simplification can be helpful to mitigate various path following issues that can arise with certain agent types and script behaviors. E.g. "steering" agents or avoidance in "open fields". + .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` diff --git a/classes/class_navigationserver3d.rst b/classes/class_navigationserver3d.rst index 28bd9edcb..c49395cf1 100644 --- a/classes/class_navigationserver3d.rst +++ b/classes/class_navigationserver3d.rst @@ -42,10 +42,10 @@ This server keeps tracks of any call and executes them during the sync phase. Th Tutorials --------- -- `3D Navmesh Demo `__ - - :doc:`Using NavigationServer <../tutorials/navigation/navigation_using_navigationservers>` +- `3D Navigation Demo `__ + .. rst-class:: classref-reftable-group Methods @@ -337,6 +337,8 @@ Methods +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | |void| | :ref:`set_debug_enabled`\ (\ enabled\: :ref:`bool`\ ) | +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`PackedVector3Array` | :ref:`simplify_path`\ (\ path\: :ref:`PackedVector3Array`, epsilon\: :ref:`float`\ ) | + +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -2197,6 +2199,20 @@ Control activation of this server. If ``true`` enables debug mode on the NavigationServer. +.. rst-class:: classref-item-separator + +---- + +.. _class_NavigationServer3D_method_simplify_path: + +.. rst-class:: classref-method + +:ref:`PackedVector3Array` **simplify_path**\ (\ path\: :ref:`PackedVector3Array`, epsilon\: :ref:`float`\ ) + +Returns a simplified version of ``path`` with less critical path points removed. The simplification amount is in worlds units and controlled by ``epsilon``. The simplification uses a variant of Ramer-Douglas-Peucker algorithm for curve point decimation. + +Path simplification can be helpful to mitigate various path following issues that can arise with certain agent types and script behaviors. E.g. "steering" agents or avoidance in "open fields". + .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` diff --git a/classes/class_node.rst b/classes/class_node.rst index ae0a57df8..789f8bf2d 100644 --- a/classes/class_node.rst +++ b/classes/class_node.rst @@ -253,7 +253,7 @@ Methods +------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | |void| | :ref:`reparent`\ (\ new_parent\: :ref:`Node`, keep_global_transform\: :ref:`bool` = true\ ) | +------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`replace_by`\ (\ node\: :ref:`Node`, keep_groups\: :ref:`bool` = false, keep_children\: :ref:`bool` = true\ ) | + | |void| | :ref:`replace_by`\ (\ node\: :ref:`Node`, keep_groups\: :ref:`bool` = false\ ) | +------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | |void| | :ref:`request_ready`\ (\ ) | +------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -1986,7 +1986,7 @@ Fetches a node. The :ref:`NodePath` can either be a relative pat \ **Example:** Assume this method is called from the Character node, inside the following tree: -:: +.. code:: text ┖╴root ┠╴Character (you are here!) @@ -2191,9 +2191,9 @@ Returns the :ref:`SceneTree` that contains this node. If this n Returns the tree as a :ref:`String`. Used mainly for debugging purposes. This version displays the path relative to the current node, and is good for copy/pasting into the :ref:`get_node` function. It also can be used in game UI/UX. -\ **Example output:**\ +May print, for example: -:: +.. code:: text TheGame TheGame/Menu @@ -2214,9 +2214,9 @@ Returns the tree as a :ref:`String`. Used mainly for debugging pur Similar to :ref:`get_tree_string`, this returns the tree as a :ref:`String`. This version displays a more graphical representation similar to what is displayed in the Scene Dock. It is useful for inspecting larger trees. -\ **Example output:**\ +May print, for example: -:: +.. code:: text ┖╴TheGame ┠╴Menu @@ -2561,9 +2561,9 @@ Prints all orphan nodes (nodes outside the :ref:`SceneTree`). U Prints the node and its children to the console, recursively. The node does not have to be inside the tree. This method outputs :ref:`NodePath`\ s relative to this node, and is good for copy/pasting into :ref:`get_node`. See also :ref:`print_tree_pretty`. -\ **Example output:**\ +May print, for example: -:: +.. code:: text . Menu @@ -2584,9 +2584,9 @@ Prints the node and its children to the console, recursively. The node does not Prints the node and its children to the console, recursively. The node does not have to be inside the tree. Similar to :ref:`print_tree`, but the graphical representation looks like what is displayed in the editor's Scene dock. It is useful for inspecting larger trees. -\ **Example output:**\ +May print, for example: -:: +.. code:: text ┖╴TheGame ┠╴Menu @@ -2685,9 +2685,9 @@ If ``keep_global_transform`` is ``true``, the node's global transform will be pr .. rst-class:: classref-method -|void| **replace_by**\ (\ node\: :ref:`Node`, keep_groups\: :ref:`bool` = false, keep_children\: :ref:`bool` = true\ ) +|void| **replace_by**\ (\ node\: :ref:`Node`, keep_groups\: :ref:`bool` = false\ ) -Replaces this node by the given ``node``. If ``keep_children`` is ``true`` all children of this node are moved to ``node``. +Replaces this node by the given ``node``. All children of this node are moved to ``node``. If ``keep_groups`` is ``true``, the ``node`` is added to the same groups that the replaced node is in (see :ref:`add_to_group`). diff --git a/classes/class_nodepath.rst b/classes/class_nodepath.rst index d25c1caf2..2355f4877 100644 --- a/classes/class_nodepath.rst +++ b/classes/class_nodepath.rst @@ -66,7 +66,7 @@ See also :ref:`StringName`, which is a similar type designed f Tutorials --------- -- `2D Role Playing Game Demo `__ +- `2D Role Playing Game (RPG) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_object.rst b/classes/class_object.rst index 57c5750ec..e7c77c835 100644 --- a/classes/class_object.rst +++ b/classes/class_object.rst @@ -989,7 +989,7 @@ While all options have the same outcome (``button``'s :ref:`BaseButton.button_do The syntax to bind parameters is through :ref:`Callable.bind`, which returns a copy of the :ref:`Callable` with its parameters bound. -When calling :ref:`emit_signal`, the signal parameters can be also passed. The examples below show the relationship between these signal parameters and bound parameters. +When calling :ref:`emit_signal` or :ref:`Signal.emit`, the signal parameters can be also passed. The examples below show the relationship between these signal parameters and bound parameters. .. tabs:: @@ -1003,7 +1003,7 @@ When calling :ref:`emit_signal`, the signal par player.hit.connect(_on_player_hit.bind("sword", 100)) # Parameters added when emitting the signal are passed first. - player.emit_signal("hit", "Dark lord", 5) + player.hit.emit("Dark lord", 5) # We pass two arguments when emitting (`hit_by`, `level`), # and bind two more arguments when connecting (`weapon_type`, `damage`). diff --git a/classes/class_occluderpolygon2d.rst b/classes/class_occluderpolygon2d.rst index 0784c6893..526c0d6ed 100644 --- a/classes/class_occluderpolygon2d.rst +++ b/classes/class_occluderpolygon2d.rst @@ -132,7 +132,7 @@ The culling mode to use. A :ref:`Vector2` array with the index for polygon's vertices positions. -\ **Note:** The returned value is a copy of the underlying array, rather than a reference. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_oggpacketsequence.rst b/classes/class_oggpacketsequence.rst index 7a8f1cec8..66230031e 100644 --- a/classes/class_oggpacketsequence.rst +++ b/classes/class_oggpacketsequence.rst @@ -71,6 +71,8 @@ Property Descriptions Contains the granule positions for each page in this packet sequence. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt64Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_openxraction.rst b/classes/class_openxraction.rst index 26459cd09..23da5b6e0 100644 --- a/classes/class_openxraction.rst +++ b/classes/class_openxraction.rst @@ -150,6 +150,8 @@ The localized description of this action. A collections of toplevel paths to which this action can be bound. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` diff --git a/classes/class_openxrcompositionlayer.rst b/classes/class_openxrcompositionlayer.rst index ab30aab90..5b311b97a 100644 --- a/classes/class_openxrcompositionlayer.rst +++ b/classes/class_openxrcompositionlayer.rst @@ -49,9 +49,11 @@ Methods .. table:: :widths: auto - +-------------------------+-------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`is_natively_supported`\ (\ ) |const| | - +-------------------------+-------------------------------------------------------------------------------------------------------+ + +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Vector2` | :ref:`intersects_ray`\ (\ origin\: :ref:`Vector3`, direction\: :ref:`Vector3`\ ) |const| | + +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_natively_supported`\ (\ ) |const| | + +-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -122,6 +124,20 @@ The sort order for this composition layer. Higher numbers will be shown in front Method Descriptions ------------------- +.. _class_OpenXRCompositionLayer_method_intersects_ray: + +.. rst-class:: classref-method + +:ref:`Vector2` **intersects_ray**\ (\ origin\: :ref:`Vector3`, direction\: :ref:`Vector3`\ ) |const| + +Returns UV coordinates where the given ray intersects with the composition layer. ``origin`` and ``direction`` must be in global space. + +Returns ``Vector2(-1.0, -1.0)`` if the ray doesn't intersect. + +.. rst-class:: classref-item-separator + +---- + .. _class_OpenXRCompositionLayer_method_is_natively_supported: .. rst-class:: classref-method diff --git a/classes/class_openxrextensionwrapperextension.rst b/classes/class_openxrextensionwrapperextension.rst index c26df4efb..a56a5d86f 100644 --- a/classes/class_openxrextensionwrapperextension.rst +++ b/classes/class_openxrextensionwrapperextension.rst @@ -29,65 +29,73 @@ Methods .. table:: :widths: auto - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`_get_composition_layer`\ (\ index\: :ref:`int`\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`_get_composition_layer_count`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`_get_composition_layer_order`\ (\ index\: :ref:`int`\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Dictionary` | :ref:`_get_requested_extensions`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`PackedStringArray` | :ref:`_get_suggested_tracker_names`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_before_instance_created`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`_on_event_polled`\ (\ event\: ``const void*``\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_instance_created`\ (\ instance\: :ref:`int`\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_instance_destroyed`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_pre_render`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_process`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_register_metadata`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_session_created`\ (\ session\: :ref:`int`\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_session_destroyed`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_state_exiting`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_state_focused`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_state_idle`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_state_loss_pending`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_state_ready`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_state_stopping`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_state_synchronized`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`_on_state_visible`\ (\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`_set_hand_joint_locations_and_get_next_pointer`\ (\ hand_index\: :ref:`int`, next_pointer\: ``void*``\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`_set_instance_create_info_and_get_next_pointer`\ (\ next_pointer\: ``void*``\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`_set_session_create_and_get_next_pointer`\ (\ next_pointer\: ``void*``\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`_set_swapchain_create_info_and_get_next_pointer`\ (\ next_pointer\: ``void*``\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`_set_system_properties_and_get_next_pointer`\ (\ next_pointer\: ``void*``\ ) |virtual| | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`OpenXRAPIExtension` | :ref:`get_openxr_api`\ (\ ) | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | |void| | :ref:`register_extension_wrapper`\ (\ ) | - +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`_get_composition_layer`\ (\ index\: :ref:`int`\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`_get_composition_layer_count`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`_get_composition_layer_order`\ (\ index\: :ref:`int`\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Dictionary` | :ref:`_get_requested_extensions`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`PackedStringArray` | :ref:`_get_suggested_tracker_names`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Array`\[:ref:`Dictionary`\] | :ref:`_get_viewport_composition_layer_extension_properties`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Dictionary` | :ref:`_get_viewport_composition_layer_extension_property_defaults`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_before_instance_created`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`_on_event_polled`\ (\ event\: ``const void*``\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_instance_created`\ (\ instance\: :ref:`int`\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_instance_destroyed`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_pre_render`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_process`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_register_metadata`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_session_created`\ (\ session\: :ref:`int`\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_session_destroyed`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_state_exiting`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_state_focused`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_state_idle`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_state_loss_pending`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_state_ready`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_state_stopping`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_state_synchronized`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_state_visible`\ (\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`_on_viewport_composition_layer_destroyed`\ (\ layer\: ``const void*``\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`_set_hand_joint_locations_and_get_next_pointer`\ (\ hand_index\: :ref:`int`, next_pointer\: ``void*``\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`_set_instance_create_info_and_get_next_pointer`\ (\ next_pointer\: ``void*``\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`_set_session_create_and_get_next_pointer`\ (\ next_pointer\: ``void*``\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`_set_swapchain_create_info_and_get_next_pointer`\ (\ next_pointer\: ``void*``\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`_set_system_properties_and_get_next_pointer`\ (\ next_pointer\: ``void*``\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`_set_viewport_composition_layer_and_get_next_pointer`\ (\ layer\: ``const void*``, property_values\: :ref:`Dictionary`, next_pointer\: ``void*``\ ) |virtual| | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`OpenXRAPIExtension` | :ref:`get_openxr_api`\ (\ ) | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`register_extension_wrapper`\ (\ ) | + +------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -168,6 +176,30 @@ Returns a :ref:`PackedStringArray` of positional tracke ---- +.. _class_OpenXRExtensionWrapperExtension_private_method__get_viewport_composition_layer_extension_properties: + +.. rst-class:: classref-method + +:ref:`Array`\[:ref:`Dictionary`\] **_get_viewport_composition_layer_extension_properties**\ (\ ) |virtual| + +Gets an array of :ref:`Dictionary`\ s that represent properties, just like :ref:`Object._get_property_list`, that will be added to :ref:`OpenXRCompositionLayer` nodes. + +.. rst-class:: classref-item-separator + +---- + +.. _class_OpenXRExtensionWrapperExtension_private_method__get_viewport_composition_layer_extension_property_defaults: + +.. rst-class:: classref-method + +:ref:`Dictionary` **_get_viewport_composition_layer_extension_property_defaults**\ (\ ) |virtual| + +Gets a :ref:`Dictionary` containing the default values for the properties returned by :ref:`_get_viewport_composition_layer_extension_properties`. + +.. rst-class:: classref-item-separator + +---- + .. _class_OpenXRExtensionWrapperExtension_private_method__on_before_instance_created: .. rst-class:: classref-method @@ -374,6 +406,20 @@ Called when the OpenXR session state is changed to visible. This means OpenXR is ---- +.. _class_OpenXRExtensionWrapperExtension_private_method__on_viewport_composition_layer_destroyed: + +.. rst-class:: classref-method + +|void| **_on_viewport_composition_layer_destroyed**\ (\ layer\: ``const void*``\ ) |virtual| + +Called when a composition layer created via :ref:`OpenXRCompositionLayer` is destroyed. + +\ ``layer`` is a pointer to an ``XrCompositionLayerBaseHeader`` struct. + +.. rst-class:: classref-item-separator + +---- + .. _class_OpenXRExtensionWrapperExtension_private_method__set_hand_joint_locations_and_get_next_pointer: .. rst-class:: classref-method @@ -434,6 +480,22 @@ Adds additional data structures when interogating OpenXR system abilities. ---- +.. _class_OpenXRExtensionWrapperExtension_private_method__set_viewport_composition_layer_and_get_next_pointer: + +.. rst-class:: classref-method + +:ref:`int` **_set_viewport_composition_layer_and_get_next_pointer**\ (\ layer\: ``const void*``, property_values\: :ref:`Dictionary`, next_pointer\: ``void*``\ ) |virtual| + +Adds additional data structures to composition layers created by :ref:`OpenXRCompositionLayer`. + +\ ``property_values`` contains the values of the properties returned by :ref:`_get_viewport_composition_layer_extension_properties`. + +\ ``layer`` is a pointer to an ``XrCompositionLayerBaseHeader`` struct. + +.. rst-class:: classref-item-separator + +---- + .. _class_OpenXRExtensionWrapperExtension_method_get_openxr_api: .. rst-class:: classref-method diff --git a/classes/class_openxrinterface.rst b/classes/class_openxrinterface.rst index 1a3f478ee..3d03af3e2 100644 --- a/classes/class_openxrinterface.rst +++ b/classes/class_openxrinterface.rst @@ -111,6 +111,20 @@ Informs the user queued a recenter of the player position. ---- +.. _class_OpenXRInterface_signal_refresh_rate_changed: + +.. rst-class:: classref-signal + +**refresh_rate_changed**\ (\ refresh_rate\: :ref:`float`\ ) + +Informs the user the HMD refresh rate has changed. + +\ **Node:** Only emitted if XR runtime supports the refresh rate extension. + +.. rst-class:: classref-item-separator + +---- + .. _class_OpenXRInterface_signal_session_begun: .. rst-class:: classref-signal diff --git a/classes/class_openxripbinding.rst b/classes/class_openxripbinding.rst index 159c821b1..aa1500651 100644 --- a/classes/class_openxripbinding.rst +++ b/classes/class_openxripbinding.rst @@ -92,6 +92,8 @@ Property Descriptions Paths that define the inputs or outputs bound on the device. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_os.rst b/classes/class_os.rst index bcbc5e8d2..9145ec092 100644 --- a/classes/class_os.rst +++ b/classes/class_os.rst @@ -28,7 +28,7 @@ The **OS** class wraps the most common functionalities for communicating with th Tutorials --------- -- `OS Test Demo `__ +- `Operating System Testing Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_packedbytearray.rst b/classes/class_packedbytearray.rst index c0f7dd670..c5450db1b 100644 --- a/classes/class_packedbytearray.rst +++ b/classes/class_packedbytearray.rst @@ -21,6 +21,8 @@ An array specifically designed to hold bytes. Packs data tightly, so it saves me \ **PackedByteArray** also provides methods to encode/decode various types to/from bytes. The way values are encoded is an implementation detail and shouldn't be relied upon when interacting with external apps. +\ **Note:** Packed arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use :ref:`duplicate`. This is *not* the case for built-in properties and methods. The returned packed array of these are a copies, and changing it will *not* affect the original value. To update a built-in property you need to modify the returned array, and then assign it to the property again. + .. note:: There are notable differences when using this API with C#. See :ref:`doc_c_sharp_differences` for more information. diff --git a/classes/class_packedcolorarray.rst b/classes/class_packedcolorarray.rst index e3b1eb2c2..0f9530ad8 100644 --- a/classes/class_packedcolorarray.rst +++ b/classes/class_packedcolorarray.rst @@ -19,6 +19,10 @@ Description An array specifically designed to hold :ref:`Color`. Packs data tightly, so it saves memory for large array sizes. +\ **Differences between packed arrays, typed arrays, and untyped arrays:** Packed arrays are generally faster to iterate on and modify compared to a typed array of the same type (e.g. **PackedColorArray** versus ``Array[Color]``). Also, packed arrays consume less memory. As a downside, packed arrays are less flexible as they don't offer as many convenience methods such as :ref:`Array.map`. Typed arrays are in turn faster to iterate on and modify than untyped arrays. + +\ **Note:** Packed arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use :ref:`duplicate`. This is *not* the case for built-in properties and methods. The returned packed array of these are a copies, and changing it will *not* affect the original value. To update a built-in property you need to modify the returned array, and then assign it to the property again. + .. note:: There are notable differences when using this API with C#. See :ref:`doc_c_sharp_differences` for more information. diff --git a/classes/class_packedfloat32array.rst b/classes/class_packedfloat32array.rst index 8c38e084b..791c171d8 100644 --- a/classes/class_packedfloat32array.rst +++ b/classes/class_packedfloat32array.rst @@ -21,6 +21,8 @@ An array specifically designed to hold 32-bit floating-point values (float). Pac If you need to pack 64-bit floats tightly, see :ref:`PackedFloat64Array`. +\ **Note:** Packed arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use :ref:`duplicate`. This is *not* the case for built-in properties and methods. The returned packed array of these are a copies, and changing it will *not* affect the original value. To update a built-in property you need to modify the returned array, and then assign it to the property again. + .. note:: There are notable differences when using this API with C#. See :ref:`doc_c_sharp_differences` for more information. diff --git a/classes/class_packedfloat64array.rst b/classes/class_packedfloat64array.rst index 25bd8bc1d..c47d8a991 100644 --- a/classes/class_packedfloat64array.rst +++ b/classes/class_packedfloat64array.rst @@ -21,6 +21,10 @@ An array specifically designed to hold 64-bit floating-point values (double). Pa If you only need to pack 32-bit floats tightly, see :ref:`PackedFloat32Array` for a more memory-friendly alternative. +\ **Differences between packed arrays, typed arrays, and untyped arrays:** Packed arrays are generally faster to iterate on and modify compared to a typed array of the same type (e.g. **PackedFloat64Array** versus ``Array[float]``). Also, packed arrays consume less memory. As a downside, packed arrays are less flexible as they don't offer as many convenience methods such as :ref:`Array.map`. Typed arrays are in turn faster to iterate on and modify than untyped arrays. + +\ **Note:** Packed arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use :ref:`duplicate`. This is *not* the case for built-in properties and methods. The returned packed array of these are a copies, and changing it will *not* affect the original value. To update a built-in property you need to modify the returned array, and then assign it to the property again. + .. note:: There are notable differences when using this API with C#. See :ref:`doc_c_sharp_differences` for more information. diff --git a/classes/class_packedint32array.rst b/classes/class_packedint32array.rst index 024f6d9cd..3799759f6 100644 --- a/classes/class_packedint32array.rst +++ b/classes/class_packedint32array.rst @@ -21,6 +21,8 @@ An array specifically designed to hold 32-bit integer values. Packs data tightly \ **Note:** This type stores signed 32-bit integers, which means it can take values in the interval ``[-2^31, 2^31 - 1]``, i.e. ``[-2147483648, 2147483647]``. Exceeding those bounds will wrap around. In comparison, :ref:`int` uses signed 64-bit integers which can hold much larger values. If you need to pack 64-bit integers tightly, see :ref:`PackedInt64Array`. +\ **Note:** Packed arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use :ref:`duplicate`. This is *not* the case for built-in properties and methods. The returned packed array of these are a copies, and changing it will *not* affect the original value. To update a built-in property you need to modify the returned array, and then assign it to the property again. + .. note:: There are notable differences when using this API with C#. See :ref:`doc_c_sharp_differences` for more information. diff --git a/classes/class_packedint64array.rst b/classes/class_packedint64array.rst index 692e9c251..8291b5ea7 100644 --- a/classes/class_packedint64array.rst +++ b/classes/class_packedint64array.rst @@ -21,6 +21,10 @@ An array specifically designed to hold 64-bit integer values. Packs data tightly \ **Note:** This type stores signed 64-bit integers, which means it can take values in the interval ``[-2^63, 2^63 - 1]``, i.e. ``[-9223372036854775808, 9223372036854775807]``. Exceeding those bounds will wrap around. If you only need to pack 32-bit integers tightly, see :ref:`PackedInt32Array` for a more memory-friendly alternative. +\ **Differences between packed arrays, typed arrays, and untyped arrays:** Packed arrays are generally faster to iterate on and modify compared to a typed array of the same type (e.g. :ref:`PackedInt32Array` versus ``Array[int]``). Also, packed arrays consume less memory. As a downside, packed arrays are less flexible as they don't offer as many convenience methods such as :ref:`Array.map`. Typed arrays are in turn faster to iterate on and modify than untyped arrays. + +\ **Note:** Packed arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use :ref:`duplicate`. This is *not* the case for built-in properties and methods. The returned packed array of these are a copies, and changing it will *not* affect the original value. To update a built-in property you need to modify the returned array, and then assign it to the property again. + .. note:: There are notable differences when using this API with C#. See :ref:`doc_c_sharp_differences` for more information. diff --git a/classes/class_packedscene.rst b/classes/class_packedscene.rst index 4ced4178c..273dc27a0 100644 --- a/classes/class_packedscene.rst +++ b/classes/class_packedscene.rst @@ -106,7 +106,7 @@ Can be used to save a node to a file. When saving, the node as well as all the n Tutorials --------- -- `2D Role Playing Game Demo `__ +- `2D Role Playing Game (RPG) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_packedstringarray.rst b/classes/class_packedstringarray.rst index 770d7e0d3..f91f6aa38 100644 --- a/classes/class_packedstringarray.rst +++ b/classes/class_packedstringarray.rst @@ -27,6 +27,10 @@ If you want to join the strings in the array, use :ref:`String.join`. Typed arrays are in turn faster to iterate on and modify than untyped arrays. + +\ **Note:** Packed arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use :ref:`duplicate`. This is *not* the case for built-in properties and methods. The returned packed array of these are a copies, and changing it will *not* affect the original value. To update a built-in property you need to modify the returned array, and then assign it to the property again. + .. note:: There are notable differences when using this API with C#. See :ref:`doc_c_sharp_differences` for more information. @@ -36,7 +40,7 @@ If you want to join the strings in the array, use :ref:`String.join`__ +- `Operating System Testing Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_packedvector2array.rst b/classes/class_packedvector2array.rst index 4954e2fc3..8c5b3741b 100644 --- a/classes/class_packedvector2array.rst +++ b/classes/class_packedvector2array.rst @@ -19,6 +19,10 @@ Description An array specifically designed to hold :ref:`Vector2`. Packs data tightly, so it saves memory for large array sizes. +\ **Differences between packed arrays, typed arrays, and untyped arrays:** Packed arrays are generally faster to iterate on and modify compared to a typed array of the same type (e.g. :ref:`PackedVector3Array` versus ``Array[Vector2]``). Also, packed arrays consume less memory. As a downside, packed arrays are less flexible as they don't offer as many convenience methods such as :ref:`Array.map`. Typed arrays are in turn faster to iterate on and modify than untyped arrays. + +\ **Note:** Packed arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use :ref:`duplicate`. This is *not* the case for built-in properties and methods. The returned packed array of these are a copies, and changing it will *not* affect the original value. To update a built-in property you need to modify the returned array, and then assign it to the property again. + .. note:: There are notable differences when using this API with C#. See :ref:`doc_c_sharp_differences` for more information. @@ -28,7 +32,7 @@ An array specifically designed to hold :ref:`Vector2`. Packs data Tutorials --------- -- `2D Navigation Astar Demo `__ +- `Grid-based Navigation with AStarGrid2D Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_packedvector3array.rst b/classes/class_packedvector3array.rst index 93b983409..bd4d0b4da 100644 --- a/classes/class_packedvector3array.rst +++ b/classes/class_packedvector3array.rst @@ -19,6 +19,10 @@ Description An array specifically designed to hold :ref:`Vector3`. Packs data tightly, so it saves memory for large array sizes. +\ **Differences between packed arrays, typed arrays, and untyped arrays:** Packed arrays are generally faster to iterate on and modify compared to a typed array of the same type (e.g. **PackedVector3Array** versus ``Array[Vector3]``). Also, packed arrays consume less memory. As a downside, packed arrays are less flexible as they don't offer as many convenience methods such as :ref:`Array.map`. Typed arrays are in turn faster to iterate on and modify than untyped arrays. + +\ **Note:** Packed arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use :ref:`duplicate`. This is *not* the case for built-in properties and methods. The returned packed array of these are a copies, and changing it will *not* affect the original value. To update a built-in property you need to modify the returned array, and then assign it to the property again. + .. note:: There are notable differences when using this API with C#. See :ref:`doc_c_sharp_differences` for more information. diff --git a/classes/class_panel.rst b/classes/class_panel.rst index 119f7432e..90948fc50 100644 --- a/classes/class_panel.rst +++ b/classes/class_panel.rst @@ -26,11 +26,9 @@ Description Tutorials --------- -- `2D Role Playing Game Demo `__ +- `2D Role Playing Game (RPG) Demo `__ -- `2D Finite State Machine Demo `__ - -- `3D Inverse Kinematics Demo `__ +- `Hierarchical Finite State Machine Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_panelcontainer.rst b/classes/class_panelcontainer.rst index a96efac04..04de2f1c9 100644 --- a/classes/class_panelcontainer.rst +++ b/classes/class_panelcontainer.rst @@ -30,7 +30,7 @@ Tutorials - :doc:`Using Containers <../tutorials/ui/gui_containers>` -- `2D Role Playing Game Demo `__ +- `2D Role Playing Game (RPG) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_physicalbone3d.rst b/classes/class_physicalbone3d.rst index 5a1b5c1ee..da5c4eea4 100644 --- a/classes/class_physicalbone3d.rst +++ b/classes/class_physicalbone3d.rst @@ -327,7 +327,9 @@ If ``true``, the body is deactivated when there is no movement, so it will not t - |void| **set_use_custom_integrator**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **is_using_custom_integrator**\ (\ ) -If ``true``, internal force integration will be disabled (like gravity or air friction) for this body. Other than collision response, the body will only move as determined by the :ref:`_integrate_forces` function, if defined. +If ``true``, the standard force integration (like gravity or damping) will be disabled for this body. Other than collision response, the body will only move as determined by the :ref:`_integrate_forces` method, if that virtual method is overridden. + +Setting this property will call the method :ref:`PhysicsServer3D.body_set_omit_force_integration` internally. .. rst-class:: classref-item-separator @@ -499,7 +501,7 @@ Method Descriptions |void| **_integrate_forces**\ (\ state\: :ref:`PhysicsDirectBodyState3D`\ ) |virtual| -Called during physics processing, allowing you to read and safely modify the simulation state for the object. By default, it works in addition to the usual physics behavior, but the :ref:`custom_integrator` property allows you to disable the default behavior and do fully custom force integration for a body. +Called during physics processing, allowing you to read and safely modify the simulation state for the object. By default, it is called before the standard force integration, but the :ref:`custom_integrator` property allows you to disable the standard force integration and do fully custom force integration for a body. .. rst-class:: classref-item-separator diff --git a/classes/class_physicsdirectbodystate2d.rst b/classes/class_physicsdirectbodystate2d.rst index 9166dde02..3e6349fb3 100644 --- a/classes/class_physicsdirectbodystate2d.rst +++ b/classes/class_physicsdirectbodystate2d.rst @@ -676,7 +676,7 @@ Returns the body's velocity at the given relative position, including both trans |void| **integrate_forces**\ (\ ) -Calls the built-in force integration code. +Updates the body's linear and angular velocity by applying gravity and damping for the equivalent of one physics tick. .. rst-class:: classref-item-separator diff --git a/classes/class_physicsdirectbodystate2dextension.rst b/classes/class_physicsdirectbodystate2dextension.rst index 55eaaba6f..27909ea6c 100644 --- a/classes/class_physicsdirectbodystate2dextension.rst +++ b/classes/class_physicsdirectbodystate2dextension.rst @@ -136,9 +136,7 @@ Method Descriptions |void| **_add_constant_central_force**\ (\ force\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.add_constant_central_force`. .. rst-class:: classref-item-separator @@ -150,9 +148,7 @@ Method Descriptions |void| **_add_constant_force**\ (\ force\: :ref:`Vector2`, position\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.add_constant_force`. .. rst-class:: classref-item-separator @@ -164,9 +160,7 @@ Method Descriptions |void| **_add_constant_torque**\ (\ torque\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.add_constant_torque`. .. rst-class:: classref-item-separator @@ -178,9 +172,7 @@ Method Descriptions |void| **_apply_central_force**\ (\ force\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.apply_central_force`. .. rst-class:: classref-item-separator @@ -192,9 +184,7 @@ Method Descriptions |void| **_apply_central_impulse**\ (\ impulse\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.apply_central_impulse`. .. rst-class:: classref-item-separator @@ -206,9 +196,7 @@ Method Descriptions |void| **_apply_force**\ (\ force\: :ref:`Vector2`, position\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.apply_force`. .. rst-class:: classref-item-separator @@ -220,9 +208,7 @@ Method Descriptions |void| **_apply_impulse**\ (\ impulse\: :ref:`Vector2`, position\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.apply_impulse`. .. rst-class:: classref-item-separator @@ -234,9 +220,7 @@ Method Descriptions |void| **_apply_torque**\ (\ torque\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.apply_torque`. .. rst-class:: classref-item-separator @@ -248,9 +232,7 @@ Method Descriptions |void| **_apply_torque_impulse**\ (\ impulse\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.apply_torque_impulse`. .. rst-class:: classref-item-separator @@ -262,9 +244,7 @@ Method Descriptions :ref:`float` **_get_angular_velocity**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.angular_velocity` and its respective getter. .. rst-class:: classref-item-separator @@ -276,9 +256,7 @@ Method Descriptions :ref:`Vector2` **_get_center_of_mass**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.center_of_mass` and its respective getter. .. rst-class:: classref-item-separator @@ -290,9 +268,7 @@ Method Descriptions :ref:`Vector2` **_get_center_of_mass_local**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.center_of_mass_local` and its respective getter. .. rst-class:: classref-item-separator @@ -304,9 +280,7 @@ Method Descriptions :ref:`Vector2` **_get_constant_force**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_constant_force`. .. rst-class:: classref-item-separator @@ -318,9 +292,7 @@ Method Descriptions :ref:`float` **_get_constant_torque**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_constant_torque`. .. rst-class:: classref-item-separator @@ -332,9 +304,7 @@ Method Descriptions :ref:`RID` **_get_contact_collider**\ (\ contact_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_collider`. .. rst-class:: classref-item-separator @@ -346,9 +316,7 @@ Method Descriptions :ref:`int` **_get_contact_collider_id**\ (\ contact_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_collider_id`. .. rst-class:: classref-item-separator @@ -360,9 +328,7 @@ Method Descriptions :ref:`Object` **_get_contact_collider_object**\ (\ contact_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_collider_object`. .. rst-class:: classref-item-separator @@ -374,9 +340,7 @@ Method Descriptions :ref:`Vector2` **_get_contact_collider_position**\ (\ contact_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_collider_position`. .. rst-class:: classref-item-separator @@ -388,9 +352,7 @@ Method Descriptions :ref:`int` **_get_contact_collider_shape**\ (\ contact_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_collider_shape`. .. rst-class:: classref-item-separator @@ -402,9 +364,7 @@ Method Descriptions :ref:`Vector2` **_get_contact_collider_velocity_at_position**\ (\ contact_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_collider_velocity_at_position`. .. rst-class:: classref-item-separator @@ -416,9 +376,7 @@ Method Descriptions :ref:`int` **_get_contact_count**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_count`. .. rst-class:: classref-item-separator @@ -430,9 +388,7 @@ Method Descriptions :ref:`Vector2` **_get_contact_impulse**\ (\ contact_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_impulse`. .. rst-class:: classref-item-separator @@ -444,9 +400,7 @@ Method Descriptions :ref:`Vector2` **_get_contact_local_normal**\ (\ contact_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_local_normal`. .. rst-class:: classref-item-separator @@ -458,9 +412,7 @@ Method Descriptions :ref:`Vector2` **_get_contact_local_position**\ (\ contact_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_local_position`. .. rst-class:: classref-item-separator @@ -472,9 +424,7 @@ Method Descriptions :ref:`int` **_get_contact_local_shape**\ (\ contact_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_local_shape`. .. rst-class:: classref-item-separator @@ -486,9 +436,7 @@ Method Descriptions :ref:`Vector2` **_get_contact_local_velocity_at_position**\ (\ contact_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_contact_local_velocity_at_position`. .. rst-class:: classref-item-separator @@ -500,9 +448,7 @@ Method Descriptions :ref:`float` **_get_inverse_inertia**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.inverse_inertia` and its respective getter. .. rst-class:: classref-item-separator @@ -514,9 +460,7 @@ Method Descriptions :ref:`float` **_get_inverse_mass**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.inverse_mass` and its respective getter. .. rst-class:: classref-item-separator @@ -528,9 +472,7 @@ Method Descriptions :ref:`Vector2` **_get_linear_velocity**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.linear_velocity` and its respective getter. .. rst-class:: classref-item-separator @@ -542,9 +484,7 @@ Method Descriptions :ref:`PhysicsDirectSpaceState2D` **_get_space_state**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_space_state`. .. rst-class:: classref-item-separator @@ -556,9 +496,7 @@ Method Descriptions :ref:`float` **_get_step**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.step` and its respective getter. .. rst-class:: classref-item-separator @@ -570,9 +508,7 @@ Method Descriptions :ref:`float` **_get_total_angular_damp**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.total_angular_damp` and its respective getter. .. rst-class:: classref-item-separator @@ -584,9 +520,7 @@ Method Descriptions :ref:`Vector2` **_get_total_gravity**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.total_gravity` and its respective getter. .. rst-class:: classref-item-separator @@ -598,9 +532,7 @@ Method Descriptions :ref:`float` **_get_total_linear_damp**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.total_linear_damp` and its respective getter. .. rst-class:: classref-item-separator @@ -612,9 +544,7 @@ Method Descriptions :ref:`Transform2D` **_get_transform**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.transform` and its respective getter. .. rst-class:: classref-item-separator @@ -626,9 +556,7 @@ Method Descriptions :ref:`Vector2` **_get_velocity_at_local_position**\ (\ local_position\: :ref:`Vector2`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.get_velocity_at_local_position`. .. rst-class:: classref-item-separator @@ -640,9 +568,7 @@ Method Descriptions |void| **_integrate_forces**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.integrate_forces`. .. rst-class:: classref-item-separator @@ -654,9 +580,7 @@ Method Descriptions :ref:`bool` **_is_sleeping**\ (\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.sleeping` and its respective getter. .. rst-class:: classref-item-separator @@ -668,9 +592,7 @@ Method Descriptions |void| **_set_angular_velocity**\ (\ velocity\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.angular_velocity` and its respective setter. .. rst-class:: classref-item-separator @@ -682,9 +604,7 @@ Method Descriptions |void| **_set_constant_force**\ (\ force\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.set_constant_force`. .. rst-class:: classref-item-separator @@ -696,9 +616,7 @@ Method Descriptions |void| **_set_constant_torque**\ (\ torque\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsDirectBodyState2D.set_constant_torque`. .. rst-class:: classref-item-separator @@ -710,9 +628,7 @@ Method Descriptions |void| **_set_linear_velocity**\ (\ velocity\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.linear_velocity` and its respective setter. .. rst-class:: classref-item-separator @@ -724,9 +640,7 @@ Method Descriptions |void| **_set_sleep_state**\ (\ enabled\: :ref:`bool`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.sleeping` and its respective setter. .. rst-class:: classref-item-separator @@ -738,9 +652,7 @@ Method Descriptions |void| **_set_transform**\ (\ transform\: :ref:`Transform2D`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Implement to override the behavior of :ref:`PhysicsDirectBodyState2D.transform` and its respective setter. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_physicsdirectbodystate3d.rst b/classes/class_physicsdirectbodystate3d.rst index 5daee5c2d..dbfa83c98 100644 --- a/classes/class_physicsdirectbodystate3d.rst +++ b/classes/class_physicsdirectbodystate3d.rst @@ -714,7 +714,7 @@ Returns the body's velocity at the given relative position, including both trans |void| **integrate_forces**\ (\ ) -Calls the built-in force integration code. +Updates the body's linear and angular velocity by applying gravity and damping for the equivalent of one physics tick. .. rst-class:: classref-item-separator diff --git a/classes/class_physicsserver2d.rst b/classes/class_physicsserver2d.rst index 20254a921..e5351bd92 100644 --- a/classes/class_physicsserver2d.rst +++ b/classes/class_physicsserver2d.rst @@ -1863,7 +1863,7 @@ Returns the value of the given state of the body. See :ref:`BodyState` **body_is_omitting_force_integration**\ (\ body\: :ref:`RID`\ ) |const| -Returns ``true`` if the body uses a callback function to calculate its own physics (see :ref:`body_set_force_integration_callback`). +Returns ``true`` if the body is omitting the standard force integration. See :ref:`body_set_omit_force_integration`. .. rst-class:: classref-item-separator @@ -2001,15 +2001,17 @@ Continuous collision detection tries to predict where a moving body would collid |void| **body_set_force_integration_callback**\ (\ body\: :ref:`RID`, callable\: :ref:`Callable`, userdata\: :ref:`Variant` = null\ ) -Sets the function used to calculate physics for the body, if that body allows it (see :ref:`body_set_omit_force_integration`). +Sets the body's custom force integration callback function to ``callable``. Use an empty :ref:`Callable` (``Callable()``) to clear the custom callback. -The force integration function takes the following two parameters: +The function ``callable`` will be called every physics tick, before the standard force integration (see :ref:`body_set_omit_force_integration`). It can be used for example to update the body's linear and angular velocity based on contact with other bodies. -1. a :ref:`PhysicsDirectBodyState2D` ``state``: used to retrieve and modify the body's state, +If ``userdata`` is not ``null``, the function ``callable`` must take the following two parameters: -2. a :ref:`Variant` ``userdata``: optional user data. +1. ``state``: a :ref:`PhysicsDirectBodyState2D` used to retrieve and modify the body's state, -\ **Note:** This callback is currently not called in Godot Physics. +2. ``userdata``: a :ref:`Variant`; its value will be the ``userdata`` passed into this method. + +If ``userdata`` is ``null``, then ``callable`` must take only the ``state`` parameter. .. rst-class:: classref-item-separator @@ -2045,7 +2047,9 @@ Sets the body's mode. See :ref:`BodyMode` for the |void| **body_set_omit_force_integration**\ (\ body\: :ref:`RID`, enable\: :ref:`bool`\ ) -Sets whether the body uses a callback function to calculate its own physics (see :ref:`body_set_force_integration_callback`). +Sets whether the body omits the standard force integration. If ``enable`` is ``true``, the body will not automatically use applied forces, torques, and damping to update the body's linear and angular velocity. In this case, :ref:`body_set_force_integration_callback` can be used to manually update the linear and angular velocity instead. + +This method is called when the property :ref:`RigidBody2D.custom_integrator` is set. .. rst-class:: classref-item-separator diff --git a/classes/class_physicsserver2dextension.rst b/classes/class_physicsserver2dextension.rst index 066de7755..eddbdc60a 100644 --- a/classes/class_physicsserver2dextension.rst +++ b/classes/class_physicsserver2dextension.rst @@ -328,9 +328,7 @@ Method Descriptions |void| **_area_add_shape**\ (\ area\: :ref:`RID`, shape\: :ref:`RID`, transform\: :ref:`Transform2D`, disabled\: :ref:`bool`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_add_shape`. .. rst-class:: classref-item-separator @@ -342,9 +340,7 @@ Method Descriptions |void| **_area_attach_canvas_instance_id**\ (\ area\: :ref:`RID`, id\: :ref:`int`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_attach_canvas_instance_id`. .. rst-class:: classref-item-separator @@ -356,9 +352,7 @@ Method Descriptions |void| **_area_attach_object_instance_id**\ (\ area\: :ref:`RID`, id\: :ref:`int`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_attach_object_instance_id`. .. rst-class:: classref-item-separator @@ -370,9 +364,7 @@ Method Descriptions |void| **_area_clear_shapes**\ (\ area\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_clear_shapes`. .. rst-class:: classref-item-separator @@ -384,9 +376,7 @@ Method Descriptions :ref:`RID` **_area_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_create`. .. rst-class:: classref-item-separator @@ -398,9 +388,7 @@ Method Descriptions :ref:`int` **_area_get_canvas_instance_id**\ (\ area\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_get_canvas_instance_id`. .. rst-class:: classref-item-separator @@ -412,9 +400,7 @@ Method Descriptions :ref:`int` **_area_get_collision_layer**\ (\ area\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_get_collision_layer`. .. rst-class:: classref-item-separator @@ -426,9 +412,7 @@ Method Descriptions :ref:`int` **_area_get_collision_mask**\ (\ area\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_get_collision_mask`. .. rst-class:: classref-item-separator @@ -440,9 +424,7 @@ Method Descriptions :ref:`int` **_area_get_object_instance_id**\ (\ area\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_get_object_instance_id`. .. rst-class:: classref-item-separator @@ -454,9 +436,7 @@ Method Descriptions :ref:`Variant` **_area_get_param**\ (\ area\: :ref:`RID`, param\: :ref:`AreaParameter`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_get_param`. .. rst-class:: classref-item-separator @@ -468,9 +448,7 @@ Method Descriptions :ref:`RID` **_area_get_shape**\ (\ area\: :ref:`RID`, shape_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_get_shape`. .. rst-class:: classref-item-separator @@ -482,9 +460,7 @@ Method Descriptions :ref:`int` **_area_get_shape_count**\ (\ area\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_get_shape_count`. .. rst-class:: classref-item-separator @@ -496,9 +472,7 @@ Method Descriptions :ref:`Transform2D` **_area_get_shape_transform**\ (\ area\: :ref:`RID`, shape_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_get_shape_transform`. .. rst-class:: classref-item-separator @@ -510,9 +484,7 @@ Method Descriptions :ref:`RID` **_area_get_space**\ (\ area\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_get_space`. .. rst-class:: classref-item-separator @@ -524,9 +496,7 @@ Method Descriptions :ref:`Transform2D` **_area_get_transform**\ (\ area\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_get_transform`. .. rst-class:: classref-item-separator @@ -538,9 +508,7 @@ Method Descriptions |void| **_area_remove_shape**\ (\ area\: :ref:`RID`, shape_idx\: :ref:`int`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_remove_shape`. .. rst-class:: classref-item-separator @@ -552,9 +520,7 @@ Method Descriptions |void| **_area_set_area_monitor_callback**\ (\ area\: :ref:`RID`, callback\: :ref:`Callable`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_set_area_monitor_callback`. .. rst-class:: classref-item-separator @@ -566,9 +532,7 @@ Method Descriptions |void| **_area_set_collision_layer**\ (\ area\: :ref:`RID`, layer\: :ref:`int`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_set_collision_layer`. .. rst-class:: classref-item-separator @@ -580,9 +544,7 @@ Method Descriptions |void| **_area_set_collision_mask**\ (\ area\: :ref:`RID`, mask\: :ref:`int`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_set_collision_mask`. .. rst-class:: classref-item-separator @@ -594,9 +556,7 @@ Method Descriptions |void| **_area_set_monitor_callback**\ (\ area\: :ref:`RID`, callback\: :ref:`Callable`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_set_monitor_callback`. .. rst-class:: classref-item-separator @@ -608,9 +568,7 @@ Method Descriptions |void| **_area_set_monitorable**\ (\ area\: :ref:`RID`, monitorable\: :ref:`bool`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_set_monitorable`. .. rst-class:: classref-item-separator @@ -622,9 +580,7 @@ Method Descriptions |void| **_area_set_param**\ (\ area\: :ref:`RID`, param\: :ref:`AreaParameter`, value\: :ref:`Variant`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_set_param`. .. rst-class:: classref-item-separator @@ -636,9 +592,9 @@ Method Descriptions |void| **_area_set_pickable**\ (\ area\: :ref:`RID`, pickable\: :ref:`bool`\ ) |virtual| -.. container:: contribute +If set to ``true``, allows the area with the given :ref:`RID` to detect mouse inputs when the mouse cursor is hovering on it. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``area_set_pickable`` method. Corresponds to :ref:`PhysicsBody2D.input_pickable`. .. rst-class:: classref-item-separator @@ -650,9 +606,7 @@ Method Descriptions |void| **_area_set_shape**\ (\ area\: :ref:`RID`, shape_idx\: :ref:`int`, shape\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_set_shape`. .. rst-class:: classref-item-separator @@ -664,9 +618,7 @@ Method Descriptions |void| **_area_set_shape_disabled**\ (\ area\: :ref:`RID`, shape_idx\: :ref:`int`, disabled\: :ref:`bool`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_set_shape_disabled`. .. rst-class:: classref-item-separator @@ -678,9 +630,7 @@ Method Descriptions |void| **_area_set_shape_transform**\ (\ area\: :ref:`RID`, shape_idx\: :ref:`int`, transform\: :ref:`Transform2D`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_set_shape_transform`. .. rst-class:: classref-item-separator @@ -692,9 +642,7 @@ Method Descriptions |void| **_area_set_space**\ (\ area\: :ref:`RID`, space\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_set_space`. .. rst-class:: classref-item-separator @@ -706,9 +654,7 @@ Method Descriptions |void| **_area_set_transform**\ (\ area\: :ref:`RID`, transform\: :ref:`Transform2D`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.area_set_transform`. .. rst-class:: classref-item-separator @@ -720,9 +666,7 @@ Method Descriptions |void| **_body_add_collision_exception**\ (\ body\: :ref:`RID`, excepted_body\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_add_collision_exception`. .. rst-class:: classref-item-separator @@ -734,9 +678,7 @@ Method Descriptions |void| **_body_add_constant_central_force**\ (\ body\: :ref:`RID`, force\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_add_constant_central_force`. .. rst-class:: classref-item-separator @@ -748,9 +690,7 @@ Method Descriptions |void| **_body_add_constant_force**\ (\ body\: :ref:`RID`, force\: :ref:`Vector2`, position\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_add_constant_force`. .. rst-class:: classref-item-separator @@ -762,9 +702,7 @@ Method Descriptions |void| **_body_add_constant_torque**\ (\ body\: :ref:`RID`, torque\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_add_constant_torque`. .. rst-class:: classref-item-separator @@ -776,9 +714,7 @@ Method Descriptions |void| **_body_add_shape**\ (\ body\: :ref:`RID`, shape\: :ref:`RID`, transform\: :ref:`Transform2D`, disabled\: :ref:`bool`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_add_shape`. .. rst-class:: classref-item-separator @@ -790,9 +726,7 @@ Method Descriptions |void| **_body_apply_central_force**\ (\ body\: :ref:`RID`, force\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_apply_central_force`. .. rst-class:: classref-item-separator @@ -804,9 +738,7 @@ Method Descriptions |void| **_body_apply_central_impulse**\ (\ body\: :ref:`RID`, impulse\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_apply_central_impulse`. .. rst-class:: classref-item-separator @@ -818,9 +750,7 @@ Method Descriptions |void| **_body_apply_force**\ (\ body\: :ref:`RID`, force\: :ref:`Vector2`, position\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_apply_force`. .. rst-class:: classref-item-separator @@ -832,9 +762,7 @@ Method Descriptions |void| **_body_apply_impulse**\ (\ body\: :ref:`RID`, impulse\: :ref:`Vector2`, position\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_apply_impulse`. .. rst-class:: classref-item-separator @@ -846,9 +774,7 @@ Method Descriptions |void| **_body_apply_torque**\ (\ body\: :ref:`RID`, torque\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_apply_torque`. .. rst-class:: classref-item-separator @@ -860,9 +786,7 @@ Method Descriptions |void| **_body_apply_torque_impulse**\ (\ body\: :ref:`RID`, impulse\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_apply_torque_impulse`. .. rst-class:: classref-item-separator @@ -874,9 +798,7 @@ Method Descriptions |void| **_body_attach_canvas_instance_id**\ (\ body\: :ref:`RID`, id\: :ref:`int`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_attach_canvas_instance_id`. .. rst-class:: classref-item-separator @@ -888,9 +810,7 @@ Method Descriptions |void| **_body_attach_object_instance_id**\ (\ body\: :ref:`RID`, id\: :ref:`int`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_attach_object_instance_id`. .. rst-class:: classref-item-separator @@ -902,9 +822,7 @@ Method Descriptions |void| **_body_clear_shapes**\ (\ body\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_clear_shapes`. .. rst-class:: classref-item-separator @@ -916,9 +834,9 @@ Method Descriptions :ref:`bool` **_body_collide_shape**\ (\ body\: :ref:`RID`, body_shape\: :ref:`int`, shape\: :ref:`RID`, shape_xform\: :ref:`Transform2D`, motion\: :ref:`Vector2`, results\: ``void*``, result_max\: :ref:`int`, result_count\: ``int32_t*``\ ) |virtual| -.. container:: contribute +Given a ``body``, a ``shape``, and their respective parameters, this method should return ``true`` if a collision between the two would occur, with additional details passed in ``results``. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``shape_collide`` method. Corresponds to :ref:`PhysicsDirectSpaceState2D.collide_shape`. .. rst-class:: classref-item-separator @@ -930,9 +848,7 @@ Method Descriptions :ref:`RID` **_body_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_create`. .. rst-class:: classref-item-separator @@ -944,9 +860,7 @@ Method Descriptions :ref:`int` **_body_get_canvas_instance_id**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_canvas_instance_id`. .. rst-class:: classref-item-separator @@ -958,9 +872,9 @@ Method Descriptions :ref:`Array`\[:ref:`RID`\] **_body_get_collision_exceptions**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute +Returns the :ref:`RID`\ s of all bodies added as collision exceptions for the given ``body``. See also :ref:`_body_add_collision_exception` and :ref:`_body_remove_collision_exception`. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``body_get_collision_exceptions`` method. Corresponds to :ref:`PhysicsBody2D.get_collision_exceptions`. .. rst-class:: classref-item-separator @@ -972,9 +886,7 @@ Method Descriptions :ref:`int` **_body_get_collision_layer**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_collision_layer`. .. rst-class:: classref-item-separator @@ -986,9 +898,7 @@ Method Descriptions :ref:`int` **_body_get_collision_mask**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_collision_mask`. .. rst-class:: classref-item-separator @@ -1000,9 +910,7 @@ Method Descriptions :ref:`float` **_body_get_collision_priority**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_collision_priority`. .. rst-class:: classref-item-separator @@ -1014,9 +922,7 @@ Method Descriptions :ref:`Vector2` **_body_get_constant_force**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_constant_force`. .. rst-class:: classref-item-separator @@ -1028,9 +934,7 @@ Method Descriptions :ref:`float` **_body_get_constant_torque**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_constant_torque`. .. rst-class:: classref-item-separator @@ -1042,9 +946,9 @@ Method Descriptions :ref:`float` **_body_get_contacts_reported_depth_threshold**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute +Overridable version of :ref:`PhysicsServer2D`'s internal ``body_get_contacts_reported_depth_threshold`` method. - There is currently no description for this method. Please help us by :ref:`contributing one `! +\ **Note:** This method is currently unused by Godot's default physics implementation. .. rst-class:: classref-item-separator @@ -1056,9 +960,7 @@ Method Descriptions :ref:`CCDMode` **_body_get_continuous_collision_detection_mode**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_continuous_collision_detection_mode`. .. rst-class:: classref-item-separator @@ -1070,9 +972,7 @@ Method Descriptions :ref:`PhysicsDirectBodyState2D` **_body_get_direct_state**\ (\ body\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_direct_state`. .. rst-class:: classref-item-separator @@ -1084,9 +984,7 @@ Method Descriptions :ref:`int` **_body_get_max_contacts_reported**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_max_contacts_reported`. .. rst-class:: classref-item-separator @@ -1098,9 +996,7 @@ Method Descriptions :ref:`BodyMode` **_body_get_mode**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_mode`. .. rst-class:: classref-item-separator @@ -1112,9 +1008,7 @@ Method Descriptions :ref:`int` **_body_get_object_instance_id**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_object_instance_id`. .. rst-class:: classref-item-separator @@ -1126,9 +1020,7 @@ Method Descriptions :ref:`Variant` **_body_get_param**\ (\ body\: :ref:`RID`, param\: :ref:`BodyParameter`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_param`. .. rst-class:: classref-item-separator @@ -1140,9 +1032,7 @@ Method Descriptions :ref:`RID` **_body_get_shape**\ (\ body\: :ref:`RID`, shape_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_shape`. .. rst-class:: classref-item-separator @@ -1154,9 +1044,7 @@ Method Descriptions :ref:`int` **_body_get_shape_count**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_shape_count`. .. rst-class:: classref-item-separator @@ -1168,9 +1056,7 @@ Method Descriptions :ref:`Transform2D` **_body_get_shape_transform**\ (\ body\: :ref:`RID`, shape_idx\: :ref:`int`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_shape_transform`. .. rst-class:: classref-item-separator @@ -1182,9 +1068,7 @@ Method Descriptions :ref:`RID` **_body_get_space**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_space`. .. rst-class:: classref-item-separator @@ -1196,9 +1080,7 @@ Method Descriptions :ref:`Variant` **_body_get_state**\ (\ body\: :ref:`RID`, state\: :ref:`BodyState`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_get_state`. .. rst-class:: classref-item-separator @@ -1210,9 +1092,7 @@ Method Descriptions :ref:`bool` **_body_is_omitting_force_integration**\ (\ body\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_is_omitting_force_integration`. .. rst-class:: classref-item-separator @@ -1224,9 +1104,7 @@ Method Descriptions |void| **_body_remove_collision_exception**\ (\ body\: :ref:`RID`, excepted_body\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_remove_collision_exception`. .. rst-class:: classref-item-separator @@ -1238,9 +1116,7 @@ Method Descriptions |void| **_body_remove_shape**\ (\ body\: :ref:`RID`, shape_idx\: :ref:`int`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_remove_shape`. .. rst-class:: classref-item-separator @@ -1252,9 +1128,7 @@ Method Descriptions |void| **_body_reset_mass_properties**\ (\ body\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_reset_mass_properties`. .. rst-class:: classref-item-separator @@ -1266,9 +1140,7 @@ Method Descriptions |void| **_body_set_axis_velocity**\ (\ body\: :ref:`RID`, axis_velocity\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_axis_velocity`. .. rst-class:: classref-item-separator @@ -1280,9 +1152,7 @@ Method Descriptions |void| **_body_set_collision_layer**\ (\ body\: :ref:`RID`, layer\: :ref:`int`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_collision_layer`. .. rst-class:: classref-item-separator @@ -1294,9 +1164,7 @@ Method Descriptions |void| **_body_set_collision_mask**\ (\ body\: :ref:`RID`, mask\: :ref:`int`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_collision_mask`. .. rst-class:: classref-item-separator @@ -1308,9 +1176,7 @@ Method Descriptions |void| **_body_set_collision_priority**\ (\ body\: :ref:`RID`, priority\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_collision_priority`. .. rst-class:: classref-item-separator @@ -1322,9 +1188,7 @@ Method Descriptions |void| **_body_set_constant_force**\ (\ body\: :ref:`RID`, force\: :ref:`Vector2`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_constant_force`. .. rst-class:: classref-item-separator @@ -1336,9 +1200,7 @@ Method Descriptions |void| **_body_set_constant_torque**\ (\ body\: :ref:`RID`, torque\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_constant_torque`. .. rst-class:: classref-item-separator @@ -1350,9 +1212,9 @@ Method Descriptions |void| **_body_set_contacts_reported_depth_threshold**\ (\ body\: :ref:`RID`, threshold\: :ref:`float`\ ) |virtual| -.. container:: contribute +Overridable version of :ref:`PhysicsServer2D`'s internal ``body_set_contacts_reported_depth_threshold`` method. - There is currently no description for this method. Please help us by :ref:`contributing one `! +\ **Note:** This method is currently unused by Godot's default physics implementation. .. rst-class:: classref-item-separator @@ -1364,9 +1226,7 @@ Method Descriptions |void| **_body_set_continuous_collision_detection_mode**\ (\ body\: :ref:`RID`, mode\: :ref:`CCDMode`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_continuous_collision_detection_mode`. .. rst-class:: classref-item-separator @@ -1378,9 +1238,7 @@ Method Descriptions |void| **_body_set_force_integration_callback**\ (\ body\: :ref:`RID`, callable\: :ref:`Callable`, userdata\: :ref:`Variant`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_force_integration_callback`. .. rst-class:: classref-item-separator @@ -1392,9 +1250,7 @@ Method Descriptions |void| **_body_set_max_contacts_reported**\ (\ body\: :ref:`RID`, amount\: :ref:`int`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_max_contacts_reported`. .. rst-class:: classref-item-separator @@ -1406,9 +1262,7 @@ Method Descriptions |void| **_body_set_mode**\ (\ body\: :ref:`RID`, mode\: :ref:`BodyMode`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_mode`. .. rst-class:: classref-item-separator @@ -1420,9 +1274,7 @@ Method Descriptions |void| **_body_set_omit_force_integration**\ (\ body\: :ref:`RID`, enable\: :ref:`bool`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_omit_force_integration`. .. rst-class:: classref-item-separator @@ -1434,9 +1286,7 @@ Method Descriptions |void| **_body_set_param**\ (\ body\: :ref:`RID`, param\: :ref:`BodyParameter`, value\: :ref:`Variant`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_param`. .. rst-class:: classref-item-separator @@ -1448,9 +1298,9 @@ Method Descriptions |void| **_body_set_pickable**\ (\ body\: :ref:`RID`, pickable\: :ref:`bool`\ ) |virtual| -.. container:: contribute +If set to ``true``, allows the body with the given :ref:`RID` to detect mouse inputs when the mouse cursor is hovering on it. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``body_set_pickable`` method. Corresponds to :ref:`PhysicsBody2D.input_pickable`. .. rst-class:: classref-item-separator @@ -1462,9 +1312,7 @@ Method Descriptions |void| **_body_set_shape**\ (\ body\: :ref:`RID`, shape_idx\: :ref:`int`, shape\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_shape`. .. rst-class:: classref-item-separator @@ -1476,9 +1324,7 @@ Method Descriptions |void| **_body_set_shape_as_one_way_collision**\ (\ body\: :ref:`RID`, shape_idx\: :ref:`int`, enable\: :ref:`bool`, margin\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_shape_as_one_way_collision`. .. rst-class:: classref-item-separator @@ -1490,9 +1336,7 @@ Method Descriptions |void| **_body_set_shape_disabled**\ (\ body\: :ref:`RID`, shape_idx\: :ref:`int`, disabled\: :ref:`bool`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_shape_disabled`. .. rst-class:: classref-item-separator @@ -1504,9 +1348,7 @@ Method Descriptions |void| **_body_set_shape_transform**\ (\ body\: :ref:`RID`, shape_idx\: :ref:`int`, transform\: :ref:`Transform2D`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_shape_transform`. .. rst-class:: classref-item-separator @@ -1518,9 +1360,7 @@ Method Descriptions |void| **_body_set_space**\ (\ body\: :ref:`RID`, space\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_space`. .. rst-class:: classref-item-separator @@ -1532,9 +1372,7 @@ Method Descriptions |void| **_body_set_state**\ (\ body\: :ref:`RID`, state\: :ref:`BodyState`, value\: :ref:`Variant`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_set_state`. .. rst-class:: classref-item-separator @@ -1546,9 +1384,9 @@ Method Descriptions |void| **_body_set_state_sync_callback**\ (\ body\: :ref:`RID`, callable\: :ref:`Callable`\ ) |virtual| -.. container:: contribute +Assigns the ``body`` to call the given ``callable`` during the synchronization phase of the loop, before :ref:`_step` is called. See also :ref:`_sync`. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``body_set_state_sync_callback`` method. .. rst-class:: classref-item-separator @@ -1560,9 +1398,7 @@ Method Descriptions :ref:`bool` **_body_test_motion**\ (\ body\: :ref:`RID`, from\: :ref:`Transform2D`, motion\: :ref:`Vector2`, margin\: :ref:`float`, collide_separation_ray\: :ref:`bool`, recovery_as_collision\: :ref:`bool`, result\: ``PhysicsServer2DExtensionMotionResult*``\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.body_test_motion`. Unlike the exposed implementation, this method does not receive all of the arguments inside a :ref:`PhysicsTestMotionParameters2D`. .. rst-class:: classref-item-separator @@ -1574,9 +1410,7 @@ Method Descriptions :ref:`RID` **_capsule_shape_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.capsule_shape_create`. .. rst-class:: classref-item-separator @@ -1588,9 +1422,7 @@ Method Descriptions :ref:`RID` **_circle_shape_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.circle_shape_create`. .. rst-class:: classref-item-separator @@ -1602,9 +1434,7 @@ Method Descriptions :ref:`RID` **_concave_polygon_shape_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.concave_polygon_shape_create`. .. rst-class:: classref-item-separator @@ -1616,9 +1446,7 @@ Method Descriptions :ref:`RID` **_convex_polygon_shape_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.convex_polygon_shape_create`. .. rst-class:: classref-item-separator @@ -1630,9 +1458,7 @@ Method Descriptions :ref:`float` **_damped_spring_joint_get_param**\ (\ joint\: :ref:`RID`, param\: :ref:`DampedSpringParam`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.damped_spring_joint_get_param`. .. rst-class:: classref-item-separator @@ -1644,9 +1470,7 @@ Method Descriptions |void| **_damped_spring_joint_set_param**\ (\ joint\: :ref:`RID`, param\: :ref:`DampedSpringParam`, value\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.damped_spring_joint_set_param`. .. rst-class:: classref-item-separator @@ -1658,9 +1482,9 @@ Method Descriptions |void| **_end_sync**\ (\ ) |virtual| -.. container:: contribute +Called to indicate that the physics server has stopped synchronizing. It is in the loop's iteration/physics phase, and can access physics objects even if running on a separate thread. See also :ref:`_sync`. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``end_sync`` method. .. rst-class:: classref-item-separator @@ -1672,9 +1496,9 @@ Method Descriptions |void| **_finish**\ (\ ) |virtual| -.. container:: contribute +Called when the main loop finalizes to shut down the physics server. See also :ref:`MainLoop._finalize` and :ref:`_init`. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``finish`` method. .. rst-class:: classref-item-separator @@ -1686,9 +1510,9 @@ Method Descriptions |void| **_flush_queries**\ (\ ) |virtual| -.. container:: contribute +Called every physics step before :ref:`_step` to process all remaining queries. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``flush_queries`` method. .. rst-class:: classref-item-separator @@ -1700,9 +1524,7 @@ Method Descriptions |void| **_free_rid**\ (\ rid\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.free_rid`. .. rst-class:: classref-item-separator @@ -1714,9 +1536,7 @@ Method Descriptions :ref:`int` **_get_process_info**\ (\ process_info\: :ref:`ProcessInfo`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.get_process_info`. .. rst-class:: classref-item-separator @@ -1728,9 +1548,9 @@ Method Descriptions |void| **_init**\ (\ ) |virtual| -.. container:: contribute +Called when the main loop is initialized and creates a new instance of this physics server. See also :ref:`MainLoop._initialize` and :ref:`_finish`. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``init`` method. .. rst-class:: classref-item-separator @@ -1742,9 +1562,9 @@ Method Descriptions :ref:`bool` **_is_flushing_queries**\ (\ ) |virtual| |const| -.. container:: contribute +Overridable method that should return ``true`` when the physics server is processing queries. See also :ref:`_flush_queries`. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``is_flushing_queries`` method. .. rst-class:: classref-item-separator @@ -1756,9 +1576,7 @@ Method Descriptions |void| **_joint_clear**\ (\ joint\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.joint_clear`. .. rst-class:: classref-item-separator @@ -1770,9 +1588,7 @@ Method Descriptions :ref:`RID` **_joint_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.joint_create`. .. rst-class:: classref-item-separator @@ -1784,9 +1600,7 @@ Method Descriptions |void| **_joint_disable_collisions_between_bodies**\ (\ joint\: :ref:`RID`, disable\: :ref:`bool`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.joint_disable_collisions_between_bodies`. .. rst-class:: classref-item-separator @@ -1798,9 +1612,7 @@ Method Descriptions :ref:`float` **_joint_get_param**\ (\ joint\: :ref:`RID`, param\: :ref:`JointParam`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.joint_get_param`. .. rst-class:: classref-item-separator @@ -1812,9 +1624,7 @@ Method Descriptions :ref:`JointType` **_joint_get_type**\ (\ joint\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.joint_get_type`. .. rst-class:: classref-item-separator @@ -1826,9 +1636,7 @@ Method Descriptions :ref:`bool` **_joint_is_disabled_collisions_between_bodies**\ (\ joint\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.joint_is_disabled_collisions_between_bodies`. .. rst-class:: classref-item-separator @@ -1840,9 +1648,7 @@ Method Descriptions |void| **_joint_make_damped_spring**\ (\ joint\: :ref:`RID`, anchor_a\: :ref:`Vector2`, anchor_b\: :ref:`Vector2`, body_a\: :ref:`RID`, body_b\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.joint_make_damped_spring`. .. rst-class:: classref-item-separator @@ -1854,9 +1660,7 @@ Method Descriptions |void| **_joint_make_groove**\ (\ joint\: :ref:`RID`, a_groove1\: :ref:`Vector2`, a_groove2\: :ref:`Vector2`, b_anchor\: :ref:`Vector2`, body_a\: :ref:`RID`, body_b\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.joint_make_groove`. .. rst-class:: classref-item-separator @@ -1868,9 +1672,7 @@ Method Descriptions |void| **_joint_make_pin**\ (\ joint\: :ref:`RID`, anchor\: :ref:`Vector2`, body_a\: :ref:`RID`, body_b\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.joint_make_pin`. .. rst-class:: classref-item-separator @@ -1882,9 +1684,7 @@ Method Descriptions |void| **_joint_set_param**\ (\ joint\: :ref:`RID`, param\: :ref:`JointParam`, value\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.joint_set_param`. .. rst-class:: classref-item-separator @@ -1896,9 +1696,7 @@ Method Descriptions :ref:`bool` **_pin_joint_get_flag**\ (\ joint\: :ref:`RID`, flag\: :ref:`PinJointFlag`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.pin_joint_get_flag`. .. rst-class:: classref-item-separator @@ -1910,9 +1708,7 @@ Method Descriptions :ref:`float` **_pin_joint_get_param**\ (\ joint\: :ref:`RID`, param\: :ref:`PinJointParam`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.pin_joint_get_param`. .. rst-class:: classref-item-separator @@ -1924,9 +1720,7 @@ Method Descriptions |void| **_pin_joint_set_flag**\ (\ joint\: :ref:`RID`, flag\: :ref:`PinJointFlag`, enabled\: :ref:`bool`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.pin_joint_set_flag`. .. rst-class:: classref-item-separator @@ -1938,9 +1732,7 @@ Method Descriptions |void| **_pin_joint_set_param**\ (\ joint\: :ref:`RID`, param\: :ref:`PinJointParam`, value\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.pin_joint_set_param`. .. rst-class:: classref-item-separator @@ -1952,9 +1744,7 @@ Method Descriptions :ref:`RID` **_rectangle_shape_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.rectangle_shape_create`. .. rst-class:: classref-item-separator @@ -1966,9 +1756,7 @@ Method Descriptions :ref:`RID` **_segment_shape_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.segment_shape_create`. .. rst-class:: classref-item-separator @@ -1980,9 +1768,7 @@ Method Descriptions :ref:`RID` **_separation_ray_shape_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.separation_ray_shape_create`. .. rst-class:: classref-item-separator @@ -1994,9 +1780,7 @@ Method Descriptions |void| **_set_active**\ (\ active\: :ref:`bool`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.set_active`. .. rst-class:: classref-item-separator @@ -2008,9 +1792,9 @@ Method Descriptions :ref:`bool` **_shape_collide**\ (\ shape_A\: :ref:`RID`, xform_A\: :ref:`Transform2D`, motion_A\: :ref:`Vector2`, shape_B\: :ref:`RID`, xform_B\: :ref:`Transform2D`, motion_B\: :ref:`Vector2`, results\: ``void*``, result_max\: :ref:`int`, result_count\: ``int32_t*``\ ) |virtual| -.. container:: contribute +Given two shapes and their parameters, should return ``true`` if a collision between the two would occur, with additional details passed in ``results``. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``shape_collide`` method. Corresponds to :ref:`PhysicsDirectSpaceState2D.collide_shape`. .. rst-class:: classref-item-separator @@ -2022,9 +1806,9 @@ Method Descriptions :ref:`float` **_shape_get_custom_solver_bias**\ (\ shape\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute +Should return the custom solver bias of the given ``shape``, which defines how much bodies are forced to separate on contact when this shape is involved. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``shape_get_custom_solver_bias`` method. Corresponds to :ref:`Shape2D.custom_solver_bias`. .. rst-class:: classref-item-separator @@ -2036,9 +1820,7 @@ Method Descriptions :ref:`Variant` **_shape_get_data**\ (\ shape\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.shape_get_data`. .. rst-class:: classref-item-separator @@ -2050,9 +1832,7 @@ Method Descriptions :ref:`ShapeType` **_shape_get_type**\ (\ shape\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.shape_get_type`. .. rst-class:: classref-item-separator @@ -2064,9 +1844,9 @@ Method Descriptions |void| **_shape_set_custom_solver_bias**\ (\ shape\: :ref:`RID`, bias\: :ref:`float`\ ) |virtual| -.. container:: contribute +Should set the custom solver bias for the given ``shape``. It defines how much bodies are forced to separate on contact. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``shape_get_custom_solver_bias`` method. Corresponds to :ref:`Shape2D.custom_solver_bias`. .. rst-class:: classref-item-separator @@ -2078,9 +1858,7 @@ Method Descriptions |void| **_shape_set_data**\ (\ shape\: :ref:`RID`, data\: :ref:`Variant`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.shape_set_data`. .. rst-class:: classref-item-separator @@ -2092,9 +1870,7 @@ Method Descriptions :ref:`RID` **_space_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.space_create`. .. rst-class:: classref-item-separator @@ -2106,9 +1882,9 @@ Method Descriptions :ref:`int` **_space_get_contact_count**\ (\ space\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute +Should return how many contacts have occurred during the last physics step in the given ``space``. See also :ref:`_space_get_contacts` and :ref:`_space_set_debug_contacts`. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``space_get_contact_count`` method. .. rst-class:: classref-item-separator @@ -2120,9 +1896,9 @@ Method Descriptions :ref:`PackedVector2Array` **_space_get_contacts**\ (\ space\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute +Should return the positions of all contacts that have occurred during the last physics step in the given ``space``. See also :ref:`_space_get_contact_count` and :ref:`_space_set_debug_contacts`. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``space_get_contacts`` method. .. rst-class:: classref-item-separator @@ -2134,9 +1910,7 @@ Method Descriptions :ref:`PhysicsDirectSpaceState2D` **_space_get_direct_state**\ (\ space\: :ref:`RID`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.space_get_direct_state`. .. rst-class:: classref-item-separator @@ -2148,9 +1922,7 @@ Method Descriptions :ref:`float` **_space_get_param**\ (\ space\: :ref:`RID`, param\: :ref:`SpaceParameter`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.space_get_param`. .. rst-class:: classref-item-separator @@ -2162,9 +1934,7 @@ Method Descriptions :ref:`bool` **_space_is_active**\ (\ space\: :ref:`RID`\ ) |virtual| |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.space_is_active`. .. rst-class:: classref-item-separator @@ -2176,9 +1946,7 @@ Method Descriptions |void| **_space_set_active**\ (\ space\: :ref:`RID`, active\: :ref:`bool`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.space_set_active`. .. rst-class:: classref-item-separator @@ -2190,9 +1958,9 @@ Method Descriptions |void| **_space_set_debug_contacts**\ (\ space\: :ref:`RID`, max_contacts\: :ref:`int`\ ) |virtual| -.. container:: contribute +Used internally to allow the given ``space`` to store contact points, up to ``max_contacts``. This is automatically set for the main :ref:`World2D`'s space when :ref:`SceneTree.debug_collisions_hint` is ``true``, or by checking "Visible Collision Shapes" in the editor. Only works in debug builds. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``space_set_debug_contacts`` method. .. rst-class:: classref-item-separator @@ -2204,9 +1972,7 @@ Method Descriptions |void| **_space_set_param**\ (\ space\: :ref:`RID`, param\: :ref:`SpaceParameter`, value\: :ref:`float`\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.space_set_param`. .. rst-class:: classref-item-separator @@ -2218,9 +1984,9 @@ Method Descriptions |void| **_step**\ (\ step\: :ref:`float`\ ) |virtual| -.. container:: contribute +Called every physics step to process the physics simulation. ``step`` is the time elapsed since the last physics step, in seconds. It is usually the same as :ref:`Node.get_physics_process_delta_time`. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``step`` method. .. rst-class:: classref-item-separator @@ -2232,9 +1998,9 @@ Method Descriptions |void| **_sync**\ (\ ) |virtual| -.. container:: contribute +Called to indicate that the physics server is synchronizing and cannot access physics states if running on a separate thread. See also :ref:`_end_sync`. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D`'s internal ``sync`` method. .. rst-class:: classref-item-separator @@ -2246,9 +2012,7 @@ Method Descriptions :ref:`RID` **_world_boundary_shape_create**\ (\ ) |virtual| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Overridable version of :ref:`PhysicsServer2D.world_boundary_shape_create`. .. rst-class:: classref-item-separator @@ -2260,9 +2024,7 @@ Method Descriptions :ref:`bool` **body_test_motion_is_excluding_body**\ (\ body\: :ref:`RID`\ ) |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Returns ``true`` if the body with the given :ref:`RID` is being excluded from :ref:`_body_test_motion`. See also :ref:`Object.get_instance_id`. .. rst-class:: classref-item-separator @@ -2274,9 +2036,7 @@ Method Descriptions :ref:`bool` **body_test_motion_is_excluding_object**\ (\ object\: :ref:`int`\ ) |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Returns ``true`` if the object with the given instance ID is being excluded from :ref:`_body_test_motion`. See also :ref:`Object.get_instance_id`. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_physicsserver3d.rst b/classes/class_physicsserver3d.rst index 9c46a52a9..fba5e41bd 100644 --- a/classes/class_physicsserver3d.rst +++ b/classes/class_physicsserver3d.rst @@ -1326,7 +1326,7 @@ Constant to set/get the priority (order of processing) of an area. :ref:`AreaParameter` **AREA_PARAM_WIND_FORCE_MAGNITUDE** = ``10`` -Constant to set/get the magnitude of area-specific wind force. +Constant to set/get the magnitude of area-specific wind force. This wind force only applies to :ref:`SoftBody3D` nodes. Other physics bodies are currently not affected by wind. .. _class_PhysicsServer3D_constant_AREA_PARAM_WIND_SOURCE: @@ -2587,7 +2587,7 @@ If ``true``, the continuous collision detection mode is enabled. :ref:`bool` **body_is_omitting_force_integration**\ (\ body\: :ref:`RID`\ ) |const| -Returns whether a body uses a callback function to calculate its own physics (see :ref:`body_set_force_integration_callback`). +Returns ``true`` if the body is omitting the standard force integration. See :ref:`body_set_omit_force_integration`. .. rst-class:: classref-item-separator @@ -2741,11 +2741,17 @@ Continuous collision detection tries to predict where a moving body will collide |void| **body_set_force_integration_callback**\ (\ body\: :ref:`RID`, callable\: :ref:`Callable`, userdata\: :ref:`Variant` = null\ ) -Sets the function used to calculate physics for an object, if that object allows it (see :ref:`body_set_omit_force_integration`). The force integration function takes 2 arguments: +Sets the body's custom force integration callback function to ``callable``. Use an empty :ref:`Callable` (``Callable()``) to clear the custom callback. -- ``state`` — :ref:`PhysicsDirectBodyState3D` used to retrieve and modify the body's state. +The function ``callable`` will be called every physics tick, before the standard force integration (see :ref:`body_set_omit_force_integration`). It can be used for example to update the body's linear and angular velocity based on contact with other bodies. -- ``userdata`` — optional user data passed to :ref:`body_set_force_integration_callback`. +If ``userdata`` is not ``null``, the function ``callable`` must take the following two parameters: + +1. ``state``: a :ref:`PhysicsDirectBodyState3D`, used to retrieve and modify the body's state, + +2. ``userdata``: a :ref:`Variant`; its value will be the ``userdata`` passed into this method. + +If ``userdata`` is ``null``, then ``callable`` must take only the ``state`` parameter. .. rst-class:: classref-item-separator @@ -2781,7 +2787,9 @@ Sets the body mode, from one of the :ref:`BodyMode`, enable\: :ref:`bool`\ ) -Sets whether a body uses a callback function to calculate its own physics (see :ref:`body_set_force_integration_callback`). +Sets whether the body omits the standard force integration. If ``enable`` is ``true``, the body will not automatically use applied forces, torques, and damping to update the body's linear and angular velocity. In this case, :ref:`body_set_force_integration_callback` can be used to manually update the linear and angular velocity instead. + +This method is called when the property :ref:`RigidBody3D.custom_integrator` is set. .. rst-class:: classref-item-separator diff --git a/classes/class_polygon2d.rst b/classes/class_polygon2d.rst index 343794e62..561bdcf71 100644 --- a/classes/class_polygon2d.rst +++ b/classes/class_polygon2d.rst @@ -225,7 +225,7 @@ The offset applied to each vertex. The polygon's list of vertices. The final point will be connected to the first. -\ **Note:** This returns a copy of the :ref:`PackedVector2Array` rather than a reference. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. .. rst-class:: classref-item-separator @@ -346,6 +346,8 @@ Amount to multiply the :ref:`uv` coordinates when u Texture coordinates for each vertex of the polygon. There should be one UV value per polygon vertex. If there are fewer, undefined vertices will use ``Vector2(0, 0)``. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -363,6 +365,8 @@ Texture coordinates for each vertex of the polygon. There should be one UV value Color for each vertex. Colors are interpolated between vertices, resulting in smooth gradients. There should be one per polygon vertex. If there are fewer, undefined vertices will use :ref:`color`. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedColorArray` for more details. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_polygonoccluder3d.rst b/classes/class_polygonoccluder3d.rst index 24fc094ec..cafe861f5 100644 --- a/classes/class_polygonoccluder3d.rst +++ b/classes/class_polygonoccluder3d.rst @@ -66,6 +66,8 @@ The polygon to use for occlusion culling. The polygon can be convex or concave, The polygon must *not* have intersecting lines. Otherwise, triangulation will fail (with an error message printed). +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` diff --git a/classes/class_projectsettings.rst b/classes/class_projectsettings.rst index ae1701466..16dc7bc14 100644 --- a/classes/class_projectsettings.rst +++ b/classes/class_projectsettings.rst @@ -32,11 +32,11 @@ When naming a Project Settings property, use the full path to the setting includ Tutorials --------- -- `3D Physics Tests Demo `__ +- `3D Physics Tests Demo `__ -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `OS Test Demo `__ +- `Operating System Testing Demo `__ .. rst-class:: classref-reftable-group @@ -95,6 +95,8 @@ Properties +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`application/run/disable_stdout` | ``false`` | +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`application/run/enable_alt_space_menu` | ``false`` | + +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`application/run/flush_stdout_on_print` | ``false`` | +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`application/run/flush_stdout_on_print.debug` | ``true`` | @@ -1505,6 +1507,8 @@ Properties +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`String` | :ref:`rendering/rendering_device/driver.windows` | | +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`rendering/rendering_device/pipeline_cache/enable` | ``true`` | + +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`float` | :ref:`rendering/rendering_device/pipeline_cache/save_chunk_size_mb` | ``3.0`` | +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`rendering/rendering_device/staging_buffer/block_size_kb` | ``256`` | @@ -1992,6 +1996,22 @@ Changes to this setting will only be applied upon restarting the application. ---- +.. _class_ProjectSettings_property_application/run/enable_alt_space_menu: + +.. rst-class:: classref-property + +:ref:`bool` **application/run/enable_alt_space_menu** = ``false`` + +If ``true``, allows the :kbd:`Alt + Space` keys to display the window menu. This menu allows the user to perform various window management operations such as moving, resizing, or minimizing the window. + +\ **Note:** When the menu is displayed, project execution will pause until the menu is *fully* closed due to Windows behavior. Consider this when enabling this setting in a networked multiplayer game. The menu is only considered fully closed when an option is selected, when the user clicks outside, or when :kbd:`Escape` is pressed after bringing up the window menu *and* another key is pressed afterwards. + +\ **Note:** This setting is implemented only on Windows. + +.. rst-class:: classref-item-separator + +---- + .. _class_ProjectSettings_property_application/run/flush_stdout_on_print: .. rst-class:: classref-property @@ -2932,7 +2952,7 @@ When set to ``warn`` or ``error``, produces a warning or an error respectively w :ref:`int` **debug/gdscript/warnings/unsafe_cast** = ``0`` -When set to ``warn`` or ``error``, produces a warning or an error respectively when performing an unsafe cast. +When set to ``warn`` or ``error``, produces a warning or an error respectively when a :ref:`Variant` value is cast to a non-Variant. .. rst-class:: classref-item-separator @@ -4438,7 +4458,7 @@ It is possible to make another executable run Godot by using the ``%command%`` p For example, this can be used to force the project to run on the dedicated GPU in an NVIDIA Optimus system on Linux: -:: +.. code:: text prime-run %command% @@ -4454,6 +4474,8 @@ For example, this can be used to force the project to run on the dedicated GPU i Text-based file extensions to include in the script editor's "Find in Files" feature. You can add e.g. ``tscn`` if you wish to also parse your scene files, especially if you use built-in scripts which are serialized in the scene files. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -11048,6 +11070,20 @@ Windows override for :ref:`rendering/rendering_device/driver` **rendering/rendering_device/pipeline_cache/enable** = ``true`` + +Enable the pipeline cache that is saved to disk if the graphics API supports it. + +\ **Note:** This property is unable to control the pipeline caching the GPU driver itself does. Only turn this off along with deleting the contents of the driver's cache if you wish to simulate the experience a user will get when starting the game for the first time. + +.. rst-class:: classref-item-separator + +---- + .. _class_ProjectSettings_property_rendering/rendering_device/pipeline_cache/save_chunk_size_mb: .. rst-class:: classref-property @@ -11526,7 +11562,7 @@ If :ref:`rendering/vrs/mode` The texture *must* use a lossless compression format so that colors can be matched precisely. The following VRS densities are mapped to various colors, with brighter colors representing a lower level of shading precision: -:: +.. code:: text - 1×1 = rgb(0, 0, 0) - #000000 - 1×2 = rgb(0, 85, 0) - #005500 diff --git a/classes/class_quadmesh.rst b/classes/class_quadmesh.rst index f738310a8..e2046e1fe 100644 --- a/classes/class_quadmesh.rst +++ b/classes/class_quadmesh.rst @@ -26,9 +26,9 @@ Class representing a square :ref:`PrimitiveMesh`. This flat Tutorials --------- -- `GUI in 3D Demo `__ +- `GUI in 3D Viewport Demo `__ -- `2D in 3D Demo `__ +- `2D in 3D Viewport Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_quaternion.rst b/classes/class_quaternion.rst index 22be54323..8315acfb6 100644 --- a/classes/class_quaternion.rst +++ b/classes/class_quaternion.rst @@ -42,7 +42,7 @@ Tutorials - `Using 3D transforms <../tutorials/3d/using_transforms.html#interpolating-with-quaternions>`__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ - `Advanced Quaternion Visualization `__ diff --git a/classes/class_raycast2d.rst b/classes/class_raycast2d.rst index 3a0f4eae9..9d7b4f9eb 100644 --- a/classes/class_raycast2d.rst +++ b/classes/class_raycast2d.rst @@ -311,6 +311,27 @@ Returns the :ref:`RID` of the first object that the ray intersects, o Returns the shape ID of the first object that the ray intersects, or ``0`` if no object is intersecting the ray (i.e. :ref:`is_colliding` returns ``false``). +To get the intersected shape node, for a :ref:`CollisionObject2D` target, use: + + +.. tabs:: + + .. code-tab:: gdscript + + var target = get_collider() # A CollisionObject2D. + var shape_id = get_collider_shape() # The shape index in the collider. + var owner_id = target.shape_find_owner(shape_id) # The owner ID in the collider. + var shape = target.shape_owner_get_owner(owner_id) + + .. code-tab:: csharp + + var target = (CollisionObject2D)GetCollider(); // A CollisionObject2D. + var shapeId = GetColliderShape(); // The shape index in the collider. + var ownerId = target.ShapeFindOwner(shapeId); // The owner ID in the collider. + var shape = target.ShapeOwnerGetOwner(ownerId); + + + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_raycast3d.rst b/classes/class_raycast3d.rst index 87feae909..6e2f089a5 100644 --- a/classes/class_raycast3d.rst +++ b/classes/class_raycast3d.rst @@ -34,7 +34,7 @@ Tutorials - :doc:`Ray-casting <../tutorials/physics/ray-casting>` -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group @@ -374,6 +374,27 @@ Returns the :ref:`RID` of the first object that the ray intersects, o Returns the shape ID of the first object that the ray intersects, or ``0`` if no object is intersecting the ray (i.e. :ref:`is_colliding` returns ``false``). +To get the intersected shape node, for a :ref:`CollisionObject3D` target, use: + + +.. tabs:: + + .. code-tab:: gdscript + + var target = get_collider() # A CollisionObject3D. + var shape_id = get_collider_shape() # The shape index in the collider. + var owner_id = target.shape_find_owner(shape_id) # The owner ID in the collider. + var shape = target.shape_owner_get_owner(owner_id) + + .. code-tab:: csharp + + var target = (CollisionObject3D)GetCollider(); // A CollisionObject3D. + var shapeId = GetColliderShape(); // The shape index in the collider. + var ownerId = target.ShapeFindOwner(shapeId); // The owner ID in the collider. + var shape = target.ShapeOwnerGetOwner(ownerId); + + + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_rdframebufferpass.rst b/classes/class_rdframebufferpass.rst index 0d4364ddb..c3f25b56b 100644 --- a/classes/class_rdframebufferpass.rst +++ b/classes/class_rdframebufferpass.rst @@ -84,6 +84,8 @@ Property Descriptions Color attachments in order starting from 0. If this attachment is not used by the shader, pass ATTACHMENT_UNUSED to skip. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt32Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -118,6 +120,8 @@ Depth attachment. ATTACHMENT_UNUSED should be used if no depth buffer is require Used for multipass framebuffers (more than one render pass). Converts an attachment to an input. Make sure to also supply it properly in the :ref:`RDUniform` for the uniform set. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt32Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -135,6 +139,8 @@ Used for multipass framebuffers (more than one render pass). Converts an attachm Attachments to preserve in this pass (otherwise they are erased). +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt32Array` for more details. + .. rst-class:: classref-item-separator ---- @@ -152,6 +158,8 @@ Attachments to preserve in this pass (otherwise they are erased). If the color attachments are multisampled, non-multisampled resolve attachments can be provided. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt32Array` for more details. + .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` diff --git a/classes/class_rdshaderspirv.rst b/classes/class_rdshaderspirv.rst index 169f1b77c..0b8b16a92 100644 --- a/classes/class_rdshaderspirv.rst +++ b/classes/class_rdshaderspirv.rst @@ -93,6 +93,8 @@ Property Descriptions The SPIR-V bytecode for the compute shader stage. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedByteArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -110,6 +112,8 @@ The SPIR-V bytecode for the compute shader stage. The SPIR-V bytecode for the fragment shader stage. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedByteArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -127,6 +131,8 @@ The SPIR-V bytecode for the fragment shader stage. The SPIR-V bytecode for the tessellation control shader stage. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedByteArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -144,6 +150,8 @@ The SPIR-V bytecode for the tessellation control shader stage. The SPIR-V bytecode for the tessellation evaluation shader stage. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedByteArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -161,6 +169,8 @@ The SPIR-V bytecode for the tessellation evaluation shader stage. The SPIR-V bytecode for the vertex shader stage. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedByteArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_rectangleshape2d.rst b/classes/class_rectangleshape2d.rst index 4db6354ac..9d28e458c 100644 --- a/classes/class_rectangleshape2d.rst +++ b/classes/class_rectangleshape2d.rst @@ -28,9 +28,9 @@ A 2D rectangle shape, intended for use in physics. Usually used to provide a sha Tutorials --------- -- `2D Pong Demo `__ +- `2D Pong Demo `__ -- `2D Kinematic Character Demo `__ +- `2D Kinematic Character Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_regexmatch.rst b/classes/class_regexmatch.rst index ded48dc51..bdd12eaef 100644 --- a/classes/class_regexmatch.rst +++ b/classes/class_regexmatch.rst @@ -92,6 +92,8 @@ A dictionary of named groups and its corresponding group number. Only groups tha An :ref:`Array` of the match and its capturing groups. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_renderingdevice.rst b/classes/class_renderingdevice.rst index 9d89e1899..973064ab1 100644 --- a/classes/class_renderingdevice.rst +++ b/classes/class_renderingdevice.rst @@ -67,6 +67,8 @@ Methods +------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | |void| | :ref:`compute_list_dispatch`\ (\ compute_list\: :ref:`int`, x_groups\: :ref:`int`, y_groups\: :ref:`int`, z_groups\: :ref:`int`\ ) | +------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | |void| | :ref:`compute_list_dispatch_indirect`\ (\ compute_list\: :ref:`int`, buffer\: :ref:`RID`, offset\: :ref:`int`\ ) | + +------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | |void| | :ref:`compute_list_end`\ (\ ) | +------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | |void| | :ref:`compute_list_set_push_constant`\ (\ compute_list\: :ref:`int`, buffer\: :ref:`PackedByteArray`, size_bytes\: :ref:`int`\ ) | @@ -3791,11 +3793,7 @@ flags **PipelineDynamicStateFlags**: :ref:`PipelineDynamicStateFlags` **DYNAMIC_STATE_LINE_WIDTH** = ``1`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Allows dynamically changing the width of rendering lines. .. _class_RenderingDevice_constant_DYNAMIC_STATE_DEPTH_BIAS: @@ -3803,11 +3801,7 @@ flags **PipelineDynamicStateFlags**: :ref:`PipelineDynamicStateFlags` **DYNAMIC_STATE_DEPTH_BIAS** = ``2`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Allows dynamically changing the depth bias. .. _class_RenderingDevice_constant_DYNAMIC_STATE_BLEND_CONSTANTS: @@ -4727,6 +4721,18 @@ Submits the compute list for processing on the GPU. This is the compute equivale ---- +.. _class_RenderingDevice_method_compute_list_dispatch_indirect: + +.. rst-class:: classref-method + +|void| **compute_list_dispatch_indirect**\ (\ compute_list\: :ref:`int`, buffer\: :ref:`RID`, offset\: :ref:`int`\ ) + +Submits the compute list for processing on the GPU with the given group counts stored in the ``buffer`` at ``offset``. Buffer must have been created with :ref:`STORAGE_BUFFER_USAGE_DISPATCH_INDIRECT` flag. + +.. rst-class:: classref-item-separator + +---- + .. _class_RenderingDevice_method_compute_list_end: .. rst-class:: classref-method diff --git a/classes/class_renderingserver.rst b/classes/class_renderingserver.rst index 0bbf8350e..c3bc4657c 100644 --- a/classes/class_renderingserver.rst +++ b/classes/class_renderingserver.rst @@ -8492,7 +8492,7 @@ Sets the override material of a specific surface. Equivalent to :ref:`MeshInstan |void| **instance_set_transform**\ (\ instance\: :ref:`RID`, transform\: :ref:`Transform3D`\ ) -Sets the world space transform of the instance. Equivalent to :ref:`Node3D.transform`. +Sets the world space transform of the instance. Equivalent to :ref:`Node3D.global_transform`. .. rst-class:: classref-item-separator @@ -9518,7 +9518,7 @@ Set the entire data to use for drawing the ``multimesh`` at once to ``buffer`` ( The per-instance data size and expected data order is: -:: +.. code:: text 2D: - Position: 8 floats (8 floats for Transform2D) diff --git a/classes/class_resourceimportercsvtranslation.rst b/classes/class_resourceimportercsvtranslation.rst index b4b6510ca..b03df9e1b 100644 --- a/classes/class_resourceimportercsvtranslation.rst +++ b/classes/class_resourceimportercsvtranslation.rst @@ -23,7 +23,7 @@ Comma-separated values are a plain text table storage format. The format's simpl \ **Example CSV file:**\ -:: +.. code:: text keys,en,es,ja GREET,"Hello, friend!","Hola, amigo!",こんにちは diff --git a/classes/class_resourceimporterimagefont.rst b/classes/class_resourceimporterimagefont.rst index 11f551246..8615a9fe0 100644 --- a/classes/class_resourceimporterimagefont.rst +++ b/classes/class_resourceimporterimagefont.rst @@ -109,6 +109,8 @@ For any range, the character advance and offset can be customized by appending t Make sure :ref:`character_ranges` doesn't exceed the number of :ref:`columns` \* :ref:`rows` defined. Otherwise, the font will fail to import. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -183,6 +185,8 @@ Kerning pairs for the font. Kerning pair adjust the spacing between two characte Each string consist of three space separated values: "from" string, "to" string and integer offset. Each combination form the two string for a kerning pair, e.g, ``ab cd -3`` will create kerning pairs ``ac``, ``ad``, ``bc``, and ``bd`` with offset ``-3``. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_resourceloader.rst b/classes/class_resourceloader.rst index df029af21..5aa9bd317 100644 --- a/classes/class_resourceloader.rst +++ b/classes/class_resourceloader.rst @@ -30,7 +30,7 @@ It uses the many :ref:`ResourceFormatLoader` classes Tutorials --------- -- `OS Test Demo `__ +- `Operating System Testing Demo `__ .. rst-class:: classref-reftable-group @@ -280,6 +280,8 @@ GDScript has a simplified :ref:`@GDScript.load` bui \ **Note:** If :ref:`ProjectSettings.editor/export/convert_text_resources_to_binary` is ``true``, :ref:`@GDScript.load` will not be able to read converted files in an exported project. If you rely on run-time loading of files present within the PCK, set :ref:`ProjectSettings.editor/export/convert_text_resources_to_binary` to ``false``. +\ **Note:** Relative paths will be prefixed with ``"res://"`` before loading, to avoid unexpected results make sure your paths are absolute. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_richtextlabel.rst b/classes/class_richtextlabel.rst index 51d5e97d6..a44b60d86 100644 --- a/classes/class_richtextlabel.rst +++ b/classes/class_richtextlabel.rst @@ -36,9 +36,9 @@ Tutorials - :doc:`BBCode in RichTextLabel <../tutorials/ui/bbcode_in_richtextlabel>` -- `GUI Rich Text/BBcode Demo `__ +- `Rich Text Label with BBCode Demo `__ -- `OS Test Demo `__ +- `Operating System Testing Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_rigidbody2d.rst b/classes/class_rigidbody2d.rst index e1f752bd4..39c48fbd2 100644 --- a/classes/class_rigidbody2d.rst +++ b/classes/class_rigidbody2d.rst @@ -36,9 +36,9 @@ If you need to override the default physics behavior, you can write a custom for Tutorials --------- -- `2D Physics Platformer Demo `__ +- `2D Physics Platformer Demo `__ -- `Instancing Demo `__ +- `Instancing Demo `__ .. rst-class:: classref-reftable-group @@ -538,7 +538,9 @@ Continuous collision detection tries to predict where a moving body will collide - |void| **set_use_custom_integrator**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **is_using_custom_integrator**\ (\ ) -If ``true``, internal force integration is disabled for this body. Aside from collision response, the body will only move as determined by the :ref:`_integrate_forces` function. +If ``true``, the standard force integration (like gravity or damping) will be disabled for this body. Other than collision response, the body will only move as determined by the :ref:`_integrate_forces` method, if that virtual method is overridden. + +Setting this property will call the method :ref:`PhysicsServer2D.body_set_omit_force_integration` internally. .. rst-class:: classref-item-separator @@ -801,7 +803,7 @@ Method Descriptions |void| **_integrate_forces**\ (\ state\: :ref:`PhysicsDirectBodyState2D`\ ) |virtual| -Allows you to read and safely modify the simulation state for the object. Use this instead of :ref:`Node._physics_process` if you need to directly change the body's ``position`` or other physics properties. By default, it works in addition to the usual physics behavior, but :ref:`custom_integrator` allows you to disable the default behavior and write custom force integration for a body. +Called during physics processing, allowing you to read and safely modify the simulation state for the object. By default, it is called before the standard force integration, but the :ref:`custom_integrator` property allows you to disable the standard force integration and do fully custom force integration for a body. .. rst-class:: classref-item-separator diff --git a/classes/class_rigidbody3d.rst b/classes/class_rigidbody3d.rst index a33a69d41..44086f6b9 100644 --- a/classes/class_rigidbody3d.rst +++ b/classes/class_rigidbody3d.rst @@ -38,9 +38,9 @@ Tutorials - :doc:`Physics introduction <../tutorials/physics/physics_introduction>` -- `3D Truck Town Demo `__ +- `3D Truck Town Demo `__ -- `3D Physics Tests Demo `__ +- `3D Physics Tests Demo `__ .. rst-class:: classref-reftable-group @@ -508,7 +508,9 @@ Continuous collision detection tries to predict where a moving body will collide - |void| **set_use_custom_integrator**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **is_using_custom_integrator**\ (\ ) -If ``true``, internal force integration will be disabled (like gravity or air friction) for this body. Other than collision response, the body will only move as determined by the :ref:`_integrate_forces` function, if defined. +If ``true``, the standard force integration (like gravity or damping) will be disabled for this body. Other than collision response, the body will only move as determined by the :ref:`_integrate_forces` method, if that virtual method is overridden. + +Setting this property will call the method :ref:`PhysicsServer3D.body_set_omit_force_integration` internally. .. rst-class:: classref-item-separator @@ -771,7 +773,7 @@ Method Descriptions |void| **_integrate_forces**\ (\ state\: :ref:`PhysicsDirectBodyState3D`\ ) |virtual| -Called during physics processing, allowing you to read and safely modify the simulation state for the object. By default, it works in addition to the usual physics behavior, but the :ref:`custom_integrator` property allows you to disable the default behavior and do fully custom force integration for a body. +Called during physics processing, allowing you to read and safely modify the simulation state for the object. By default, it is called before the standard force integration, but the :ref:`custom_integrator` property allows you to disable the standard force integration and do fully custom force integration for a body. .. rst-class:: classref-item-separator diff --git a/classes/class_shapecast2d.rst b/classes/class_shapecast2d.rst index ee7ed2c9a..b6e233e86 100644 --- a/classes/class_shapecast2d.rst +++ b/classes/class_shapecast2d.rst @@ -348,6 +348,8 @@ The fraction from the **ShapeCast2D**'s origin to its :ref:`target_position` (between 0 and 1) of how far the shape must move to trigger a collision. +In ideal conditions this would be the same as :ref:`get_closest_collision_safe_fraction`, however shape casting is calculated in discrete steps, so the precise point of collision can occur between two calculated positions. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_shapecast3d.rst b/classes/class_shapecast3d.rst index 9854997ba..02f1eb48d 100644 --- a/classes/class_shapecast3d.rst +++ b/classes/class_shapecast3d.rst @@ -371,6 +371,8 @@ The fraction from the **ShapeCast3D**'s origin to its :ref:`target_position` (between 0 and 1) of how far the shape must move to trigger a collision. +In ideal conditions this would be the same as :ref:`get_closest_collision_safe_fraction`, however shape casting is calculated in discrete steps, so the precise point of collision can occur between two calculated positions. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_skeleton3d.rst b/classes/class_skeleton3d.rst index 4a1bd4659..95e4ce007 100644 --- a/classes/class_skeleton3d.rst +++ b/classes/class_skeleton3d.rst @@ -30,9 +30,7 @@ Note that "global pose" below refers to the overall transform of the bone with r Tutorials --------- -- `3D Inverse Kinematics Demo `__ - -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_skeletonik3d.rst b/classes/class_skeletonik3d.rst index 602dcb24f..e6371d13b 100644 --- a/classes/class_skeletonik3d.rst +++ b/classes/class_skeletonik3d.rst @@ -43,13 +43,6 @@ SkeletonIK3D is used to rotate all bones of a :ref:`Skeleton3D # Apply zero IK effect (a value at or below 0.01 also removes bones_global_pose_override on Skeleton) skeleton_ik_node.set_influence(0.0) -.. rst-class:: classref-introduction-group - -Tutorials ---------- - -- `3D Inverse Kinematics Demo `__ - .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_skeletonprofilehumanoid.rst b/classes/class_skeletonprofilehumanoid.rst index 2f89d331d..814d3d51a 100644 --- a/classes/class_skeletonprofilehumanoid.rst +++ b/classes/class_skeletonprofilehumanoid.rst @@ -23,7 +23,7 @@ A :ref:`SkeletonProfile` as a preset that is optimized fo A humanoid skeleton profile contains 54 bones divided in 4 groups: ``"Body"``, ``"Face"``, ``"LeftHand"``, and ``"RightHand"``. It is structured as follows: -:: +.. code:: text Root └─ Hips diff --git a/classes/class_skinreference.rst b/classes/class_skinreference.rst index b44bd1c06..178488890 100644 --- a/classes/class_skinreference.rst +++ b/classes/class_skinreference.rst @@ -12,9 +12,22 @@ SkinReference **Inherits:** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A reference-counted holder object for a skeleton RID used in the :ref:`RenderingServer`. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +An internal object containing a mapping from a :ref:`Skin` used within the context of a particular :ref:`MeshInstance3D` to refer to the skeleton's :ref:`RID` in the RenderingServer. + +See also :ref:`MeshInstance3D.get_skin_reference` and :ref:`RenderingServer.instance_attach_skeleton`. + +Note that despite the similar naming, the skeleton RID used in the :ref:`RenderingServer` does not have a direct one-to-one correspondence to a :ref:`Skeleton3D` node. + +In particular, a :ref:`Skeleton3D` node with no :ref:`MeshInstance3D` children may be unknown to the :ref:`RenderingServer`. + +On the other hand, a :ref:`Skeleton3D` with multiple :ref:`MeshInstance3D` nodes which each have different :ref:`MeshInstance3D.skin` objects may have multiple SkinReference instances (and hence, multiple skeleton :ref:`RID`\ s). .. rst-class:: classref-reftable-group @@ -45,9 +58,7 @@ Method Descriptions :ref:`RID` **get_skeleton**\ (\ ) |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Returns the :ref:`RID` owned by this SkinReference, as returned by :ref:`RenderingServer.skeleton_create`. .. rst-class:: classref-item-separator @@ -59,9 +70,9 @@ Method Descriptions :ref:`Skin` **get_skin**\ (\ ) |const| -.. container:: contribute +Returns the :ref:`Skin` connected to this SkinReference. In the case of :ref:`MeshInstance3D` with no :ref:`MeshInstance3D.skin` assigned, this will reference an internal default :ref:`Skin` owned by that :ref:`MeshInstance3D`. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Note that a single :ref:`Skin` may have more than one **SkinReference** in the case that it is shared by meshes across multiple :ref:`Skeleton3D` nodes. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_sliderjoint3d.rst b/classes/class_sliderjoint3d.rst index 9666bba28..360c9eff0 100644 --- a/classes/class_sliderjoint3d.rst +++ b/classes/class_sliderjoint3d.rst @@ -110,7 +110,7 @@ enum **Param**: :ref:`Param` **PARAM_LINEAR_LIMIT_UPPER** = ``0`` -The maximum difference between the pivot points on their X axis before damping happens. +Constant for accessing :ref:`linear_limit/upper_distance`. The maximum difference between the pivot points on their X axis before damping happens. .. _class_SliderJoint3D_constant_PARAM_LINEAR_LIMIT_LOWER: @@ -118,7 +118,7 @@ The maximum difference between the pivot points on their X axis before damping h :ref:`Param` **PARAM_LINEAR_LIMIT_LOWER** = ``1`` -The minimum difference between the pivot points on their X axis before damping happens. +Constant for accessing :ref:`linear_limit/lower_distance`. The minimum difference between the pivot points on their X axis before damping happens. .. _class_SliderJoint3D_constant_PARAM_LINEAR_LIMIT_SOFTNESS: @@ -126,7 +126,7 @@ The minimum difference between the pivot points on their X axis before damping h :ref:`Param` **PARAM_LINEAR_LIMIT_SOFTNESS** = ``2`` -A factor applied to the movement across the slider axis once the limits get surpassed. The lower, the slower the movement. +Constant for accessing :ref:`linear_limit/softness`. A factor applied to the movement across the slider axis once the limits get surpassed. The lower, the slower the movement. .. _class_SliderJoint3D_constant_PARAM_LINEAR_LIMIT_RESTITUTION: @@ -134,7 +134,7 @@ A factor applied to the movement across the slider axis once the limits get surp :ref:`Param` **PARAM_LINEAR_LIMIT_RESTITUTION** = ``3`` -The amount of restitution once the limits are surpassed. The lower, the more velocity-energy gets lost. +Constant for accessing :ref:`linear_limit/restitution`. The amount of restitution once the limits are surpassed. The lower, the more velocity-energy gets lost. .. _class_SliderJoint3D_constant_PARAM_LINEAR_LIMIT_DAMPING: @@ -142,7 +142,7 @@ The amount of restitution once the limits are surpassed. The lower, the more vel :ref:`Param` **PARAM_LINEAR_LIMIT_DAMPING** = ``4`` -The amount of damping once the slider limits are surpassed. +Constant for accessing :ref:`linear_limit/damping`. The amount of damping once the slider limits are surpassed. .. _class_SliderJoint3D_constant_PARAM_LINEAR_MOTION_SOFTNESS: @@ -150,7 +150,7 @@ The amount of damping once the slider limits are surpassed. :ref:`Param` **PARAM_LINEAR_MOTION_SOFTNESS** = ``5`` -A factor applied to the movement across the slider axis as long as the slider is in the limits. The lower, the slower the movement. +Constant for accessing :ref:`linear_motion/softness`. A factor applied to the movement across the slider axis as long as the slider is in the limits. The lower, the slower the movement. .. _class_SliderJoint3D_constant_PARAM_LINEAR_MOTION_RESTITUTION: @@ -158,7 +158,7 @@ A factor applied to the movement across the slider axis as long as the slider is :ref:`Param` **PARAM_LINEAR_MOTION_RESTITUTION** = ``6`` -The amount of restitution inside the slider limits. +Constant for accessing :ref:`linear_motion/restitution`. The amount of restitution inside the slider limits. .. _class_SliderJoint3D_constant_PARAM_LINEAR_MOTION_DAMPING: @@ -166,7 +166,7 @@ The amount of restitution inside the slider limits. :ref:`Param` **PARAM_LINEAR_MOTION_DAMPING** = ``7`` -The amount of damping inside the slider limits. +Constant for accessing :ref:`linear_motion/damping`. The amount of damping inside the slider limits. .. _class_SliderJoint3D_constant_PARAM_LINEAR_ORTHOGONAL_SOFTNESS: @@ -174,7 +174,7 @@ The amount of damping inside the slider limits. :ref:`Param` **PARAM_LINEAR_ORTHOGONAL_SOFTNESS** = ``8`` -A factor applied to the movement across axes orthogonal to the slider. +Constant for accessing :ref:`linear_ortho/softness`. A factor applied to the movement across axes orthogonal to the slider. .. _class_SliderJoint3D_constant_PARAM_LINEAR_ORTHOGONAL_RESTITUTION: @@ -182,7 +182,7 @@ A factor applied to the movement across axes orthogonal to the slider. :ref:`Param` **PARAM_LINEAR_ORTHOGONAL_RESTITUTION** = ``9`` -The amount of restitution when movement is across axes orthogonal to the slider. +Constant for accessing :ref:`linear_motion/restitution`. The amount of restitution when movement is across axes orthogonal to the slider. .. _class_SliderJoint3D_constant_PARAM_LINEAR_ORTHOGONAL_DAMPING: @@ -190,7 +190,7 @@ The amount of restitution when movement is across axes orthogonal to the slider. :ref:`Param` **PARAM_LINEAR_ORTHOGONAL_DAMPING** = ``10`` -The amount of damping when movement is across axes orthogonal to the slider. +Constant for accessing :ref:`linear_motion/damping`. The amount of damping when movement is across axes orthogonal to the slider. .. _class_SliderJoint3D_constant_PARAM_ANGULAR_LIMIT_UPPER: @@ -198,7 +198,7 @@ The amount of damping when movement is across axes orthogonal to the slider. :ref:`Param` **PARAM_ANGULAR_LIMIT_UPPER** = ``11`` -The upper limit of rotation in the slider. +Constant for accessing :ref:`angular_limit/upper_angle`. The upper limit of rotation in the slider. .. _class_SliderJoint3D_constant_PARAM_ANGULAR_LIMIT_LOWER: @@ -206,7 +206,7 @@ The upper limit of rotation in the slider. :ref:`Param` **PARAM_ANGULAR_LIMIT_LOWER** = ``12`` -The lower limit of rotation in the slider. +Constant for accessing :ref:`angular_limit/lower_angle`. The lower limit of rotation in the slider. .. _class_SliderJoint3D_constant_PARAM_ANGULAR_LIMIT_SOFTNESS: @@ -214,7 +214,7 @@ The lower limit of rotation in the slider. :ref:`Param` **PARAM_ANGULAR_LIMIT_SOFTNESS** = ``13`` -A factor applied to the all rotation once the limit is surpassed. +Constant for accessing :ref:`angular_limit/softness`. A factor applied to the all rotation once the limit is surpassed. .. _class_SliderJoint3D_constant_PARAM_ANGULAR_LIMIT_RESTITUTION: @@ -222,7 +222,7 @@ A factor applied to the all rotation once the limit is surpassed. :ref:`Param` **PARAM_ANGULAR_LIMIT_RESTITUTION** = ``14`` -The amount of restitution of the rotation when the limit is surpassed. +Constant for accessing :ref:`angular_limit/restitution`. The amount of restitution of the rotation when the limit is surpassed. .. _class_SliderJoint3D_constant_PARAM_ANGULAR_LIMIT_DAMPING: @@ -230,7 +230,7 @@ The amount of restitution of the rotation when the limit is surpassed. :ref:`Param` **PARAM_ANGULAR_LIMIT_DAMPING** = ``15`` -The amount of damping of the rotation when the limit is surpassed. +Constant for accessing :ref:`angular_limit/damping`. The amount of damping of the rotation when the limit is surpassed. .. _class_SliderJoint3D_constant_PARAM_ANGULAR_MOTION_SOFTNESS: @@ -238,7 +238,7 @@ The amount of damping of the rotation when the limit is surpassed. :ref:`Param` **PARAM_ANGULAR_MOTION_SOFTNESS** = ``16`` -A factor applied to the all rotation in the limits. +Constant for accessing :ref:`angular_motion/softness`. A factor applied to the all rotation in the limits. .. _class_SliderJoint3D_constant_PARAM_ANGULAR_MOTION_RESTITUTION: @@ -246,7 +246,7 @@ A factor applied to the all rotation in the limits. :ref:`Param` **PARAM_ANGULAR_MOTION_RESTITUTION** = ``17`` -The amount of restitution of the rotation in the limits. +Constant for accessing :ref:`angular_motion/restitution`. The amount of restitution of the rotation in the limits. .. _class_SliderJoint3D_constant_PARAM_ANGULAR_MOTION_DAMPING: @@ -254,7 +254,7 @@ The amount of restitution of the rotation in the limits. :ref:`Param` **PARAM_ANGULAR_MOTION_DAMPING** = ``18`` -The amount of damping of the rotation in the limits. +Constant for accessing :ref:`angular_motion/damping`. The amount of damping of the rotation in the limits. .. _class_SliderJoint3D_constant_PARAM_ANGULAR_ORTHOGONAL_SOFTNESS: @@ -262,7 +262,7 @@ The amount of damping of the rotation in the limits. :ref:`Param` **PARAM_ANGULAR_ORTHOGONAL_SOFTNESS** = ``19`` -A factor applied to the all rotation across axes orthogonal to the slider. +Constant for accessing :ref:`angular_ortho/softness`. A factor applied to the all rotation across axes orthogonal to the slider. .. _class_SliderJoint3D_constant_PARAM_ANGULAR_ORTHOGONAL_RESTITUTION: @@ -270,7 +270,7 @@ A factor applied to the all rotation across axes orthogonal to the slider. :ref:`Param` **PARAM_ANGULAR_ORTHOGONAL_RESTITUTION** = ``20`` -The amount of restitution of the rotation across axes orthogonal to the slider. +Constant for accessing :ref:`angular_ortho/restitution`. The amount of restitution of the rotation across axes orthogonal to the slider. .. _class_SliderJoint3D_constant_PARAM_ANGULAR_ORTHOGONAL_DAMPING: @@ -278,7 +278,7 @@ The amount of restitution of the rotation across axes orthogonal to the slider. :ref:`Param` **PARAM_ANGULAR_ORTHOGONAL_DAMPING** = ``21`` -The amount of damping of the rotation across axes orthogonal to the slider. +Constant for accessing :ref:`angular_ortho/damping`. The amount of damping of the rotation across axes orthogonal to the slider. .. _class_SliderJoint3D_constant_PARAM_MAX: @@ -688,9 +688,7 @@ Method Descriptions :ref:`float` **get_param**\ (\ param\: :ref:`Param`\ ) |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Returns the value of the given parameter (see :ref:`Param` constants). .. rst-class:: classref-item-separator @@ -702,9 +700,7 @@ Method Descriptions |void| **set_param**\ (\ param\: :ref:`Param`, value\: :ref:`float`\ ) -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Assigns ``value`` to the given parameter (see :ref:`Param` constants). .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_softbody3d.rst b/classes/class_softbody3d.rst index 2f26ce9ea..2983a198b 100644 --- a/classes/class_softbody3d.rst +++ b/classes/class_softbody3d.rst @@ -21,6 +21,8 @@ Description A deformable 3D physics mesh. Used to create elastic or deformable objects such as cloth, rubber, or other flexible materials. +Additionally, **SoftBody3D** is subject to wind forces defined in :ref:`Area3D` (see :ref:`Area3D.wind_source_path`, :ref:`Area3D.wind_force_magnitude`, and :ref:`Area3D.wind_attenuation_factor`). + \ **Note:** There are many known bugs in **SoftBody3D**. Therefore, it's not recommended to use them for things that can affect gameplay (such as trampolines). .. rst-class:: classref-introduction-group diff --git a/classes/class_sphereshape3d.rst b/classes/class_sphereshape3d.rst index fb3fe3564..3c8818a9b 100644 --- a/classes/class_sphereshape3d.rst +++ b/classes/class_sphereshape3d.rst @@ -28,7 +28,7 @@ A 3D sphere shape, intended for use in physics. Usually used to provide a shape Tutorials --------- -- `3D Physics Tests Demo `__ +- `3D Physics Tests Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_spotlight3d.rst b/classes/class_spotlight3d.rst index fca3f8fdd..92f89b7f5 100644 --- a/classes/class_spotlight3d.rst +++ b/classes/class_spotlight3d.rst @@ -34,7 +34,7 @@ Tutorials - :doc:`Faking global illumination <../tutorials/3d/global_illumination/faking_global_illumination>` -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_sprite2d.rst b/classes/class_sprite2d.rst index edf2334eb..c19fa0203 100644 --- a/classes/class_sprite2d.rst +++ b/classes/class_sprite2d.rst @@ -26,7 +26,7 @@ A node that displays a 2D texture. The texture displayed can be a region from a Tutorials --------- -- `Instancing Demo `__ +- `Instancing Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_staticbody3d.rst b/classes/class_staticbody3d.rst index 2bfc213e7..1ce9f0f21 100644 --- a/classes/class_staticbody3d.rst +++ b/classes/class_staticbody3d.rst @@ -32,11 +32,11 @@ When **StaticBody3D** is moved, it is teleported to its new position without aff Tutorials --------- -- `3D Physics Tests Demo `__ +- `3D Physics Tests Demo `__ -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_streampeerbuffer.rst b/classes/class_streampeerbuffer.rst index eeb93a882..c4b6388e5 100644 --- a/classes/class_streampeerbuffer.rst +++ b/classes/class_streampeerbuffer.rst @@ -79,6 +79,8 @@ Property Descriptions The underlying data buffer. Setting this value resets the cursor. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedByteArray` for more details. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_string.rst b/classes/class_string.rst index 8ff65e475..6d23cd8f5 100644 --- a/classes/class_string.rst +++ b/classes/class_string.rst @@ -703,6 +703,15 @@ Some additional handling is performed when ``values`` is an :ref:`Array` tutorial. +\ **Note:** The replacement of placeholders is not done all at once, instead each placeholder is replaced in the order they are passed, this means that if one of the replacement strings contains a key it will also be replaced. This can be very powerful, but can also cause unexpected results if you are not careful. If you do not need to perform replacement in the replacement strings, make sure your replacements do not contain placeholders to ensure reliable results. + +:: + + print("{0} {1}".format(["{1}", "x"])) # Prints "x x". + print("{0} {1}".format(["x", "{0}"])) # Prints "x {0}". + print("{foo} {bar}".format({"foo": "{bar}", "bar": "baz"})) # Prints "baz baz". + print("{foo} {bar}".format({"bar": "baz", "foo": "{bar}"})) # Prints "{bar} baz". + \ **Note:** In C#, it's recommended to `interpolate strings with "$" `__, instead. .. rst-class:: classref-item-separator diff --git a/classes/class_styleboxflat.rst b/classes/class_styleboxflat.rst index 628eb37f2..0fb0426bf 100644 --- a/classes/class_styleboxflat.rst +++ b/classes/class_styleboxflat.rst @@ -25,7 +25,7 @@ Setting corner radius to high values is allowed. As soon as corners overlap, the \ **Example:**\ -:: +.. code:: text height = 30 corner_radius_top_left = 50 @@ -33,7 +33,7 @@ Setting corner radius to high values is allowed. As soon as corners overlap, the The relative system now would take the 1:2 ratio of the two left corners to calculate the actual corner width. Both corners added will **never** be more than the height. Result: -:: +.. code:: text corner_radius_top_left: 10 corner_radius_bottom_left: 20 diff --git a/classes/class_subviewport.rst b/classes/class_subviewport.rst index 048fb291b..ab7fa0a65 100644 --- a/classes/class_subviewport.rst +++ b/classes/class_subviewport.rst @@ -32,17 +32,17 @@ Tutorials - :doc:`Viewport and canvas transforms <../tutorials/2d/2d_transforms>` -- `GUI in 3D Demo `__ +- `GUI in 3D Viewport Demo `__ -- `3D in 2D Demo `__ +- `3D in 2D Viewport Demo `__ -- `2D in 3D Demo `__ +- `2D in 3D Viewport Demo `__ -- `Screen Capture Demo `__ +- `Screen Capture Demo `__ -- `Dynamic Split Screen Demo `__ +- `Dynamic Split Screen Demo `__ -- `3D Viewport Scaling Demo `__ +- `3D Resolution Scaling Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_surfacetool.rst b/classes/class_surfacetool.rst index ce3104e5e..6c632817f 100644 --- a/classes/class_surfacetool.rst +++ b/classes/class_surfacetool.rst @@ -59,7 +59,7 @@ Tutorials - :doc:`Using the SurfaceTool <../tutorials/3d/procedural_geometry/surfacetool>` -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_systemfont.rst b/classes/class_systemfont.rst index 81de38285..9e4e8f220 100644 --- a/classes/class_systemfont.rst +++ b/classes/class_systemfont.rst @@ -159,6 +159,8 @@ If set to ``true``, italic or oblique font is preferred. Array of font family names to search, first matching font found is used. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_texturebutton.rst b/classes/class_texturebutton.rst index f6e54b07a..57cc5d956 100644 --- a/classes/class_texturebutton.rst +++ b/classes/class_texturebutton.rst @@ -30,7 +30,7 @@ See also :ref:`BaseButton` which contains common properties an Tutorials --------- -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_texturerect.rst b/classes/class_texturerect.rst index 7757575ea..ab9d5711c 100644 --- a/classes/class_texturerect.rst +++ b/classes/class_texturerect.rst @@ -26,7 +26,7 @@ A control that displays a texture, for example an icon inside a GUI. The texture Tutorials --------- -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_thread.rst b/classes/class_thread.rst index 1fb8bcef9..4a99c43a3 100644 --- a/classes/class_thread.rst +++ b/classes/class_thread.rst @@ -40,7 +40,7 @@ Tutorials - :doc:`Thread-safe APIs <../tutorials/performance/thread_safe_apis>` -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_tilemap.rst b/classes/class_tilemap.rst index 4620d55e6..759f3bccd 100644 --- a/classes/class_tilemap.rst +++ b/classes/class_tilemap.rst @@ -37,17 +37,17 @@ Tutorials - :doc:`Using Tilemaps <../tutorials/2d/using_tilemaps>` -- `2D Platformer Demo `__ +- `2D Platformer Demo `__ -- `2D Isometric Demo `__ +- `2D Isometric Demo `__ -- `2D Hexagonal Demo `__ +- `2D Hexagonal Demo `__ -- `2D Navigation Astar Demo `__ +- `2D Grid-based Navigation with AStarGrid2D Demo `__ -- `2D Role Playing Game Demo `__ +- `2D Role Playing Game (RPG) Demo `__ -- `2D Kinematic Character Demo `__ +- `2D Kinematic Character Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_tilemaplayer.rst b/classes/class_tilemaplayer.rst index c9884e074..50fb0bb18 100644 --- a/classes/class_tilemaplayer.rst +++ b/classes/class_tilemaplayer.rst @@ -33,27 +33,27 @@ Properties .. table:: :widths: auto - +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+---------------------------+ - | :ref:`bool` | :ref:`collision_enabled` | ``true`` | - +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+---------------------------+ - | :ref:`DebugVisibilityMode` | :ref:`collision_visibility_mode` | ``0`` | - +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+---------------------------+ - | :ref:`bool` | :ref:`enabled` | ``true`` | - +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+---------------------------+ - | :ref:`bool` | :ref:`navigation_enabled` | ``true`` | - +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+---------------------------+ - | :ref:`DebugVisibilityMode` | :ref:`navigation_visibility_mode` | ``0`` | - +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+---------------------------+ - | :ref:`int` | :ref:`rendering_quadrant_size` | ``16`` | - +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+---------------------------+ - | :ref:`PackedByteArray` | :ref:`tile_map_data` | ``PackedByteArray(0, 0)`` | - +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+---------------------------+ - | :ref:`TileSet` | :ref:`tile_set` | | - +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+---------------------------+ - | :ref:`bool` | :ref:`use_kinematic_bodies` | ``false`` | - +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+---------------------------+ - | :ref:`int` | :ref:`y_sort_origin` | ``0`` | - +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+---------------------------+ + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+-----------------------------+ + | :ref:`bool` | :ref:`collision_enabled` | ``true`` | + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+-----------------------------+ + | :ref:`DebugVisibilityMode` | :ref:`collision_visibility_mode` | ``0`` | + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+-----------------------------+ + | :ref:`bool` | :ref:`enabled` | ``true`` | + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+-----------------------------+ + | :ref:`bool` | :ref:`navigation_enabled` | ``true`` | + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+-----------------------------+ + | :ref:`DebugVisibilityMode` | :ref:`navigation_visibility_mode` | ``0`` | + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+-----------------------------+ + | :ref:`int` | :ref:`rendering_quadrant_size` | ``16`` | + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+-----------------------------+ + | :ref:`PackedByteArray` | :ref:`tile_map_data` | ``PackedByteArray("AAA=")`` | + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+-----------------------------+ + | :ref:`TileSet` | :ref:`tile_set` | | + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+-----------------------------+ + | :ref:`bool` | :ref:`use_kinematic_bodies` | ``false`` | + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+-----------------------------+ + | :ref:`int` | :ref:`y_sort_origin` | ``0`` | + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------+-----------------------------+ .. rst-class:: classref-reftable-group @@ -298,7 +298,7 @@ The quadrant size does not apply on a Y-sorted **TileMapLayer**, as tiles are be .. rst-class:: classref-property -:ref:`PackedByteArray` **tile_map_data** = ``PackedByteArray(0, 0)`` +:ref:`PackedByteArray` **tile_map_data** = ``PackedByteArray("AAA=")`` .. rst-class:: classref-property-setget @@ -307,6 +307,8 @@ The quadrant size does not apply on a Y-sorted **TileMapLayer**, as tiles are be The raw tile map data as a byte array. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedByteArray` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_tileset.rst b/classes/class_tileset.rst index acf225d13..b7aec4811 100644 --- a/classes/class_tileset.rst +++ b/classes/class_tileset.rst @@ -38,17 +38,17 @@ Tutorials - :doc:`Using Tilemaps <../tutorials/2d/using_tilemaps>` -- `2D Platformer Demo `__ +- `2D Platformer Demo `__ -- `2D Isometric Demo `__ +- `2D Isometric Demo `__ -- `2D Hexagonal Demo `__ +- `2D Hexagonal Demo `__ -- `2D Navigation Astar Demo `__ +- `2D Grid-based Navigation with AStarGrid2D Demo `__ -- `2D Role Playing Game Demo `__ +- `2D Role Playing Game (RPG) Demo `__ -- `2D Kinematic Character Demo `__ +- `2D Kinematic Character Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_timer.rst b/classes/class_timer.rst index e3a934e72..f30a3d323 100644 --- a/classes/class_timer.rst +++ b/classes/class_timer.rst @@ -39,7 +39,7 @@ Without requiring much code, a timer node can be added and configured in the edi Tutorials --------- -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_transform2d.rst b/classes/class_transform2d.rst index 3f22eac7e..c88057f0b 100644 --- a/classes/class_transform2d.rst +++ b/classes/class_transform2d.rst @@ -34,9 +34,9 @@ Tutorials - :doc:`Matrices and transforms <../tutorials/math/matrices_and_transforms>` -- `Matrix Transform Demo `__ +- `Matrix Transform Demo `__ -- `2.5D Demo `__ +- `2.5D Game Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_transform3d.rst b/classes/class_transform3d.rst index b71703dac..81bd3ebb2 100644 --- a/classes/class_transform3d.rst +++ b/classes/class_transform3d.rst @@ -38,11 +38,11 @@ Tutorials - :doc:`Using 3D transforms <../tutorials/3d/using_transforms>` -- `Matrix Transform Demo `__ +- `Matrix Transform Demo `__ -- `3D Platformer Demo `__ +- `3D Platformer Demo `__ -- `2.5D Demo `__ +- `2.5D Game Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_undoredo.rst b/classes/class_undoredo.rst index 25d7793f6..8fc8c1b1f 100644 --- a/classes/class_undoredo.rst +++ b/classes/class_undoredo.rst @@ -230,7 +230,7 @@ Makes "do"/"undo" operations stay in separate actions. :ref:`MergeMode` **MERGE_ENDS** = ``1`` -Makes so that the action's "undo" operations are from the first action created and the "do" operations are from the last subsequent action with the same name. +Merges this action with the previous one if they have the same name. Keeps only the first action's "undo" operations and the last action's "do" operations. Useful for sequential changes to a single value. .. _class_UndoRedo_constant_MERGE_ALL: @@ -238,7 +238,7 @@ Makes so that the action's "undo" operations are from the first action created a :ref:`MergeMode` **MERGE_ALL** = ``2`` -Makes subsequent actions with the same name be merged into one. +Merges this action with the previous one if they have the same name. .. rst-class:: classref-section-separator @@ -301,7 +301,9 @@ Register a ``property`` that would change its value to ``value`` when the action |void| **add_do_reference**\ (\ object\: :ref:`Object`\ ) -Register a reference for "do" that will be erased if the "do" history is lost. This is useful mostly for new nodes created for the "do" call. Do not use for resources. +Register a reference to an object that will be erased if the "do" history is deleted. This is useful for objects added by the "do" action and removed by the "undo" action. + +When the "do" history is deleted, if the object is a :ref:`RefCounted`, it will be unreferenced. Otherwise, it will be freed. Do not use for resources. :: @@ -346,7 +348,9 @@ Register a ``property`` that would change its value to ``value`` when the action |void| **add_undo_reference**\ (\ object\: :ref:`Object`\ ) -Register a reference for "undo" that will be erased if the "undo" history is lost. This is useful mostly for nodes removed with the "do" call (not the "undo" call!). +Register a reference to an object that will be erased if the "undo" history is deleted. This is useful for objects added by the "undo" action and removed by the "do" action. + +When the "undo" history is deleted, if the object is a :ref:`RefCounted`, it will be unreferenced. Otherwise, it will be freed. Do not use for resources. :: diff --git a/classes/class_upnpdevice.rst b/classes/class_upnpdevice.rst index 8fc31a54f..5fb89a4a4 100644 --- a/classes/class_upnpdevice.rst +++ b/classes/class_upnpdevice.rst @@ -106,6 +106,8 @@ Empty HTTP response. :ref:`IGDStatus` **IGD_STATUS_NO_URLS** = ``3`` +**Deprecated:** This value is no longer used. + Returned response contained no URLs. .. _class_UPNPDevice_constant_IGD_STATUS_NO_IGD: @@ -146,6 +148,8 @@ Invalid control. :ref:`IGDStatus` **IGD_STATUS_MALLOC_ERROR** = ``8`` +**Deprecated:** This value is no longer used. + Memory allocation error. .. _class_UPNPDevice_constant_IGD_STATUS_UNKNOWN_ERROR: diff --git a/classes/class_vboxcontainer.rst b/classes/class_vboxcontainer.rst index 21b6e0a68..320831064 100644 --- a/classes/class_vboxcontainer.rst +++ b/classes/class_vboxcontainer.rst @@ -30,7 +30,7 @@ Tutorials - :doc:`Using Containers <../tutorials/ui/gui_containers>` -- `3D Voxel Demo `__ +- `3D Voxel Demo `__ .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_vector2.rst b/classes/class_vector2.rst index e04c02f2d..475ea51fe 100644 --- a/classes/class_vector2.rst +++ b/classes/class_vector2.rst @@ -38,7 +38,7 @@ Tutorials - `3Blue1Brown Essence of Linear Algebra `__ -- `Matrix Transform Demo `__ +- `Matrix Transform Demo `__ - `All 2D Demos `__ @@ -153,7 +153,7 @@ Methods +-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`project`\ (\ b\: :ref:`Vector2`\ ) |const| | +-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Vector2` | :ref:`reflect`\ (\ n\: :ref:`Vector2`\ ) |const| | + | :ref:`Vector2` | :ref:`reflect`\ (\ line\: :ref:`Vector2`\ ) |const| | +-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`rotated`\ (\ angle\: :ref:`float`\ ) |const| | +-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -482,7 +482,9 @@ Returns the point at the given ``t`` on the `Bézier curve ` **bounce**\ (\ n\: :ref:`Vector2`\ ) |const| -Returns a new vector "bounced off" from a plane defined by the given normal. +Returns the vector "bounced off" from a line defined by the given normal ``n`` perpendicular to the line. + +\ **Note:** :ref:`bounce` performs the operation that most engines and frameworks call ``reflect()``. .. rst-class:: classref-item-separator @@ -520,7 +522,7 @@ Returns a new vector with all components clamped between the components of ``min Returns the 2D analog of the cross product for this vector and ``with``. -This is the signed area of the parallelogram formed by the two vectors. If the second vector is clockwise from the first vector, then the cross product is the positive area. If counter-clockwise, the cross product is the negative area. +This is the signed area of the parallelogram formed by the two vectors. If the second vector is clockwise from the first vector, then the cross product is the positive area. If counter-clockwise, the cross product is the negative area. If the two vectors are parallel this returns zero, making it useful for testing if two vectors are parallel. \ **Note:** Cross product is not defined in 2D mathematically. This method embeds the 2D vectors in the XY plane of 3D space and uses their cross product's Z component as the analog. @@ -844,9 +846,11 @@ Returns a new vector resulting from projecting this vector onto the given vector .. rst-class:: classref-method -:ref:`Vector2` **reflect**\ (\ n\: :ref:`Vector2`\ ) |const| +:ref:`Vector2` **reflect**\ (\ line\: :ref:`Vector2`\ ) |const| -Returns the result of reflecting the vector from a line defined by the given direction vector ``n``. +Returns the result of reflecting the vector from a line defined by the given direction vector ``line``. + +\ **Note:** :ref:`reflect` differs from what other engines and frameworks call ``reflect()``. In other engines, ``reflect()`` takes a normal direction which is a direction perpendicular to the line. In Godot, you specify the direction of the line directly. See also :ref:`bounce` which does what most engines call ``reflect()``. .. rst-class:: classref-item-separator diff --git a/classes/class_vector3.rst b/classes/class_vector3.rst index 09a908de3..70a41ac6f 100644 --- a/classes/class_vector3.rst +++ b/classes/class_vector3.rst @@ -38,7 +38,7 @@ Tutorials - `3Blue1Brown Essence of Linear Algebra `__ -- `Matrix Transform Demo `__ +- `Matrix Transform Demo `__ - `All 3D Demos `__ @@ -153,7 +153,7 @@ Methods +-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`project`\ (\ b\: :ref:`Vector3`\ ) |const| | +-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Vector3` | :ref:`reflect`\ (\ n\: :ref:`Vector3`\ ) |const| | + | :ref:`Vector3` | :ref:`reflect`\ (\ direction\: :ref:`Vector3`\ ) |const| | +-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`rotated`\ (\ axis\: :ref:`Vector3`, angle\: :ref:`float`\ ) |const| | +-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -524,7 +524,9 @@ Returns the point at the given ``t`` on the `Bézier curve ` **bounce**\ (\ n\: :ref:`Vector3`\ ) |const| -Returns the vector "bounced off" from a plane defined by the given normal. +Returns the vector "bounced off" from a plane defined by the given normal ``n``. + +\ **Note:** :ref:`bounce` performs the operation that most engines and frameworks call ``reflect()``. .. rst-class:: classref-item-separator @@ -562,6 +564,8 @@ Returns a new vector with all components clamped between the components of ``min Returns the cross product of this vector and ``with``. +This returns a vector perpendicular to both this and ``with``, which would be the normal vector of the plane defined by the two vectors. As there are two such vectors, in opposite directions, this method returns the vector defined by a right-handed coordinate system. If the two vectors are parallel this returns an empty vector, making it useful for testing if two vectors are parallel. + .. rst-class:: classref-item-separator ---- @@ -904,9 +908,11 @@ Returns a new vector resulting from projecting this vector onto the given vector .. rst-class:: classref-method -:ref:`Vector3` **reflect**\ (\ n\: :ref:`Vector3`\ ) |const| +:ref:`Vector3` **reflect**\ (\ direction\: :ref:`Vector3`\ ) |const| -Returns the result of reflecting the vector from a plane defined by the given normal ``n``. +Returns the result of reflecting the vector from a plane defined by the given direction vector ``direction``. + +\ **Note:** :ref:`reflect` differs from what other engines and frameworks call ``reflect()``. In other engines, ``reflect()`` takes a normal direction which is a direction perpendicular to the plane. In Godot, you specify a direction parallel to the plane. See also :ref:`bounce` which does what most engines call ``reflect()``. .. rst-class:: classref-item-separator diff --git a/classes/class_vehiclebody3d.rst b/classes/class_vehiclebody3d.rst index cbd02afe9..349606059 100644 --- a/classes/class_vehiclebody3d.rst +++ b/classes/class_vehiclebody3d.rst @@ -30,7 +30,7 @@ This physics body implements all the physics logic needed to simulate a car. It Tutorials --------- -- `3D Truck Town Demo `__ +- `3D Truck Town Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_vehiclewheel3d.rst b/classes/class_vehiclewheel3d.rst index 16ffdeb29..5a4d42d5f 100644 --- a/classes/class_vehiclewheel3d.rst +++ b/classes/class_vehiclewheel3d.rst @@ -28,7 +28,7 @@ A node used as a child of a :ref:`VehicleBody3D` parent to Tutorials --------- -- `3D Truck Town Demo `__ +- `3D Truck Town Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_viewport.rst b/classes/class_viewport.rst index 55d58e633..febfa7cb8 100644 --- a/classes/class_viewport.rst +++ b/classes/class_viewport.rst @@ -40,17 +40,17 @@ Tutorials - :doc:`Viewport and canvas transforms <../tutorials/2d/2d_transforms>` -- `GUI in 3D Demo `__ +- `GUI in 3D Viewport Demo `__ -- `3D in 2D Demo `__ +- `3D in 2D Viewport Demo `__ -- `2D in 3D Demo `__ +- `2D in 3D Viewport Demo `__ -- `Screen Capture Demo `__ +- `Screen Capture Demo `__ -- `Dynamic Split Screen Demo `__ +- `Dynamic Split Screen Demo `__ -- `3D Viewport Scaling Demo `__ +- `3D Resolution Scaling Demo `__ .. rst-class:: classref-reftable-group @@ -572,11 +572,7 @@ Objects are displayed without light information. :ref:`DebugDraw` **DEBUG_DRAW_LIGHTING** = ``2`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Objects are displayed without textures and only with lighting information. .. _class_Viewport_constant_DEBUG_DRAW_OVERDRAW: @@ -592,7 +588,7 @@ Objects are displayed semi-transparent with additive blending so you can see whe :ref:`DebugDraw` **DEBUG_DRAW_WIREFRAME** = ``4`` -Objects are displayed in wireframe style. +Objects are displayed as wireframe models. .. _class_Viewport_constant_DEBUG_DRAW_NORMAL_BUFFER: @@ -600,11 +596,7 @@ Objects are displayed in wireframe style. :ref:`DebugDraw` **DEBUG_DRAW_NORMAL_BUFFER** = ``5`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Objects are displayed without lighting information and their textures replaced by normal mapping. .. _class_Viewport_constant_DEBUG_DRAW_VOXEL_GI_ALBEDO: @@ -652,11 +644,7 @@ Draws the shadow atlas that stores shadows from :ref:`DirectionalLight3D` **DEBUG_DRAW_SCENE_LUMINANCE** = ``11`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Draws the scene luminance buffer (if available) in the upper left quadrant of the **Viewport**. .. _class_Viewport_constant_DEBUG_DRAW_SSAO: @@ -696,11 +684,9 @@ Draws the decal atlas used by :ref:`Decal`\ s and light projector t :ref:`DebugDraw` **DEBUG_DRAW_SDFGI** = ``16`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - +Draws the cascades used to render signed distance field global illumination (SDFGI). +Does nothing if the current environment's :ref:`Environment.sdfgi_enabled` is ``false`` or SDFGI is not supported on the platform. .. _class_Viewport_constant_DEBUG_DRAW_SDFGI_PROBES: @@ -708,11 +694,9 @@ Draws the decal atlas used by :ref:`Decal`\ s and light projector t :ref:`DebugDraw` **DEBUG_DRAW_SDFGI_PROBES** = ``17`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - +Draws the probes used for signed distance field global illumination (SDFGI). +Does nothing if the current environment's :ref:`Environment.sdfgi_enabled` is ``false`` or SDFGI is not supported on the platform. .. _class_Viewport_constant_DEBUG_DRAW_GI_BUFFER: @@ -720,11 +704,7 @@ Draws the decal atlas used by :ref:`Decal`\ s and light projector t :ref:`DebugDraw` **DEBUG_DRAW_GI_BUFFER** = ``18`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Draws the buffer used for global illumination (GI). .. _class_Viewport_constant_DEBUG_DRAW_DISABLE_LOD: @@ -732,11 +712,7 @@ Draws the decal atlas used by :ref:`Decal`\ s and light projector t :ref:`DebugDraw` **DEBUG_DRAW_DISABLE_LOD** = ``19`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Draws all of the objects at their highest polycount, without low level of detail (LOD). .. _class_Viewport_constant_DEBUG_DRAW_CLUSTER_OMNI_LIGHTS: @@ -744,11 +720,7 @@ Draws the decal atlas used by :ref:`Decal`\ s and light projector t :ref:`DebugDraw` **DEBUG_DRAW_CLUSTER_OMNI_LIGHTS** = ``20`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Draws the cluster used by :ref:`OmniLight3D` nodes to optimize light rendering. .. _class_Viewport_constant_DEBUG_DRAW_CLUSTER_SPOT_LIGHTS: @@ -756,11 +728,7 @@ Draws the decal atlas used by :ref:`Decal`\ s and light projector t :ref:`DebugDraw` **DEBUG_DRAW_CLUSTER_SPOT_LIGHTS** = ``21`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Draws the cluster used by :ref:`SpotLight3D` nodes to optimize light rendering. .. _class_Viewport_constant_DEBUG_DRAW_CLUSTER_DECALS: @@ -768,11 +736,7 @@ Draws the decal atlas used by :ref:`Decal`\ s and light projector t :ref:`DebugDraw` **DEBUG_DRAW_CLUSTER_DECALS** = ``22`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Draws the cluster used by :ref:`Decal` nodes to optimize decal rendering. .. _class_Viewport_constant_DEBUG_DRAW_CLUSTER_REFLECTION_PROBES: @@ -780,11 +744,7 @@ Draws the decal atlas used by :ref:`Decal`\ s and light projector t :ref:`DebugDraw` **DEBUG_DRAW_CLUSTER_REFLECTION_PROBES** = ``23`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Draws the cluster used by :ref:`ReflectionProbe` nodes to optimize decal rendering. .. _class_Viewport_constant_DEBUG_DRAW_OCCLUDERS: @@ -792,11 +752,7 @@ Draws the decal atlas used by :ref:`Decal`\ s and light projector t :ref:`DebugDraw` **DEBUG_DRAW_OCCLUDERS** = ``24`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Draws the buffer used for occlusion culling. .. _class_Viewport_constant_DEBUG_DRAW_MOTION_VECTORS: @@ -804,11 +760,7 @@ Draws the decal atlas used by :ref:`Decal`\ s and light projector t :ref:`DebugDraw` **DEBUG_DRAW_MOTION_VECTORS** = ``25`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Draws vector lines over the viewport to indicate the movement of pixels between frames. .. _class_Viewport_constant_DEBUG_DRAW_INTERNAL_BUFFER: @@ -870,7 +822,7 @@ Use this for non-pixel art textures that may be viewed at a low scale (e.g. due :ref:`DefaultCanvasItemTextureFilter` **DEFAULT_CANVAS_ITEM_TEXTURE_FILTER_MAX** = ``4`` -Max value for :ref:`DefaultCanvasItemTextureFilter` enum. +Represents the size of the :ref:`DefaultCanvasItemTextureFilter` enum. .. rst-class:: classref-item-separator @@ -912,7 +864,7 @@ Flip the texture when repeating so that the edge lines up instead of abruptly ch :ref:`DefaultCanvasItemTextureRepeat` **DEFAULT_CANVAS_ITEM_TEXTURE_REPEAT_MAX** = ``3`` -Max value for :ref:`DefaultCanvasItemTextureRepeat` enum. +Represents the size of the :ref:`DefaultCanvasItemTextureRepeat` enum. .. rst-class:: classref-item-separator @@ -930,11 +882,7 @@ enum **SDFOversize**: :ref:`SDFOversize` **SDF_OVERSIZE_100_PERCENT** = ``0`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +The signed distance field only covers the viewport's own rectangle. .. _class_Viewport_constant_SDF_OVERSIZE_120_PERCENT: @@ -942,11 +890,7 @@ enum **SDFOversize**: :ref:`SDFOversize` **SDF_OVERSIZE_120_PERCENT** = ``1`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +The signed distance field is expanded to cover 20% of the viewport's size around the borders. .. _class_Viewport_constant_SDF_OVERSIZE_150_PERCENT: @@ -954,11 +898,7 @@ enum **SDFOversize**: :ref:`SDFOversize` **SDF_OVERSIZE_150_PERCENT** = ``2`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +The signed distance field is expanded to cover 50% of the viewport's size around the borders. .. _class_Viewport_constant_SDF_OVERSIZE_200_PERCENT: @@ -966,11 +906,7 @@ enum **SDFOversize**: :ref:`SDFOversize` **SDF_OVERSIZE_200_PERCENT** = ``3`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +The signed distance field is expanded to cover 100% (double) of the viewport's size around the borders. .. _class_Viewport_constant_SDF_OVERSIZE_MAX: @@ -978,11 +914,7 @@ enum **SDFOversize**: :ref:`SDFOversize` **SDF_OVERSIZE_MAX** = ``4`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Represents the size of the :ref:`SDFOversize` enum. .. rst-class:: classref-item-separator @@ -1000,11 +932,7 @@ enum **SDFScale**: :ref:`SDFScale` **SDF_SCALE_100_PERCENT** = ``0`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +The signed distance field is rendered at full resolution. .. _class_Viewport_constant_SDF_SCALE_50_PERCENT: @@ -1012,11 +940,7 @@ enum **SDFScale**: :ref:`SDFScale` **SDF_SCALE_50_PERCENT** = ``1`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +The signed distance field is rendered at half the resolution of this viewport. .. _class_Viewport_constant_SDF_SCALE_25_PERCENT: @@ -1024,11 +948,7 @@ enum **SDFScale**: :ref:`SDFScale` **SDF_SCALE_25_PERCENT** = ``2`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +The signed distance field is rendered at a quarter the resolution of this viewport. .. _class_Viewport_constant_SDF_SCALE_MAX: @@ -1036,11 +956,7 @@ enum **SDFScale**: :ref:`SDFScale` **SDF_SCALE_MAX** = ``3`` -.. container:: contribute - - There is currently no description for this enum. Please help us by :ref:`contributing one `! - - +Represents the size of the :ref:`SDFScale` enum. .. rst-class:: classref-item-separator @@ -1058,7 +974,7 @@ enum **VRSMode**: :ref:`VRSMode` **VRS_DISABLED** = ``0`` -VRS is disabled. +Variable Rate Shading is disabled. .. _class_Viewport_constant_VRS_TEXTURE: @@ -1066,7 +982,7 @@ VRS is disabled. :ref:`VRSMode` **VRS_TEXTURE** = ``1`` -VRS uses a texture. Note, for stereoscopic use a texture atlas with a texture for each view. +Variable Rate Shading uses a texture. Note, for stereoscopic use a texture atlas with a texture for each view. .. _class_Viewport_constant_VRS_XR: @@ -1074,7 +990,7 @@ VRS uses a texture. Note, for stereoscopic use a texture atlas with a texture fo :ref:`VRSMode` **VRS_XR** = ``2`` -VRS texture is supplied by the primary :ref:`XRInterface`. +Variable Rate Shading's texture is supplied by the primary :ref:`XRInterface`. .. _class_Viewport_constant_VRS_MAX: @@ -1642,9 +1558,9 @@ Sets the screen-space antialiasing method used. Screen-space antialiasing works - |void| **set_sdf_oversize**\ (\ value\: :ref:`SDFOversize`\ ) - :ref:`SDFOversize` **get_sdf_oversize**\ (\ ) -.. container:: contribute +Controls how much of the original viewport's size should be covered by the 2D signed distance field. This SDF can be sampled in :ref:`CanvasItem` shaders and is also used for :ref:`GPUParticles2D` collision. Higher values allow portions of occluders located outside the viewport to still be taken into account in the generated signed distance field, at the cost of performance. If you notice particles falling through :ref:`LightOccluder2D`\ s as the occluders leave the viewport, increase this setting. - There is currently no description for this property. Please help us by :ref:`contributing one `! +The percentage is added on each axis and on both sides. For example, with the default :ref:`SDF_OVERSIZE_120_PERCENT`, the signed distance field will cover 20% of the viewport's size outside the viewport on each side (top, right, bottom, left). .. rst-class:: classref-item-separator @@ -1661,9 +1577,7 @@ Sets the screen-space antialiasing method used. Screen-space antialiasing works - |void| **set_sdf_scale**\ (\ value\: :ref:`SDFScale`\ ) - :ref:`SDFScale` **get_sdf_scale**\ (\ ) -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +The resolution scale to use for the 2D signed distance field. Higher values lead to a more precise and more stable signed distance field as the camera moves, at the cost of performance. .. rst-class:: classref-item-separator @@ -1680,9 +1594,7 @@ Sets the screen-space antialiasing method used. Screen-space antialiasing works - |void| **set_snap_2d_transforms_to_pixel**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **is_snap_2d_transforms_to_pixel_enabled**\ (\ ) -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +If ``true``, :ref:`CanvasItem` nodes will internally snap to full pixels. Their position can still be sub-pixel, but the decimals will not have effect. This can lead to a crisper appearance at the cost of less smooth movement, especially when :ref:`Camera2D` smoothing is enabled. .. rst-class:: classref-item-separator @@ -1699,9 +1611,7 @@ Sets the screen-space antialiasing method used. Screen-space antialiasing works - |void| **set_snap_2d_vertices_to_pixel**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **is_snap_2d_vertices_to_pixel_enabled**\ (\ ) -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +If ``true``, vertices of :ref:`CanvasItem` nodes will snap to full pixels. Only affects the final vertex positions, not the transforms. This can lead to a crisper appearance at the cost of less smooth movement, especially when :ref:`Camera2D` smoothing is enabled. .. rst-class:: classref-item-separator @@ -1874,7 +1784,7 @@ Texture to use when :ref:`vrs_mode` is set to The texture *must* use a lossless compression format so that colors can be matched precisely. The following VRS densities are mapped to various colors, with brighter colors representing a lower level of shading precision: -:: +.. code:: text - 1×1 = rgb(0, 0, 0) - #000000 - 1×2 = rgb(0, 85, 0) - #005500 diff --git a/classes/class_viewporttexture.rst b/classes/class_viewporttexture.rst index bd16350a8..8373e35c2 100644 --- a/classes/class_viewporttexture.rst +++ b/classes/class_viewporttexture.rst @@ -19,24 +19,26 @@ Provides the content of a :ref:`Viewport` as a dynamic texture. Description ----------- -Provides the content of a :ref:`Viewport` as a dynamic :ref:`Texture2D`. This can be used to mix controls, 2D game objects, and 3D game objects in the same scene. +A **ViewportTexture** provides the content of a :ref:`Viewport` as a dynamic :ref:`Texture2D`. This can be used to combine the rendering of :ref:`Control`, :ref:`Node2D` and :ref:`Node3D` nodes. For example, you can use this texture to display a 3D scene inside a :ref:`TextureRect`, or a 2D overlay in a :ref:`Sprite3D`. -To create a **ViewportTexture** in code, use the :ref:`Viewport.get_texture` method on the target viewport. +To get a **ViewportTexture** in code, use the :ref:`Viewport.get_texture` method on the target viewport. \ **Note:** A **ViewportTexture** is always local to its scene (see :ref:`Resource.resource_local_to_scene`). If the scene root is not ready, it may return incorrect data (see :ref:`Node.ready`). +\ **Note:** Instantiating scenes containing a high-resolution **ViewportTexture** may cause noticeable stutter. + .. rst-class:: classref-introduction-group Tutorials --------- -- `GUI in 3D Demo `__ +- `GUI in 3D Viewport Demo `__ -- `3D in 2D Demo `__ +- `3D in 2D Viewport Demo `__ -- `2D in 3D Demo `__ +- `2D in 3D Viewport Demo `__ -- `3D Viewport Scaling Demo `__ +- `3D Resolution Scaling Demo `__ .. rst-class:: classref-reftable-group @@ -70,9 +72,9 @@ Property Descriptions - |void| **set_viewport_path_in_scene**\ (\ value\: :ref:`NodePath`\ ) - :ref:`NodePath` **get_viewport_path_in_scene**\ (\ ) -The path to the :ref:`Viewport` node to display. This is relative to the scene root, not to the node that uses the texture. +The path to the :ref:`Viewport` node to display. This is relative to the local scene root (see :ref:`Resource.get_local_scene`), **not** to the nodes that use this texture. -\ **Note:** In the editor, this path is automatically updated when the target viewport or one of its ancestors is renamed or moved. At runtime, the path may not be able to automatically update due to the inability to determine the scene root. +\ **Note:** In the editor, this path is automatically updated when the target viewport or one of its ancestors is renamed or moved. At runtime, this path may not automatically update if the scene root cannot be found. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` diff --git a/classes/class_visibleonscreennotifier2d.rst b/classes/class_visibleonscreennotifier2d.rst index 831071de0..600c8dd3e 100644 --- a/classes/class_visibleonscreennotifier2d.rst +++ b/classes/class_visibleonscreennotifier2d.rst @@ -32,7 +32,7 @@ If you want a node to be enabled automatically when this region is visible on sc Tutorials --------- -- `2D Dodge The Creeps Demo `__ +- `2D Dodge The Creeps Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_visualshadernodeframe.rst b/classes/class_visualshadernodeframe.rst index fd83aeccb..af385e5e9 100644 --- a/classes/class_visualshadernodeframe.rst +++ b/classes/class_visualshadernodeframe.rst @@ -81,6 +81,8 @@ Property Descriptions The list of nodes attached to the frame. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedInt32Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_voxelgi.rst b/classes/class_voxelgi.rst index a26b94430..7e07e410c 100644 --- a/classes/class_voxelgi.rst +++ b/classes/class_voxelgi.rst @@ -36,7 +36,7 @@ Tutorials - :doc:`Using Voxel global illumination <../tutorials/3d/global_illumination/using_voxel_gi>` -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_voxelgidata.rst b/classes/class_voxelgidata.rst index 44ae597c6..9535b135f 100644 --- a/classes/class_voxelgidata.rst +++ b/classes/class_voxelgidata.rst @@ -28,7 +28,7 @@ Description Tutorials --------- -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_websocketmultiplayerpeer.rst b/classes/class_websocketmultiplayerpeer.rst index d4734cc3e..f8e3a590a 100644 --- a/classes/class_websocketmultiplayerpeer.rst +++ b/classes/class_websocketmultiplayerpeer.rst @@ -87,6 +87,8 @@ Property Descriptions The extra headers to use during handshake. See :ref:`WebSocketPeer.handshake_headers` for more details. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -172,6 +174,8 @@ The outbound buffer size for connected peers. See :ref:`WebSocketPeer.outbound_b The supported WebSocket sub-protocols. See :ref:`WebSocketPeer.supported_protocols` for more details. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_websocketpeer.rst b/classes/class_websocketpeer.rst index bbeacb47f..586650c14 100644 --- a/classes/class_websocketpeer.rst +++ b/classes/class_websocketpeer.rst @@ -215,6 +215,8 @@ The extra HTTP headers to be sent during the WebSocket handshake. \ **Note:** Not supported in Web exports due to browsers' restrictions. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-item-separator ---- @@ -283,6 +285,8 @@ The size of the input buffer in bytes (roughly the maximum amount of memory that The WebSocket sub-protocols allowed during the WebSocket handshake. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedStringArray` for more details. + .. rst-class:: classref-section-separator ---- diff --git a/classes/class_window.rst b/classes/class_window.rst index 1061765f0..6f7d814b7 100644 --- a/classes/class_window.rst +++ b/classes/class_window.rst @@ -1257,6 +1257,8 @@ Passing an empty array will disable passthrough support (all mouse events will b \ **Note:** This property is implemented on Linux (X11), macOS and Windows. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedVector2Array` for more details. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_worldenvironment.rst b/classes/class_worldenvironment.rst index a99c040ac..e21d74081 100644 --- a/classes/class_worldenvironment.rst +++ b/classes/class_worldenvironment.rst @@ -35,11 +35,9 @@ Tutorials - :doc:`Environment and post-processing <../tutorials/3d/environment_and_post_processing>` -- `3D Material Testers Demo `__ +- `3D Material Testers Demo `__ -- `2D HDR Demo `__ - -- `Third Person Shooter Demo `__ +- `Third Person Shooter (TPS) Demo `__ .. rst-class:: classref-reftable-group diff --git a/classes/class_xrfacetracker.rst b/classes/class_xrfacetracker.rst index f337d90d6..4e17474af 100644 --- a/classes/class_xrfacetracker.rst +++ b/classes/class_xrfacetracker.rst @@ -1247,6 +1247,8 @@ Property Descriptions The array of face blend shape weights with indices corresponding to the :ref:`BlendShapeEntry` enum. +**Note:** The returned array is *copied* and any changes to it will not update the original property value. See :ref:`PackedFloat32Array` for more details. + .. rst-class:: classref-section-separator ----