diff --git a/classes/class_@globalscope.rst b/classes/class_@globalscope.rst index fb444e7b0..75875ca66 100644 --- a/classes/class_@globalscope.rst +++ b/classes/class_@globalscope.rst @@ -2853,7 +2853,7 @@ Soft hyphen key. .. rst-class:: classref-enumeration -enum **KeyModifierMask**: +flags **KeyModifierMask**: .. _class_@GlobalScope_constant_KEY_CODE_MASK: @@ -3017,11 +3017,21 @@ Extra mouse button 1. This is sometimes present, usually to the sides of the mou Extra mouse button 2. This is sometimes present, usually to the sides of the mouse. +.. rst-class:: classref-item-separator + +---- + +.. _enum_@GlobalScope_MouseButtonMask: + +.. rst-class:: classref-enumeration + +flags **MouseButtonMask**: + .. _class_@GlobalScope_constant_MOUSE_BUTTON_MASK_LEFT: .. rst-class:: classref-enumeration-constant -:ref:`MouseButton` **MOUSE_BUTTON_MASK_LEFT** = ``1`` +:ref:`MouseButtonMask` **MOUSE_BUTTON_MASK_LEFT** = ``1`` Primary mouse button mask, usually for the left button. @@ -3029,7 +3039,7 @@ Primary mouse button mask, usually for the left button. .. rst-class:: classref-enumeration-constant -:ref:`MouseButton` **MOUSE_BUTTON_MASK_RIGHT** = ``2`` +:ref:`MouseButtonMask` **MOUSE_BUTTON_MASK_RIGHT** = ``2`` Secondary mouse button mask, usually for the right button. @@ -3037,23 +3047,23 @@ Secondary mouse button mask, usually for the right button. .. rst-class:: classref-enumeration-constant -:ref:`MouseButton` **MOUSE_BUTTON_MASK_MIDDLE** = ``4`` +:ref:`MouseButtonMask` **MOUSE_BUTTON_MASK_MIDDLE** = ``4`` Middle mouse button mask. -.. _class_@GlobalScope_constant_MOUSE_BUTTON_MASK_XBUTTON1: +.. _class_@GlobalScope_constant_MOUSE_BUTTON_MASK_MB_XBUTTON1: .. rst-class:: classref-enumeration-constant -:ref:`MouseButton` **MOUSE_BUTTON_MASK_XBUTTON1** = ``128`` +:ref:`MouseButtonMask` **MOUSE_BUTTON_MASK_MB_XBUTTON1** = ``128`` Extra mouse button 1 mask. -.. _class_@GlobalScope_constant_MOUSE_BUTTON_MASK_XBUTTON2: +.. _class_@GlobalScope_constant_MOUSE_BUTTON_MASK_MB_XBUTTON2: .. rst-class:: classref-enumeration-constant -:ref:`MouseButton` **MOUSE_BUTTON_MASK_XBUTTON2** = ``256`` +:ref:`MouseButtonMask` **MOUSE_BUTTON_MASK_MB_XBUTTON2** = ``256`` Extra mouse button 2 mask. @@ -4156,75 +4166,11 @@ Hint that a property represents a particular type. If a property is :ref:`TYPE_S -.. _class_@GlobalScope_constant_PROPERTY_HINT_METHOD_OF_VARIANT_TYPE: - -.. rst-class:: classref-enumeration-constant - -:ref:`PropertyHint` **PROPERTY_HINT_METHOD_OF_VARIANT_TYPE** = ``25`` - - - -.. _class_@GlobalScope_constant_PROPERTY_HINT_METHOD_OF_BASE_TYPE: - -.. rst-class:: classref-enumeration-constant - -:ref:`PropertyHint` **PROPERTY_HINT_METHOD_OF_BASE_TYPE** = ``26`` - - - -.. _class_@GlobalScope_constant_PROPERTY_HINT_METHOD_OF_INSTANCE: - -.. rst-class:: classref-enumeration-constant - -:ref:`PropertyHint` **PROPERTY_HINT_METHOD_OF_INSTANCE** = ``27`` - - - -.. _class_@GlobalScope_constant_PROPERTY_HINT_METHOD_OF_SCRIPT: - -.. rst-class:: classref-enumeration-constant - -:ref:`PropertyHint` **PROPERTY_HINT_METHOD_OF_SCRIPT** = ``28`` - - - -.. _class_@GlobalScope_constant_PROPERTY_HINT_PROPERTY_OF_VARIANT_TYPE: - -.. rst-class:: classref-enumeration-constant - -:ref:`PropertyHint` **PROPERTY_HINT_PROPERTY_OF_VARIANT_TYPE** = ``29`` - - - -.. _class_@GlobalScope_constant_PROPERTY_HINT_PROPERTY_OF_BASE_TYPE: - -.. rst-class:: classref-enumeration-constant - -:ref:`PropertyHint` **PROPERTY_HINT_PROPERTY_OF_BASE_TYPE** = ``30`` - - - -.. _class_@GlobalScope_constant_PROPERTY_HINT_PROPERTY_OF_INSTANCE: - -.. rst-class:: classref-enumeration-constant - -:ref:`PropertyHint` **PROPERTY_HINT_PROPERTY_OF_INSTANCE** = ``31`` - - - -.. _class_@GlobalScope_constant_PROPERTY_HINT_PROPERTY_OF_SCRIPT: - -.. rst-class:: classref-enumeration-constant - -:ref:`PropertyHint` **PROPERTY_HINT_PROPERTY_OF_SCRIPT** = ``32`` - - - .. _class_@GlobalScope_constant_PROPERTY_HINT_OBJECT_TOO_BIG: .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_OBJECT_TOO_BIG** = ``33`` +:ref:`PropertyHint` **PROPERTY_HINT_OBJECT_TOO_BIG** = ``25`` @@ -4232,7 +4178,7 @@ Hint that a property represents a particular type. If a property is :ref:`TYPE_S .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_NODE_PATH_VALID_TYPES** = ``34`` +:ref:`PropertyHint` **PROPERTY_HINT_NODE_PATH_VALID_TYPES** = ``26`` @@ -4240,7 +4186,7 @@ Hint that a property represents a particular type. If a property is :ref:`TYPE_S .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_SAVE_FILE** = ``35`` +:ref:`PropertyHint` **PROPERTY_HINT_SAVE_FILE** = ``27`` @@ -4248,7 +4194,7 @@ Hint that a property represents a particular type. If a property is :ref:`TYPE_S .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_GLOBAL_SAVE_FILE** = ``36`` +:ref:`PropertyHint` **PROPERTY_HINT_GLOBAL_SAVE_FILE** = ``28`` @@ -4256,7 +4202,7 @@ Hint that a property represents a particular type. If a property is :ref:`TYPE_S .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_INT_IS_OBJECTID** = ``37`` +:ref:`PropertyHint` **PROPERTY_HINT_INT_IS_OBJECTID** = ``29`` @@ -4264,7 +4210,7 @@ Hint that a property represents a particular type. If a property is :ref:`TYPE_S .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_INT_IS_POINTER** = ``38`` +:ref:`PropertyHint` **PROPERTY_HINT_INT_IS_POINTER** = ``30`` @@ -4272,7 +4218,7 @@ Hint that a property represents a particular type. If a property is :ref:`TYPE_S .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_ARRAY_TYPE** = ``39`` +:ref:`PropertyHint` **PROPERTY_HINT_ARRAY_TYPE** = ``31`` @@ -4280,7 +4226,7 @@ Hint that a property represents a particular type. If a property is :ref:`TYPE_S .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_LOCALE_ID** = ``40`` +:ref:`PropertyHint` **PROPERTY_HINT_LOCALE_ID** = ``32`` Hints that a string property is a locale code. Editing it will show a locale dialog for picking language and country. @@ -4288,7 +4234,7 @@ Hints that a string property is a locale code. Editing it will show a locale dia .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_LOCALIZABLE_STRING** = ``41`` +:ref:`PropertyHint` **PROPERTY_HINT_LOCALIZABLE_STRING** = ``33`` Hints that a dictionary property is string translation map. Dictionary keys are locale codes and, values are translated strings. @@ -4296,7 +4242,7 @@ Hints that a dictionary property is string translation map. Dictionary keys are .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_NODE_TYPE** = ``42`` +:ref:`PropertyHint` **PROPERTY_HINT_NODE_TYPE** = ``34`` @@ -4304,7 +4250,7 @@ Hints that a dictionary property is string translation map. Dictionary keys are .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_HIDE_QUATERNION_EDIT** = ``43`` +:ref:`PropertyHint` **PROPERTY_HINT_HIDE_QUATERNION_EDIT** = ``35`` Hints that a quaternion property should disable the temporary euler editor. @@ -4312,7 +4258,7 @@ Hints that a quaternion property should disable the temporary euler editor. .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_PASSWORD** = ``44`` +:ref:`PropertyHint` **PROPERTY_HINT_PASSWORD** = ``36`` Hints that a string property is a password, and every character is replaced with the secret character. @@ -4320,7 +4266,7 @@ Hints that a string property is a password, and every character is replaced with .. rst-class:: classref-enumeration-constant -:ref:`PropertyHint` **PROPERTY_HINT_MAX** = ``45`` +:ref:`PropertyHint` **PROPERTY_HINT_MAX** = ``37`` @@ -4332,7 +4278,7 @@ Hints that a string property is a password, and every character is replaced with .. rst-class:: classref-enumeration -enum **PropertyUsageFlags**: +flags **PropertyUsageFlags**: .. _class_@GlobalScope_constant_PROPERTY_USAGE_NONE: @@ -4358,11 +4304,19 @@ The property is serialized and saved in the scene file (default). The property is shown in the :ref:`EditorInspector` (default). +.. _class_@GlobalScope_constant_PROPERTY_USAGE_INTERNAL: + +.. rst-class:: classref-enumeration-constant + +:ref:`PropertyUsageFlags` **PROPERTY_USAGE_INTERNAL** = ``8`` + + + .. _class_@GlobalScope_constant_PROPERTY_USAGE_CHECKABLE: .. rst-class:: classref-enumeration-constant -:ref:`PropertyUsageFlags` **PROPERTY_USAGE_CHECKABLE** = ``8`` +:ref:`PropertyUsageFlags` **PROPERTY_USAGE_CHECKABLE** = ``16`` The property can be checked in the :ref:`EditorInspector`. @@ -4370,18 +4324,10 @@ The property can be checked in the :ref:`EditorInspector` .. rst-class:: classref-enumeration-constant -:ref:`PropertyUsageFlags` **PROPERTY_USAGE_CHECKED** = ``16`` +:ref:`PropertyUsageFlags` **PROPERTY_USAGE_CHECKED** = ``32`` The property is checked in the :ref:`EditorInspector`. -.. _class_@GlobalScope_constant_PROPERTY_USAGE_INTERNATIONALIZED: - -.. rst-class:: classref-enumeration-constant - -:ref:`PropertyUsageFlags` **PROPERTY_USAGE_INTERNATIONALIZED** = ``32`` - -The property is a translatable string. - .. _class_@GlobalScope_constant_PROPERTY_USAGE_GROUP: .. rst-class:: classref-enumeration-constant @@ -4478,13 +4424,13 @@ The property is a script variable which should be serialized and saved in the sc -.. _class_@GlobalScope_constant_PROPERTY_USAGE_INTERNAL: +.. _class_@GlobalScope_constant_PROPERTY_USAGE_ARRAY: .. rst-class:: classref-enumeration-constant -:ref:`PropertyUsageFlags` **PROPERTY_USAGE_INTERNAL** = ``262144`` - +:ref:`PropertyUsageFlags` **PROPERTY_USAGE_ARRAY** = ``262144`` +The property is an array. .. _class_@GlobalScope_constant_PROPERTY_USAGE_DO_NOT_SHARE_ON_DUPLICATE: @@ -4558,14 +4504,6 @@ The property is only shown in the editor if modern renderers are supported (GLES The property is read-only in the :ref:`EditorInspector`. -.. _class_@GlobalScope_constant_PROPERTY_USAGE_ARRAY: - -.. rst-class:: classref-enumeration-constant - -:ref:`PropertyUsageFlags` **PROPERTY_USAGE_ARRAY** = ``268435456`` - -The property is an array. - .. _class_@GlobalScope_constant_PROPERTY_USAGE_DEFAULT: .. rst-class:: classref-enumeration-constant @@ -4574,14 +4512,6 @@ The property is an array. Default usage (storage, editor and network). -.. _class_@GlobalScope_constant_PROPERTY_USAGE_DEFAULT_INTL: - -.. rst-class:: classref-enumeration-constant - -:ref:`PropertyUsageFlags` **PROPERTY_USAGE_DEFAULT_INTL** = ``38`` - -Default usage for translatable strings (storage, editor, network and internationalized). - .. _class_@GlobalScope_constant_PROPERTY_USAGE_NO_EDITOR: .. rst-class:: classref-enumeration-constant @@ -4598,7 +4528,7 @@ Default usage but without showing the property in the editor (storage, network). .. rst-class:: classref-enumeration -enum **MethodFlags**: +flags **MethodFlags**: .. _class_@GlobalScope_constant_METHOD_FLAG_NORMAL: diff --git a/classes/class_animatedsprite2d.rst b/classes/class_animatedsprite2d.rst index d08d0b03c..bca3b504e 100644 --- a/classes/class_animatedsprite2d.rst +++ b/classes/class_animatedsprite2d.rst @@ -23,7 +23,7 @@ Description After setting up :ref:`frames`, :ref:`play` may be called. It's also possible to select an :ref:`animation` and toggle :ref:`playing`, even within the editor. -To pause the current animation, call :ref:`stop` or set :ref:`playing` to ``false``. Alternatively, setting :ref:`speed_scale` to ``0`` also preserves the current frame's elapsed time. +To pause the current animation, set :ref:`playing` to ``false``. Alternatively, setting :ref:`speed_scale` to ``0`` also preserves the current frame's elapsed time. \ **Note:** You can associate a set of normal or specular maps by creating additional :ref:`SpriteFrames` resources with a ``_normal`` or ``_specular`` suffix. For example, having 3 :ref:`SpriteFrames` resources ``run``, ``run_normal``, and ``run_specular`` will make it so the ``run`` animation uses normal and specular maps. @@ -93,7 +93,7 @@ Signals **animation_finished** **(** **)** -Emitted when the animation is finished (when it plays the last frame). If the animation is looping, this signal is emitted every time the last frame is drawn. +Emitted when the animation reaches the end, or the start if it is played in reverse. If the animation is looping, this signal is emitted at the end of each loop. .. rst-class:: classref-item-separator @@ -246,7 +246,11 @@ The texture's drawing offset. - void **set_playing** **(** :ref:`bool` value **)** - :ref:`bool` **is_playing** **(** **)** -If ``true``, the :ref:`animation` is currently playing. Setting this property to ``false`` is the equivalent of calling :ref:`stop`. +If ``true``, the :ref:`animation` is currently playing. Setting this property to ``false`` pauses the current animation. Use :ref:`stop` to stop the animation at the current frame instead. + +\ **Note:** Unlike :ref:`stop`, changing this property to ``false`` preserves the current frame's elapsed time and the ``backwards`` flag of the current :ref:`animation` (if it was previously set by :ref:`play`). + +\ **Note:** After a non-looping animation finishes, the property still remains ``true``. .. rst-class:: classref-item-separator @@ -282,6 +286,8 @@ void **play** **(** :ref:`StringName` anim=&"", :ref:`bool` is negative, the animation direction specified by ``backwards`` will be inverted. + .. rst-class:: classref-item-separator ---- @@ -294,7 +300,7 @@ void **stop** **(** **)** Stops the current :ref:`animation` at the current :ref:`frame`. -\ **Note:** This method resets the current frame's elapsed time. If this behavior is undesired, consider setting :ref:`speed_scale` to ``0``, instead. +\ **Note:** This method resets the current frame's elapsed time and removes the ``backwards`` flag from the current :ref:`animation` (if it was previously set by :ref:`play`). If this behavior is undesired, set :ref:`playing` to ``false`` instead. .. |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_animatedsprite3d.rst b/classes/class_animatedsprite3d.rst index daeb5ee1c..432d1c771 100644 --- a/classes/class_animatedsprite3d.rst +++ b/classes/class_animatedsprite3d.rst @@ -23,7 +23,7 @@ Description After setting up :ref:`frames`, :ref:`play` may be called. It's also possible to select an :ref:`animation` and toggle :ref:`playing`, even within the editor. -To pause the current animation, call :ref:`stop` or set :ref:`playing` to ``false``. Alternatively, setting :ref:`speed_scale` to ``0`` also preserves the current frame's elapsed time. +To pause the current animation, set :ref:`playing` to ``false``. Alternatively, setting :ref:`speed_scale` to ``0`` also preserves the current frame's elapsed time. .. rst-class:: classref-introduction-group @@ -81,7 +81,7 @@ Signals **animation_finished** **(** **)** -Emitted when the animation is finished (when it plays the last frame). If the animation is looping, this signal is emitted every time the last frame is drawn. +Emitted when the animation reaches the end, or the start if it is played in reverse. If the animation is looping, this signal is emitted at the end of each loop. .. rst-class:: classref-item-separator @@ -166,7 +166,11 @@ The :ref:`SpriteFrames` resource containing the animation(s) - void **set_playing** **(** :ref:`bool` value **)** - :ref:`bool` **is_playing** **(** **)** -If ``true``, the :ref:`animation` is currently playing. Setting this property to ``false`` is the equivalent of calling :ref:`stop`. +If ``true``, the :ref:`animation` is currently playing. Setting this property to ``false`` pauses the current animation. Use :ref:`stop` to stop the animation at the current frame instead. + +\ **Note:** Unlike :ref:`stop`, changing this property to ``false`` preserves the current frame's elapsed time and the ``backwards`` flag of the current :ref:`animation` (if it was previously set by :ref:`play`). + +\ **Note:** After a non-looping animation finishes, the property still remains ``true``. .. rst-class:: classref-item-separator @@ -202,6 +206,8 @@ void **play** **(** :ref:`StringName` anim=&"", :ref:`bool` is negative, the animation direction specified by ``backwards`` will be inverted. + .. rst-class:: classref-item-separator ---- @@ -214,7 +220,7 @@ void **stop** **(** **)** Stops the current :ref:`animation` at the current :ref:`frame`. -\ **Note:** This method resets the current frame's elapsed time. If this behavior is undesired, consider setting :ref:`speed_scale` to ``0``, instead. +\ **Note:** This method resets the current frame's elapsed time and removes the ``backwards`` flag from the current :ref:`animation` (if it was previously set by :ref:`play`). If this behavior is undesired, set :ref:`playing` to ``false`` instead. .. |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_animationnode.rst b/classes/class_animationnode.rst index 49edf9ffc..637fa5fe0 100644 --- a/classes/class_animationnode.rst +++ b/classes/class_animationnode.rst @@ -99,18 +99,6 @@ Methods Signals ------- -.. _class_AnimationNode_signal_removed_from_graph: - -.. rst-class:: classref-signal - -**removed_from_graph** **(** **)** - -Emitted when the node was removed from the graph. - -.. rst-class:: classref-item-separator - ----- - .. _class_AnimationNode_signal_tree_changed: .. rst-class:: classref-signal diff --git a/classes/class_array.rst b/classes/class_array.rst index 976795f62..004ababfd 100644 --- a/classes/class_array.rst +++ b/classes/class_array.rst @@ -68,6 +68,8 @@ Arrays can be concatenated using the ``+`` operator: \ **Note:** 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`. +\ **Note:** Erasing elements while iterating over arrays is **not** supported and will result in unpredictable behavior. + \ **Note:** When declaring an array with ``const``, the array itself can still be mutated by defining the values at individual indices or pushing/removing elements. Using ``const`` will only prevent assigning the constant with another value after it was initialized. .. rst-class:: classref-reftable-group @@ -539,7 +541,7 @@ Returns the number of times an element is in the array. Returns a copy of the array. -If ``deep`` is ``true``, a deep copy is performed: all nested arrays and dictionaries are duplicated and will not be shared with the original array. If ``false``, a shallow copy is made and references to the original nested arrays and dictionaries are kept, so that modifying a sub-array or dictionary in the copy will also impact those referenced in the source array. +If ``deep`` is ``true``, a deep copy is performed: all nested arrays and dictionaries are duplicated and will not be shared with the original array. If ``false``, a shallow copy is made and references to the original nested arrays and dictionaries are kept, so that modifying a sub-array or dictionary in the copy will also impact those referenced in the source array. Note that any :ref:`Object`-derived elements will be shallow copied regardless of the ``deep`` setting. .. rst-class:: classref-item-separator @@ -557,6 +559,8 @@ Removes the first occurrence of a value from the array. If the value does not ex \ **Note:** On large arrays, this method will be slower if the removed element is close to the beginning of the array (index 0). This is because all elements placed after the removed element have to be reindexed. +\ **Note:** Do not erase entries while iterating over the array. + .. rst-class:: classref-item-separator ---- diff --git a/classes/class_arraymesh.rst b/classes/class_arraymesh.rst index 0ad7fc5bf..37361e842 100644 --- a/classes/class_arraymesh.rst +++ b/classes/class_arraymesh.rst @@ -103,45 +103,45 @@ Methods .. table:: :widths: auto - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`add_blend_shape` **(** :ref:`StringName` name **)** | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`add_surface_from_arrays` **(** :ref:`PrimitiveType` primitive, :ref:`Array` arrays, :ref:`Array[]` blend_shapes=[], :ref:`Dictionary` lods={}, :ref:`int` compress_flags=0 **)** | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`clear_blend_shapes` **(** **)** | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`clear_surfaces` **(** **)** | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`get_blend_shape_count` **(** **)** |const| | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`StringName` | :ref:`get_blend_shape_name` **(** :ref:`int` index **)** |const| | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Error` | :ref:`lightmap_unwrap` **(** :ref:`Transform3D` transform, :ref:`float` texel_size **)** | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`regen_normal_maps` **(** **)** | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_blend_shape_name` **(** :ref:`int` index, :ref:`StringName` name **)** | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`surface_find_by_name` **(** :ref:`String` name **)** |const| | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`surface_get_array_index_len` **(** :ref:`int` surf_idx **)** |const| | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`surface_get_array_len` **(** :ref:`int` surf_idx **)** |const| | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`surface_get_format` **(** :ref:`int` surf_idx **)** |const| | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`String` | :ref:`surface_get_name` **(** :ref:`int` surf_idx **)** |const| | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`PrimitiveType` | :ref:`surface_get_primitive_type` **(** :ref:`int` surf_idx **)** |const| | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`surface_set_name` **(** :ref:`int` surf_idx, :ref:`String` name **)** | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`surface_update_attribute_region` **(** :ref:`int` surf_idx, :ref:`int` offset, :ref:`PackedByteArray` data **)** | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`surface_update_skin_region` **(** :ref:`int` surf_idx, :ref:`int` offset, :ref:`PackedByteArray` data **)** | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`surface_update_vertex_region` **(** :ref:`int` surf_idx, :ref:`int` offset, :ref:`PackedByteArray` data **)** | - +-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`add_blend_shape` **(** :ref:`StringName` name **)** | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`add_surface_from_arrays` **(** :ref:`PrimitiveType` primitive, :ref:`Array` arrays, :ref:`Array[]` blend_shapes=[], :ref:`Dictionary` lods={}, :ref:`ArrayFormat` compress_flags=0 **)** | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`clear_blend_shapes` **(** **)** | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`clear_surfaces` **(** **)** | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`get_blend_shape_count` **(** **)** |const| | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`StringName` | :ref:`get_blend_shape_name` **(** :ref:`int` index **)** |const| | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Error` | :ref:`lightmap_unwrap` **(** :ref:`Transform3D` transform, :ref:`float` texel_size **)** | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`regen_normal_maps` **(** **)** | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`set_blend_shape_name` **(** :ref:`int` index, :ref:`StringName` name **)** | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`surface_find_by_name` **(** :ref:`String` name **)** |const| | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`surface_get_array_index_len` **(** :ref:`int` surf_idx **)** |const| | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`surface_get_array_len` **(** :ref:`int` surf_idx **)** |const| | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`ArrayFormat` | :ref:`surface_get_format` **(** :ref:`int` surf_idx **)** |const| | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`String` | :ref:`surface_get_name` **(** :ref:`int` surf_idx **)** |const| | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`PrimitiveType` | :ref:`surface_get_primitive_type` **(** :ref:`int` surf_idx **)** |const| | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`surface_set_name` **(** :ref:`int` surf_idx, :ref:`String` name **)** | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`surface_update_attribute_region` **(** :ref:`int` surf_idx, :ref:`int` offset, :ref:`PackedByteArray` data **)** | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`surface_update_skin_region` **(** :ref:`int` surf_idx, :ref:`int` offset, :ref:`PackedByteArray` data **)** | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`surface_update_vertex_region` **(** :ref:`int` surf_idx, :ref:`int` offset, :ref:`PackedByteArray` data **)** | + +-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -226,7 +226,7 @@ Adds name for a blend shape that will be added with :ref:`add_surface_from_array .. rst-class:: classref-method -void **add_surface_from_arrays** **(** :ref:`PrimitiveType` primitive, :ref:`Array` arrays, :ref:`Array[]` blend_shapes=[], :ref:`Dictionary` lods={}, :ref:`int` compress_flags=0 **)** +void **add_surface_from_arrays** **(** :ref:`PrimitiveType` primitive, :ref:`Array` arrays, :ref:`Array[]` blend_shapes=[], :ref:`Dictionary` lods={}, :ref:`ArrayFormat` compress_flags=0 **)** Creates a new surface. @@ -362,7 +362,7 @@ Returns the length in vertices of the vertex array in the requested surface (see .. rst-class:: classref-method -:ref:`int` **surface_get_format** **(** :ref:`int` surf_idx **)** |const| +:ref:`ArrayFormat` **surface_get_format** **(** :ref:`int` surf_idx **)** |const| Returns the format mask of the requested surface (see :ref:`add_surface_from_arrays`). diff --git a/classes/class_astargrid2d.rst b/classes/class_astargrid2d.rst index d434f5822..beeb868c5 100644 --- a/classes/class_astargrid2d.rst +++ b/classes/class_astargrid2d.rst @@ -54,19 +54,21 @@ Properties .. table:: :widths: auto - +----------------------------------------------------+------------------------------------------------------------------------+--------------------+ - | :ref:`Vector2` | :ref:`cell_size` | ``Vector2(1, 1)`` | - +----------------------------------------------------+------------------------------------------------------------------------+--------------------+ - | :ref:`Heuristic` | :ref:`default_heuristic` | ``0`` | - +----------------------------------------------------+------------------------------------------------------------------------+--------------------+ - | :ref:`DiagonalMode` | :ref:`diagonal_mode` | ``0`` | - +----------------------------------------------------+------------------------------------------------------------------------+--------------------+ - | :ref:`bool` | :ref:`jumping_enabled` | ``false`` | - +----------------------------------------------------+------------------------------------------------------------------------+--------------------+ - | :ref:`Vector2` | :ref:`offset` | ``Vector2(0, 0)`` | - +----------------------------------------------------+------------------------------------------------------------------------+--------------------+ - | :ref:`Vector2i` | :ref:`size` | ``Vector2i(0, 0)`` | - +----------------------------------------------------+------------------------------------------------------------------------+--------------------+ + +----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+ + | :ref:`Vector2` | :ref:`cell_size` | ``Vector2(1, 1)`` | + +----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+ + | :ref:`Heuristic` | :ref:`default_compute_heuristic` | ``0`` | + +----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+ + | :ref:`Heuristic` | :ref:`default_estimate_heuristic` | ``0`` | + +----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+ + | :ref:`DiagonalMode` | :ref:`diagonal_mode` | ``0`` | + +----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+ + | :ref:`bool` | :ref:`jumping_enabled` | ``false`` | + +----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+ + | :ref:`Vector2` | :ref:`offset` | ``Vector2(0, 0)`` | + +----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+ + | :ref:`Vector2i` | :ref:`size` | ``Vector2i(0, 0)`` | + +----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+ .. rst-class:: classref-reftable-group @@ -266,18 +268,35 @@ The size of the point cell which will be applied to calculate the resulting poin ---- -.. _class_AStarGrid2D_property_default_heuristic: +.. _class_AStarGrid2D_property_default_compute_heuristic: .. rst-class:: classref-property -:ref:`Heuristic` **default_heuristic** = ``0`` +:ref:`Heuristic` **default_compute_heuristic** = ``0`` .. rst-class:: classref-property-setget -- void **set_default_heuristic** **(** :ref:`Heuristic` value **)** -- :ref:`Heuristic` **get_default_heuristic** **(** **)** +- void **set_default_compute_heuristic** **(** :ref:`Heuristic` value **)** +- :ref:`Heuristic` **get_default_compute_heuristic** **(** **)** -The default :ref:`Heuristic` which will be used to calculate the path if :ref:`_compute_cost` and/or :ref:`_estimate_cost` were not overridden. +The default :ref:`Heuristic` which will be used to calculate the cost between two points if :ref:`_compute_cost` was not overridden. + +.. rst-class:: classref-item-separator + +---- + +.. _class_AStarGrid2D_property_default_estimate_heuristic: + +.. rst-class:: classref-property + +:ref:`Heuristic` **default_estimate_heuristic** = ``0`` + +.. rst-class:: classref-property-setget + +- void **set_default_estimate_heuristic** **(** :ref:`Heuristic` value **)** +- :ref:`Heuristic` **get_default_estimate_heuristic** **(** **)** + +The default :ref:`Heuristic` which will be used to calculate the cost between the point and the end point if :ref:`_estimate_cost` was not overridden. .. rst-class:: classref-item-separator diff --git a/classes/class_basebutton.rst b/classes/class_basebutton.rst index 4efaaece2..f666c8793 100644 --- a/classes/class_basebutton.rst +++ b/classes/class_basebutton.rst @@ -31,29 +31,29 @@ Properties .. table:: :widths: auto - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ - | :ref:`ActionMode` | :ref:`action_mode` | ``1`` | - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ - | :ref:`ButtonGroup` | :ref:`button_group` | | - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ - | :ref:`MouseButton` | :ref:`button_mask` | ``1`` | - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ - | :ref:`bool` | :ref:`button_pressed` | ``false`` | - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ - | :ref:`bool` | :ref:`disabled` | ``false`` | - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ - | :ref:`FocusMode` | focus_mode | ``2`` (overrides :ref:`Control`) | - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ - | :ref:`bool` | :ref:`keep_pressed_outside` | ``false`` | - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ - | :ref:`Shortcut` | :ref:`shortcut` | | - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ - | :ref:`bool` | :ref:`shortcut_feedback` | ``true`` | - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ - | :ref:`bool` | :ref:`shortcut_in_tooltip` | ``true`` | - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ - | :ref:`bool` | :ref:`toggle_mode` | ``false`` | - +---------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + | :ref:`ActionMode` | :ref:`action_mode` | ``1`` | + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + | :ref:`ButtonGroup` | :ref:`button_group` | | + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + | :ref:`MouseButtonMask` | :ref:`button_mask` | ``1`` | + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + | :ref:`bool` | :ref:`button_pressed` | ``false`` | + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + | :ref:`bool` | :ref:`disabled` | ``false`` | + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + | :ref:`FocusMode` | focus_mode | ``2`` (overrides :ref:`Control`) | + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + | :ref:`bool` | :ref:`keep_pressed_outside` | ``false`` | + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + | :ref:`Shortcut` | :ref:`shortcut` | | + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + | :ref:`bool` | :ref:`shortcut_feedback` | ``true`` | + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + | :ref:`bool` | :ref:`shortcut_in_tooltip` | ``true`` | + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ + | :ref:`bool` | :ref:`toggle_mode` | ``false`` | + +-----------------------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+ .. rst-class:: classref-reftable-group @@ -258,12 +258,12 @@ The :ref:`ButtonGroup` associated with the button. Not to be .. rst-class:: classref-property -:ref:`MouseButton` **button_mask** = ``1`` +:ref:`MouseButtonMask` **button_mask** = ``1`` .. rst-class:: classref-property-setget -- void **set_button_mask** **(** :ref:`MouseButton` value **)** -- :ref:`MouseButton` **get_button_mask** **(** **)** +- void **set_button_mask** **(** :ref:`MouseButtonMask` value **)** +- :ref:`MouseButtonMask` **get_button_mask** **(** **)** Binary mask to choose which mouse buttons this button will respond to. diff --git a/classes/class_basematerial3d.rst b/classes/class_basematerial3d.rst index 4b500cc85..2b3acfb5a 100644 --- a/classes/class_basematerial3d.rst +++ b/classes/class_basematerial3d.rst @@ -585,7 +585,7 @@ The material will use the texture's alpha values for transparency. :ref:`Transparency` **TRANSPARENCY_ALPHA_SCISSOR** = ``2`` -The material will cut off all values below a threshold, the rest will remain opaque. The opaque portions will be rendering in the depth prepass. +The material will cut off all values below a threshold, the rest will remain opaque. The opaque portions will be rendered in the depth prepass. .. _class_BaseMaterial3D_constant_TRANSPARENCY_ALPHA_HASH: @@ -601,7 +601,7 @@ The material will cut off all values below a spatially-deterministic threshold, :ref:`Transparency` **TRANSPARENCY_ALPHA_DEPTH_PRE_PASS** = ``4`` -The material will use the texture's alpha value for transparency, but will still be rendered in the depth prepass. +The material will use the texture's alpha value for transparency, but will discard fragments with an alpha of less than 0.99 during the depth prepass and fragments with an alpha less than 0.1 during the shadow pass. .. _class_BaseMaterial3D_constant_TRANSPARENCY_MAX: diff --git a/classes/class_callable.rst b/classes/class_callable.rst index b374080d6..33b822f80 100644 --- a/classes/class_callable.rst +++ b/classes/class_callable.rst @@ -93,12 +93,18 @@ Methods +-------------------------------------+-------------------------------------------------------------------------------------------------------------+ | :ref:`Callable` | :ref:`bind` **(** ... **)** |vararg| |const| | +-------------------------------------+-------------------------------------------------------------------------------------------------------------+ + | :ref:`Callable` | :ref:`bindv` **(** :ref:`Array` arguments **)** | + +-------------------------------------+-------------------------------------------------------------------------------------------------------------+ | :ref:`Variant` | :ref:`call` **(** ... **)** |vararg| |const| | +-------------------------------------+-------------------------------------------------------------------------------------------------------------+ | void | :ref:`call_deferred` **(** ... **)** |vararg| |const| | +-------------------------------------+-------------------------------------------------------------------------------------------------------------+ | :ref:`Variant` | :ref:`callv` **(** :ref:`Array` arguments **)** |const| | +-------------------------------------+-------------------------------------------------------------------------------------------------------------+ + | :ref:`Array` | :ref:`get_bound_arguments` **(** **)** |const| | + +-------------------------------------+-------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`get_bound_arguments_count` **(** **)** |const| | + +-------------------------------------+-------------------------------------------------------------------------------------------------------------+ | :ref:`StringName` | :ref:`get_method` **(** **)** |const| | +-------------------------------------+-------------------------------------------------------------------------------------------------------------+ | :ref:`Object` | :ref:`get_object` **(** **)** |const| | @@ -194,6 +200,18 @@ Returns a copy of this **Callable** with one or more arguments bound. When calle ---- +.. _class_Callable_method_bindv: + +.. rst-class:: classref-method + +:ref:`Callable` **bindv** **(** :ref:`Array` arguments **)** + +Returns a copy of this **Callable** with one or more arguments bound, reading them from an array. When called, the bound arguments are passed *after* the arguments supplied by :ref:`call`. + +.. rst-class:: classref-item-separator + +---- + .. _class_Callable_method_call: .. rst-class:: classref-method @@ -235,6 +253,30 @@ Calls the method represented by this **Callable**. Unlike :ref:`call` **get_bound_arguments** **(** **)** |const| + +Return the bound arguments (as long as :ref:`get_bound_arguments_count` is greater than zero), or empty (if :ref:`get_bound_arguments_count` is less than or equal to zero). + +.. rst-class:: classref-item-separator + +---- + +.. _class_Callable_method_get_bound_arguments_count: + +.. rst-class:: classref-method + +:ref:`int` **get_bound_arguments_count** **(** **)** |const| + +Returns the total amount of arguments bound (or unbound) via successive :ref:`bind` or :ref:`unbind` calls. If the amount of arguments unbound is greater than the ones bound, this function returns a value less than zero. + +.. rst-class:: classref-item-separator + +---- + .. _class_Callable_method_get_method: .. rst-class:: classref-method diff --git a/classes/class_characterbody3d.rst b/classes/class_characterbody3d.rst index 6cd42b765..25a3e5863 100644 --- a/classes/class_characterbody3d.rst +++ b/classes/class_characterbody3d.rst @@ -97,6 +97,8 @@ Methods +---------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`KinematicCollision3D` | :ref:`get_last_slide_collision` **(** **)** | +---------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Vector3` | :ref:`get_platform_angular_velocity` **(** **)** |const| | + +---------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`get_platform_velocity` **(** **)** |const| | +---------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`get_position_delta` **(** **)** |const| | @@ -518,13 +520,25 @@ Returns a :ref:`KinematicCollision3D`, which contain ---- +.. _class_CharacterBody3D_method_get_platform_angular_velocity: + +.. rst-class:: classref-method + +:ref:`Vector3` **get_platform_angular_velocity** **(** **)** |const| + +Returns the angular velocity of the platform at the last collision point. Only valid after calling :ref:`move_and_slide`. + +.. rst-class:: classref-item-separator + +---- + .. _class_CharacterBody3D_method_get_platform_velocity: .. rst-class:: classref-method :ref:`Vector3` **get_platform_velocity** **(** **)** |const| -Returns the linear velocity 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 linear velocity of the platform at the last collision point. Only valid after calling :ref:`move_and_slide`. .. rst-class:: classref-item-separator diff --git a/classes/class_codeedit.rst b/classes/class_codeedit.rst index ad1cafc13..837e476db 100644 --- a/classes/class_codeedit.rst +++ b/classes/class_codeedit.rst @@ -539,7 +539,7 @@ Sets whether code completion is allowed. .. rst-class:: classref-property-setget - void **set_code_completion_prefixes** **(** :ref:`String[]` value **)** -- :ref:`String[]` **get_code_comletion_prefixes** **(** **)** +- :ref:`String[]` **get_code_completion_prefixes** **(** **)** Sets prefixes that will trigger code completion. diff --git a/classes/class_control.rst b/classes/class_control.rst index f35b73fee..d18ec88ae 100644 --- a/classes/class_control.rst +++ b/classes/class_control.rst @@ -129,11 +129,11 @@ Properties +------------------------------------------------------+----------------------------------------------------------------------------------------------+-------------------+ | :ref:`Vector2` | :ref:`size` | ``Vector2(0, 0)`` | +------------------------------------------------------+----------------------------------------------------------------------------------------------+-------------------+ - | :ref:`int` | :ref:`size_flags_horizontal` | ``1`` | + | :ref:`SizeFlags` | :ref:`size_flags_horizontal` | ``1`` | +------------------------------------------------------+----------------------------------------------------------------------------------------------+-------------------+ | :ref:`float` | :ref:`size_flags_stretch_ratio` | ``1.0`` | +------------------------------------------------------+----------------------------------------------------------------------------------------------+-------------------+ - | :ref:`int` | :ref:`size_flags_vertical` | ``1`` | + | :ref:`SizeFlags` | :ref:`size_flags_vertical` | ``1`` | +------------------------------------------------------+----------------------------------------------------------------------------------------------+-------------------+ | :ref:`Theme` | :ref:`theme` | | +------------------------------------------------------+----------------------------------------------------------------------------------------------+-------------------+ @@ -297,7 +297,7 @@ Methods +----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_begin` **(** :ref:`Vector2` position **)** | +----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_drag_forwarding` **(** :ref:`Object` target **)** | + | void | :ref:`set_drag_forwarding` **(** :ref:`Callable` drag_func, :ref:`Callable` can_drop_func, :ref:`Callable` drop_func **)** | +----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_drag_preview` **(** :ref:`Control` control **)** | +----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -818,7 +818,7 @@ The control's size will not change. .. rst-class:: classref-enumeration -enum **SizeFlags**: +flags **SizeFlags**: .. _class_Control_constant_SIZE_SHRINK_BEGIN: @@ -1730,12 +1730,12 @@ The size of the node's bounding rectangle, in pixels. :ref:`Container` **size_flags_horizontal** = ``1`` +:ref:`SizeFlags` **size_flags_horizontal** = ``1`` .. rst-class:: classref-property-setget -- void **set_h_size_flags** **(** :ref:`int` value **)** -- :ref:`int` **get_h_size_flags** **(** **)** +- void **set_h_size_flags** **(** :ref:`SizeFlags` value **)** +- :ref:`SizeFlags` **get_h_size_flags** **(** **)** Tells the parent :ref:`Container` nodes how they should resize and place the node on the X axis. Use one of the :ref:`SizeFlags` constants to change the flags. See the constants to learn what each does. @@ -1764,12 +1764,12 @@ If the node and at least one of its neighbors uses the :ref:`SIZE_EXPAND` **size_flags_vertical** = ``1`` +:ref:`SizeFlags` **size_flags_vertical** = ``1`` .. rst-class:: classref-property-setget -- void **set_v_size_flags** **(** :ref:`int` value **)** -- :ref:`int` **get_v_size_flags** **(** **)** +- void **set_v_size_flags** **(** :ref:`SizeFlags` value **)** +- :ref:`SizeFlags` **get_v_size_flags** **(** **)** Tells the parent :ref:`Container` nodes how they should resize and place the node on the Y axis. Use one of the :ref:`SizeFlags` constants to change the flags. See the constants to learn what each does. @@ -3095,75 +3095,13 @@ Sets :ref:`offset_left` and :ref:`offset_top .. rst-class:: classref-method -void **set_drag_forwarding** **(** :ref:`Object` target **)** +void **set_drag_forwarding** **(** :ref:`Callable` drag_func, :ref:`Callable` can_drop_func, :ref:`Callable` drop_func **)** -Forwards the handling of this control's drag and drop to ``target`` object. - -Forwarding can be implemented in the target object similar to the methods :ref:`_get_drag_data`, :ref:`_can_drop_data`, and :ref:`_drop_data` but with two differences: - -1. The function name must be suffixed with **_fw**\ - -2. The function must take an extra argument that is the control doing the forwarding - - -.. tabs:: - - .. code-tab:: gdscript - - # ThisControl.gd - extends Control - export(Control) var target_control - - func _ready(): - set_drag_forwarding(target_control) - - # TargetControl.gd - extends Control - - func _can_drop_data_fw(position, data, from_control): - return true - - func _drop_data_fw(position, data, from_control): - my_handle_data(data) # Your handler method. - - func _get_drag_data_fw(position, from_control): - set_drag_preview(my_preview) - return my_data() - - .. code-tab:: csharp - - // ThisControl.cs - public class ThisControl : Control - { - [Export] - public Control TargetControl { get; set; } - public override void _Ready() - { - SetDragForwarding(TargetControl); - } - } - - // TargetControl.cs - public class TargetControl : Control - { - public void CanDropDataFw(Vector2 position, object data, Control fromControl) - { - return true; - } - - public void DropDataFw(Vector2 position, object data, Control fromControl) - { - MyHandleData(data); // Your handler method. - } - - public void GetDragDataFw(Vector2 position, Control fromControl) - { - SetDragPreview(MyPreview); - return MyData(); - } - } +Forwards the handling of this control's :ref:`_get_drag_data`, :ref:`_can_drop_data` and :ref:`_drop_data` virtual functions to delegate callables. +For each argument, if not empty, the delegate callable is used, otherwise the local (virtual) function is used. +The function format for each callable should be exactly the same as the virtual functions described above. .. rst-class:: classref-item-separator diff --git a/classes/class_displayserver.rst b/classes/class_displayserver.rst index ac2bad7d6..88373f3f3 100644 --- a/classes/class_displayserver.rst +++ b/classes/class_displayserver.rst @@ -64,8 +64,12 @@ Methods +----------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`String` | :ref:`get_name` **(** **)** |const| | +----------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`get_primary_screen` **(** **)** |const| | + +----------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`get_screen_count` **(** **)** |const| | +----------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`get_screen_from_rect` **(** :ref:`Rect2` rect **)** |const| | + +----------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`get_swap_cancel_ok` **(** **)** | +----------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`get_window_at_screen_position` **(** :ref:`Vector2i` position **)** |const| | @@ -184,7 +188,7 @@ Methods +----------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`keyboard_set_current_layout` **(** :ref:`int` index **)** | +----------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`MouseButton` | :ref:`mouse_get_button_state` **(** **)** |const| | + | :ref:`MouseButtonMask` | :ref:`mouse_get_button_state` **(** **)** |const| | +----------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`MouseMode` | :ref:`mouse_get_mode` **(** **)** |const| | +----------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -546,7 +550,7 @@ Makes the mouse cursor hidden if it is visible. :ref:`MouseMode` **MOUSE_MODE_CAPTURED** = ``2`` -Captures the mouse. The mouse will be hidden and its position locked at the center of the screen. +Captures the mouse. The mouse will be hidden and its position locked at the center of the window manager's window. \ **Note:** If you want to process the mouse's movement in this mode, you need to use :ref:`InputEventMouseMotion.relative`. @@ -1255,6 +1259,14 @@ Utterance reached a word or sentence boundary. Constants --------- +.. _class_DisplayServer_constant_SCREEN_PRIMARY: + +.. rst-class:: classref-constant + +**SCREEN_PRIMARY** = ``-2`` + +Represents the primary screen. + .. _class_DisplayServer_constant_SCREEN_OF_MAIN_WINDOW: .. rst-class:: classref-constant @@ -1498,6 +1510,18 @@ The names of built-in display servers are ``Windows``, ``macOS``, ``X11`` (Linux ---- +.. _class_DisplayServer_method_get_primary_screen: + +.. rst-class:: classref-method + +:ref:`int` **get_primary_screen** **(** **)** |const| + +Returns index of the primary screen. + +.. rst-class:: classref-item-separator + +---- + .. _class_DisplayServer_method_get_screen_count: .. rst-class:: classref-method @@ -1510,6 +1534,18 @@ Returns the number of displays available. ---- +.. _class_DisplayServer_method_get_screen_from_rect: + +.. rst-class:: classref-method + +:ref:`int` **get_screen_from_rect** **(** :ref:`Rect2` rect **)** |const| + +Returns index of the screen which contains specified rectangle. + +.. rst-class:: classref-item-separator + +---- + .. _class_DisplayServer_method_get_swap_cancel_ok: .. rst-class:: classref-method @@ -2449,7 +2485,7 @@ Sets the active keyboard layout. .. rst-class:: classref-method -:ref:`MouseButton` **mouse_get_button_state** **(** **)** |const| +:ref:`MouseButtonMask` **mouse_get_button_state** **(** **)** |const| Returns the current state of mouse buttons (whether each button is pressed) as a bitmask. If multiple mouse buttons are pressed at the same time, the bits are added together. Equivalent to :ref:`Input.get_mouse_button_mask`. diff --git a/classes/class_editorplugin.rst b/classes/class_editorplugin.rst index 6f174ce21..1ac90d6b3 100644 --- a/classes/class_editorplugin.rst +++ b/classes/class_editorplugin.rst @@ -1510,7 +1510,7 @@ Removes a custom translation parser plugin registered by :ref:`add_translation_p void **remove_undo_redo_inspector_hook_callback** **(** :ref:`Callable` callable **)** -Removes a callback previsously added by :ref:`add_undo_redo_inspector_hook_callback`. +Removes a callback previously added by :ref:`add_undo_redo_inspector_hook_callback`. .. rst-class:: classref-item-separator diff --git a/classes/class_editorspinslider.rst b/classes/class_editorspinslider.rst index 326da8b92..1fcd6622c 100644 --- a/classes/class_editorspinslider.rst +++ b/classes/class_editorspinslider.rst @@ -40,7 +40,7 @@ Properties +------------------------------------------+-----------------------------------------------------------------+------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`read_only` | ``false`` | +------------------------------------------+-----------------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`int` | size_flags_vertical | ``1`` (overrides :ref:`Control`) | + | :ref:`SizeFlags` | size_flags_vertical | ``1`` (overrides :ref:`Control`) | +------------------------------------------+-----------------------------------------------------------------+------------------------------------------------------------------------------+ | :ref:`float` | step | ``1.0`` (overrides :ref:`Range`) | +------------------------------------------+-----------------------------------------------------------------+------------------------------------------------------------------------------+ diff --git a/classes/class_input.rst b/classes/class_input.rst index 6dd90fbe8..a5babc7cf 100644 --- a/classes/class_input.rst +++ b/classes/class_input.rst @@ -54,91 +54,91 @@ Methods .. table:: :widths: auto - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`action_press` **(** :ref:`StringName` action, :ref:`float` strength=1.0 **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`action_release` **(** :ref:`StringName` action **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`add_joy_mapping` **(** :ref:`String` mapping, :ref:`bool` update_existing=false **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`flush_buffered_events` **(** **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Vector3` | :ref:`get_accelerometer` **(** **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`get_action_raw_strength` **(** :ref:`StringName` action, :ref:`bool` exact_match=false **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`get_action_strength` **(** :ref:`StringName` action, :ref:`bool` exact_match=false **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`get_axis` **(** :ref:`StringName` negative_action, :ref:`StringName` positive_action **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int[]` | :ref:`get_connected_joypads` **(** **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`CursorShape` | :ref:`get_current_cursor_shape` **(** **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Vector3` | :ref:`get_gravity` **(** **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Vector3` | :ref:`get_gyroscope` **(** **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`get_joy_axis` **(** :ref:`int` device, :ref:`JoyAxis` axis **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`String` | :ref:`get_joy_guid` **(** :ref:`int` device **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`String` | :ref:`get_joy_name` **(** :ref:`int` device **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`get_joy_vibration_duration` **(** :ref:`int` device **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Vector2` | :ref:`get_joy_vibration_strength` **(** :ref:`int` device **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Vector2` | :ref:`get_last_mouse_velocity` **(** **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Vector3` | :ref:`get_magnetometer` **(** **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`MouseButton` | :ref:`get_mouse_button_mask` **(** **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Vector2` | :ref:`get_vector` **(** :ref:`StringName` negative_x, :ref:`StringName` positive_x, :ref:`StringName` negative_y, :ref:`StringName` positive_y, :ref:`float` deadzone=-1.0 **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`is_action_just_pressed` **(** :ref:`StringName` action, :ref:`bool` exact_match=false **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`is_action_just_released` **(** :ref:`StringName` action, :ref:`bool` exact_match=false **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`is_action_pressed` **(** :ref:`StringName` action, :ref:`bool` exact_match=false **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`is_anything_pressed` **(** **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`is_joy_button_pressed` **(** :ref:`int` device, :ref:`JoyButton` button **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`is_joy_known` **(** :ref:`int` device **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`is_key_pressed` **(** :ref:`Key` keycode **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`is_mouse_button_pressed` **(** :ref:`MouseButton` button **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`is_physical_key_pressed` **(** :ref:`Key` keycode **)** |const| | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`parse_input_event` **(** :ref:`InputEvent` event **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`remove_joy_mapping` **(** :ref:`String` guid **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_accelerometer` **(** :ref:`Vector3` value **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_custom_mouse_cursor` **(** :ref:`Resource` image, :ref:`CursorShape` shape=0, :ref:`Vector2` hotspot=Vector2(0, 0) **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_default_cursor_shape` **(** :ref:`CursorShape` shape=0 **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_gravity` **(** :ref:`Vector3` value **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_gyroscope` **(** :ref:`Vector3` value **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_magnetometer` **(** :ref:`Vector3` value **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`start_joy_vibration` **(** :ref:`int` device, :ref:`float` weak_magnitude, :ref:`float` strong_magnitude, :ref:`float` duration=0 **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`stop_joy_vibration` **(** :ref:`int` device **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`vibrate_handheld` **(** :ref:`int` duration_ms=500 **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`warp_mouse` **(** :ref:`Vector2` position **)** | - +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`action_press` **(** :ref:`StringName` action, :ref:`float` strength=1.0 **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`action_release` **(** :ref:`StringName` action **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`add_joy_mapping` **(** :ref:`String` mapping, :ref:`bool` update_existing=false **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`flush_buffered_events` **(** **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Vector3` | :ref:`get_accelerometer` **(** **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`get_action_raw_strength` **(** :ref:`StringName` action, :ref:`bool` exact_match=false **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`get_action_strength` **(** :ref:`StringName` action, :ref:`bool` exact_match=false **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`get_axis` **(** :ref:`StringName` negative_action, :ref:`StringName` positive_action **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int[]` | :ref:`get_connected_joypads` **(** **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`CursorShape` | :ref:`get_current_cursor_shape` **(** **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Vector3` | :ref:`get_gravity` **(** **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Vector3` | :ref:`get_gyroscope` **(** **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`get_joy_axis` **(** :ref:`int` device, :ref:`JoyAxis` axis **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`String` | :ref:`get_joy_guid` **(** :ref:`int` device **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`String` | :ref:`get_joy_name` **(** :ref:`int` device **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`get_joy_vibration_duration` **(** :ref:`int` device **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Vector2` | :ref:`get_joy_vibration_strength` **(** :ref:`int` device **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Vector2` | :ref:`get_last_mouse_velocity` **(** **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Vector3` | :ref:`get_magnetometer` **(** **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`MouseButtonMask` | :ref:`get_mouse_button_mask` **(** **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Vector2` | :ref:`get_vector` **(** :ref:`StringName` negative_x, :ref:`StringName` positive_x, :ref:`StringName` negative_y, :ref:`StringName` positive_y, :ref:`float` deadzone=-1.0 **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_action_just_pressed` **(** :ref:`StringName` action, :ref:`bool` exact_match=false **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_action_just_released` **(** :ref:`StringName` action, :ref:`bool` exact_match=false **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_action_pressed` **(** :ref:`StringName` action, :ref:`bool` exact_match=false **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_anything_pressed` **(** **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_joy_button_pressed` **(** :ref:`int` device, :ref:`JoyButton` button **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_joy_known` **(** :ref:`int` device **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_key_pressed` **(** :ref:`Key` keycode **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_mouse_button_pressed` **(** :ref:`MouseButton` button **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_physical_key_pressed` **(** :ref:`Key` keycode **)** |const| | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`parse_input_event` **(** :ref:`InputEvent` event **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`remove_joy_mapping` **(** :ref:`String` guid **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`set_accelerometer` **(** :ref:`Vector3` value **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`set_custom_mouse_cursor` **(** :ref:`Resource` image, :ref:`CursorShape` shape=0, :ref:`Vector2` hotspot=Vector2(0, 0) **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`set_default_cursor_shape` **(** :ref:`CursorShape` shape=0 **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`set_gravity` **(** :ref:`Vector3` value **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`set_gyroscope` **(** :ref:`Vector3` value **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`set_magnetometer` **(** :ref:`Vector3` value **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`start_joy_vibration` **(** :ref:`int` device, :ref:`float` weak_magnitude, :ref:`float` strong_magnitude, :ref:`float` duration=0 **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`stop_joy_vibration` **(** :ref:`int` device **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`vibrate_handheld` **(** :ref:`int` duration_ms=500 **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`warp_mouse` **(** :ref:`Vector2` position **)** | + +-----------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -194,7 +194,7 @@ Makes the mouse cursor hidden if it is visible. :ref:`MouseMode` **MOUSE_MODE_CAPTURED** = ``2`` -Captures the mouse. The mouse will be hidden and its position locked at the center of the screen. +Captures the mouse. The mouse will be hidden and its position locked at the center of the window manager's window. \ **Note:** If you want to process the mouse's movement in this mode, you need to use :ref:`InputEventMouseMotion.relative`. @@ -668,7 +668,7 @@ Returns the magnetic field strength in micro-Tesla for all axes of the device's .. rst-class:: classref-method -:ref:`MouseButton` **get_mouse_button_mask** **(** **)** |const| +:ref:`MouseButtonMask` **get_mouse_button_mask** **(** **)** |const| Returns mouse buttons as a bitmask. If multiple mouse buttons are pressed at the same time, the bits are added together. Equivalent to :ref:`DisplayServer.mouse_get_button_state`. diff --git a/classes/class_inputeventaction.rst b/classes/class_inputeventaction.rst index 81e0902cc..840586210 100644 --- a/classes/class_inputeventaction.rst +++ b/classes/class_inputeventaction.rst @@ -21,6 +21,8 @@ Description Contains a generic action which can be targeted from several types of inputs. Actions can be created from the **Input Map** tab in the **Project > Project Settings** menu. See :ref:`Node._input`. +\ **Note:** Unlike the other :ref:`InputEvent` subclasses which map to unique physical events, this virtual one is not emitted by the engine. This class is useful to emit actions manually with :ref:`Input.parse_input_event`, which are then received in :ref:`Node._input`. To check if a physical event matches an action from the Input Map, use :ref:`InputEvent.is_action` and :ref:`InputEvent.is_action_pressed`. + .. rst-class:: classref-introduction-group Tutorials diff --git a/classes/class_inputeventmouse.rst b/classes/class_inputeventmouse.rst index 0729bb043..a9f62fed2 100644 --- a/classes/class_inputeventmouse.rst +++ b/classes/class_inputeventmouse.rst @@ -38,13 +38,13 @@ Properties .. table:: :widths: auto - +---------------------------------------------------+------------------------------------------------------------------------+-------------------+ - | :ref:`MouseButton` | :ref:`button_mask` | ``0`` | - +---------------------------------------------------+------------------------------------------------------------------------+-------------------+ - | :ref:`Vector2` | :ref:`global_position` | ``Vector2(0, 0)`` | - +---------------------------------------------------+------------------------------------------------------------------------+-------------------+ - | :ref:`Vector2` | :ref:`position` | ``Vector2(0, 0)`` | - +---------------------------------------------------+------------------------------------------------------------------------+-------------------+ + +-----------------------------------------------------------+------------------------------------------------------------------------+-------------------+ + | :ref:`MouseButtonMask` | :ref:`button_mask` | ``0`` | + +-----------------------------------------------------------+------------------------------------------------------------------------+-------------------+ + | :ref:`Vector2` | :ref:`global_position` | ``Vector2(0, 0)`` | + +-----------------------------------------------------------+------------------------------------------------------------------------+-------------------+ + | :ref:`Vector2` | :ref:`position` | ``Vector2(0, 0)`` | + +-----------------------------------------------------------+------------------------------------------------------------------------+-------------------+ .. rst-class:: classref-section-separator @@ -59,12 +59,12 @@ Property Descriptions .. rst-class:: classref-property -:ref:`MouseButton` **button_mask** = ``0`` +:ref:`MouseButtonMask` **button_mask** = ``0`` .. rst-class:: classref-property-setget -- void **set_button_mask** **(** :ref:`MouseButton` value **)** -- :ref:`MouseButton` **get_button_mask** **(** **)** +- void **set_button_mask** **(** :ref:`MouseButtonMask` value **)** +- :ref:`MouseButtonMask` **get_button_mask** **(** **)** The mouse button mask identifier, one of or a bitwise combination of the :ref:`MouseButton` button masks. diff --git a/classes/class_inputeventscreendrag.rst b/classes/class_inputeventscreendrag.rst index 1c6a20bf3..0b5177879 100644 --- a/classes/class_inputeventscreendrag.rst +++ b/classes/class_inputeventscreendrag.rst @@ -36,15 +36,21 @@ Properties .. table:: :widths: auto - +-------------------------------+---------------------------------------------------------------+-------------------+ - | :ref:`int` | :ref:`index` | ``0`` | - +-------------------------------+---------------------------------------------------------------+-------------------+ - | :ref:`Vector2` | :ref:`position` | ``Vector2(0, 0)`` | - +-------------------------------+---------------------------------------------------------------+-------------------+ - | :ref:`Vector2` | :ref:`relative` | ``Vector2(0, 0)`` | - +-------------------------------+---------------------------------------------------------------+-------------------+ - | :ref:`Vector2` | :ref:`velocity` | ``Vector2(0, 0)`` | - +-------------------------------+---------------------------------------------------------------+-------------------+ + +-------------------------------+-----------------------------------------------------------------------+-------------------+ + | :ref:`int` | :ref:`index` | ``0`` | + +-------------------------------+-----------------------------------------------------------------------+-------------------+ + | :ref:`bool` | :ref:`pen_inverted` | ``false`` | + +-------------------------------+-----------------------------------------------------------------------+-------------------+ + | :ref:`Vector2` | :ref:`position` | ``Vector2(0, 0)`` | + +-------------------------------+-----------------------------------------------------------------------+-------------------+ + | :ref:`float` | :ref:`pressure` | ``0.0`` | + +-------------------------------+-----------------------------------------------------------------------+-------------------+ + | :ref:`Vector2` | :ref:`relative` | ``Vector2(0, 0)`` | + +-------------------------------+-----------------------------------------------------------------------+-------------------+ + | :ref:`Vector2` | :ref:`tilt` | ``Vector2(0, 0)`` | + +-------------------------------+-----------------------------------------------------------------------+-------------------+ + | :ref:`Vector2` | :ref:`velocity` | ``Vector2(0, 0)`` | + +-------------------------------+-----------------------------------------------------------------------+-------------------+ .. rst-class:: classref-section-separator @@ -72,6 +78,23 @@ The drag event index in the case of a multi-drag event. ---- +.. _class_InputEventScreenDrag_property_pen_inverted: + +.. rst-class:: classref-property + +:ref:`bool` **pen_inverted** = ``false`` + +.. rst-class:: classref-property-setget + +- void **set_pen_inverted** **(** :ref:`bool` value **)** +- :ref:`bool` **get_pen_inverted** **(** **)** + +Returns ``true`` when using the eraser end of a stylus pen. + +.. rst-class:: classref-item-separator + +---- + .. _class_InputEventScreenDrag_property_position: .. rst-class:: classref-property @@ -89,6 +112,23 @@ The drag position. ---- +.. _class_InputEventScreenDrag_property_pressure: + +.. rst-class:: classref-property + +:ref:`float` **pressure** = ``0.0`` + +.. rst-class:: classref-property-setget + +- void **set_pressure** **(** :ref:`float` value **)** +- :ref:`float` **get_pressure** **(** **)** + +Represents the pressure the user puts on the pen. Ranges from ``0.0`` to ``1.0``. + +.. rst-class:: classref-item-separator + +---- + .. _class_InputEventScreenDrag_property_relative: .. rst-class:: classref-property @@ -106,6 +146,23 @@ The drag position relative to the previous position (position at the last frame) ---- +.. _class_InputEventScreenDrag_property_tilt: + +.. rst-class:: classref-property + +:ref:`Vector2` **tilt** = ``Vector2(0, 0)`` + +.. rst-class:: classref-property-setget + +- void **set_tilt** **(** :ref:`Vector2` value **)** +- :ref:`Vector2` **get_tilt** **(** **)** + +Represents the angles of tilt of the pen. Positive X-coordinate value indicates a tilt to the right. Positive Y-coordinate value indicates a tilt toward the user. Ranges from ``-1.0`` to ``1.0`` for both axes. + +.. rst-class:: classref-item-separator + +---- + .. _class_InputEventScreenDrag_property_velocity: .. rst-class:: classref-property diff --git a/classes/class_javascriptbridge.rst b/classes/class_javascriptbridge.rst index 18b3aa03a..085d839fd 100644 --- a/classes/class_javascriptbridge.rst +++ b/classes/class_javascriptbridge.rst @@ -47,6 +47,8 @@ Methods +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Variant` | :ref:`eval` **(** :ref:`String` code, :ref:`bool` use_global_execution_context=false **)** | +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`force_fs_sync` **(** **)** | + +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`JavaScriptObject` | :ref:`get_interface` **(** :ref:`String` interface **)** | +-------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`pwa_needs_update` **(** **)** |const| | @@ -136,6 +138,20 @@ If ``use_global_execution_context`` is ``true``, the code will be evaluated in t ---- +.. _class_JavaScriptBridge_method_force_fs_sync: + +.. rst-class:: classref-method + +void **force_fs_sync** **(** **)** + +Force synchronization of the persistent file system (when enabled). + +\ **Note:** This is only useful for modules or extensions that can't use :ref:`FileAccess` to write files. + +.. rst-class:: classref-item-separator + +---- + .. _class_JavaScriptBridge_method_get_interface: .. rst-class:: classref-method diff --git a/classes/class_label.rst b/classes/class_label.rst index 282981103..455665985 100644 --- a/classes/class_label.rst +++ b/classes/class_label.rst @@ -55,7 +55,7 @@ Properties +-----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------+ | :ref:`MouseFilter` | mouse_filter | ``2`` (overrides :ref:`Control`) | +-----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`int` | size_flags_vertical | ``4`` (overrides :ref:`Control`) | + | :ref:`SizeFlags` | size_flags_vertical | ``4`` (overrides :ref:`Control`) | +-----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------+ | :ref:`StructuredTextParser` | :ref:`structured_text_bidi_override` | ``0`` | +-----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------+ diff --git a/classes/class_mesh.rst b/classes/class_mesh.rst index e318452ac..8338477d6 100644 --- a/classes/class_mesh.rst +++ b/classes/class_mesh.rst @@ -377,7 +377,7 @@ Represents the size of the :ref:`ArrayCustomFormat` .. rst-class:: classref-enumeration -enum **ArrayFormat**: +flags **ArrayFormat**: .. _class_Mesh_constant_ARRAY_FORMAT_VERTEX: diff --git a/classes/class_multiplayerspawner.rst b/classes/class_multiplayerspawner.rst index 8e6d34863..8bd8d12af 100644 --- a/classes/class_multiplayerspawner.rst +++ b/classes/class_multiplayerspawner.rst @@ -21,7 +21,7 @@ Description Spawnable scenes can be configured in the editor or through code (see :ref:`add_spawnable_scene`). -Also supports custom node spawns through :ref:`spawn`, calling :ref:`_spawn_custom` on all peers. +Also supports custom node spawns through :ref:`spawn`, calling :ref:`spawn_function` on all peers. Internally, **MultiplayerSpawner** uses :ref:`MultiplayerAPI.object_configuration_add` to notify spawns passing the spawned node as the ``object`` and itself as the ``configuration``, and :ref:`MultiplayerAPI.object_configuration_remove` to notify despawns in a similar way. @@ -33,11 +33,13 @@ Properties .. table:: :widths: auto - +---------------------------------+-------------------------------------------------------------------+------------------+ - | :ref:`int` | :ref:`spawn_limit` | ``0`` | - +---------------------------------+-------------------------------------------------------------------+------------------+ - | :ref:`NodePath` | :ref:`spawn_path` | ``NodePath("")`` | - +---------------------------------+-------------------------------------------------------------------+------------------+ + +---------------------------------+-------------------------------------------------------------------------+------------------+ + | :ref:`Callable` | :ref:`spawn_function` | | + +---------------------------------+-------------------------------------------------------------------------+------------------+ + | :ref:`int` | :ref:`spawn_limit` | ``0`` | + +---------------------------------+-------------------------------------------------------------------------+------------------+ + | :ref:`NodePath` | :ref:`spawn_path` | ``NodePath("")`` | + +---------------------------------+-------------------------------------------------------------------------+------------------+ .. rst-class:: classref-reftable-group @@ -47,8 +49,6 @@ Methods .. table:: :widths: auto - +-----------------------------+---------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Node` | :ref:`_spawn_custom` **(** :ref:`Variant` data **)** |virtual| | +-----------------------------+---------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`add_spawnable_scene` **(** :ref:`String` path **)** | +-----------------------------+---------------------------------------------------------------------------------------------------------------------------------+ @@ -99,6 +99,25 @@ Emitted when a spawnable scene or custom spawn was spawned by the multiplayer au Property Descriptions --------------------- +.. _class_MultiplayerSpawner_property_spawn_function: + +.. rst-class:: classref-property + +:ref:`Callable` **spawn_function** + +.. rst-class:: classref-property-setget + +- void **set_spawn_function** **(** :ref:`Callable` value **)** +- :ref:`Callable` **get_spawn_function** **(** **)** + +Method called on all peers when for every custom :ref:`spawn` requested by the authority. Will receive the ``data`` parameter, and should return a :ref:`Node` that is not in the scene tree. + +\ **Note:** The returned node should **not** be added to the scene with :ref:`Node.add_child`. This is done automatically. + +.. rst-class:: classref-item-separator + +---- + .. _class_MultiplayerSpawner_property_spawn_limit: .. rst-class:: classref-property @@ -140,20 +159,6 @@ Path to the spawn root. Spawnable scenes that are added as direct children are r Method Descriptions ------------------- -.. _class_MultiplayerSpawner_method__spawn_custom: - -.. rst-class:: classref-method - -:ref:`Node` **_spawn_custom** **(** :ref:`Variant` data **)** |virtual| - -Method called on all peers when a custom spawn was requested by the authority using :ref:`spawn`. Should return a :ref:`Node` that is not in the scene tree. - -\ **Note:** Spawned nodes should **not** be added to the scene with :ref:`Node.add_child`. This is done automatically. - -.. rst-class:: classref-item-separator - ----- - .. _class_MultiplayerSpawner_method_add_spawnable_scene: .. rst-class:: classref-method @@ -208,7 +213,7 @@ Returns the count of spawnable scene paths. :ref:`Node` **spawn** **(** :ref:`Variant` data=null **)** -Requests a custom spawn, with ``data`` passed to :ref:`_spawn_custom` on all peers. Returns the locally spawned node instance already inside the scene tree, and added as a child of the node pointed by :ref:`spawn_path`. +Requests a custom spawn, with ``data`` passed to :ref:`spawn_function` on all peers. Returns the locally spawned node instance already inside the scene tree, and added as a child of the node pointed by :ref:`spawn_path`. \ **Note:** Spawnable scenes are spawned automatically. :ref:`spawn` is only needed for custom spawns. diff --git a/classes/class_navigationagent2d.rst b/classes/class_navigationagent2d.rst index 84cfe5785..e1d1c9d10 100644 --- a/classes/class_navigationagent2d.rst +++ b/classes/class_navigationagent2d.rst @@ -23,6 +23,13 @@ Description \ **Note:** After setting :ref:`target_location` it is required to use the :ref:`get_next_location` function once every physics frame to update the internal path logic of the NavigationAgent. The returned vector position from this function should be used as the next movement position for the agent's parent Node. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationAgents <../tutorials/navigation/navigation_using_navigationagents>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationagent3d.rst b/classes/class_navigationagent3d.rst index caf503bc1..fec5cac7f 100644 --- a/classes/class_navigationagent3d.rst +++ b/classes/class_navigationagent3d.rst @@ -23,6 +23,13 @@ Description \ **Note:** After setting :ref:`target_location` it is required to use the :ref:`get_next_location` function once every physics frame to update the internal path logic of the NavigationAgent. The returned vector position from this function should be used as the next movement position for the agent's parent Node. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationAgents <../tutorials/navigation/navigation_using_navigationagents>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationlink2d.rst b/classes/class_navigationlink2d.rst index a0a74d8a9..3cb301278 100644 --- a/classes/class_navigationlink2d.rst +++ b/classes/class_navigationlink2d.rst @@ -21,6 +21,13 @@ Description Creates a link between two locations that :ref:`NavigationServer2D` can route agents through. Links can be used to express navigation methods that aren't just traveling along the surface of the navigation mesh, like zip-lines, teleporters, or jumping across gaps. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationLinks <../tutorials/navigation/navigation_using_navigationlinks>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationlink3d.rst b/classes/class_navigationlink3d.rst index e8d0808bd..a01690541 100644 --- a/classes/class_navigationlink3d.rst +++ b/classes/class_navigationlink3d.rst @@ -21,6 +21,13 @@ Description Creates a link between two locations that :ref:`NavigationServer3D` can route agents through. Links can be used to express navigation methods that aren't just traveling along the surface of the navigation mesh, like zip-lines, teleporters, or jumping across gaps. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationLinks <../tutorials/navigation/navigation_using_navigationlinks>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationmesh.rst b/classes/class_navigationmesh.rst index ae69ccbad..ad344ef28 100644 --- a/classes/class_navigationmesh.rst +++ b/classes/class_navigationmesh.rst @@ -28,6 +28,8 @@ Tutorials - `3D Navmesh Demo `__ +- :doc:`Using NavigationMeshes <../tutorials/navigation/navigation_using_navigationmeshes>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationmeshgenerator.rst b/classes/class_navigationmeshgenerator.rst index 48e5a62ba..daa381d67 100644 --- a/classes/class_navigationmeshgenerator.rst +++ b/classes/class_navigationmeshgenerator.rst @@ -29,6 +29,13 @@ The finalized navigation mesh is then returned and stored inside the :ref:`Navig \ **Note:** Using meshes to not only define walkable surfaces but also obstruct navigation baking does not always work. The navigation baking has no concept of what is a geometry "inside" when dealing with mesh source geometry and this is intentional. Depending on current baking parameters, as soon as the obstructing mesh is large enough to fit a navigation mesh area inside, the baking will generate navigation mesh areas that are inside the obstructing source geometry mesh. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationMeshes <../tutorials/navigation/navigation_using_navigationmeshes>` + .. rst-class:: classref-reftable-group Methods diff --git a/classes/class_navigationobstacle2d.rst b/classes/class_navigationobstacle2d.rst index 6b024dce9..bd2975e3e 100644 --- a/classes/class_navigationobstacle2d.rst +++ b/classes/class_navigationobstacle2d.rst @@ -23,6 +23,13 @@ Description Obstacles **don't** change the resulting path from the pathfinding, they only affect the navigation agent movement in a radius. Therefore, using obstacles for the static walls in your level won't work because those walls don't exist in the pathfinding. The navigation agent will be pushed in a semi-random direction away while moving inside that radius. Obstacles are intended as a last resort option for constantly moving objects that cannot be (re)baked to a navigation mesh efficiently. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationObstacles <../tutorials/navigation/navigation_using_navigationobstacles>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationobstacle3d.rst b/classes/class_navigationobstacle3d.rst index 8d51d7731..af0a871bd 100644 --- a/classes/class_navigationobstacle3d.rst +++ b/classes/class_navigationobstacle3d.rst @@ -23,6 +23,13 @@ Description Obstacles **don't** change the resulting path from the pathfinding, they only affect the navigation agent movement in a radius. Therefore, using obstacles for the static walls in your level won't work because those walls don't exist in the pathfinding. The navigation agent will be pushed in a semi-random direction away while moving inside that radius. Obstacles are intended as a last resort option for constantly moving objects that cannot be (re)baked to a navigation mesh efficiently. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationObstacles <../tutorials/navigation/navigation_using_navigationobstacles>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationpathqueryparameters2d.rst b/classes/class_navigationpathqueryparameters2d.rst index 94abd63ef..7b9afc06d 100644 --- a/classes/class_navigationpathqueryparameters2d.rst +++ b/classes/class_navigationpathqueryparameters2d.rst @@ -21,6 +21,13 @@ Description This class contains the start and target position and other parameters to be used with :ref:`NavigationServer2D.query_path`. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationPathQueryObjects <../tutorials/navigation/navigation_using_navigationpathqueryobjects>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationpathqueryparameters3d.rst b/classes/class_navigationpathqueryparameters3d.rst index ee4ffb402..9e82b79e0 100644 --- a/classes/class_navigationpathqueryparameters3d.rst +++ b/classes/class_navigationpathqueryparameters3d.rst @@ -21,6 +21,13 @@ Description This class contains the start and target position and other parameters to be used with :ref:`NavigationServer3D.query_path`. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationPathQueryObjects <../tutorials/navigation/navigation_using_navigationpathqueryobjects>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationpathqueryresult2d.rst b/classes/class_navigationpathqueryresult2d.rst index 6386052ed..af8e0b3f2 100644 --- a/classes/class_navigationpathqueryresult2d.rst +++ b/classes/class_navigationpathqueryresult2d.rst @@ -21,6 +21,13 @@ Description This class contains the result of a navigation path query from :ref:`NavigationServer2D.query_path`. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationPathQueryObjects <../tutorials/navigation/navigation_using_navigationpathqueryobjects>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationpathqueryresult3d.rst b/classes/class_navigationpathqueryresult3d.rst index 86c076a26..8e35c1a56 100644 --- a/classes/class_navigationpathqueryresult3d.rst +++ b/classes/class_navigationpathqueryresult3d.rst @@ -21,6 +21,13 @@ Description This class contains the result of a navigation path query from :ref:`NavigationServer3D.query_path`. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationPathQueryObjects <../tutorials/navigation/navigation_using_navigationpathqueryobjects>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationpolygon.rst b/classes/class_navigationpolygon.rst index c7d2a8cea..2303b6151 100644 --- a/classes/class_navigationpolygon.rst +++ b/classes/class_navigationpolygon.rst @@ -76,6 +76,8 @@ Tutorials - `2D Navigation Demo `__ +- :doc:`Using NavigationMeshes <../tutorials/navigation/navigation_using_navigationmeshes>` + .. rst-class:: classref-reftable-group Methods diff --git a/classes/class_navigationregion2d.rst b/classes/class_navigationregion2d.rst index 687652531..111926f10 100644 --- a/classes/class_navigationregion2d.rst +++ b/classes/class_navigationregion2d.rst @@ -33,6 +33,13 @@ The pathfinding cost of traveling distances inside this region can be controlled \ **Note:** This node caches changes to its properties, so if you make changes to the underlying region :ref:`RID` in :ref:`NavigationServer2D`, they will not be reflected in this node's properties. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationRegions <../tutorials/navigation/navigation_using_navigationregions>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationregion3d.rst b/classes/class_navigationregion3d.rst index f47c0934d..d8a350087 100644 --- a/classes/class_navigationregion3d.rst +++ b/classes/class_navigationregion3d.rst @@ -33,6 +33,13 @@ The cost of traveling distances inside this region can be controlled with the :r \ **Note:** This node caches changes to its properties, so if you make changes to the underlying region :ref:`RID` in :ref:`NavigationServer3D`, they will not be reflected in this node's properties. +.. rst-class:: classref-introduction-group + +Tutorials +--------- + +- :doc:`Using NavigationRegions <../tutorials/navigation/navigation_using_navigationregions>` + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_navigationserver2d.rst b/classes/class_navigationserver2d.rst index e81a1b19a..eeffd465d 100644 --- a/classes/class_navigationserver2d.rst +++ b/classes/class_navigationserver2d.rst @@ -42,6 +42,8 @@ Tutorials - `2D Navigation Demo `__ +- :doc:`Using NavigationServer <../tutorials/navigation/navigation_using_navigationservers>` + .. rst-class:: classref-reftable-group Methods @@ -51,37 +53,37 @@ Methods :widths: auto +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`RID` | :ref:`agent_create` **(** **)** |const| | + | :ref:`RID` | :ref:`agent_create` **(** **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`RID` | :ref:`agent_get_map` **(** :ref:`RID` agent **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`agent_is_map_changed` **(** :ref:`RID` agent **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_callback` **(** :ref:`RID` agent, :ref:`int` object_id, :ref:`StringName` method, :ref:`Variant` userdata=null **)** |const| | + | void | :ref:`agent_set_callback` **(** :ref:`RID` agent, :ref:`int` object_id, :ref:`StringName` method, :ref:`Variant` userdata=null **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_map` **(** :ref:`RID` agent, :ref:`RID` map **)** |const| | + | void | :ref:`agent_set_map` **(** :ref:`RID` agent, :ref:`RID` map **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_max_neighbors` **(** :ref:`RID` agent, :ref:`int` count **)** |const| | + | void | :ref:`agent_set_max_neighbors` **(** :ref:`RID` agent, :ref:`int` count **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_max_speed` **(** :ref:`RID` agent, :ref:`float` max_speed **)** |const| | + | void | :ref:`agent_set_max_speed` **(** :ref:`RID` agent, :ref:`float` max_speed **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_neighbor_distance` **(** :ref:`RID` agent, :ref:`float` distance **)** |const| | + | void | :ref:`agent_set_neighbor_distance` **(** :ref:`RID` agent, :ref:`float` distance **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_position` **(** :ref:`RID` agent, :ref:`Vector2` position **)** |const| | + | void | :ref:`agent_set_position` **(** :ref:`RID` agent, :ref:`Vector2` position **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_radius` **(** :ref:`RID` agent, :ref:`float` radius **)** |const| | + | void | :ref:`agent_set_radius` **(** :ref:`RID` agent, :ref:`float` radius **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_target_velocity` **(** :ref:`RID` agent, :ref:`Vector2` target_velocity **)** |const| | + | void | :ref:`agent_set_target_velocity` **(** :ref:`RID` agent, :ref:`Vector2` target_velocity **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_time_horizon` **(** :ref:`RID` agent, :ref:`float` time **)** |const| | + | void | :ref:`agent_set_time_horizon` **(** :ref:`RID` agent, :ref:`float` time **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_velocity` **(** :ref:`RID` agent, :ref:`Vector2` velocity **)** |const| | + | void | :ref:`agent_set_velocity` **(** :ref:`RID` agent, :ref:`Vector2` velocity **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`free_rid` **(** :ref:`RID` rid **)** |const| | + | void | :ref:`free_rid` **(** :ref:`RID` rid **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`RID[]` | :ref:`get_maps` **(** **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`RID` | :ref:`link_create` **(** **)** |const| | + | :ref:`RID` | :ref:`link_create` **(** **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`link_get_end_location` **(** :ref:`RID` link **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -99,23 +101,23 @@ Methods +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`link_is_bidirectional` **(** :ref:`RID` link **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_bidirectional` **(** :ref:`RID` link, :ref:`bool` bidirectional **)** |const| | + | void | :ref:`link_set_bidirectional` **(** :ref:`RID` link, :ref:`bool` bidirectional **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_end_location` **(** :ref:`RID` link, :ref:`Vector2` location **)** |const| | + | void | :ref:`link_set_end_location` **(** :ref:`RID` link, :ref:`Vector2` location **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_enter_cost` **(** :ref:`RID` link, :ref:`float` enter_cost **)** |const| | + | void | :ref:`link_set_enter_cost` **(** :ref:`RID` link, :ref:`float` enter_cost **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_map` **(** :ref:`RID` link, :ref:`RID` map **)** |const| | + | void | :ref:`link_set_map` **(** :ref:`RID` link, :ref:`RID` map **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_navigation_layers` **(** :ref:`RID` link, :ref:`int` navigation_layers **)** |const| | + | void | :ref:`link_set_navigation_layers` **(** :ref:`RID` link, :ref:`int` navigation_layers **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_owner_id` **(** :ref:`RID` link, :ref:`int` owner_id **)** |const| | + | void | :ref:`link_set_owner_id` **(** :ref:`RID` link, :ref:`int` owner_id **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_start_location` **(** :ref:`RID` link, :ref:`Vector2` location **)** |const| | + | void | :ref:`link_set_start_location` **(** :ref:`RID` link, :ref:`Vector2` location **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_travel_cost` **(** :ref:`RID` link, :ref:`float` travel_cost **)** |const| | + | void | :ref:`link_set_travel_cost` **(** :ref:`RID` link, :ref:`float` travel_cost **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`RID` | :ref:`map_create` **(** **)** |const| | + | :ref:`RID` | :ref:`map_create` **(** **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`map_force_update` **(** :ref:`RID` map **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -139,17 +141,17 @@ Methods +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`map_is_active` **(** :ref:`RID` map **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`map_set_active` **(** :ref:`RID` map, :ref:`bool` active **)** |const| | + | void | :ref:`map_set_active` **(** :ref:`RID` map, :ref:`bool` active **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`map_set_cell_size` **(** :ref:`RID` map, :ref:`float` cell_size **)** |const| | + | void | :ref:`map_set_cell_size` **(** :ref:`RID` map, :ref:`float` cell_size **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`map_set_edge_connection_margin` **(** :ref:`RID` map, :ref:`float` margin **)** |const| | + | void | :ref:`map_set_edge_connection_margin` **(** :ref:`RID` map, :ref:`float` margin **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`map_set_link_connection_radius` **(** :ref:`RID` map, :ref:`float` radius **)** |const| | + | void | :ref:`map_set_link_connection_radius` **(** :ref:`RID` map, :ref:`float` radius **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`query_path` **(** :ref:`NavigationPathQueryParameters2D` parameters, :ref:`NavigationPathQueryResult2D` result **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`RID` | :ref:`region_create` **(** **)** |const| | + | :ref:`RID` | :ref:`region_create` **(** **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`region_get_connection_pathway_end` **(** :ref:`RID` region, :ref:`int` connection **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -169,19 +171,19 @@ Methods +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`region_owns_point` **(** :ref:`RID` region, :ref:`Vector2` point **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_enter_cost` **(** :ref:`RID` region, :ref:`float` enter_cost **)** |const| | + | void | :ref:`region_set_enter_cost` **(** :ref:`RID` region, :ref:`float` enter_cost **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_map` **(** :ref:`RID` region, :ref:`RID` map **)** |const| | + | void | :ref:`region_set_map` **(** :ref:`RID` region, :ref:`RID` map **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_navigation_layers` **(** :ref:`RID` region, :ref:`int` navigation_layers **)** |const| | + | void | :ref:`region_set_navigation_layers` **(** :ref:`RID` region, :ref:`int` navigation_layers **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_navigation_polygon` **(** :ref:`RID` region, :ref:`NavigationPolygon` navigation_polygon **)** |const| | + | void | :ref:`region_set_navigation_polygon` **(** :ref:`RID` region, :ref:`NavigationPolygon` navigation_polygon **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_owner_id` **(** :ref:`RID` region, :ref:`int` owner_id **)** |const| | + | void | :ref:`region_set_owner_id` **(** :ref:`RID` region, :ref:`int` owner_id **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_transform` **(** :ref:`RID` region, :ref:`Transform2D` transform **)** |const| | + | void | :ref:`region_set_transform` **(** :ref:`RID` region, :ref:`Transform2D` transform **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_travel_cost` **(** :ref:`RID` region, :ref:`float` travel_cost **)** |const| | + | void | :ref:`region_set_travel_cost` **(** :ref:`RID` region, :ref:`float` travel_cost **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -214,7 +216,7 @@ Method Descriptions .. rst-class:: classref-method -:ref:`RID` **agent_create** **(** **)** |const| +:ref:`RID` **agent_create** **(** **)** Creates the agent. @@ -250,7 +252,7 @@ Returns true if the map got changed the previous frame. .. rst-class:: classref-method -void **agent_set_callback** **(** :ref:`RID` agent, :ref:`int` object_id, :ref:`StringName` method, :ref:`Variant` userdata=null **)** |const| +void **agent_set_callback** **(** :ref:`RID` agent, :ref:`int` object_id, :ref:`StringName` method, :ref:`Variant` userdata=null **)** Sets the callback ``object_id`` and ``method`` that gets called after each avoidance processing step for the ``agent``. The calculated ``safe_velocity`` will be dispatched with a signal to the object just before the physics calculations. @@ -264,7 +266,7 @@ Sets the callback ``object_id`` and ``method`` that gets called after each avoid .. rst-class:: classref-method -void **agent_set_map** **(** :ref:`RID` agent, :ref:`RID` map **)** |const| +void **agent_set_map** **(** :ref:`RID` agent, :ref:`RID` map **)** Puts the agent in the map. @@ -276,7 +278,7 @@ Puts the agent in the map. .. rst-class:: classref-method -void **agent_set_max_neighbors** **(** :ref:`RID` agent, :ref:`int` count **)** |const| +void **agent_set_max_neighbors** **(** :ref:`RID` agent, :ref:`int` count **)** Sets the maximum number of other agents the agent takes into account in the navigation. The larger this number, the longer the running time of the simulation. If the number is too low, the simulation will not be safe. @@ -288,7 +290,7 @@ Sets the maximum number of other agents the agent takes into account in the navi .. rst-class:: classref-method -void **agent_set_max_speed** **(** :ref:`RID` agent, :ref:`float` max_speed **)** |const| +void **agent_set_max_speed** **(** :ref:`RID` agent, :ref:`float` max_speed **)** Sets the maximum speed of the agent. Must be positive. @@ -300,7 +302,7 @@ Sets the maximum speed of the agent. Must be positive. .. rst-class:: classref-method -void **agent_set_neighbor_distance** **(** :ref:`RID` agent, :ref:`float` distance **)** |const| +void **agent_set_neighbor_distance** **(** :ref:`RID` agent, :ref:`float` distance **)** Sets the maximum distance to other agents this agent takes into account in the navigation. The larger this number, the longer the running time of the simulation. If the number is too low, the simulation will not be safe. @@ -312,7 +314,7 @@ Sets the maximum distance to other agents this agent takes into account in the n .. rst-class:: classref-method -void **agent_set_position** **(** :ref:`RID` agent, :ref:`Vector2` position **)** |const| +void **agent_set_position** **(** :ref:`RID` agent, :ref:`Vector2` position **)** Sets the position of the agent in world space. @@ -324,7 +326,7 @@ Sets the position of the agent in world space. .. rst-class:: classref-method -void **agent_set_radius** **(** :ref:`RID` agent, :ref:`float` radius **)** |const| +void **agent_set_radius** **(** :ref:`RID` agent, :ref:`float` radius **)** Sets the radius of the agent. @@ -336,7 +338,7 @@ Sets the radius of the agent. .. rst-class:: classref-method -void **agent_set_target_velocity** **(** :ref:`RID` agent, :ref:`Vector2` target_velocity **)** |const| +void **agent_set_target_velocity** **(** :ref:`RID` agent, :ref:`Vector2` target_velocity **)** Sets the new target velocity. @@ -348,7 +350,7 @@ Sets the new target velocity. .. rst-class:: classref-method -void **agent_set_time_horizon** **(** :ref:`RID` agent, :ref:`float` time **)** |const| +void **agent_set_time_horizon** **(** :ref:`RID` agent, :ref:`float` time **)** The minimal amount of time for which the agent's velocities that are computed by the simulation are safe with respect to other agents. The larger this number, the sooner this agent will respond to the presence of other agents, but the less freedom this agent has in choosing its velocities. Must be positive. @@ -360,7 +362,7 @@ The minimal amount of time for which the agent's velocities that are computed by .. rst-class:: classref-method -void **agent_set_velocity** **(** :ref:`RID` agent, :ref:`Vector2` velocity **)** |const| +void **agent_set_velocity** **(** :ref:`RID` agent, :ref:`Vector2` velocity **)** Sets the current velocity of the agent. @@ -372,7 +374,7 @@ Sets the current velocity of the agent. .. rst-class:: classref-method -void **free_rid** **(** :ref:`RID` rid **)** |const| +void **free_rid** **(** :ref:`RID` rid **)** Destroys the given RID. @@ -396,7 +398,7 @@ Returns all created navigation map :ref:`RID`\ s on the NavigationSer .. rst-class:: classref-method -:ref:`RID` **link_create** **(** **)** |const| +:ref:`RID` **link_create** **(** **)** Create a new link between two locations on a map. @@ -504,7 +506,7 @@ Returns whether this ``link`` can be travelled in both directions. .. rst-class:: classref-method -void **link_set_bidirectional** **(** :ref:`RID` link, :ref:`bool` bidirectional **)** |const| +void **link_set_bidirectional** **(** :ref:`RID` link, :ref:`bool` bidirectional **)** Sets whether this ``link`` can be travelled in both directions. @@ -516,7 +518,7 @@ Sets whether this ``link`` can be travelled in both directions. .. rst-class:: classref-method -void **link_set_end_location** **(** :ref:`RID` link, :ref:`Vector2` location **)** |const| +void **link_set_end_location** **(** :ref:`RID` link, :ref:`Vector2` location **)** Sets the exit location for the ``link``. @@ -528,7 +530,7 @@ Sets the exit location for the ``link``. .. rst-class:: classref-method -void **link_set_enter_cost** **(** :ref:`RID` link, :ref:`float` enter_cost **)** |const| +void **link_set_enter_cost** **(** :ref:`RID` link, :ref:`float` enter_cost **)** Sets the ``enter_cost`` for this ``link``. @@ -540,7 +542,7 @@ Sets the ``enter_cost`` for this ``link``. .. rst-class:: classref-method -void **link_set_map** **(** :ref:`RID` link, :ref:`RID` map **)** |const| +void **link_set_map** **(** :ref:`RID` link, :ref:`RID` map **)** Sets the navigation map :ref:`RID` for the link. @@ -552,7 +554,7 @@ Sets the navigation map :ref:`RID` for the link. .. rst-class:: classref-method -void **link_set_navigation_layers** **(** :ref:`RID` link, :ref:`int` navigation_layers **)** |const| +void **link_set_navigation_layers** **(** :ref:`RID` link, :ref:`int` navigation_layers **)** Set the links's navigation layers. This allows selecting links from a path request (when using :ref:`map_get_path`). @@ -564,7 +566,7 @@ Set the links's navigation layers. This allows selecting links from a path reque .. rst-class:: classref-method -void **link_set_owner_id** **(** :ref:`RID` link, :ref:`int` owner_id **)** |const| +void **link_set_owner_id** **(** :ref:`RID` link, :ref:`int` owner_id **)** Set the ``ObjectID`` of the object which manages this link. @@ -576,7 +578,7 @@ Set the ``ObjectID`` of the object which manages this link. .. rst-class:: classref-method -void **link_set_start_location** **(** :ref:`RID` link, :ref:`Vector2` location **)** |const| +void **link_set_start_location** **(** :ref:`RID` link, :ref:`Vector2` location **)** Sets the entry location for this ``link``. @@ -588,7 +590,7 @@ Sets the entry location for this ``link``. .. rst-class:: classref-method -void **link_set_travel_cost** **(** :ref:`RID` link, :ref:`float` travel_cost **)** |const| +void **link_set_travel_cost** **(** :ref:`RID` link, :ref:`float` travel_cost **)** Sets the ``travel_cost`` for this ``link``. @@ -600,7 +602,7 @@ Sets the ``travel_cost`` for this ``link``. .. rst-class:: classref-method -:ref:`RID` **map_create** **(** **)** |const| +:ref:`RID` **map_create** **(** **)** Create a new map. @@ -750,7 +752,7 @@ Returns true if the map is active. .. rst-class:: classref-method -void **map_set_active** **(** :ref:`RID` map, :ref:`bool` active **)** |const| +void **map_set_active** **(** :ref:`RID` map, :ref:`bool` active **)** Sets the map active. @@ -762,7 +764,7 @@ Sets the map active. .. rst-class:: classref-method -void **map_set_cell_size** **(** :ref:`RID` map, :ref:`float` cell_size **)** |const| +void **map_set_cell_size** **(** :ref:`RID` map, :ref:`float` cell_size **)** Set the map cell size used to weld the navigation mesh polygons. @@ -774,7 +776,7 @@ Set the map cell size used to weld the navigation mesh polygons. .. rst-class:: classref-method -void **map_set_edge_connection_margin** **(** :ref:`RID` map, :ref:`float` margin **)** |const| +void **map_set_edge_connection_margin** **(** :ref:`RID` map, :ref:`float` margin **)** Set the map edge connection margin used to weld the compatible region edges. @@ -786,7 +788,7 @@ Set the map edge connection margin used to weld the compatible region edges. .. rst-class:: classref-method -void **map_set_link_connection_radius** **(** :ref:`RID` map, :ref:`float` radius **)** |const| +void **map_set_link_connection_radius** **(** :ref:`RID` map, :ref:`float` radius **)** Set the map's link connection radius used to connect links to navigation polygons. @@ -810,7 +812,7 @@ Queries a path in a given navigation map. Start and target position and other pa .. rst-class:: classref-method -:ref:`RID` **region_create** **(** **)** |const| +:ref:`RID` **region_create** **(** **)** Creates a new region. @@ -934,7 +936,7 @@ If multiple navigation meshes have positions at equal distance the navigation re .. rst-class:: classref-method -void **region_set_enter_cost** **(** :ref:`RID` region, :ref:`float` enter_cost **)** |const| +void **region_set_enter_cost** **(** :ref:`RID` region, :ref:`float` enter_cost **)** Sets the ``enter_cost`` for this ``region``. @@ -946,7 +948,7 @@ Sets the ``enter_cost`` for this ``region``. .. rst-class:: classref-method -void **region_set_map** **(** :ref:`RID` region, :ref:`RID` map **)** |const| +void **region_set_map** **(** :ref:`RID` region, :ref:`RID` map **)** Sets the map for the region. @@ -958,7 +960,7 @@ Sets the map for the region. .. rst-class:: classref-method -void **region_set_navigation_layers** **(** :ref:`RID` region, :ref:`int` navigation_layers **)** |const| +void **region_set_navigation_layers** **(** :ref:`RID` region, :ref:`int` navigation_layers **)** Set the region's navigation layers. This allows selecting regions from a path request (when using :ref:`map_get_path`). @@ -970,7 +972,7 @@ Set the region's navigation layers. This allows selecting regions from a path re .. rst-class:: classref-method -void **region_set_navigation_polygon** **(** :ref:`RID` region, :ref:`NavigationPolygon` navigation_polygon **)** |const| +void **region_set_navigation_polygon** **(** :ref:`RID` region, :ref:`NavigationPolygon` navigation_polygon **)** Sets the ``navigation_polygon`` for the region. @@ -982,7 +984,7 @@ Sets the ``navigation_polygon`` for the region. .. rst-class:: classref-method -void **region_set_owner_id** **(** :ref:`RID` region, :ref:`int` owner_id **)** |const| +void **region_set_owner_id** **(** :ref:`RID` region, :ref:`int` owner_id **)** Set the ``ObjectID`` of the object which manages this region. @@ -994,7 +996,7 @@ Set the ``ObjectID`` of the object which manages this region. .. rst-class:: classref-method -void **region_set_transform** **(** :ref:`RID` region, :ref:`Transform2D` transform **)** |const| +void **region_set_transform** **(** :ref:`RID` region, :ref:`Transform2D` transform **)** Sets the global transformation for the region. @@ -1006,7 +1008,7 @@ Sets the global transformation for the region. .. rst-class:: classref-method -void **region_set_travel_cost** **(** :ref:`RID` region, :ref:`float` travel_cost **)** |const| +void **region_set_travel_cost** **(** :ref:`RID` region, :ref:`float` travel_cost **)** Sets the ``travel_cost`` for this ``region``. diff --git a/classes/class_navigationserver3d.rst b/classes/class_navigationserver3d.rst index 9a0008d02..e99f0e4c6 100644 --- a/classes/class_navigationserver3d.rst +++ b/classes/class_navigationserver3d.rst @@ -42,6 +42,8 @@ Tutorials - `3D Navmesh Demo `__ +- :doc:`Using NavigationServer <../tutorials/navigation/navigation_using_navigationservers>` + .. rst-class:: classref-reftable-group Methods @@ -51,37 +53,37 @@ Methods :widths: auto +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`RID` | :ref:`agent_create` **(** **)** |const| | + | :ref:`RID` | :ref:`agent_create` **(** **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`RID` | :ref:`agent_get_map` **(** :ref:`RID` agent **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`agent_is_map_changed` **(** :ref:`RID` agent **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_callback` **(** :ref:`RID` agent, :ref:`int` object_id, :ref:`StringName` method, :ref:`Variant` userdata=null **)** |const| | + | void | :ref:`agent_set_callback` **(** :ref:`RID` agent, :ref:`int` object_id, :ref:`StringName` method, :ref:`Variant` userdata=null **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_map` **(** :ref:`RID` agent, :ref:`RID` map **)** |const| | + | void | :ref:`agent_set_map` **(** :ref:`RID` agent, :ref:`RID` map **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_max_neighbors` **(** :ref:`RID` agent, :ref:`int` count **)** |const| | + | void | :ref:`agent_set_max_neighbors` **(** :ref:`RID` agent, :ref:`int` count **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_max_speed` **(** :ref:`RID` agent, :ref:`float` max_speed **)** |const| | + | void | :ref:`agent_set_max_speed` **(** :ref:`RID` agent, :ref:`float` max_speed **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_neighbor_distance` **(** :ref:`RID` agent, :ref:`float` distance **)** |const| | + | void | :ref:`agent_set_neighbor_distance` **(** :ref:`RID` agent, :ref:`float` distance **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_position` **(** :ref:`RID` agent, :ref:`Vector3` position **)** |const| | + | void | :ref:`agent_set_position` **(** :ref:`RID` agent, :ref:`Vector3` position **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_radius` **(** :ref:`RID` agent, :ref:`float` radius **)** |const| | + | void | :ref:`agent_set_radius` **(** :ref:`RID` agent, :ref:`float` radius **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_target_velocity` **(** :ref:`RID` agent, :ref:`Vector3` target_velocity **)** |const| | + | void | :ref:`agent_set_target_velocity` **(** :ref:`RID` agent, :ref:`Vector3` target_velocity **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_time_horizon` **(** :ref:`RID` agent, :ref:`float` time **)** |const| | + | void | :ref:`agent_set_time_horizon` **(** :ref:`RID` agent, :ref:`float` time **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`agent_set_velocity` **(** :ref:`RID` agent, :ref:`Vector3` velocity **)** |const| | + | void | :ref:`agent_set_velocity` **(** :ref:`RID` agent, :ref:`Vector3` velocity **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`free_rid` **(** :ref:`RID` rid **)** |const| | + | void | :ref:`free_rid` **(** :ref:`RID` rid **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`RID[]` | :ref:`get_maps` **(** **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`RID` | :ref:`link_create` **(** **)** |const| | + | :ref:`RID` | :ref:`link_create` **(** **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`link_get_end_location` **(** :ref:`RID` link **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -99,23 +101,23 @@ Methods +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`link_is_bidirectional` **(** :ref:`RID` link **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_bidirectional` **(** :ref:`RID` link, :ref:`bool` bidirectional **)** |const| | + | void | :ref:`link_set_bidirectional` **(** :ref:`RID` link, :ref:`bool` bidirectional **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_end_location` **(** :ref:`RID` link, :ref:`Vector3` location **)** |const| | + | void | :ref:`link_set_end_location` **(** :ref:`RID` link, :ref:`Vector3` location **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_enter_cost` **(** :ref:`RID` link, :ref:`float` enter_cost **)** |const| | + | void | :ref:`link_set_enter_cost` **(** :ref:`RID` link, :ref:`float` enter_cost **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_map` **(** :ref:`RID` link, :ref:`RID` map **)** |const| | + | void | :ref:`link_set_map` **(** :ref:`RID` link, :ref:`RID` map **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_navigation_layers` **(** :ref:`RID` link, :ref:`int` navigation_layers **)** |const| | + | void | :ref:`link_set_navigation_layers` **(** :ref:`RID` link, :ref:`int` navigation_layers **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_owner_id` **(** :ref:`RID` link, :ref:`int` owner_id **)** |const| | + | void | :ref:`link_set_owner_id` **(** :ref:`RID` link, :ref:`int` owner_id **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_start_location` **(** :ref:`RID` link, :ref:`Vector3` location **)** |const| | + | void | :ref:`link_set_start_location` **(** :ref:`RID` link, :ref:`Vector3` location **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`link_set_travel_cost` **(** :ref:`RID` link, :ref:`float` travel_cost **)** |const| | + | void | :ref:`link_set_travel_cost` **(** :ref:`RID` link, :ref:`float` travel_cost **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`RID` | :ref:`map_create` **(** **)** |const| | + | :ref:`RID` | :ref:`map_create` **(** **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`map_force_update` **(** :ref:`RID` map **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -145,23 +147,23 @@ Methods +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`map_is_active` **(** :ref:`RID` map **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`map_set_active` **(** :ref:`RID` map, :ref:`bool` active **)** |const| | + | void | :ref:`map_set_active` **(** :ref:`RID` map, :ref:`bool` active **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`map_set_cell_size` **(** :ref:`RID` map, :ref:`float` cell_size **)** |const| | + | void | :ref:`map_set_cell_size` **(** :ref:`RID` map, :ref:`float` cell_size **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`map_set_edge_connection_margin` **(** :ref:`RID` map, :ref:`float` margin **)** |const| | + | void | :ref:`map_set_edge_connection_margin` **(** :ref:`RID` map, :ref:`float` margin **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`map_set_link_connection_radius` **(** :ref:`RID` map, :ref:`float` radius **)** |const| | + | void | :ref:`map_set_link_connection_radius` **(** :ref:`RID` map, :ref:`float` radius **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`map_set_up` **(** :ref:`RID` map, :ref:`Vector3` up **)** |const| | + | void | :ref:`map_set_up` **(** :ref:`RID` map, :ref:`Vector3` up **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`process` **(** :ref:`float` delta_time **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`query_path` **(** :ref:`NavigationPathQueryParameters3D` parameters, :ref:`NavigationPathQueryResult3D` result **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_bake_navigation_mesh` **(** :ref:`NavigationMesh` navigation_mesh, :ref:`Node` root_node **)** |const| | + | void | :ref:`region_bake_navigation_mesh` **(** :ref:`NavigationMesh` navigation_mesh, :ref:`Node` root_node **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`RID` | :ref:`region_create` **(** **)** |const| | + | :ref:`RID` | :ref:`region_create` **(** **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`region_get_connection_pathway_end` **(** :ref:`RID` region, :ref:`int` connection **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -181,21 +183,21 @@ Methods +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`region_owns_point` **(** :ref:`RID` region, :ref:`Vector3` point **)** |const| | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_enter_cost` **(** :ref:`RID` region, :ref:`float` enter_cost **)** |const| | + | void | :ref:`region_set_enter_cost` **(** :ref:`RID` region, :ref:`float` enter_cost **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_map` **(** :ref:`RID` region, :ref:`RID` map **)** |const| | + | void | :ref:`region_set_map` **(** :ref:`RID` region, :ref:`RID` map **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_navigation_layers` **(** :ref:`RID` region, :ref:`int` navigation_layers **)** |const| | + | void | :ref:`region_set_navigation_layers` **(** :ref:`RID` region, :ref:`int` navigation_layers **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_navigation_mesh` **(** :ref:`RID` region, :ref:`NavigationMesh` navigation_mesh **)** |const| | + | void | :ref:`region_set_navigation_mesh` **(** :ref:`RID` region, :ref:`NavigationMesh` navigation_mesh **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_owner_id` **(** :ref:`RID` region, :ref:`int` owner_id **)** |const| | + | void | :ref:`region_set_owner_id` **(** :ref:`RID` region, :ref:`int` owner_id **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_transform` **(** :ref:`RID` region, :ref:`Transform3D` transform **)** |const| | + | void | :ref:`region_set_transform` **(** :ref:`RID` region, :ref:`Transform3D` transform **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`region_set_travel_cost` **(** :ref:`RID` region, :ref:`float` travel_cost **)** |const| | + | void | :ref:`region_set_travel_cost` **(** :ref:`RID` region, :ref:`float` travel_cost **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_active` **(** :ref:`bool` active **)** |const| | + | void | :ref:`set_active` **(** :ref:`bool` active **)** | +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -240,7 +242,7 @@ Method Descriptions .. rst-class:: classref-method -:ref:`RID` **agent_create** **(** **)** |const| +:ref:`RID` **agent_create** **(** **)** Creates the agent. @@ -276,7 +278,7 @@ Returns true if the map got changed the previous frame. .. rst-class:: classref-method -void **agent_set_callback** **(** :ref:`RID` agent, :ref:`int` object_id, :ref:`StringName` method, :ref:`Variant` userdata=null **)** |const| +void **agent_set_callback** **(** :ref:`RID` agent, :ref:`int` object_id, :ref:`StringName` method, :ref:`Variant` userdata=null **)** Sets the callback ``object_id`` and ``method`` that gets called after each avoidance processing step for the ``agent``. The calculated ``safe_velocity`` will be dispatched with a signal to the object just before the physics calculations. @@ -290,7 +292,7 @@ Sets the callback ``object_id`` and ``method`` that gets called after each avoid .. rst-class:: classref-method -void **agent_set_map** **(** :ref:`RID` agent, :ref:`RID` map **)** |const| +void **agent_set_map** **(** :ref:`RID` agent, :ref:`RID` map **)** Puts the agent in the map. @@ -302,7 +304,7 @@ Puts the agent in the map. .. rst-class:: classref-method -void **agent_set_max_neighbors** **(** :ref:`RID` agent, :ref:`int` count **)** |const| +void **agent_set_max_neighbors** **(** :ref:`RID` agent, :ref:`int` count **)** Sets the maximum number of other agents the agent takes into account in the navigation. The larger this number, the longer the running time of the simulation. If the number is too low, the simulation will not be safe. @@ -314,7 +316,7 @@ Sets the maximum number of other agents the agent takes into account in the navi .. rst-class:: classref-method -void **agent_set_max_speed** **(** :ref:`RID` agent, :ref:`float` max_speed **)** |const| +void **agent_set_max_speed** **(** :ref:`RID` agent, :ref:`float` max_speed **)** Sets the maximum speed of the agent. Must be positive. @@ -326,7 +328,7 @@ Sets the maximum speed of the agent. Must be positive. .. rst-class:: classref-method -void **agent_set_neighbor_distance** **(** :ref:`RID` agent, :ref:`float` distance **)** |const| +void **agent_set_neighbor_distance** **(** :ref:`RID` agent, :ref:`float` distance **)** Sets the maximum distance to other agents this agent takes into account in the navigation. The larger this number, the longer the running time of the simulation. If the number is too low, the simulation will not be safe. @@ -338,7 +340,7 @@ Sets the maximum distance to other agents this agent takes into account in the n .. rst-class:: classref-method -void **agent_set_position** **(** :ref:`RID` agent, :ref:`Vector3` position **)** |const| +void **agent_set_position** **(** :ref:`RID` agent, :ref:`Vector3` position **)** Sets the position of the agent in world space. @@ -350,7 +352,7 @@ Sets the position of the agent in world space. .. rst-class:: classref-method -void **agent_set_radius** **(** :ref:`RID` agent, :ref:`float` radius **)** |const| +void **agent_set_radius** **(** :ref:`RID` agent, :ref:`float` radius **)** Sets the radius of the agent. @@ -362,7 +364,7 @@ Sets the radius of the agent. .. rst-class:: classref-method -void **agent_set_target_velocity** **(** :ref:`RID` agent, :ref:`Vector3` target_velocity **)** |const| +void **agent_set_target_velocity** **(** :ref:`RID` agent, :ref:`Vector3` target_velocity **)** Sets the new target velocity. @@ -374,7 +376,7 @@ Sets the new target velocity. .. rst-class:: classref-method -void **agent_set_time_horizon** **(** :ref:`RID` agent, :ref:`float` time **)** |const| +void **agent_set_time_horizon** **(** :ref:`RID` agent, :ref:`float` time **)** The minimal amount of time for which the agent's velocities that are computed by the simulation are safe with respect to other agents. The larger this number, the sooner this agent will respond to the presence of other agents, but the less freedom this agent has in choosing its velocities. Must be positive. @@ -386,7 +388,7 @@ The minimal amount of time for which the agent's velocities that are computed by .. rst-class:: classref-method -void **agent_set_velocity** **(** :ref:`RID` agent, :ref:`Vector3` velocity **)** |const| +void **agent_set_velocity** **(** :ref:`RID` agent, :ref:`Vector3` velocity **)** Sets the current velocity of the agent. @@ -398,7 +400,7 @@ Sets the current velocity of the agent. .. rst-class:: classref-method -void **free_rid** **(** :ref:`RID` rid **)** |const| +void **free_rid** **(** :ref:`RID` rid **)** Destroys the given RID. @@ -422,7 +424,7 @@ Returns all created navigation map :ref:`RID`\ s on the NavigationSer .. rst-class:: classref-method -:ref:`RID` **link_create** **(** **)** |const| +:ref:`RID` **link_create** **(** **)** Create a new link between two locations on a map. @@ -530,7 +532,7 @@ Returns whether this ``link`` can be travelled in both directions. .. rst-class:: classref-method -void **link_set_bidirectional** **(** :ref:`RID` link, :ref:`bool` bidirectional **)** |const| +void **link_set_bidirectional** **(** :ref:`RID` link, :ref:`bool` bidirectional **)** Sets whether this ``link`` can be travelled in both directions. @@ -542,7 +544,7 @@ Sets whether this ``link`` can be travelled in both directions. .. rst-class:: classref-method -void **link_set_end_location** **(** :ref:`RID` link, :ref:`Vector3` location **)** |const| +void **link_set_end_location** **(** :ref:`RID` link, :ref:`Vector3` location **)** Sets the exit location for the ``link``. @@ -554,7 +556,7 @@ Sets the exit location for the ``link``. .. rst-class:: classref-method -void **link_set_enter_cost** **(** :ref:`RID` link, :ref:`float` enter_cost **)** |const| +void **link_set_enter_cost** **(** :ref:`RID` link, :ref:`float` enter_cost **)** Sets the ``enter_cost`` for this ``link``. @@ -566,7 +568,7 @@ Sets the ``enter_cost`` for this ``link``. .. rst-class:: classref-method -void **link_set_map** **(** :ref:`RID` link, :ref:`RID` map **)** |const| +void **link_set_map** **(** :ref:`RID` link, :ref:`RID` map **)** Sets the navigation map :ref:`RID` for the link. @@ -578,7 +580,7 @@ Sets the navigation map :ref:`RID` for the link. .. rst-class:: classref-method -void **link_set_navigation_layers** **(** :ref:`RID` link, :ref:`int` navigation_layers **)** |const| +void **link_set_navigation_layers** **(** :ref:`RID` link, :ref:`int` navigation_layers **)** Set the links's navigation layers. This allows selecting links from a path request (when using :ref:`map_get_path`). @@ -590,7 +592,7 @@ Set the links's navigation layers. This allows selecting links from a path reque .. rst-class:: classref-method -void **link_set_owner_id** **(** :ref:`RID` link, :ref:`int` owner_id **)** |const| +void **link_set_owner_id** **(** :ref:`RID` link, :ref:`int` owner_id **)** Set the ``ObjectID`` of the object which manages this link. @@ -602,7 +604,7 @@ Set the ``ObjectID`` of the object which manages this link. .. rst-class:: classref-method -void **link_set_start_location** **(** :ref:`RID` link, :ref:`Vector3` location **)** |const| +void **link_set_start_location** **(** :ref:`RID` link, :ref:`Vector3` location **)** Sets the entry location for this ``link``. @@ -614,7 +616,7 @@ Sets the entry location for this ``link``. .. rst-class:: classref-method -void **link_set_travel_cost** **(** :ref:`RID` link, :ref:`float` travel_cost **)** |const| +void **link_set_travel_cost** **(** :ref:`RID` link, :ref:`float` travel_cost **)** Sets the ``travel_cost`` for this ``link``. @@ -626,7 +628,7 @@ Sets the ``travel_cost`` for this ``link``. .. rst-class:: classref-method -:ref:`RID` **map_create** **(** **)** |const| +:ref:`RID` **map_create** **(** **)** Create a new map. @@ -812,7 +814,7 @@ Returns true if the map is active. .. rst-class:: classref-method -void **map_set_active** **(** :ref:`RID` map, :ref:`bool` active **)** |const| +void **map_set_active** **(** :ref:`RID` map, :ref:`bool` active **)** Sets the map active. @@ -824,7 +826,7 @@ Sets the map active. .. rst-class:: classref-method -void **map_set_cell_size** **(** :ref:`RID` map, :ref:`float` cell_size **)** |const| +void **map_set_cell_size** **(** :ref:`RID` map, :ref:`float` cell_size **)** Set the map cell size used to weld the navigation mesh polygons. @@ -836,7 +838,7 @@ Set the map cell size used to weld the navigation mesh polygons. .. rst-class:: classref-method -void **map_set_edge_connection_margin** **(** :ref:`RID` map, :ref:`float` margin **)** |const| +void **map_set_edge_connection_margin** **(** :ref:`RID` map, :ref:`float` margin **)** Set the map edge connection margin used to weld the compatible region edges. @@ -848,7 +850,7 @@ Set the map edge connection margin used to weld the compatible region edges. .. rst-class:: classref-method -void **map_set_link_connection_radius** **(** :ref:`RID` map, :ref:`float` radius **)** |const| +void **map_set_link_connection_radius** **(** :ref:`RID` map, :ref:`float` radius **)** Set the map's link connection radius used to connect links to navigation polygons. @@ -860,7 +862,7 @@ Set the map's link connection radius used to connect links to navigation polygon .. rst-class:: classref-method -void **map_set_up** **(** :ref:`RID` map, :ref:`Vector3` up **)** |const| +void **map_set_up** **(** :ref:`RID` map, :ref:`Vector3` up **)** Sets the map up direction. @@ -900,7 +902,7 @@ Queries a path in a given navigation map. Start and target position and other pa .. rst-class:: classref-method -void **region_bake_navigation_mesh** **(** :ref:`NavigationMesh` navigation_mesh, :ref:`Node` root_node **)** |const| +void **region_bake_navigation_mesh** **(** :ref:`NavigationMesh` navigation_mesh, :ref:`Node` root_node **)** Bakes the ``navigation_mesh`` with bake source geometry collected starting from the ``root_node``. @@ -912,7 +914,7 @@ Bakes the ``navigation_mesh`` with bake source geometry collected starting from .. rst-class:: classref-method -:ref:`RID` **region_create** **(** **)** |const| +:ref:`RID` **region_create** **(** **)** Creates a new region. @@ -1036,7 +1038,7 @@ If multiple navigation meshes have positions at equal distance the navigation re .. rst-class:: classref-method -void **region_set_enter_cost** **(** :ref:`RID` region, :ref:`float` enter_cost **)** |const| +void **region_set_enter_cost** **(** :ref:`RID` region, :ref:`float` enter_cost **)** Sets the ``enter_cost`` for this ``region``. @@ -1048,7 +1050,7 @@ Sets the ``enter_cost`` for this ``region``. .. rst-class:: classref-method -void **region_set_map** **(** :ref:`RID` region, :ref:`RID` map **)** |const| +void **region_set_map** **(** :ref:`RID` region, :ref:`RID` map **)** Sets the map for the region. @@ -1060,7 +1062,7 @@ Sets the map for the region. .. rst-class:: classref-method -void **region_set_navigation_layers** **(** :ref:`RID` region, :ref:`int` navigation_layers **)** |const| +void **region_set_navigation_layers** **(** :ref:`RID` region, :ref:`int` navigation_layers **)** Set the region's navigation layers. This allows selecting regions from a path request (when using :ref:`map_get_path`). @@ -1072,7 +1074,7 @@ Set the region's navigation layers. This allows selecting regions from a path re .. rst-class:: classref-method -void **region_set_navigation_mesh** **(** :ref:`RID` region, :ref:`NavigationMesh` navigation_mesh **)** |const| +void **region_set_navigation_mesh** **(** :ref:`RID` region, :ref:`NavigationMesh` navigation_mesh **)** Sets the navigation mesh for the region. @@ -1084,7 +1086,7 @@ Sets the navigation mesh for the region. .. rst-class:: classref-method -void **region_set_owner_id** **(** :ref:`RID` region, :ref:`int` owner_id **)** |const| +void **region_set_owner_id** **(** :ref:`RID` region, :ref:`int` owner_id **)** Set the ``ObjectID`` of the object which manages this region. @@ -1096,7 +1098,7 @@ Set the ``ObjectID`` of the object which manages this region. .. rst-class:: classref-method -void **region_set_transform** **(** :ref:`RID` region, :ref:`Transform3D` transform **)** |const| +void **region_set_transform** **(** :ref:`RID` region, :ref:`Transform3D` transform **)** Sets the global transformation for the region. @@ -1108,7 +1110,7 @@ Sets the global transformation for the region. .. rst-class:: classref-method -void **region_set_travel_cost** **(** :ref:`RID` region, :ref:`float` travel_cost **)** |const| +void **region_set_travel_cost** **(** :ref:`RID` region, :ref:`float` travel_cost **)** Sets the ``travel_cost`` for this ``region``. @@ -1120,7 +1122,7 @@ Sets the ``travel_cost`` for this ``region``. .. rst-class:: classref-method -void **set_active** **(** :ref:`bool` active **)** |const| +void **set_active** **(** :ref:`bool` active **)** Control activation of this server. diff --git a/classes/class_node.rst b/classes/class_node.rst index 8ab234c44..fae16284c 100644 --- a/classes/class_node.rst +++ b/classes/class_node.rst @@ -161,6 +161,8 @@ Methods +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Viewport` | :ref:`get_viewport` **(** **)** |const| | +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Window` | :ref:`get_window` **(** **)** |const| | + +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`has_node` **(** :ref:`NodePath` path **)** |const| | +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`has_node_and_resource` **(** :ref:`NodePath` path **)** |const| | @@ -213,6 +215,8 @@ Methods +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`remove_from_group` **(** :ref:`StringName` group **)** | +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`reparent` **(** :ref:`Node` new_parent, :ref:`bool` keep_global_transform=true **)** | + +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`replace_by` **(** :ref:`Node` node, :ref:`bool` keep_groups=false **)** | +---------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`request_ready` **(** **)** | @@ -1690,6 +1694,18 @@ Returns the node's :ref:`Viewport`. ---- +.. _class_Node_method_get_window: + +.. rst-class:: classref-method + +:ref:`Window` **get_window** **(** **)** |const| + +Returns the :ref:`Window` that contains this node. If the node is in the main window, this is equivalent to getting the root node (``get_tree().get_root()``). + +.. rst-class:: classref-item-separator + +---- + .. _class_Node_method_has_node: .. rst-class:: classref-method @@ -2030,6 +2046,20 @@ Removes a node from the ``group``. Does nothing if the node is not in the ``grou ---- +.. _class_Node_method_reparent: + +.. rst-class:: classref-method + +void **reparent** **(** :ref:`Node` new_parent, :ref:`bool` keep_global_transform=true **)** + +Changes the parent of this **Node** to the ``new_parent``. The node needs to already have a parent. + +If ``keep_global_transform`` is ``true``, the node's global transform will be preserved if supported. :ref:`Node2D`, :ref:`Node3D` and :ref:`Control` support this argument (but :ref:`Control` keeps only position). + +.. rst-class:: classref-item-separator + +---- + .. _class_Node_method_replace_by: .. rst-class:: classref-method diff --git a/classes/class_optionbutton.rst b/classes/class_optionbutton.rst index 1ce194ae4..98804436a 100644 --- a/classes/class_optionbutton.rst +++ b/classes/class_optionbutton.rst @@ -400,9 +400,9 @@ Returns the :ref:`PopupMenu` contained in this button. :ref:`int` **get_selectable_item** **(** :ref:`bool` from_last=false **)** |const| -.. container:: contribute +Returns the index of the first item which is not disabled, or marked as a separator. If ``from_last`` is ``true``, the items will be searched in reverse order. - There is currently no description for this method. Please help us by :ref:`contributing one `! +Returns ``-1`` if no item is found. .. rst-class:: classref-item-separator @@ -438,9 +438,7 @@ Gets the metadata of the selected item. Metadata for items can be set using :ref :ref:`bool` **has_selectable_items** **(** **)** |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Returns ``true`` if this button contains at least one item which is not disabled, or marked as a separator. .. rst-class:: classref-item-separator @@ -464,9 +462,7 @@ Returns ``true`` if the item at index ``idx`` is disabled. :ref:`bool` **is_item_separator** **(** :ref:`int` idx **)** |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Returns ``true`` if the item at index ``idx`` is marked as a separator. .. rst-class:: classref-item-separator diff --git a/classes/class_os.rst b/classes/class_os.rst index a0a126771..abb1608ed 100644 --- a/classes/class_os.rst +++ b/classes/class_os.rst @@ -207,178 +207,6 @@ The OpenGL 3 rendering driver. It uses OpenGL 3.3 Core Profile on desktop platfo ---- -.. _enum_OS_Weekday: - -.. rst-class:: classref-enumeration - -enum **Weekday**: - -.. _class_OS_constant_DAY_SUNDAY: - -.. rst-class:: classref-enumeration-constant - -:ref:`Weekday` **DAY_SUNDAY** = ``0`` - -Sunday. - -.. _class_OS_constant_DAY_MONDAY: - -.. rst-class:: classref-enumeration-constant - -:ref:`Weekday` **DAY_MONDAY** = ``1`` - -Monday. - -.. _class_OS_constant_DAY_TUESDAY: - -.. rst-class:: classref-enumeration-constant - -:ref:`Weekday` **DAY_TUESDAY** = ``2`` - -Tuesday. - -.. _class_OS_constant_DAY_WEDNESDAY: - -.. rst-class:: classref-enumeration-constant - -:ref:`Weekday` **DAY_WEDNESDAY** = ``3`` - -Wednesday. - -.. _class_OS_constant_DAY_THURSDAY: - -.. rst-class:: classref-enumeration-constant - -:ref:`Weekday` **DAY_THURSDAY** = ``4`` - -Thursday. - -.. _class_OS_constant_DAY_FRIDAY: - -.. rst-class:: classref-enumeration-constant - -:ref:`Weekday` **DAY_FRIDAY** = ``5`` - -Friday. - -.. _class_OS_constant_DAY_SATURDAY: - -.. rst-class:: classref-enumeration-constant - -:ref:`Weekday` **DAY_SATURDAY** = ``6`` - -Saturday. - -.. rst-class:: classref-item-separator - ----- - -.. _enum_OS_Month: - -.. rst-class:: classref-enumeration - -enum **Month**: - -.. _class_OS_constant_MONTH_JANUARY: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_JANUARY** = ``1`` - -January. - -.. _class_OS_constant_MONTH_FEBRUARY: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_FEBRUARY** = ``2`` - -February. - -.. _class_OS_constant_MONTH_MARCH: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_MARCH** = ``3`` - -March. - -.. _class_OS_constant_MONTH_APRIL: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_APRIL** = ``4`` - -April. - -.. _class_OS_constant_MONTH_MAY: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_MAY** = ``5`` - -May. - -.. _class_OS_constant_MONTH_JUNE: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_JUNE** = ``6`` - -June. - -.. _class_OS_constant_MONTH_JULY: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_JULY** = ``7`` - -July. - -.. _class_OS_constant_MONTH_AUGUST: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_AUGUST** = ``8`` - -August. - -.. _class_OS_constant_MONTH_SEPTEMBER: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_SEPTEMBER** = ``9`` - -September. - -.. _class_OS_constant_MONTH_OCTOBER: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_OCTOBER** = ``10`` - -October. - -.. _class_OS_constant_MONTH_NOVEMBER: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_NOVEMBER** = ``11`` - -November. - -.. _class_OS_constant_MONTH_DECEMBER: - -.. rst-class:: classref-enumeration-constant - -:ref:`Month` **MONTH_DECEMBER** = ``12`` - -December. - -.. rst-class:: classref-item-separator - ----- - .. _enum_OS_SystemDir: .. rst-class:: classref-enumeration diff --git a/classes/class_physicsdirectbodystate2d.rst b/classes/class_physicsdirectbodystate2d.rst index bebb6f615..5836d976e 100644 --- a/classes/class_physicsdirectbodystate2d.rst +++ b/classes/class_physicsdirectbodystate2d.rst @@ -111,6 +111,8 @@ Methods +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`get_contact_count` **(** **)** |const| | +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Vector2` | :ref:`get_contact_impulse` **(** :ref:`int` contact_idx **)** |const| | + +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`get_contact_local_normal` **(** :ref:`int` contact_idx **)** |const| | +-------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`get_contact_local_position` **(** :ref:`int` contact_idx **)** |const| | @@ -582,6 +584,18 @@ Returns the number of contacts this body has with other bodies. ---- +.. _class_PhysicsDirectBodyState2D_method_get_contact_impulse: + +.. rst-class:: classref-method + +:ref:`Vector2` **get_contact_impulse** **(** :ref:`int` contact_idx **)** |const| + +Returns the impulse created by the contact. + +.. rst-class:: classref-item-separator + +---- + .. _class_PhysicsDirectBodyState2D_method_get_contact_local_normal: .. rst-class:: classref-method diff --git a/classes/class_physicsdirectbodystate2dextension.rst b/classes/class_physicsdirectbodystate2dextension.rst index 3a91f037b..0c041a6a7 100644 --- a/classes/class_physicsdirectbodystate2dextension.rst +++ b/classes/class_physicsdirectbodystate2dextension.rst @@ -67,6 +67,8 @@ Methods +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`_get_contact_count` **(** **)** |virtual| |const| | +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Vector2` | :ref:`_get_contact_impulse` **(** :ref:`int` contact_idx **)** |virtual| |const| | + +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`_get_contact_local_normal` **(** :ref:`int` contact_idx **)** |virtual| |const| | +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector2` | :ref:`_get_contact_local_position` **(** :ref:`int` contact_idx **)** |virtual| |const| | @@ -413,6 +415,20 @@ void **_apply_torque_impulse** **(** :ref:`float` impulse **)** |vi ---- +.. _class_PhysicsDirectBodyState2DExtension_method__get_contact_impulse: + +.. rst-class:: classref-method + +:ref:`Vector2` **_get_contact_impulse** **(** :ref:`int` contact_idx **)** |virtual| |const| + +.. container:: contribute + + There is currently no description for this method. Please help us by :ref:`contributing one `! + +.. rst-class:: classref-item-separator + +---- + .. _class_PhysicsDirectBodyState2DExtension_method__get_contact_local_normal: .. rst-class:: classref-method diff --git a/classes/class_physicsdirectbodystate3d.rst b/classes/class_physicsdirectbodystate3d.rst index 0c4483db2..f35d93944 100644 --- a/classes/class_physicsdirectbodystate3d.rst +++ b/classes/class_physicsdirectbodystate3d.rst @@ -115,7 +115,7 @@ Methods +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`get_contact_count` **(** **)** |const| | +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`get_contact_impulse` **(** :ref:`int` contact_idx **)** |const| | + | :ref:`Vector3` | :ref:`get_contact_impulse` **(** :ref:`int` contact_idx **)** |const| | +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`get_contact_local_normal` **(** :ref:`int` contact_idx **)** |const| | +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -626,9 +626,9 @@ Returns the number of contacts this body has with other bodies. .. rst-class:: classref-method -:ref:`float` **get_contact_impulse** **(** :ref:`int` contact_idx **)** |const| +:ref:`Vector3` **get_contact_impulse** **(** :ref:`int` contact_idx **)** |const| -Impulse created by the contact. Only implemented for Bullet physics. +Impulse created by the contact. .. rst-class:: classref-item-separator diff --git a/classes/class_physicsdirectbodystate3dextension.rst b/classes/class_physicsdirectbodystate3dextension.rst index 1f6356c72..203a98af6 100644 --- a/classes/class_physicsdirectbodystate3dextension.rst +++ b/classes/class_physicsdirectbodystate3dextension.rst @@ -67,7 +67,7 @@ Methods +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`_get_contact_count` **(** **)** |virtual| |const| | +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`_get_contact_impulse` **(** :ref:`int` contact_idx **)** |virtual| |const| | + | :ref:`Vector3` | :ref:`_get_contact_impulse` **(** :ref:`int` contact_idx **)** |virtual| |const| | +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`_get_contact_local_normal` **(** :ref:`int` contact_idx **)** |virtual| |const| | +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -423,7 +423,7 @@ void **_apply_torque_impulse** **(** :ref:`Vector3` impulse **)** .. rst-class:: classref-method -:ref:`float` **_get_contact_impulse** **(** :ref:`int` contact_idx **)** |virtual| |const| +:ref:`Vector3` **_get_contact_impulse** **(** :ref:`int` contact_idx **)** |virtual| |const| .. container:: contribute diff --git a/classes/class_physicsdirectspacestate2dextension.rst b/classes/class_physicsdirectspacestate2dextension.rst index 23ea21bd3..5c9cdbce8 100644 --- a/classes/class_physicsdirectspacestate2dextension.rst +++ b/classes/class_physicsdirectspacestate2dextension.rst @@ -37,6 +37,8 @@ Methods +-------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`_rest_info` **(** :ref:`RID` shape_rid, :ref:`Transform2D` transform, :ref:`Vector2` motion, :ref:`float` margin, :ref:`int` collision_mask, :ref:`bool` collide_with_bodies, :ref:`bool` collide_with_areas, PhysicsServer2DExtensionShapeRestInfo* rest_info **)** |virtual| | +-------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_body_excluded_from_query` **(** :ref:`RID` body **)** |const| | + +-------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -123,6 +125,20 @@ Method Descriptions :ref:`bool` **_rest_info** **(** :ref:`RID` shape_rid, :ref:`Transform2D` transform, :ref:`Vector2` motion, :ref:`float` margin, :ref:`int` collision_mask, :ref:`bool` collide_with_bodies, :ref:`bool` collide_with_areas, PhysicsServer2DExtensionShapeRestInfo* rest_info **)** |virtual| +.. container:: contribute + + There is currently no description for this method. Please help us by :ref:`contributing one `! + +.. rst-class:: classref-item-separator + +---- + +.. _class_PhysicsDirectSpaceState2DExtension_method_is_body_excluded_from_query: + +.. rst-class:: classref-method + +:ref:`bool` **is_body_excluded_from_query** **(** :ref:`RID` body **)** |const| + .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! diff --git a/classes/class_physicsdirectspacestate3dextension.rst b/classes/class_physicsdirectspacestate3dextension.rst index 2214889d4..6c2c4cab6 100644 --- a/classes/class_physicsdirectspacestate3dextension.rst +++ b/classes/class_physicsdirectspacestate3dextension.rst @@ -39,6 +39,8 @@ Methods +-------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`_rest_info` **(** :ref:`RID` shape_rid, :ref:`Transform3D` transform, :ref:`Vector3` motion, :ref:`float` margin, :ref:`int` collision_mask, :ref:`bool` collide_with_bodies, :ref:`bool` collide_with_areas, PhysicsServer3DExtensionShapeRestInfo* rest_info **)** |virtual| | +-------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`is_body_excluded_from_query` **(** :ref:`RID` body **)** |const| | + +-------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -139,6 +141,20 @@ Method Descriptions :ref:`bool` **_rest_info** **(** :ref:`RID` shape_rid, :ref:`Transform3D` transform, :ref:`Vector3` motion, :ref:`float` margin, :ref:`int` collision_mask, :ref:`bool` collide_with_bodies, :ref:`bool` collide_with_areas, PhysicsServer3DExtensionShapeRestInfo* rest_info **)** |virtual| +.. container:: contribute + + There is currently no description for this method. Please help us by :ref:`contributing one `! + +.. rst-class:: classref-item-separator + +---- + +.. _class_PhysicsDirectSpaceState3DExtension_method_is_body_excluded_from_query: + +.. rst-class:: classref-method + +:ref:`bool` **is_body_excluded_from_query** **(** :ref:`RID` body **)** |const| + .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! diff --git a/classes/class_physicsserver2d.rst b/classes/class_physicsserver2d.rst index d6b3ec279..b4de8eb6d 100644 --- a/classes/class_physicsserver2d.rst +++ b/classes/class_physicsserver2d.rst @@ -232,6 +232,10 @@ Methods +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`joint_set_param` **(** :ref:`RID` joint, :ref:`JointParam` param, :ref:`float` value **)** | +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`pin_joint_get_param` **(** :ref:`RID` joint, :ref:`PinJointParam` param **)** |const| | + +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`pin_joint_set_param` **(** :ref:`RID` joint, :ref:`PinJointParam` param, :ref:`float` value **)** | + +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`RID` | :ref:`rectangle_shape_create` **(** **)** | +-------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`RID` | :ref:`segment_shape_create` **(** **)** | @@ -2301,6 +2305,30 @@ Sets a joint parameter. See :ref:`JointParam` f ---- +.. _class_PhysicsServer2D_method_pin_joint_get_param: + +.. rst-class:: classref-method + +:ref:`float` **pin_joint_get_param** **(** :ref:`RID` joint, :ref:`PinJointParam` param **)** |const| + +Returns the value of a pin joint parameter. See :ref:`PinJointParam` for a list of available parameters. + +.. rst-class:: classref-item-separator + +---- + +.. _class_PhysicsServer2D_method_pin_joint_set_param: + +.. rst-class:: classref-method + +void **pin_joint_set_param** **(** :ref:`RID` joint, :ref:`PinJointParam` param, :ref:`float` value **)** + +Sets a pin joint parameter. See :ref:`PinJointParam` for a list of available parameters. + +.. rst-class:: classref-item-separator + +---- + .. _class_PhysicsServer2D_method_rectangle_shape_create: .. rst-class:: classref-method diff --git a/classes/class_physicsserver2dextension.rst b/classes/class_physicsserver2dextension.rst index 796d0f38a..2aecdc86b 100644 --- a/classes/class_physicsserver2dextension.rst +++ b/classes/class_physicsserver2dextension.rst @@ -297,6 +297,10 @@ Methods +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`RID` | :ref:`_world_boundary_shape_create` **(** **)** |virtual| | +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`body_test_motion_is_excluding_body` **(** :ref:`RID` body **)** |const| | + +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`body_test_motion_is_excluding_object` **(** :ref:`int` object **)** |const| | + +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -2203,6 +2207,34 @@ void **_sync** **(** **)** |virtual| :ref:`RID` **_world_boundary_shape_create** **(** **)** |virtual| +.. container:: contribute + + There is currently no description for this method. Please help us by :ref:`contributing one `! + +.. rst-class:: classref-item-separator + +---- + +.. _class_PhysicsServer2DExtension_method_body_test_motion_is_excluding_body: + +.. rst-class:: classref-method + +:ref:`bool` **body_test_motion_is_excluding_body** **(** :ref:`RID` body **)** |const| + +.. container:: contribute + + There is currently no description for this method. Please help us by :ref:`contributing one `! + +.. rst-class:: classref-item-separator + +---- + +.. _class_PhysicsServer2DExtension_method_body_test_motion_is_excluding_object: + +.. rst-class:: classref-method + +:ref:`bool` **body_test_motion_is_excluding_object** **(** :ref:`int` object **)** |const| + .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! diff --git a/classes/class_physicsserver3dextension.rst b/classes/class_physicsserver3dextension.rst index 21709c3e2..a27eba368 100644 --- a/classes/class_physicsserver3dextension.rst +++ b/classes/class_physicsserver3dextension.rst @@ -401,6 +401,10 @@ Methods +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`RID` | :ref:`_world_boundary_shape_create` **(** **)** |virtual| | +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`body_test_motion_is_excluding_body` **(** :ref:`RID` body **)** |const| | + +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`body_test_motion_is_excluding_object` **(** :ref:`int` object **)** |const| | + +-------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -3035,6 +3039,34 @@ void **_sync** **(** **)** |virtual| :ref:`RID` **_world_boundary_shape_create** **(** **)** |virtual| +.. container:: contribute + + There is currently no description for this method. Please help us by :ref:`contributing one `! + +.. rst-class:: classref-item-separator + +---- + +.. _class_PhysicsServer3DExtension_method_body_test_motion_is_excluding_body: + +.. rst-class:: classref-method + +:ref:`bool` **body_test_motion_is_excluding_body** **(** :ref:`RID` body **)** |const| + +.. container:: contribute + + There is currently no description for this method. Please help us by :ref:`contributing one `! + +.. rst-class:: classref-item-separator + +---- + +.. _class_PhysicsServer3DExtension_method_body_test_motion_is_excluding_object: + +.. rst-class:: classref-method + +:ref:`bool` **body_test_motion_is_excluding_object** **(** :ref:`int` object **)** |const| + .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! diff --git a/classes/class_projectsettings.rst b/classes/class_projectsettings.rst index 360941d17..30b73d52c 100644 --- a/classes/class_projectsettings.rst +++ b/classes/class_projectsettings.rst @@ -211,8 +211,6 @@ Properties +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`debug/gdscript/warnings/unused_variable` | ``1`` | +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`debug/gdscript/warnings/void_assignment` | ``1`` | - +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`String` | :ref:`debug/settings/crash_handler/message` | ``"Please include this when reporting the bug to the project developer."`` | +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`String` | :ref:`debug/settings/crash_handler/message.editor` | ``"Please include this when reporting the bug on: https://github.com/godotengine/godot/issues"`` | @@ -297,6 +295,8 @@ Properties +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`display/window/size/extend_to_title` | ``false`` | +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`display/window/size/initial_screen` | ``-2`` | + +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`display/window/size/mode` | ``0`` | +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`display/window/size/no_focus` | ``false`` | @@ -2407,18 +2407,6 @@ When set to ``warn`` or ``error``, produces a warning or an error respectively w ---- -.. _class_ProjectSettings_property_debug/gdscript/warnings/void_assignment: - -.. rst-class:: classref-property - -:ref:`int` **debug/gdscript/warnings/void_assignment** = ``1`` - -When set to ``warn`` or ``error``, produces a warning or an error respectively when assigning the result of a function that returns ``void`` to a variable. - -.. rst-class:: classref-item-separator - ----- - .. _class_ProjectSettings_property_debug/settings/crash_handler/message: .. rst-class:: classref-property @@ -2935,6 +2923,18 @@ Main window content is expanded to the full size of the window. Unlike a borderl ---- +.. _class_ProjectSettings_property_display/window/size/initial_screen: + +.. rst-class:: classref-property + +:ref:`int` **display/window/size/initial_screen** = ``-2`` + +Main window initial screen. + +.. rst-class:: classref-item-separator + +---- + .. _class_ProjectSettings_property_display/window/size/mode: .. rst-class:: classref-property diff --git a/classes/class_range.rst b/classes/class_range.rst index fa189bda1..268e3c04f 100644 --- a/classes/class_range.rst +++ b/classes/class_range.rst @@ -31,29 +31,29 @@ Properties .. table:: :widths: auto - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`allow_greater` | ``false`` | - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`allow_lesser` | ``false`` | - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`exp_edit` | ``false`` | - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`max_value` | ``100.0`` | - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`min_value` | ``0.0`` | - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`page` | ``0.0`` | - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`ratio` | | - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`rounded` | ``false`` | - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`int` | size_flags_vertical | ``0`` (overrides :ref:`Control`) | - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`step` | ``0.01`` | - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`value` | ``0.0`` | - +---------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`allow_greater` | ``false`` | + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`allow_lesser` | ``false`` | + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`exp_edit` | ``false`` | + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`max_value` | ``100.0`` | + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`min_value` | ``0.0`` | + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`page` | ``0.0`` | + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`ratio` | | + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`rounded` | ``false`` | + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + | :ref:`SizeFlags` | size_flags_vertical | ``0`` (overrides :ref:`Control`) | + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`step` | ``0.01`` | + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`value` | ``0.0`` | + +------------------------------------------+----------------------------------------------------------+------------------------------------------------------------------------------+ .. rst-class:: classref-reftable-group diff --git a/classes/class_renderingserver.rst b/classes/class_renderingserver.rst index d7ba88f30..25b3fb436 100644 --- a/classes/class_renderingserver.rst +++ b/classes/class_renderingserver.rst @@ -533,7 +533,7 @@ Methods +----------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`mesh_add_surface` **(** :ref:`RID` mesh, :ref:`Dictionary` surface **)** | +----------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`mesh_add_surface_from_arrays` **(** :ref:`RID` mesh, :ref:`PrimitiveType` primitive, :ref:`Array` arrays, :ref:`Array` blend_shapes=[], :ref:`Dictionary` lods={}, :ref:`int` compress_format=0 **)** | + | void | :ref:`mesh_add_surface_from_arrays` **(** :ref:`RID` mesh, :ref:`PrimitiveType` primitive, :ref:`Array` arrays, :ref:`Array` blend_shapes=[], :ref:`Dictionary` lods={}, :ref:`ArrayFormat` compress_format=0 **)** | +----------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`mesh_clear` **(** :ref:`RID` mesh **)** | +----------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -561,13 +561,13 @@ Methods +----------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Array[]` | :ref:`mesh_surface_get_blend_shape_arrays` **(** :ref:`RID` mesh, :ref:`int` surface **)** |const| | +----------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`mesh_surface_get_format_attribute_stride` **(** :ref:`int` format, :ref:`int` vertex_count **)** |const| | + | :ref:`int` | :ref:`mesh_surface_get_format_attribute_stride` **(** :ref:`ArrayFormat` format, :ref:`int` vertex_count **)** |const| | +----------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`mesh_surface_get_format_offset` **(** :ref:`int` format, :ref:`int` vertex_count, :ref:`int` array_index **)** |const| | + | :ref:`int` | :ref:`mesh_surface_get_format_offset` **(** :ref:`ArrayFormat` format, :ref:`int` vertex_count, :ref:`int` array_index **)** |const| | +----------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`mesh_surface_get_format_skin_stride` **(** :ref:`int` format, :ref:`int` vertex_count **)** |const| | + | :ref:`int` | :ref:`mesh_surface_get_format_skin_stride` **(** :ref:`ArrayFormat` format, :ref:`int` vertex_count **)** |const| | +----------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`mesh_surface_get_format_vertex_stride` **(** :ref:`int` format, :ref:`int` vertex_count **)** |const| | + | :ref:`int` | :ref:`mesh_surface_get_format_vertex_stride` **(** :ref:`ArrayFormat` format, :ref:`int` vertex_count **)** |const| | +----------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`RID` | :ref:`mesh_surface_get_material` **(** :ref:`RID` mesh, :ref:`int` surface **)** |const| | +----------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -1372,7 +1372,7 @@ enum **ArrayCustomFormat**: .. rst-class:: classref-enumeration -enum **ArrayFormat**: +flags **ArrayFormat**: .. _class_RenderingServer_constant_ARRAY_FORMAT_VERTEX: @@ -8306,7 +8306,7 @@ void **mesh_add_surface** **(** :ref:`RID` mesh, :ref:`Dictionary` mesh, :ref:`PrimitiveType` primitive, :ref:`Array` arrays, :ref:`Array` blend_shapes=[], :ref:`Dictionary` lods={}, :ref:`int` compress_format=0 **)** +void **mesh_add_surface_from_arrays** **(** :ref:`RID` mesh, :ref:`PrimitiveType` primitive, :ref:`Array` arrays, :ref:`Array` blend_shapes=[], :ref:`Dictionary` lods={}, :ref:`ArrayFormat` compress_format=0 **)** .. container:: contribute @@ -8486,7 +8486,7 @@ Returns a mesh's surface's arrays for blend shapes. .. rst-class:: classref-method -:ref:`int` **mesh_surface_get_format_attribute_stride** **(** :ref:`int` format, :ref:`int` vertex_count **)** |const| +:ref:`int` **mesh_surface_get_format_attribute_stride** **(** :ref:`ArrayFormat` format, :ref:`int` vertex_count **)** |const| .. container:: contribute @@ -8500,7 +8500,7 @@ Returns a mesh's surface's arrays for blend shapes. .. rst-class:: classref-method -:ref:`int` **mesh_surface_get_format_offset** **(** :ref:`int` format, :ref:`int` vertex_count, :ref:`int` array_index **)** |const| +:ref:`int` **mesh_surface_get_format_offset** **(** :ref:`ArrayFormat` format, :ref:`int` vertex_count, :ref:`int` array_index **)** |const| .. container:: contribute @@ -8514,7 +8514,7 @@ Returns a mesh's surface's arrays for blend shapes. .. rst-class:: classref-method -:ref:`int` **mesh_surface_get_format_skin_stride** **(** :ref:`int` format, :ref:`int` vertex_count **)** |const| +:ref:`int` **mesh_surface_get_format_skin_stride** **(** :ref:`ArrayFormat` format, :ref:`int` vertex_count **)** |const| .. container:: contribute @@ -8528,7 +8528,7 @@ Returns a mesh's surface's arrays for blend shapes. .. rst-class:: classref-method -:ref:`int` **mesh_surface_get_format_vertex_stride** **(** :ref:`int` format, :ref:`int` vertex_count **)** |const| +:ref:`int` **mesh_surface_get_format_vertex_stride** **(** :ref:`ArrayFormat` format, :ref:`int` vertex_count **)** |const| .. container:: contribute diff --git a/classes/class_resourceformatsaver.rst b/classes/class_resourceformatsaver.rst index 753e1bd1d..a1959ffdd 100644 --- a/classes/class_resourceformatsaver.rst +++ b/classes/class_resourceformatsaver.rst @@ -40,6 +40,8 @@ Methods +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`_save` **(** :ref:`Resource` resource, :ref:`String` path, :ref:`int` flags **)** |virtual| | +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Error` | :ref:`_set_uid` **(** :ref:`String` path, :ref:`int` uid **)** |virtual| | + +---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -98,6 +100,18 @@ Saves the given resource object to a file at the target ``path``. ``flags`` is a Returns :ref:`@GlobalScope.OK` on success, or an :ref:`Error` constant in case of failure. +.. rst-class:: classref-item-separator + +---- + +.. _class_ResourceFormatSaver_method__set_uid: + +.. rst-class:: classref-method + +:ref:`Error` **_set_uid** **(** :ref:`String` path, :ref:`int` uid **)** |virtual| + +Sets a new UID for the resource at the given ``path``. Returns :ref:`@GlobalScope.OK` on success, or an :ref:`Error` constant in case of failure. + .. |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_scenemultiplayer.rst b/classes/class_scenemultiplayer.rst index a95198f76..aee346bb0 100644 --- a/classes/class_scenemultiplayer.rst +++ b/classes/class_scenemultiplayer.rst @@ -225,6 +225,8 @@ This effectively allows to have different branches of the scene tree to be manag Enable or disable the server feature that notifies clients of other peers' connection/disconnection, and relays messages between them. When this option is ``false``, clients won't be automatically notified of other peers and won't be able to send them packets through the server. +\ **Note:** Changing this option while other peers are connected may lead to unexpected behaviors. + \ **Note:** Support for this feature may depend on the current :ref:`MultiplayerPeer` configuration. See :ref:`MultiplayerPeer.is_server_relay_supported`. .. rst-class:: classref-section-separator diff --git a/classes/class_scenetree.rst b/classes/class_scenetree.rst index 92529c5d3..14f2ff25d 100644 --- a/classes/class_scenetree.rst +++ b/classes/class_scenetree.rst @@ -115,6 +115,8 @@ Methods +---------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_multiplayer` **(** :ref:`MultiplayerAPI` multiplayer, :ref:`NodePath` root_path=NodePath("") **)** | +---------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`unload_current_scene` **(** **)** | + +---------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -508,7 +510,7 @@ Changes the running scene to the one at the given ``path``, after loading it int Returns :ref:`@GlobalScope.OK` on success, :ref:`@GlobalScope.ERR_CANT_OPEN` if the ``path`` cannot be loaded into a :ref:`PackedScene`, or :ref:`@GlobalScope.ERR_CANT_CREATE` if that scene cannot be instantiated. -\ **Note:** The scene change is deferred, which means that the new scene node is added on the next idle frame. You won't be able to access it immediately after the :ref:`change_scene_to_file` call. +\ **Note:** The scene change is deferred, which means that the new scene node is added on the next idle frame. This ensures that both scenes are never loaded at the same time, which can exhaust system resources if the scenes are too large or if running in a memory constrained environment. As such, you won't be able to access the loaded scene immediately after the :ref:`change_scene_to_file` call. .. rst-class:: classref-item-separator @@ -520,9 +522,9 @@ Returns :ref:`@GlobalScope.OK` on success, :ref: :ref:`Error` **change_scene_to_packed** **(** :ref:`PackedScene` packed_scene **)** -Changes the running scene to a new instance of the given :ref:`PackedScene`. +Changes the running scene to a new instance of the given :ref:`PackedScene` (which must be valid). -Returns :ref:`@GlobalScope.OK` on success or :ref:`@GlobalScope.ERR_CANT_CREATE` if the scene cannot be instantiated. +Returns :ref:`@GlobalScope.OK` on success, :ref:`@GlobalScope.ERR_CANT_CREATE` if the scene cannot be instantiated, or :ref:`@GlobalScope.ERR_INVALID_PARAMETER` if the scene is invalid. \ **Note:** The scene change is deferred, which means that the new scene node is added on the next idle frame. You won't be able to access it immediately after the :ref:`change_scene_to_packed` call. @@ -777,6 +779,18 @@ void **set_multiplayer** **(** :ref:`MultiplayerAPI` multi Sets a custom :ref:`MultiplayerAPI` with the given ``root_path`` (controlling also the relative subpaths), or override the default one if ``root_path`` is empty. +.. rst-class:: classref-item-separator + +---- + +.. _class_SceneTree_method_unload_current_scene: + +.. rst-class:: classref-method + +void **unload_current_scene** **(** **)** + +If a current scene is loaded, calling this method will unload it. + .. |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_spinbox.rst b/classes/class_spinbox.rst index af1e07313..ef3458bbb 100644 --- a/classes/class_spinbox.rst +++ b/classes/class_spinbox.rst @@ -71,7 +71,7 @@ Properties +-------------------------------------------------------------------+------------------------------------------------------------------------------+------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`select_all_on_focus` | ``false`` | +-------------------------------------------------------------------+------------------------------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`int` | size_flags_vertical | ``1`` (overrides :ref:`Control`) | + | :ref:`SizeFlags` | size_flags_vertical | ``1`` (overrides :ref:`Control`) | +-------------------------------------------------------------------+------------------------------------------------------------------------------+------------------------------------------------------------------------------+ | :ref:`float` | step | ``1.0`` (overrides :ref:`Range`) | +-------------------------------------------------------------------+------------------------------------------------------------------------------+------------------------------------------------------------------------------+ diff --git a/classes/class_spriteframes.rst b/classes/class_spriteframes.rst index 24a0f4c79..5ff49e3b6 100644 --- a/classes/class_spriteframes.rst +++ b/classes/class_spriteframes.rst @@ -31,39 +31,41 @@ Methods .. table:: :widths: auto - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`add_animation` **(** :ref:`StringName` anim **)** | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`add_frame` **(** :ref:`StringName` anim, :ref:`Texture2D` frame, :ref:`int` at_position=-1 **)** | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`clear` **(** :ref:`StringName` anim **)** | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`clear_all` **(** **)** | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`get_animation_loop` **(** :ref:`StringName` anim **)** |const| | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`PackedStringArray` | :ref:`get_animation_names` **(** **)** |const| | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`float` | :ref:`get_animation_speed` **(** :ref:`StringName` anim **)** |const| | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`Texture2D` | :ref:`get_frame` **(** :ref:`StringName` anim, :ref:`int` idx **)** |const| | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`int` | :ref:`get_frame_count` **(** :ref:`StringName` anim **)** |const| | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | :ref:`bool` | :ref:`has_animation` **(** :ref:`StringName` anim **)** |const| | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`remove_animation` **(** :ref:`StringName` anim **)** | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`remove_frame` **(** :ref:`StringName` anim, :ref:`int` idx **)** | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`rename_animation` **(** :ref:`StringName` anim, :ref:`StringName` newname **)** | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_animation_loop` **(** :ref:`StringName` anim, :ref:`bool` loop **)** | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_animation_speed` **(** :ref:`StringName` anim, :ref:`float` speed **)** | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_frame` **(** :ref:`StringName` anim, :ref:`int` idx, :ref:`Texture2D` txt **)** | - +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`add_animation` **(** :ref:`StringName` anim **)** | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`add_frame` **(** :ref:`StringName` anim, :ref:`Texture2D` texture, :ref:`float` duration=1.0, :ref:`int` at_position=-1 **)** | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`clear` **(** :ref:`StringName` anim **)** | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`clear_all` **(** **)** | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`get_animation_loop` **(** :ref:`StringName` anim **)** |const| | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`PackedStringArray` | :ref:`get_animation_names` **(** **)** |const| | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`get_animation_speed` **(** :ref:`StringName` anim **)** |const| | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`int` | :ref:`get_frame_count` **(** :ref:`StringName` anim **)** |const| | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`float` | :ref:`get_frame_duration` **(** :ref:`StringName` anim, :ref:`int` idx **)** |const| | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`Texture2D` | :ref:`get_frame_texture` **(** :ref:`StringName` anim, :ref:`int` idx **)** |const| | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | :ref:`bool` | :ref:`has_animation` **(** :ref:`StringName` anim **)** |const| | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`remove_animation` **(** :ref:`StringName` anim **)** | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`remove_frame` **(** :ref:`StringName` anim, :ref:`int` idx **)** | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`rename_animation` **(** :ref:`StringName` anim, :ref:`StringName` newname **)** | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`set_animation_loop` **(** :ref:`StringName` anim, :ref:`bool` loop **)** | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`set_animation_speed` **(** :ref:`StringName` anim, :ref:`float` fps **)** | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`set_frame` **(** :ref:`StringName` anim, :ref:`int` idx, :ref:`Texture2D` texture, :ref:`float` duration=1.0 **)** | + +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator @@ -90,7 +92,7 @@ Adds a new animation to the library. .. rst-class:: classref-method -void **add_frame** **(** :ref:`StringName` anim, :ref:`Texture2D` frame, :ref:`int` at_position=-1 **)** +void **add_frame** **(** :ref:`StringName` anim, :ref:`Texture2D` texture, :ref:`float` duration=1.0, :ref:`int` at_position=-1 **)** Adds a frame to the given animation. @@ -152,19 +154,7 @@ Returns an array containing the names associated to each animation. Values are p :ref:`float` **get_animation_speed** **(** :ref:`StringName` anim **)** |const| -The animation's speed in frames per second. - -.. rst-class:: classref-item-separator - ----- - -.. _class_SpriteFrames_method_get_frame: - -.. rst-class:: classref-method - -:ref:`Texture2D` **get_frame** **(** :ref:`StringName` anim, :ref:`int` idx **)** |const| - -Returns the animation's selected frame. +Returns the speed in frames per second for the ``anim`` animation. .. rst-class:: classref-item-separator @@ -176,7 +166,37 @@ Returns the animation's selected frame. :ref:`int` **get_frame_count** **(** :ref:`StringName` anim **)** |const| -Returns the number of frames in the animation. +Returns the number of frames for the ``anim`` animation. + +.. rst-class:: classref-item-separator + +---- + +.. _class_SpriteFrames_method_get_frame_duration: + +.. rst-class:: classref-method + +:ref:`float` **get_frame_duration** **(** :ref:`StringName` anim, :ref:`int` idx **)** |const| + +Returns a relative duration of the frame ``idx`` in the ``anim`` animation (defaults to ``1.0``). For example, a frame with a duration of ``2.0`` is displayed twice as long as a frame with a duration of ``1.0``. You can calculate the absolute duration (in seconds) of a frame using the following formula: + +:: + + absolute_duration = relative_duration / (animation_fps * abs(speed_scale)) + +In this example, ``speed_scale`` refers to either :ref:`AnimatedSprite2D.speed_scale` or :ref:`AnimatedSprite3D.speed_scale`. + +.. rst-class:: classref-item-separator + +---- + +.. _class_SpriteFrames_method_get_frame_texture: + +.. rst-class:: classref-method + +:ref:`Texture2D` **get_frame_texture** **(** :ref:`StringName` anim, :ref:`int` idx **)** |const| + +Returns the texture of the frame ``idx`` in the ``anim`` animation. .. rst-class:: classref-item-separator @@ -246,9 +266,9 @@ If ``true``, the animation will loop. .. rst-class:: classref-method -void **set_animation_speed** **(** :ref:`StringName` anim, :ref:`float` speed **)** +void **set_animation_speed** **(** :ref:`StringName` anim, :ref:`float` fps **)** -The animation's speed in frames per second. +Sets the speed for the ``anim`` animation in frames per second. .. rst-class:: classref-item-separator @@ -258,9 +278,9 @@ The animation's speed in frames per second. .. rst-class:: classref-method -void **set_frame** **(** :ref:`StringName` anim, :ref:`int` idx, :ref:`Texture2D` txt **)** +void **set_frame** **(** :ref:`StringName` anim, :ref:`int` idx, :ref:`Texture2D` texture, :ref:`float` duration=1.0 **)** -Sets the texture of the given frame. +Sets the texture and the duration of the frame ``idx`` in the ``anim`` animation. .. |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_tabbar.rst b/classes/class_tabbar.rst index 2d5c5b09c..b60d0d07b 100644 --- a/classes/class_tabbar.rst +++ b/classes/class_tabbar.rst @@ -64,6 +64,8 @@ Methods +--------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`add_tab` **(** :ref:`String` title="", :ref:`Texture2D` icon=null **)** | +--------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`clear_tabs` **(** **)** | + +--------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`ensure_tab_visible` **(** :ref:`int` idx **)** | +--------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`get_offset_buttons_visible` **(** **)** |const| | @@ -579,6 +581,18 @@ Adds a new tab. ---- +.. _class_TabBar_method_clear_tabs: + +.. rst-class:: classref-method + +void **clear_tabs** **(** **)** + +Clears all tabs. + +.. rst-class:: classref-item-separator + +---- + .. _class_TabBar_method_ensure_tab_visible: .. rst-class:: classref-method diff --git a/classes/class_textureprogressbar.rst b/classes/class_textureprogressbar.rst index 5554d3f5d..eb43b243a 100644 --- a/classes/class_textureprogressbar.rst +++ b/classes/class_textureprogressbar.rst @@ -42,7 +42,7 @@ Properties +----------------------------------------------+-------------------------------------------------------------------------------------------+------------------------------------------------------------------------------+ | :ref:`float` | :ref:`radial_initial_angle` | ``0.0`` | +----------------------------------------------+-------------------------------------------------------------------------------------------+------------------------------------------------------------------------------+ - | :ref:`int` | size_flags_vertical | ``1`` (overrides :ref:`Control`) | + | :ref:`SizeFlags` | size_flags_vertical | ``1`` (overrides :ref:`Control`) | +----------------------------------------------+-------------------------------------------------------------------------------------------+------------------------------------------------------------------------------+ | :ref:`float` | step | ``1.0`` (overrides :ref:`Range`) | +----------------------------------------------+-------------------------------------------------------------------------------------------+------------------------------------------------------------------------------+ diff --git a/classes/class_tilemap.rst b/classes/class_tilemap.rst index 9e441ddd9..469cc4c4b 100644 --- a/classes/class_tilemap.rst +++ b/classes/class_tilemap.rst @@ -785,7 +785,7 @@ void **set_layer_y_sort_enabled** **(** :ref:`int` layer, :ref:`bool< Enables or disables a layer's Y-sorting. If a layer is Y-sorted, the layer will behave as a CanvasItem node where each of its tile gets Y-sorted. -Y-sorted layers should usually be on different Z-index values than not Y-sorted layers, otherwise, each of those layer will be Y-sorted as whole with the Y-sorted one. This is usually an undesired behvaior. +Y-sorted layers should usually be on different Z-index values than not Y-sorted layers, otherwise, each of those layer will be Y-sorted as whole with the Y-sorted one. This is usually an undesired behavior. If ``layer`` is negative, the layers are accessed from the last one. diff --git a/classes/class_transform2d.rst b/classes/class_transform2d.rst index 6727b7781..7bcf08e59 100644 --- a/classes/class_transform2d.rst +++ b/classes/class_transform2d.rst @@ -113,12 +113,6 @@ Methods +---------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Transform2D` | :ref:`scaled_local` **(** :ref:`Vector2` scale **)** |const| | +---------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_rotation` **(** :ref:`float` rotation **)** | - +---------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_scale` **(** :ref:`Vector2` scale **)** | - +---------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | void | :ref:`set_skew` **(** :ref:`float` skew **)** | - +---------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Transform2D` | :ref:`translated` **(** :ref:`Vector2` offset **)** |const| | +---------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Transform2D` | :ref:`translated_local` **(** :ref:`Vector2` offset **)** |const| | @@ -526,44 +520,6 @@ This can be seen as transforming with respect to the local frame. ---- -.. _class_Transform2D_method_set_rotation: - -.. rst-class:: classref-method - -void **set_rotation** **(** :ref:`float` rotation **)** - -Sets the transform's rotation (in radians). - -.. rst-class:: classref-item-separator - ----- - -.. _class_Transform2D_method_set_scale: - -.. rst-class:: classref-method - -void **set_scale** **(** :ref:`Vector2` scale **)** - -Sets the transform's scale. - -\ **Note:** Negative X scales in 2D are not decomposable from the transformation matrix. Due to the way scale is represented with transformation matrices in Godot, negative scales on the X axis will be changed to negative scales on the Y axis and a rotation of 180 degrees when decomposed. - -.. rst-class:: classref-item-separator - ----- - -.. _class_Transform2D_method_set_skew: - -.. rst-class:: classref-method - -void **set_skew** **(** :ref:`float` skew **)** - -Sets the transform's skew (in radians). - -.. rst-class:: classref-item-separator - ----- - .. _class_Transform2D_method_translated: .. rst-class:: classref-method diff --git a/classes/class_tree.rst b/classes/class_tree.rst index 0bb06627e..85b6ee516 100644 --- a/classes/class_tree.rst +++ b/classes/class_tree.rst @@ -105,6 +105,8 @@ Methods +--------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`TreeItem` | :ref:`create_item` **(** :ref:`TreeItem` parent=null, :ref:`int` idx=-1 **)** | +--------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | void | :ref:`deselect_all` **(** **)** | + +--------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`edit_selected` **(** **)** | +--------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`ensure_cursor_is_visible` **(** **)** | @@ -787,6 +789,18 @@ The new item will be the ``idx``\ th child of parent, or it will be the last chi ---- +.. _class_Tree_method_deselect_all: + +.. rst-class:: classref-method + +void **deselect_all** **(** **)** + +Deselects all tree items (rows and columns). In :ref:`SELECT_MULTI` mode also removes selection cursor. + +.. rst-class:: classref-item-separator + +---- + .. _class_Tree_method_edit_selected: .. rst-class:: classref-method diff --git a/classes/class_visualshader.rst b/classes/class_visualshader.rst index 69452d672..ea9897af0 100644 --- a/classes/class_visualshader.rst +++ b/classes/class_visualshader.rst @@ -126,7 +126,7 @@ A shader for light calculations. :ref:`Type` **TYPE_START** = ``3`` - +A function for the "start" stage of particle shader. .. _class_VisualShader_constant_TYPE_PROCESS: @@ -134,7 +134,7 @@ A shader for light calculations. :ref:`Type` **TYPE_PROCESS** = ``4`` - +A function for the "process" stage of particle shader. .. _class_VisualShader_constant_TYPE_COLLIDE: @@ -142,7 +142,7 @@ A shader for light calculations. :ref:`Type` **TYPE_COLLIDE** = ``5`` - +A function for the "collide" stage (particle collision handler) of particle shader. .. _class_VisualShader_constant_TYPE_START_CUSTOM: @@ -150,7 +150,7 @@ A shader for light calculations. :ref:`Type` **TYPE_START_CUSTOM** = ``6`` - +A function for the "start" stage of particle shader, with customized output. .. _class_VisualShader_constant_TYPE_PROCESS_CUSTOM: @@ -158,7 +158,7 @@ A shader for light calculations. :ref:`Type` **TYPE_PROCESS_CUSTOM** = ``7`` - +A function for the "process" stage of particle shader, with customized output. .. _class_VisualShader_constant_TYPE_SKY: @@ -166,7 +166,7 @@ A shader for light calculations. :ref:`Type` **TYPE_SKY** = ``8`` - +A shader for 3D environment's sky. .. _class_VisualShader_constant_TYPE_FOG: @@ -200,7 +200,7 @@ enum **VaryingMode**: :ref:`VaryingMode` **VARYING_MODE_VERTEX_TO_FRAG_LIGHT** = ``0`` - +Varying is passed from ``Vertex`` function to ``Fragment`` and ``Light`` functions. .. _class_VisualShader_constant_VARYING_MODE_FRAG_TO_LIGHT: @@ -208,7 +208,7 @@ enum **VaryingMode**: :ref:`VaryingMode` **VARYING_MODE_FRAG_TO_LIGHT** = ``1`` - +Varying is passed from ``Fragment`` function to ``Light`` function. .. _class_VisualShader_constant_VARYING_MODE_MAX: @@ -216,7 +216,7 @@ enum **VaryingMode**: :ref:`VaryingMode` **VARYING_MODE_MAX** = ``2`` - +Represents the size of the :ref:`VaryingMode` enum. .. rst-class:: classref-item-separator @@ -234,7 +234,7 @@ enum **VaryingType**: :ref:`VaryingType` **VARYING_TYPE_FLOAT** = ``0`` - +Varying is of type :ref:`float`. .. _class_VisualShader_constant_VARYING_TYPE_INT: @@ -242,55 +242,63 @@ enum **VaryingType**: :ref:`VaryingType` **VARYING_TYPE_INT** = ``1`` +Varying is of type :ref:`int`. +.. _class_VisualShader_constant_VARYING_TYPE_UINT: + +.. rst-class:: classref-enumeration-constant + +:ref:`VaryingType` **VARYING_TYPE_UINT** = ``2`` + +Varying is of type unsigned :ref:`int`. .. _class_VisualShader_constant_VARYING_TYPE_VECTOR_2D: .. rst-class:: classref-enumeration-constant -:ref:`VaryingType` **VARYING_TYPE_VECTOR_2D** = ``2`` - +:ref:`VaryingType` **VARYING_TYPE_VECTOR_2D** = ``3`` +Varying is of type :ref:`Vector2`. .. _class_VisualShader_constant_VARYING_TYPE_VECTOR_3D: .. rst-class:: classref-enumeration-constant -:ref:`VaryingType` **VARYING_TYPE_VECTOR_3D** = ``3`` - +:ref:`VaryingType` **VARYING_TYPE_VECTOR_3D** = ``4`` +Varying is of type :ref:`Vector3`. .. _class_VisualShader_constant_VARYING_TYPE_VECTOR_4D: .. rst-class:: classref-enumeration-constant -:ref:`VaryingType` **VARYING_TYPE_VECTOR_4D** = ``4`` - +:ref:`VaryingType` **VARYING_TYPE_VECTOR_4D** = ``5`` +Varying is of type :ref:`Vector4`. .. _class_VisualShader_constant_VARYING_TYPE_BOOLEAN: .. rst-class:: classref-enumeration-constant -:ref:`VaryingType` **VARYING_TYPE_BOOLEAN** = ``5`` - +:ref:`VaryingType` **VARYING_TYPE_BOOLEAN** = ``6`` +Varying is of type :ref:`bool`. .. _class_VisualShader_constant_VARYING_TYPE_TRANSFORM: .. rst-class:: classref-enumeration-constant -:ref:`VaryingType` **VARYING_TYPE_TRANSFORM** = ``6`` - +:ref:`VaryingType` **VARYING_TYPE_TRANSFORM** = ``7`` +Varying is of type :ref:`Transform3D`. .. _class_VisualShader_constant_VARYING_TYPE_MAX: .. rst-class:: classref-enumeration-constant -:ref:`VaryingType` **VARYING_TYPE_MAX** = ``7`` - +:ref:`VaryingType` **VARYING_TYPE_MAX** = ``8`` +Represents the size of the :ref:`VaryingType` enum. .. rst-class:: classref-section-separator @@ -307,7 +315,7 @@ Constants **NODE_ID_INVALID** = ``-1`` - +Denotes invalid **VisualShader** node. .. _class_VisualShader_constant_NODE_ID_OUTPUT: @@ -315,7 +323,7 @@ Constants **NODE_ID_OUTPUT** = ``0`` - +Denotes output node of **VisualShader**. .. rst-class:: classref-section-separator @@ -366,9 +374,7 @@ Adds the specified ``node`` to the shader. void **add_varying** **(** :ref:`String` name, :ref:`VaryingMode` mode, :ref:`VaryingType` type **)** -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Adds a new varying value node to the shader. .. rst-class:: classref-item-separator @@ -476,9 +482,7 @@ Returns the position of the specified node within the shader graph. :ref:`int` **get_valid_node_id** **(** :ref:`Type` type **)** |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Returns next valid node ID that can be added to the shader graph. .. rst-class:: classref-item-separator @@ -490,9 +494,7 @@ Returns the position of the specified node within the shader graph. :ref:`bool` **has_varying** **(** :ref:`String` name **)** |const| -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Returns ``true`` if the shader has a varying with the given ``name``. .. rst-class:: classref-item-separator @@ -528,9 +530,7 @@ Removes the specified node from the shader. void **remove_varying** **(** :ref:`String` name **)** -.. container:: contribute - - There is currently no description for this method. Please help us by :ref:`contributing one `! +Removes a varying value node with the given ``name``. Prints an error if a node with this name is not found. .. rst-class:: classref-item-separator diff --git a/classes/class_visualshadernode.rst b/classes/class_visualshadernode.rst index 6db49ed6c..3dc0c010e 100644 --- a/classes/class_visualshadernode.rst +++ b/classes/class_visualshadernode.rst @@ -12,7 +12,7 @@ VisualShaderNode **Inherits:** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -**Inherited By:** :ref:`VisualShaderNodeBillboard`, :ref:`VisualShaderNodeClamp`, :ref:`VisualShaderNodeColorFunc`, :ref:`VisualShaderNodeColorOp`, :ref:`VisualShaderNodeCompare`, :ref:`VisualShaderNodeConstant`, :ref:`VisualShaderNodeCubemap`, :ref:`VisualShaderNodeCustom`, :ref:`VisualShaderNodeDerivativeFunc`, :ref:`VisualShaderNodeDeterminant`, :ref:`VisualShaderNodeDistanceFade`, :ref:`VisualShaderNodeDotProduct`, :ref:`VisualShaderNodeFloatFunc`, :ref:`VisualShaderNodeFloatOp`, :ref:`VisualShaderNodeFresnel`, :ref:`VisualShaderNodeIf`, :ref:`VisualShaderNodeInput`, :ref:`VisualShaderNodeIntFunc`, :ref:`VisualShaderNodeIntOp`, :ref:`VisualShaderNodeIs`, :ref:`VisualShaderNodeLinearSceneDepth`, :ref:`VisualShaderNodeMix`, :ref:`VisualShaderNodeMultiplyAdd`, :ref:`VisualShaderNodeOuterProduct`, :ref:`VisualShaderNodeOutput`, :ref:`VisualShaderNodeParameter`, :ref:`VisualShaderNodeParameterRef`, :ref:`VisualShaderNodeParticleAccelerator`, :ref:`VisualShaderNodeParticleConeVelocity`, :ref:`VisualShaderNodeParticleEmit`, :ref:`VisualShaderNodeParticleEmitter`, :ref:`VisualShaderNodeParticleMultiplyByAxisAngle`, :ref:`VisualShaderNodeParticleRandomness`, :ref:`VisualShaderNodeProximityFade`, :ref:`VisualShaderNodeRandomRange`, :ref:`VisualShaderNodeRemap`, :ref:`VisualShaderNodeResizableBase`, :ref:`VisualShaderNodeSample3D`, :ref:`VisualShaderNodeScreenUVToSDF`, :ref:`VisualShaderNodeSDFRaymarch`, :ref:`VisualShaderNodeSDFToScreenUV`, :ref:`VisualShaderNodeSmoothStep`, :ref:`VisualShaderNodeStep`, :ref:`VisualShaderNodeSwitch`, :ref:`VisualShaderNodeTexture`, :ref:`VisualShaderNodeTextureSDF`, :ref:`VisualShaderNodeTextureSDFNormal`, :ref:`VisualShaderNodeTransformCompose`, :ref:`VisualShaderNodeTransformDecompose`, :ref:`VisualShaderNodeTransformFunc`, :ref:`VisualShaderNodeTransformOp`, :ref:`VisualShaderNodeTransformVecMult`, :ref:`VisualShaderNodeUVFunc`, :ref:`VisualShaderNodeUVPolarCoord`, :ref:`VisualShaderNodeVarying`, :ref:`VisualShaderNodeVectorBase` +**Inherited By:** :ref:`VisualShaderNodeBillboard`, :ref:`VisualShaderNodeClamp`, :ref:`VisualShaderNodeColorFunc`, :ref:`VisualShaderNodeColorOp`, :ref:`VisualShaderNodeCompare`, :ref:`VisualShaderNodeConstant`, :ref:`VisualShaderNodeCubemap`, :ref:`VisualShaderNodeCustom`, :ref:`VisualShaderNodeDerivativeFunc`, :ref:`VisualShaderNodeDeterminant`, :ref:`VisualShaderNodeDistanceFade`, :ref:`VisualShaderNodeDotProduct`, :ref:`VisualShaderNodeFloatFunc`, :ref:`VisualShaderNodeFloatOp`, :ref:`VisualShaderNodeFresnel`, :ref:`VisualShaderNodeIf`, :ref:`VisualShaderNodeInput`, :ref:`VisualShaderNodeIntFunc`, :ref:`VisualShaderNodeIntOp`, :ref:`VisualShaderNodeIs`, :ref:`VisualShaderNodeLinearSceneDepth`, :ref:`VisualShaderNodeMix`, :ref:`VisualShaderNodeMultiplyAdd`, :ref:`VisualShaderNodeOuterProduct`, :ref:`VisualShaderNodeOutput`, :ref:`VisualShaderNodeParameter`, :ref:`VisualShaderNodeParameterRef`, :ref:`VisualShaderNodeParticleAccelerator`, :ref:`VisualShaderNodeParticleConeVelocity`, :ref:`VisualShaderNodeParticleEmit`, :ref:`VisualShaderNodeParticleEmitter`, :ref:`VisualShaderNodeParticleMultiplyByAxisAngle`, :ref:`VisualShaderNodeParticleRandomness`, :ref:`VisualShaderNodeProximityFade`, :ref:`VisualShaderNodeRandomRange`, :ref:`VisualShaderNodeRemap`, :ref:`VisualShaderNodeResizableBase`, :ref:`VisualShaderNodeSample3D`, :ref:`VisualShaderNodeScreenUVToSDF`, :ref:`VisualShaderNodeSDFRaymarch`, :ref:`VisualShaderNodeSDFToScreenUV`, :ref:`VisualShaderNodeSmoothStep`, :ref:`VisualShaderNodeStep`, :ref:`VisualShaderNodeSwitch`, :ref:`VisualShaderNodeTexture`, :ref:`VisualShaderNodeTextureSDF`, :ref:`VisualShaderNodeTextureSDFNormal`, :ref:`VisualShaderNodeTransformCompose`, :ref:`VisualShaderNodeTransformDecompose`, :ref:`VisualShaderNodeTransformFunc`, :ref:`VisualShaderNodeTransformOp`, :ref:`VisualShaderNodeTransformVecMult`, :ref:`VisualShaderNodeUIntFunc`, :ref:`VisualShaderNodeUIntOp`, :ref:`VisualShaderNodeUVFunc`, :ref:`VisualShaderNodeUVPolarCoord`, :ref:`VisualShaderNodeVarying`, :ref:`VisualShaderNodeVectorBase` Base class for nodes in a visual shader graph. @@ -112,11 +112,19 @@ Floating-point scalar. Translated to ``float`` type in shader code. Integer scalar. Translated to ``int`` type in shader code. +.. _class_VisualShaderNode_constant_PORT_TYPE_SCALAR_UINT: + +.. rst-class:: classref-enumeration-constant + +:ref:`PortType` **PORT_TYPE_SCALAR_UINT** = ``2`` + +Unsigned integer scalar. Translated to ``uint`` type in shader code. + .. _class_VisualShaderNode_constant_PORT_TYPE_VECTOR_2D: .. rst-class:: classref-enumeration-constant -:ref:`PortType` **PORT_TYPE_VECTOR_2D** = ``2`` +:ref:`PortType` **PORT_TYPE_VECTOR_2D** = ``3`` 2D vector of floating-point values. Translated to ``vec2`` type in shader code. @@ -124,7 +132,7 @@ Integer scalar. Translated to ``int`` type in shader code. .. rst-class:: classref-enumeration-constant -:ref:`PortType` **PORT_TYPE_VECTOR_3D** = ``3`` +:ref:`PortType` **PORT_TYPE_VECTOR_3D** = ``4`` 3D vector of floating-point values. Translated to ``vec3`` type in shader code. @@ -132,7 +140,7 @@ Integer scalar. Translated to ``int`` type in shader code. .. rst-class:: classref-enumeration-constant -:ref:`PortType` **PORT_TYPE_VECTOR_4D** = ``4`` +:ref:`PortType` **PORT_TYPE_VECTOR_4D** = ``5`` 4D vector of floating-point values. Translated to ``vec4`` type in shader code. @@ -140,7 +148,7 @@ Integer scalar. Translated to ``int`` type in shader code. .. rst-class:: classref-enumeration-constant -:ref:`PortType` **PORT_TYPE_BOOLEAN** = ``5`` +:ref:`PortType` **PORT_TYPE_BOOLEAN** = ``6`` Boolean type. Translated to ``bool`` type in shader code. @@ -148,7 +156,7 @@ Boolean type. Translated to ``bool`` type in shader code. .. rst-class:: classref-enumeration-constant -:ref:`PortType` **PORT_TYPE_TRANSFORM** = ``6`` +:ref:`PortType` **PORT_TYPE_TRANSFORM** = ``7`` Transform type. Translated to ``mat4`` type in shader code. @@ -156,7 +164,7 @@ Transform type. Translated to ``mat4`` type in shader code. .. rst-class:: classref-enumeration-constant -:ref:`PortType` **PORT_TYPE_SAMPLER** = ``7`` +:ref:`PortType` **PORT_TYPE_SAMPLER** = ``8`` Sampler type. Translated to reference of sampler uniform in shader code. Can only be used for input ports in non-uniform nodes. @@ -164,7 +172,7 @@ Sampler type. Translated to reference of sampler uniform in shader code. Can onl .. rst-class:: classref-enumeration-constant -:ref:`PortType` **PORT_TYPE_MAX** = ``8`` +:ref:`PortType` **PORT_TYPE_MAX** = ``9`` Represents the size of the :ref:`PortType` enum. diff --git a/classes/class_visualshadernodeclamp.rst b/classes/class_visualshadernodeclamp.rst index a995e3df6..aa15e6161 100644 --- a/classes/class_visualshadernodeclamp.rst +++ b/classes/class_visualshadernodeclamp.rst @@ -64,11 +64,19 @@ A floating-point scalar. An integer scalar. +.. _class_VisualShaderNodeClamp_constant_OP_TYPE_UINT: + +.. rst-class:: classref-enumeration-constant + +:ref:`OpType` **OP_TYPE_UINT** = ``2`` + +An unsigned integer scalar. + .. _class_VisualShaderNodeClamp_constant_OP_TYPE_VECTOR_2D: .. rst-class:: classref-enumeration-constant -:ref:`OpType` **OP_TYPE_VECTOR_2D** = ``2`` +:ref:`OpType` **OP_TYPE_VECTOR_2D** = ``3`` A 2D vector type. @@ -76,7 +84,7 @@ A 2D vector type. .. rst-class:: classref-enumeration-constant -:ref:`OpType` **OP_TYPE_VECTOR_3D** = ``3`` +:ref:`OpType` **OP_TYPE_VECTOR_3D** = ``4`` A 3D vector type. @@ -84,7 +92,7 @@ A 3D vector type. .. rst-class:: classref-enumeration-constant -:ref:`OpType` **OP_TYPE_VECTOR_4D** = ``4`` +:ref:`OpType` **OP_TYPE_VECTOR_4D** = ``5`` A 4D vector type. @@ -92,7 +100,7 @@ A 4D vector type. .. rst-class:: classref-enumeration-constant -:ref:`OpType` **OP_TYPE_MAX** = ``5`` +:ref:`OpType` **OP_TYPE_MAX** = ``6`` Represents the size of the :ref:`OpType` enum. diff --git a/classes/class_visualshadernodecompare.rst b/classes/class_visualshadernodecompare.rst index 463daebf0..360228b7f 100644 --- a/classes/class_visualshadernodecompare.rst +++ b/classes/class_visualshadernodecompare.rst @@ -68,11 +68,19 @@ A floating-point scalar. An integer scalar. +.. _class_VisualShaderNodeCompare_constant_CTYPE_SCALAR_UINT: + +.. rst-class:: classref-enumeration-constant + +:ref:`ComparisonType` **CTYPE_SCALAR_UINT** = ``2`` + +An unsigned integer scalar. + .. _class_VisualShaderNodeCompare_constant_CTYPE_VECTOR_2D: .. rst-class:: classref-enumeration-constant -:ref:`ComparisonType` **CTYPE_VECTOR_2D** = ``2`` +:ref:`ComparisonType` **CTYPE_VECTOR_2D** = ``3`` A 2D vector type. @@ -80,7 +88,7 @@ A 2D vector type. .. rst-class:: classref-enumeration-constant -:ref:`ComparisonType` **CTYPE_VECTOR_3D** = ``3`` +:ref:`ComparisonType` **CTYPE_VECTOR_3D** = ``4`` A 3D vector type. @@ -88,7 +96,7 @@ A 3D vector type. .. rst-class:: classref-enumeration-constant -:ref:`ComparisonType` **CTYPE_VECTOR_4D** = ``4`` +:ref:`ComparisonType` **CTYPE_VECTOR_4D** = ``5`` A 4D vector type. @@ -96,7 +104,7 @@ A 4D vector type. .. rst-class:: classref-enumeration-constant -:ref:`ComparisonType` **CTYPE_BOOLEAN** = ``5`` +:ref:`ComparisonType` **CTYPE_BOOLEAN** = ``6`` A boolean type. @@ -104,7 +112,7 @@ A boolean type. .. rst-class:: classref-enumeration-constant -:ref:`ComparisonType` **CTYPE_TRANSFORM** = ``6`` +:ref:`ComparisonType` **CTYPE_TRANSFORM** = ``7`` A transform (``mat4``) type. @@ -112,7 +120,7 @@ A transform (``mat4``) type. .. rst-class:: classref-enumeration-constant -:ref:`ComparisonType` **CTYPE_MAX** = ``7`` +:ref:`ComparisonType` **CTYPE_MAX** = ``8`` Represents the size of the :ref:`ComparisonType` enum. diff --git a/classes/class_visualshadernodeconstant.rst b/classes/class_visualshadernodeconstant.rst index 1fb3175c7..133634ec6 100644 --- a/classes/class_visualshadernodeconstant.rst +++ b/classes/class_visualshadernodeconstant.rst @@ -12,10 +12,17 @@ VisualShaderNodeConstant **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -**Inherited By:** :ref:`VisualShaderNodeBooleanConstant`, :ref:`VisualShaderNodeColorConstant`, :ref:`VisualShaderNodeFloatConstant`, :ref:`VisualShaderNodeIntConstant`, :ref:`VisualShaderNodeTransformConstant`, :ref:`VisualShaderNodeVec2Constant`, :ref:`VisualShaderNodeVec3Constant`, :ref:`VisualShaderNodeVec4Constant` +**Inherited By:** :ref:`VisualShaderNodeBooleanConstant`, :ref:`VisualShaderNodeColorConstant`, :ref:`VisualShaderNodeFloatConstant`, :ref:`VisualShaderNodeIntConstant`, :ref:`VisualShaderNodeTransformConstant`, :ref:`VisualShaderNodeUIntConstant`, :ref:`VisualShaderNodeVec2Constant`, :ref:`VisualShaderNodeVec3Constant`, :ref:`VisualShaderNodeVec4Constant` A base type for the constants within the visual shader graph. +.. rst-class:: classref-introduction-group + +Description +----------- + +This is an abstract class. See the derived types for descriptions of the possible values. + .. |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_visualshadernodedistancefade.rst b/classes/class_visualshadernodedistancefade.rst index 86c4ec4f0..3c4134c09 100644 --- a/classes/class_visualshadernodedistancefade.rst +++ b/classes/class_visualshadernodedistancefade.rst @@ -12,9 +12,14 @@ VisualShaderNodeDistanceFade **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node representing distance fade effect. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +The distance fade effect fades out each pixel based on its distance to another object. .. |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_visualshadernodeintparameter.rst b/classes/class_visualshadernodeintparameter.rst index e7b7f9109..4ab652023 100644 --- a/classes/class_visualshadernodeintparameter.rst +++ b/classes/class_visualshadernodeintparameter.rst @@ -12,9 +12,14 @@ VisualShaderNodeIntParameter **Inherits:** :ref:`VisualShaderNodeParameter` **<** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node for shader parameter (uniform) of type :ref:`int`. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +A :ref:`VisualShaderNodeParameter` of type :ref:`int`. Offers additional customization for range of accepted values. .. rst-class:: classref-reftable-group @@ -59,7 +64,7 @@ enum **Hint**: :ref:`Hint` **HINT_NONE** = ``0`` - +The parameter will not constrain its value. .. _class_VisualShaderNodeIntParameter_constant_HINT_RANGE: @@ -67,7 +72,7 @@ enum **Hint**: :ref:`Hint` **HINT_RANGE** = ``1`` - +The parameter's value must be within the specified :ref:`min`/:ref:`max` range. .. _class_VisualShaderNodeIntParameter_constant_HINT_RANGE_STEP: @@ -75,7 +80,7 @@ enum **Hint**: :ref:`Hint` **HINT_RANGE_STEP** = ``2`` - +The parameter's value must be within the specified range, with the given :ref:`step` between values. .. _class_VisualShaderNodeIntParameter_constant_HINT_MAX: @@ -83,7 +88,7 @@ enum **Hint**: :ref:`Hint` **HINT_MAX** = ``3`` - +Represents the size of the :ref:`Hint` enum. .. rst-class:: classref-section-separator @@ -105,9 +110,7 @@ Property Descriptions - void **set_default_value** **(** :ref:`int` value **)** - :ref:`int` **get_default_value** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +Default value of this parameter, which will be used if not set externally. :ref:`default_value_enabled` must be enabled; defaults to ``0`` otherwise. .. rst-class:: classref-item-separator @@ -124,9 +127,7 @@ Property Descriptions - void **set_default_value_enabled** **(** :ref:`bool` value **)** - :ref:`bool` **is_default_value_enabled** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +If ``true``, the node will have a custom default value. .. rst-class:: classref-item-separator @@ -143,9 +144,7 @@ Property Descriptions - void **set_hint** **(** :ref:`Hint` value **)** - :ref:`Hint` **get_hint** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +Range hint of this node. Use it to customize valid parameter range. .. rst-class:: classref-item-separator @@ -162,9 +161,7 @@ Property Descriptions - void **set_max** **(** :ref:`int` value **)** - :ref:`int` **get_max** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +The maximum value this parameter can take. :ref:`hint` must be either :ref:`HINT_RANGE` or :ref:`HINT_RANGE_STEP` for this to take effect. .. rst-class:: classref-item-separator @@ -181,9 +178,7 @@ Property Descriptions - void **set_min** **(** :ref:`int` value **)** - :ref:`int` **get_min** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +The minimum value this parameter can take. :ref:`hint` must be either :ref:`HINT_RANGE` or :ref:`HINT_RANGE_STEP` for this to take effect. .. rst-class:: classref-item-separator @@ -200,9 +195,7 @@ Property Descriptions - void **set_step** **(** :ref:`int` value **)** - :ref:`int` **get_step** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +The step between parameter's values. Forces the parameter to be a multiple of the given value. :ref:`hint` must be :ref:`HINT_RANGE_STEP` for this to take effect. .. |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_visualshadernodelinearscenedepth.rst b/classes/class_visualshadernodelinearscenedepth.rst index 456a4a875..72041e3bb 100644 --- a/classes/class_visualshadernodelinearscenedepth.rst +++ b/classes/class_visualshadernodelinearscenedepth.rst @@ -12,9 +12,14 @@ VisualShaderNodeLinearSceneDepth **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that returns the depth value of the DEPTH_TEXTURE node in a linear space. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +This node can be used in fragment shaders. .. |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_visualshadernodeparameter.rst b/classes/class_visualshadernodeparameter.rst index f8ce0c080..9363b6f16 100644 --- a/classes/class_visualshadernodeparameter.rst +++ b/classes/class_visualshadernodeparameter.rst @@ -12,7 +12,7 @@ VisualShaderNodeParameter **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -**Inherited By:** :ref:`VisualShaderNodeBooleanParameter`, :ref:`VisualShaderNodeColorParameter`, :ref:`VisualShaderNodeFloatParameter`, :ref:`VisualShaderNodeIntParameter`, :ref:`VisualShaderNodeTextureParameter`, :ref:`VisualShaderNodeTransformParameter`, :ref:`VisualShaderNodeVec2Parameter`, :ref:`VisualShaderNodeVec3Parameter`, :ref:`VisualShaderNodeVec4Parameter` +**Inherited By:** :ref:`VisualShaderNodeBooleanParameter`, :ref:`VisualShaderNodeColorParameter`, :ref:`VisualShaderNodeFloatParameter`, :ref:`VisualShaderNodeIntParameter`, :ref:`VisualShaderNodeTextureParameter`, :ref:`VisualShaderNodeTransformParameter`, :ref:`VisualShaderNodeUIntParameter`, :ref:`VisualShaderNodeVec2Parameter`, :ref:`VisualShaderNodeVec3Parameter`, :ref:`VisualShaderNodeVec4Parameter` A base type for the parameters within the visual shader graph. @@ -58,7 +58,7 @@ enum **Qualifier**: :ref:`Qualifier` **QUAL_NONE** = ``0`` - +The parameter will be tied to the :ref:`ShaderMaterial` using this shader. .. _class_VisualShaderNodeParameter_constant_QUAL_GLOBAL: @@ -66,7 +66,7 @@ enum **Qualifier**: :ref:`Qualifier` **QUAL_GLOBAL** = ``1`` - +The parameter will use a global value, defined in Project Settings. .. _class_VisualShaderNodeParameter_constant_QUAL_INSTANCE: @@ -74,7 +74,7 @@ enum **Qualifier**: :ref:`Qualifier` **QUAL_INSTANCE** = ``2`` - +The parameter will be tied to the node with attached :ref:`ShaderMaterial` using this shader. .. _class_VisualShaderNodeParameter_constant_QUAL_MAX: @@ -121,9 +121,7 @@ Name of the parameter, by which it can be accessed through the :ref:`ShaderMater - void **set_qualifier** **(** :ref:`Qualifier` value **)** - :ref:`Qualifier` **get_qualifier** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +Defines the scope of the parameter. .. |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_visualshadernodeparticleaccelerator.rst b/classes/class_visualshadernodeparticleaccelerator.rst index 085a3a04a..d69d4e8a0 100644 --- a/classes/class_visualshadernodeparticleaccelerator.rst +++ b/classes/class_visualshadernodeparticleaccelerator.rst @@ -12,9 +12,14 @@ VisualShaderNodeParticleAccelerator **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that accelerates particles. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +Particle accelerator can be used in "process" step of particle shader. It will accelerate the particles. Connect it to the Velocity output port. .. rst-class:: classref-reftable-group @@ -49,7 +54,7 @@ enum **Mode**: :ref:`Mode` **MODE_LINEAR** = ``0`` - +The particles will be accelerated based on their velocity. .. _class_VisualShaderNodeParticleAccelerator_constant_MODE_RADIAL: @@ -57,7 +62,7 @@ enum **Mode**: :ref:`Mode` **MODE_RADIAL** = ``1`` - +The particles will be accelerated towards or away from the center. .. _class_VisualShaderNodeParticleAccelerator_constant_MODE_TANGENTIAL: @@ -65,7 +70,7 @@ enum **Mode**: :ref:`Mode` **MODE_TANGENTIAL** = ``2`` - +The particles will be accelerated tangentially to the radius vector from center to their position. .. _class_VisualShaderNodeParticleAccelerator_constant_MODE_MAX: @@ -95,9 +100,7 @@ Property Descriptions - void **set_mode** **(** :ref:`Mode` value **)** - :ref:`Mode` **get_mode** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +Defines in what manner the particles will be accelerated. .. |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_visualshadernodeparticleboxemitter.rst b/classes/class_visualshadernodeparticleboxemitter.rst index f3bd96bd8..bd3befe7f 100644 --- a/classes/class_visualshadernodeparticleboxemitter.rst +++ b/classes/class_visualshadernodeparticleboxemitter.rst @@ -12,9 +12,14 @@ VisualShaderNodeParticleBoxEmitter **Inherits:** :ref:`VisualShaderNodeParticleEmitter` **<** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that makes particles emitted in a box shape. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +:ref:`VisualShaderNodeParticleEmitter` that makes the particles emitted in box shape with the specified extents. .. |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_visualshadernodeparticleconevelocity.rst b/classes/class_visualshadernodeparticleconevelocity.rst index debdc77ed..9cfb0000c 100644 --- a/classes/class_visualshadernodeparticleconevelocity.rst +++ b/classes/class_visualshadernodeparticleconevelocity.rst @@ -12,9 +12,14 @@ VisualShaderNodeParticleConeVelocity **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that makes particles move in a cone shape. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +This node can be used in "start" step of particle shader. It defines the initial velocity of the particles, making them move in cone shape starting from the center, with a given spread. .. |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_visualshadernodeparticleemit.rst b/classes/class_visualshadernodeparticleemit.rst index bda50bf5e..10f25aed9 100644 --- a/classes/class_visualshadernodeparticleemit.rst +++ b/classes/class_visualshadernodeparticleemit.rst @@ -12,9 +12,14 @@ VisualShaderNodeParticleEmit **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that forces to emit a particle from a sub-emitter. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +This node internally calls ``emit_subparticle`` shader method. It will emit a particle from the configured sub-emitter and also allows to customize how its emitted. Requires a sub-emitter assigned to the particles node with this shader. .. rst-class:: classref-reftable-group @@ -49,7 +54,7 @@ enum **EmitFlags**: :ref:`EmitFlags` **EMIT_FLAG_POSITION** = ``1`` - +If enabled, the particle starts with the position defined by this node. .. _class_VisualShaderNodeParticleEmit_constant_EMIT_FLAG_ROT_SCALE: @@ -57,7 +62,7 @@ enum **EmitFlags**: :ref:`EmitFlags` **EMIT_FLAG_ROT_SCALE** = ``2`` - +If enabled, the particle starts with the rotation and scale defined by this node. .. _class_VisualShaderNodeParticleEmit_constant_EMIT_FLAG_VELOCITY: @@ -65,7 +70,7 @@ enum **EmitFlags**: :ref:`EmitFlags` **EMIT_FLAG_VELOCITY** = ``4`` - +If enabled,the particle starts with the velocity defined by this node. .. _class_VisualShaderNodeParticleEmit_constant_EMIT_FLAG_COLOR: @@ -73,7 +78,7 @@ enum **EmitFlags**: :ref:`EmitFlags` **EMIT_FLAG_COLOR** = ``8`` - +If enabled, the particle starts with the color defined by this node. .. _class_VisualShaderNodeParticleEmit_constant_EMIT_FLAG_CUSTOM: @@ -81,7 +86,7 @@ enum **EmitFlags**: :ref:`EmitFlags` **EMIT_FLAG_CUSTOM** = ``16`` - +If enabled, the particle starts with the ``CUSTOM`` data defined by this node. .. rst-class:: classref-section-separator @@ -103,9 +108,7 @@ Property Descriptions - void **set_flags** **(** :ref:`EmitFlags` value **)** - :ref:`EmitFlags` **get_flags** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +Flags used to override the properties defined in the sub-emitter's process material. .. |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_visualshadernodeparticleemitter.rst b/classes/class_visualshadernodeparticleemitter.rst index 63c7297b3..acbd47079 100644 --- a/classes/class_visualshadernodeparticleemitter.rst +++ b/classes/class_visualshadernodeparticleemitter.rst @@ -16,6 +16,13 @@ VisualShaderNodeParticleEmitter A base class for particle emitters. +.. rst-class:: classref-introduction-group + +Description +----------- + +Particle emitter nodes can be used in "start" step of particle shaders and they define the starting position of the particles. Connect them to the Position output port. + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_visualshadernodeparticlemeshemitter.rst b/classes/class_visualshadernodeparticlemeshemitter.rst index e912b3040..e647e5227 100644 --- a/classes/class_visualshadernodeparticlemeshemitter.rst +++ b/classes/class_visualshadernodeparticlemeshemitter.rst @@ -12,9 +12,14 @@ VisualShaderNodeParticleMeshEmitter **Inherits:** :ref:`VisualShaderNodeParticleEmitter` **<** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that makes particles emitted in a shape defined by a :ref:`Mesh`. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +:ref:`VisualShaderNodeParticleEmitter` that makes the particles emitted in a shape of the assigned :ref:`mesh`. It will emit from the mesh's surfaces, either all or only the specified one. .. rst-class:: classref-reftable-group @@ -52,9 +57,7 @@ Property Descriptions - void **set_mesh** **(** :ref:`Mesh` value **)** - :ref:`Mesh` **get_mesh** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +The :ref:`Mesh` that defines emission shape. .. rst-class:: classref-item-separator @@ -71,9 +74,7 @@ Property Descriptions - void **set_surface_index** **(** :ref:`int` value **)** - :ref:`int` **get_surface_index** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +Index of the surface that emits particles. :ref:`use_all_surfaces` must be ``false`` for this to take effect. .. rst-class:: classref-item-separator @@ -90,9 +91,7 @@ Property Descriptions - void **set_use_all_surfaces** **(** :ref:`bool` value **)** - :ref:`bool` **is_use_all_surfaces** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +If ``true``, the particles will emit from all surfaces of the mesh. .. |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_visualshadernodeparticlemultiplybyaxisangle.rst b/classes/class_visualshadernodeparticlemultiplybyaxisangle.rst index e36c70bd6..655893231 100644 --- a/classes/class_visualshadernodeparticlemultiplybyaxisangle.rst +++ b/classes/class_visualshadernodeparticlemultiplybyaxisangle.rst @@ -12,9 +12,14 @@ VisualShaderNodeParticleMultiplyByAxisAngle **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader helper node for multiplying position and rotation of particles. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +This node helps to multiply a position input vector by rotation using specific axis. Intended to work with emitters. .. rst-class:: classref-reftable-group @@ -48,9 +53,7 @@ Property Descriptions - void **set_degrees_mode** **(** :ref:`bool` value **)** - :ref:`bool` **is_degrees_mode** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +If ``true``, the angle will be interpreted in degrees instead of radians. .. |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_visualshadernodeparticleoutput.rst b/classes/class_visualshadernodeparticleoutput.rst index 722cf2d09..1b12f5b13 100644 --- a/classes/class_visualshadernodeparticleoutput.rst +++ b/classes/class_visualshadernodeparticleoutput.rst @@ -12,9 +12,14 @@ VisualShaderNodeParticleOutput **Inherits:** :ref:`VisualShaderNodeOutput` **<** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +Visual shader node that defines output values for particle emitting. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +This node defines how particles are emitted. It allows to customize e.g. position and velocity. Available ports are different depending on which function this node is inside (start, process, collision) and whether custom data is enabled. .. |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_visualshadernodeparticlerandomness.rst b/classes/class_visualshadernodeparticlerandomness.rst index 05c39a334..8ec3ef2a1 100644 --- a/classes/class_visualshadernodeparticlerandomness.rst +++ b/classes/class_visualshadernodeparticlerandomness.rst @@ -12,9 +12,14 @@ VisualShaderNodeParticleRandomness **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +Visual shader node for randomizing particle values. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +Randomness node will output pseudo-random values of the given type based on the specified minimum and maximum values. .. rst-class:: classref-reftable-group diff --git a/classes/class_visualshadernodeparticleringemitter.rst b/classes/class_visualshadernodeparticleringemitter.rst index dc5937517..c2c370add 100644 --- a/classes/class_visualshadernodeparticleringemitter.rst +++ b/classes/class_visualshadernodeparticleringemitter.rst @@ -12,9 +12,14 @@ VisualShaderNodeParticleRingEmitter **Inherits:** :ref:`VisualShaderNodeParticleEmitter` **<** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that makes particles emitted in a ring shape. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +:ref:`VisualShaderNodeParticleEmitter` that makes the particles emitted in ring shape with the specified inner and outer radii and height. .. |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_visualshadernodeparticlesphereemitter.rst b/classes/class_visualshadernodeparticlesphereemitter.rst index 8112c14a7..fea3ff0b7 100644 --- a/classes/class_visualshadernodeparticlesphereemitter.rst +++ b/classes/class_visualshadernodeparticlesphereemitter.rst @@ -12,9 +12,14 @@ VisualShaderNodeParticleSphereEmitter **Inherits:** :ref:`VisualShaderNodeParticleEmitter` **<** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that makes particles emitted in a sphere shape. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +:ref:`VisualShaderNodeParticleEmitter` that makes the particles emitted in sphere shape with the specified inner and outer radii. .. |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_visualshadernodeproximityfade.rst b/classes/class_visualshadernodeproximityfade.rst index 3512c3893..c1e834ab5 100644 --- a/classes/class_visualshadernodeproximityfade.rst +++ b/classes/class_visualshadernodeproximityfade.rst @@ -12,9 +12,14 @@ VisualShaderNodeProximityFade **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node representing proximity fade effect. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +The proximity fade effect fades out each pixel based on its distance to another object. .. |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_visualshadernoderandomrange.rst b/classes/class_visualshadernoderandomrange.rst index 9a4994c77..251690bc9 100644 --- a/classes/class_visualshadernoderandomrange.rst +++ b/classes/class_visualshadernoderandomrange.rst @@ -12,9 +12,14 @@ VisualShaderNodeRandomRange **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that generates a pseudo-random scalar. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +Random range node will output a pseudo-random scalar value in the specified range, based on the seed. The value is always the same for the given seed and range, so you should provide a changing input, e.g. by using time. .. |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_visualshadernoderemap.rst b/classes/class_visualshadernoderemap.rst index 354f687e8..2cbb4974b 100644 --- a/classes/class_visualshadernoderemap.rst +++ b/classes/class_visualshadernoderemap.rst @@ -12,9 +12,14 @@ VisualShaderNodeRemap **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node for remap function. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +Remap will transform the input range into output range, e.g. you can change a ``0..1`` value to ``-2..2`` etc. See :ref:`@GlobalScope.remap` 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_visualshadernodeswitch.rst b/classes/class_visualshadernodeswitch.rst index 6b64b6610..e582f8f6b 100644 --- a/classes/class_visualshadernodeswitch.rst +++ b/classes/class_visualshadernodeswitch.rst @@ -64,11 +64,19 @@ A floating-point scalar. An integer scalar. +.. _class_VisualShaderNodeSwitch_constant_OP_TYPE_UINT: + +.. rst-class:: classref-enumeration-constant + +:ref:`OpType` **OP_TYPE_UINT** = ``2`` + +An unsigned integer scalar. + .. _class_VisualShaderNodeSwitch_constant_OP_TYPE_VECTOR_2D: .. rst-class:: classref-enumeration-constant -:ref:`OpType` **OP_TYPE_VECTOR_2D** = ``2`` +:ref:`OpType` **OP_TYPE_VECTOR_2D** = ``3`` A 2D vector type. @@ -76,7 +84,7 @@ A 2D vector type. .. rst-class:: classref-enumeration-constant -:ref:`OpType` **OP_TYPE_VECTOR_3D** = ``3`` +:ref:`OpType` **OP_TYPE_VECTOR_3D** = ``4`` A 3D vector type. @@ -84,7 +92,7 @@ A 3D vector type. .. rst-class:: classref-enumeration-constant -:ref:`OpType` **OP_TYPE_VECTOR_4D** = ``4`` +:ref:`OpType` **OP_TYPE_VECTOR_4D** = ``5`` A 4D vector type. @@ -92,7 +100,7 @@ A 4D vector type. .. rst-class:: classref-enumeration-constant -:ref:`OpType` **OP_TYPE_BOOLEAN** = ``5`` +:ref:`OpType` **OP_TYPE_BOOLEAN** = ``6`` A boolean type. @@ -100,7 +108,7 @@ A boolean type. .. rst-class:: classref-enumeration-constant -:ref:`OpType` **OP_TYPE_TRANSFORM** = ``6`` +:ref:`OpType` **OP_TYPE_TRANSFORM** = ``7`` A transform type. @@ -108,7 +116,7 @@ A transform type. .. rst-class:: classref-enumeration-constant -:ref:`OpType` **OP_TYPE_MAX** = ``7`` +:ref:`OpType` **OP_TYPE_MAX** = ``8`` Represents the size of the :ref:`OpType` enum. diff --git a/classes/class_visualshadernodetexture2darrayparameter.rst b/classes/class_visualshadernodetexture2darrayparameter.rst index a1c8bedd3..d0dd199b6 100644 --- a/classes/class_visualshadernodetexture2darrayparameter.rst +++ b/classes/class_visualshadernodetexture2darrayparameter.rst @@ -12,9 +12,14 @@ VisualShaderNodeTexture2DArrayParameter **Inherits:** :ref:`VisualShaderNodeTextureParameter` **<** :ref:`VisualShaderNodeParameter` **<** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node for shader parameter (uniform) of type :ref:`Texture2DArray`. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +This parameter allows to provide a collection of textures for the shader. You can use :ref:`VisualShaderNodeTexture2DArray` to extract the textures from array. .. |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_visualshadernodetextureparameter.rst b/classes/class_visualshadernodetextureparameter.rst index 52c53063c..02033ba0e 100644 --- a/classes/class_visualshadernodetextureparameter.rst +++ b/classes/class_visualshadernodetextureparameter.rst @@ -154,7 +154,7 @@ enum **TextureFilter**: :ref:`TextureFilter` **FILTER_DEFAULT** = ``0`` - +Sample the texture using the filter determined by the node this shader is attached to. .. _class_VisualShaderNodeTextureParameter_constant_FILTER_NEAREST: @@ -162,7 +162,7 @@ enum **TextureFilter**: :ref:`TextureFilter` **FILTER_NEAREST** = ``1`` - +The texture filter reads from the nearest pixel only. The simplest and fastest method of filtering, but the texture will look pixelized. .. _class_VisualShaderNodeTextureParameter_constant_FILTER_LINEAR: @@ -170,7 +170,7 @@ enum **TextureFilter**: :ref:`TextureFilter` **FILTER_LINEAR** = ``2`` - +The texture filter blends between the nearest four pixels. Use this for most cases where you want to avoid a pixelated style. .. _class_VisualShaderNodeTextureParameter_constant_FILTER_NEAREST_MIPMAP: @@ -178,7 +178,7 @@ enum **TextureFilter**: :ref:`TextureFilter` **FILTER_NEAREST_MIPMAP** = ``3`` - +The texture filter reads from the nearest pixel in the nearest mipmap. This is the fastest way to read from textures with mipmaps. .. _class_VisualShaderNodeTextureParameter_constant_FILTER_LINEAR_MIPMAP: @@ -186,7 +186,7 @@ enum **TextureFilter**: :ref:`TextureFilter` **FILTER_LINEAR_MIPMAP** = ``4`` - +The texture filter blends between the nearest 4 pixels and between the nearest 2 mipmaps. Use this for non-pixel art textures that may be viewed at a low scale (e.g. due to :ref:`Camera2D` zoom), as mipmaps are important to smooth out pixels that are smaller than on-screen pixels. .. _class_VisualShaderNodeTextureParameter_constant_FILTER_NEAREST_MIPMAP_ANISOTROPIC: @@ -194,7 +194,9 @@ enum **TextureFilter**: :ref:`TextureFilter` **FILTER_NEAREST_MIPMAP_ANISOTROPIC** = ``5`` +The texture filter reads from the nearest pixel, but selects a mipmap based on the angle between the surface and the camera view. This reduces artifacts on surfaces that are almost in line with the camera. The anisotropic filtering level can be changed by adjusting :ref:`ProjectSettings.rendering/textures/default_filters/anisotropic_filtering_level`. +\ **Note:** This texture filter is rarely useful in 2D projects. :ref:`FILTER_LINEAR_MIPMAP` is usually more appropriate. .. _class_VisualShaderNodeTextureParameter_constant_FILTER_LINEAR_MIPMAP_ANISOTROPIC: @@ -202,7 +204,9 @@ enum **TextureFilter**: :ref:`TextureFilter` **FILTER_LINEAR_MIPMAP_ANISOTROPIC** = ``6`` +The texture filter blends between the nearest 4 pixels and selects a mipmap based on the angle between the surface and the camera view. This reduces artifacts on surfaces that are almost in line with the camera. This is the slowest of the filtering options, but results in the highest quality texturing. The anisotropic filtering level can be changed by adjusting :ref:`ProjectSettings.rendering/textures/default_filters/anisotropic_filtering_level`. +\ **Note:** This texture filter is rarely useful in 2D projects. :ref:`FILTER_LINEAR_MIPMAP` is usually more appropriate. .. _class_VisualShaderNodeTextureParameter_constant_FILTER_MAX: @@ -228,7 +232,7 @@ enum **TextureRepeat**: :ref:`TextureRepeat` **REPEAT_DEFAULT** = ``0`` - +Sample the texture using the repeat mode determined by the node this shader is attached to. .. _class_VisualShaderNodeTextureParameter_constant_REPEAT_ENABLED: @@ -236,7 +240,7 @@ enum **TextureRepeat**: :ref:`TextureRepeat` **REPEAT_ENABLED** = ``1`` - +Texture will repeat normally. .. _class_VisualShaderNodeTextureParameter_constant_REPEAT_DISABLED: @@ -244,7 +248,7 @@ enum **TextureRepeat**: :ref:`TextureRepeat` **REPEAT_DISABLED** = ``2`` - +Texture will not repeat. .. _class_VisualShaderNodeTextureParameter_constant_REPEAT_MAX: diff --git a/classes/class_visualshadernodeuintconstant.rst b/classes/class_visualshadernodeuintconstant.rst new file mode 100644 index 000000000..3c32f7e15 --- /dev/null +++ b/classes/class_visualshadernodeuintconstant.rst @@ -0,0 +1,63 @@ +:github_url: hide + +.. DO NOT EDIT THIS FILE!!! +.. Generated automatically from Godot engine sources. +.. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py. +.. XML source: https://github.com/godotengine/godot/tree/master/doc/classes/VisualShaderNodeUIntConstant.xml. + +.. _class_VisualShaderNodeUIntConstant: + +VisualShaderNodeUIntConstant +============================ + +**Inherits:** :ref:`VisualShaderNodeConstant` **<** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` + +An unsigned scalar integer constant to be used within the visual shader graph. + +.. rst-class:: classref-introduction-group + +Description +----------- + +Translated to ``uint`` in the shader language. + +.. rst-class:: classref-reftable-group + +Properties +---------- + +.. table:: + :widths: auto + + +-----------------------+-----------------------------------------------------------------------+-------+ + | :ref:`int` | :ref:`constant` | ``0`` | + +-----------------------+-----------------------------------------------------------------------+-------+ + +.. rst-class:: classref-section-separator + +---- + +.. rst-class:: classref-descriptions-group + +Property Descriptions +--------------------- + +.. _class_VisualShaderNodeUIntConstant_property_constant: + +.. rst-class:: classref-property + +:ref:`int` **constant** = ``0`` + +.. rst-class:: classref-property-setget + +- void **set_constant** **(** :ref:`int` value **)** +- :ref:`int` **get_constant** **(** **)** + +An unsigned integer constant which represents a state of 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.)` +.. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` +.. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)` +.. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)` +.. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)` diff --git a/classes/class_visualshadernodeuintfunc.rst b/classes/class_visualshadernodeuintfunc.rst new file mode 100644 index 000000000..9329b60a2 --- /dev/null +++ b/classes/class_visualshadernodeuintfunc.rst @@ -0,0 +1,102 @@ +:github_url: hide + +.. DO NOT EDIT THIS FILE!!! +.. Generated automatically from Godot engine sources. +.. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py. +.. XML source: https://github.com/godotengine/godot/tree/master/doc/classes/VisualShaderNodeUIntFunc.xml. + +.. _class_VisualShaderNodeUIntFunc: + +VisualShaderNodeUIntFunc +======================== + +**Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` + +An unsigned scalar integer function to be used within the visual shader graph. + +.. rst-class:: classref-introduction-group + +Description +----------- + +Accept an unsigned integer scalar (``x``) to the input port and transform it according to :ref:`function`. + +.. rst-class:: classref-reftable-group + +Properties +---------- + +.. table:: + :widths: auto + + +---------------------------------------------------------+-------------------------------------------------------------------+-------+ + | :ref:`Function` | :ref:`function` | ``0`` | + +---------------------------------------------------------+-------------------------------------------------------------------+-------+ + +.. rst-class:: classref-section-separator + +---- + +.. rst-class:: classref-descriptions-group + +Enumerations +------------ + +.. _enum_VisualShaderNodeUIntFunc_Function: + +.. rst-class:: classref-enumeration + +enum **Function**: + +.. _class_VisualShaderNodeUIntFunc_constant_FUNC_NEGATE: + +.. rst-class:: classref-enumeration-constant + +:ref:`Function` **FUNC_NEGATE** = ``0`` + +Negates the ``x`` using ``-(x)``. + +.. _class_VisualShaderNodeUIntFunc_constant_FUNC_BITWISE_NOT: + +.. rst-class:: classref-enumeration-constant + +:ref:`Function` **FUNC_BITWISE_NOT** = ``1`` + +Returns the result of bitwise ``NOT`` operation on the integer. Translates to ``~a`` in the Godot Shader Language. + +.. _class_VisualShaderNodeUIntFunc_constant_FUNC_MAX: + +.. rst-class:: classref-enumeration-constant + +:ref:`Function` **FUNC_MAX** = ``2`` + +Represents the size of the :ref:`Function` enum. + +.. rst-class:: classref-section-separator + +---- + +.. rst-class:: classref-descriptions-group + +Property Descriptions +--------------------- + +.. _class_VisualShaderNodeUIntFunc_property_function: + +.. rst-class:: classref-property + +:ref:`Function` **function** = ``0`` + +.. rst-class:: classref-property-setget + +- void **set_function** **(** :ref:`Function` value **)** +- :ref:`Function` **get_function** **(** **)** + +A function to be applied to the scalar. See :ref:`Function` for options. + +.. |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.)` +.. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)` +.. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)` +.. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)` diff --git a/classes/class_visualshadernodeuintop.rst b/classes/class_visualshadernodeuintop.rst new file mode 100644 index 000000000..37c86132c --- /dev/null +++ b/classes/class_visualshadernodeuintop.rst @@ -0,0 +1,182 @@ +:github_url: hide + +.. DO NOT EDIT THIS FILE!!! +.. Generated automatically from Godot engine sources. +.. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py. +.. XML source: https://github.com/godotengine/godot/tree/master/doc/classes/VisualShaderNodeUIntOp.xml. + +.. _class_VisualShaderNodeUIntOp: + +VisualShaderNodeUIntOp +====================== + +**Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` + +An unsigned integer scalar operator to be used within the visual shader graph. + +.. rst-class:: classref-introduction-group + +Description +----------- + +Applies :ref:`operator` to two unsigned integer inputs: ``a`` and ``b``. + +.. rst-class:: classref-reftable-group + +Properties +---------- + +.. table:: + :widths: auto + + +-------------------------------------------------------+-----------------------------------------------------------------+-------+ + | :ref:`Operator` | :ref:`operator` | ``0`` | + +-------------------------------------------------------+-----------------------------------------------------------------+-------+ + +.. rst-class:: classref-section-separator + +---- + +.. rst-class:: classref-descriptions-group + +Enumerations +------------ + +.. _enum_VisualShaderNodeUIntOp_Operator: + +.. rst-class:: classref-enumeration + +enum **Operator**: + +.. _class_VisualShaderNodeUIntOp_constant_OP_ADD: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_ADD** = ``0`` + +Sums two numbers using ``a + b``. + +.. _class_VisualShaderNodeUIntOp_constant_OP_SUB: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_SUB** = ``1`` + +Subtracts two numbers using ``a - b``. + +.. _class_VisualShaderNodeUIntOp_constant_OP_MUL: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_MUL** = ``2`` + +Multiplies two numbers using ``a * b``. + +.. _class_VisualShaderNodeUIntOp_constant_OP_DIV: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_DIV** = ``3`` + +Divides two numbers using ``a / b``. + +.. _class_VisualShaderNodeUIntOp_constant_OP_MOD: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_MOD** = ``4`` + +Calculates the remainder of two numbers using ``a % b``. + +.. _class_VisualShaderNodeUIntOp_constant_OP_MAX: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_MAX** = ``5`` + +Returns the greater of two numbers. Translates to ``max(a, b)`` in the Godot Shader Language. + +.. _class_VisualShaderNodeUIntOp_constant_OP_MIN: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_MIN** = ``6`` + +Returns the lesser of two numbers. Translates to ``max(a, b)`` in the Godot Shader Language. + +.. _class_VisualShaderNodeUIntOp_constant_OP_BITWISE_AND: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_BITWISE_AND** = ``7`` + +Returns the result of bitwise ``AND`` operation on the integer. Translates to ``a & b`` in the Godot Shader Language. + +.. _class_VisualShaderNodeUIntOp_constant_OP_BITWISE_OR: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_BITWISE_OR** = ``8`` + +Returns the result of bitwise ``OR`` operation for two integers. Translates to ``a | b`` in the Godot Shader Language. + +.. _class_VisualShaderNodeUIntOp_constant_OP_BITWISE_XOR: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_BITWISE_XOR** = ``9`` + +Returns the result of bitwise ``XOR`` operation for two integers. Translates to ``a ^ b`` in the Godot Shader Language. + +.. _class_VisualShaderNodeUIntOp_constant_OP_BITWISE_LEFT_SHIFT: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_BITWISE_LEFT_SHIFT** = ``10`` + +Returns the result of bitwise left shift operation on the integer. Translates to ``a << b`` in the Godot Shader Language. + +.. _class_VisualShaderNodeUIntOp_constant_OP_BITWISE_RIGHT_SHIFT: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_BITWISE_RIGHT_SHIFT** = ``11`` + +Returns the result of bitwise right shift operation on the integer. Translates to ``a >> b`` in the Godot Shader Language. + +.. _class_VisualShaderNodeUIntOp_constant_OP_ENUM_SIZE: + +.. rst-class:: classref-enumeration-constant + +:ref:`Operator` **OP_ENUM_SIZE** = ``12`` + +Represents the size of the :ref:`Operator` enum. + +.. rst-class:: classref-section-separator + +---- + +.. rst-class:: classref-descriptions-group + +Property Descriptions +--------------------- + +.. _class_VisualShaderNodeUIntOp_property_operator: + +.. rst-class:: classref-property + +:ref:`Operator` **operator** = ``0`` + +.. rst-class:: classref-property-setget + +- void **set_operator** **(** :ref:`Operator` value **)** +- :ref:`Operator` **get_operator** **(** **)** + +An operator to be applied to the inputs. See :ref:`Operator` for options. + +.. |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.)` +.. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)` +.. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)` +.. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)` diff --git a/classes/class_visualshadernodeuintparameter.rst b/classes/class_visualshadernodeuintparameter.rst new file mode 100644 index 000000000..b4a7cc1b7 --- /dev/null +++ b/classes/class_visualshadernodeuintparameter.rst @@ -0,0 +1,82 @@ +:github_url: hide + +.. DO NOT EDIT THIS FILE!!! +.. Generated automatically from Godot engine sources. +.. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py. +.. XML source: https://github.com/godotengine/godot/tree/master/doc/classes/VisualShaderNodeUIntParameter.xml. + +.. _class_VisualShaderNodeUIntParameter: + +VisualShaderNodeUIntParameter +============================= + +**Inherits:** :ref:`VisualShaderNodeParameter` **<** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` + +A visual shader node for shader parameter (uniform) of type unsigned :ref:`int`. + +.. rst-class:: classref-introduction-group + +Description +----------- + +A :ref:`VisualShaderNodeParameter` of type unsigned :ref:`int`. Offers additional customization for range of accepted values. + +.. rst-class:: classref-reftable-group + +Properties +---------- + +.. table:: + :widths: auto + + +-------------------------+--------------------------------------------------------------------------------------------------+-----------+ + | :ref:`int` | :ref:`default_value` | ``0`` | + +-------------------------+--------------------------------------------------------------------------------------------------+-----------+ + | :ref:`bool` | :ref:`default_value_enabled` | ``false`` | + +-------------------------+--------------------------------------------------------------------------------------------------+-----------+ + +.. rst-class:: classref-section-separator + +---- + +.. rst-class:: classref-descriptions-group + +Property Descriptions +--------------------- + +.. _class_VisualShaderNodeUIntParameter_property_default_value: + +.. rst-class:: classref-property + +:ref:`int` **default_value** = ``0`` + +.. rst-class:: classref-property-setget + +- void **set_default_value** **(** :ref:`int` value **)** +- :ref:`int` **get_default_value** **(** **)** + +Default value of this parameter, which will be used if not set externally. :ref:`default_value_enabled` must be enabled; defaults to ``0`` otherwise. + +.. rst-class:: classref-item-separator + +---- + +.. _class_VisualShaderNodeUIntParameter_property_default_value_enabled: + +.. rst-class:: classref-property + +:ref:`bool` **default_value_enabled** = ``false`` + +.. rst-class:: classref-property-setget + +- void **set_default_value_enabled** **(** :ref:`bool` value **)** +- :ref:`bool` **is_default_value_enabled** **(** **)** + +If ``true``, the node will have a custom default value. + +.. |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.)` +.. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)` +.. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)` +.. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)` diff --git a/classes/class_visualshadernodeuvfunc.rst b/classes/class_visualshadernodeuvfunc.rst index 056173187..a20805755 100644 --- a/classes/class_visualshadernodeuvfunc.rst +++ b/classes/class_visualshadernodeuvfunc.rst @@ -14,6 +14,13 @@ VisualShaderNodeUVFunc Contains functions to modify texture coordinates (``uv``) to be used within the visual shader graph. +.. rst-class:: classref-introduction-group + +Description +----------- + +UV functions are similar to :ref:`Vector2` functions, but the input port of this node uses the shader's UV value by default. + .. rst-class:: classref-reftable-group Properties diff --git a/classes/class_visualshadernodeuvpolarcoord.rst b/classes/class_visualshadernodeuvpolarcoord.rst index 454af6f60..2ea80c522 100644 --- a/classes/class_visualshadernodeuvpolarcoord.rst +++ b/classes/class_visualshadernodeuvpolarcoord.rst @@ -12,9 +12,14 @@ VisualShaderNodeUVPolarCoord **Inherits:** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that modifies the texture UV using polar coordinates. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +UV polar coord node will transform UV values into polar coordinates, with specified scale, zoom strength and repeat parameters. It can be used to create various swirl distortions. .. |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_visualshadernodevarying.rst b/classes/class_visualshadernodevarying.rst index b29e2ecba..b1e410511 100644 --- a/classes/class_visualshadernodevarying.rst +++ b/classes/class_visualshadernodevarying.rst @@ -14,9 +14,14 @@ VisualShaderNodeVarying **Inherited By:** :ref:`VisualShaderNodeVaryingGetter`, :ref:`VisualShaderNodeVaryingSetter` -.. container:: contribute +A visual shader node that represents a "varying" shader value. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +Varying values are shader variables that can be passed between shader functions, e.g. from Vertex shader to Fragment shader. .. rst-class:: classref-reftable-group @@ -52,9 +57,7 @@ Property Descriptions - void **set_varying_name** **(** :ref:`String` value **)** - :ref:`String` **get_varying_name** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +Name of the variable. Must be unique. .. rst-class:: classref-item-separator @@ -71,9 +74,7 @@ Property Descriptions - void **set_varying_type** **(** :ref:`VaryingType` value **)** - :ref:`VaryingType` **get_varying_type** **(** **)** -.. container:: contribute - - There is currently no description for this property. Please help us by :ref:`contributing one `! +Type of the variable. Determines where the variable can be accessed. .. |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_visualshadernodevaryinggetter.rst b/classes/class_visualshadernodevaryinggetter.rst index dcc229bd1..dff606d5c 100644 --- a/classes/class_visualshadernodevaryinggetter.rst +++ b/classes/class_visualshadernodevaryinggetter.rst @@ -12,9 +12,14 @@ VisualShaderNodeVaryingGetter **Inherits:** :ref:`VisualShaderNodeVarying` **<** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that gets a value of a varying. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +Outputs a value of a varying defined in the shader. You need to first create a varying that can be used in the given function, e.g. varying getter in Fragment shader requires a varying with mode set to :ref:`VisualShader.VARYING_MODE_VERTEX_TO_FRAG_LIGHT`. .. |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_visualshadernodevaryingsetter.rst b/classes/class_visualshadernodevaryingsetter.rst index 5073b8249..6abf42d16 100644 --- a/classes/class_visualshadernodevaryingsetter.rst +++ b/classes/class_visualshadernodevaryingsetter.rst @@ -12,9 +12,14 @@ VisualShaderNodeVaryingSetter **Inherits:** :ref:`VisualShaderNodeVarying` **<** :ref:`VisualShaderNode` **<** :ref:`Resource` **<** :ref:`RefCounted` **<** :ref:`Object` -.. container:: contribute +A visual shader node that sets a value of a varying. - There is currently no description for this class. Please help us by :ref:`contributing one `! +.. rst-class:: classref-introduction-group + +Description +----------- + +Inputs a value to a varying defined in the shader. You need to first create a varying that can be used in the given function, e.g. varying setter in Fragment shader requires a varying with mode set to :ref:`VisualShader.VARYING_MODE_FRAG_TO_LIGHT`. .. |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_visualshadernodevectorbase.rst b/classes/class_visualshadernodevectorbase.rst index 0f9fe20fd..cf55fd02a 100644 --- a/classes/class_visualshadernodevectorbase.rst +++ b/classes/class_visualshadernodevectorbase.rst @@ -14,7 +14,14 @@ VisualShaderNodeVectorBase **Inherited By:** :ref:`VisualShaderNodeFaceForward`, :ref:`VisualShaderNodeVectorCompose`, :ref:`VisualShaderNodeVectorDecompose`, :ref:`VisualShaderNodeVectorDistance`, :ref:`VisualShaderNodeVectorFunc`, :ref:`VisualShaderNodeVectorLen`, :ref:`VisualShaderNodeVectorOp`, :ref:`VisualShaderNodeVectorRefract` -A base type for the nodes using different vector types within the visual shader graph. +A base type for the nodes that perform vector operations within the visual shader graph. + +.. rst-class:: classref-introduction-group + +Description +----------- + +This is an abstract class. See the derived types for descriptions of the possible operations. .. rst-class:: classref-reftable-group @@ -95,7 +102,7 @@ Property Descriptions - void **set_op_type** **(** :ref:`OpType` value **)** - :ref:`OpType` **get_op_type** **(** **)** -A base type. +A vector type that this operation is performed on. .. |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_vscrollbar.rst b/classes/class_vscrollbar.rst index f2b53989e..97ea17a34 100644 --- a/classes/class_vscrollbar.rst +++ b/classes/class_vscrollbar.rst @@ -29,11 +29,11 @@ Properties .. table:: :widths: auto - +-----------------------+-----------------------+--------------------------------------------------------------------------------+ - | :ref:`int` | size_flags_horizontal | ``0`` (overrides :ref:`Control`) | - +-----------------------+-----------------------+--------------------------------------------------------------------------------+ - | :ref:`int` | size_flags_vertical | ``1`` (overrides :ref:`Control`) | - +-----------------------+-----------------------+--------------------------------------------------------------------------------+ + +------------------------------------------+-----------------------+--------------------------------------------------------------------------------+ + | :ref:`SizeFlags` | size_flags_horizontal | ``0`` (overrides :ref:`Control`) | + +------------------------------------------+-----------------------+--------------------------------------------------------------------------------+ + | :ref:`SizeFlags` | size_flags_vertical | ``1`` (overrides :ref:`Control`) | + +------------------------------------------+-----------------------+--------------------------------------------------------------------------------+ .. rst-class:: classref-reftable-group diff --git a/classes/class_vslider.rst b/classes/class_vslider.rst index f89b9922b..bfa079f57 100644 --- a/classes/class_vslider.rst +++ b/classes/class_vslider.rst @@ -31,11 +31,11 @@ Properties .. table:: :widths: auto - +-----------------------+-----------------------+--------------------------------------------------------------------------------+ - | :ref:`int` | size_flags_horizontal | ``0`` (overrides :ref:`Control`) | - +-----------------------+-----------------------+--------------------------------------------------------------------------------+ - | :ref:`int` | size_flags_vertical | ``1`` (overrides :ref:`Control`) | - +-----------------------+-----------------------+--------------------------------------------------------------------------------+ + +------------------------------------------+-----------------------+--------------------------------------------------------------------------------+ + | :ref:`SizeFlags` | size_flags_horizontal | ``0`` (overrides :ref:`Control`) | + +------------------------------------------+-----------------------+--------------------------------------------------------------------------------+ + | :ref:`SizeFlags` | size_flags_vertical | ``1`` (overrides :ref:`Control`) | + +------------------------------------------+-----------------------+--------------------------------------------------------------------------------+ .. rst-class:: classref-reftable-group diff --git a/classes/class_window.rst b/classes/class_window.rst index aa1a5c469..4987299a3 100644 --- a/classes/class_window.rst +++ b/classes/class_window.rst @@ -33,57 +33,59 @@ Properties .. table:: :widths: auto - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`always_on_top` | ``false`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`auto_translate` | ``true`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`borderless` | ``false`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`ContentScaleAspect` | :ref:`content_scale_aspect` | ``0`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`float` | :ref:`content_scale_factor` | ``1.0`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`ContentScaleMode` | :ref:`content_scale_mode` | ``0`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`Vector2i` | :ref:`content_scale_size` | ``Vector2i(0, 0)`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`int` | :ref:`current_screen` | ``0`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`exclusive` | ``false`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`extend_to_title` | ``false`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`Vector2i` | :ref:`max_size` | ``Vector2i(0, 0)`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`Vector2i` | :ref:`min_size` | ``Vector2i(0, 0)`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`Mode` | :ref:`mode` | ``0`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`popup_window` | ``false`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`Vector2i` | :ref:`position` | ``Vector2i(0, 0)`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`Vector2i` | :ref:`size` | ``Vector2i(100, 100)`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`Theme` | :ref:`theme` | | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`StringName` | :ref:`theme_type_variation` | ``&""`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`String` | :ref:`title` | ``""`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`transient` | ``false`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`transparent` | ``false`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`unfocusable` | ``false`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`unresizable` | ``false`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`visible` | ``true`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ - | :ref:`bool` | :ref:`wrap_controls` | ``false`` | - +-----------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`always_on_top` | ``false`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`auto_translate` | ``true`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`borderless` | ``false`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`ContentScaleAspect` | :ref:`content_scale_aspect` | ``0`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`float` | :ref:`content_scale_factor` | ``1.0`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`ContentScaleMode` | :ref:`content_scale_mode` | ``0`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`Vector2i` | :ref:`content_scale_size` | ``Vector2i(0, 0)`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`int` | :ref:`current_screen` | | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`exclusive` | ``false`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`extend_to_title` | ``false`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`WindowInitialPosition` | :ref:`initial_position` | ``0`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`Vector2i` | :ref:`max_size` | ``Vector2i(0, 0)`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`Vector2i` | :ref:`min_size` | ``Vector2i(0, 0)`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`Mode` | :ref:`mode` | ``0`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`popup_window` | ``false`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`Vector2i` | :ref:`position` | ``Vector2i(0, 0)`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`Vector2i` | :ref:`size` | ``Vector2i(100, 100)`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`Theme` | :ref:`theme` | | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`StringName` | :ref:`theme_type_variation` | ``&""`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`String` | :ref:`title` | ``""`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`transient` | ``false`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`transparent` | ``false`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`unfocusable` | ``false`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`unresizable` | ``false`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`visible` | ``true`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ + | :ref:`bool` | :ref:`wrap_controls` | ``false`` | + +-----------------------------------------------------------------+-------------------------------------------------------------------------+------------------------+ .. rst-class:: classref-reftable-group @@ -683,6 +685,32 @@ Left-to-right layout direction. Right-to-left layout direction. +.. rst-class:: classref-item-separator + +---- + +.. _enum_Window_WindowInitialPosition: + +.. rst-class:: classref-enumeration + +enum **WindowInitialPosition**: + +.. _class_Window_constant_WINDOW_INITIAL_POSITION_ABSOLUTE: + +.. rst-class:: classref-enumeration-constant + +:ref:`WindowInitialPosition` **WINDOW_INITIAL_POSITION_ABSOLUTE** = ``0`` + + + +.. _class_Window_constant_WINDOW_INITIAL_POSITION_CENTER_SCREEN: + +.. rst-class:: classref-enumeration-constant + +:ref:`WindowInitialPosition` **WINDOW_INITIAL_POSITION_CENTER_SCREEN** = ``1`` + + + .. rst-class:: classref-section-separator ---- @@ -848,7 +876,7 @@ Base size of the content (i.e. nodes that are drawn inside the window). If non-z .. rst-class:: classref-property -:ref:`int` **current_screen** = ``0`` +:ref:`int` **current_screen** .. rst-class:: classref-property-setget @@ -897,6 +925,25 @@ If ``true``, the **Window** contents is expanded to the full size of the window, ---- +.. _class_Window_property_initial_position: + +.. rst-class:: classref-property + +:ref:`WindowInitialPosition` **initial_position** = ``0`` + +.. rst-class:: classref-property-setget + +- void **set_initial_position** **(** :ref:`WindowInitialPosition` value **)** +- :ref:`WindowInitialPosition` **get_initial_position** **(** **)** + +.. container:: contribute + + There is currently no description for this property. Please help us by :ref:`contributing one `! + +.. rst-class:: classref-item-separator + +---- + .. _class_Window_property_max_size: .. rst-class:: classref-property diff --git a/classes/index.rst b/classes/index.rst index 7dc6106ef..a986faf1e 100644 --- a/classes/index.rst +++ b/classes/index.rst @@ -622,6 +622,10 @@ Resources class_visualshadernodetransformop class_visualshadernodetransformparameter class_visualshadernodetransformvecmult + class_visualshadernodeuintconstant + class_visualshadernodeuintfunc + class_visualshadernodeuintop + class_visualshadernodeuintparameter class_visualshadernodeuvfunc class_visualshadernodeuvpolarcoord class_visualshadernodevarying