Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

classref: Sync with current master branch (dc5f1b7) #10405

Merged
merged 1 commit into from
Dec 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 43 additions & 1 deletion classes/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -787,7 +787,7 @@ Add a custom icon to the current script. The icon specified at ``icon_path`` is

\ **Note:** As annotations describe their subject, the :ref:`@icon<class_@GDScript_annotation_@icon>` annotation must be placed before the class definition and inheritance.

\ **Note:** Unlike other annotations, the argument of the :ref:`@icon<class_@GDScript_annotation_@icon>` annotation must be a string literal (constant expressions are not supported).
\ **Note:** Unlike most other annotations, the argument of the :ref:`@icon<class_@GDScript_annotation_@icon>` annotation must be a string literal (constant expressions are not supported).

.. rst-class:: classref-item-separator

Expand Down Expand Up @@ -893,6 +893,48 @@ Mark the following statement to ignore the specified ``warning``. See :doc:`GDSc
@warning_ignore("unreachable_code")
print("unreachable")

See also :ref:`@warning_ignore_start<class_@GDScript_annotation_@warning_ignore_start>` and :ref:`@warning_ignore_restore<class_@GDScript_annotation_@warning_ignore_restore>`.

.. rst-class:: classref-item-separator

----

.. _class_@GDScript_annotation_@warning_ignore_restore:

.. rst-class:: classref-annotation

**@warning_ignore_restore**\ (\ warning\: :ref:`String<class_String>`, ...\ ) |vararg| :ref:`🔗<class_@GDScript_annotation_@warning_ignore_restore>`

Stops ignoring the listed warning types after :ref:`@warning_ignore_start<class_@GDScript_annotation_@warning_ignore_start>`. Ignoring the specified warning types will be reset to Project Settings. This annotation can be omitted to ignore the warning types until the end of the file.

\ **Note:** Unlike most other annotations, arguments of the :ref:`@warning_ignore_restore<class_@GDScript_annotation_@warning_ignore_restore>` annotation must be string literals (constant expressions are not supported).

.. rst-class:: classref-item-separator

----

.. _class_@GDScript_annotation_@warning_ignore_start:

.. rst-class:: classref-annotation

**@warning_ignore_start**\ (\ warning\: :ref:`String<class_String>`, ...\ ) |vararg| :ref:`🔗<class_@GDScript_annotation_@warning_ignore_start>`

Starts ignoring the listed warning types until the end of the file or the :ref:`@warning_ignore_restore<class_@GDScript_annotation_@warning_ignore_restore>` annotation with the given warning type.

::

func test():
var a = 1 # Warning (if enabled in the Project Settings).
@warning_ignore_start("unused_variable")
var b = 2 # No warning.
var c = 3 # No warning.
@warning_ignore_restore("unused_variable")
var d = 4 # Warning (if enabled in the Project Settings).

\ **Note:** To suppress a single warning, use :ref:`@warning_ignore<class_@GDScript_annotation_@warning_ignore>` instead.

\ **Note:** Unlike most other annotations, arguments of the :ref:`@warning_ignore_start<class_@GDScript_annotation_@warning_ignore_start>` annotation must be string literals (constant expressions are not supported).

.. rst-class:: classref-section-separator

----
Expand Down
2 changes: 0 additions & 2 deletions classes/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -6473,8 +6473,6 @@ Converts one or more arguments of any type to string in the best way possible an

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 a 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.
Expand Down
36 changes: 18 additions & 18 deletions classes/class_aabb.rst
Original file line number Diff line number Diff line change
Expand Up @@ -252,8 +252,8 @@ Returns an **AABB** equivalent to this bounding box, with its width, height, and

var box = AABB(Vector3(5, 0, 5), Vector3(-20, -10, -5))
var absolute = box.abs()
print(absolute.position) # Prints (-15, -10, 0)
print(absolute.size) # Prints (20, 10, 5)
print(absolute.position) # Prints (-15.0, -10.0, 0.0)
print(absolute.size) # Prints (20.0, 10.0, 5.0)

.. code-tab:: csharp

Expand Down Expand Up @@ -323,12 +323,12 @@ Returns a copy of this bounding box expanded to align the edges with the given `
var box = AABB(Vector3(0, 0, 0), Vector3(5, 2, 5))

box = box.expand(Vector3(10, 0, 0))
print(box.position) # Prints (0, 0, 0)
print(box.size) # Prints (10, 2, 5)
print(box.position) # Prints (0.0, 0.0, 0.0)
print(box.size) # Prints (10.0, 2.0, 5.0)

box = box.expand(Vector3(-5, 0, 5))
print(box.position) # Prints (-5, 0, 0)
print(box.size) # Prints (15, 2, 5)
print(box.position) # Prints (-5.0, 0.0, 0.0)
print(box.size) # Prints (15.0, 2.0, 5.0)

.. code-tab:: csharp

Expand Down Expand Up @@ -387,16 +387,16 @@ Returns the longest normalized axis of this bounding box's :ref:`size<class_AABB

var box = AABB(Vector3(0, 0, 0), Vector3(2, 4, 8))

print(box.get_longest_axis()) # Prints (0, 0, 1)
print(box.get_longest_axis()) # Prints (0.0, 0.0, 1.0)
print(box.get_longest_axis_index()) # Prints 2
print(box.get_longest_axis_size()) # Prints 8
print(box.get_longest_axis_size()) # Prints 8.0

