classref: Sync with current master branch (c64afeb)

This commit is contained in:
Godot Organization
2023-05-13 03:19:02 +00:00
parent 0757559a3a
commit 6febc8ee06
274 changed files with 16684 additions and 4675 deletions

View File

@@ -133,7 +133,7 @@ Mark the following property as exported (editable in the Inspector dock and save
@export var string = ""
@export var int_number = 5
@export var float_number: float = 5
@export var image : Image
@export var image: Image
.. rst-class:: classref-item-separator
@@ -173,7 +173,7 @@ See also :ref:`@GlobalScope.PROPERTY_HINT_COLOR_NO_ALPHA<class_@GlobalScope_cons
::
@export_color_no_alpha var dye_color : Color
@export_color_no_alpha var dye_color: Color
.. rst-class:: classref-item-separator
@@ -418,6 +418,24 @@ See also :ref:`@GlobalScope.PROPERTY_HINT_LAYERS_3D_RENDER<class_@GlobalScope_co
----
.. _class_@GDScript_annotation_@export_flags_avoidance:
.. rst-class:: classref-annotation
**@export_flags_avoidance** **(** **)**
Export an integer property as a bit flag field for navigation avoidance layers. The widget in the Inspector dock will use the layer names defined in :ref:`ProjectSettings.layer_names/avoidance/layer_1<class_ProjectSettings_property_layer_names/avoidance/layer_1>`.
See also :ref:`@GlobalScope.PROPERTY_HINT_LAYERS_AVOIDANCE<class_@GlobalScope_constant_PROPERTY_HINT_LAYERS_AVOIDANCE>`.
::
@export_flags_avoidance var avoidance_layers: int
.. rst-class:: classref-item-separator
----
.. _class_@GDScript_annotation_@export_global_dir:
.. rst-class:: classref-annotation
@@ -465,7 +483,7 @@ See also :ref:`@GlobalScope.PROPERTY_HINT_GLOBAL_FILE<class_@GlobalScope_constan
Define a new group for the following exported properties. This helps to organize properties in the Inspector dock. Groups can be added with an optional ``prefix``, which would make group to only consider properties that have this prefix. The grouping will break on the first property that doesn't have a prefix. The prefix is also removed from the property's name in the Inspector dock.
If no ``prefix`` is provided, the every following property is added to the group. The group ends when then next group or category is defined. You can also force end a group by using this annotation with empty strings for parameters, ``@export_group("", "")``.
If no ``prefix`` is provided, then every following property will be added to the group. The group ends when then next group or category is defined. You can also force end a group by using this annotation with empty strings for parameters, ``@export_group("", "")``.
Groups cannot be nested, use :ref:`@export_subgroup<class_@GDScript_annotation_@export_subgroup>` to add subgroups within groups.
@@ -662,6 +680,18 @@ The order of ``mode``, ``sync`` and ``transfer_mode`` does not matter and all ar
----
.. _class_@GDScript_annotation_@static_unload:
.. rst-class:: classref-annotation
**@static_unload** **(** **)**
Make a script with static variables to not persist after all references are lost. If the script is loaded again the static variables will revert to their default values.
.. rst-class:: classref-item-separator
----
.. _class_@GDScript_annotation_@tool:
.. rst-class:: classref-annotation
@@ -712,7 +742,7 @@ Method Descriptions
:ref:`Color<class_Color>` **Color8** **(** :ref:`int<class_int>` r8, :ref:`int<class_int>` g8, :ref:`int<class_int>` b8, :ref:`int<class_int>` a8=255 **)**
Returns a :ref:`Color<class_Color>` constructed from red (``r8``), green (``g8``), blue (``b8``), and optionally alpha (``a8``) integer channels, each divided by ``255.0`` for their final value.
Returns a :ref:`Color<class_Color>` constructed from red (``r8``), green (``g8``), blue (``b8``), and optionally alpha (``a8``) integer channels, each divided by ``255.0`` for their final value. Using :ref:`Color8<class_@GDScript_method_Color8>` instead of the standard :ref:`Color<class_Color>` constructor is useful when you need to match exact color values in an :ref:`Image<class_Image>`.
::
@@ -720,6 +750,8 @@ Returns a :ref:`Color<class_Color>` constructed from red (``r8``), green (``g8``
var dark_blue = Color8(0, 0, 51) # Same as Color(0, 0, 0.2).
var my_color = Color8(306, 255, 0, 102) # Same as Color(1.2, 1, 0, 0.4).
\ **Note:** Due to the lower precision of :ref:`Color8<class_@GDScript_method_Color8>` compared to the standard :ref:`Color<class_Color>` constructor, a color created with :ref:`Color8<class_@GDScript_method_Color8>` will generally not be equal to the same color created with the standard :ref:`Color<class_Color>` constructor. Use :ref:`Color.is_equal_approx<class_Color_method_is_equal_approx>` for comparisons to avoid issues with floating-point precision error.
.. rst-class:: classref-item-separator
----
@@ -887,7 +919,7 @@ Examples:
print(is_instance_of(a, MyClass))
print(is_instance_of(a, MyClass.InnerClass))
\ **Note:** If ``value`` and/or ``type`` are freed objects (see :ref:`@GlobalScope.is_instance_valid<class_@GlobalScope_method_is_instance_valid>`), or ``type`` is not one of the above options, this method will raise an runtime error.
\ **Note:** If ``value`` and/or ``type`` are freed objects (see :ref:`@GlobalScope.is_instance_valid<class_@GlobalScope_method_is_instance_valid>`), or ``type`` is not one of the above options, this method will raise a runtime error.
See also :ref:`@GlobalScope.typeof<class_@GlobalScope_method_typeof>`, :ref:`type_exists<class_@GDScript_method_type_exists>`, :ref:`Array.is_same_typed<class_Array_method_is_same_typed>` (and other :ref:`Array<class_Array>` methods).
@@ -936,6 +968,8 @@ This function is a simplified version of :ref:`ResourceLoader.load<class_Resourc
\ **Note:** Files have to be imported into the engine first to load them using this function. If you want to load :ref:`Image<class_Image>`\ s at run-time, you may use :ref:`Image.load<class_Image_method_load>`. If you want to import audio files, you can use the snippet described in :ref:`AudioStreamMP3.data<class_AudioStreamMP3_property_data>`.
\ **Note:** If :ref:`ProjectSettings.editor/export/convert_text_resources_to_binary<class_ProjectSettings_property_editor/export/convert_text_resources_to_binary>` is ``true``, :ref:`load<class_@GDScript_method_load>` will not be able to read converted files in an exported project. If you rely on run-time loading of files present within the PCK, set :ref:`ProjectSettings.editor/export/convert_text_resources_to_binary<class_ProjectSettings_property_editor/export/convert_text_resources_to_binary>` to ``false``.
.. rst-class:: classref-item-separator
----
@@ -1034,8 +1068,8 @@ To iterate over an :ref:`Array<class_Array>` backwards, use:
::
var array = [3, 6, 9]
for i in range(array.size(), 0, -1):
print(array[i - 1])
for i in range(array.size() - 1, -1, -1):
print(array[i])
Output:

View File

@@ -3509,6 +3509,14 @@ Hints that an :ref:`int<class_int>` property is a bitmask using the optionally n
Hints that an :ref:`int<class_int>` property is a bitmask using the optionally named 3D navigation layers.
.. _class_@GlobalScope_constant_PROPERTY_HINT_LAYERS_AVOIDANCE:
.. rst-class:: classref-enumeration-constant
:ref:`PropertyHint<enum_@GlobalScope_PropertyHint>` **PROPERTY_HINT_LAYERS_AVOIDANCE** = ``37``
Hints that an integer property is a bitmask using the optionally named avoidance layers.
.. _class_@GlobalScope_constant_PROPERTY_HINT_FILE:
.. rst-class:: classref-enumeration-constant
@@ -3714,7 +3722,7 @@ Hints that a string property is a password, and every character is replaced with
.. rst-class:: classref-enumeration-constant
:ref:`PropertyHint<enum_@GlobalScope_PropertyHint>` **PROPERTY_HINT_MAX** = ``37``
:ref:`PropertyHint<enum_@GlobalScope_PropertyHint>` **PROPERTY_HINT_MAX** = ``38``
Represents the size of the :ref:`PropertyHint<enum_@GlobalScope_PropertyHint>` enum.
@@ -3758,7 +3766,7 @@ The property is shown in the :ref:`EditorInspector<class_EditorInspector>` (defa
:ref:`PropertyUsageFlags<enum_@GlobalScope_PropertyUsageFlags>` **PROPERTY_USAGE_INTERNAL** = ``8``
The property is excluded from the class reference.
.. _class_@GlobalScope_constant_PROPERTY_USAGE_CHECKABLE:
@@ -3960,6 +3968,14 @@ The property is only shown in the editor if modern renderers are supported (the
The property is read-only in the :ref:`EditorInspector<class_EditorInspector>`.
.. _class_@GlobalScope_constant_PROPERTY_USAGE_SECRET:
.. rst-class:: classref-enumeration-constant
:ref:`PropertyUsageFlags<enum_@GlobalScope_PropertyUsageFlags>` **PROPERTY_USAGE_SECRET** = ``536870912``
An export preset property with this flag contains confidential information and is stored separately from the rest of the export preset configuration.
.. _class_@GlobalScope_constant_PROPERTY_USAGE_DEFAULT:
.. rst-class:: classref-enumeration-constant
@@ -5114,7 +5130,7 @@ Returns the absolute value of int parameter ``x`` (i.e. positive value).
:ref:`float<class_float>` **acos** **(** :ref:`float<class_float>` x **)**
Returns the arc cosine of ``x`` in radians. Use to get the angle of cosine ``x``. ``x`` must be between ``-1.0`` and ``1.0`` (inclusive), otherwise, :ref:`acos<class_@GlobalScope_method_acos>` will return :ref:`@GDScript.NAN<class_@GDScript_constant_NAN>`.
Returns the arc cosine of ``x`` in radians. Use to get the angle of cosine ``x``. ``x`` will be clamped between ``-1.0`` and ``1.0`` (inclusive), in order to prevent :ref:`acos<class_@GlobalScope_method_acos>` from returning :ref:`@GDScript.NAN<class_@GDScript_constant_NAN>`.
::
@@ -5131,7 +5147,7 @@ Returns the arc cosine of ``x`` in radians. Use to get the angle of cosine ``x``
:ref:`float<class_float>` **asin** **(** :ref:`float<class_float>` x **)**
Returns the arc sine of ``x`` in radians. Use to get the angle of sine ``x``. ``x`` must be between ``-1.0`` and ``1.0`` (inclusive), otherwise, :ref:`asin<class_@GlobalScope_method_asin>` will return :ref:`@GDScript.NAN<class_@GDScript_constant_NAN>`.
Returns the arc sine of ``x`` in radians. Use to get the angle of sine ``x``. ``x`` will be clamped between ``-1.0`` and ``1.0`` (inclusive), in order to prevent :ref:`asin<class_@GlobalScope_method_asin>` from returning :ref:`@GDScript.NAN<class_@GDScript_constant_NAN>`.
::
@@ -5904,7 +5920,7 @@ Linearly interpolates between two values by the factor defined in ``weight``. To
::
lerp(0, 4, 0.75) # Returns 3.0
lerpf(0, 4, 0.75) # Returns 3.0
See also :ref:`inverse_lerp<class_@GlobalScope_method_inverse_lerp>` which performs the reverse of this operation. To perform eased interpolation with :ref:`lerp<class_@GlobalScope_method_lerp>`, combine it with :ref:`ease<class_@GlobalScope_method_ease>` or :ref:`smoothstep<class_@GlobalScope_method_smoothstep>`.
@@ -5939,9 +5955,9 @@ Converts from linear energy to decibels (audio). This can be used to implement v
:ref:`float<class_float>` **log** **(** :ref:`float<class_float>` x **)**
Returns the natural logarithm of ``x``. This is the amount of time needed to reach a certain level of continuous growth.
Returns the `natural logarithm <https://en.wikipedia.org/wiki/Natural_logarithm>`__ of ``x`` (base `[i]e[/i] <https://en.wikipedia.org/wiki/E_(mathematical_constant)>`__, with *e* being approximately 2.71828). This is the amount of time needed to reach a certain level of continuous growth.
\ **Note:** This is not the same as the "log" function on most calculators, which uses a base 10 logarithm.
\ **Note:** This is not the same as the "log" function on most calculators, which uses a base 10 logarithm. To use base 10 logarithm, use ``log(x) / log(10)``.
::
@@ -6208,25 +6224,33 @@ Converts one or more arguments of any type to string in the best way possible an
void **print_rich** **(** ... **)** |vararg|
Converts one or more arguments of any type to string in the best way possible and prints them to the console. The following BBCode tags are supported: b, i, u, s, indent, code, url, center, right, color, bgcolor, fgcolor. Color tags only support named colors such as ``red``, *not* hexadecimal color codes. Unsupported tags will be left as-is in standard output.
Converts one or more arguments of any type to string in the best way possible and prints them to the console.
When printing to standard output, the supported subset of BBCode is converted to ANSI escape codes for the terminal emulator to display. Displaying ANSI escape codes is currently only supported on Linux and macOS. Support for ANSI escape codes may vary across terminal emulators, especially for italic and strikethrough.
The following BBCode tags are supported: ``b``, ``i``, ``u``, ``s``, ``indent``, ``code``, ``url``, ``center``, ``right``, ``color``, ``bgcolor``, ``fgcolor``.
Color tags only support the following named colors: ``black``, ``red``, ``green``, ``yellow``, ``blue``, ``magenta``, ``pink``, ``purple``, ``cyan``, ``white``, ``orange``, ``gray``. Hexadecimal color codes are not supported.
URL tags only support URLs wrapped by an URL tag, not URLs with a different title.
When printing to standard output, the supported subset of BBCode is converted to ANSI escape codes for the terminal emulator to display. Support for ANSI escape codes varies across terminal emulators, especially for italic and strikethrough. In standard output, ``code`` is represented with faint text but without any font change. Unsupported tags are left as-is in standard output.
.. tabs::
.. code-tab:: gdscript
print_rich("[code][b]Hello world![/b][/code]") # Prints out: [b]Hello world![/b]
print_rich("[color=green][b]Hello world![/b][/color]") # Prints out "Hello world!" in green with a bold font
.. code-tab:: csharp
GD.PrintRich("[code][b]Hello world![/b][/code]"); // Prints out: [b]Hello world![/b]
GD.PrintRich("[color=green][b]Hello world![/b][/color]"); // Prints out "Hello world!" in green with a bold font
\ **Note:** Consider using :ref:`push_error<class_@GlobalScope_method_push_error>` and :ref:`push_warning<class_@GlobalScope_method_push_warning>` to print error and warning messages instead of :ref:`print<class_@GlobalScope_method_print>` or :ref:`print_rich<class_@GlobalScope_method_print_rich>`. This distinguishes them from print messages used for debugging purposes, while also displaying a stack trace when an error or warning is printed.
\ **Note:** On Windows, only Windows 10 and later correctly displays ANSI escape codes in standard output.
.. rst-class:: classref-item-separator
----
@@ -6735,9 +6759,9 @@ Returns ``-1.0`` if ``x`` is negative, ``1.0`` if ``x`` is positive, and ``0.0``
::
sign(-6.5) # Returns -1.0
sign(0.0) # Returns 0.0
sign(6.5) # Returns 1.0
signf(-6.5) # Returns -1.0
signf(0.0) # Returns 0.0
signf(6.5) # Returns 1.0
.. rst-class:: classref-item-separator
@@ -6753,9 +6777,9 @@ Returns ``-1`` if ``x`` is negative, ``1`` if ``x`` is positive, and ``0`` if if
::
sign(-6) # Returns -1
sign(0) # Returns 0
sign(6) # Returns 1
signi(-6) # Returns -1
signi(0) # Returns 0
signi(6) # Returns 1
.. rst-class:: classref-item-separator
@@ -6859,8 +6883,8 @@ A type-safe version of :ref:`snapped<class_@GlobalScope_method_snapped>`, return
::
snapped(32.0, 2.5) # Returns 32.5
snapped(3.14159, 0.01) # Returns 3.14
snappedf(32.0, 2.5) # Returns 32.5
snappedf(3.14159, 0.01) # Returns 3.14
.. rst-class:: classref-item-separator
@@ -6878,8 +6902,8 @@ A type-safe version of :ref:`snapped<class_@GlobalScope_method_snapped>`, return
::
snapped(53, 16) # Returns 48
snapped(4096, 100) # Returns 4100
snappedi(53, 16) # Returns 48
snappedi(4096, 100) # Returns 4100
.. rst-class:: classref-item-separator

View File

@@ -502,7 +502,7 @@ Returns ``true`` if the **AABB** is on both sides of a plane.
:ref:`Variant<class_Variant>` **intersects_ray** **(** :ref:`Vector3<class_Vector3>` from, :ref:`Vector3<class_Vector3>` dir **)** |const|
Returns ``true`` if the given ray intersects with this **AABB**. Ray length is infinite.
Returns the point of intersection of the given ray with this **AABB** or ``null`` if there is no intersection. Ray length is infinite.
.. rst-class:: classref-item-separator
@@ -514,7 +514,7 @@ Returns ``true`` if the given ray intersects with this **AABB**. Ray length is i
:ref:`Variant<class_Variant>` **intersects_segment** **(** :ref:`Vector3<class_Vector3>` from, :ref:`Vector3<class_Vector3>` to **)** |const|
Returns ``true`` if the **AABB** intersects the line segment between ``from`` and ``to``.
Returns the point of intersection between ``from`` and ``to`` with this **AABB** or ``null`` if there is no intersection.
.. rst-class:: classref-item-separator
@@ -567,7 +567,7 @@ Operator Descriptions
:ref:`bool<class_bool>` **operator !=** **(** :ref:`AABB<class_AABB>` right **)**
Returns ``true`` if the vectors are not equal.
Returns ``true`` if the AABBs are not equal.
\ **Note:** Due to floating-point precision errors, consider using :ref:`is_equal_approx<class_AABB_method_is_equal_approx>` instead, which is more reliable.

View File

@@ -34,27 +34,27 @@ This class provides access to AES encryption/decryption of raw data. Both AES-EC
var key = "My secret key!!!" # Key must be either 16 or 32 bytes.
var data = "My secret text!!" # Data size must be multiple of 16 bytes, apply padding if needed.
# Encrypt ECB
aes.start(AESContext.MODE_ECB_ENCRYPT, key.to_utf8())
var encrypted = aes.update(data.to_utf8())
aes.start(AESContext.MODE_ECB_ENCRYPT, key.to_utf8_buffer())
var encrypted = aes.update(data.to_utf8_buffer())
aes.finish()
# Decrypt ECB
aes.start(AESContext.MODE_ECB_DECRYPT, key.to_utf8())
aes.start(AESContext.MODE_ECB_DECRYPT, key.to_utf8_buffer())
var decrypted = aes.update(encrypted)
aes.finish()
# Check ECB
assert(decrypted == data.to_utf8())
assert(decrypted == data.to_utf8_buffer())
var iv = "My secret iv!!!!" # IV must be of exactly 16 bytes.
# Encrypt CBC
aes.start(AESContext.MODE_CBC_ENCRYPT, key.to_utf8(), iv.to_utf8())
encrypted = aes.update(data.to_utf8())
aes.start(AESContext.MODE_CBC_ENCRYPT, key.to_utf8_buffer(), iv.to_utf8_buffer())
encrypted = aes.update(data.to_utf8_buffer())
aes.finish()
# Decrypt CBC
aes.start(AESContext.MODE_CBC_DECRYPT, key.to_utf8(), iv.to_utf8())
aes.start(AESContext.MODE_CBC_DECRYPT, key.to_utf8_buffer(), iv.to_utf8_buffer())
decrypted = aes.update(encrypted)
aes.finish()
# Check CBC
assert(decrypted == data.to_utf8())
assert(decrypted == data.to_utf8_buffer())
.. code-tab:: csharp
@@ -70,27 +70,27 @@ This class provides access to AES encryption/decryption of raw data. Both AES-EC
string key = "My secret key!!!"; // Key must be either 16 or 32 bytes.
string data = "My secret text!!"; // Data size must be multiple of 16 bytes, apply padding if needed.
// Encrypt ECB
_aes.Start(AesContext.Mode.EcbEncrypt, key.ToUtf8());
byte[] encrypted = _aes.Update(data.ToUtf8());
_aes.Start(AesContext.Mode.EcbEncrypt, key.ToUtf8Buffer());
byte[] encrypted = _aes.Update(data.ToUtf8Buffer());
_aes.Finish();
// Decrypt ECB
_aes.Start(AesContext.Mode.EcbDecrypt, key.ToUtf8());
_aes.Start(AesContext.Mode.EcbDecrypt, key.ToUtf8Buffer());
byte[] decrypted = _aes.Update(encrypted);
_aes.Finish();
// Check ECB
Debug.Assert(decrypted == data.ToUtf8());
Debug.Assert(decrypted == data.ToUtf8Buffer());
string iv = "My secret iv!!!!"; // IV must be of exactly 16 bytes.
// Encrypt CBC
_aes.Start(AesContext.Mode.EcbEncrypt, key.ToUtf8(), iv.ToUtf8());
encrypted = _aes.Update(data.ToUtf8());
_aes.Start(AesContext.Mode.EcbEncrypt, key.ToUtf8Buffer(), iv.ToUtf8Buffer());
encrypted = _aes.Update(data.ToUtf8Buffer());
_aes.Finish();
// Decrypt CBC
_aes.Start(AesContext.Mode.EcbDecrypt, key.ToUtf8(), iv.ToUtf8());
_aes.Start(AesContext.Mode.EcbDecrypt, key.ToUtf8Buffer(), iv.ToUtf8Buffer());
decrypted = _aes.Update(encrypted);
_aes.Finish();
// Check CBC
Debug.Assert(decrypted == data.ToUtf8());
Debug.Assert(decrypted == data.ToUtf8Buffer());
}
}

View File

@@ -12,7 +12,7 @@ AnimatableBody2D
**Inherits:** :ref:`StaticBody2D<class_StaticBody2D>` **<** :ref:`PhysicsBody2D<class_PhysicsBody2D>` **<** :ref:`CollisionObject2D<class_CollisionObject2D>` **<** :ref:`Node2D<class_Node2D>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
Physics body for 2D physics which moves only by script or animation. Useful for moving platforms and doors.
Physics body for 2D physics which moves only by script or animation (while affecting other bodies on its path). Useful for moving platforms and doors.
.. rst-class:: classref-introduction-group

View File

@@ -12,7 +12,7 @@ AnimatableBody3D
**Inherits:** :ref:`StaticBody3D<class_StaticBody3D>` **<** :ref:`PhysicsBody3D<class_PhysicsBody3D>` **<** :ref:`CollisionObject3D<class_CollisionObject3D>` **<** :ref:`Node3D<class_Node3D>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
Physics body for 3D physics which moves only by script or animation. Useful for moving platforms and doors.
Physics body for 3D physics which moves only by script or animation (while affecting other bodies on its path). Useful for moving platforms and doors.
.. rst-class:: classref-introduction-group

View File

@@ -12,14 +12,14 @@ Animation
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Contains data used to animate everything in the engine.
Holds data that can be used to animate anything in the engine.
.. rst-class:: classref-introduction-group
Description
-----------
An Animation resource contains data used to animate everything in the engine. Animations are divided into tracks, and each track must be linked to a node. The state of that node can be changed through time, by adding timed keys (events) to the track.
This resource holds data that can be used to animate anything in the engine. Animations are divided into tracks and each track must be linked to a node. The state of that node can be changed through time, by adding timed keys (events) to the track.
.. tabs::
@@ -126,6 +126,8 @@ Methods
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`blend_shape_track_insert_key<class_Animation_method_blend_shape_track_insert_key>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`float<class_float>` amount **)** |
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`blend_shape_track_interpolate<class_Animation_method_blend_shape_track_interpolate>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const| |
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`clear<class_Animation_method_clear>` **(** **)** |
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`compress<class_Animation_method_compress>` **(** :ref:`int<class_int>` page_size=8192, :ref:`int<class_int>` fps=120, :ref:`float<class_float>` split_tolerance=4.0 **)** |
@@ -142,12 +144,18 @@ Methods
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`position_track_insert_key<class_Animation_method_position_track_insert_key>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`Vector3<class_Vector3>` position **)** |
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Vector3<class_Vector3>` | :ref:`position_track_interpolate<class_Animation_method_position_track_interpolate>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const| |
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`remove_track<class_Animation_method_remove_track>` **(** :ref:`int<class_int>` track_idx **)** |
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`rotation_track_insert_key<class_Animation_method_rotation_track_insert_key>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`Quaternion<class_Quaternion>` rotation **)** |
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Quaternion<class_Quaternion>` | :ref:`rotation_track_interpolate<class_Animation_method_rotation_track_interpolate>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const| |
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`scale_track_insert_key<class_Animation_method_scale_track_insert_key>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`Vector3<class_Vector3>` scale **)** |
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Vector3<class_Vector3>` | :ref:`scale_track_interpolate<class_Animation_method_scale_track_interpolate>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const| |
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`track_find_key<class_Animation_method_track_find_key>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`FindMode<enum_Animation_FindMode>` find_mode=0 **)** |const| |
+------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`track_get_interpolation_loop_wrap<class_Animation_method_track_get_interpolation_loop_wrap>` **(** :ref:`int<class_int>` track_idx **)** |const| |
@@ -825,6 +833,18 @@ Inserts a key in a given blend shape track. Returns the key index.
----
.. _class_Animation_method_blend_shape_track_interpolate:
.. rst-class:: classref-method
:ref:`float<class_float>` **blend_shape_track_interpolate** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const|
Returns the interpolated blend shape value at the given time (in seconds). The ``track_idx`` must be the index of a blend shape track.
.. rst-class:: classref-item-separator
----
.. _class_Animation_method_clear:
.. rst-class:: classref-method
@@ -923,6 +943,18 @@ Inserts a key in a given 3D position track. Returns the key index.
----
.. _class_Animation_method_position_track_interpolate:
.. rst-class:: classref-method
:ref:`Vector3<class_Vector3>` **position_track_interpolate** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const|
Returns the interpolated position value at the given time (in seconds). The ``track_idx`` must be the index of a 3D position track.
.. rst-class:: classref-item-separator
----
.. _class_Animation_method_remove_track:
.. rst-class:: classref-method
@@ -947,6 +979,18 @@ Inserts a key in a given 3D rotation track. Returns the key index.
----
.. _class_Animation_method_rotation_track_interpolate:
.. rst-class:: classref-method
:ref:`Quaternion<class_Quaternion>` **rotation_track_interpolate** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const|
Returns the interpolated rotation value at the given time (in seconds). The ``track_idx`` must be the index of a 3D rotation track.
.. rst-class:: classref-item-separator
----
.. _class_Animation_method_scale_track_insert_key:
.. rst-class:: classref-method
@@ -959,6 +1003,18 @@ Inserts a key in a given 3D scale track. Returns the key index.
----
.. _class_Animation_method_scale_track_interpolate:
.. rst-class:: classref-method
:ref:`Vector3<class_Vector3>` **scale_track_interpolate** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const|
Returns the interpolated scale value at the given time (in seconds). The ``track_idx`` must be the index of a 3D scale track.
.. rst-class:: classref-item-separator
----
.. _class_Animation_method_track_find_key:
.. rst-class:: classref-method

View File

@@ -14,7 +14,7 @@ AnimationNode
**Inherited By:** :ref:`AnimationNodeOutput<class_AnimationNodeOutput>`, :ref:`AnimationNodeSync<class_AnimationNodeSync>`, :ref:`AnimationNodeTimeScale<class_AnimationNodeTimeScale>`, :ref:`AnimationNodeTimeSeek<class_AnimationNodeTimeSeek>`, :ref:`AnimationRootNode<class_AnimationRootNode>`
Base resource for :ref:`AnimationTree<class_AnimationTree>` nodes.
Base class for :ref:`AnimationTree<class_AnimationTree>` nodes. Not related to scene nodes.
.. rst-class:: classref-introduction-group
@@ -30,7 +30,7 @@ Inherit this when creating nodes mainly for use in :ref:`AnimationNodeBlendTree<
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
.. rst-class:: classref-reftable-group
@@ -52,49 +52,49 @@ Methods
.. table::
:widths: auto
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`_get_caption<class_AnimationNode_method__get_caption>` **(** **)** |virtual| |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`AnimationNode<class_AnimationNode>` | :ref:`_get_child_by_name<class_AnimationNode_method__get_child_by_name>` **(** :ref:`StringName<class_StringName>` name **)** |virtual| |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Dictionary<class_Dictionary>` | :ref:`_get_child_nodes<class_AnimationNode_method__get_child_nodes>` **(** **)** |virtual| |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Variant<class_Variant>` | :ref:`_get_parameter_default_value<class_AnimationNode_method__get_parameter_default_value>` **(** :ref:`StringName<class_StringName>` parameter **)** |virtual| |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Array<class_Array>` | :ref:`_get_parameter_list<class_AnimationNode_method__get_parameter_list>` **(** **)** |virtual| |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_has_filter<class_AnimationNode_method__has_filter>` **(** **)** |virtual| |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_is_parameter_read_only<class_AnimationNode_method__is_parameter_read_only>` **(** :ref:`StringName<class_StringName>` parameter **)** |virtual| |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`_process<class_AnimationNode_method__process>` **(** :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking **)** |virtual| |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`add_input<class_AnimationNode_method_add_input>` **(** :ref:`String<class_String>` name **)** |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`blend_animation<class_AnimationNode_method_blend_animation>` **(** :ref:`StringName<class_StringName>` animation, :ref:`float<class_float>` time, :ref:`float<class_float>` delta, :ref:`bool<class_bool>` seeked, :ref:`bool<class_bool>` is_external_seeking, :ref:`float<class_float>` blend, :ref:`LoopedFlag<enum_Animation_LoopedFlag>` looped_flag=0 **)** |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`blend_input<class_AnimationNode_method_blend_input>` **(** :ref:`int<class_int>` input_index, :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking, :ref:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` sync=true **)** |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`blend_node<class_AnimationNode_method_blend_node>` **(** :ref:`StringName<class_StringName>` name, :ref:`AnimationNode<class_AnimationNode>` node, :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking, :ref:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` sync=true **)** |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`find_input<class_AnimationNode_method_find_input>` **(** :ref:`String<class_String>` name **)** |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_input_count<class_AnimationNode_method_get_input_count>` **(** **)** |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_input_name<class_AnimationNode_method_get_input_name>` **(** :ref:`int<class_int>` input **)** |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Variant<class_Variant>` | :ref:`get_parameter<class_AnimationNode_method_get_parameter>` **(** :ref:`StringName<class_StringName>` name **)** |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`is_path_filtered<class_AnimationNode_method_is_path_filtered>` **(** :ref:`NodePath<class_NodePath>` path **)** |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`remove_input<class_AnimationNode_method_remove_input>` **(** :ref:`int<class_int>` index **)** |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`set_filter_path<class_AnimationNode_method_set_filter_path>` **(** :ref:`NodePath<class_NodePath>` path, :ref:`bool<class_bool>` enable **)** |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`set_input_name<class_AnimationNode_method_set_input_name>` **(** :ref:`int<class_int>` input, :ref:`String<class_String>` name **)** |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`set_parameter<class_AnimationNode_method_set_parameter>` **(** :ref:`StringName<class_StringName>` name, :ref:`Variant<class_Variant>` value **)** |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`_get_caption<class_AnimationNode_method__get_caption>` **(** **)** |virtual| |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`AnimationNode<class_AnimationNode>` | :ref:`_get_child_by_name<class_AnimationNode_method__get_child_by_name>` **(** :ref:`StringName<class_StringName>` name **)** |virtual| |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Dictionary<class_Dictionary>` | :ref:`_get_child_nodes<class_AnimationNode_method__get_child_nodes>` **(** **)** |virtual| |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Variant<class_Variant>` | :ref:`_get_parameter_default_value<class_AnimationNode_method__get_parameter_default_value>` **(** :ref:`StringName<class_StringName>` parameter **)** |virtual| |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Array<class_Array>` | :ref:`_get_parameter_list<class_AnimationNode_method__get_parameter_list>` **(** **)** |virtual| |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_has_filter<class_AnimationNode_method__has_filter>` **(** **)** |virtual| |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_is_parameter_read_only<class_AnimationNode_method__is_parameter_read_only>` **(** :ref:`StringName<class_StringName>` parameter **)** |virtual| |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`_process<class_AnimationNode_method__process>` **(** :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking, :ref:`bool<class_bool>` test_only **)** |virtual| |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`add_input<class_AnimationNode_method_add_input>` **(** :ref:`String<class_String>` name **)** |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`blend_animation<class_AnimationNode_method_blend_animation>` **(** :ref:`StringName<class_StringName>` animation, :ref:`float<class_float>` time, :ref:`float<class_float>` delta, :ref:`bool<class_bool>` seeked, :ref:`bool<class_bool>` is_external_seeking, :ref:`float<class_float>` blend, :ref:`LoopedFlag<enum_Animation_LoopedFlag>` looped_flag=0 **)** |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`blend_input<class_AnimationNode_method_blend_input>` **(** :ref:`int<class_int>` input_index, :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking, :ref:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` sync=true, :ref:`bool<class_bool>` test_only=false **)** |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`blend_node<class_AnimationNode_method_blend_node>` **(** :ref:`StringName<class_StringName>` name, :ref:`AnimationNode<class_AnimationNode>` node, :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking, :ref:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` sync=true, :ref:`bool<class_bool>` test_only=false **)** |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`find_input<class_AnimationNode_method_find_input>` **(** :ref:`String<class_String>` name **)** |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_input_count<class_AnimationNode_method_get_input_count>` **(** **)** |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_input_name<class_AnimationNode_method_get_input_name>` **(** :ref:`int<class_int>` input **)** |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Variant<class_Variant>` | :ref:`get_parameter<class_AnimationNode_method_get_parameter>` **(** :ref:`StringName<class_StringName>` name **)** |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`is_path_filtered<class_AnimationNode_method_is_path_filtered>` **(** :ref:`NodePath<class_NodePath>` path **)** |const| |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`remove_input<class_AnimationNode_method_remove_input>` **(** :ref:`int<class_int>` index **)** |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`set_filter_path<class_AnimationNode_method_set_filter_path>` **(** :ref:`NodePath<class_NodePath>` path, :ref:`bool<class_bool>` enable **)** |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`set_input_name<class_AnimationNode_method_set_input_name>` **(** :ref:`int<class_int>` input, :ref:`String<class_String>` name **)** |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`set_parameter<class_AnimationNode_method_set_parameter>` **(** :ref:`StringName<class_StringName>` name, :ref:`Variant<class_Variant>` value **)** |
+-------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
@@ -303,7 +303,7 @@ When inheriting from :ref:`AnimationRootNode<class_AnimationRootNode>`, implemen
.. rst-class:: classref-method
:ref:`float<class_float>` **_process** **(** :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking **)** |virtual| |const|
:ref:`float<class_float>` **_process** **(** :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking, :ref:`bool<class_bool>` test_only **)** |virtual| |const|
When inheriting from :ref:`AnimationRootNode<class_AnimationRootNode>`, implement this virtual method to run some code when this node is processed. The ``time`` parameter is a relative delta, unless ``seek`` is ``true``, in which case it is absolute.
@@ -345,7 +345,7 @@ A ``looped_flag`` is used by internal processing immediately after the loop. See
.. rst-class:: classref-method
:ref:`float<class_float>` **blend_input** **(** :ref:`int<class_int>` input_index, :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking, :ref:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` sync=true **)**
:ref:`float<class_float>` **blend_input** **(** :ref:`int<class_int>` input_index, :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking, :ref:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` sync=true, :ref:`bool<class_bool>` test_only=false **)**
Blend an input. This is only useful for nodes created for an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. The ``time`` parameter is a relative delta, unless ``seek`` is ``true``, in which case it is absolute. A filter mode may be optionally passed (see :ref:`FilterAction<enum_AnimationNode_FilterAction>` for options).
@@ -357,7 +357,7 @@ Blend an input. This is only useful for nodes created for an :ref:`AnimationNode
.. rst-class:: classref-method
:ref:`float<class_float>` **blend_node** **(** :ref:`StringName<class_StringName>` name, :ref:`AnimationNode<class_AnimationNode>` node, :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking, :ref:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` sync=true **)**
:ref:`float<class_float>` **blend_node** **(** :ref:`StringName<class_StringName>` name, :ref:`AnimationNode<class_AnimationNode>` node, :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`bool<class_bool>` is_external_seeking, :ref:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` sync=true, :ref:`bool<class_bool>` test_only=false **)**
Blend another animation node (in case this node contains children animation nodes). This function is only useful if you inherit from :ref:`AnimationRootNode<class_AnimationRootNode>` instead, else editors will not display your node for addition.

View File

@@ -26,7 +26,7 @@ A resource to add to an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTre
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
.. |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.)`

View File

@@ -34,7 +34,7 @@ This node has three inputs:
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__

View File

@@ -12,21 +12,21 @@ AnimationNodeAnimation
**Inherits:** :ref:`AnimationRootNode<class_AnimationRootNode>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Input animation to use in an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
An input animation for an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
.. rst-class:: classref-introduction-group
Description
-----------
A resource to add to an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. Only features one output set using the :ref:`animation<class_AnimationNodeAnimation_property_animation>` property. Use it as an input for :ref:`AnimationNode<class_AnimationNode>` that blend animations together.
A resource to add to an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. Only has one output port using the :ref:`animation<class_AnimationNodeAnimation_property_animation>` property. Used as an input for :ref:`AnimationNode<class_AnimationNode>`\ s that blend animations together.
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__