.. code-tab:: csharp

var box = new Aabb(new Vector3(0, 0, 0), new Vector3(2, 4, 8));

GD.Print(box.GetLongestAxis()); // Prints (0, 0, 1)
GD.Print(box.GetLongestAxisIndex()); // Prints 2
GD.Print(box.GetLongestAxisIndex()); // Prints Z
GD.Print(box.GetLongestAxisSize()); // Prints 8


Expand Down Expand Up @@ -450,16 +450,16 @@ Returns the shortest normalized axis of this bounding box's :ref:`size<class_AAB

var box = AABB(Vector3(0, 0, 0), Vector3(2, 4, 8))

print(box.get_shortest_axis()) # Prints (1, 0, 0)
print(box.get_shortest_axis()) # Prints (1.0, 0.0, 0.0)
print(box.get_shortest_axis_index()) # Prints 0
print(box.get_shortest_axis_size()) # Prints 2
print(box.get_shortest_axis_size()) # Prints 2.0

.. code-tab:: csharp

var box = new Aabb(new Vector3(0, 0, 0), new Vector3(2, 4, 8));

GD.Print(box.GetShortestAxis()); // Prints (1, 0, 0)
GD.Print(box.GetShortestAxisIndex()); // Prints 0
GD.Print(box.GetShortestAxisIndex()); // Prints X
GD.Print(box.GetShortestAxisSize()); // Prints 2


Expand Down Expand Up @@ -536,12 +536,12 @@ Returns a copy of this bounding box extended on all sides by the given amount ``
.. code-tab:: gdscript

var a = AABB(Vector3(4, 4, 4), Vector3(8, 8, 8)).grow(4)
print(a.position) # Prints (0, 0, 0)
print(a.size) # Prints (16, 16, 16)
print(a.position) # Prints (0.0, 0.0, 0.0)
print(a.size) # Prints (16.0, 16.0, 16.0)

var b = AABB(Vector3(0, 0, 0), Vector3(8, 4, 2)).grow(2)
print(b.position) # Prints (-2, -2, -2)
print(b.size) # Prints (12, 8, 6)
print(b.position) # Prints (-2.0, -2.0, -2.0)
print(b.size) # Prints (12.0, 8.0, 6.0)

.. code-tab:: csharp

Expand Down Expand Up @@ -614,8 +614,8 @@ Returns the intersection between this bounding box and ``with``. If the boxes do
var box2 = AABB(Vector3(2, 0, 2), Vector3(8, 4, 4))

var intersection = box1.intersection(box2)
print(intersection.position) # Prints (2, 0, 2)
print(intersection.size) # Prints (3, 2, 4)
print(intersection.position) # Prints (2.0, 0.0, 2.0)
print(intersection.size) # Prints (3.0, 2.0, 4.0)

.. code-tab:: csharp

Expand Down
32 changes: 31 additions & 1 deletion classes/class_animationnode.rst
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,12 @@ Methods
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Variant<class_Variant>` | :ref:`get_parameter<class_AnimationNode_method_get_parameter>`\ (\ name\: :ref:`StringName<class_StringName>`\ ) |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_processing_animation_tree_instance_id<class_AnimationNode_method_get_processing_animation_tree_instance_id>`\ (\ ) |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`is_path_filtered<class_AnimationNode_method_is_path_filtered>`\ (\ path\: :ref:`NodePath<class_NodePath>`\ ) |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`is_process_testing<class_AnimationNode_method_is_process_testing>`\ (\ ) |const| |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_input<class_AnimationNode_method_remove_input>`\ (\ index\: :ref:`int<class_int>`\ ) |
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_filter_path<class_AnimationNode_method_set_filter_path>`\ (\ path\: :ref:`NodePath<class_NodePath>`, enable\: :ref:`bool<class_bool>`\ ) |
Expand Down Expand Up @@ -425,13 +429,39 @@ Gets the value of a parameter. Parameters are custom local memory used for your

----

.. _class_AnimationNode_method_get_processing_animation_tree_instance_id:

.. rst-class:: classref-method

:ref:`int<class_int>` **get_processing_animation_tree_instance_id**\ (\ ) |const| :ref:`🔗<class_AnimationNode_method_get_processing_animation_tree_instance_id>`

Returns the object id of the :ref:`AnimationTree<class_AnimationTree>` that owns this node.

\ **Note:** This method should only be called from within the :ref:`AnimationNodeExtension._process<class_AnimationNodeExtension_private_method__process>` method, and will return an invalid id otherwise.

.. rst-class:: classref-item-separator

----

.. _class_AnimationNode_method_is_path_filtered:

.. rst-class:: classref-method

:ref:`bool<class_bool>` **is_path_filtered**\ (\ path\: :ref:`NodePath<class_NodePath>`\ ) |const| :ref:`🔗<class_AnimationNode_method_is_path_filtered>`

Returns whether the given path is filtered.
Returns ``true`` if the given path is filtered.

.. rst-class:: classref-item-separator

----

.. _class_AnimationNode_method_is_process_testing:

.. rst-class:: classref-method

:ref:`bool<class_bool>` **is_process_testing**\ (\ ) |const| :ref:`🔗<class_AnimationNode_method_is_process_testing>`

Returns ``true`` if this animation node is being processed in test-only mode.

.. rst-class:: classref-item-separator

Expand Down
Loading