View File

@@ -26,7 +26,7 @@ A resource to add to an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTre
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__

View File

@@ -34,7 +34,7 @@ This node has three inputs:
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
.. |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.)`

View File

@@ -12,27 +12,25 @@ AnimationNodeBlendSpace1D
**Inherits:** :ref:`AnimationRootNode<class_AnimationRootNode>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Blends linearly between two of any number of :ref:`AnimationNode<class_AnimationNode>` of any type placed on a virtual axis.
A set of :ref:`AnimationRootNode<class_AnimationRootNode>`\ s placed on a virtual axis, crossfading between the two adjacent ones. Used by :ref:`AnimationTree<class_AnimationTree>`.
.. rst-class:: classref-introduction-group
Description
-----------
A resource to add to an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
A resource used by :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
This is a virtual axis on which you can add any type of :ref:`AnimationNode<class_AnimationNode>` using :ref:`add_blend_point<class_AnimationNodeBlendSpace1D_method_add_blend_point>`.
\ **AnimationNodeBlendSpace1D** represents a virtual axis on which any type of :ref:`AnimationRootNode<class_AnimationRootNode>`\ s can be added using :ref:`add_blend_point<class_AnimationNodeBlendSpace1D_method_add_blend_point>`. Outputs the linear blend of the two :ref:`AnimationRootNode<class_AnimationRootNode>`\ s adjacent to the current value.
Outputs the linear blend of the two :ref:`AnimationNode<class_AnimationNode>`\ s closest to the node's current value.
You can set the extents of the axis using the :ref:`min_space<class_AnimationNodeBlendSpace1D_property_min_space>` and :ref:`max_space<class_AnimationNodeBlendSpace1D_property_max_space>`.
You can set the extents of the axis with :ref:`min_space<class_AnimationNodeBlendSpace1D_property_min_space>` and :ref:`max_space<class_AnimationNodeBlendSpace1D_property_max_space>`.
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
.. rst-class:: classref-reftable-group

View File

@@ -12,25 +12,25 @@ AnimationNodeBlendSpace2D
**Inherits:** :ref:`AnimationRootNode<class_AnimationRootNode>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Blends linearly between three :ref:`AnimationNode<class_AnimationNode>` of any type placed in a 2D space.
A set of :ref:`AnimationRootNode<class_AnimationRootNode>`\ s placed on 2D coordinates, crossfading between the three adjacent ones. Used by :ref:`AnimationTree<class_AnimationTree>`.
.. rst-class:: classref-introduction-group
Description
-----------
A resource to add to an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
A resource used by :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
This node allows you to blend linearly between three animations using a :ref:`Vector2<class_Vector2>` weight.
\ :ref:`AnimationNodeBlendSpace1D<class_AnimationNodeBlendSpace1D>` represents a virtual 2D space on which :ref:`AnimationRootNode<class_AnimationRootNode>`\ s are placed. Outputs the linear blend of the three adjacent animations using a :ref:`Vector2<class_Vector2>` weight. Adjacent in this context means the three :ref:`AnimationRootNode<class_AnimationRootNode>`\ s making up the triangle that contains the current value.
You can add vertices to the blend space with :ref:`add_blend_point<class_AnimationNodeBlendSpace2D_method_add_blend_point>` and automatically triangulate it by setting :ref:`auto_triangles<class_AnimationNodeBlendSpace2D_property_auto_triangles>` to ``true``. Otherwise, use :ref:`add_triangle<class_AnimationNodeBlendSpace2D_method_add_triangle>` and :ref:`remove_triangle<class_AnimationNodeBlendSpace2D_method_remove_triangle>` to create up the blend space by hand.
You can add vertices to the blend space with :ref:`add_blend_point<class_AnimationNodeBlendSpace2D_method_add_blend_point>` and automatically triangulate it by setting :ref:`auto_triangles<class_AnimationNodeBlendSpace2D_property_auto_triangles>` to ``true``. Otherwise, use :ref:`add_triangle<class_AnimationNodeBlendSpace2D_method_add_triangle>` and :ref:`remove_triangle<class_AnimationNodeBlendSpace2D_method_remove_triangle>` to triangulate the blend space by hand.
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__

View File

@@ -12,14 +12,14 @@ AnimationNodeBlendTree
**Inherits:** :ref:`AnimationRootNode<class_AnimationRootNode>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
:ref:`AnimationTree<class_AnimationTree>` node resource that contains many blend type nodes.
A sub-tree of blend type :ref:`AnimationNode<class_AnimationNode>`\ s used for complex animations. Used by :ref:`AnimationTree<class_AnimationTree>`.
.. rst-class:: classref-introduction-group
Description
-----------
This node may contain a sub-tree of any other blend type nodes, such as :ref:`AnimationNodeTransition<class_AnimationNodeTransition>`, :ref:`AnimationNodeBlend2<class_AnimationNodeBlend2>`, :ref:`AnimationNodeBlend3<class_AnimationNodeBlend3>`, :ref:`AnimationNodeOneShot<class_AnimationNodeOneShot>`, etc. This is one of the most commonly used roots.
This node may contain a sub-tree of any other blend type nodes, such as :ref:`AnimationNodeTransition<class_AnimationNodeTransition>`, :ref:`AnimationNodeBlend2<class_AnimationNodeBlend2>`, :ref:`AnimationNodeBlend3<class_AnimationNodeBlend3>`, :ref:`AnimationNodeOneShot<class_AnimationNodeOneShot>`, etc. This is one of the most commonly used animation node roots.
An :ref:`AnimationNodeOutput<class_AnimationNodeOutput>` node named ``output`` is created by default.
@@ -28,7 +28,7 @@ An :ref:`AnimationNodeOutput<class_AnimationNodeOutput>` node named ``output`` i
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
.. rst-class:: classref-reftable-group

View File

@@ -12,7 +12,7 @@ AnimationNodeOneShot
**Inherits:** :ref:`AnimationNodeSync<class_AnimationNodeSync>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Plays an animation once in :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
Plays an animation once in an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
.. rst-class:: classref-introduction-group
@@ -61,7 +61,7 @@ After setting the request and changing the animation playback, the one-shot node
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__

View File

@@ -12,14 +12,21 @@ AnimationNodeOutput
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Generic output node to be added to :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
The animation output node of an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
.. rst-class:: classref-introduction-group
Description
-----------
A node created automatically in an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>` that outputs the final animation.
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__

View File

@@ -12,14 +12,14 @@ AnimationNodeStateMachine
**Inherits:** :ref:`AnimationRootNode<class_AnimationRootNode>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
State machine for control of animations.
A state machine with multiple :ref:`AnimationRootNode<class_AnimationRootNode>`\ s, used by :ref:`AnimationTree<class_AnimationTree>`.
.. rst-class:: classref-introduction-group
Description
-----------
Contains multiple nodes representing animation states, connected in a graph. Node transitions can be configured to happen automatically or via code, using a shortest-path algorithm. Retrieve the :ref:`AnimationNodeStateMachinePlayback<class_AnimationNodeStateMachinePlayback>` object from the :ref:`AnimationTree<class_AnimationTree>` node to control it programmatically.
Contains multiple :ref:`AnimationRootNode<class_AnimationRootNode>`\ s representing animation states, connected in a graph. Node transitions can be configured to happen automatically or via code, using a shortest-path algorithm. Retrieve the :ref:`AnimationNodeStateMachinePlayback<class_AnimationNodeStateMachinePlayback>` object from the :ref:`AnimationTree<class_AnimationTree>` node to control it programmatically.
\ **Example:**\
@@ -43,7 +43,7 @@ Contains multiple nodes representing animation states, connected in a graph. Nod
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
.. rst-class:: classref-reftable-group
@@ -53,9 +53,13 @@ Properties
.. table::
:widths: auto
+-------------------------+----------------------------------------------------------------------------------------------------+-----------+
| :ref:`bool<class_bool>` | :ref:`allow_transition_to_self<class_AnimationNodeStateMachine_property_allow_transition_to_self>` | ``false`` |
+-------------------------+----------------------------------------------------------------------------------------------------+-----------+
+--------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------+
| :ref:`bool<class_bool>` | :ref:`allow_transition_to_self<class_AnimationNodeStateMachine_property_allow_transition_to_self>` | ``false`` |
+--------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------+
| :ref:`bool<class_bool>` | :ref:`reset_ends<class_AnimationNodeStateMachine_property_reset_ends>` | ``false`` |
+--------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------+
| :ref:`StateMachineType<enum_AnimationNodeStateMachine_StateMachineType>` | :ref:`state_machine_type<class_AnimationNodeStateMachine_property_state_machine_type>` | ``0`` |
+--------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------+-----------+
.. rst-class:: classref-reftable-group
@@ -111,6 +115,45 @@ Methods
.. rst-class:: classref-descriptions-group
Enumerations
------------
.. _enum_AnimationNodeStateMachine_StateMachineType:
.. rst-class:: classref-enumeration
enum **StateMachineType**:
.. _class_AnimationNodeStateMachine_constant_STATE_MACHINE_TYPE_ROOT:
.. rst-class:: classref-enumeration-constant
:ref:`StateMachineType<enum_AnimationNodeStateMachine_StateMachineType>` **STATE_MACHINE_TYPE_ROOT** = ``0``
Seeking to the beginning is treated as playing from the start state. Transition to the end state is treated as exiting the state machine.
.. _class_AnimationNodeStateMachine_constant_STATE_MACHINE_TYPE_NESTED:
.. rst-class:: classref-enumeration-constant
:ref:`StateMachineType<enum_AnimationNodeStateMachine_StateMachineType>` **STATE_MACHINE_TYPE_NESTED** = ``1``
Seeking to the beginning is treated as seeking to the beginning of the animation in the current state. Transition to the end state, or the absence of transitions in each state, is treated as exiting the state machine.
.. _class_AnimationNodeStateMachine_constant_STATE_MACHINE_TYPE_GROUPED:
.. rst-class:: classref-enumeration-constant
:ref:`StateMachineType<enum_AnimationNodeStateMachine_StateMachineType>` **STATE_MACHINE_TYPE_GROUPED** = ``2``
This is a grouped state machine that can be controlled from a parent state machine. It does not work on standalone. There must be a state machine with :ref:`state_machine_type<class_AnimationNodeStateMachine_property_state_machine_type>` of :ref:`STATE_MACHINE_TYPE_ROOT<class_AnimationNodeStateMachine_constant_STATE_MACHINE_TYPE_ROOT>` or :ref:`STATE_MACHINE_TYPE_NESTED<class_AnimationNodeStateMachine_constant_STATE_MACHINE_TYPE_NESTED>` in the parent or ancestor.
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Property Descriptions
---------------------
@@ -127,6 +170,42 @@ Property Descriptions
If ``true``, allows teleport to the self state with :ref:`AnimationNodeStateMachinePlayback.travel<class_AnimationNodeStateMachinePlayback_method_travel>`. When the reset option is enabled in :ref:`AnimationNodeStateMachinePlayback.travel<class_AnimationNodeStateMachinePlayback_method_travel>`, the animation is restarted. If ``false``, nothing happens on the teleportation to the self state.
.. rst-class:: classref-item-separator
----
.. _class_AnimationNodeStateMachine_property_reset_ends:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **reset_ends** = ``false``
.. rst-class:: classref-property-setget
- void **set_reset_ends** **(** :ref:`bool<class_bool>` value **)**
- :ref:`bool<class_bool>` **are_ends_reset** **(** **)**
If ``true``, treat the cross-fade to the start and end nodes as a blend with the RESET animation.
In most cases, when additional cross-fades are performed in the parent :ref:`AnimationNode<class_AnimationNode>` of the state machine, setting this property to ``false`` and matching the cross-fade time of the parent :ref:`AnimationNode<class_AnimationNode>` and the state machine's start node and end node gives good results.
.. rst-class:: classref-item-separator
----
.. _class_AnimationNodeStateMachine_property_state_machine_type:
.. rst-class:: classref-property
:ref:`StateMachineType<enum_AnimationNodeStateMachine_StateMachineType>` **state_machine_type** = ``0``
.. rst-class:: classref-property-setget
- void **set_state_machine_type** **(** :ref:`StateMachineType<enum_AnimationNodeStateMachine_StateMachineType>` value **)**
- :ref:`StateMachineType<enum_AnimationNodeStateMachine_StateMachineType>` **get_state_machine_type** **(** **)**
This property can define the process of transitions for different use cases. See also :ref:`StateMachineType<enum_AnimationNodeStateMachine_StateMachineType>`.
.. rst-class:: classref-section-separator
----

View File

@@ -12,7 +12,7 @@ AnimationNodeStateMachinePlayback
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Playback control for :ref:`AnimationNodeStateMachine<class_AnimationNodeStateMachine>`.
Provides playback control for an :ref:`AnimationNodeStateMachine<class_AnimationNodeStateMachine>`.
.. rst-class:: classref-introduction-group
@@ -43,7 +43,7 @@ Allows control of :ref:`AnimationTree<class_AnimationTree>` state machines creat
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
.. rst-class:: classref-reftable-group
@@ -65,27 +65,27 @@ Methods
.. table::
:widths: auto
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`get_current_length<class_AnimationNodeStateMachinePlayback_method_get_current_length>` **(** **)** |const| |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`StringName<class_StringName>` | :ref:`get_current_node<class_AnimationNodeStateMachinePlayback_method_get_current_node>` **(** **)** |const| |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`get_current_play_position<class_AnimationNodeStateMachinePlayback_method_get_current_play_position>` **(** **)** |const| |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`StringName<class_StringName>` | :ref:`get_fading_from_node<class_AnimationNodeStateMachinePlayback_method_get_fading_from_node>` **(** **)** |const| |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`PackedStringArray<class_PackedStringArray>` | :ref:`get_travel_path<class_AnimationNodeStateMachinePlayback_method_get_travel_path>` **(** **)** |const| |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`is_playing<class_AnimationNodeStateMachinePlayback_method_is_playing>` **(** **)** |const| |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`next<class_AnimationNodeStateMachinePlayback_method_next>` **(** **)** |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`start<class_AnimationNodeStateMachinePlayback_method_start>` **(** :ref:`StringName<class_StringName>` node, :ref:`bool<class_bool>` reset=true **)** |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`stop<class_AnimationNodeStateMachinePlayback_method_stop>` **(** **)** |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`travel<class_AnimationNodeStateMachinePlayback_method_travel>` **(** :ref:`StringName<class_StringName>` to_node, :ref:`bool<class_bool>` reset_on_teleport=true **)** |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`get_current_length<class_AnimationNodeStateMachinePlayback_method_get_current_length>` **(** **)** |const| |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`StringName<class_StringName>` | :ref:`get_current_node<class_AnimationNodeStateMachinePlayback_method_get_current_node>` **(** **)** |const| |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`get_current_play_position<class_AnimationNodeStateMachinePlayback_method_get_current_play_position>` **(** **)** |const| |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`StringName<class_StringName>` | :ref:`get_fading_from_node<class_AnimationNodeStateMachinePlayback_method_get_fading_from_node>` **(** **)** |const| |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`StringName[]<class_StringName>` | :ref:`get_travel_path<class_AnimationNodeStateMachinePlayback_method_get_travel_path>` **(** **)** |const| |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`is_playing<class_AnimationNodeStateMachinePlayback_method_is_playing>` **(** **)** |const| |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`next<class_AnimationNodeStateMachinePlayback_method_next>` **(** **)** |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`start<class_AnimationNodeStateMachinePlayback_method_start>` **(** :ref:`StringName<class_StringName>` node, :ref:`bool<class_bool>` reset=true **)** |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`stop<class_AnimationNodeStateMachinePlayback_method_stop>` **(** **)** |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`travel<class_AnimationNodeStateMachinePlayback_method_travel>` **(** :ref:`StringName<class_StringName>` to_node, :ref:`bool<class_bool>` reset_on_teleport=true **)** |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
@@ -152,7 +152,7 @@ Returns the starting state of currently fading animation.
.. rst-class:: classref-method
:ref:`PackedStringArray<class_PackedStringArray>` **get_travel_path** **(** **)** |const|
:ref:`StringName[]<class_StringName>` **get_travel_path** **(** **)** |const|
Returns the current travel path as computed internally by the A\* algorithm.

View File

@@ -12,7 +12,7 @@ AnimationNodeStateMachineTransition
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
A resource to connect each node to make a path for :ref:`AnimationNodeStateMachine<class_AnimationNodeStateMachine>`.
A transition within an :ref:`AnimationNodeStateMachine<class_AnimationNodeStateMachine>` connecting two :ref:`AnimationRootNode<class_AnimationRootNode>`\ s.
.. rst-class:: classref-introduction-group
@@ -28,7 +28,7 @@ You can set the timing and conditions of the transition in detail.
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
.. rst-class:: classref-reftable-group

View File

@@ -14,7 +14,21 @@ AnimationNodeSync
**Inherited By:** :ref:`AnimationNodeAdd2<class_AnimationNodeAdd2>`, :ref:`AnimationNodeAdd3<class_AnimationNodeAdd3>`, :ref:`AnimationNodeBlend2<class_AnimationNodeBlend2>`, :ref:`AnimationNodeBlend3<class_AnimationNodeBlend3>`, :ref:`AnimationNodeOneShot<class_AnimationNodeOneShot>`, :ref:`AnimationNodeTransition<class_AnimationNodeTransition>`
The base class for :ref:`AnimationNode<class_AnimationNode>` which has more than two input ports and needs to synchronize them.
Base class for :ref:`AnimationNode<class_AnimationNode>`\ s with more than two input ports that must be synchronized.
.. rst-class:: classref-introduction-group
Description
-----------
An animation node used to combine, mix, or blend two or more animations together while keeping them synchronized within an :ref:`AnimationTree<class_AnimationTree>`.
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
.. rst-class:: classref-reftable-group

View File

@@ -12,21 +12,21 @@ AnimationNodeTimeScale
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
A time-scaling animation node to be used with :ref:`AnimationTree<class_AnimationTree>`.
A time-scaling animation node used in :ref:`AnimationTree<class_AnimationTree>`.
.. rst-class:: classref-introduction-group
Description
-----------
Allows scaling the speed of the animation (or reversing it) in any children nodes. Setting it to 0 will pause the animation.
Allows to scale the speed of the animation (or reverse it) in any children :ref:`AnimationNode<class_AnimationNode>`\ s. Setting it to ``0.0`` will pause the animation.
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__

View File

@@ -12,7 +12,7 @@ AnimationNodeTimeSeek
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
A time-seeking animation node to be used with :ref:`AnimationTree<class_AnimationTree>`.
A time-seeking animation node used in :ref:`AnimationTree<class_AnimationTree>`.
.. rst-class:: classref-introduction-group
@@ -53,7 +53,7 @@ After setting the time and changing the animation playback, the time seek node a
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
.. |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.)`

View File

@@ -12,7 +12,7 @@ AnimationNodeTransition
**Inherits:** :ref:`AnimationNodeSync<class_AnimationNodeSync>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
A generic animation transition node for :ref:`AnimationTree<class_AnimationTree>`.
A transition within an :ref:`AnimationTree<class_AnimationTree>` connecting two :ref:`AnimationNode<class_AnimationNode>`\ s.
.. rst-class:: classref-introduction-group
@@ -63,7 +63,7 @@ After setting the request and changing the animation playback, the transition no
Tutorials
---------
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__

View File

@@ -12,20 +12,20 @@ AnimationPlayer
**Inherits:** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
Player of :ref:`Animation<class_Animation>` resources.
A node used for animation playback.
.. rst-class:: classref-introduction-group
Description
-----------
An animation player is used for general-purpose playback of :ref:`Animation<class_Animation>` resources. It contains a dictionary of :ref:`AnimationLibrary<class_AnimationLibrary>` resources and custom blend times between animation transitions.
An animation player is used for general-purpose playback of animations. It contains a dictionary of :ref:`AnimationLibrary<class_AnimationLibrary>` resources and custom blend times between animation transitions.
Some methods and properties use a single key to reference an animation directly. These keys are formatted as the key for the library, followed by a forward slash, then the key for the animation within the library, for example ``"movement/run"``. If the library's key is an empty string (known as the default library), the forward slash is omitted, being the same key used by the library.
\ **AnimationPlayer** is more suited than :ref:`Tween<class_Tween>` for animations where you know the final values in advance. For example, fading a screen in and out is more easily done with an **AnimationPlayer** node thanks to the animation tools provided by the editor. That particular example can also be implemented with a :ref:`Tween<class_Tween>`, but it requires doing everything by code.
\ **AnimationPlayer** is better-suited than :ref:`Tween<class_Tween>` for more complex animations, for example ones with non-trivial timings. It can also be used over :ref:`Tween<class_Tween>` if the animation track editor is more convenient than doing it in code.
Updating the target properties of animations occurs at process time.
Updating the target properties of animations occurs at the process frame.
.. rst-class:: classref-introduction-group
@@ -308,7 +308,7 @@ Property Descriptions
- void **set_assigned_animation** **(** :ref:`String<class_String>` value **)**
- :ref:`String<class_String>` **get_assigned_animation** **(** **)**
If playing, the the current animation's key, otherwise, the animation last played. When set, this changes the animation, but will not play it unless already playing. See also :ref:`current_animation<class_AnimationPlayer_property_current_animation>`.
If playing, the current animation's key, otherwise, the animation last played. When set, this changes the animation, but will not play it unless already playing. See also :ref:`current_animation<class_AnimationPlayer_property_current_animation>`.
.. rst-class:: classref-item-separator

View File

@@ -14,7 +14,21 @@ AnimationRootNode
**Inherited By:** :ref:`AnimationNodeAnimation<class_AnimationNodeAnimation>`, :ref:`AnimationNodeBlendSpace1D<class_AnimationNodeBlendSpace1D>`, :ref:`AnimationNodeBlendSpace2D<class_AnimationNodeBlendSpace2D>`, :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`, :ref:`AnimationNodeStateMachine<class_AnimationNodeStateMachine>`
The :ref:`AnimationNode<class_AnimationNode>` which can be set as the root of an :ref:`AnimationTree<class_AnimationTree>`.
Base class for :ref:`AnimationNode<class_AnimationNode>`\ s that hold one or multiple composite animations. Usually used for :ref:`AnimationTree.tree_root<class_AnimationTree_property_tree_root>`.
.. rst-class:: classref-introduction-group
Description
-----------
**AnimationRootNode** is a base class for :ref:`AnimationNode<class_AnimationNode>`\ s that hold a complete animation. A complete animation refers to the output of an :ref:`AnimationNodeOutput<class_AnimationNodeOutput>` in an :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>` or the output of another **AnimationRootNode**. Used for :ref:`AnimationTree.tree_root<class_AnimationTree_property_tree_root>` or in other **AnimationRootNode**\ s.
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
.. |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.)`

View File

@@ -12,14 +12,14 @@ AnimationTree
**Inherits:** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
A node to be used for advanced animation transitions in an :ref:`AnimationPlayer<class_AnimationPlayer>`.
A node used for advanced animation transitions in an :ref:`AnimationPlayer<class_AnimationPlayer>`.
.. rst-class:: classref-introduction-group
Description
-----------
A node to be used for advanced animation transitions in an :ref:`AnimationPlayer<class_AnimationPlayer>`.
A node used for advanced animation transitions in an :ref:`AnimationPlayer<class_AnimationPlayer>`.
\ **Note:** When linked with an :ref:`AnimationPlayer<class_AnimationPlayer>`, several properties and methods of the corresponding :ref:`AnimationPlayer<class_AnimationPlayer>` will not function as expected. Playback and transitions should be handled using only the **AnimationTree** and its constituent :ref:`AnimationNode<class_AnimationNode>`\ (s). The :ref:`AnimationPlayer<class_AnimationPlayer>` node should be used solely for adding, deleting, and editing animations.

View File

@@ -75,7 +75,7 @@ Properties
+-------------------------------------------------+---------------------------------------------------------------------------------------+-------------------+
| :ref:`bool<class_bool>` | :ref:`monitoring<class_Area2D_property_monitoring>` | ``true`` |
+-------------------------------------------------+---------------------------------------------------------------------------------------+-------------------+
| :ref:`float<class_float>` | :ref:`priority<class_Area2D_property_priority>` | ``0.0`` |
| :ref:`int<class_int>` | :ref:`priority<class_Area2D_property_priority>` | ``0`` |
+-------------------------------------------------+---------------------------------------------------------------------------------------+-------------------+
.. rst-class:: classref-reftable-group
@@ -551,14 +551,14 @@ If ``true``, the area detects bodies or areas entering and exiting it.
.. rst-class:: classref-property
:ref:`float<class_float>` **priority** = ``0.0``
:ref:`int<class_int>` **priority** = ``0``
.. rst-class:: classref-property-setget
- void **set_priority** **(** :ref:`float<class_float>` value **)**
- :ref:`float<class_float>` **get_priority** **(** **)**
- void **set_priority** **(** :ref:`int<class_int>` value **)**
- :ref:`int<class_int>` **get_priority** **(** **)**
The area's priority. Higher priority areas are processed first.
The area's priority. Higher priority areas are processed first. The :ref:`World2D<class_World2D>`'s physics is always processed last, after all areas.
.. rst-class:: classref-section-separator

View File

@@ -73,7 +73,7 @@ Properties
+-------------------------------------------------+---------------------------------------------------------------------------------------+-----------------------+
| :ref:`bool<class_bool>` | :ref:`monitoring<class_Area3D_property_monitoring>` | ``true`` |
+-------------------------------------------------+---------------------------------------------------------------------------------------+-----------------------+
| :ref:`float<class_float>` | :ref:`priority<class_Area3D_property_priority>` | ``0.0`` |
| :ref:`int<class_int>` | :ref:`priority<class_Area3D_property_priority>` | ``0`` |
+-------------------------------------------------+---------------------------------------------------------------------------------------+-----------------------+
| :ref:`float<class_float>` | :ref:`reverb_bus_amount<class_Area3D_property_reverb_bus_amount>` | ``0.0`` |
+-------------------------------------------------+---------------------------------------------------------------------------------------+-----------------------+
@@ -563,14 +563,14 @@ If ``true``, the area detects bodies or areas entering and exiting it.
.. rst-class:: classref-property
:ref:`float<class_float>` **priority** = ``0.0``
:ref:`int<class_int>` **priority** = ``0``
.. rst-class:: classref-property-setget
- void **set_priority** **(** :ref:`float<class_float>` value **)**
- :ref:`float<class_float>` **get_priority** **(** **)**
- void **set_priority** **(** :ref:`int<class_int>` value **)**
- :ref:`int<class_int>` **get_priority** **(** **)**
The area's priority. Higher priority areas are processed first.
The area's priority. Higher priority areas are processed first. The :ref:`World3D<class_World3D>`'s physics is always processed last, after all areas.
.. rst-class:: classref-item-separator
@@ -689,7 +689,7 @@ The magnitude of area-specific wind force.
- void **set_wind_source_path** **(** :ref:`NodePath<class_NodePath>` value **)**
- :ref:`NodePath<class_NodePath>` **get_wind_source_path** **(** **)**
The :ref:`Node3D<class_Node3D>` which is used to specify the the direction and origin of an area-specific wind force. The direction is opposite to the z-axis of the :ref:`Node3D<class_Node3D>`'s local transform, and its origin is the origin of the :ref:`Node3D<class_Node3D>`'s local transform.
The :ref:`Node3D<class_Node3D>` which is used to specify the direction and origin of an area-specific wind force. The direction is opposite to the z-axis of the :ref:`Node3D<class_Node3D>`'s local transform, and its origin is the origin of the :ref:`Node3D<class_Node3D>`'s local transform.
.. rst-class:: classref-section-separator

View File

@@ -70,8 +70,6 @@ Arrays can be concatenated using the ``+`` operator:
\ **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
Constructors
@@ -873,6 +871,18 @@ See also :ref:`filter<class_Array_method_filter>`, :ref:`reduce<class_Array_meth
Returns the maximum value contained in the array if all elements are of comparable types. If the elements can't be compared, ``null`` is returned.
To find the maximum value using a custom comparator, you can use :ref:`reduce<class_Array_method_reduce>`. In this example every array element is checked and the first maximum value is returned:
::
func _ready():
var arr = [Vector2(0, 1), Vector2(2, 0), Vector2(1, 1), Vector2(1, 0), Vector2(0, 2)]
# In this example we compare the lengths.
print(arr.reduce(func(max, val): return val if is_length_greater(val, max) else max))
func is_length_greater(a, b):
return a.length() > b.length()
.. rst-class:: classref-item-separator
----
@@ -885,6 +895,8 @@ Returns the maximum value contained in the array if all elements are of comparab
Returns the minimum value contained in the array if all elements are of comparable types. If the elements can't be compared, ``null`` is returned.
See also :ref:`max<class_Array_method_max>` for an example of using a custom comparator.
.. rst-class:: classref-item-separator
----

View File

@@ -21,7 +21,7 @@ Description
Compared to :ref:`AStar2D<class_AStar2D>` you don't need to manually create points or connect them together. It also supports multiple type of heuristics and modes for diagonal movement. This class also provides a jumping mode which is faster to calculate than without it in the :ref:`AStar2D<class_AStar2D>` class.
In contrast to :ref:`AStar2D<class_AStar2D>`, you only need set the :ref:`size<class_AStarGrid2D_property_size>` of the grid, optionally set the :ref:`cell_size<class_AStarGrid2D_property_cell_size>` and then call the :ref:`update<class_AStarGrid2D_method_update>` method:
In contrast to :ref:`AStar2D<class_AStar2D>`, you only need set the :ref:`region<class_AStarGrid2D_property_region>` of the grid, optionally set the :ref:`cell_size<class_AStarGrid2D_property_cell_size>` and then call the :ref:`update<class_AStarGrid2D_method_update>` method:
.. tabs::
@@ -29,7 +29,7 @@ In contrast to :ref:`AStar2D<class_AStar2D>`, you only need set the :ref:`size<c
.. code-tab:: gdscript
var astar_grid = AStarGrid2D.new()
astar_grid.size = Vector2i(32, 32)
astar_grid.region = Rect2i(0, 0, 32, 32)
astar_grid.cell_size = Vector2(16, 16)
astar_grid.update()
print(astar_grid.get_id_path(Vector2i(0, 0), Vector2i(3, 4))) # prints (0, 0), (1, 1), (2, 2), (3, 3), (3, 4)
@@ -54,21 +54,23 @@ Properties
.. table::
:widths: auto
+----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+
| :ref:`Vector2<class_Vector2>` | :ref:`cell_size<class_AStarGrid2D_property_cell_size>` | ``Vector2(1, 1)`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+
| :ref:`Heuristic<enum_AStarGrid2D_Heuristic>` | :ref:`default_compute_heuristic<class_AStarGrid2D_property_default_compute_heuristic>` | ``0`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+
| :ref:`Heuristic<enum_AStarGrid2D_Heuristic>` | :ref:`default_estimate_heuristic<class_AStarGrid2D_property_default_estimate_heuristic>` | ``0`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+
| :ref:`DiagonalMode<enum_AStarGrid2D_DiagonalMode>` | :ref:`diagonal_mode<class_AStarGrid2D_property_diagonal_mode>` | ``0`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+
| :ref:`bool<class_bool>` | :ref:`jumping_enabled<class_AStarGrid2D_property_jumping_enabled>` | ``false`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+
| :ref:`Vector2<class_Vector2>` | :ref:`offset<class_AStarGrid2D_property_offset>` | ``Vector2(0, 0)`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+
| :ref:`Vector2i<class_Vector2i>` | :ref:`size<class_AStarGrid2D_property_size>` | ``Vector2i(0, 0)`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+--------------------+
+----------------------------------------------------+------------------------------------------------------------------------------------------+------------------------+
| :ref:`Vector2<class_Vector2>` | :ref:`cell_size<class_AStarGrid2D_property_cell_size>` | ``Vector2(1, 1)`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+------------------------+
| :ref:`Heuristic<enum_AStarGrid2D_Heuristic>` | :ref:`default_compute_heuristic<class_AStarGrid2D_property_default_compute_heuristic>` | ``0`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+------------------------+
| :ref:`Heuristic<enum_AStarGrid2D_Heuristic>` | :ref:`default_estimate_heuristic<class_AStarGrid2D_property_default_estimate_heuristic>` | ``0`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+------------------------+
| :ref:`DiagonalMode<enum_AStarGrid2D_DiagonalMode>` | :ref:`diagonal_mode<class_AStarGrid2D_property_diagonal_mode>` | ``0`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+------------------------+
| :ref:`bool<class_bool>` | :ref:`jumping_enabled<class_AStarGrid2D_property_jumping_enabled>` | ``false`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+------------------------+
| :ref:`Vector2<class_Vector2>` | :ref:`offset<class_AStarGrid2D_property_offset>` | ``Vector2(0, 0)`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+------------------------+
| :ref:`Rect2i<class_Rect2i>` | :ref:`region<class_AStarGrid2D_property_region>` | ``Rect2i(0, 0, 0, 0)`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+------------------------+
| :ref:`Vector2i<class_Vector2i>` | :ref:`size<class_AStarGrid2D_property_size>` | ``Vector2i(0, 0)`` |
+----------------------------------------------------+------------------------------------------------------------------------------------------+------------------------+
.. rst-class:: classref-reftable-group
@@ -355,6 +357,23 @@ The offset of the grid which will be applied to calculate the resulting point po
----
.. _class_AStarGrid2D_property_region:
.. rst-class:: classref-property
:ref:`Rect2i<class_Rect2i>` **region** = ``Rect2i(0, 0, 0, 0)``
.. rst-class:: classref-property-setget
- void **set_region** **(** :ref:`Rect2i<class_Rect2i>` value **)**
- :ref:`Rect2i<class_Rect2i>` **get_region** **(** **)**
The region of grid cells available for pathfinding. If changed, :ref:`update<class_AStarGrid2D_method_update>` needs to be called before finding the next path.
.. rst-class:: classref-item-separator
----
.. _class_AStarGrid2D_property_size:
.. rst-class:: classref-property
@@ -368,6 +387,8 @@ The offset of the grid which will be applied to calculate the resulting point po
The size of the grid (number of cells of size :ref:`cell_size<class_AStarGrid2D_property_cell_size>` on each axis). If changed, :ref:`update<class_AStarGrid2D_method_update>` needs to be called before finding the next path.
\ **Note:** This property is deprecated, use :ref:`region<class_AStarGrid2D_property_region>` instead.
.. rst-class:: classref-section-separator
----
@@ -411,7 +432,7 @@ Note that this function is hidden in the default ``AStarGrid2D`` class.
void **clear** **(** **)**
Clears the grid and sets the :ref:`size<class_AStarGrid2D_property_size>` to :ref:`Vector2i.ZERO<class_Vector2i_constant_ZERO>`.
Clears the grid and sets the :ref:`region<class_AStarGrid2D_property_region>` to ``Rect2i(0, 0, 0, 0)``.
.. rst-class:: classref-item-separator
@@ -549,7 +570,9 @@ Sets the ``weight_scale`` for the point with the given ``id``. The ``weight_scal
void **update** **(** **)**
Updates the internal state of the grid according to the parameters to prepare it to search the path. Needs to be called if parameters like :ref:`size<class_AStarGrid2D_property_size>`, :ref:`cell_size<class_AStarGrid2D_property_cell_size>` or :ref:`offset<class_AStarGrid2D_property_offset>` are changed. :ref:`is_dirty<class_AStarGrid2D_method_is_dirty>` will return ``true`` if this is the case and this needs to be called.
Updates the internal state of the grid according to the parameters to prepare it to search the path. Needs to be called if parameters like :ref:`region<class_AStarGrid2D_property_region>`, :ref:`cell_size<class_AStarGrid2D_property_cell_size>` or :ref:`offset<class_AStarGrid2D_property_offset>` are changed. :ref:`is_dirty<class_AStarGrid2D_method_is_dirty>` will return ``true`` if this is the case and this needs to be called.
\ **Note:** All point data (solidity and weight scale) will be cleared.
.. |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.)`

View File

@@ -12,14 +12,38 @@ AudioStreamGenerator
**Inherits:** :ref:`AudioStream<class_AudioStream>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Audio stream that generates sounds procedurally.
An audio stream with utilities for procedural sound generation.
.. rst-class:: classref-introduction-group
Description
-----------
This audio stream does not play back sounds, but expects a script to generate audio data for it instead. See also :ref:`AudioStreamGeneratorPlayback<class_AudioStreamGeneratorPlayback>`.
**AudioStreamGenerator** is a type of audio stream that does not play back sounds on its own; instead, it expects a script to generate audio data for it. See also :ref:`AudioStreamGeneratorPlayback<class_AudioStreamGeneratorPlayback>`.
Here's a sample on how to use it to generate a sine wave:
::
var playback # Will hold the AudioStreamGeneratorPlayback.
@onready var sample_hz = $AudioStreamPlayer.stream.mix_rate
var pulse_hz = 440.0 # The frequency of the sound wave.
func _ready():
$AudioStreamPlayer.play()
playback = $AudioStreamPlayer.get_stream_playback()
fill_buffer()
func fill_buffer():
var phase = 0.0
var increment = pulse_hz / sample_hz
var frames_available = playback.get_frames_available()
for i in range(frames_available):
playback.push_frame(Vector2.ONE * sin(phase * TAU))
phase = fmod(phase + increment, 1.0)
In the example above, the "AudioStreamPlayer" node must use an **AudioStreamGenerator** as its stream. The ``fill_buffer`` function provides audio data for approximating a sine wave.
See also :ref:`AudioEffectSpectrumAnalyzer<class_AudioEffectSpectrumAnalyzer>` for performing real-time audio spectrum analysis.
@@ -32,8 +56,6 @@ Tutorials
- `Audio Generator Demo <https://godotengine.org/asset-library/asset/526>`__
- `Godot 3.2 will get new audio features <https://godotengine.org/article/godot-32-will-get-new-audio-features>`__
.. rst-class:: classref-reftable-group
Properties

View File

@@ -250,6 +250,8 @@ Determines when the button is considered clicked, one of the :ref:`ActionMode<en
The :ref:`ButtonGroup<class_ButtonGroup>` associated with the button. Not to be confused with node groups.
\ **Note:** The button will be configured as a radio button if a :ref:`ButtonGroup<class_ButtonGroup>` is assigned to it.
.. rst-class:: classref-item-separator
----

View File

@@ -2945,7 +2945,7 @@ The method for rendering the specular blob. See :ref:`SpecularMode<enum_BaseMate
- void **set_feature** **(** :ref:`Feature<enum_BaseMaterial3D_Feature>` feature, :ref:`bool<class_bool>` enable **)**
- :ref:`bool<class_bool>` **get_feature** **(** :ref:`Feature<enum_BaseMaterial3D_Feature>` feature **)** |const|
If ``true``, subsurface scattering is enabled. Emulates light that penetrates an object's surface, is scattered, and then emerges.
If ``true``, subsurface scattering is enabled. Emulates light that penetrates an object's surface, is scattered, and then emerges. Subsurface scattering quality is controlled by :ref:`ProjectSettings.rendering/environment/subsurface_scattering/subsurface_scattering_quality<class_ProjectSettings_property_rendering/environment/subsurface_scattering/subsurface_scattering_quality>`.
.. rst-class:: classref-item-separator
@@ -2979,7 +2979,7 @@ If ``true``, subsurface scattering will use a special mode optimized for the col
- void **set_subsurface_scattering_strength** **(** :ref:`float<class_float>` value **)**
- :ref:`float<class_float>` **get_subsurface_scattering_strength** **(** **)**
The strength of the subsurface scattering effect.
The strength of the subsurface scattering effect. The depth of the effect is also controlled by :ref:`ProjectSettings.rendering/environment/subsurface_scattering/subsurface_scattering_scale<class_ProjectSettings_property_rendering/environment/subsurface_scattering/subsurface_scattering_scale>`, which is set globally.
.. rst-class:: classref-item-separator
@@ -3134,7 +3134,7 @@ Repeat flags for the texture. See :ref:`TextureFilter<enum_BaseMaterial3D_Textur
- void **set_transparency** **(** :ref:`Transparency<enum_BaseMaterial3D_Transparency>` value **)**
- :ref:`Transparency<enum_BaseMaterial3D_Transparency>` **get_transparency** **(** **)**
If ``true``, transparency is enabled on the body. Some transparency modes will disable shadow casting. Any transparency mode other than Disabled has a greater performance impact compared to opaque rendering. See also :ref:`blend_mode<class_BaseMaterial3D_property_blend_mode>`.
The material's transparency mode. Some transparency modes will disable shadow casting. Any transparency mode other than :ref:`TRANSPARENCY_DISABLED<class_BaseMaterial3D_constant_TRANSPARENCY_DISABLED>` has a greater performance impact compared to opaque rendering. See also :ref:`blend_mode<class_BaseMaterial3D_property_blend_mode>`.
.. rst-class:: classref-item-separator

View File

@@ -12,16 +12,16 @@ Bone2D
**Inherits:** :ref:`Node2D<class_Node2D>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
Joint used with :ref:`Skeleton2D<class_Skeleton2D>` to control and animate other nodes.
A joint used with :ref:`Skeleton2D<class_Skeleton2D>` to control and animate other nodes.
.. rst-class:: classref-introduction-group
Description
-----------
Use a hierarchy of ``Bone2D`` bound to a :ref:`Skeleton2D<class_Skeleton2D>` to control, and animate other :ref:`Node2D<class_Node2D>` nodes.
A hierarchy of **Bone2D**\ s can be bound to a :ref:`Skeleton2D<class_Skeleton2D>` to control and animate other :ref:`Node2D<class_Node2D>` nodes.
You can use ``Bone2D`` and ``Skeleton2D`` nodes to animate 2D meshes created with the Polygon 2D UV editor.
You can use **Bone2D** and :ref:`Skeleton2D<class_Skeleton2D>` nodes to animate 2D meshes created with the :ref:`Polygon2D<class_Polygon2D>` UV editor.
Each bone has a :ref:`rest<class_Bone2D_property_rest>` transform that you can reset to with :ref:`apply_rest<class_Bone2D_method_apply_rest>`. These rest poses are relative to the bone's parent.
@@ -116,7 +116,7 @@ Stores the node's current transforms in :ref:`rest<class_Bone2D_property_rest>`.
:ref:`bool<class_bool>` **get_autocalculate_length_and_angle** **(** **)** |const|
Returns whether this ``Bone2D`` node is going to autocalculate its length and bone angle using its first ``Bone2D`` child node, if one exists. If there are no ``Bone2D`` children, then it cannot autocalculate these values and will print a warning.
Returns whether this **Bone2D** is going to autocalculate its length and bone angle using its first **Bone2D** child node, if one exists. If there are no **Bone2D** children, then it cannot autocalculate these values and will print a warning.
.. rst-class:: classref-item-separator
@@ -128,9 +128,9 @@ Returns whether this ``Bone2D`` node is going to autocalculate its length and bo
:ref:`float<class_float>` **get_bone_angle** **(** **)** |const|
Returns the angle of the bone in the ``Bone2D`` node.
Returns the angle of the bone in the **Bone2D**.
\ **Note:** This is different from the ``Bone2D``'s rotation. The bone angle is the rotation of the bone shown by the ``Bone2D`` gizmo, and because ``Bone2D`` bones are based on positions, this can vary from the actual rotation of the ``Bone2D`` node.
\ **Note:** This is different from the **Bone2D**'s rotation. The bone's angle is the rotation of the bone shown by the gizmo, which is unaffected by the **Bone2D**'s :ref:`Node2D.transform<class_Node2D_property_transform>`.
.. rst-class:: classref-item-separator
@@ -154,7 +154,7 @@ Returns the node's index as part of the entire skeleton. See :ref:`Skeleton2D<cl
:ref:`float<class_float>` **get_length** **(** **)** |const|
Returns the length of the bone in the ``Bone2D`` node.
Returns the length of the bone in the **Bone2D** node.
.. rst-class:: classref-item-separator
@@ -178,7 +178,7 @@ Returns the node's :ref:`rest<class_Bone2D_property_rest>` ``Transform2D`` if it
void **set_autocalculate_length_and_angle** **(** :ref:`bool<class_bool>` auto_calculate **)**
When set to ``true``, the ``Bone2D`` node will attempt to automatically calculate the bone angle and length using the first child ``Bone2D`` node, if one exists. If none exist, the ``Bone2D`` cannot automatically calculate these values and will print a warning.
When set to ``true``, the **Bone2D** node will attempt to automatically calculate the bone angle and length using the first child **Bone2D** node, if one exists. If none exist, the **Bone2D** cannot automatically calculate these values and will print a warning.
.. rst-class:: classref-item-separator
@@ -190,9 +190,9 @@ When set to ``true``, the ``Bone2D`` node will attempt to automatically calculat
void **set_bone_angle** **(** :ref:`float<class_float>` angle **)**
Sets the bone angle for the ``Bone2D`` node. This is typically set to the rotation from the ``Bone2D`` node to a child ``Bone2D`` node.
Sets the bone angle for the **Bone2D**. This is typically set to the rotation from the **Bone2D** to a child **Bone2D** node.
\ **Note:** This is different from the ``Bone2D``'s rotation. The bone angle is the rotation of the bone shown by the ``Bone2D`` gizmo, and because ``Bone2D`` bones are based on positions, this can vary from the actual rotation of the ``Bone2D`` node.
\ **Note:** **Note:** This is different from the **Bone2D**'s rotation. The bone's angle is the rotation of the bone shown by the gizmo, which is unaffected by the **Bone2D**'s :ref:`Node2D.transform<class_Node2D_property_transform>`.
.. rst-class:: classref-item-separator
@@ -204,7 +204,7 @@ Sets the bone angle for the ``Bone2D`` node. This is typically set to the rotati
void **set_length** **(** :ref:`float<class_float>` length **)**
Sets the length of the bone in the ``Bone2D`` node.
Sets the length of the bone in the **Bone2D**.
.. |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.)`

View File

@@ -12,16 +12,14 @@ BoneAttachment3D
**Inherits:** :ref:`Node3D<class_Node3D>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
A node that will attach to a bone.
А node that dynamically copies or overrides the 3D transform of a bone in its parent :ref:`Skeleton3D<class_Skeleton3D>`.
.. rst-class:: classref-introduction-group
Description
-----------
This node will allow you to select a bone for this node to attach to. The BoneAttachment3D node can copy the transform of the select bone, or can override the transform of the selected bone.
The BoneAttachment3D node must either be a child of a :ref:`Skeleton3D<class_Skeleton3D>` node or be given an external :ref:`Skeleton3D<class_Skeleton3D>` to use in order to function properly.
This node selects a bone in a :ref:`Skeleton3D<class_Skeleton3D>` and attaches to it. This means that the **BoneAttachment3D** node will either dynamically copy or override the 3D transform of the selected bone.
.. rst-class:: classref-reftable-group

View File

@@ -12,14 +12,14 @@ BoneMap
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Bone map for retargeting.
Describes a mapping of bone names for retargeting :ref:`Skeleton3D<class_Skeleton3D>` into common names defined by a :ref:`SkeletonProfile<class_SkeletonProfile>`.
.. rst-class:: classref-introduction-group
Description
-----------
This class contains a hashmap that uses a list of bone names in :ref:`SkeletonProfile<class_SkeletonProfile>` as key names.
This class contains a dictionary that uses a list of bone names in :ref:`SkeletonProfile<class_SkeletonProfile>` as key names.
By assigning the actual :ref:`Skeleton3D<class_Skeleton3D>` bone name as the key value, it maps the :ref:`Skeleton3D<class_Skeleton3D>` to the :ref:`SkeletonProfile<class_SkeletonProfile>`.

View File

@@ -79,27 +79,29 @@ Properties
.. table::
:widths: auto
+-------------------------------------------------------------------+---------------------------------------------------------------------------+-----------+
| :ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>` | :ref:`alignment<class_Button_property_alignment>` | ``1`` |
+-------------------------------------------------------------------+---------------------------------------------------------------------------+-----------+
| :ref:`bool<class_bool>` | :ref:`clip_text<class_Button_property_clip_text>` | ``false`` |
+-------------------------------------------------------------------+---------------------------------------------------------------------------+-----------+
| :ref:`bool<class_bool>` | :ref:`expand_icon<class_Button_property_expand_icon>` | ``false`` |
+-------------------------------------------------------------------+---------------------------------------------------------------------------+-----------+
| :ref:`bool<class_bool>` | :ref:`flat<class_Button_property_flat>` | ``false`` |
+-------------------------------------------------------------------+---------------------------------------------------------------------------+-----------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`icon<class_Button_property_icon>` | |
+-------------------------------------------------------------------+---------------------------------------------------------------------------+-----------+
| :ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>` | :ref:`icon_alignment<class_Button_property_icon_alignment>` | ``0`` |
+-------------------------------------------------------------------+---------------------------------------------------------------------------+-----------+
| :ref:`String<class_String>` | :ref:`language<class_Button_property_language>` | ``""`` |
+-------------------------------------------------------------------+---------------------------------------------------------------------------+-----------+
| :ref:`String<class_String>` | :ref:`text<class_Button_property_text>` | ``""`` |
+-------------------------------------------------------------------+---------------------------------------------------------------------------+-----------+
| :ref:`TextDirection<enum_Control_TextDirection>` | :ref:`text_direction<class_Button_property_text_direction>` | ``0`` |
+-------------------------------------------------------------------+---------------------------------------------------------------------------+-----------+
| :ref:`OverrunBehavior<enum_TextServer_OverrunBehavior>` | :ref:`text_overrun_behavior<class_Button_property_text_overrun_behavior>` | ``0`` |
+-------------------------------------------------------------------+---------------------------------------------------------------------------+-----------+
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>` | :ref:`alignment<class_Button_property_alignment>` | ``1`` |
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`bool<class_bool>` | :ref:`clip_text<class_Button_property_clip_text>` | ``false`` |
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`bool<class_bool>` | :ref:`expand_icon<class_Button_property_expand_icon>` | ``false`` |
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`bool<class_bool>` | :ref:`flat<class_Button_property_flat>` | ``false`` |
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`icon<class_Button_property_icon>` | |
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>` | :ref:`icon_alignment<class_Button_property_icon_alignment>` | ``0`` |
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`String<class_String>` | :ref:`language<class_Button_property_language>` | ``""`` |
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`String<class_String>` | :ref:`text<class_Button_property_text>` | ``""`` |
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`TextDirection<enum_Control_TextDirection>` | :ref:`text_direction<class_Button_property_text_direction>` | ``0`` |
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`OverrunBehavior<enum_TextServer_OverrunBehavior>` | :ref:`text_overrun_behavior<class_Button_property_text_overrun_behavior>` | ``0`` |
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
| :ref:`VerticalAlignment<enum_@GlobalScope_VerticalAlignment>` | :ref:`vertical_icon_alignment<class_Button_property_vertical_icon_alignment>` | ``1`` |
+-------------------------------------------------------------------+-------------------------------------------------------------------------------+-----------+
.. rst-class:: classref-reftable-group
@@ -138,6 +140,8 @@ Theme Properties
+---------------------------------+------------------------------------------------------------------------------------+-------------------------------------+
| :ref:`int<class_int>` | :ref:`h_separation<class_Button_theme_constant_h_separation>` | ``2`` |
+---------------------------------+------------------------------------------------------------------------------------+-------------------------------------+
| :ref:`int<class_int>` | :ref:`icon_max_width<class_Button_theme_constant_icon_max_width>` | ``0`` |
+---------------------------------+------------------------------------------------------------------------------------+-------------------------------------+
| :ref:`int<class_int>` | :ref:`outline_size<class_Button_theme_constant_outline_size>` | ``0`` |
+---------------------------------+------------------------------------------------------------------------------------+-------------------------------------+
| :ref:`Font<class_Font>` | :ref:`font<class_Button_theme_font_font>` | |
@@ -209,7 +213,7 @@ When this property is enabled, text that is too large to fit the button is clipp
- void **set_expand_icon** **(** :ref:`bool<class_bool>` value **)**
- :ref:`bool<class_bool>` **is_expand_icon** **(** **)**
When enabled, the button's icon will expand/shrink to fit the button's size while keeping its aspect.
When enabled, the button's icon will expand/shrink to fit the button's size while keeping its aspect. See also :ref:`icon_max_width<class_Button_theme_constant_icon_max_width>`.
.. rst-class:: classref-item-separator
@@ -262,7 +266,7 @@ To edit margin and spacing of the icon, use :ref:`h_separation<class_Button_them
- void **set_icon_alignment** **(** :ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>` value **)**
- :ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>` **get_icon_alignment** **(** **)**
Specifies if the icon should be aligned to the left, right, or center of a button. Uses the same :ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>` constants as the text alignment. If centered, text will draw on top of the icon.
Specifies if the icon should be aligned horizontally to the left, right, or center of a button. Uses the same :ref:`HorizontalAlignment<enum_@GlobalScope_HorizontalAlignment>` constants as the text alignment. If centered horizontally and vertically, text will draw on top of the icon.
.. rst-class:: classref-item-separator
@@ -332,6 +336,23 @@ Base text writing direction.
Sets the clipping behavior when the text exceeds the node's bounding rectangle. See :ref:`OverrunBehavior<enum_TextServer_OverrunBehavior>` for a description of all modes.
.. rst-class:: classref-item-separator
----
.. _class_Button_property_vertical_icon_alignment:
.. rst-class:: classref-property
:ref:`VerticalAlignment<enum_@GlobalScope_VerticalAlignment>` **vertical_icon_alignment** = ``1``
.. rst-class:: classref-property-setget
- void **set_vertical_icon_alignment** **(** :ref:`VerticalAlignment<enum_@GlobalScope_VerticalAlignment>` value **)**
- :ref:`VerticalAlignment<enum_@GlobalScope_VerticalAlignment>` **get_vertical_icon_alignment** **(** **)**
Specifies if the icon should be aligned vertically to the top, bottom, or center of a button. Uses the same :ref:`VerticalAlignment<enum_@GlobalScope_VerticalAlignment>` constants as the text alignment. If centered horizontally and vertically, text will draw on top of the icon.
.. rst-class:: classref-section-separator
----
@@ -509,6 +530,18 @@ The horizontal space between **Button**'s icon and text. Negative values will be
----
.. _class_Button_theme_constant_icon_max_width:
.. rst-class:: classref-themeproperty
:ref:`int<class_int>` **icon_max_width** = ``0``
The maximum allowed width of the **Button**'s icon. This limit is applied on top of the default size of the icon, or its expanded size if :ref:`expand_icon<class_Button_property_expand_icon>` is ``true``. The height is adjusted according to the icon's ratio.
.. rst-class:: classref-item-separator
----
.. _class_Button_theme_constant_outline_size:
.. rst-class:: classref-themeproperty

View File

@@ -19,7 +19,7 @@ Group of Buttons.
Description
-----------
Group of :ref:`BaseButton<class_BaseButton>`. The members of this group are treated like radio buttons in the sense that only one button can be pressed at the same time.
Group of :ref:`BaseButton<class_BaseButton>`. The members of this group are treated like radio buttons in the sense that only one button can be pressed at the same time. Some types of buttons (such as :ref:`CheckBox<class_CheckBox>`) may have a special appearance for this state.
Every member of the ButtonGroup should have :ref:`BaseButton.toggle_mode<class_BaseButton_property_toggle_mode>` set to ``true``.
@@ -31,9 +31,11 @@ Properties
.. table::
:widths: auto
+-------------------------+-------------------------+---------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | resource_local_to_scene | ``true`` (overrides :ref:`Resource<class_Resource_property_resource_local_to_scene>`) |
+-------------------------+-------------------------+---------------------------------------------------------------------------------------+
+-------------------------+----------------------------------------------------------------+---------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`allow_unpress<class_ButtonGroup_property_allow_unpress>` | ``false`` |
+-------------------------+----------------------------------------------------------------+---------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | resource_local_to_scene | ``true`` (overrides :ref:`Resource<class_Resource_property_resource_local_to_scene>`) |
+-------------------------+----------------------------------------------------------------+---------------------------------------------------------------------------------------+
.. rst-class:: classref-reftable-group
@@ -72,6 +74,28 @@ Emitted when one of the buttons of the group is pressed.
.. rst-class:: classref-descriptions-group
Property Descriptions
---------------------
.. _class_ButtonGroup_property_allow_unpress:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **allow_unpress** = ``false``
.. rst-class:: classref-property-setget
- void **set_allow_unpress** **(** :ref:`bool<class_bool>` value **)**
- :ref:`bool<class_bool>` **is_allow_unpress** **(** **)**
If ``true``, it is possible to unpress all buttons in this **ButtonGroup**.
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Method Descriptions
-------------------

View File

@@ -196,7 +196,9 @@ Method Descriptions
:ref:`Callable<class_Callable>` **bind** **(** ... **)** |vararg| |const|
Returns a copy of this **Callable** with one or more arguments bound. When called, the bound arguments are passed *after* the arguments supplied by :ref:`call<class_Callable_method_call>`.
Returns a copy of this **Callable** with one or more arguments bound. When called, the bound arguments are passed *after* the arguments supplied by :ref:`call<class_Callable_method_call>`. See also :ref:`unbind<class_Callable_method_unbind>`.
\ **Note:** When this method is chained with other similar methods, the order in which the argument list is modified is read from right to left.
.. rst-class:: classref-item-separator
@@ -208,7 +210,9 @@ Returns a copy of this **Callable** with one or more arguments bound. When calle
:ref:`Callable<class_Callable>` **bindv** **(** :ref:`Array<class_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<class_Callable_method_call>`.
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<class_Callable_method_call>`. See also :ref:`unbind<class_Callable_method_unbind>`.
\ **Note:** When this method is chained with other similar methods, the order in which the argument list is modified is read from right to left.
.. rst-class:: classref-item-separator
@@ -407,7 +411,15 @@ Perform an RPC (Remote Procedure Call) on a specific peer ID (see multiplayer do
:ref:`Callable<class_Callable>` **unbind** **(** :ref:`int<class_int>` argcount **)** |const|
Returns a copy of this **Callable** with the arguments unbound, as defined by ``argcount``. Calling the returned **Callable** will call the method without the extra arguments that are supplied in the **Callable** on which you are calling this method.
Returns a copy of this **Callable** with a number of arguments unbound. In other words, when the new callable is called the last few arguments supplied by the user are ignored, according to ``argcount``. The remaining arguments are passed to the callable. This allows to use the original callable in a context that attempts to pass more arguments than this callable can handle, e.g. a signal with a fixed number of arguments. See also :ref:`bind<class_Callable_method_bind>`.
\ **Note:** When this method is chained with other similar methods, the order in which the argument list is modified is read from right to left.
::
func _ready():
foo.unbind(1).call(1, 2) # Calls foo(1).
foo.bind(3, 4).unbind(1).call(1, 2) # Calls foo(1, 3, 4), note that it does not change the arguments from bind.
.. rst-class:: classref-section-separator

View File

@@ -495,6 +495,14 @@ The **CanvasItem** has entered the canvas.
The **CanvasItem** has exited the canvas.
.. _class_CanvasItem_constant_NOTIFICATION_WORLD_2D_CHANGED:
.. rst-class:: classref-constant
**NOTIFICATION_WORLD_2D_CHANGED** = ``36``
The **CanvasItem**'s active :ref:`World2D<class_World2D>` changed.
.. rst-class:: classref-section-separator
----
@@ -549,7 +557,7 @@ The rendering layers in which this **CanvasItem** responds to :ref:`Light2D<clas
- void **set_material** **(** :ref:`Material<class_Material>` value **)**
- :ref:`Material<class_Material>` **get_material** **(** **)**
The material applied to textures on this **CanvasItem**.
The material applied to this **CanvasItem**.
.. rst-class:: classref-item-separator
@@ -566,7 +574,7 @@ The material applied to textures on this **CanvasItem**.
- void **set_modulate** **(** :ref:`Color<class_Color>` value **)**
- :ref:`Color<class_Color>` **get_modulate** **(** **)**
The color applied to textures on this **CanvasItem**.
The color applied to this **CanvasItem**. This property does affect child **CanvasItem**\ s, unlike :ref:`self_modulate<class_CanvasItem_property_self_modulate>` which only affects the node itself.
.. rst-class:: classref-item-separator
@@ -583,7 +591,9 @@ The color applied to textures on this **CanvasItem**.
- void **set_self_modulate** **(** :ref:`Color<class_Color>` value **)**
- :ref:`Color<class_Color>` **get_self_modulate** **(** **)**
The color applied to textures on this **CanvasItem**. This is not inherited by children **CanvasItem**\ s.
The color applied to this **CanvasItem**. This property does **not** affect child **CanvasItem**\ s, unlike :ref:`modulate<class_CanvasItem_property_modulate>` which affects both the node itself and its children.
\ **Note:** Internal children (e.g. sliders in :ref:`ColorPicker<class_ColorPicker>` or tab bar in :ref:`TabContainer<class_TabContainer>`) are also not affected by this property (see ``include_internal`` parameter of :ref:`Node.get_child<class_Node_method_get_child>` and other similar methods).
.. rst-class:: classref-item-separator
@@ -702,7 +712,7 @@ The rendering layer in which this **CanvasItem** is rendered by :ref:`Viewport<c
- void **set_visible** **(** :ref:`bool<class_bool>` value **)**
- :ref:`bool<class_bool>` **is_visible** **(** **)**
If ``true``, this **CanvasItem** is drawn. The node is only visible if all of its antecedents are visible as well (in other words, :ref:`is_visible_in_tree<class_CanvasItem_method_is_visible_in_tree>` must return ``true``).
If ``true``, this **CanvasItem** is drawn. The node is only visible if all of its ancestors are visible as well (in other words, :ref:`is_visible_in_tree<class_CanvasItem_method_is_visible_in_tree>` must return ``true``).
\ **Note:** For controls that inherit :ref:`Popup<class_Popup>`, the correct way to make them visible is to call one of the multiple ``popup*()`` functions instead.
@@ -1019,7 +1029,7 @@ Draws a :ref:`MultiMesh<class_MultiMesh>` in 2D with the provided texture. See :
void **draw_polygon** **(** :ref:`PackedVector2Array<class_PackedVector2Array>` points, :ref:`PackedColorArray<class_PackedColorArray>` colors, :ref:`PackedVector2Array<class_PackedVector2Array>` uvs=PackedVector2Array(), :ref:`Texture2D<class_Texture2D>` texture=null **)**
Draws a solid polygon of any number of points, convex or concave. Unlike :ref:`draw_colored_polygon<class_CanvasItem_method_draw_colored_polygon>`, each point's color can be changed individually. See also :ref:`draw_polyline<class_CanvasItem_method_draw_polyline>` and :ref:`draw_polyline_colors<class_CanvasItem_method_draw_polyline_colors>`.
Draws a solid polygon of any number of points, convex or concave. Unlike :ref:`draw_colored_polygon<class_CanvasItem_method_draw_colored_polygon>`, each point's color can be changed individually. See also :ref:`draw_polyline<class_CanvasItem_method_draw_polyline>` and :ref:`draw_polyline_colors<class_CanvasItem_method_draw_polyline_colors>`. If you need more flexibility (such as being able to use bones), use :ref:`RenderingServer.canvas_item_add_triangle_array<class_RenderingServer_method_canvas_item_add_triangle_array>` instead.
.. rst-class:: classref-item-separator
@@ -1071,7 +1081,7 @@ Draws a custom primitive. 1 point for a point, 2 points for a line, 3 points for
void **draw_rect** **(** :ref:`Rect2<class_Rect2>` rect, :ref:`Color<class_Color>` color, :ref:`bool<class_bool>` filled=true, :ref:`float<class_float>` width=-1.0 **)**
Draws a rectangle. If ``filled`` is ``true``, the rectangle will be filled with the ``color`` specified. If ``filled`` is ``false``, the rectangle will be drawn as a stroke with the ``color`` and ``width`` specified.
Draws a rectangle. If ``filled`` is ``true``, the rectangle will be filled with the ``color`` specified. If ``filled`` is ``false``, the rectangle will be drawn as a stroke with the ``color`` and ``width`` specified. See also :ref:`draw_texture_rect<class_CanvasItem_method_draw_texture_rect>`.
If ``width`` is negative, then two-point primitives will be drawn instead of a four-point ones. This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not desired, then pass a positive ``width`` like ``1.0``.
@@ -1190,7 +1200,7 @@ Draws a texture at a given position.
void **draw_texture_rect** **(** :ref:`Texture2D<class_Texture2D>` texture, :ref:`Rect2<class_Rect2>` rect, :ref:`bool<class_bool>` tile, :ref:`Color<class_Color>` modulate=Color(1, 1, 1, 1), :ref:`bool<class_bool>` transpose=false **)**
Draws a textured rectangle at a given position, optionally modulated by a color. If ``transpose`` is ``true``, the texture will have its X and Y coordinates swapped.
Draws a textured rectangle at a given position, optionally modulated by a color. If ``transpose`` is ``true``, the texture will have its X and Y coordinates swapped. See also :ref:`draw_rect<class_CanvasItem_method_draw_rect>` and :ref:`draw_texture_rect_region<class_CanvasItem_method_draw_texture_rect_region>`.
.. rst-class:: classref-item-separator
@@ -1202,7 +1212,7 @@ Draws a textured rectangle at a given position, optionally modulated by a color.
void **draw_texture_rect_region** **(** :ref:`Texture2D<class_Texture2D>` texture, :ref:`Rect2<class_Rect2>` rect, :ref:`Rect2<class_Rect2>` src_rect, :ref:`Color<class_Color>` modulate=Color(1, 1, 1, 1), :ref:`bool<class_bool>` transpose=false, :ref:`bool<class_bool>` clip_uv=true **)**
Draws a textured rectangle region at a given position, optionally modulated by a color. If ``transpose`` is ``true``, the texture will have its X and Y coordinates swapped.
Draws a textured rectangle from a texture's region (specified by ``src_rect``) at a given position, optionally modulated by a color. If ``transpose`` is ``true``, the texture will have its X and Y coordinates swapped. See also :ref:`draw_texture_rect<class_CanvasItem_method_draw_texture_rect>`.
.. rst-class:: classref-item-separator
@@ -1264,6 +1274,8 @@ Returns the transform from the coordinate system of the canvas, this item is in,
Returns the mouse's position in the :ref:`CanvasLayer<class_CanvasLayer>` that this **CanvasItem** is in using the coordinate system of the :ref:`CanvasLayer<class_CanvasLayer>`.
\ **Note:** For screen-space coordinates (e.g. when using a non-embedded :ref:`Popup<class_Popup>`), you can use :ref:`DisplayServer.mouse_get_position<class_DisplayServer_method_mouse_get_position>`.
.. rst-class:: classref-item-separator
----
@@ -1420,7 +1432,7 @@ Returns ``true`` if global transform notifications are communicated to children.
:ref:`bool<class_bool>` **is_visible_in_tree** **(** **)** |const|
Returns ``true`` if the node is present in the :ref:`SceneTree<class_SceneTree>`, its :ref:`visible<class_CanvasItem_property_visible>` property is ``true`` and all its antecedents are also visible. If any antecedent is hidden, this node will not be visible in the scene tree, and is consequently not drawn (see :ref:`_draw<class_CanvasItem_method__draw>`).
Returns ``true`` if the node is present in the :ref:`SceneTree<class_SceneTree>`, its :ref:`visible<class_CanvasItem_property_visible>` property is ``true`` and all its ancestors are also visible. If any ancestor is hidden, this node will not be visible in the scene tree, and is consequently not drawn (see :ref:`_draw<class_CanvasItem_method__draw>`).
.. rst-class:: classref-item-separator

View File

@@ -86,6 +86,8 @@ Methods
.. table::
:widths: auto
+---------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`apply_floor_snap<class_CharacterBody2D_method_apply_floor_snap>` **(** **)** |
+---------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`get_floor_angle<class_CharacterBody2D_method_get_floor_angle>` **(** :ref:`Vector2<class_Vector2>` up_direction=Vector2(0, -1) **)** |const| |
+---------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
@@ -262,7 +264,7 @@ Maximum angle (in radians) where a slope is still considered a floor (or a ceili
Sets a snapping distance. When set to a value different from ``0.0``, the body is kept attached to slopes when calling :ref:`move_and_slide<class_CharacterBody2D_method_move_and_slide>`. The snapping vector is determined by the given distance along the opposite direction of the :ref:`up_direction<class_CharacterBody2D_property_up_direction>`.
As long as the snapping vector is in contact with the ground and the body moves against :ref:`up_direction<class_CharacterBody2D_property_up_direction>`, the body will remain attached to the surface. Snapping is not applied if the body moves along :ref:`up_direction<class_CharacterBody2D_property_up_direction>`, so it will be able to detach from the ground when jumping.
As long as the snapping vector is in contact with the ground and the body moves against :ref:`up_direction<class_CharacterBody2D_property_up_direction>`, the body will remain attached to the surface. Snapping is not applied if the body moves along :ref:`up_direction<class_CharacterBody2D_property_up_direction>`, meaning it contains vertical rising velocity, so it will be able to detach from the ground when jumping or when the body is pushed up by something. If you want to apply a snap without taking into account the velocity, use :ref:`apply_floor_snap<class_CharacterBody2D_method_apply_floor_snap>`.
.. rst-class:: classref-item-separator
@@ -468,6 +470,18 @@ Minimum angle (in radians) where the body is allowed to slide when it encounters
Method Descriptions
-------------------
.. _class_CharacterBody2D_method_apply_floor_snap:
.. rst-class:: classref-method
void **apply_floor_snap** **(** **)**
Allows to manually apply a snap to the floor regardless of the body's velocity. This function does nothing when :ref:`is_on_floor<class_CharacterBody2D_method_is_on_floor>` returns ``true``.
.. rst-class:: classref-item-separator
----
.. _class_CharacterBody2D_method_get_floor_angle:
.. rst-class:: classref-method
@@ -568,8 +582,8 @@ Returns a :ref:`KinematicCollision2D<class_KinematicCollision2D>`, which contain
.. code-tab:: gdscript
for i in get_slide_collision_count():
var collision = get_slide_collision(i)
print("Collided with: ", collision.collider.name)
var collision = get_slide_collision(i)
print("Collided with: ", collision.get_collider().name)
.. code-tab:: csharp

View File

@@ -90,6 +90,8 @@ Methods
.. table::
:widths: auto
+---------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`apply_floor_snap<class_CharacterBody3D_method_apply_floor_snap>` **(** **)** |
+---------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`get_floor_angle<class_CharacterBody3D_method_get_floor_angle>` **(** :ref:`Vector3<class_Vector3>` up_direction=Vector3(0, 1, 0) **)** |const| |
+---------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
@@ -268,7 +270,7 @@ Maximum angle (in radians) where a slope is still considered a floor (or a ceili
Sets a snapping distance. When set to a value different from ``0.0``, the body is kept attached to slopes when calling :ref:`move_and_slide<class_CharacterBody3D_method_move_and_slide>`. The snapping vector is determined by the given distance along the opposite direction of the :ref:`up_direction<class_CharacterBody3D_property_up_direction>`.
As long as the snapping vector is in contact with the ground and the body moves against :ref:`up_direction<class_CharacterBody3D_property_up_direction>`, the body will remain attached to the surface. Snapping is not applied if the body moves along :ref:`up_direction<class_CharacterBody3D_property_up_direction>`, so it will be able to detach from the ground when jumping.
As long as the snapping vector is in contact with the ground and the body moves against :ref:`up_direction<class_CharacterBody3D_property_up_direction>`, the body will remain attached to the surface. Snapping is not applied if the body moves along :ref:`up_direction<class_CharacterBody3D_property_up_direction>`, meaning it contains vertical rising velocity, so it will be able to detach from the ground when jumping or when the body is pushed up by something. If you want to apply a snap without taking into account the velocity, use :ref:`apply_floor_snap<class_CharacterBody3D_method_apply_floor_snap>`.
.. rst-class:: classref-item-separator
@@ -474,6 +476,18 @@ Minimum angle (in radians) where the body is allowed to slide when it encounters
Method Descriptions
-------------------
.. _class_CharacterBody3D_method_apply_floor_snap:
.. rst-class:: classref-method
void **apply_floor_snap** **(** **)**
Allows to manually apply a snap to the floor regardless of the body's velocity. This function does nothing when :ref:`is_on_floor<class_CharacterBody3D_method_is_on_floor>` returns ``true``.
.. rst-class:: classref-item-separator
----
.. _class_CharacterBody3D_method_get_floor_angle:
.. rst-class:: classref-method

View File

@@ -23,6 +23,8 @@ A checkbox allows the user to make a binary choice (choosing only one of two pos
See also :ref:`BaseButton<class_BaseButton>` which contains common properties and methods associated with this node.
\ **Note:** CheckBox changes its appearance when it's configured as a radio button. See various ``radio_*`` theme properties. To configure CheckBox to act as a radio button, use :ref:`BaseButton.button_group<class_BaseButton_property_button_group>` and :ref:`ButtonGroup<class_ButtonGroup>`.
.. rst-class:: classref-reftable-group
Properties

View File

@@ -116,6 +116,8 @@ Methods
+-------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`confirm_code_completion<class_CodeEdit_method_confirm_code_completion>` **(** :ref:`bool<class_bool>` replace=false **)** |
+-------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`convert_indent<class_CodeEdit_method_convert_indent>` **(** :ref:`int<class_int>` from_line=-1, :ref:`int<class_int>` to_line=-1 **)** |
+-------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`do_indent<class_CodeEdit_method_do_indent>` **(** **)** |
+-------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`fold_all_lines<class_CodeEdit_method_fold_all_lines>` **(** **)** |
@@ -417,7 +419,7 @@ Marks the option as a member.
:ref:`CodeCompletionKind<enum_CodeEdit_CodeCompletionKind>` **KIND_ENUM** = ``5``
Marks the option as a enum entry.
Marks the option as an enum entry.
.. _class_CodeEdit_constant_KIND_CONSTANT:
@@ -999,6 +1001,20 @@ Inserts the selected entry into the text. If ``replace`` is true, any existing t
----
.. _class_CodeEdit_method_convert_indent:
.. rst-class:: classref-method
void **convert_indent** **(** :ref:`int<class_int>` from_line=-1, :ref:`int<class_int>` to_line=-1 **)**
Converts the indents of lines between ``from_line`` and ``to_line`` to tabs or spaces as set by :ref:`indent_use_spaces<class_CodeEdit_property_indent_use_spaces>`.
Values of ``-1`` convert the entire text.
.. rst-class:: classref-item-separator
----
.. _class_CodeEdit_method_do_indent:
.. rst-class:: classref-method

View File

@@ -12,14 +12,16 @@ CollisionPolygon2D
**Inherits:** :ref:`Node2D<class_Node2D>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
Defines a 2D collision polygon.
Node that represents a 2D collision polygon.
.. rst-class:: classref-introduction-group
Description
-----------
Provides a concave or convex 2D collision polygon to a :ref:`CollisionObject2D<class_CollisionObject2D>` parent. Polygons can be drawn in the editor or specified by a list of vertices. See also :ref:`ConvexPolygonShape2D<class_ConvexPolygonShape2D>`.
Provides a 2D collision polygon to a :ref:`CollisionObject2D<class_CollisionObject2D>` parent. Polygons can be drawn in the editor or specified by a list of vertices.
Depending on the build mode, this node effectively provides several convex shapes (by convex decomposition of the polygon) or a single concave shape made of the polygon's segments.
In the editor, a **CollisionPolygon2D** can be generated from a :ref:`Sprite2D<class_Sprite2D>`'s outline by selecting a :ref:`Sprite2D<class_Sprite2D>` node, going to the **Sprite2D** menu at the top of the 2D editor viewport then choosing **Create CollisionPolygon2D Sibling**.
@@ -64,7 +66,7 @@ enum **BuildMode**:
:ref:`BuildMode<enum_CollisionPolygon2D_BuildMode>` **BUILD_SOLIDS** = ``0``
Collisions will include the polygon and its contained area.
Collisions will include the polygon and its contained area. In this mode the node has the same effect as several :ref:`ConvexPolygonShape2D<class_ConvexPolygonShape2D>` nodes, one for each convex shape in the convex decomposition of the polygon (but without the overhead of multiple nodes).
.. _class_CollisionPolygon2D_constant_BUILD_SEGMENTS:
@@ -72,7 +74,7 @@ Collisions will include the polygon and its contained area.
:ref:`BuildMode<enum_CollisionPolygon2D_BuildMode>` **BUILD_SEGMENTS** = ``1``
Collisions will only include the polygon edges.
Collisions will only include the polygon edges. In this mode the node has the same effect as a single :ref:`ConcavePolygonShape2D<class_ConcavePolygonShape2D>` made of segments, with the restriction that each segment (after the first one) starts where the previous one ends, and the last one ends where the first one starts (forming a closed but hollow polygon).
.. rst-class:: classref-section-separator
@@ -164,7 +166,9 @@ The margin used for one-way collision (in pixels). Higher values will make the s
- void **set_polygon** **(** :ref:`PackedVector2Array<class_PackedVector2Array>` value **)**
- :ref:`PackedVector2Array<class_PackedVector2Array>` **get_polygon** **(** **)**
The polygon's list of vertices. The final point will be connected to the first. The returned value is a clone of the :ref:`PackedVector2Array<class_PackedVector2Array>`, not a reference.
The polygon's list of vertices. Each point will be connected to the next, and the final point will be connected to the first.
\ **Warning:** The returned value is a clone of the :ref:`PackedVector2Array<class_PackedVector2Array>`, not a reference.
.. |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.)`

View File

@@ -12,16 +12,16 @@ CollisionPolygon3D
**Inherits:** :ref:`Node3D<class_Node3D>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
Editor-only node for defining a collision polygon in 3D space.
Node that represents a 3D collision polygon, given by the thickening of a 2D polygon in the local XY plane along the local Z axis.
.. rst-class:: classref-introduction-group
Description
-----------
Allows editing a concave or convex collision polygon's vertices on a selected plane. Can also set a depth perpendicular to that plane. This class is only available in the editor. It will not appear in the scene tree at run-time. Creates several :ref:`ConvexPolygonShape3D<class_ConvexPolygonShape3D>`\ s at run-time to represent the original polygon using convex decomposition.
Provides a 3D collision polygon to a :ref:`CollisionObject3D<class_CollisionObject3D>` parent, by thickening a 2D (convex or concave) polygon in the local XY plane along the local Z axis. The 2D polygon in the local XY plane can be drawn in the editor or specified by a list of vertices. That 2D polygon is thickened evenly in the local Z and -Z directions.
\ **Note:** Since this is an editor-only helper, properties modified during gameplay will have no effect.
This node has the same effect as several :ref:`ConvexPolygonShape3D<class_ConvexPolygonShape3D>` nodes, created by thickening the 2D convex polygons in the convex decomposition of the given 2D polygon (but without the overhead of multiple nodes).
\ **Warning:** A non-uniformly scaled CollisionPolygon3D node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change its :ref:`polygon<class_CollisionPolygon3D_property_polygon>`'s vertices instead.
@@ -63,7 +63,7 @@ Property Descriptions
- void **set_depth** **(** :ref:`float<class_float>` value **)**
- :ref:`float<class_float>` **get_depth** **(** **)**
Length that the resulting collision extends in either direction perpendicular to its polygon.
Length that the resulting collision extends in either direction perpendicular to its 2D polygon.
.. rst-class:: classref-item-separator
@@ -114,7 +114,7 @@ The collision margin for the generated :ref:`Shape3D<class_Shape3D>`. See :ref:`
- void **set_polygon** **(** :ref:`PackedVector2Array<class_PackedVector2Array>` value **)**
- :ref:`PackedVector2Array<class_PackedVector2Array>` **get_polygon** **(** **)**
Array of vertices which define the polygon.
Array of vertices which define the 2D polygon in the local XY plane.
\ **Note:** The returned value is a copy of the original. Methods which mutate the size or properties of the return value will not impact the original polygon. To change properties of the polygon, assign it to a temporary variable and make changes before reassigning the ``polygon`` member.

View File

@@ -19,7 +19,7 @@ Node that represents collision shape data in 2D space.
Description
-----------
Editor facility for creating and editing collision shapes in 2D space. Set the :ref:`shape<class_CollisionShape2D_property_shape>` property to configure the shape. **IMPORTANT**: this is an Editor-only helper to create shapes, use :ref:`CollisionObject2D.shape_owner_get_shape<class_CollisionObject2D_method_shape_owner_get_shape>` to get the actual shape.
Editor facility for creating and editing collision shapes in 2D space. Set the :ref:`shape<class_CollisionShape2D_property_shape>` property to configure the shape.
You can use this node to represent all sorts of collision shapes, for example, add this to an :ref:`Area2D<class_Area2D>` to give it a detection shape, or add it to a :ref:`PhysicsBody2D<class_PhysicsBody2D>` to create a solid object.

View File

@@ -19,7 +19,7 @@ Node that represents collision shape data in 3D space.
Description
-----------
Editor facility for creating and editing collision shapes in 3D space. Set the :ref:`shape<class_CollisionShape3D_property_shape>` property to configure the shape. **IMPORTANT**: this is an Editor-only helper to create shapes, use :ref:`CollisionObject3D.shape_owner_get_shape<class_CollisionObject3D_method_shape_owner_get_shape>` to get the actual shape.
Editor facility for creating and editing collision shapes in 3D space. Set the :ref:`shape<class_CollisionShape3D_property_shape>` property to configure the shape.
You can use this node to represent all sorts of collision shapes, for example, add this to an :ref:`Area3D<class_Area3D>` to give it a detection shape, or add it to a :ref:`PhysicsBody3D<class_PhysicsBody3D>` to create a solid object.

View File

@@ -92,43 +92,45 @@ Theme Properties
.. table::
:widths: auto
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`int<class_int>` | :ref:`h_width<class_ColorPicker_theme_constant_h_width>` | ``30`` |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`int<class_int>` | :ref:`label_width<class_ColorPicker_theme_constant_label_width>` | ``10`` |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`int<class_int>` | :ref:`margin<class_ColorPicker_theme_constant_margin>` | ``4`` |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`int<class_int>` | :ref:`sv_height<class_ColorPicker_theme_constant_sv_height>` | ``256`` |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`int<class_int>` | :ref:`sv_width<class_ColorPicker_theme_constant_sv_width>` | ``256`` |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`add_preset<class_ColorPicker_theme_icon_add_preset>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`bar_arrow<class_ColorPicker_theme_icon_bar_arrow>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`color_hue<class_ColorPicker_theme_icon_color_hue>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`color_okhsl_hue<class_ColorPicker_theme_icon_color_okhsl_hue>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`expanded_arrow<class_ColorPicker_theme_icon_expanded_arrow>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`folded_arrow<class_ColorPicker_theme_icon_folded_arrow>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`overbright_indicator<class_ColorPicker_theme_icon_overbright_indicator>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`picker_cursor<class_ColorPicker_theme_icon_picker_cursor>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`sample_bg<class_ColorPicker_theme_icon_sample_bg>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`screen_picker<class_ColorPicker_theme_icon_screen_picker>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`shape_circle<class_ColorPicker_theme_icon_shape_circle>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`shape_rect<class_ColorPicker_theme_icon_shape_rect>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`shape_rect_wheel<class_ColorPicker_theme_icon_shape_rect_wheel>` | |
+-----------------------------------+--------------------------------------------------------------------------------+---------+
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`int<class_int>` | :ref:`center_slider_grabbers<class_ColorPicker_theme_constant_center_slider_grabbers>` | ``1`` |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`int<class_int>` | :ref:`h_width<class_ColorPicker_theme_constant_h_width>` | ``30`` |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`int<class_int>` | :ref:`label_width<class_ColorPicker_theme_constant_label_width>` | ``10`` |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`int<class_int>` | :ref:`margin<class_ColorPicker_theme_constant_margin>` | ``4`` |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`int<class_int>` | :ref:`sv_height<class_ColorPicker_theme_constant_sv_height>` | ``256`` |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`int<class_int>` | :ref:`sv_width<class_ColorPicker_theme_constant_sv_width>` | ``256`` |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`add_preset<class_ColorPicker_theme_icon_add_preset>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`bar_arrow<class_ColorPicker_theme_icon_bar_arrow>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`color_hue<class_ColorPicker_theme_icon_color_hue>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`color_okhsl_hue<class_ColorPicker_theme_icon_color_okhsl_hue>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`expanded_arrow<class_ColorPicker_theme_icon_expanded_arrow>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`folded_arrow<class_ColorPicker_theme_icon_folded_arrow>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`overbright_indicator<class_ColorPicker_theme_icon_overbright_indicator>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`picker_cursor<class_ColorPicker_theme_icon_picker_cursor>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`sample_bg<class_ColorPicker_theme_icon_sample_bg>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`screen_picker<class_ColorPicker_theme_icon_screen_picker>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`shape_circle<class_ColorPicker_theme_icon_shape_circle>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`shape_rect<class_ColorPicker_theme_icon_shape_rect>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`shape_rect_wheel<class_ColorPicker_theme_icon_shape_rect_wheel>` | |
+-----------------------------------+----------------------------------------------------------------------------------------+---------+
.. rst-class:: classref-section-separator
@@ -554,6 +556,18 @@ Returns the list of colors in the recent presets of the color picker.
Theme Property Descriptions
---------------------------
.. _class_ColorPicker_theme_constant_center_slider_grabbers:
.. rst-class:: classref-themeproperty
:ref:`int<class_int>` **center_slider_grabbers** = ``1``
Overrides the :ref:`HSlider.center_grabber<class_HSlider_theme_constant_center_grabber>` theme property of the sliders.
.. rst-class:: classref-item-separator
----
.. _class_ColorPicker_theme_constant_h_width:
.. rst-class:: classref-themeproperty

View File

@@ -21,14 +21,16 @@ Description
A cubemap that is loaded from a ``.ccube`` file. This file format is internal to Godot; it is created by importing other image formats with the import system. **CompressedCubemap** can use one of 4 compresson methods:
- Uncompressed (uncompressed on the GPU)
- Lossless (WebP or PNG, uncompressed on the GPU)
- Lossy (WebP, uncompressed on the GPU)
- VRAM Compressed (compressed on the GPU)
- VRAM Uncompressed (uncompressed on the GPU)
- Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to compress and lower quality than VRAM Compressed)
Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and **Lossy** compression methods will reduce the required storage on disk, but they will not reduce memory usage on the GPU as the texture is sent to the GPU uncompressed.
Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to load compared to textures using lossless or lossy compression. VRAM compression can exhibit noticeable artifacts and is intended to be used for 3D rendering, not 2D.

View File

@@ -21,14 +21,16 @@ Description
A cubemap array that is loaded from a ``.ccubearray`` file. This file format is internal to Godot; it is created by importing other image formats with the import system. **CompressedCubemapArray** can use one of 4 compresson methods:
- Uncompressed (uncompressed on the GPU)
- Lossless (WebP or PNG, uncompressed on the GPU)
- Lossy (WebP, uncompressed on the GPU)
- VRAM Compressed (compressed on the GPU)
- VRAM Uncompressed (uncompressed on the GPU)
- Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to compress and lower quality than VRAM Compressed)
Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and **Lossy** compression methods will reduce the required storage on disk, but they will not reduce memory usage on the GPU as the texture is sent to the GPU uncompressed.
Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to load compared to textures using lossless or lossy compression. VRAM compression can exhibit noticeable artifacts and is intended to be used for 3D rendering, not 2D.

View File

@@ -21,14 +21,16 @@ Description
A texture that is loaded from a ``.ctex`` file. This file format is internal to Godot; it is created by importing other image formats with the import system. **CompressedTexture2D** can use one of 4 compression methods (including a lack of any compression):
- Uncompressed (uncompressed on the GPU)
- Lossless (WebP or PNG, uncompressed on the GPU)
- Lossy (WebP, uncompressed on the GPU)
- VRAM Compressed (compressed on the GPU)
- VRAM Uncompressed (uncompressed on the GPU)
- Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to compress and lower quality than VRAM Compressed)
Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and **Lossy** compression methods will reduce the required storage on disk, but they will not reduce memory usage on the GPU as the texture is sent to the GPU uncompressed.
Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to load compared to textures using lossless or lossy compression. VRAM compression can exhibit noticeable artifacts and is intended to be used for 3D rendering, not 2D.

View File

@@ -21,14 +21,16 @@ Description
A texture array that is loaded from a ``.ctexarray`` file. This file format is internal to Godot; it is created by importing other image formats with the import system. **CompressedTexture2DArray** can use one of 4 compresson methods:
- Uncompressed (uncompressed on the GPU)
- Lossless (WebP or PNG, uncompressed on the GPU)
- Lossy (WebP, uncompressed on the GPU)
- VRAM Compressed (compressed on the GPU)
- VRAM Uncompressed (uncompressed on the GPU)
- Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to compress and lower quality than VRAM Compressed)
Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and **Lossy** compression methods will reduce the required storage on disk, but they will not reduce memory usage on the GPU as the texture is sent to the GPU uncompressed.
Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to load compared to textures using lossless or lossy compression. VRAM compression can exhibit noticeable artifacts and is intended to be used for 3D rendering, not 2D.

View File

@@ -21,19 +21,7 @@ Base class for texture arrays that can optionally be compressed.
Description
-----------
A texture array that is loaded from a ``.ctexarray`` file. This file format is internal to Godot; it is created by importing other image formats with the import system. :ref:`CompressedTexture2D<class_CompressedTexture2D>` can use one of 4 compresson methods:
- Uncompressed (uncompressed on the GPU)
- Lossless (WebP or PNG, uncompressed on the GPU)
- Lossy (WebP, uncompressed on the GPU)
- VRAM Compressed (compressed on the GPU)
Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and **Lossy** compression methods will reduce the required storage on disk, but they will not reduce memory usage on the GPU as the texture is sent to the GPU uncompressed.
Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to load compared to textures using lossless or lossy compression. VRAM compression can exhibit noticeable artifacts and is intended to be used for 3D rendering, not 2D.
Base class for :ref:`CompressedTexture2DArray<class_CompressedTexture2DArray>` and :ref:`CompressedTexture3D<class_CompressedTexture3D>`. Cannot be used directly, but contains all the functions necessary for accessing the derived resource types. See also :ref:`TextureLayered<class_TextureLayered>`.
.. rst-class:: classref-reftable-group

View File

@@ -19,14 +19,20 @@ Concave polygon shape resource for 2D physics.
Description
-----------
2D concave polygon shape to be added as a *direct* child of a :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`Area2D<class_Area2D>` using a :ref:`CollisionShape2D<class_CollisionShape2D>` node. It is made out of segments and is optimal for complex polygonal concave collisions. However, it is not advised to use for :ref:`RigidBody2D<class_RigidBody2D>` nodes. A CollisionPolygon2D in convex decomposition mode (solids) or several convex objects are advised for that instead. Otherwise, a concave polygon 2D shape is better for static collisions.
2D concave polygon shape to be added as a *direct* child of a :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`Area2D<class_Area2D>` using a :ref:`CollisionShape2D<class_CollisionShape2D>` node.
The main difference between a :ref:`ConvexPolygonShape2D<class_ConvexPolygonShape2D>` and a **ConcavePolygonShape2D** is that a concave polygon assumes it is concave and uses a more complex method of collision detection, and a convex one forces itself to be convex to speed up collision detection.
The shape consists of a collection of line segments, and as such it does not include any "inside" that the segments might be enclosing. If the segments do enclose anything, then the shape is *hollow*, as opposed to a :ref:`ConvexPolygonShape2D<class_ConvexPolygonShape2D>` which is solid. See also :ref:`CollisionPolygon2D<class_CollisionPolygon2D>`.
\ **Performance:** Due to its complexity, **ConcavePolygonShape2D** is the slowest collision shape to check collisions against. Its use should generally be limited to level geometry. For convex geometry, using :ref:`ConvexPolygonShape2D<class_ConvexPolygonShape2D>` will perform better. For dynamic physics bodies that need concave collision, several :ref:`ConvexPolygonShape2D<class_ConvexPolygonShape2D>`\ s can be used to represent its collision by using convex decomposition; see :ref:`ConvexPolygonShape2D<class_ConvexPolygonShape2D>`'s documentation for instructions. However, consider using primitive collision shapes such as :ref:`CircleShape2D<class_CircleShape2D>` or :ref:`RectangleShape2D<class_RectangleShape2D>` first.
Being made out of line segments, this shape is the most freely configurable single 2D shape. It can be used to form (hollow) polygons of any nature, convex or concave.
\ **Note:** When used for collision, **ConcavePolygonShape2D** is intended to work with static :ref:`PhysicsBody2D<class_PhysicsBody2D>` nodes like :ref:`StaticBody2D<class_StaticBody2D>` and is not recommended to use with :ref:`RigidBody2D<class_RigidBody2D>` nodes in a mode other than Static. A :ref:`CollisionPolygon2D<class_CollisionPolygon2D>` in convex decomposition mode (solids) or several convex objects are advised for that instead. Otherwise, a concave polygon 2D shape is better suited for static bodies.
\ **Warning:** The nature of this shape makes it extra prone to being tunneled through by (small) fast physics bodies. For example, consider a (small) rigid body *Ball* traveling toward a static body *Box* at high speed. If the box uses a **ConcavePolygonShape2D** consisting of four segments, then the ball might end up inside the box or tunnel all the way through the box, if it goes fast enough. This is (partly) because the ball can only collide against the individual segments of the hollow box. In interactions with rigid bodies tunneling can be avoided by enabling continuous collision detection on the rigid body.
\ **Warning:** Using this shape for an :ref:`Area2D<class_Area2D>` (via a :ref:`CollisionShape2D<class_CollisionShape2D>` node) may give unexpected results: the area will only detect collisions with the segments in the **ConcavePolygonShape2D** (and not with any "inside" of the shape, for example).
\ **Performance:** Due to its complexity, **ConcavePolygonShape2D** is the slowest collision shape to check collisions against. Its use should generally be limited to level geometry. For convex geometry, using :ref:`ConvexPolygonShape2D<class_ConvexPolygonShape2D>` will perform better. For dynamic physics bodies that need concave collision, several :ref:`ConvexPolygonShape2D<class_ConvexPolygonShape2D>`\ s can be used to represent its collision by using convex decomposition; see :ref:`ConvexPolygonShape2D<class_ConvexPolygonShape2D>`'s documentation for instructions. However, consider using primitive collision shapes such as :ref:`CircleShape2D<class_CircleShape2D>` or :ref:`RectangleShape2D<class_RectangleShape2D>` first.
.. rst-class:: classref-reftable-group
Properties
@@ -59,7 +65,7 @@ Property Descriptions
- void **set_segments** **(** :ref:`PackedVector2Array<class_PackedVector2Array>` value **)**
- :ref:`PackedVector2Array<class_PackedVector2Array>` **get_segments** **(** **)**
The array of points that make up the **ConcavePolygonShape2D**'s line segments.
The array of points that make up the **ConcavePolygonShape2D**'s line segments. The array (of length divisible by two) is naturally divided into pairs (one pair for each segment); each pair consists of the starting point of a segment and the endpoint of a segment.
.. |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.)`

View File

@@ -19,14 +19,20 @@ Concave polygon shape resource (also called "trimesh") for 3D physics.
Description
-----------
3D concave polygon shape resource (also called "trimesh") to be added as a *direct* child of a :ref:`PhysicsBody3D<class_PhysicsBody3D>` or :ref:`Area3D<class_Area3D>` using a :ref:`CollisionShape3D<class_CollisionShape3D>` node. This shape is created by feeding a list of triangles. Despite its name, **ConcavePolygonShape3D** can also store convex polygon shapes. However, unlike :ref:`ConvexPolygonShape3D<class_ConvexPolygonShape3D>`, **ConcavePolygonShape3D** is *not* limited to storing convex shapes exclusively.
3D concave polygon shape resource (also called "trimesh") to be added as a *direct* child of a :ref:`PhysicsBody3D<class_PhysicsBody3D>` or :ref:`Area3D<class_Area3D>` using a :ref:`CollisionShape3D<class_CollisionShape3D>` node.
\ **Note:** When used for collision, **ConcavePolygonShape3D** is intended to work with static :ref:`PhysicsBody3D<class_PhysicsBody3D>` nodes like :ref:`StaticBody3D<class_StaticBody3D>` and will not work with :ref:`CharacterBody3D<class_CharacterBody3D>` or :ref:`RigidBody3D<class_RigidBody3D>` with a mode other than Static.
The shape consists of a collection of triangle faces, and as such it does not include any "inside" that the faces might be enclosing. If the faces enclose anything, then the shape is *hollow*, as opposed to a :ref:`ConvexPolygonShape3D<class_ConvexPolygonShape3D>` which is solid. See also :ref:`CollisionPolygon3D<class_CollisionPolygon3D>`.
\ **Performance:** Due to its complexity, **ConcavePolygonShape3D** is the slowest collision shape to check collisions against. Its use should generally be limited to level geometry. For convex geometry, using :ref:`ConvexPolygonShape3D<class_ConvexPolygonShape3D>` will perform better. For dynamic physics bodies that need concave collision, several :ref:`ConvexPolygonShape3D<class_ConvexPolygonShape3D>`\ s can be used to represent its collision by using convex decomposition; see :ref:`ConvexPolygonShape3D<class_ConvexPolygonShape3D>`'s documentation for instructions. However, consider using primitive collision shapes such as :ref:`SphereShape3D<class_SphereShape3D>` or :ref:`BoxShape3D<class_BoxShape3D>` first.
Being made out of triangle faces, this shape is the most freely configurable single 3D shape. Despite its name, it can be used to form (hollow) polyhedra of any nature, convex or concave.
\ **Note:** When used for collision, **ConcavePolygonShape3D** is intended to work with static :ref:`PhysicsBody3D<class_PhysicsBody3D>` nodes like :ref:`StaticBody3D<class_StaticBody3D>` and will not work with :ref:`CharacterBody3D<class_CharacterBody3D>` or :ref:`RigidBody3D<class_RigidBody3D>` in a mode other than Static.
\ **Warning:** The nature of this shape makes it extra prone to being tunneled through by (small) fast physics bodies. For example, consider a (small) rigid body *Ball* traveling toward a static body *Box* at high speed. If the box uses a **ConcavePolygonShape3D** consisting of twelve triangle faces (two triangle faces for each of the six sides of the box), then the ball might end up inside the box or tunnel all the way through the box, if it goes fast enough. This is (partly) because the ball can only collide against the individual faces of the hollow box. In interactions with rigid bodies tunneling can be avoided by enabling continuous collision detection on the rigid body.
\ **Warning:** Using this shape for an :ref:`Area3D<class_Area3D>` (via a :ref:`CollisionShape3D<class_CollisionShape3D>` node, created e.g. by using the *Create Trimesh Collision Sibling* option in the *Mesh* menu that appears when selecting a :ref:`MeshInstance3D<class_MeshInstance3D>` node) may give unexpected results: the area will only detect collisions with the triangle faces in the **ConcavePolygonShape3D** (and not with any "inside" of the shape, for example); moreover it will only detect all such collisions if :ref:`backface_collision<class_ConcavePolygonShape3D_property_backface_collision>` is ``true``.
\ **Performance:** Due to its complexity, **ConcavePolygonShape3D** is the slowest collision shape to check collisions against. Its use should generally be limited to level geometry. For convex geometry, using :ref:`ConvexPolygonShape3D<class_ConvexPolygonShape3D>` will perform better. For dynamic physics bodies that need concave collision, several :ref:`ConvexPolygonShape3D<class_ConvexPolygonShape3D>`\ s can be used to represent its collision by using convex decomposition; see :ref:`ConvexPolygonShape3D<class_ConvexPolygonShape3D>`'s documentation for instructions. However, consider using primitive collision shapes such as :ref:`SphereShape3D<class_SphereShape3D>` or :ref:`BoxShape3D<class_BoxShape3D>` first.
.. rst-class:: classref-introduction-group
Tutorials
@@ -97,7 +103,7 @@ Method Descriptions
:ref:`PackedVector3Array<class_PackedVector3Array>` **get_faces** **(** **)** |const|
Returns the faces (an array of triangles).
Returns the faces of the trimesh shape as an array of vertices. The array (of length divisible by three) is naturally divided into triples; each triple of vertices defines a triangle.
.. rst-class:: classref-item-separator
@@ -109,7 +115,7 @@ Returns the faces (an array of triangles).
void **set_faces** **(** :ref:`PackedVector3Array<class_PackedVector3Array>` faces **)**
Sets the faces (an array of triangles).
Sets the faces of the trimesh shape from an array of vertices. The ``faces`` array should be composed of triples such that each triple of vertices defines a triangle.
.. |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.)`

View File

@@ -247,9 +247,7 @@ Method Descriptions
:ref:`float<class_float>` **get_param** **(** :ref:`Param<enum_ConeTwistJoint3D_Param>` param **)** |const|
.. container:: contribute
There is currently no description for this method. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
Returns the value of the specified parameter.
.. rst-class:: classref-item-separator
@@ -261,9 +259,7 @@ Method Descriptions
void **set_param** **(** :ref:`Param<enum_ConeTwistJoint3D_Param>` param, :ref:`float<class_float>` value **)**
.. container:: contribute
There is currently no description for this method. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
Sets the value of the specified 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.)`

View File

@@ -159,6 +159,8 @@ Methods
+----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Vector2<class_Vector2>` | :ref:`_get_minimum_size<class_Control_method__get_minimum_size>` **(** **)** |virtual| |const| |
+----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`_get_tooltip<class_Control_method__get_tooltip>` **(** :ref:`Vector2<class_Vector2>` at_position **)** |virtual| |const| |
+----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`_gui_input<class_Control_method__gui_input>` **(** :ref:`InputEvent<class_InputEvent>` event **)** |virtual| |
+----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_has_point<class_Control_method__has_point>` **(** :ref:`Vector2<class_Vector2>` point **)** |virtual| |const| |
@@ -1223,7 +1225,7 @@ Anchors the top edge of the node to the origin, the center or the end of its par
- void **set_auto_translate** **(** :ref:`bool<class_bool>` value **)**
- :ref:`bool<class_bool>` **is_auto_translating** **(** **)**
Toggles if any text should automatically change to its translated version depending on the current locale. Note that this will not affect any internal nodes (e.g. the popup of a :ref:`MenuButton<class_MenuButton>`).
Toggles if any text should automatically change to its translated version depending on the current locale.
Also decides if the node's strings should be parsed for POT generation.
@@ -1327,7 +1329,7 @@ Tells Godot which node it should give focus to if the user presses the left arro
- void **set_focus_neighbor** **(** :ref:`Side<enum_@GlobalScope_Side>` side, :ref:`NodePath<class_NodePath>` neighbor **)**
- :ref:`NodePath<class_NodePath>` **get_focus_neighbor** **(** :ref:`Side<enum_@GlobalScope_Side>` side **)** |const|
Tells Godot which node it should give focus to if the user presses the right arrow on the keyboard or right on a gamepad by default. You can change the key by editing the :ref:`ProjectSettings.input/ui_right<class_ProjectSettings_property_input/ui_right>` input action. The node must be a **Control**. If this property is not set, Godot will give focus to the closest **Control** to the bottom of this one.
Tells Godot which node it should give focus to if the user presses the right arrow on the keyboard or right on a gamepad by default. You can change the key by editing the :ref:`ProjectSettings.input/ui_right<class_ProjectSettings_property_input/ui_right>` input action. The node must be a **Control**. If this property is not set, Godot will give focus to the closest **Control** to the right of this one.
.. rst-class:: classref-item-separator
@@ -1344,7 +1346,7 @@ Tells Godot which node it should give focus to if the user presses the right arr
- void **set_focus_neighbor** **(** :ref:`Side<enum_@GlobalScope_Side>` side, :ref:`NodePath<class_NodePath>` neighbor **)**
- :ref:`NodePath<class_NodePath>` **get_focus_neighbor** **(** :ref:`Side<enum_@GlobalScope_Side>` side **)** |const|
Tells Godot which node it should give focus to if the user presses the top arrow on the keyboard or top on a gamepad by default. You can change the key by editing the :ref:`ProjectSettings.input/ui_up<class_ProjectSettings_property_input/ui_up>` input action. The node must be a **Control**. If this property is not set, Godot will give focus to the closest **Control** to the bottom of this one.
Tells Godot which node it should give focus to if the user presses the top arrow on the keyboard or top on a gamepad by default. You can change the key by editing the :ref:`ProjectSettings.input/ui_up<class_ProjectSettings_property_input/ui_up>` input action. The node must be a **Control**. If this property is not set, Godot will give focus to the closest **Control** to the top of this one.
.. rst-class:: classref-item-separator
@@ -1993,6 +1995,20 @@ If not overridden, defaults to :ref:`Vector2.ZERO<class_Vector2_constant_ZERO>`.
----
.. _class_Control_method__get_tooltip:
.. rst-class:: classref-method
:ref:`String<class_String>` **_get_tooltip** **(** :ref:`Vector2<class_Vector2>` at_position **)** |virtual| |const|
Virtual method to be implemented by the user. Returns the tooltip text for the position ``at_position`` in control's local coordinates, which will typically appear when the cursor is resting over this control. See :ref:`get_tooltip<class_Control_method_get_tooltip>`.
\ **Note:** If this method returns an empty :ref:`String<class_String>`, no tooltip is displayed.
.. rst-class:: classref-item-separator
----
.. _class_Control_method__gui_input:
.. rst-class:: classref-method
@@ -2150,6 +2166,8 @@ void **accept_event** **(** **)**
Marks an input event as handled. Once you accept an input event, it stops propagating, even to nodes listening to :ref:`Node._unhandled_input<class_Node_method__unhandled_input>` or :ref:`Node._unhandled_key_input<class_Node_method__unhandled_key_input>`.
\ **Note:** This does not affect the methods in :ref:`Input<class_Input>`, only the way events are propagated.
.. rst-class:: classref-item-separator
----
@@ -2462,7 +2480,7 @@ Returns the minimum size for this control. See :ref:`custom_minimum_size<class_C
:ref:`float<class_float>` **get_offset** **(** :ref:`Side<enum_@GlobalScope_Side>` offset **)** |const|
Returns the anchor for the specified :ref:`Side<enum_@GlobalScope_Side>`. A getter method for :ref:`offset_bottom<class_Control_property_offset_bottom>`, :ref:`offset_left<class_Control_property_offset_left>`, :ref:`offset_right<class_Control_property_offset_right>` and :ref:`offset_top<class_Control_property_offset_top>`.
Returns the offset for the specified :ref:`Side<enum_@GlobalScope_Side>`. A getter method for :ref:`offset_bottom<class_Control_property_offset_bottom>`, :ref:`offset_left<class_Control_property_offset_left>`, :ref:`offset_right<class_Control_property_offset_right>` and :ref:`offset_top<class_Control_property_offset_top>`.
.. rst-class:: classref-item-separator
@@ -2685,9 +2703,11 @@ See :ref:`get_theme_color<class_Control_method_get_theme_color>` for details.
:ref:`String<class_String>` **get_tooltip** **(** :ref:`Vector2<class_Vector2>` at_position=Vector2(0, 0) **)** |const|
Returns the tooltip text ``at_position`` in local coordinates, which will typically appear when the cursor is resting over this control. By default, it returns :ref:`tooltip_text<class_Control_property_tooltip_text>`.
Returns the tooltip text for the position ``at_position`` in control's local coordinates, which will typically appear when the cursor is resting over this control. By default, it returns :ref:`tooltip_text<class_Control_property_tooltip_text>`.
\ **Note:** This method can be overridden to customize its behavior. If this method returns an empty :ref:`String<class_String>`, no tooltip is displayed.
This method can be overridden to customize its behavior. See :ref:`_get_tooltip<class_Control_method__get_tooltip>`.
\ **Note:** If this method returns an empty :ref:`String<class_String>`, no tooltip is displayed.
.. rst-class:: classref-item-separator
@@ -3182,7 +3202,7 @@ Sets :ref:`offset_right<class_Control_property_offset_right>` and :ref:`offset_b
void **set_focus_neighbor** **(** :ref:`Side<enum_@GlobalScope_Side>` side, :ref:`NodePath<class_NodePath>` neighbor **)**
Sets the anchor for the specified :ref:`Side<enum_@GlobalScope_Side>` to the **Control** at ``neighbor`` node path. A setter method for :ref:`focus_neighbor_bottom<class_Control_property_focus_neighbor_bottom>`, :ref:`focus_neighbor_left<class_Control_property_focus_neighbor_left>`, :ref:`focus_neighbor_right<class_Control_property_focus_neighbor_right>` and :ref:`focus_neighbor_top<class_Control_property_focus_neighbor_top>`.
Sets the focus neighbor for the specified :ref:`Side<enum_@GlobalScope_Side>` to the **Control** at ``neighbor`` node path. A setter method for :ref:`focus_neighbor_bottom<class_Control_property_focus_neighbor_bottom>`, :ref:`focus_neighbor_left<class_Control_property_focus_neighbor_left>`, :ref:`focus_neighbor_right<class_Control_property_focus_neighbor_right>` and :ref:`focus_neighbor_top<class_Control_property_focus_neighbor_top>`.
.. rst-class:: classref-item-separator

View File

@@ -19,11 +19,15 @@ Convex polygon shape resource for 2D physics.
Description
-----------
2D convex polygon shape to be added as a *direct* child of a :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`Area2D<class_Area2D>` using a :ref:`CollisionShape2D<class_CollisionShape2D>` node. A convex polygon, whatever its shape, is internally decomposed into as many convex polygons as needed to ensure all collision checks against it are always done on convex polygons (which are faster to check). See also :ref:`CollisionPolygon2D<class_CollisionPolygon2D>`.
2D convex polygon shape to be added as a *direct* child of a :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`Area2D<class_Area2D>` using a :ref:`CollisionShape2D<class_CollisionShape2D>` node.
The main difference between a **ConvexPolygonShape2D** and a :ref:`ConcavePolygonShape2D<class_ConcavePolygonShape2D>` is that a concave polygon assumes it is concave and uses a more complex method of collision detection, and a convex one forces itself to be convex to speed up collision detection.
The shape is a *solid* that includes all the points that it encloses, as opposed to :ref:`ConcavePolygonShape2D<class_ConcavePolygonShape2D>` which is hollow if it encloses anything. See also :ref:`CollisionPolygon2D<class_CollisionPolygon2D>`.
\ **Performance:** **ConvexPolygonShape2D** is faster to check collisions against compared to :ref:`ConcavePolygonShape2D<class_ConcavePolygonShape2D>`, but it is slower than primitive collision shapes such as :ref:`CircleShape2D<class_CircleShape2D>` or :ref:`RectangleShape2D<class_RectangleShape2D>`. Its use should generally be limited to medium-sized objects that cannot have their collision accurately represented by a primitive shape.
The solid nature of the shape makes it well-suited for both detection and physics; in physics body interactions this allows depenetrating even those shapes which end up (e.g. due to high speed) fully inside the convex shape (similarly to primitive shapes, but unlike :ref:`ConcavePolygonShape2D<class_ConcavePolygonShape2D>`). The convexity limits the possible geometric shape of a single **ConvexPolygonShape2D**: it cannot be concave.
\ **Convex decomposition:** Concave objects' collisions can be represented accurately using *several* convex shapes. This allows dynamic physics bodies to have complex concave collisions (at a performance cost). It can be achieved using several **ConvexPolygonShape2D** nodes or by using the :ref:`CollisionPolygon2D<class_CollisionPolygon2D>` node in Solids build mode. To generate a collision polygon from a sprite, select the :ref:`Sprite2D<class_Sprite2D>` node, go to the **Sprite2D** menu that appears above the viewport, and choose **Create Polygon2D Sibling**.
\ **Performance:** **ConvexPolygonShape2D** is faster to check collisions against compared to :ref:`ConcavePolygonShape2D<class_ConcavePolygonShape2D>`, but it is slower than primitive collision shapes such as :ref:`CircleShape2D<class_CircleShape2D>` or :ref:`RectangleShape2D<class_RectangleShape2D>`. Its use should generally be limited to medium-sized objects that cannot have their collision accurately represented by primitive shapes.
.. rst-class:: classref-reftable-group
@@ -69,7 +73,9 @@ Property Descriptions
- void **set_points** **(** :ref:`PackedVector2Array<class_PackedVector2Array>` value **)**
- :ref:`PackedVector2Array<class_PackedVector2Array>` **get_points** **(** **)**
The polygon's list of vertices. Can be in either clockwise or counterclockwise order. Only set this property with convex hull points, use :ref:`set_point_cloud<class_ConvexPolygonShape2D_method_set_point_cloud>` to generate a convex hull shape from concave shape points.
The polygon's list of vertices that form a convex hull. Can be in either clockwise or counterclockwise order.
\ **Warning:** Only set this property to a list of points that actually form a convex hull. Use :ref:`set_point_cloud<class_ConvexPolygonShape2D_method_set_point_cloud>` to generate the convex hull of an arbitrary set of points.
.. rst-class:: classref-section-separator
@@ -86,7 +92,7 @@ Method Descriptions
void **set_point_cloud** **(** :ref:`PackedVector2Array<class_PackedVector2Array>` point_cloud **)**
Based on the set of points provided, this creates and assigns the :ref:`points<class_ConvexPolygonShape2D_property_points>` property using the convex hull algorithm. Removing all unneeded points. See :ref:`Geometry2D.convex_hull<class_Geometry2D_method_convex_hull>` for details.
Based on the set of points provided, this assigns the :ref:`points<class_ConvexPolygonShape2D_property_points>` property using the convex hull algorithm, removing all unneeded points. See :ref:`Geometry2D.convex_hull<class_Geometry2D_method_convex_hull>` for 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.)`

View File

@@ -19,11 +19,15 @@ Convex polygon shape resource for 3D physics.
Description
-----------
3D convex polygon shape resource to be added as a *direct* child of a :ref:`PhysicsBody3D<class_PhysicsBody3D>` or :ref:`Area3D<class_Area3D>` using a :ref:`CollisionShape3D<class_CollisionShape3D>` node. Unlike :ref:`ConcavePolygonShape3D<class_ConcavePolygonShape3D>`, **ConvexPolygonShape3D** cannot store concave polygon shapes. **ConvexPolygonShape3D**\ s can be manually drawn in the editor using the :ref:`CollisionPolygon3D<class_CollisionPolygon3D>` node.
3D convex polygon shape resource to be added as a *direct* child of a :ref:`PhysicsBody3D<class_PhysicsBody3D>` or :ref:`Area3D<class_Area3D>` using a :ref:`CollisionShape3D<class_CollisionShape3D>` node.
\ **Convex decomposition:** Concave objects' collisions can be represented accurately using *several* **ConvexPolygonShape3D**\ s. This allows dynamic physics bodies to have complex concave collisions (at a performance cost). This is available in the editor by selecting the :ref:`MeshInstance3D<class_MeshInstance3D>`, going to the **Mesh** menu and choosing **Create Multiple Convex Collision Siblings**. Alternatively, :ref:`MeshInstance3D.create_multiple_convex_collisions<class_MeshInstance3D_method_create_multiple_convex_collisions>` can be called in a script to perform this decomposition at run-time.
The shape is a *solid* that includes all the points that it encloses, as opposed to :ref:`ConcavePolygonShape3D<class_ConcavePolygonShape3D>` which is hollow if it encloses anything. See also :ref:`CollisionPolygon3D<class_CollisionPolygon3D>`.
\ **Performance:** **ConvexPolygonShape3D** is faster to check collisions against compared to :ref:`ConcavePolygonShape3D<class_ConcavePolygonShape3D>`, but it is slower than primitive collision shapes such as :ref:`SphereShape3D<class_SphereShape3D>` or :ref:`BoxShape3D<class_BoxShape3D>`. Its use should generally be limited to medium-sized objects that cannot have their collision accurately represented by a primitive shape.
The solid nature of the shape makes it well-suited for both detection and physics; in physics body interactions this allows depenetrating even those shapes which end up (e.g. due to high speed) fully inside the convex shape (similarly to primitive shapes, but unlike :ref:`ConcavePolygonShape3D<class_ConcavePolygonShape3D>` and :ref:`HeightMapShape3D<class_HeightMapShape3D>`). The convexity restricts the possible geometric shape of a single **ConvexPolygonShape3D**: it cannot be concave.
\ **Convex decomposition:** Concave objects' collisions can be represented accurately using *several* convex shapes. This allows dynamic physics bodies to have complex concave collisions (at a performance cost). It can be achieved by using several **ConvexPolygonShape3D** nodes or by using the :ref:`CollisionPolygon3D<class_CollisionPolygon3D>` node. To generate a collision polygon from a mesh, select the :ref:`MeshInstance3D<class_MeshInstance3D>` node, go to the **Mesh** menu that appears above the viewport and choose **Create Multiple Convex Collision Siblings**. Alternatively, :ref:`MeshInstance3D.create_multiple_convex_collisions<class_MeshInstance3D_method_create_multiple_convex_collisions>` can be called in a script to perform this decomposition at run-time.
\ **Performance:** **ConvexPolygonShape3D** is faster to check collisions against compared to :ref:`ConcavePolygonShape3D<class_ConcavePolygonShape3D>`, but it is slower than primitive collision shapes such as :ref:`SphereShape3D<class_SphereShape3D>` or :ref:`BoxShape3D<class_BoxShape3D>`. Its use should generally be limited to medium-sized objects that cannot have their collision accurately represented by primitive shapes.
.. rst-class:: classref-introduction-group

View File

@@ -1662,7 +1662,7 @@ Particle system's running speed scaling ratio. A value of ``0`` can be used to p
- void **set_split_scale** **(** :ref:`bool<class_bool>` value **)**
- :ref:`bool<class_bool>` **get_split_scale** **(** **)**
If set to true, three different scale curves can be specified, one per scale axis.
If set to ``true``, three different scale curves can be specified, one per scale axis.
.. rst-class:: classref-item-separator

View File

@@ -44,7 +44,7 @@ For now, this includes generating cryptographically secure random bytes, RSA key
cert.save("user://generated.crt")
# Encryption
var data = "Some data"
var encrypted = crypto.encrypt(key, data.to_utf8())
var encrypted = crypto.encrypt(key, data.to_utf8_buffer())
# Decryption
var decrypted = crypto.decrypt(key, encrypted)
# Signing
@@ -53,7 +53,7 @@ For now, this includes generating cryptographically secure random bytes, RSA key
var verified = crypto.verify(HashingContext.HASH_SHA256, data.sha256_buffer(), signature, key)
# Checks
assert(verified)
assert(data.to_utf8() == decrypted)
assert(data.to_utf8_buffer() == decrypted)
.. code-tab:: csharp
@@ -77,7 +77,7 @@ For now, this includes generating cryptographically secure random bytes, RSA key
_cert.Save("user://generated.crt");
// Encryption
string data = "Some data";
byte[] encrypted = _crypto.Encrypt(_key, data.ToUtf8());
byte[] encrypted = _crypto.Encrypt(_key, data.ToUtf8Buffer());
// Decryption
byte[] decrypted = _crypto.Decrypt(_key, encrypted);
// Signing
@@ -86,7 +86,7 @@ For now, this includes generating cryptographically secure random bytes, RSA key
bool verified = _crypto.Verify(HashingContext.HashType.Sha256, Data.Sha256Buffer(), signature, _key);
// Checks
Debug.Assert(verified);
Debug.Assert(data.ToUtf8() == decrypted);
Debug.Assert(data.ToUtf8Buffer() == decrypted);
}
}

View File

@@ -226,7 +226,7 @@ The operation that is performed on this shape. This is ignored for the first CSG
- void **set_snap** **(** :ref:`float<class_float>` value **)**
- :ref:`float<class_float>` **get_snap** **(** **)**
Snap makes the mesh snap to a given distance so that the faces of two meshes can be perfectly aligned. A lower value results in greater precision but may be harder to adjust.
Snap makes the mesh vertices snap to a given distance so that the faces of two meshes can be perfectly aligned. A lower value results in greater precision but may be harder to adjust.
.. rst-class:: classref-item-separator

View File

@@ -378,7 +378,7 @@ If the curve has no up vectors, the function sends an error to the console, and
:ref:`Transform3D<class_Transform3D>` **sample_baked_with_rotation** **(** :ref:`float<class_float>` offset=0.0, :ref:`bool<class_bool>` cubic=false, :ref:`bool<class_bool>` apply_tilt=false **)** |const|
Similar with ``interpolate_baked()``. The the return value is ``Transform3D``, with ``origin`` as point position, ``basis.x`` as sideway vector, ``basis.y`` as up vector, ``basis.z`` as forward vector. When the curve length is 0, there is no reasonable way to calculate the rotation, all vectors aligned with global space axes.
Similar with ``interpolate_baked()``. The return value is ``Transform3D``, with ``origin`` as point position, ``basis.x`` as sideway vector, ``basis.y`` as up vector, ``basis.z`` as forward vector. When the curve length is 0, there is no reasonable way to calculate the rotation, all vectors aligned with global space axes.
.. rst-class:: classref-item-separator

View File

@@ -109,7 +109,7 @@ The :ref:`Curve<class_Curve>` that is rendered onto the texture.
- void **set_texture_mode** **(** :ref:`TextureMode<enum_CurveTexture_TextureMode>` value **)**
- :ref:`TextureMode<enum_CurveTexture_TextureMode>` **get_texture_mode** **(** **)**
The format the texture should be generated with. When passing a CurveTexture as a input to a :ref:`Shader<class_Shader>`, this may need to be adjusted.
The format the texture should be generated with. When passing a CurveTexture as an input to a :ref:`Shader<class_Shader>`, this may need to be adjusted.
.. rst-class:: classref-item-separator

View File

@@ -397,7 +397,7 @@ Sets the size of the :ref:`AABB<class_AABB>` used by the decal. All dimensions m
\ **Note:** Unlike :ref:`BaseMaterial3D<class_BaseMaterial3D>` whose filter mode can be adjusted on a per-material basis, the filter mode for **Decal** textures is set globally with :ref:`ProjectSettings.rendering/textures/decals/filter<class_ProjectSettings_property_rendering/textures/decals/filter>`.
\ **Note:** Setting this texture alone will not result in a visible decal, as :ref:`texture_albedo<class_Decal_property_texture_albedo>` must also be set. To create a ORM-only decal, load an albedo texture into :ref:`texture_albedo<class_Decal_property_texture_albedo>` and set :ref:`albedo_mix<class_Decal_property_albedo_mix>` to ``0.0``. The albedo texture's alpha channel will be used to determine where the underlying surface's ORM map should be overridden (and its intensity).
\ **Note:** Setting this texture alone will not result in a visible decal, as :ref:`texture_albedo<class_Decal_property_texture_albedo>` must also be set. To create an ORM-only decal, load an albedo texture into :ref:`texture_albedo<class_Decal_property_texture_albedo>` and set :ref:`albedo_mix<class_Decal_property_albedo_mix>` to ``0.0``. The albedo texture's alpha channel will be used to determine where the underlying surface's ORM map should be overridden (and its intensity).
.. rst-class:: classref-item-separator

View File

@@ -189,8 +189,6 @@ The keys of a dictionary can be iterated with the ``for`` keyword:
\ **Note:** Erasing elements while iterating over dictionaries is **not** supported and will result in unpredictable behavior.
\ **Note:** When declaring a dictionary with ``const``, the dictionary becomes read-only. A read-only Dictionary's entries cannot be overridden at run-time. This does *not* affect nested :ref:`Array<class_Array>` and **Dictionary** values.
.. rst-class:: classref-introduction-group
Tutorials

View File

@@ -195,7 +195,7 @@ Property Descriptions
- void **set_include_hidden** **(** :ref:`bool<class_bool>` value **)**
- :ref:`bool<class_bool>` **get_include_hidden** **(** **)**
If ``true``, hidden files are included when the navigating directory.
If ``true``, hidden files are included when navigating the directory.
Affects :ref:`list_dir_begin<class_DirAccess_method_list_dir_begin>`, :ref:`get_directories<class_DirAccess_method_get_directories>` and :ref:`get_files<class_DirAccess_method_get_files>`.
@@ -417,6 +417,8 @@ Returns a :ref:`PackedStringArray<class_PackedStringArray>` containing filenames
Affected by :ref:`include_hidden<class_DirAccess_property_include_hidden>`.
\ **Note:** When used on a ``res://`` path in an exported project, only the files actually included in the PCK at the given folder level are returned. In practice, this means that since imported resources are stored in a top-level ``.godot/`` folder, only paths to ``*.gd`` and ``*.import`` files are returned (plus a few files such as ``project.godot`` or ``project.binary[code] and the project icon). In an exported project, the list of returned files will also vary depending on whether [member ProjectSettings.editor/export/convert_text_resources_to_binary] is [code]true``.
.. rst-class:: classref-item-separator
----

View File

@@ -62,6 +62,8 @@ Methods
+----------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Rect2i<class_Rect2i>` | :ref:`get_display_safe_area<class_DisplayServer_method_get_display_safe_area>` **(** **)** |const| |
+----------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_keyboard_focus_screen<class_DisplayServer_method_get_keyboard_focus_screen>` **(** **)** |const| |
+----------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_name<class_DisplayServer_method_get_name>` **(** **)** |const| |
+----------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_primary_screen<class_DisplayServer_method_get_primary_screen>` **(** **)** |const| |
@@ -204,6 +206,8 @@ Methods
+----------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`ScreenOrientation<enum_DisplayServer_ScreenOrientation>` | :ref:`screen_get_orientation<class_DisplayServer_method_screen_get_orientation>` **(** :ref:`int<class_int>` screen=-1 **)** |const| |
+----------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Color<class_Color>` | :ref:`screen_get_pixel<class_DisplayServer_method_screen_get_pixel>` **(** :ref:`Vector2i<class_Vector2i>` position **)** |const| |
+----------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Vector2i<class_Vector2i>` | :ref:`screen_get_position<class_DisplayServer_method_screen_get_position>` **(** :ref:`int<class_int>` screen=-1 **)** |const| |
+----------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`screen_get_refresh_rate<class_DisplayServer_method_screen_get_refresh_rate>` **(** :ref:`int<class_int>` screen=-1 **)** |const| |
@@ -518,6 +522,14 @@ Display server supports text-to-speech. See ``tts_*`` methods. **Windows, macOS,
Display server supports expanding window content to the title. See :ref:`WINDOW_FLAG_EXTEND_TO_TITLE<class_DisplayServer_constant_WINDOW_FLAG_EXTEND_TO_TITLE>`. **macOS**
.. _class_DisplayServer_constant_FEATURE_SCREEN_CAPTURE:
.. rst-class:: classref-enumeration-constant
:ref:`Feature<enum_DisplayServer_Feature>` **FEATURE_SCREEN_CAPTURE** = ``21``
Display server supports reading screen pixels. See :ref:`screen_get_pixel<class_DisplayServer_method_screen_get_pixel>`.
.. rst-class:: classref-item-separator
----
@@ -594,7 +606,7 @@ Default landscape orientation.
:ref:`ScreenOrientation<enum_DisplayServer_ScreenOrientation>` **SCREEN_PORTRAIT** = ``1``
Default portrait orienstation.
Default portrait orientation.
.. _class_DisplayServer_constant_SCREEN_REVERSE_LANDSCAPE:
@@ -946,7 +958,7 @@ enum **WindowFlags**:
:ref:`WindowFlags<enum_DisplayServer_WindowFlags>` **WINDOW_FLAG_RESIZE_DISABLED** = ``0``
The window can't be resizing by dragging its resize grip. It's still possible to resize the window using :ref:`window_set_size<class_DisplayServer_method_window_set_size>`. This flag is ignored for full screen windows.
The window can't be resized by dragging its resize grip. It's still possible to resize the window using :ref:`window_set_size<class_DisplayServer_method_window_set_size>`. This flag is ignored for full screen windows.
.. _class_DisplayServer_constant_WINDOW_FLAG_BORDERLESS:
@@ -990,7 +1002,7 @@ The window can't be focused. No-focus window will ignore all input, except mouse
:ref:`WindowFlags<enum_DisplayServer_WindowFlags>` **WINDOW_FLAG_POPUP** = ``5``
Window is part of menu or :ref:`OptionButton<class_OptionButton>` dropdown. This flag can't be changed when the window is visible. An active popup window will exclusively receive all input, without stealing focus from its parent. Popup windows are automatically closed when uses click outside it, or when an application is switched. Popup window must have ``transient parent`` set (see :ref:`window_set_transient<class_DisplayServer_method_window_set_transient>`).
Window is part of menu or :ref:`OptionButton<class_OptionButton>` dropdown. This flag can't be changed when the window is visible. An active popup window will exclusively receive all input, without stealing focus from its parent. Popup windows are automatically closed when uses click outside it, or when an application is switched. Popup window must have transient parent set (see :ref:`window_set_transient<class_DisplayServer_method_window_set_transient>`).
.. _class_DisplayServer_constant_WINDOW_FLAG_EXTEND_TO_TITLE:
@@ -1212,7 +1224,7 @@ OpenGL context (only with the GL Compatibility renderer):
- Linux: ``GLXContext*`` for the window.
- MacOS: ``NSOpenGLContext*`` for the window.
- macOS: ``NSOpenGLContext*`` for the window.
- Android: ``EGLContext`` for the window.
@@ -1267,6 +1279,22 @@ Utterance reached a word or sentence boundary.
Constants
---------
.. _class_DisplayServer_constant_SCREEN_WITH_MOUSE_FOCUS:
.. rst-class:: classref-constant
**SCREEN_WITH_MOUSE_FOCUS** = ``-4``
Represents the screen containing the mouse pointer.
.. _class_DisplayServer_constant_SCREEN_WITH_KEYBOARD_FOCUS:
.. rst-class:: classref-constant
**SCREEN_WITH_KEYBOARD_FOCUS** = ``-3``
Represents the screen containing the window with the keyboard focus.
.. _class_DisplayServer_constant_SCREEN_PRIMARY:
.. rst-class:: classref-constant
@@ -1504,6 +1532,18 @@ Returns the unobscured area of the display where interactive controls should be
----
.. _class_DisplayServer_method_get_keyboard_focus_screen:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_keyboard_focus_screen** **(** **)** |const|
Returns the index of the screen containing the window with the keyboard focus, or the primary screen if there's no focused window.
.. rst-class:: classref-item-separator
----
.. _class_DisplayServer_method_get_name:
.. rst-class:: classref-method
@@ -1613,7 +1653,7 @@ Adds a new checkable item with text ``label`` to the global menu with ID ``menu_
Returns index of the inserted item, it's not guaranteed to be the same as ``index`` value.
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using boolean OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using bitwise OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
\ **Note:** The ``callback`` and ``key_callback`` Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to ``tag``.
@@ -1640,7 +1680,7 @@ Adds a new checkable item with text ``label`` and icon ``icon`` to the global me
Returns index of the inserted item, it's not guaranteed to be the same as ``index`` value.
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using boolean OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using bitwise OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
\ **Note:** The ``callback`` and ``key_callback`` Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to ``tag``.
@@ -1667,7 +1707,7 @@ Adds a new item with text ``label`` and icon ``icon`` to the global menu with ID
Returns index of the inserted item, it's not guaranteed to be the same as ``index`` value.
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using boolean OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using bitwise OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
\ **Note:** The ``callback`` and ``key_callback`` Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to ``tag``.
@@ -1694,7 +1734,7 @@ Adds a new radio-checkable item with text ``label`` and icon ``icon`` to the glo
Returns index of the inserted item, it's not guaranteed to be the same as ``index`` value.
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using boolean OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using bitwise OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
\ **Note:** Radio-checkable items just display a checkmark, but don't have any built-in checking behavior and must be checked/unchecked manually. See :ref:`global_menu_set_item_checked<class_DisplayServer_method_global_menu_set_item_checked>` for more info on how to control it.
@@ -1723,7 +1763,7 @@ Adds a new item with text ``label`` to the global menu with ID ``menu_root``.
Returns index of the inserted item, it's not guaranteed to be the same as ``index`` value.
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using boolean OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using bitwise OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
\ **Note:** The ``callback`` and ``key_callback`` Callables need to accept exactly one Variant parameter, the parameter passed to the Callables will be the value passed to ``tag``.
@@ -1752,7 +1792,7 @@ Contrarily to normal binary items, multistate items can have more than two state
Returns index of the inserted item, it's not guaranteed to be the same as ``index`` value.
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using boolean OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using bitwise OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
\ **Note:** By default, there's no indication of the current item state, it should be changed manually.
@@ -1781,7 +1821,7 @@ Adds a new radio-checkable item with text ``label`` to the global menu with ID `
Returns index of the inserted item, it's not guaranteed to be the same as ``index`` value.
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using boolean OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
An ``accelerator`` can optionally be defined, which is a keyboard shortcut that can be pressed to trigger the menu button even if it's not currently open. The ``accelerator`` is generally a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using bitwise OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
\ **Note:** Radio-checkable items just display a checkmark, but don't have any built-in checking behavior and must be checked/unchecked manually. See :ref:`global_menu_set_item_checked<class_DisplayServer_method_global_menu_set_item_checked>` for more info on how to control it.
@@ -1985,7 +2025,7 @@ Returns the callback of the item accelerator at index ``idx``.
:ref:`int<class_int>` **global_menu_get_item_max_states** **(** :ref:`String<class_String>` menu_root, :ref:`int<class_int>` idx **)** |const|
Returns number of states of an multistate item. See :ref:`global_menu_add_multistate_item<class_DisplayServer_method_global_menu_add_multistate_item>` for details.
Returns number of states of a multistate item. See :ref:`global_menu_add_multistate_item<class_DisplayServer_method_global_menu_add_multistate_item>` for details.
\ **Note:** This method is implemented on macOS.
@@ -1999,7 +2039,7 @@ Returns number of states of an multistate item. See :ref:`global_menu_add_multis
:ref:`int<class_int>` **global_menu_get_item_state** **(** :ref:`String<class_String>` menu_root, :ref:`int<class_int>` idx **)** |const|
Returns the state of an multistate item. See :ref:`global_menu_add_multistate_item<class_DisplayServer_method_global_menu_add_multistate_item>` for details.
Returns the state of a multistate item. See :ref:`global_menu_add_multistate_item<class_DisplayServer_method_global_menu_add_multistate_item>` for details.
\ **Note:** This method is implemented on macOS.
@@ -2055,7 +2095,7 @@ Returns the text of the item at index ``idx``.
:ref:`String<class_String>` **global_menu_get_item_tooltip** **(** :ref:`String<class_String>` menu_root, :ref:`int<class_int>` idx **)** |const|
Returns the tooltip associated with the specified index index ``idx``.
Returns the tooltip associated with the specified index ``idx``.
\ **Note:** This method is implemented on macOS.
@@ -2145,7 +2185,7 @@ Removes the item at index ``idx`` from the global menu ``menu_root``.
void **global_menu_set_item_accelerator** **(** :ref:`String<class_String>` menu_root, :ref:`int<class_int>` idx, :ref:`Key<enum_@GlobalScope_Key>` keycode **)**
Sets the accelerator of the item at index ``idx``. ``keycode`` can be a single :ref:`Key<enum_@GlobalScope_Key>`, or a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using boolean OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
Sets the accelerator of the item at index ``idx``. ``keycode`` can be a single :ref:`Key<enum_@GlobalScope_Key>`, or a combination of :ref:`KeyModifierMask<enum_@GlobalScope_KeyModifierMask>`\ s and :ref:`Key<enum_@GlobalScope_Key>`\ s using bitwise OR such as ``KEY_MASK_CTRL | KEY_A`` (:kbd:`Ctrl + A`).
\ **Note:** This method is implemented on macOS.
@@ -2161,7 +2201,7 @@ void **global_menu_set_item_callback** **(** :ref:`String<class_String>` menu_ro
Sets the callback of the item at index ``idx``. Callback is emitted when an item is pressed.
\ **Note:** The ``callback`` Callable needs to accept exactly one Variant parameter, the parameter passed to the Callable will be the value passed to the tag parameter when the menu item was created.
\ **Note:** The ``callback`` Callable needs to accept exactly one Variant parameter, the parameter passed to the Callable will be the value passed to the ``tag`` parameter when the menu item was created.
\ **Note:** This method is implemented on macOS.
@@ -2249,7 +2289,7 @@ void **global_menu_set_item_key_callback** **(** :ref:`String<class_String>` men
Sets the callback of the item at index ``idx``. Callback is emitted when its accelerator is activated.
\ **Note:** The ``key_callback`` Callable needs to accept exactly one Variant parameter, the parameter passed to the Callable will be the value passed to the tag parameter when the menu item was created.
\ **Note:** The ``key_callback`` Callable needs to accept exactly one Variant parameter, the parameter passed to the Callable will be the value passed to the ``tag`` parameter when the menu item was created.
\ **Note:** This method is implemented on macOS.
@@ -2263,7 +2303,7 @@ Sets the callback of the item at index ``idx``. Callback is emitted when its acc
void **global_menu_set_item_max_states** **(** :ref:`String<class_String>` menu_root, :ref:`int<class_int>` idx, :ref:`int<class_int>` max_states **)**
Sets number of state of an multistate item. See :ref:`global_menu_add_multistate_item<class_DisplayServer_method_global_menu_add_multistate_item>` for details.
Sets number of state of a multistate item. See :ref:`global_menu_add_multistate_item<class_DisplayServer_method_global_menu_add_multistate_item>` for details.
\ **Note:** This method is implemented on macOS.
@@ -2293,7 +2333,7 @@ Sets the type of the item at the specified index ``idx`` to radio button. If ``f
void **global_menu_set_item_state** **(** :ref:`String<class_String>` menu_root, :ref:`int<class_int>` idx, :ref:`int<class_int>` state **)**
Sets the state of an multistate item. See :ref:`global_menu_add_multistate_item<class_DisplayServer_method_global_menu_add_multistate_item>` for details.
Sets the state of a multistate item. See :ref:`global_menu_add_multistate_item<class_DisplayServer_method_global_menu_add_multistate_item>` for details.
\ **Note:** This method is implemented on macOS.
@@ -2551,7 +2591,7 @@ Returns the current mouse mode. See also :ref:`mouse_set_mode<class_DisplayServe
:ref:`Vector2i<class_Vector2i>` **mouse_get_position** **(** **)** |const|
Returns the mouse cursor's current position.
Returns the mouse cursor's current position in screen coordinates.
.. rst-class:: classref-item-separator
@@ -2638,6 +2678,22 @@ Returns the ``screen``'s current orientation. See also :ref:`screen_set_orientat
----
.. _class_DisplayServer_method_screen_get_pixel:
.. rst-class:: classref-method
:ref:`Color<class_Color>` **screen_get_pixel** **(** :ref:`Vector2i<class_Vector2i>` position **)** |const|
Returns color of the display pixel at the ``position``.
\ **Note:** This method is implemented on Linux (X11), macOS, and Windows.
\ **Note:** On macOS, this method requires "Screen Recording" permission, if permission is not granted it will return desktop wallpaper color.
.. rst-class:: classref-item-separator
----
.. _class_DisplayServer_method_screen_get_position:
.. rst-class:: classref-method
@@ -2765,7 +2821,7 @@ Sets the ``screen``'s ``orientation``. See also :ref:`screen_get_orientation<cla
void **set_icon** **(** :ref:`Image<class_Image>` image **)**
Sets the window icon (usually displayed in the top-left corner) in the operating system's *native* format. To use icons in the operating system's native format, use :ref:`set_native_icon<class_DisplayServer_method_set_native_icon>` instead.
Sets the window icon (usually displayed in the top-left corner) with an :ref:`Image<class_Image>`. To use icons in the operating system's native format, use :ref:`set_native_icon<class_DisplayServer_method_set_native_icon>` instead.
.. rst-class:: classref-item-separator
@@ -2855,7 +2911,7 @@ Each :ref:`Dictionary<class_Dictionary>` contains two :ref:`String<class_String>
- ``language`` is language code in ``lang_Variant`` format. ``lang`` part is a 2 or 3-letter code based on the ISO-639 standard, in lowercase. And ``Variant`` part is an engine dependent string describing country, region or/and dialect.
Note that Godot depends on system libraries for text-to-speech functionality. These libraries are installed by default on Windows and MacOS, but not on all Linux distributions. If they are not present, this method will return an empty list. This applies to both Godot users on Linux, as well as end-users on Linux running Godot games that use text-to-speech.
Note that Godot depends on system libraries for text-to-speech functionality. These libraries are installed by default on Windows and macOS, but not on all Linux distributions. If they are not present, this method will return an empty list. This applies to both Godot users on Linux, as well as end-users on Linux running Godot games that use text-to-speech.
\ **Note:** This method is implemented on Android, iOS, Web, Linux (X11), macOS, and Windows.
@@ -2941,9 +2997,9 @@ void **tts_set_utterance_callback** **(** :ref:`TTSUtteranceEvent<enum_DisplaySe
Adds a callback, which is called when the utterance has started, finished, canceled or reached a text boundary.
- :ref:`TTS_UTTERANCE_STARTED<class_DisplayServer_constant_TTS_UTTERANCE_STARTED>`, :ref:`TTS_UTTERANCE_ENDED<class_DisplayServer_constant_TTS_UTTERANCE_ENDED>`, and :ref:`TTS_UTTERANCE_CANCELED<class_DisplayServer_constant_TTS_UTTERANCE_CANCELED>` callable's method should take one :ref:`int<class_int>` parameter, the utterance id.
- :ref:`TTS_UTTERANCE_STARTED<class_DisplayServer_constant_TTS_UTTERANCE_STARTED>`, :ref:`TTS_UTTERANCE_ENDED<class_DisplayServer_constant_TTS_UTTERANCE_ENDED>`, and :ref:`TTS_UTTERANCE_CANCELED<class_DisplayServer_constant_TTS_UTTERANCE_CANCELED>` callable's method should take one :ref:`int<class_int>` parameter, the utterance ID.
- :ref:`TTS_UTTERANCE_BOUNDARY<class_DisplayServer_constant_TTS_UTTERANCE_BOUNDARY>` callable's method should take two :ref:`int<class_int>` parameters, the index of the character and the utterance id.
- :ref:`TTS_UTTERANCE_BOUNDARY<class_DisplayServer_constant_TTS_UTTERANCE_BOUNDARY>` callable's method should take two :ref:`int<class_int>` parameters, the index of the character and the utterance ID.
\ **Note:** The granularity of the boundary callbacks is engine dependent.

View File

@@ -43,8 +43,8 @@ Below a small example of how to use it:
func _process(delta):
while server.is_connection_available():
var peer : PacketPeerUDP = server.take_connection()
var dtls_peer : PacketPeerDTLS = dtls.take_connection(peer)
var peer: PacketPeerUDP = server.take_connection()
var dtls_peer: PacketPeerDTLS = dtls.take_connection(peer)
if dtls_peer.get_status() != PacketPeerDTLS.STATUS_HANDSHAKING:
continue # It is normal that 50% of the connections fails due to cookie exchange.
print("Peer connected!")
@@ -55,7 +55,7 @@ Below a small example of how to use it:
if p.get_status() == PacketPeerDTLS.STATUS_CONNECTED:
while p.get_available_packet_count() > 0:
print("Received message from client: %s" % p.get_packet().get_string_from_utf8())
p.put_packet("Hello DTLS client".to_utf8())
p.put_packet("Hello DTLS client".to_utf8_buffer())
.. code-tab:: csharp
@@ -98,7 +98,7 @@ Below a small example of how to use it:
while (p.GetAvailablePacketCount() > 0)
{
GD.Print($"Received Message From Client: {p.GetPacket().GetStringFromUtf8()}");
p.PutPacket("Hello DTLS Client".ToUtf8());
p.PutPacket("Hello DTLS Client".ToUtf8Buffer());
}
}
}
@@ -128,7 +128,7 @@ Below a small example of how to use it:
if dtls.get_status() == PacketPeerDTLS.STATUS_CONNECTED:
if !connected:
# Try to contact server
dtls.put_packet("The answer is... 42!".to_utf8())
dtls.put_packet("The answer is... 42!".to_utf8_buffer())
while dtls.get_available_packet_count() > 0:
print("Connected: %s" % dtls.get_packet().get_string_from_utf8())
connected = true
@@ -159,7 +159,7 @@ Below a small example of how to use it:
if (!_connected)
{
// Try to contact server
_dtls.PutPacket("The Answer Is..42!".ToUtf8());
_dtls.PutPacket("The Answer Is..42!".ToUtf8Buffer());
}
while (_dtls.GetAvailablePacketCount() > 0)
{

View File

@@ -12,6 +12,8 @@ EditorExportPlatform
**Inherits:** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
**Inherited By:** :ref:`EditorExportPlatformAndroid<class_EditorExportPlatformAndroid>`, :ref:`EditorExportPlatformIOS<class_EditorExportPlatformIOS>`, :ref:`EditorExportPlatformMacOS<class_EditorExportPlatformMacOS>`, :ref:`EditorExportPlatformPC<class_EditorExportPlatformPC>`, :ref:`EditorExportPlatformWeb<class_EditorExportPlatformWeb>`
Identifies a supported export platform, and internally provides the functionality of exporting to that platform.
.. rst-class:: classref-introduction-group

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,832 @@
: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/platform/ios/doc_classes/EditorExportPlatformIOS.xml.
.. _class_EditorExportPlatformIOS:
EditorExportPlatformIOS
=======================
**Inherits:** :ref:`EditorExportPlatform<class_EditorExportPlatform>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Exporter for iOS.
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`Exporting for iOS <../tutorials/export/exporting_for_ios>`
.. rst-class:: classref-reftable-group
Properties
----------
.. table::
:widths: auto
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/app_store_team_id<class_EditorExportPlatformIOS_property_application/app_store_team_id>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/bundle_identifier<class_EditorExportPlatformIOS_property_application/bundle_identifier>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/code_sign_identity_debug<class_EditorExportPlatformIOS_property_application/code_sign_identity_debug>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/code_sign_identity_release<class_EditorExportPlatformIOS_property_application/code_sign_identity_release>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`application/export_method_debug<class_EditorExportPlatformIOS_property_application/export_method_debug>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`application/export_method_release<class_EditorExportPlatformIOS_property_application/export_method_release>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`application/icon_interpolation<class_EditorExportPlatformIOS_property_application/icon_interpolation>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`application/launch_screens_interpolation<class_EditorExportPlatformIOS_property_application/launch_screens_interpolation>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/provisioning_profile_uuid_debug<class_EditorExportPlatformIOS_property_application/provisioning_profile_uuid_debug>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/provisioning_profile_uuid_release<class_EditorExportPlatformIOS_property_application/provisioning_profile_uuid_release>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/short_version<class_EditorExportPlatformIOS_property_application/short_version>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/signature<class_EditorExportPlatformIOS_property_application/signature>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`application/targeted_device_family<class_EditorExportPlatformIOS_property_application/targeted_device_family>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/version<class_EditorExportPlatformIOS_property_application/version>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`architectures/arm64<class_EditorExportPlatformIOS_property_architectures/arm64>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`capabilities/access_wifi<class_EditorExportPlatformIOS_property_capabilities/access_wifi>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`capabilities/push_notifications<class_EditorExportPlatformIOS_property_capabilities/push_notifications>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`custom_template/debug<class_EditorExportPlatformIOS_property_custom_template/debug>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`custom_template/release<class_EditorExportPlatformIOS_property_custom_template/release>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/app_store_1024x1024<class_EditorExportPlatformIOS_property_icons/app_store_1024x1024>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/ipad_76x76<class_EditorExportPlatformIOS_property_icons/ipad_76x76>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/ipad_152x152<class_EditorExportPlatformIOS_property_icons/ipad_152x152>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/ipad_167x167<class_EditorExportPlatformIOS_property_icons/ipad_167x167>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/iphone_120x120<class_EditorExportPlatformIOS_property_icons/iphone_120x120>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/iphone_180x180<class_EditorExportPlatformIOS_property_icons/iphone_180x180>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/notification_40x40<class_EditorExportPlatformIOS_property_icons/notification_40x40>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/notification_60x60<class_EditorExportPlatformIOS_property_icons/notification_60x60>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/settings_58x58<class_EditorExportPlatformIOS_property_icons/settings_58x58>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/settings_87x87<class_EditorExportPlatformIOS_property_icons/settings_87x87>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/spotlight_40x40<class_EditorExportPlatformIOS_property_icons/spotlight_40x40>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`icons/spotlight_80x80<class_EditorExportPlatformIOS_property_icons/spotlight_80x80>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`landscape_launch_screens/ipad_1024x768<class_EditorExportPlatformIOS_property_landscape_launch_screens/ipad_1024x768>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`landscape_launch_screens/ipad_2048x1536<class_EditorExportPlatformIOS_property_landscape_launch_screens/ipad_2048x1536>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`landscape_launch_screens/iphone_2208x1242<class_EditorExportPlatformIOS_property_landscape_launch_screens/iphone_2208x1242>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`landscape_launch_screens/iphone_2436x1125<class_EditorExportPlatformIOS_property_landscape_launch_screens/iphone_2436x1125>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`portrait_launch_screens/ipad_768x1024<class_EditorExportPlatformIOS_property_portrait_launch_screens/ipad_768x1024>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`portrait_launch_screens/ipad_1536x2048<class_EditorExportPlatformIOS_property_portrait_launch_screens/ipad_1536x2048>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`portrait_launch_screens/iphone_640x960<class_EditorExportPlatformIOS_property_portrait_launch_screens/iphone_640x960>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`portrait_launch_screens/iphone_640x1136<class_EditorExportPlatformIOS_property_portrait_launch_screens/iphone_640x1136>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`portrait_launch_screens/iphone_750x1334<class_EditorExportPlatformIOS_property_portrait_launch_screens/iphone_750x1334>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`portrait_launch_screens/iphone_1125x2436<class_EditorExportPlatformIOS_property_portrait_launch_screens/iphone_1125x2436>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`portrait_launch_screens/iphone_1242x2208<class_EditorExportPlatformIOS_property_portrait_launch_screens/iphone_1242x2208>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`privacy/camera_usage_description<class_EditorExportPlatformIOS_property_privacy/camera_usage_description>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Dictionary<class_Dictionary>` | :ref:`privacy/camera_usage_description_localized<class_EditorExportPlatformIOS_property_privacy/camera_usage_description_localized>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`privacy/microphone_usage_description<class_EditorExportPlatformIOS_property_privacy/microphone_usage_description>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Dictionary<class_Dictionary>` | :ref:`privacy/microphone_usage_description_localized<class_EditorExportPlatformIOS_property_privacy/microphone_usage_description_localized>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`privacy/photolibrary_usage_description<class_EditorExportPlatformIOS_property_privacy/photolibrary_usage_description>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Dictionary<class_Dictionary>` | :ref:`privacy/photolibrary_usage_description_localized<class_EditorExportPlatformIOS_property_privacy/photolibrary_usage_description_localized>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Color<class_Color>` | :ref:`storyboard/custom_bg_color<class_EditorExportPlatformIOS_property_storyboard/custom_bg_color>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`storyboard/custom_image@2x<class_EditorExportPlatformIOS_property_storyboard/custom_image@2x>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`storyboard/custom_image@3x<class_EditorExportPlatformIOS_property_storyboard/custom_image@3x>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`storyboard/image_scale_mode<class_EditorExportPlatformIOS_property_storyboard/image_scale_mode>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`storyboard/use_custom_bg_color<class_EditorExportPlatformIOS_property_storyboard/use_custom_bg_color>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`storyboard/use_launch_screen_storyboard<class_EditorExportPlatformIOS_property_storyboard/use_launch_screen_storyboard>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`user_data/accessible_from_files_app<class_EditorExportPlatformIOS_property_user_data/accessible_from_files_app>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`user_data/accessible_from_itunes_sharing<class_EditorExportPlatformIOS_property_user_data/accessible_from_itunes_sharing>` |
+-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Property Descriptions
---------------------
.. _class_EditorExportPlatformIOS_property_application/app_store_team_id:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/app_store_team_id**
Apple Team ID, unique 10-character string. To locate your Team ID check "Membership details" section in your Apple developer account dashboard, or "Organizational Unit" of your code signing certificate. See `Locate your Team ID <https://developer.apple.com/help/account/manage-your-team/locate-your-team-id>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/bundle_identifier:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/bundle_identifier**
Unique application identifier in a reverse-DNS format, can only contain alphanumeric characters (``A-Z``, ``a-z``, and ``0-9``), hyphens (``-``), and periods (``.``).
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/code_sign_identity_debug:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/code_sign_identity_debug**
The "Full Name", "Common Name" or SHA-1 hash of the signing identity used for debug export.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/code_sign_identity_release:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/code_sign_identity_release**
The "Full Name", "Common Name" or SHA-1 hash of the signing identity used for release export.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/export_method_debug:
.. rst-class:: classref-property
:ref:`int<class_int>` **application/export_method_debug**
Application distribution target (debug export).
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/export_method_release:
.. rst-class:: classref-property
:ref:`int<class_int>` **application/export_method_release**
Application distribution target (release export).
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/icon_interpolation:
.. rst-class:: classref-property
:ref:`int<class_int>` **application/icon_interpolation**
Interpolation method used to resize application icon.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/launch_screens_interpolation:
.. rst-class:: classref-property
:ref:`int<class_int>` **application/launch_screens_interpolation**
Interpolation method used to resize launch screen images.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/provisioning_profile_uuid_debug:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/provisioning_profile_uuid_debug**
UUID of the provisioning profile. If left empty, Xcode will download or create a provisioning profile automatically. See `Edit, download, or delete provisioning profiles <https://developer.apple.com/help/account/manage-profiles/edit-download-or-delete-profiles>`__.
Can be overridden with the environment variable ``GODOT_IOS_PROVISIONING_PROFILE_UUID_DEBUG``.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/provisioning_profile_uuid_release:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/provisioning_profile_uuid_release**
UUID of the provisioning profile. If left empty, Xcode will download or create a provisioning profile automatically. See `Edit, download, or delete provisioning profiles <https://developer.apple.com/help/account/manage-profiles/edit-download-or-delete-profiles>`__.
Can be overridden with the environment variable ``GODOT_IOS_PROVISIONING_PROFILE_UUID_RELEASE``.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/short_version:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/short_version**
Application version visible to the user, can only contain numeric characters (``0-9``) and periods (``.``).
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/signature:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/signature**
A four-character creator code that is specific to the bundle. Optional.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/targeted_device_family:
.. rst-class:: classref-property
:ref:`int<class_int>` **application/targeted_device_family**
Supported device family.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_application/version:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/version**
Machine-readable application version, in the ``major.minor.patch`` format, can only contain numeric characters (``0-9``) and periods (``.``).
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_architectures/arm64:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **architectures/arm64**
If ``true``, ``arm64`` binaries are included into exported project.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_capabilities/access_wifi:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **capabilities/access_wifi**
If ``true``, networking features related to Wi-Fi access are enabled. See `Required Device Capabilities <https://developer.apple.com/support/required-device-capabilities/>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_capabilities/push_notifications:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **capabilities/push_notifications**
If ``true``, push notifications are enabled. See `Required Device Capabilities <https://developer.apple.com/support/required-device-capabilities/>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_custom_template/debug:
.. rst-class:: classref-property
:ref:`String<class_String>` **custom_template/debug**
Path to the custom export template. If left empty, default template is used.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_custom_template/release:
.. rst-class:: classref-property
:ref:`String<class_String>` **custom_template/release**
Path to the custom export template. If left empty, default template is used.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/app_store_1024x1024:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/app_store_1024x1024**
App Store application icon file. If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/ipad_76x76:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/ipad_76x76**
Home screen application icon file on iPad (1x DPI). If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/ipad_152x152:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/ipad_152x152**
Home screen application icon file on iPad (2x DPI). If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/ipad_167x167:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/ipad_167x167**
Home screen application icon file on iPad (3x DPI). If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/iphone_120x120:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/iphone_120x120**
Home screen application icon file on iPhone (2x DPI). If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/iphone_180x180:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/iphone_180x180**
Home screen application icon file on iPhone (3x DPI). If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/notification_40x40:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/notification_40x40**
Notification icon file on iPad and iPhone (2x DPI). If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/notification_60x60:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/notification_60x60**
Notification icon file on iPhone (3x DPI). If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/settings_58x58:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/settings_58x58**
Application settings icon file on iPad and iPhone (2x DPI). If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/settings_87x87:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/settings_87x87**
Application settings icon file on iPhone (3x DPI). If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/spotlight_40x40:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/spotlight_40x40**
Spotlight icon file on iPad (1x DPI). If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_icons/spotlight_80x80:
.. rst-class:: classref-property
:ref:`String<class_String>` **icons/spotlight_80x80**
Spotlight icon file on iPad and iPhone (2x DPI). If left empty, project icon is used instead. See `App icons <https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_landscape_launch_screens/ipad_1024x768:
.. rst-class:: classref-property
:ref:`String<class_String>` **landscape_launch_screens/ipad_1024x768**
Application launch screen image file, if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_landscape_launch_screens/ipad_2048x1536:
.. rst-class:: classref-property
:ref:`String<class_String>` **landscape_launch_screens/ipad_2048x1536**
Application launch screen image file, if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_landscape_launch_screens/iphone_2208x1242:
.. rst-class:: classref-property
:ref:`String<class_String>` **landscape_launch_screens/iphone_2208x1242**
Application launch screen image file, if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_landscape_launch_screens/iphone_2436x1125:
.. rst-class:: classref-property
:ref:`String<class_String>` **landscape_launch_screens/iphone_2436x1125**
Application launch screen image file, if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_portrait_launch_screens/ipad_768x1024:
.. rst-class:: classref-property
:ref:`String<class_String>` **portrait_launch_screens/ipad_768x1024**
Application launch screen image file, if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_portrait_launch_screens/ipad_1536x2048:
.. rst-class:: classref-property
:ref:`String<class_String>` **portrait_launch_screens/ipad_1536x2048**
Application launch screen image file, if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_portrait_launch_screens/iphone_640x960:
.. rst-class:: classref-property
:ref:`String<class_String>` **portrait_launch_screens/iphone_640x960**
Application launch screen image file, if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_portrait_launch_screens/iphone_640x1136:
.. rst-class:: classref-property
:ref:`String<class_String>` **portrait_launch_screens/iphone_640x1136**
Application launch screen image file, if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_portrait_launch_screens/iphone_750x1334:
.. rst-class:: classref-property
:ref:`String<class_String>` **portrait_launch_screens/iphone_750x1334**
Application launch screen image file, if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_portrait_launch_screens/iphone_1125x2436:
.. rst-class:: classref-property
:ref:`String<class_String>` **portrait_launch_screens/iphone_1125x2436**
Application launch screen image file, if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_portrait_launch_screens/iphone_1242x2208:
.. rst-class:: classref-property
:ref:`String<class_String>` **portrait_launch_screens/iphone_1242x2208**
Application launch screen image file, if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_privacy/camera_usage_description:
.. rst-class:: classref-property
:ref:`String<class_String>` **privacy/camera_usage_description**
A message displayed when requesting access to the device's camera (in English).
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_privacy/camera_usage_description_localized:
.. rst-class:: classref-property
:ref:`Dictionary<class_Dictionary>` **privacy/camera_usage_description_localized**
A message displayed when requesting access to the device's camera (localized).
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_privacy/microphone_usage_description:
.. rst-class:: classref-property
:ref:`String<class_String>` **privacy/microphone_usage_description**
A message displayed when requesting access to the device's microphone (in English).
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_privacy/microphone_usage_description_localized:
.. rst-class:: classref-property
:ref:`Dictionary<class_Dictionary>` **privacy/microphone_usage_description_localized**
A message displayed when requesting access to the device's microphone (localized).
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_privacy/photolibrary_usage_description:
.. rst-class:: classref-property
:ref:`String<class_String>` **privacy/photolibrary_usage_description**
A message displayed when requesting access to the user's photo library (in English).
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_privacy/photolibrary_usage_description_localized:
.. rst-class:: classref-property
:ref:`Dictionary<class_Dictionary>` **privacy/photolibrary_usage_description_localized**
A message displayed when requesting access to the user's photo library (localized).
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_storyboard/custom_bg_color:
.. rst-class:: classref-property
:ref:`Color<class_Color>` **storyboard/custom_bg_color**
A custom background color of the storyboard launch screen.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_storyboard/custom_image@2x:
.. rst-class:: classref-property
:ref:`String<class_String>` **storyboard/custom_image@2x**
Application launch screen image file (2x DPI), if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_storyboard/custom_image@3x:
.. rst-class:: classref-property
:ref:`String<class_String>` **storyboard/custom_image@3x**
Application launch screen image file (3x DPI), if left empty project splash screen is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_storyboard/image_scale_mode:
.. rst-class:: classref-property
:ref:`int<class_int>` **storyboard/image_scale_mode**
Launch screen image scaling mode.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_storyboard/use_custom_bg_color:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **storyboard/use_custom_bg_color**
If ``true``, :ref:`storyboard/custom_bg_color<class_EditorExportPlatformIOS_property_storyboard/custom_bg_color>` is used as a launch screen background color, otherwise ``application/boot_splash/bg_color`` project setting is used.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_storyboard/use_launch_screen_storyboard:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **storyboard/use_launch_screen_storyboard**
If ``true``, storyboard launch screen is used instead of launch screen images.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_user_data/accessible_from_files_app:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **user_data/accessible_from_files_app**
If ``true``, the app "Documents" folder can be accessed via "Files" app. See `LSSupportsOpeningDocumentsInPlace <https://developer.apple.com/documentation/bundleresources/information_property_list/lssupportsopeningdocumentsinplace>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformIOS_property_user_data/accessible_from_itunes_sharing:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **user_data/accessible_from_itunes_sharing**
If ``true``, the app "Documents" folder can be accessed via iTunes file sharing. See `UIFileSharingEnabled <https://developer.apple.com/documentation/bundleresources/information_property_list/uifilesharingenabled>`__.
.. |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.)`

View File

@@ -0,0 +1,292 @@
: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/platform/linuxbsd/doc_classes/EditorExportPlatformLinuxBSD.xml.
.. _class_EditorExportPlatformLinuxBSD:
EditorExportPlatformLinuxBSD
============================
**Inherits:** :ref:`EditorExportPlatformPC<class_EditorExportPlatformPC>` **<** :ref:`EditorExportPlatform<class_EditorExportPlatform>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Exporter for Linux/BSD.
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`Exporting for Linux <../tutorials/export/exporting_for_linux>`
.. rst-class:: classref-reftable-group
Properties
----------
.. table::
:widths: auto
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`binary_format/architecture<class_EditorExportPlatformLinuxBSD_property_binary_format/architecture>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`binary_format/embed_pck<class_EditorExportPlatformLinuxBSD_property_binary_format/embed_pck>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`custom_template/debug<class_EditorExportPlatformLinuxBSD_property_custom_template/debug>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`custom_template/release<class_EditorExportPlatformLinuxBSD_property_custom_template/release>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`debug/export_console_script<class_EditorExportPlatformLinuxBSD_property_debug/export_console_script>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/cleanup_script<class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/cleanup_script>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`ssh_remote_deploy/enabled<class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/enabled>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/extra_args_scp<class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/extra_args_scp>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/extra_args_ssh<class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/extra_args_ssh>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/host<class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/host>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/port<class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/port>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/run_script<class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/run_script>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`texture_format/bptc<class_EditorExportPlatformLinuxBSD_property_texture_format/bptc>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`texture_format/etc<class_EditorExportPlatformLinuxBSD_property_texture_format/etc>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`texture_format/etc2<class_EditorExportPlatformLinuxBSD_property_texture_format/etc2>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`texture_format/s3tc<class_EditorExportPlatformLinuxBSD_property_texture_format/s3tc>` |
+-----------------------------+-----------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Property Descriptions
---------------------
.. _class_EditorExportPlatformLinuxBSD_property_binary_format/architecture:
.. rst-class:: classref-property
:ref:`String<class_String>` **binary_format/architecture**
Application executable architecture.
Supported architectures: ``x86_32``, ``x86_64``, ``arm64``, ``arm32``, ``rv64``, ``ppc64``, and ``ppc32``.
Official export templates include ``x86_32`` and ``x86_64`` binaries only.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_binary_format/embed_pck:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **binary_format/embed_pck**
If ``true``, project resources are embedded into the executable.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_custom_template/debug:
.. rst-class:: classref-property
:ref:`String<class_String>` **custom_template/debug**
Path to the custom export template. If left empty, default template is used.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_custom_template/release:
.. rst-class:: classref-property
:ref:`String<class_String>` **custom_template/release**
Path to the custom export template. If left empty, default template is used.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_debug/export_console_script:
.. rst-class:: classref-property
:ref:`int<class_int>` **debug/export_console_script**
If ``true``, a console wrapper script is exported alongside the main executable, which allows running the project with enabled console output.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/cleanup_script:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/cleanup_script**
Script code to execute on the remote host when app is finished.
The following variables can be used in the script:
- ``{temp_dir}`` - Path of temporary folder on the remote, used to upload app and scripts to.
- ``{archive_name}`` - Name of the ZIP containing uploaded application.
- ``{exe_name}`` - Name of application executable.
- ``{cmd_args}`` - Array of the command line argument for the application.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/enabled:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **ssh_remote_deploy/enabled**
Enables remote deploy using SSH/SCP.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/extra_args_scp:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/extra_args_scp**
Array of the additional command line arguments passed to the SCP.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/extra_args_ssh:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/extra_args_ssh**
Array of the additional command line arguments passed to the SSH.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/host:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/host**
Remote host SSH user name and address, in ``user@address`` format.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/port:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/port**
Remote host SSH port number.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_ssh_remote_deploy/run_script:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/run_script**
Script code to execute on the remote host when running the app.
The following variables can be used in the script:
- ``{temp_dir}`` - Path of temporary folder on the remote, used to upload app and scripts to.
- ``{archive_name}`` - Name of the ZIP containing uploaded application.
- ``{exe_name}`` - Name of application executable.
- ``{cmd_args}`` - Array of the command line argument for the application.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_texture_format/bptc:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **texture_format/bptc**
If ``true``, project textures are exported in the BPTC format.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_texture_format/etc:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **texture_format/etc**
If ``true``, project textures are exported in the ETC format.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_texture_format/etc2:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **texture_format/etc2**
If ``true``, project textures are exported in the ETC2 format.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformLinuxBSD_property_texture_format/s3tc:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **texture_format/s3tc**
If ``true``, project textures are exported in the S3TC format.
.. |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.)`

File diff suppressed because it is too large Load Diff

View File

@@ -3,18 +3,18 @@
.. 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/AnimationTrackEditPlugin.xml.
.. XML source: https://github.com/godotengine/godot/tree/master/doc/classes/EditorExportPlatformPC.xml.
.. _class_AnimationTrackEditPlugin:
.. _class_EditorExportPlatformPC:
AnimationTrackEditPlugin
========================
EditorExportPlatformPC
======================
**Inherits:** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
**Inherits:** :ref:`EditorExportPlatform<class_EditorExportPlatform>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
.. container:: contribute
**Inherited By:** :ref:`EditorExportPlatformLinuxBSD<class_EditorExportPlatformLinuxBSD>`, :ref:`EditorExportPlatformWindows<class_EditorExportPlatformWindows>`
There is currently no description for this class. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
Base class for the desktop platform exporter (Windows and Linux/BSD).
.. |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.)`

View File

@@ -0,0 +1,342 @@
: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/platform/web/doc_classes/EditorExportPlatformWeb.xml.
.. _class_EditorExportPlatformWeb:
EditorExportPlatformWeb
=======================
**Inherits:** :ref:`EditorExportPlatform<class_EditorExportPlatform>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Exporter for the Web.
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`Exporting for the Web <../tutorials/export/exporting_for_web>`
.. rst-class:: classref-reftable-group
Properties
----------
.. table::
:widths: auto
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`custom_template/debug<class_EditorExportPlatformWeb_property_custom_template/debug>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`custom_template/release<class_EditorExportPlatformWeb_property_custom_template/release>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`html/canvas_resize_policy<class_EditorExportPlatformWeb_property_html/canvas_resize_policy>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`html/custom_html_shell<class_EditorExportPlatformWeb_property_html/custom_html_shell>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`html/experimental_virtual_keyboard<class_EditorExportPlatformWeb_property_html/experimental_virtual_keyboard>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`html/export_icon<class_EditorExportPlatformWeb_property_html/export_icon>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`html/focus_canvas_on_start<class_EditorExportPlatformWeb_property_html/focus_canvas_on_start>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`html/head_include<class_EditorExportPlatformWeb_property_html/head_include>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`Color<class_Color>` | :ref:`progressive_web_app/background_color<class_EditorExportPlatformWeb_property_progressive_web_app/background_color>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`progressive_web_app/display<class_EditorExportPlatformWeb_property_progressive_web_app/display>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`progressive_web_app/enabled<class_EditorExportPlatformWeb_property_progressive_web_app/enabled>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`progressive_web_app/icon_144x144<class_EditorExportPlatformWeb_property_progressive_web_app/icon_144x144>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`progressive_web_app/icon_180x180<class_EditorExportPlatformWeb_property_progressive_web_app/icon_180x180>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`progressive_web_app/icon_512x512<class_EditorExportPlatformWeb_property_progressive_web_app/icon_512x512>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`progressive_web_app/offline_page<class_EditorExportPlatformWeb_property_progressive_web_app/offline_page>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`progressive_web_app/orientation<class_EditorExportPlatformWeb_property_progressive_web_app/orientation>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`variant/extensions_support<class_EditorExportPlatformWeb_property_variant/extensions_support>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`vram_texture_compression/for_desktop<class_EditorExportPlatformWeb_property_vram_texture_compression/for_desktop>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`vram_texture_compression/for_mobile<class_EditorExportPlatformWeb_property_vram_texture_compression/for_mobile>` |
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Property Descriptions
---------------------
.. _class_EditorExportPlatformWeb_property_custom_template/debug:
.. rst-class:: classref-property
:ref:`String<class_String>` **custom_template/debug**
Path to the custom export template. If left empty, default template is used.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_custom_template/release:
.. rst-class:: classref-property
:ref:`String<class_String>` **custom_template/release**
Path to the custom export template. If left empty, default template is used.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_html/canvas_resize_policy:
.. rst-class:: classref-property
:ref:`int<class_int>` **html/canvas_resize_policy**
The canvas resize policy determines how the canvas should be resized by Godot.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_html/custom_html_shell:
.. rst-class:: classref-property
:ref:`String<class_String>` **html/custom_html_shell**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_html/experimental_virtual_keyboard:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **html/experimental_virtual_keyboard**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_html/export_icon:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **html/export_icon**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_html/focus_canvas_on_start:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **html/focus_canvas_on_start**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_html/head_include:
.. rst-class:: classref-property
:ref:`String<class_String>` **html/head_include**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_progressive_web_app/background_color:
.. rst-class:: classref-property
:ref:`Color<class_Color>` **progressive_web_app/background_color**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_progressive_web_app/display:
.. rst-class:: classref-property
:ref:`int<class_int>` **progressive_web_app/display**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_progressive_web_app/enabled:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **progressive_web_app/enabled**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_progressive_web_app/icon_144x144:
.. rst-class:: classref-property
:ref:`String<class_String>` **progressive_web_app/icon_144x144**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_progressive_web_app/icon_180x180:
.. rst-class:: classref-property
:ref:`String<class_String>` **progressive_web_app/icon_180x180**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_progressive_web_app/icon_512x512:
.. rst-class:: classref-property
:ref:`String<class_String>` **progressive_web_app/icon_512x512**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_progressive_web_app/offline_page:
.. rst-class:: classref-property
:ref:`String<class_String>` **progressive_web_app/offline_page**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_progressive_web_app/orientation:
.. rst-class:: classref-property
:ref:`int<class_int>` **progressive_web_app/orientation**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_variant/extensions_support:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **variant/extensions_support**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_vram_texture_compression/for_desktop:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **vram_texture_compression/for_desktop**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWeb_property_vram_texture_compression/for_mobile:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **vram_texture_compression/for_mobile**
.. container:: contribute
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. |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.)`

View File

@@ -0,0 +1,578 @@
: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/platform/windows/doc_classes/EditorExportPlatformWindows.xml.
.. _class_EditorExportPlatformWindows:
EditorExportPlatformWindows
===========================
**Inherits:** :ref:`EditorExportPlatformPC<class_EditorExportPlatformPC>` **<** :ref:`EditorExportPlatform<class_EditorExportPlatform>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Exporter for Windows.
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`Exporting for Windows <../tutorials/export/exporting_for_windows>`
.. rst-class:: classref-reftable-group
Properties
----------
.. table::
:widths: auto
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/company_name<class_EditorExportPlatformWindows_property_application/company_name>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/console_wrapper_icon<class_EditorExportPlatformWindows_property_application/console_wrapper_icon>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/copyright<class_EditorExportPlatformWindows_property_application/copyright>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/file_description<class_EditorExportPlatformWindows_property_application/file_description>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/file_version<class_EditorExportPlatformWindows_property_application/file_version>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/icon<class_EditorExportPlatformWindows_property_application/icon>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`application/icon_interpolation<class_EditorExportPlatformWindows_property_application/icon_interpolation>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`application/modify_resources<class_EditorExportPlatformWindows_property_application/modify_resources>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/product_name<class_EditorExportPlatformWindows_property_application/product_name>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/product_version<class_EditorExportPlatformWindows_property_application/product_version>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`application/trademarks<class_EditorExportPlatformWindows_property_application/trademarks>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`binary_format/architecture<class_EditorExportPlatformWindows_property_binary_format/architecture>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`binary_format/embed_pck<class_EditorExportPlatformWindows_property_binary_format/embed_pck>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`PackedStringArray<class_PackedStringArray>` | :ref:`codesign/custom_options<class_EditorExportPlatformWindows_property_codesign/custom_options>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`codesign/description<class_EditorExportPlatformWindows_property_codesign/description>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`codesign/digest_algorithm<class_EditorExportPlatformWindows_property_codesign/digest_algorithm>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`codesign/enable<class_EditorExportPlatformWindows_property_codesign/enable>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`codesign/identity<class_EditorExportPlatformWindows_property_codesign/identity>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`codesign/identity_type<class_EditorExportPlatformWindows_property_codesign/identity_type>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`codesign/password<class_EditorExportPlatformWindows_property_codesign/password>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`codesign/timestamp<class_EditorExportPlatformWindows_property_codesign/timestamp>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`codesign/timestamp_server_url<class_EditorExportPlatformWindows_property_codesign/timestamp_server_url>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`custom_template/debug<class_EditorExportPlatformWindows_property_custom_template/debug>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`custom_template/release<class_EditorExportPlatformWindows_property_custom_template/release>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`debug/export_console_script<class_EditorExportPlatformWindows_property_debug/export_console_script>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/cleanup_script<class_EditorExportPlatformWindows_property_ssh_remote_deploy/cleanup_script>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`ssh_remote_deploy/enabled<class_EditorExportPlatformWindows_property_ssh_remote_deploy/enabled>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/extra_args_scp<class_EditorExportPlatformWindows_property_ssh_remote_deploy/extra_args_scp>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/extra_args_ssh<class_EditorExportPlatformWindows_property_ssh_remote_deploy/extra_args_ssh>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/host<class_EditorExportPlatformWindows_property_ssh_remote_deploy/host>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/port<class_EditorExportPlatformWindows_property_ssh_remote_deploy/port>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`ssh_remote_deploy/run_script<class_EditorExportPlatformWindows_property_ssh_remote_deploy/run_script>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`texture_format/bptc<class_EditorExportPlatformWindows_property_texture_format/bptc>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`texture_format/etc<class_EditorExportPlatformWindows_property_texture_format/etc>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`texture_format/etc2<class_EditorExportPlatformWindows_property_texture_format/etc2>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`texture_format/s3tc<class_EditorExportPlatformWindows_property_texture_format/s3tc>` |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Property Descriptions
---------------------
.. _class_EditorExportPlatformWindows_property_application/company_name:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/company_name**
Company that produced the application. Required. See `StringFileInfo <https://learn.microsoft.com/en-us/windows/win32/menurc/stringfileinfo-block>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_application/console_wrapper_icon:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/console_wrapper_icon**
Console wrapper icon file. If left empty, application icon is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_application/copyright:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/copyright**
Copyright notice for the bundle visible to the user. Optional. See `StringFileInfo <https://learn.microsoft.com/en-us/windows/win32/menurc/stringfileinfo-block>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_application/file_description:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/file_description**
File description to be presented to users. Required. See `StringFileInfo <https://learn.microsoft.com/en-us/windows/win32/menurc/stringfileinfo-block>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_application/file_version:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/file_version**
Version number of the file. Required. See `StringFileInfo <https://learn.microsoft.com/en-us/windows/win32/menurc/stringfileinfo-block>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_application/icon:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/icon**
Application icon file. If left empty, project icon is used instead.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_application/icon_interpolation:
.. rst-class:: classref-property
:ref:`int<class_int>` **application/icon_interpolation**
Interpolation method used to resize application icon.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_application/modify_resources:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **application/modify_resources**
If enabled, icon and metadata of the exported executable is set according to the other ``application/*`` values.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_application/product_name:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/product_name**
Name of the application. Required. See `StringFileInfo <https://learn.microsoft.com/en-us/windows/win32/menurc/stringfileinfo-block>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_application/product_version:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/product_version**
Application version visible to the user. Required. See `StringFileInfo <https://learn.microsoft.com/en-us/windows/win32/menurc/stringfileinfo-block>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_application/trademarks:
.. rst-class:: classref-property
:ref:`String<class_String>` **application/trademarks**
Trademarks and registered trademarks that apply to the file. Optional. See `StringFileInfo <https://learn.microsoft.com/en-us/windows/win32/menurc/stringfileinfo-block>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_binary_format/architecture:
.. rst-class:: classref-property
:ref:`String<class_String>` **binary_format/architecture**
Application executable architecture.
Supported architectures: ``x86_32``, ``x86_64``, and ``arm64``.
Official export templates include ``x86_32`` and ``x86_64`` binaries only.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_binary_format/embed_pck:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **binary_format/embed_pck**
If ``true``, project resources are embedded into the executable.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_codesign/custom_options:
.. rst-class:: classref-property
:ref:`PackedStringArray<class_PackedStringArray>` **codesign/custom_options**
Array of the additional command line arguments passed to the code signing tool. See `Sign Tool <https://learn.microsoft.com/en-us/dotnet/framework/tools/signtool-exe>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_codesign/description:
.. rst-class:: classref-property
:ref:`String<class_String>` **codesign/description**
Description of the signed content. See `Sign Tool <https://learn.microsoft.com/en-us/dotnet/framework/tools/signtool-exe>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_codesign/digest_algorithm:
.. rst-class:: classref-property
:ref:`int<class_int>` **codesign/digest_algorithm**
Digest algorithm to use for creating signature. See `Sign Tool <https://learn.microsoft.com/en-us/dotnet/framework/tools/signtool-exe>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_codesign/enable:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **codesign/enable**
If ``true``, executable signing is enabled.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_codesign/identity:
.. rst-class:: classref-property
:ref:`String<class_String>` **codesign/identity**
PKCS #12 certificate file used to sign executable or certificate SHA-1 hash (if :ref:`codesign/identity_type<class_EditorExportPlatformWindows_property_codesign/identity_type>` is set to "Use certificate store"). See `Sign Tool <https://learn.microsoft.com/en-us/dotnet/framework/tools/signtool-exe>`__.
Can be overridden with the environment variable ``GODOT_WINDOWS_CODESIGN_IDENTITY``.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_codesign/identity_type:
.. rst-class:: classref-property
:ref:`int<class_int>` **codesign/identity_type**
Type of identity to use. See `Sign Tool <https://learn.microsoft.com/en-us/dotnet/framework/tools/signtool-exe>`__.
Can be overridden with the environment variable ``GODOT_WINDOWS_CODESIGN_IDENTITY_TYPE``.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_codesign/password:
.. rst-class:: classref-property
:ref:`String<class_String>` **codesign/password**
Password for the certificate file used to sign executable. See `Sign Tool <https://learn.microsoft.com/en-us/dotnet/framework/tools/signtool-exe>`__.
Can be overridden with the environment variable ``GODOT_WINDOWS_CODESIGN_PASSWORD``.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_codesign/timestamp:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **codesign/timestamp**
If ``true``, time-stamp is added to the signature. See `Sign Tool <https://learn.microsoft.com/en-us/dotnet/framework/tools/signtool-exe>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_codesign/timestamp_server_url:
.. rst-class:: classref-property
:ref:`String<class_String>` **codesign/timestamp_server_url**
URL of the time stamp server. If left empty, the default server is used. See `Sign Tool <https://learn.microsoft.com/en-us/dotnet/framework/tools/signtool-exe>`__.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_custom_template/debug:
.. rst-class:: classref-property
:ref:`String<class_String>` **custom_template/debug**
Path to the custom export template. If left empty, default template is used.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_custom_template/release:
.. rst-class:: classref-property
:ref:`String<class_String>` **custom_template/release**
Path to the custom export template. If left empty, default template is used.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_debug/export_console_script:
.. rst-class:: classref-property
:ref:`int<class_int>` **debug/export_console_script**
If ``true``, a console wrapper executable is exported alongside the main executable, which allows running the project with enabled console output.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_ssh_remote_deploy/cleanup_script:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/cleanup_script**
Script code to execute on the remote host when app is finished.
The following variables can be used in the script:
- ``{temp_dir}`` - Path of temporary folder on the remote, used to upload app and scripts to.
- ``{archive_name}`` - Name of the ZIP containing uploaded application.
- ``{exe_name}`` - Name of application executable.
- ``{cmd_args}`` - Array of the command line argument for the application.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_ssh_remote_deploy/enabled:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **ssh_remote_deploy/enabled**
Enables remote deploy using SSH/SCP.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_ssh_remote_deploy/extra_args_scp:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/extra_args_scp**
Array of the additional command line arguments passed to the SCP.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_ssh_remote_deploy/extra_args_ssh:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/extra_args_ssh**
Array of the additional command line arguments passed to the SSH.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_ssh_remote_deploy/host:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/host**
Remote host SSH user name and address, in ``user@address`` format.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_ssh_remote_deploy/port:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/port**
Remote host SSH port number.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_ssh_remote_deploy/run_script:
.. rst-class:: classref-property
:ref:`String<class_String>` **ssh_remote_deploy/run_script**
Script code to execute on the remote host when running the app.
The following variables can be used in the script:
- ``{temp_dir}`` - Path of temporary folder on the remote, used to upload app and scripts to.
- ``{archive_name}`` - Name of the ZIP containing uploaded application.
- ``{exe_name}`` - Name of application executable.
- ``{cmd_args}`` - Array of the command line argument for the application.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_texture_format/bptc:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **texture_format/bptc**
If ``true``, project textures are exported in the BPTC format.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_texture_format/etc:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **texture_format/etc**
If ``true``, project textures are exported in the ETC format.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_texture_format/etc2:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **texture_format/etc2**
If ``true``, project textures are exported in the ETC2 format.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlatformWindows_property_texture_format/s3tc:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **texture_format/s3tc**
If ``true``, project textures are exported in the S3TC format.
.. |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.)`

View File

@@ -54,8 +54,12 @@ Methods
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`PackedStringArray<class_PackedStringArray>` | :ref:`_get_export_features<class_EditorExportPlugin_method__get_export_features>` **(** :ref:`EditorExportPlatform<class_EditorExportPlatform>` platform, :ref:`bool<class_bool>` debug **)** |virtual| |const| |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Dictionary[]<class_Dictionary>` | :ref:`_get_export_options<class_EditorExportPlugin_method__get_export_options>` **(** :ref:`EditorExportPlatform<class_EditorExportPlatform>` platform **)** |virtual| |const| |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`_get_name<class_EditorExportPlugin_method__get_name>` **(** **)** |virtual| |const| |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_should_update_export_options<class_EditorExportPlugin_method__should_update_export_options>` **(** :ref:`EditorExportPlatform<class_EditorExportPlatform>` platform **)** |virtual| |const| |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`add_file<class_EditorExportPlugin_method_add_file>` **(** :ref:`String<class_String>` path, :ref:`PackedByteArray<class_PackedByteArray>` file, :ref:`bool<class_bool>` remap **)** |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`add_ios_bundle_file<class_EditorExportPlugin_method_add_ios_bundle_file>` **(** :ref:`String<class_String>` path **)** |
@@ -76,6 +80,8 @@ Methods
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`add_shared_object<class_EditorExportPlugin_method_add_shared_object>` **(** :ref:`String<class_String>` path, :ref:`PackedStringArray<class_PackedStringArray>` tags, :ref:`String<class_String>` target **)** |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Variant<class_Variant>` | :ref:`get_option<class_EditorExportPlugin_method_get_option>` **(** :ref:`StringName<class_StringName>` name **)** |const| |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`skip<class_EditorExportPlugin_method_skip>` **(** **)** |
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
@@ -232,6 +238,26 @@ Return a :ref:`PackedStringArray<class_PackedStringArray>` of additional feature
----
.. _class_EditorExportPlugin_method__get_export_options:
.. rst-class:: classref-method
:ref:`Dictionary[]<class_Dictionary>` **_get_export_options** **(** :ref:`EditorExportPlatform<class_EditorExportPlatform>` platform **)** |virtual| |const|
Return a list of export options that can be configured for this export plugin.
Each element in the return value is a :ref:`Dictionary<class_Dictionary>` with the following keys:
- ``option``: A dictionary with the structure documented by :ref:`Object.get_property_list<class_Object_method_get_property_list>`, but all keys are optional.
- ``default_value``: The default value for this option.
- ``update_visibility``: An optional boolean value. If set to ``true``, the preset will emit :ref:`Object.property_list_changed<class_Object_signal_property_list_changed>` when the option is changed.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlugin_method__get_name:
.. rst-class:: classref-method
@@ -246,6 +272,18 @@ Implementing this method is required.
----
.. _class_EditorExportPlugin_method__should_update_export_options:
.. rst-class:: classref-method
:ref:`bool<class_bool>` **_should_update_export_options** **(** :ref:`EditorExportPlatform<class_EditorExportPlatform>` platform **)** |virtual| |const|
Return ``true``, if the result of :ref:`_get_export_options<class_EditorExportPlugin_method__get_export_options>` has changed and the export options of preset corresponding to ``platform`` should be updated.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlugin_method_add_file:
.. rst-class:: classref-method
@@ -376,6 +414,18 @@ In case of a directory code-sign will error if you place non code object in dire
----
.. _class_EditorExportPlugin_method_get_option:
.. rst-class:: classref-method
:ref:`Variant<class_Variant>` **get_option** **(** :ref:`StringName<class_StringName>` name **)** |const|
Returns the current value of an export option supplied by :ref:`_get_export_options<class_EditorExportPlugin_method__get_export_options>`.
.. rst-class:: classref-item-separator
----
.. _class_EditorExportPlugin_method_skip:
.. rst-class:: classref-method

View File

@@ -351,7 +351,7 @@ The view format in which the **EditorFileDialog** displays resources to the user
- void **set_file_mode** **(** :ref:`FileMode<enum_EditorFileDialog_FileMode>` value **)**
- :ref:`FileMode<enum_EditorFileDialog_FileMode>` **get_file_mode** **(** **)**
The dialog's open or save mode, which affects the selection behavior. See :ref:`FileMode<enum_EditorFileDialog_FileMode>`
The dialog's open or save mode, which affects the selection behavior. See :ref:`FileMode<enum_EditorFileDialog_FileMode>`.
.. rst-class:: classref-item-separator

View File

@@ -10,7 +10,7 @@
EditorInterface
===============
**Inherits:** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
**Inherits:** :ref:`Object<class_Object>`
Godot editor's interface.
@@ -34,6 +34,8 @@ Properties
+-------------------------+------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`distraction_free_mode<class_EditorInterface_property_distraction_free_mode>` |
+-------------------------+------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`movie_maker_enabled<class_EditorInterface_property_movie_maker_enabled>` |
+-------------------------+------------------------------------------------------------------------------------+
.. rst-class:: classref-reftable-group
@@ -50,7 +52,7 @@ Methods
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`edit_script<class_EditorInterface_method_edit_script>` **(** :ref:`Script<class_Script>` script, :ref:`int<class_int>` line=-1, :ref:`int<class_int>` column=0, :ref:`bool<class_bool>` grab_focus=true **)** |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Control<class_Control>` | :ref:`get_base_control<class_EditorInterface_method_get_base_control>` **(** **)** |
| :ref:`Control<class_Control>` | :ref:`get_base_control<class_EditorInterface_method_get_base_control>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`EditorCommandPalette<class_EditorCommandPalette>` | :ref:`get_command_palette<class_EditorInterface_method_get_command_palette>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
@@ -58,17 +60,17 @@ Methods
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_current_path<class_EditorInterface_method_get_current_path>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Node<class_Node>` | :ref:`get_edited_scene_root<class_EditorInterface_method_get_edited_scene_root>` **(** **)** |
| :ref:`Node<class_Node>` | :ref:`get_edited_scene_root<class_EditorInterface_method_get_edited_scene_root>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`VBoxContainer<class_VBoxContainer>` | :ref:`get_editor_main_screen<class_EditorInterface_method_get_editor_main_screen>` **(** **)** |
| :ref:`VBoxContainer<class_VBoxContainer>` | :ref:`get_editor_main_screen<class_EditorInterface_method_get_editor_main_screen>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`EditorPaths<class_EditorPaths>` | :ref:`get_editor_paths<class_EditorInterface_method_get_editor_paths>` **(** **)** |
| :ref:`EditorPaths<class_EditorPaths>` | :ref:`get_editor_paths<class_EditorInterface_method_get_editor_paths>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`get_editor_scale<class_EditorInterface_method_get_editor_scale>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`EditorSettings<class_EditorSettings>` | :ref:`get_editor_settings<class_EditorInterface_method_get_editor_settings>` **(** **)** |
| :ref:`EditorSettings<class_EditorSettings>` | :ref:`get_editor_settings<class_EditorInterface_method_get_editor_settings>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`FileSystemDock<class_FileSystemDock>` | :ref:`get_file_system_dock<class_EditorInterface_method_get_file_system_dock>` **(** **)** |
| :ref:`FileSystemDock<class_FileSystemDock>` | :ref:`get_file_system_dock<class_EditorInterface_method_get_file_system_dock>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`EditorInspector<class_EditorInspector>` | :ref:`get_inspector<class_EditorInterface_method_get_inspector>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
@@ -76,20 +78,18 @@ Methods
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_playing_scene<class_EditorInterface_method_get_playing_scene>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`EditorFileSystem<class_EditorFileSystem>` | :ref:`get_resource_filesystem<class_EditorInterface_method_get_resource_filesystem>` **(** **)** |
| :ref:`EditorFileSystem<class_EditorFileSystem>` | :ref:`get_resource_filesystem<class_EditorInterface_method_get_resource_filesystem>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`EditorResourcePreview<class_EditorResourcePreview>` | :ref:`get_resource_previewer<class_EditorInterface_method_get_resource_previewer>` **(** **)** |
| :ref:`EditorResourcePreview<class_EditorResourcePreview>` | :ref:`get_resource_previewer<class_EditorInterface_method_get_resource_previewer>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`ScriptEditor<class_ScriptEditor>` | :ref:`get_script_editor<class_EditorInterface_method_get_script_editor>` **(** **)** |
| :ref:`ScriptEditor<class_ScriptEditor>` | :ref:`get_script_editor<class_EditorInterface_method_get_script_editor>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`PackedStringArray<class_PackedStringArray>` | :ref:`get_selected_paths<class_EditorInterface_method_get_selected_paths>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`EditorSelection<class_EditorSelection>` | :ref:`get_selection<class_EditorInterface_method_get_selection>` **(** **)** |
| :ref:`EditorSelection<class_EditorSelection>` | :ref:`get_selection<class_EditorInterface_method_get_selection>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`inspect_object<class_EditorInterface_method_inspect_object>` **(** :ref:`Object<class_Object>` object, :ref:`String<class_String>` for_property="", :ref:`bool<class_bool>` inspector_only=false **)** |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`is_movie_maker_enabled<class_EditorInterface_method_is_movie_maker_enabled>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`is_playing_scene<class_EditorInterface_method_is_playing_scene>` **(** **)** |const| |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`is_plugin_enabled<class_EditorInterface_method_is_plugin_enabled>` **(** :ref:`String<class_String>` plugin **)** |const| |
@@ -116,8 +116,6 @@ Methods
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`set_main_screen_editor<class_EditorInterface_method_set_main_screen_editor>` **(** :ref:`String<class_String>` name **)** |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`set_movie_maker_enabled<class_EditorInterface_method_set_movie_maker_enabled>` **(** :ref:`bool<class_bool>` enabled **)** |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`set_plugin_enabled<class_EditorInterface_method_set_plugin_enabled>` **(** :ref:`String<class_String>` plugin, :ref:`bool<class_bool>` enabled **)** |
+-----------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`stop_playing_scene<class_EditorInterface_method_stop_playing_scene>` **(** **)** |
@@ -145,6 +143,23 @@ Property Descriptions
If ``true``, enables distraction-free mode which hides side docks to increase the space available for the main view.
.. rst-class:: classref-item-separator
----
.. _class_EditorInterface_property_movie_maker_enabled:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **movie_maker_enabled**
.. rst-class:: classref-property-setget
- void **set_movie_maker_enabled** **(** :ref:`bool<class_bool>` value **)**
- :ref:`bool<class_bool>` **is_movie_maker_enabled** **(** **)**
If ``true``, the Movie Maker mode is enabled in the editor. See :ref:`MovieWriter<class_MovieWriter>` for more information.
.. rst-class:: classref-section-separator
----
@@ -194,7 +209,7 @@ Edits the given :ref:`Script<class_Script>`. The line and column on which to ope
.. rst-class:: classref-method
:ref:`Control<class_Control>` **get_base_control** **(** **)**
:ref:`Control<class_Control>` **get_base_control** **(** **)** |const|
Returns the main container of Godot editor's window. For example, you can use it to retrieve the size of the container and place your controls accordingly.
@@ -246,7 +261,7 @@ Returns the current path being viewed in the :ref:`FileSystemDock<class_FileSyst
.. rst-class:: classref-method
:ref:`Node<class_Node>` **get_edited_scene_root** **(** **)**
:ref:`Node<class_Node>` **get_edited_scene_root** **(** **)** |const|
Returns the edited (current) scene's root :ref:`Node<class_Node>`.
@@ -258,7 +273,7 @@ Returns the edited (current) scene's root :ref:`Node<class_Node>`.
.. rst-class:: classref-method
:ref:`VBoxContainer<class_VBoxContainer>` **get_editor_main_screen** **(** **)**
:ref:`VBoxContainer<class_VBoxContainer>` **get_editor_main_screen** **(** **)** |const|
Returns the editor control responsible for main screen plugins and tools. Use it with plugins that implement :ref:`EditorPlugin._has_main_screen<class_EditorPlugin_method__has_main_screen>`.
@@ -272,7 +287,7 @@ Returns the editor control responsible for main screen plugins and tools. Use it
.. rst-class:: classref-method
:ref:`EditorPaths<class_EditorPaths>` **get_editor_paths** **(** **)**
:ref:`EditorPaths<class_EditorPaths>` **get_editor_paths** **(** **)** |const|
Returns the :ref:`EditorPaths<class_EditorPaths>` singleton.
@@ -298,7 +313,7 @@ Returns the actual scale of the editor UI (``1.0`` being 100% scale). This can b
.. rst-class:: classref-method
:ref:`EditorSettings<class_EditorSettings>` **get_editor_settings** **(** **)**
:ref:`EditorSettings<class_EditorSettings>` **get_editor_settings** **(** **)** |const|
Returns the editor's :ref:`EditorSettings<class_EditorSettings>` instance.
@@ -310,7 +325,7 @@ Returns the editor's :ref:`EditorSettings<class_EditorSettings>` instance.
.. rst-class:: classref-method
:ref:`FileSystemDock<class_FileSystemDock>` **get_file_system_dock** **(** **)**
:ref:`FileSystemDock<class_FileSystemDock>` **get_file_system_dock** **(** **)** |const|
Returns the editor's :ref:`FileSystemDock<class_FileSystemDock>` instance.
@@ -362,7 +377,7 @@ Returns the name of the scene that is being played. If no scene is currently bei
.. rst-class:: classref-method
:ref:`EditorFileSystem<class_EditorFileSystem>` **get_resource_filesystem** **(** **)**
:ref:`EditorFileSystem<class_EditorFileSystem>` **get_resource_filesystem** **(** **)** |const|
Returns the editor's :ref:`EditorFileSystem<class_EditorFileSystem>` instance.
@@ -374,7 +389,7 @@ Returns the editor's :ref:`EditorFileSystem<class_EditorFileSystem>` instance.
.. rst-class:: classref-method
:ref:`EditorResourcePreview<class_EditorResourcePreview>` **get_resource_previewer** **(** **)**
:ref:`EditorResourcePreview<class_EditorResourcePreview>` **get_resource_previewer** **(** **)** |const|
Returns the editor's :ref:`EditorResourcePreview<class_EditorResourcePreview>` instance.
@@ -386,7 +401,7 @@ Returns the editor's :ref:`EditorResourcePreview<class_EditorResourcePreview>` i
.. rst-class:: classref-method
:ref:`ScriptEditor<class_ScriptEditor>` **get_script_editor** **(** **)**
:ref:`ScriptEditor<class_ScriptEditor>` **get_script_editor** **(** **)** |const|
Returns the editor's :ref:`ScriptEditor<class_ScriptEditor>` instance.
@@ -412,7 +427,7 @@ Returns an array containing the paths of the currently selected files (and direc
.. rst-class:: classref-method
:ref:`EditorSelection<class_EditorSelection>` **get_selection** **(** **)**
:ref:`EditorSelection<class_EditorSelection>` **get_selection** **(** **)** |const|
Returns the editor's :ref:`EditorSelection<class_EditorSelection>` instance.
@@ -432,18 +447,6 @@ Shows the given property on the given ``object`` in the editor's Inspector dock.
----
.. _class_EditorInterface_method_is_movie_maker_enabled:
.. rst-class:: classref-method
:ref:`bool<class_bool>` **is_movie_maker_enabled** **(** **)** |const|
Returns ``true`` if Movie Maker mode is enabled in the editor. See also :ref:`set_movie_maker_enabled<class_EditorInterface_method_set_movie_maker_enabled>`. See :ref:`MovieWriter<class_MovieWriter>` for more information.
.. rst-class:: classref-item-separator
----
.. _class_EditorInterface_method_is_playing_scene:
.. rst-class:: classref-method
@@ -600,18 +603,6 @@ Sets the editor's current main screen to the one specified in ``name``. ``name``
----
.. _class_EditorInterface_method_set_movie_maker_enabled:
.. rst-class:: classref-method
void **set_movie_maker_enabled** **(** :ref:`bool<class_bool>` enabled **)**
Sets whether Movie Maker mode is enabled in the editor. See also :ref:`is_movie_maker_enabled<class_EditorInterface_method_is_movie_maker_enabled>`. See :ref:`MovieWriter<class_MovieWriter>` for more information.
.. rst-class:: classref-item-separator
----
.. _class_EditorInterface_method_set_plugin_enabled:
.. rst-class:: classref-method

View File

@@ -155,7 +155,11 @@ Returns the absolute path to the self-contained file that makes the current Godo
Returns ``true`` if the editor is marked as self-contained, ``false`` otherwise. When self-contained mode is enabled, user configuration, data and cache files are saved in an ``editor_data/`` folder next to the editor binary. This makes portable usage easier and ensures the Godot editor minimizes file writes outside its own folder. Self-contained mode is not available for exported projects.
Self-contained mode can be enabled by creating a file named ``._sc_`` or ``_sc_`` in the same folder as the editor binary while the editor is not running. See also :ref:`get_self_contained_file<class_EditorPaths_method_get_self_contained_file>`.
Self-contained mode can be enabled by creating a file named ``._sc_`` or ``_sc_`` in the same folder as the editor binary or macOS .app bundle while the editor is not running. See also :ref:`get_self_contained_file<class_EditorPaths_method_get_self_contained_file>`.
\ **Note:** On macOS, quarantine flag should be manually removed before using self-contained mode, see `Running on macOS <https://docs.godotengine.org/en/stable/tutorials/export/running_on_macos.html>`__.
\ **Note:** On macOS, placing ``_sc_`` or any other file inside .app bundle will break digital signature and make it non-portable, consider placing it in the same folder as the .app bundle instead.
\ **Note:** The Steam release of Godot uses self-contained mode by default.

View File

@@ -1279,7 +1279,7 @@ The callback should have 4 arguments: :ref:`Object<class_Object>` ``undo_redo``,
:ref:`EditorInterface<class_EditorInterface>` **get_editor_interface** **(** **)**
Returns the :ref:`EditorInterface<class_EditorInterface>` object that gives you control over Godot editor's window and its functionalities.
Returns the :ref:`EditorInterface<class_EditorInterface>` singleton. It provides access to some parts of the editor GUI as well as various inner states and tools.
.. rst-class:: classref-item-separator

View File

@@ -30,13 +30,13 @@ Below shows an example of a basic plugin that will convert an :ref:`ImageTexture
extends EditorResourceConversionPlugin
func _handles(resource : Resource):
func _handles(resource: Resource):
return resource is ImageTexture
func _converts_to():
return "PortableCompressedTexture2D"
func _convert(itex : Resource):
func _convert(itex: Resource):
var ptex = PortableCompressedTexture2D.new()
ptex.create_from_image(itex.get_image(), PortableCompressedTexture2D.COMPRESSION_MODE_LOSSLESS)
return ptex

View File

@@ -29,17 +29,17 @@ Methods
.. table::
:widths: auto
+-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_can_generate_small_preview<class_EditorResourcePreviewGenerator_method__can_generate_small_preview>` **(** **)** |virtual| |const| |
+-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`_generate<class_EditorResourcePreviewGenerator_method__generate>` **(** :ref:`Resource<class_Resource>` resource, :ref:`Vector2i<class_Vector2i>` size **)** |virtual| |const| |
+-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`_generate_from_path<class_EditorResourcePreviewGenerator_method__generate_from_path>` **(** :ref:`String<class_String>` path, :ref:`Vector2i<class_Vector2i>` size **)** |virtual| |const| |
+-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_generate_small_preview_automatically<class_EditorResourcePreviewGenerator_method__generate_small_preview_automatically>` **(** **)** |virtual| |const| |
+-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_handles<class_EditorResourcePreviewGenerator_method__handles>` **(** :ref:`String<class_String>` type **)** |virtual| |const| |
+-----------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+-----------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_can_generate_small_preview<class_EditorResourcePreviewGenerator_method__can_generate_small_preview>` **(** **)** |virtual| |const| |
+-----------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`_generate<class_EditorResourcePreviewGenerator_method__generate>` **(** :ref:`Resource<class_Resource>` resource, :ref:`Vector2i<class_Vector2i>` size, :ref:`Dictionary<class_Dictionary>` metadata **)** |virtual| |const| |
+-----------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Texture2D<class_Texture2D>` | :ref:`_generate_from_path<class_EditorResourcePreviewGenerator_method__generate_from_path>` **(** :ref:`String<class_String>` path, :ref:`Vector2i<class_Vector2i>` size, :ref:`Dictionary<class_Dictionary>` metadata **)** |virtual| |const| |
+-----------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_generate_small_preview_automatically<class_EditorResourcePreviewGenerator_method__generate_small_preview_automatically>` **(** **)** |virtual| |const| |
+-----------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_handles<class_EditorResourcePreviewGenerator_method__handles>` **(** :ref:`String<class_String>` type **)** |virtual| |const| |
+-----------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
@@ -68,7 +68,7 @@ By default, it returns ``false``.
.. rst-class:: classref-method
:ref:`Texture2D<class_Texture2D>` **_generate** **(** :ref:`Resource<class_Resource>` resource, :ref:`Vector2i<class_Vector2i>` size **)** |virtual| |const|
:ref:`Texture2D<class_Texture2D>` **_generate** **(** :ref:`Resource<class_Resource>` resource, :ref:`Vector2i<class_Vector2i>` size, :ref:`Dictionary<class_Dictionary>` metadata **)** |virtual| |const|
Generate a preview from a given resource with the specified size. This must always be implemented.
@@ -76,6 +76,8 @@ Returning an empty texture is an OK way to fail and let another generator take c
Care must be taken because this function is always called from a thread (not the main thread).
\ ``metadata`` dictionary can modified to store file-specific metadata that can be used in :ref:`EditorResourceTooltipPlugin._make_tooltip_for_path<class_EditorResourceTooltipPlugin_method__make_tooltip_for_path>` (like image size, sample length etc.).
.. rst-class:: classref-item-separator
----
@@ -84,7 +86,7 @@ Care must be taken because this function is always called from a thread (not the
.. rst-class:: classref-method
:ref:`Texture2D<class_Texture2D>` **_generate_from_path** **(** :ref:`String<class_String>` path, :ref:`Vector2i<class_Vector2i>` size **)** |virtual| |const|
:ref:`Texture2D<class_Texture2D>` **_generate_from_path** **(** :ref:`String<class_String>` path, :ref:`Vector2i<class_Vector2i>` size, :ref:`Dictionary<class_Dictionary>` metadata **)** |virtual| |const|
Generate a preview directly from a path with the specified size. Implementing this is optional, as default code will load and call :ref:`_generate<class_EditorResourcePreviewGenerator_method__generate>`.
@@ -92,6 +94,8 @@ Returning an empty texture is an OK way to fail and let another generator take c
Care must be taken because this function is always called from a thread (not the main thread).
\ ``metadata`` dictionary can modified to store file-specific metadata that can be used in :ref:`EditorResourceTooltipPlugin._make_tooltip_for_path<class_EditorResourceTooltipPlugin_method__make_tooltip_for_path>` (like image size, sample length etc.).
.. rst-class:: classref-item-separator
----

View File

@@ -0,0 +1,106 @@
: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/EditorResourceTooltipPlugin.xml.
.. _class_EditorResourceTooltipPlugin:
EditorResourceTooltipPlugin
===========================
**Inherits:** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
A plugin that advanced tooltip for its handled resource type.
.. rst-class:: classref-introduction-group
Description
-----------
Resource tooltip plugins are used by :ref:`FileSystemDock<class_FileSystemDock>` to generate customized tooltips for specific resources. E.g. tooltip for a :ref:`Texture2D<class_Texture2D>` displays a bigger preview and the texture's dimensions.
A plugin must be first registered with :ref:`FileSystemDock.add_resource_tooltip_plugin<class_FileSystemDock_method_add_resource_tooltip_plugin>`. When the user hovers a resource in filesystem dock which is handled by the plugin, :ref:`_make_tooltip_for_path<class_EditorResourceTooltipPlugin_method__make_tooltip_for_path>` is called to create the tooltip. It works similarly to :ref:`Control._make_custom_tooltip<class_Control_method__make_custom_tooltip>`.
.. rst-class:: classref-reftable-group
Methods
-------
.. table::
:widths: auto
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`_handles<class_EditorResourceTooltipPlugin_method__handles>` **(** :ref:`String<class_String>` type **)** |virtual| |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Object<class_Object>` | :ref:`_make_tooltip_for_path<class_EditorResourceTooltipPlugin_method__make_tooltip_for_path>` **(** :ref:`String<class_String>` path, :ref:`Dictionary<class_Dictionary>` metadata **)** |virtual| |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`VBoxContainer<class_VBoxContainer>` | :ref:`make_default_tooltip<class_EditorResourceTooltipPlugin_method_make_default_tooltip>` **(** :ref:`String<class_String>` path **)** |static| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`request_thumbnail<class_EditorResourceTooltipPlugin_method_request_thumbnail>` **(** :ref:`String<class_String>` path, :ref:`TextureRect<class_TextureRect>` control **)** |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Method Descriptions
-------------------
.. _class_EditorResourceTooltipPlugin_method__handles:
.. rst-class:: classref-method
:ref:`bool<class_bool>` **_handles** **(** :ref:`String<class_String>` type **)** |virtual| |const|
Return ``true`` if the plugin is going to handle the given :ref:`Resource<class_Resource>` ``type``.
.. rst-class:: classref-item-separator
----
.. _class_EditorResourceTooltipPlugin_method__make_tooltip_for_path:
.. rst-class:: classref-method
:ref:`Object<class_Object>` **_make_tooltip_for_path** **(** :ref:`String<class_String>` path, :ref:`Dictionary<class_Dictionary>` metadata **)** |virtual| |const|
Create and return a tooltip that will be displayed when the user hovers resource under given ``path`` in filesystem dock. For best results, use :ref:`make_default_tooltip<class_EditorResourceTooltipPlugin_method_make_default_tooltip>` as a base.
The ``metadata`` dictionary is provided by preview generator (see method EditorResourcePreviewGenerator._generate]).
\ **Note:** It's unadvised to use :ref:`ResourceLoader.load<class_ResourceLoader_method_load>`, especially with heavy resources like models or textures, because it will make the editor unresponsive when creating the tooltip. You can use :ref:`request_thumbnail<class_EditorResourceTooltipPlugin_method_request_thumbnail>` if you want to display a preview in your tooltip.
.. rst-class:: classref-item-separator
----
.. _class_EditorResourceTooltipPlugin_method_make_default_tooltip:
.. rst-class:: classref-method
:ref:`VBoxContainer<class_VBoxContainer>` **make_default_tooltip** **(** :ref:`String<class_String>` path **)** |static|
Creates a default file tooltip. The tooltip includes file name, file size and :ref:`Resource<class_Resource>` type if available.
.. rst-class:: classref-item-separator
----
.. _class_EditorResourceTooltipPlugin_method_request_thumbnail:
.. rst-class:: classref-method
void **request_thumbnail** **(** :ref:`String<class_String>` path, :ref:`TextureRect<class_TextureRect>` control **)** |const|
Requests a thumbnail for the given :ref:`TextureRect<class_TextureRect>`. The thumbnail is created asynchronously by :ref:`EditorResourcePreview<class_EditorResourcePreview>` and automatically set when available.
.. |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.)`

View File

@@ -68,9 +68,9 @@ Methods
+-----------------------------------------------+--------------------------------------------------------------------------------------------------------+
| void | :ref:`add_root_node<class_EditorScript_method_add_root_node>` **(** :ref:`Node<class_Node>` node **)** |
+-----------------------------------------------+--------------------------------------------------------------------------------------------------------+
| :ref:`EditorInterface<class_EditorInterface>` | :ref:`get_editor_interface<class_EditorScript_method_get_editor_interface>` **(** **)** |
| :ref:`EditorInterface<class_EditorInterface>` | :ref:`get_editor_interface<class_EditorScript_method_get_editor_interface>` **(** **)** |const| |
+-----------------------------------------------+--------------------------------------------------------------------------------------------------------+
| :ref:`Node<class_Node>` | :ref:`get_scene<class_EditorScript_method_get_scene>` **(** **)** |
| :ref:`Node<class_Node>` | :ref:`get_scene<class_EditorScript_method_get_scene>` **(** **)** |const| |
+-----------------------------------------------+--------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
@@ -112,7 +112,7 @@ Adds ``node`` as a child of the root node in the editor context.
.. rst-class:: classref-method
:ref:`EditorInterface<class_EditorInterface>` **get_editor_interface** **(** **)**
:ref:`EditorInterface<class_EditorInterface>` **get_editor_interface** **(** **)** |const|
Returns the :ref:`EditorInterface<class_EditorInterface>` singleton instance.
@@ -124,7 +124,7 @@ Returns the :ref:`EditorInterface<class_EditorInterface>` singleton instance.
.. rst-class:: classref-method
:ref:`Node<class_Node>` **get_scene** **(** **)**
:ref:`Node<class_Node>` **get_scene** **(** **)** |const|
Returns the Editor's currently active scene.

View File

@@ -30,7 +30,7 @@ Accessing the settings can be done using the following methods, such as:
.. code-tab:: gdscript
var settings = EditorInterface.get_editor_settings()
var settings = get_editor_interface().get_editor_settings()
# `settings.set("some/property", 10)` also works as this class overrides `_set()` internally.
settings.set_setting("some/property", 10)
# `settings.get("some/property")` also works as this class overrides `_get()` internally.
@@ -203,6 +203,8 @@ Properties
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`editors/polygon_editor/show_previous_outline<class_EditorSettings_property_editors/polygon_editor/show_previous_outline>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`editors/shader_editor/behavior/files/restore_shaders_on_load<class_EditorSettings_property_editors/shader_editor/behavior/files/restore_shaders_on_load>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`editors/tiles_editor/display_grid<class_EditorSettings_property_editors/tiles_editor/display_grid>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Color<class_Color>` | :ref:`editors/tiles_editor/grid_color<class_EditorSettings_property_editors/tiles_editor/grid_color>` |
@@ -257,6 +259,8 @@ Properties
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`interface/editor/editor_language<class_EditorSettings_property_interface/editor/editor_language>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`interface/editor/editor_screen<class_EditorSettings_property_interface/editor/editor_screen>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`interface/editor/expand_to_title<class_EditorSettings_property_interface/editor/expand_to_title>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`interface/editor/font_antialiasing<class_EditorSettings_property_interface/editor/font_antialiasing>` |
@@ -275,6 +279,8 @@ Properties
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`interface/editor/mouse_extra_buttons_navigate_history<class_EditorSettings_property_interface/editor/mouse_extra_buttons_navigate_history>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`interface/editor/project_manager_screen<class_EditorSettings_property_interface/editor/project_manager_screen>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`interface/editor/save_each_scene_on_quit<class_EditorSettings_property_interface/editor/save_each_scene_on_quit>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`interface/editor/separate_distraction_mode<class_EditorSettings_property_interface/editor/separate_distraction_mode>` |
@@ -287,10 +293,18 @@ Properties
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`interface/editor/use_embedded_menu<class_EditorSettings_property_interface/editor/use_embedded_menu>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`interface/inspector/float_drag_speed<class_EditorSettings_property_interface/inspector/float_drag_speed>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`interface/inspector/max_array_dictionary_items_per_page<class_EditorSettings_property_interface/inspector/max_array_dictionary_items_per_page>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`interface/inspector/show_low_level_opentype_features<class_EditorSettings_property_interface/inspector/show_low_level_opentype_features>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`interface/multi_window/enable<class_EditorSettings_property_interface/multi_window/enable>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`interface/multi_window/maximize_window<class_EditorSettings_property_interface/multi_window/maximize_window>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`interface/multi_window/restore_windows_on_load<class_EditorSettings_property_interface/multi_window/restore_windows_on_load>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`interface/scene_tabs/display_close_button<class_EditorSettings_property_interface/scene_tabs/display_close_button>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`interface/scene_tabs/maximum_width<class_EditorSettings_property_interface/scene_tabs/maximum_width>` |
@@ -329,6 +343,8 @@ Properties
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`interface/touchscreen/increase_scrollbar_touch_area<class_EditorSettings_property_interface/touchscreen/increase_scrollbar_touch_area>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`interface/touchscreen/scale_gizmo_handles<class_EditorSettings_property_interface/touchscreen/scale_gizmo_handles>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`network/debug/remote_host<class_EditorSettings_property_network/debug/remote_host>` |
+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`network/debug/remote_port<class_EditorSettings_property_network/debug/remote_port>` |
@@ -1055,7 +1071,7 @@ If ``true``, render the grid on an XZ plane.
:ref:`bool<class_bool>` **editors/3d/grid_yz_plane**
If ``true``, render the grid on an YZ plane. This can be useful for 3D side-scrolling games.
If ``true``, render the grid on a YZ plane. This can be useful for 3D side-scrolling games.
.. rst-class:: classref-item-separator
@@ -1171,7 +1187,7 @@ The modifier key that must be held to pan in the 3D editor.
:ref:`bool<class_bool>` **editors/3d/navigation/warped_mouse_panning**
If ``true``, warps the mouse around the 3D viewport while panning in the 3D editor. This makes it possible to pan over a large area without having to exit panning then mouse the mouse back constantly.
If ``true``, warps the mouse around the 3D viewport while panning in the 3D editor. This makes it possible to pan over a large area without having to exit panning and adjust the mouse cursor.
.. rst-class:: classref-item-separator
@@ -1485,7 +1501,7 @@ Controls whether the mouse wheel scroll zooms or pans in subeditors. The list of
:ref:`bool<class_bool>` **editors/panning/warped_mouse_panning**
If ``true``, warps the mouse around the 2D viewport while panning in the 2D editor. This makes it possible to pan over a large area without having to exit panning then mouse the mouse back constantly.
If ``true``, warps the mouse around the 2D viewport while panning in the 2D editor. This makes it possible to pan over a large area without having to exit panning and adjust the mouse cursor.
.. rst-class:: classref-item-separator
@@ -1515,6 +1531,18 @@ If ``true``, displays the polygon's previous shape in the 2D polygon editors wit
----
.. _class_EditorSettings_property_editors/shader_editor/behavior/files/restore_shaders_on_load:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **editors/shader_editor/behavior/files/restore_shaders_on_load**
If ``true``, reopens shader files that were open in the shader editor when the project was last closed.
.. rst-class:: classref-item-separator
----
.. _class_EditorSettings_property_editors/tiles_editor/display_grid:
.. rst-class:: classref-property
@@ -1871,6 +1899,18 @@ Translations are provided by the community. If you spot a mistake, :doc:`contrib
----
.. _class_EditorSettings_property_interface/editor/editor_screen:
.. rst-class:: classref-property
:ref:`int<class_int>` **interface/editor/editor_screen**
The preferred monitor to display the editor.
.. rst-class:: classref-item-separator
----
.. _class_EditorSettings_property_interface/editor/expand_to_title:
.. rst-class:: classref-property
@@ -1989,13 +2029,25 @@ If ``true``, the mouse's additional side buttons will be usable to navigate in t
----
.. _class_EditorSettings_property_interface/editor/project_manager_screen:
.. rst-class:: classref-property
:ref:`int<class_int>` **interface/editor/project_manager_screen**
The preferred monitor to display the project manager.
.. rst-class:: classref-item-separator
----
.. _class_EditorSettings_property_interface/editor/save_each_scene_on_quit:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **interface/editor/save_each_scene_on_quit**
If ``true``, the editor will save all scenes when confirming the **Save** action when quitting the editor or quitting to the project list. If ``false``, the editor will ask to save each scene individually.
If ``false``, the editor will save all scenes when confirming the **Save** action when quitting the editor or quitting to the project list. If ``true``, the editor will ask to save each scene individually.
.. rst-class:: classref-item-separator
@@ -2065,6 +2117,18 @@ Specific to the macOS platform.
----
.. _class_EditorSettings_property_interface/inspector/float_drag_speed:
.. rst-class:: classref-property
:ref:`float<class_float>` **interface/inspector/float_drag_speed**
Base speed for increasing/decreasing float values by dragging them in the inspector.
.. rst-class:: classref-item-separator
----
.. _class_EditorSettings_property_interface/inspector/max_array_dictionary_items_per_page:
.. rst-class:: classref-property
@@ -2089,6 +2153,46 @@ If ``true``, display OpenType features marked as ``hidden`` by the font file in
----
.. _class_EditorSettings_property_interface/multi_window/enable:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **interface/multi_window/enable**
If ``true``, the multi window support in editor is enabled. The following panels can become dedicated windows (made floating): Docks, Script editor, and Shader editor.
\ **Note:** When :ref:`interface/editor/single_window_mode<class_EditorSettings_property_interface/editor/single_window_mode>` is ``true``, the multi window support is always disabled.
.. rst-class:: classref-item-separator
----
.. _class_EditorSettings_property_interface/multi_window/maximize_window:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **interface/multi_window/maximize_window**
If ``true``, when panels are made floating they will be maximized.
If ``false``, when panels are made floating their position and size will match the ones when they are attached (excluding window border) to the editor window.
.. rst-class:: classref-item-separator
----
.. _class_EditorSettings_property_interface/multi_window/restore_windows_on_load:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **interface/multi_window/restore_windows_on_load**
If ``true``, the floating panel position, size, and screen will be saved on editor exit. On next launch the panels that were floating will be made floating in the saved positions, sizes and screens, if possible.
.. rst-class:: classref-item-separator
----
.. _class_EditorSettings_property_interface/scene_tabs/display_close_button:
.. rst-class:: classref-property
@@ -2331,6 +2435,20 @@ If ``true``, increases the scrollbar touch area to improve usability on touchscr
----
.. _class_EditorSettings_property_interface/touchscreen/scale_gizmo_handles:
.. rst-class:: classref-property
:ref:`float<class_float>` **interface/touchscreen/scale_gizmo_handles**
Specify the multiplier to apply to the scale for the editor gizmo handles to improve usability on touchscreen devices.
\ **Note:** Defaults to ``1`` on non-touchscreen devices.
.. rst-class:: classref-item-separator
----
.. _class_EditorSettings_property_network/debug/remote_host:
.. rst-class:: classref-property
@@ -2533,7 +2651,7 @@ If ``true``, makes the caret blink according to :ref:`text_editor/appearance/car
:ref:`float<class_float>` **text_editor/appearance/caret/caret_blink_interval**
The interval at which to blink the caret (in seconds). See also :ref:`text_editor/appearance/caret/caret_blink<class_EditorSettings_property_text_editor/appearance/caret/caret_blink>`.
The interval at which the caret will blink (in seconds). See also :ref:`text_editor/appearance/caret/caret_blink<class_EditorSettings_property_text_editor/appearance/caret/caret_blink>`.
.. rst-class:: classref-item-separator
@@ -2569,7 +2687,7 @@ If ``true``, colors the background of the line the caret is currently on with :r
:ref:`int<class_int>` **text_editor/appearance/caret/type**
The shape of the caret to use in the script editor. **Line** displays a vertical line to the left of the current character, whereas **Block** displays a outline over the current character.
The shape of the caret to use in the script editor. **Line** displays a vertical line to the left of the current character, whereas **Block** displays an outline over the current character.
.. rst-class:: classref-item-separator
@@ -3646,7 +3764,7 @@ Erases the setting whose name is specified by ``property``.
:ref:`PackedStringArray<class_PackedStringArray>` **get_changed_settings** **(** **)** |const|
Gets an array of the settings which have been changed since the last save. Note that internally ``changed_settings`` is cleared after a successful save, so generally the most appropriate place to use this method is when processing :ref:`NOTIFICATION_EDITOR_SETTINGS_CHANGED<class_EditorSettings_constant_NOTIFICATION_EDITOR_SETTINGS_CHANGED>`
Gets an array of the settings which have been changed since the last save. Note that internally ``changed_settings`` is cleared after a successful save, so generally the most appropriate place to use this method is when processing :ref:`NOTIFICATION_EDITOR_SETTINGS_CHANGED<class_EditorSettings_constant_NOTIFICATION_EDITOR_SETTINGS_CHANGED>`.
.. rst-class:: classref-item-separator

View File

@@ -31,6 +31,10 @@ The usage is mostly the same as :ref:`UndoRedo<class_UndoRedo>`. You create and
This guessing can sometimes yield false results, so you can provide a custom context object when creating an action.
\ **EditorUndoRedoManager** is intended to be used by Godot editor plugins. You can obtain it using :ref:`EditorPlugin.get_undo_redo<class_EditorPlugin_method_get_undo_redo>`. For non-editor uses or plugins that don't need to integrate with the editor's undo history, use :ref:`UndoRedo<class_UndoRedo>` instead.
The manager's API is mostly the same as in :ref:`UndoRedo<class_UndoRedo>`, so you can refer to its documentation for more examples. The main difference is that **EditorUndoRedoManager** uses object + method name for actions, instead of :ref:`Callable<class_Callable>`.
.. rst-class:: classref-reftable-group
Methods

View File

@@ -265,7 +265,7 @@ Discards the changes made in a file present at ``file_path``.
void **_fetch** **(** :ref:`String<class_String>` remote **)** |virtual|
Fetches new changes from the remote, but doesn't write changes to the current working directory. Equivalent to ``git fetch``.
Fetches new changes from the ``remote``, but doesn't write changes to the current working directory. Equivalent to ``git fetch``.
.. rst-class:: classref-item-separator
@@ -397,7 +397,7 @@ Pulls changes from the remote. This can give rise to merge conflicts.
void **_push** **(** :ref:`String<class_String>` remote, :ref:`bool<class_bool>` force **)** |virtual|
Pushes changes to the ``remote``. Optionally, if ``force`` is set to true, a force push will override the change history already present on the remote.
Pushes changes to the ``remote``. If ``force`` is ``true``, a force push will override the change history already present on the remote.
.. rst-class:: classref-item-separator
@@ -517,7 +517,7 @@ Helper function to create a commit :ref:`Dictionary<class_Dictionary>` item. ``m
:ref:`Dictionary<class_Dictionary>` **create_diff_file** **(** :ref:`String<class_String>` new_file, :ref:`String<class_String>` old_file **)**
Helper function to create a ``Dictionary`` for storing old and new diff file paths.
Helper function to create a :ref:`Dictionary<class_Dictionary>` for storing old and new diff file paths.
.. rst-class:: classref-item-separator
@@ -529,7 +529,7 @@ Helper function to create a ``Dictionary`` for storing old and new diff file pat
:ref:`Dictionary<class_Dictionary>` **create_diff_hunk** **(** :ref:`int<class_int>` old_start, :ref:`int<class_int>` new_start, :ref:`int<class_int>` old_lines, :ref:`int<class_int>` new_lines **)**
Helper function to create a ``Dictionary`` for storing diff hunk data. ``old_start`` is the starting line number in old file. ``new_start`` is the starting line number in new file. ``old_lines`` is the number of lines in the old file. ``new_lines`` is the number of lines in the new file.
Helper function to create a :ref:`Dictionary<class_Dictionary>` for storing diff hunk data. ``old_start`` is the starting line number in old file. ``new_start`` is the starting line number in new file. ``old_lines`` is the number of lines in the old file. ``new_lines`` is the number of lines in the new file.
.. rst-class:: classref-item-separator
@@ -541,7 +541,7 @@ Helper function to create a ``Dictionary`` for storing diff hunk data. ``old_sta
:ref:`Dictionary<class_Dictionary>` **create_diff_line** **(** :ref:`int<class_int>` new_line_no, :ref:`int<class_int>` old_line_no, :ref:`String<class_String>` content, :ref:`String<class_String>` status **)**
Helper function to create a ``Dictionary`` for storing a line diff. ``new_line_no`` is the line number in the new file (can be ``-1`` if the line is deleted). ``old_line_no`` is the line number in the old file (can be ``-1`` if the line is added). ``content`` is the diff text. ``status`` is a single character string which stores the line origin.
Helper function to create a :ref:`Dictionary<class_Dictionary>` for storing a line diff. ``new_line_no`` is the line number in the new file (can be ``-1`` if the line is deleted). ``old_line_no`` is the line number in the old file (can be ``-1`` if the line is added). ``content`` is the diff text. ``status`` is a single character string which stores the line origin.
.. rst-class:: classref-item-separator
@@ -553,7 +553,7 @@ Helper function to create a ``Dictionary`` for storing a line diff. ``new_line_n
:ref:`Dictionary<class_Dictionary>` **create_status_file** **(** :ref:`String<class_String>` file_path, :ref:`ChangeType<enum_EditorVCSInterface_ChangeType>` change_type, :ref:`TreeArea<enum_EditorVCSInterface_TreeArea>` area **)**
Helper function to create a ``Dictionary`` used by editor to read the status of a file.
Helper function to create a :ref:`Dictionary<class_Dictionary>` used by editor to read the status of a file.
.. rst-class:: classref-item-separator

View File

@@ -511,7 +511,7 @@ void **set_timeout** **(** :ref:`int<class_int>` timeout, :ref:`int<class_int>`
Sets the timeout parameters for a peer. The timeout parameters control how and when a peer will timeout from a failure to acknowledge reliable traffic. Timeout values are expressed in milliseconds.
The ``timeout_limit`` is a factor that, multiplied by a value based on the average round trip time, will determine the timeout limit for a reliable packet. When that limit is reached, the timeout will be doubled, and the peer will be disconnected if that limit has reached ``timeout_min``. The ``timeout_max`` parameter, on the other hand, defines a fixed timeout for which any packet must be acknowledged or the peer will be dropped.
The ``timeout`` is a factor that, multiplied by a value based on the average round trip time, will determine the timeout limit for a reliable packet. When that limit is reached, the timeout will be doubled, and the peer will be disconnected if that limit has reached ``timeout_min``. The ``timeout_max`` parameter, on the other hand, defines a fixed timeout for which any packet must be acknowledged or the peer will be dropped.
.. rst-class:: classref-item-separator

View File

@@ -226,7 +226,7 @@ If ``false``, stops printing error and warning messages to the console and edito
- void **set_time_scale** **(** :ref:`float<class_float>` value **)**
- :ref:`float<class_float>` **get_time_scale** **(** **)**
Controls how fast or slow the in-game clock ticks versus the real life one. It defaults to 1.0. A value of 2.0 means the game moves twice as fast as real life, whilst a value of 0.5 means the game moves at half the regular speed.
Controls how fast or slow the in-game clock ticks versus the real life one. It defaults to 1.0. A value of 2.0 means the game moves twice as fast as real life, whilst a value of 0.5 means the game moves at half the regular speed. This also affects :ref:`Timer<class_Timer>` and :ref:`SceneTreeTimer<class_SceneTreeTimer>` (see :ref:`SceneTree.create_timer<class_SceneTree_method_create_timer>` for how to control this).
.. rst-class:: classref-section-separator

View File

@@ -1858,7 +1858,7 @@ If ``true``, screen-space reflections are enabled. Screen-space reflections are
- void **set_ssr_fade_in** **(** :ref:`float<class_float>` value **)**
- :ref:`float<class_float>` **get_ssr_fade_in** **(** **)**
The fade-in distance for screen-space reflections. Affects the area from the reflected material to the screen-space reflection). Only positive values are valid (negative values will be clamped to ``0.0``).
The fade-in distance for screen-space reflections. Affects the area from the reflected material to the screen-space reflection. Only positive values are valid (negative values will be clamped to ``0.0``).
.. rst-class:: classref-item-separator

View File

@@ -70,6 +70,13 @@ In the following example we use a :ref:`LineEdit<class_LineEdit>` node to write
.. rst-class:: classref-introduction-group
Tutorials
---------
- :doc:`Evaluating Expressions <../tutorials/scripting/evaluating_expressions>`
.. rst-class:: classref-reftable-group
Methods

View File

@@ -115,14 +115,14 @@ Methods
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`flush<class_FileAccess_method_flush>` **(** **)** |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_8<class_FileAccess_method_get_8>` **(** **)** |const| |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_16<class_FileAccess_method_get_16>` **(** **)** |const| |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_32<class_FileAccess_method_get_32>` **(** **)** |const| |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_64<class_FileAccess_method_get_64>` **(** **)** |const| |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_8<class_FileAccess_method_get_8>` **(** **)** |const| |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_as_text<class_FileAccess_method_get_as_text>` **(** :ref:`bool<class_bool>` skip_cr=false **)** |const| |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`PackedByteArray<class_PackedByteArray>` | :ref:`get_buffer<class_FileAccess_method_get_buffer>` **(** :ref:`int<class_int>` length **)** |const| |
@@ -177,14 +177,14 @@ Methods
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`seek_end<class_FileAccess_method_seek_end>` **(** :ref:`int<class_int>` position=0 **)** |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`store_8<class_FileAccess_method_store_8>` **(** :ref:`int<class_int>` value **)** |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`store_16<class_FileAccess_method_store_16>` **(** :ref:`int<class_int>` value **)** |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`store_32<class_FileAccess_method_store_32>` **(** :ref:`int<class_int>` value **)** |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`store_64<class_FileAccess_method_store_64>` **(** :ref:`int<class_int>` value **)** |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`store_8<class_FileAccess_method_store_8>` **(** :ref:`int<class_int>` value **)** |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`store_buffer<class_FileAccess_method_store_buffer>` **(** :ref:`PackedByteArray<class_PackedByteArray>` buffer **)** |
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`store_csv_line<class_FileAccess_method_store_csv_line>` **(** :ref:`PackedStringArray<class_PackedStringArray>` values, :ref:`String<class_String>` delim="," **)** |
@@ -293,6 +293,14 @@ Uses the `Zstandard <https://facebook.github.io/zstd/>`__ compression method.
Uses the `gzip <https://www.gzip.org/>`__ compression method.
.. _class_FileAccess_constant_COMPRESSION_BROTLI:
.. rst-class:: classref-enumeration-constant
:ref:`CompressionMode<enum_FileAccess_CompressionMode>` **COMPRESSION_BROTLI** = ``4``
Uses the `brotli <https://github.com/google/brotli>`__ compression method (only decompression is supported).
.. rst-class:: classref-section-separator
----
@@ -403,6 +411,18 @@ Writes the file's buffer to disk. Flushing is automatically performed when the f
----
.. _class_FileAccess_method_get_8:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_8** **(** **)** |const|
Returns the next 8 bits from the file as an integer. See :ref:`store_8<class_FileAccess_method_store_8>` for details on what values can be stored and retrieved this way.
.. rst-class:: classref-item-separator
----
.. _class_FileAccess_method_get_16:
.. rst-class:: classref-method
@@ -439,18 +459,6 @@ Returns the next 64 bits from the file as an integer. See :ref:`store_64<class_F
----
.. _class_FileAccess_method_get_8:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_8** **(** **)** |const|
Returns the next 8 bits from the file as an integer. See :ref:`store_8<class_FileAccess_method_store_8>` for details on what values can be stored and retrieved this way.
.. rst-class:: classref-item-separator
----
.. _class_FileAccess_method_get_as_text:
.. rst-class:: classref-method
@@ -811,6 +819,22 @@ Changes the file reading/writing cursor to the specified position (in bytes from
----
.. _class_FileAccess_method_store_8:
.. rst-class:: classref-method
void **store_8** **(** :ref:`int<class_int>` value **)**
Stores an integer as 8 bits in the file.
\ **Note:** The ``value`` should lie in the interval ``[0, 255]``. Any other value will overflow and wrap around.
To store a signed integer, use :ref:`store_64<class_FileAccess_method_store_64>`, or convert it manually (see :ref:`store_16<class_FileAccess_method_store_16>` for an example).
.. rst-class:: classref-item-separator
----
.. _class_FileAccess_method_store_16:
.. rst-class:: classref-method
@@ -894,22 +918,6 @@ Stores an integer as 64 bits in the file.
----
.. _class_FileAccess_method_store_8:
.. rst-class:: classref-method
void **store_8** **(** :ref:`int<class_int>` value **)**
Stores an integer as 8 bits in the file.
\ **Note:** The ``value`` should lie in the interval ``[0, 255]``. Any other value will overflow and wrap around.
To store a signed integer, use :ref:`store_64<class_FileAccess_method_store_64>`, or convert it manually (see :ref:`store_16<class_FileAccess_method_store_16>` for an example).
.. rst-class:: classref-item-separator
----
.. _class_FileAccess_method_store_buffer:
.. rst-class:: classref-method

View File

@@ -255,7 +255,7 @@ Property Descriptions
- void **set_access** **(** :ref:`Access<enum_FileDialog_Access>` value **)**
- :ref:`Access<enum_FileDialog_Access>` **get_access** **(** **)**
The file system access scope. See enum ``Access`` constants.
The file system access scope. See :ref:`Access<enum_FileDialog_Access>` constants.
\ **Warning:** Currently, in sandboxed environments such as Web builds or sandboxed macOS apps, FileDialog cannot access the host file system. See `godot-proposals#1123 <https://github.com/godotengine/godot-proposals/issues/1123>`__.
@@ -359,7 +359,7 @@ The available file type filters. For example, this shows only ``.png`` and ``.gd
- void **set_mode_overrides_title** **(** :ref:`bool<class_bool>` value **)**
- :ref:`bool<class_bool>` **is_mode_overriding_title** **(** **)**
If ``true``, changing the ``Mode`` property will set the window title accordingly (e.g. setting mode to :ref:`FILE_MODE_OPEN_FILE<class_FileDialog_constant_FILE_MODE_OPEN_FILE>` will change the window title to "Open a File").
If ``true``, changing the :ref:`file_mode<class_FileDialog_property_file_mode>` property will set the window title accordingly (e.g. setting :ref:`file_mode<class_FileDialog_property_file_mode>` to :ref:`FILE_MODE_OPEN_FILE<class_FileDialog_constant_FILE_MODE_OPEN_FILE>` will change the window title to "Open a File").
.. rst-class:: classref-item-separator

View File

@@ -12,9 +12,16 @@ FileSystemDock
**Inherits:** :ref:`VBoxContainer<class_VBoxContainer>` **<** :ref:`BoxContainer<class_BoxContainer>` **<** :ref:`Container<class_Container>` **<** :ref:`Control<class_Control>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
.. container:: contribute
Editor dock for managing files in the project.
There is currently no description for this class. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-introduction-group
Description
-----------
This class is available only in :ref:`EditorPlugin<class_EditorPlugin>`\ s and can't be instantiated. You can access it using :ref:`EditorInterface.get_file_system_dock<class_EditorInterface_method_get_file_system_dock>`.
While FileSystemDock doesn't expose any methods for file manipulation, you can listen for various file-related signals.
.. rst-class:: classref-reftable-group
@@ -24,9 +31,13 @@ Methods
.. table::
:widths: auto
+------+--------------------------------------------------------------------------------------------------------------------+
| void | :ref:`navigate_to_path<class_FileSystemDock_method_navigate_to_path>` **(** :ref:`String<class_String>` path **)** |
+------+--------------------------------------------------------------------------------------------------------------------+
+------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`add_resource_tooltip_plugin<class_FileSystemDock_method_add_resource_tooltip_plugin>` **(** :ref:`EditorResourceTooltipPlugin<class_EditorResourceTooltipPlugin>` plugin **)** |
+------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`navigate_to_path<class_FileSystemDock_method_navigate_to_path>` **(** :ref:`String<class_String>` path **)** |
+------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| void | :ref:`remove_resource_tooltip_plugin<class_FileSystemDock_method_remove_resource_tooltip_plugin>` **(** :ref:`EditorResourceTooltipPlugin<class_EditorResourceTooltipPlugin>` plugin **)** |
+------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
@@ -43,9 +54,7 @@ Signals
**display_mode_changed** **(** **)**
.. container:: contribute
There is currently no description for this signal. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
Emitted when the user switches file display mode or split mode.
.. rst-class:: classref-item-separator
@@ -57,9 +66,7 @@ Signals
**file_removed** **(** :ref:`String<class_String>` file **)**
.. container:: contribute
There is currently no description for this signal. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
Emitted when the given ``file`` was removed.
.. rst-class:: classref-item-separator
@@ -71,9 +78,7 @@ Signals
**files_moved** **(** :ref:`String<class_String>` old_file, :ref:`String<class_String>` new_file **)**
.. container:: contribute
There is currently no description for this signal. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
Emitted when a file is moved from ``old_file`` path to ``new_file`` path.
.. rst-class:: classref-item-separator
@@ -85,9 +90,7 @@ Signals
**folder_moved** **(** :ref:`String<class_String>` old_folder, :ref:`String<class_String>` new_folder **)**
.. container:: contribute
There is currently no description for this signal. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
Emitted when a folder is moved from ``old_folder`` path to ``new_folder`` path.
.. rst-class:: classref-item-separator
@@ -99,9 +102,7 @@ Signals
**folder_removed** **(** :ref:`String<class_String>` folder **)**
.. container:: contribute
There is currently no description for this signal. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
Emitted when the given ``folder`` was removed.
.. rst-class:: classref-item-separator
@@ -113,9 +114,7 @@ Signals
**inherit** **(** :ref:`String<class_String>` file **)**
.. container:: contribute
There is currently no description for this signal. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
Emitted when a new scene is created that inherits the scene at ``file`` path.
.. rst-class:: classref-item-separator
@@ -127,9 +126,7 @@ Signals
**instantiate** **(** :ref:`PackedStringArray<class_PackedStringArray>` files **)**
.. container:: contribute
There is currently no description for this signal. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
Emitted when the given scenes are being instantiated in the editor.
.. rst-class:: classref-item-separator
@@ -141,9 +138,7 @@ Signals
**resource_removed** **(** :ref:`Resource<class_Resource>` resource **)**
.. container:: contribute
There is currently no description for this signal. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
Emitted when an external ``resource`` had its file removed.
.. rst-class:: classref-section-separator
@@ -154,15 +149,37 @@ Signals
Method Descriptions
-------------------
.. _class_FileSystemDock_method_add_resource_tooltip_plugin:
.. rst-class:: classref-method
void **add_resource_tooltip_plugin** **(** :ref:`EditorResourceTooltipPlugin<class_EditorResourceTooltipPlugin>` plugin **)**
Registers a new :ref:`EditorResourceTooltipPlugin<class_EditorResourceTooltipPlugin>`.
.. rst-class:: classref-item-separator
----
.. _class_FileSystemDock_method_navigate_to_path:
.. rst-class:: classref-method
void **navigate_to_path** **(** :ref:`String<class_String>` path **)**
.. container:: contribute
Sets the given ``path`` as currently selected, ensuring that the selected file/directory is visible.
There is currently no description for this method. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
.. rst-class:: classref-item-separator
----
.. _class_FileSystemDock_method_remove_resource_tooltip_plugin:
.. rst-class:: classref-method
void **remove_resource_tooltip_plugin** **(** :ref:`EditorResourceTooltipPlugin<class_EditorResourceTooltipPlugin>` plugin **)**
Removes an :ref:`EditorResourceTooltipPlugin<class_EditorResourceTooltipPlugin>`. Fails if the plugin wasn't previously added.
.. |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.)`

View File

@@ -462,6 +462,20 @@ Returns list of supported `variation coordinates <https://docs.microsoft.com/en-
Font variations allow for continuous change of glyph characteristics along some given design axis, such as weight, width or slant.
To print available variation axes of a variable font:
::
var fv = FontVariation.new()
fv.set_base_font = load("res://RobotoFlex.ttf")
var variation_list = fv.get_supported_variation_list()
for tag in variation_list:
var name = TextServerManager.get_primary_interface().tag_to_name(tag)
var values = variation_list[tag]
print("variation axis: %s (%d)\n\tmin, max, default: %s" % [name, tag, values])
\ **Note:** To set and get variation coordinates of a :ref:`FontVariation<class_FontVariation>`, use :ref:`FontVariation.variation_opentype<class_FontVariation_property_variation_opentype>`.
.. rst-class:: classref-item-separator
----

Some files were not shown because too many files have changed in this diff Show More