mirror of
https://github.com/godotengine/godot-docs-l10n.git
synced 2025-12-31 09:49:22 +03:00
Sync class reference translations with upstream 4.x
Removes es which has too low completion ratio for now. Syncs zh_CN which is 100% complete.
This commit is contained in:
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,341 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AABB.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AABB:
|
||||
|
||||
AABB
|
||||
====
|
||||
|
||||
Caja bordeada alineada con el eje.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
``AABB`` consists of a position, a size, and several utility functions. It is typically used for fast overlap tests.
|
||||
|
||||
It uses floating-point coordinates. The 2D counterpart to ``AABB`` is :ref:`Rect2<class_Rect2>`.
|
||||
|
||||
Negative values for :ref:`size<class_AABB_property_size>` are not supported and will not work for most methods. Use :ref:`abs<class_AABB_method_abs>` to get an AABB with a positive size.
|
||||
|
||||
\ **Note:** Unlike :ref:`Rect2<class_Rect2>`, ``AABB`` does not have a variant that uses integer coordinates.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Math tutorial index <../tutorials/math/index>`
|
||||
|
||||
- :doc:`Vector math <../tutorials/math/vector_math>`
|
||||
|
||||
- :doc:`Advanced vector math <../tutorials/math/vectors_advanced>`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------------+-----------------------------------------------+------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`end<class_AABB_property_end>` | ``Vector3( 0, 0, 0 )`` |
|
||||
+-------------------------------+-----------------------------------------------+------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`position<class_AABB_property_position>` | ``Vector3( 0, 0, 0 )`` |
|
||||
+-------------------------------+-----------------------------------------------+------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`size<class_AABB_property_size>` | ``Vector3( 0, 0, 0 )`` |
|
||||
+-------------------------------+-----------------------------------------------+------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AABB<class_AABB>` | :ref:`AABB<class_AABB_method_AABB>` **(** :ref:`Vector3<class_Vector3>` position, :ref:`Vector3<class_Vector3>` size **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AABB<class_AABB>` | :ref:`abs<class_AABB_method_abs>` **(** **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`encloses<class_AABB_method_encloses>` **(** :ref:`AABB<class_AABB>` with **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AABB<class_AABB>` | :ref:`expand<class_AABB_method_expand>` **(** :ref:`Vector3<class_Vector3>` to_point **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_area<class_AABB_method_get_area>` **(** **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`get_center<class_AABB_method_get_center>` **(** **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`get_endpoint<class_AABB_method_get_endpoint>` **(** :ref:`int<class_int>` idx **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`get_longest_axis<class_AABB_method_get_longest_axis>` **(** **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_longest_axis_index<class_AABB_method_get_longest_axis_index>` **(** **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_longest_axis_size<class_AABB_method_get_longest_axis_size>` **(** **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`get_shortest_axis<class_AABB_method_get_shortest_axis>` **(** **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_shortest_axis_index<class_AABB_method_get_shortest_axis_index>` **(** **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_shortest_axis_size<class_AABB_method_get_shortest_axis_size>` **(** **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`get_support<class_AABB_method_get_support>` **(** :ref:`Vector3<class_Vector3>` dir **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AABB<class_AABB>` | :ref:`grow<class_AABB_method_grow>` **(** :ref:`float<class_float>` by **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`has_no_area<class_AABB_method_has_no_area>` **(** **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`has_no_surface<class_AABB_method_has_no_surface>` **(** **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`has_point<class_AABB_method_has_point>` **(** :ref:`Vector3<class_Vector3>` point **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AABB<class_AABB>` | :ref:`intersection<class_AABB_method_intersection>` **(** :ref:`AABB<class_AABB>` with **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`intersects<class_AABB_method_intersects>` **(** :ref:`AABB<class_AABB>` with **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`intersects_plane<class_AABB_method_intersects_plane>` **(** :ref:`Plane<class_Plane>` plane **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`intersects_segment<class_AABB_method_intersects_segment>` **(** :ref:`Vector3<class_Vector3>` from, :ref:`Vector3<class_Vector3>` to **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_equal_approx<class_AABB_method_is_equal_approx>` **(** :ref:`AABB<class_AABB>` aabb **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AABB<class_AABB>` | :ref:`merge<class_AABB_method_merge>` **(** :ref:`AABB<class_AABB>` with **)** |
|
||||
+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AABB_property_end:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **end**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``Vector3( 0, 0, 0 )`` |
|
||||
+-----------+------------------------+
|
||||
|
||||
Esquina final. Esto se calcula como ``position + size``. Cambiar esta propiedad cambia el tamaño.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_property_position:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **position**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``Vector3( 0, 0, 0 )`` |
|
||||
+-----------+------------------------+
|
||||
|
||||
Esquina de inicio. Normalmente tiene valores inferiores a :ref:`end<class_AABB_property_end>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_property_size:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **size**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``Vector3( 0, 0, 0 )`` |
|
||||
+-----------+------------------------+
|
||||
|
||||
Size from :ref:`position<class_AABB_property_position>` to :ref:`end<class_AABB_property_end>`. Typically, all components are positive.
|
||||
|
||||
If the size is negative, you can use :ref:`abs<class_AABB_method_abs>` to fix it.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AABB_method_AABB:
|
||||
|
||||
- :ref:`AABB<class_AABB>` **AABB** **(** :ref:`Vector3<class_Vector3>` position, :ref:`Vector3<class_Vector3>` size **)**
|
||||
|
||||
Construye un ``AABB`` a partir de una posición y un tamaño.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_abs:
|
||||
|
||||
- :ref:`AABB<class_AABB>` **abs** **(** **)**
|
||||
|
||||
Devuelve un AABB con posición y tamaño equivalentes, modificado para que la esquina más negativa sea el origen y el tamaño sea positivo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_encloses:
|
||||
|
||||
- :ref:`bool<class_bool>` **encloses** **(** :ref:`AABB<class_AABB>` with **)**
|
||||
|
||||
Devuelve ``true`` si este ``AABB`` contiene completamente a otro.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_expand:
|
||||
|
||||
- :ref:`AABB<class_AABB>` **expand** **(** :ref:`Vector3<class_Vector3>` to_point **)**
|
||||
|
||||
Returns a copy of this ``AABB`` expanded to include a given point.
|
||||
|
||||
\ **Example:**\
|
||||
|
||||
::
|
||||
|
||||
# position (-3, 2, 0), size (1, 1, 1)
|
||||
var box = AABB(Vector3(-3, 2, 0), Vector3(1, 1, 1))
|
||||
# position (-3, -1, 0), size (3, 4, 2), so we fit both the original AABB and Vector3(0, -1, 2)
|
||||
var box2 = box.expand(Vector3(0, -1, 2))
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_get_area:
|
||||
|
||||
- :ref:`float<class_float>` **get_area** **(** **)**
|
||||
|
||||
Devuelve el volumen del ``AABB``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_get_center:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **get_center** **(** **)**
|
||||
|
||||
Returns the center of the ``AABB``, which is equal to :ref:`position<class_AABB_property_position>` + (:ref:`size<class_AABB_property_size>` / 2).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_get_endpoint:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **get_endpoint** **(** :ref:`int<class_int>` idx **)**
|
||||
|
||||
Obtiene la posición de los 8 puntos finales del ``AABB`` en el espacio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_get_longest_axis:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **get_longest_axis** **(** **)**
|
||||
|
||||
Devuelve el eje más largo normalizado del ``AABB``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_get_longest_axis_index:
|
||||
|
||||
- :ref:`int<class_int>` **get_longest_axis_index** **(** **)**
|
||||
|
||||
Devuelve el indice del eje mas grande de ``AABB`` (segun la constante :ref:`Vector3<class_Vector3>` ``AXIS_*``).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_get_longest_axis_size:
|
||||
|
||||
- :ref:`float<class_float>` **get_longest_axis_size** **(** **)**
|
||||
|
||||
Devuelve la longitud escalar del eje más largo del ``AABB``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_get_shortest_axis:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **get_shortest_axis** **(** **)**
|
||||
|
||||
Devuelve el eje más corto normalizado de la ``AABB``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_get_shortest_axis_index:
|
||||
|
||||
- :ref:`int<class_int>` **get_shortest_axis_index** **(** **)**
|
||||
|
||||
Devuelve el índice del eje más corto del ``AABB`` (según el enumerado :ref:`Vector3<class_Vector3>`::AXIS\* ).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_get_shortest_axis_size:
|
||||
|
||||
- :ref:`float<class_float>` **get_shortest_axis_size** **(** **)**
|
||||
|
||||
Devuelve la longitud escalar del eje más corto del ``AABB``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_get_support:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **get_support** **(** :ref:`Vector3<class_Vector3>` dir **)**
|
||||
|
||||
Devuelve el punto de apoyo en una dirección determinada. Esto es útil para los algoritmos de detección de colisiones.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_grow:
|
||||
|
||||
- :ref:`AABB<class_AABB>` **grow** **(** :ref:`float<class_float>` by **)**
|
||||
|
||||
Devuelve una copia de la ``AABB`` crecida una cantidad dada de unidades hacia todos los lados.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_has_no_area:
|
||||
|
||||
- :ref:`bool<class_bool>` **has_no_area** **(** **)**
|
||||
|
||||
Devuelve ``true`` si el ``AABB`` es plano o vacío.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_has_no_surface:
|
||||
|
||||
- :ref:`bool<class_bool>` **has_no_surface** **(** **)**
|
||||
|
||||
Devuelve ``true`` si el ``AABB`` está vacío.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_has_point:
|
||||
|
||||
- :ref:`bool<class_bool>` **has_point** **(** :ref:`Vector3<class_Vector3>` point **)**
|
||||
|
||||
Devuelve ``true`` si el ``AABB`` contiene un punto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_intersection:
|
||||
|
||||
- :ref:`AABB<class_AABB>` **intersection** **(** :ref:`AABB<class_AABB>` with **)**
|
||||
|
||||
Devuelve la intersección entre dos ``AABB``. Un AABB vacío (tamaño 0,0,0) se devuelve al fallar.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_intersects:
|
||||
|
||||
- :ref:`bool<class_bool>` **intersects** **(** :ref:`AABB<class_AABB>` with **)**
|
||||
|
||||
Devuelve ``true`` si el ``AABB`` se solapa con otro.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_intersects_plane:
|
||||
|
||||
- :ref:`bool<class_bool>` **intersects_plane** **(** :ref:`Plane<class_Plane>` plane **)**
|
||||
|
||||
Devuelve ``true`` si el ``AABB`` está a ambos lados de un plano.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_intersects_segment:
|
||||
|
||||
- :ref:`bool<class_bool>` **intersects_segment** **(** :ref:`Vector3<class_Vector3>` from, :ref:`Vector3<class_Vector3>` to **)**
|
||||
|
||||
Devuelve ``true`` si el ``AABB`` intersecta el segmento de línea entre ``from`` y ``to``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_is_equal_approx:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_equal_approx** **(** :ref:`AABB<class_AABB>` aabb **)**
|
||||
|
||||
Devuelve ``true`` si este ``AABB`` y ``aabb`` son aproximadamente iguales, llamando al :ref:`@GDScript.is_equal_approx<class_@GDScript_method_is_equal_approx>` en cada componente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AABB_method_merge:
|
||||
|
||||
- :ref:`AABB<class_AABB>` **merge** **(** :ref:`AABB<class_AABB>` with **)**
|
||||
|
||||
Devuelve un ``AABB`` más grande que contiene tanto este ``AABB`` como el ``with``.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,182 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AcceptDialog.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AcceptDialog:
|
||||
|
||||
AcceptDialog
|
||||
============
|
||||
|
||||
**Inherits:** :ref:`WindowDialog<class_WindowDialog>` **<** :ref:`Popup<class_Popup>` **<** :ref:`Control<class_Control>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`ConfirmationDialog<class_ConfirmationDialog>`
|
||||
|
||||
Diálogo base para la notificación al usuario.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Este cuadro de diálogo es útil para pequeñas notificaciones al usuario sobre un evento. Sólo puede ser aceptado o cerrado, devolviendo el mismo resultado.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------+-------------------------------------------------------------------------+----------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`dialog_autowrap<class_AcceptDialog_property_dialog_autowrap>` | ``false`` |
|
||||
+-----------------------------+-------------------------------------------------------------------------+----------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`dialog_hide_on_ok<class_AcceptDialog_property_dialog_hide_on_ok>` | ``true`` |
|
||||
+-----------------------------+-------------------------------------------------------------------------+----------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`dialog_text<class_AcceptDialog_property_dialog_text>` | ``""`` |
|
||||
+-----------------------------+-------------------------------------------------------------------------+----------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | window_title | ``"Alert!"`` (overrides :ref:`WindowDialog<class_WindowDialog_property_window_title>`) |
|
||||
+-----------------------------+-------------------------------------------------------------------------+----------------------------------------------------------------------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Button<class_Button>` | :ref:`add_button<class_AcceptDialog_method_add_button>` **(** :ref:`String<class_String>` text, :ref:`bool<class_bool>` right=false, :ref:`String<class_String>` action="" **)** |
|
||||
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Button<class_Button>` | :ref:`add_cancel<class_AcceptDialog_method_add_cancel>` **(** :ref:`String<class_String>` name **)** |
|
||||
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Label<class_Label>` | :ref:`get_label<class_AcceptDialog_method_get_label>` **(** **)** |
|
||||
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Button<class_Button>` | :ref:`get_ok<class_AcceptDialog_method_get_ok>` **(** **)** |
|
||||
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`register_text_enter<class_AcceptDialog_method_register_text_enter>` **(** :ref:`Node<class_Node>` line_edit **)** |
|
||||
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_button<class_AcceptDialog_method_remove_button>` **(** :ref:`Control<class_Control>` button **)** |
|
||||
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_AcceptDialog_signal_confirmed:
|
||||
|
||||
- **confirmed** **(** **)**
|
||||
|
||||
Se emite cuando se acepta el diálogo, es decir, se pulsa el botón OK.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AcceptDialog_signal_custom_action:
|
||||
|
||||
- **custom_action** **(** :ref:`String<class_String>` action **)**
|
||||
|
||||
Se emite cuando se presiona un botón personalizado. Ver :ref:`add_button<class_AcceptDialog_method_add_button>`.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AcceptDialog_property_dialog_autowrap:
|
||||
|
||||
- :ref:`bool<class_bool>` **dialog_autowrap**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_autowrap(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | has_autowrap() |
|
||||
+-----------+---------------------+
|
||||
|
||||
El texto se expande automáticamente en el diálogo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AcceptDialog_property_dialog_hide_on_ok:
|
||||
|
||||
- :ref:`bool<class_bool>` **dialog_hide_on_ok**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_hide_on_ok(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_hide_on_ok() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Si ``true``, el diálogo se oculta cuando se pulsa el botón OK. Puedes ajustarlo a ``false`` si quieres hacer, por ejemplo, la validación de entrada al recibir la señal :ref:`confirmed<class_AcceptDialog_signal_confirmed>`, y manejar el ocultamiento del diálogo en tu propia lógica.
|
||||
|
||||
\ **Nota:** Algunos nodos derivados de esta clase pueden tener un valor por defecto diferente, y potencialmente su propia lógica incorporada anulando este ajuste. Por ejemplo, :ref:`FileDialog<class_FileDialog>` tiene por defecto ``false``, y tiene su propio código de validación de entrada que se llama al pulsar OK, que eventualmente oculta el diálogo si la entrada es válida. Como tal, esta propiedad no puede ser usada en :ref:`FileDialog<class_FileDialog>` para deshabilitar la ocultación del diálogo cuando se presiona OK.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AcceptDialog_property_dialog_text:
|
||||
|
||||
- :ref:`String<class_String>` **dialog_text**
|
||||
|
||||
+-----------+-----------------+
|
||||
| *Default* | ``""`` |
|
||||
+-----------+-----------------+
|
||||
| *Setter* | set_text(value) |
|
||||
+-----------+-----------------+
|
||||
| *Getter* | get_text() |
|
||||
+-----------+-----------------+
|
||||
|
||||
El texto mostrado en el diálogo.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AcceptDialog_method_add_button:
|
||||
|
||||
- :ref:`Button<class_Button>` **add_button** **(** :ref:`String<class_String>` text, :ref:`bool<class_bool>` right=false, :ref:`String<class_String>` action="" **)**
|
||||
|
||||
Adds a button with label ``text`` and a custom ``action`` to the dialog and returns the created button. ``action`` will be passed to the :ref:`custom_action<class_AcceptDialog_signal_custom_action>` signal when pressed.
|
||||
|
||||
If ``true``, ``right`` will place the button to the right of any sibling buttons.
|
||||
|
||||
You can use :ref:`remove_button<class_AcceptDialog_method_remove_button>` method to remove a button created with this method from the dialog.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AcceptDialog_method_add_cancel:
|
||||
|
||||
- :ref:`Button<class_Button>` **add_cancel** **(** :ref:`String<class_String>` name **)**
|
||||
|
||||
Adds a button with label ``name`` and a cancel action to the dialog and returns the created button.
|
||||
|
||||
You can use :ref:`remove_button<class_AcceptDialog_method_remove_button>` method to remove a button created with this method from the dialog.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AcceptDialog_method_get_label:
|
||||
|
||||
- :ref:`Label<class_Label>` **get_label** **(** **)**
|
||||
|
||||
Returns the label used for built-in text.
|
||||
|
||||
\ **Warning:** This is a required internal node, removing and freeing it may cause a crash. If you wish to hide it or any of its children, use their :ref:`CanvasItem.visible<class_CanvasItem_property_visible>` property.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AcceptDialog_method_get_ok:
|
||||
|
||||
- :ref:`Button<class_Button>` **get_ok** **(** **)**
|
||||
|
||||
Retorna la instancia de el :ref:`Button<class_Button>` aceptar.
|
||||
|
||||
\ **Warning:** Esto es un nodo interno requerido, removerlo y liberarlo podría causar un crasheo. Si deseas esconder este o alguno de sus hijos, utiliza su propiedad :ref:`CanvasItem.visible<class_CanvasItem_property_visible>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AcceptDialog_method_register_text_enter:
|
||||
|
||||
- void **register_text_enter** **(** :ref:`Node<class_Node>` line_edit **)**
|
||||
|
||||
Registra un :ref:`LineEdit<class_LineEdit>` en el diálogo. Cuando se pulsa la tecla intro, el diálogo se acepta.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AcceptDialog_method_remove_button:
|
||||
|
||||
- void **remove_button** **(** :ref:`Control<class_Control>` button **)**
|
||||
|
||||
Removes the ``button`` from the dialog. Does NOT free the ``button``. The ``button`` must be a :ref:`Button<class_Button>` added with :ref:`add_button<class_AcceptDialog_method_add_button>` or :ref:`add_cancel<class_AcceptDialog_method_add_cancel>` method. After removal, pressing the ``button`` will no longer emit this dialog's :ref:`custom_action<class_AcceptDialog_signal_custom_action>` signal or cancel this dialog.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,132 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AESContext.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AESContext:
|
||||
|
||||
AESContext
|
||||
==========
|
||||
|
||||
**Inherits:** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Interfaz para las características de encriptación AES de bajo nivel.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Esta clase proporciona acceso a la encriptación/desencriptación AES de los datos en bruto. Tanto el modo AES-ECB como el AES-CBC están soportados.
|
||||
|
||||
::
|
||||
|
||||
extends Node
|
||||
|
||||
var aes = AESContext.new()
|
||||
|
||||
func _ready():
|
||||
var clave = "Mi clave secreta!!!" # La clave debe ser de 16 o 32 bytes. (1 byte = 1 char) normalmdlkd
|
||||
var datos = "Mi clave secreta" # El tamaño de datos debe ser multiplo de 16, ponga algún relleno para completar de ser necesario.
|
||||
# Encriptar ECB
|
||||
aes.start(AESContext.MODE_ECB_ENCRYPT, clave.to_utf8())
|
||||
var encriptado = aes.update(datos.to_utf8())
|
||||
aes.finish()
|
||||
# Desencriptar ECB
|
||||
aes.start(AESContext.MODE_ECB_DECRYPT, clave.to_utf8())
|
||||
var desencriptado = aes.update(encriptado)
|
||||
aes.finish()
|
||||
# Comprobar ECB
|
||||
assert(desencriptado == datos.to_utf8())
|
||||
|
||||
var iv = "Mi secreto iv!!!" # IV debe ser de tamaño 16 bytes.
|
||||
# Encriptar CBC
|
||||
aes.start(AESContext.MODE_CBC_ENCRYPT, clave.to_utf8(), iv.to_utf8())
|
||||
encriptado = aes.update(datos.to_utf8())
|
||||
aes.finish()
|
||||
# Desencriptar CBC
|
||||
aes.start(AESContext.MODE_CBC_DECRYPT, clave.to_utf8(), iv.to_utf8())
|
||||
desencriptado = aes.update(encriptado)
|
||||
aes.finish()
|
||||
# Comprobar CBC
|
||||
assert(desencriptado == datos.to_utf8())
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`finish<class_AESContext_method_finish>` **(** **)** |
|
||||
+-------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolByteArray<class_PoolByteArray>` | :ref:`get_iv_state<class_AESContext_method_get_iv_state>` **(** **)** |
|
||||
+-------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Error<enum_@GlobalScope_Error>` | :ref:`start<class_AESContext_method_start>` **(** :ref:`Mode<enum_AESContext_Mode>` mode, :ref:`PoolByteArray<class_PoolByteArray>` key, :ref:`PoolByteArray<class_PoolByteArray>` iv=PoolByteArray( ) **)** |
|
||||
+-------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolByteArray<class_PoolByteArray>` | :ref:`update<class_AESContext_method_update>` **(** :ref:`PoolByteArray<class_PoolByteArray>` src **)** |
|
||||
+-------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AESContext_Mode:
|
||||
|
||||
.. _class_AESContext_constant_MODE_ECB_ENCRYPT:
|
||||
|
||||
.. _class_AESContext_constant_MODE_ECB_DECRYPT:
|
||||
|
||||
.. _class_AESContext_constant_MODE_CBC_ENCRYPT:
|
||||
|
||||
.. _class_AESContext_constant_MODE_CBC_DECRYPT:
|
||||
|
||||
.. _class_AESContext_constant_MODE_MAX:
|
||||
|
||||
enum **Mode**:
|
||||
|
||||
- **MODE_ECB_ENCRYPT** = **0** --- Modo encripción AES electronic codebook(ECB).
|
||||
|
||||
- **MODE_ECB_DECRYPT** = **1** --- Modo desencripción AES electronic codebook(ECB).
|
||||
|
||||
- **MODE_CBC_ENCRYPT** = **2** --- Modo encripción AES cipher blocker chaining (CBC).
|
||||
|
||||
- **MODE_CBC_DECRYPT** = **3** --- Modo desencripción AES cipher blocker chaining (CBC).
|
||||
|
||||
- **MODE_MAX** = **4** --- Valor máximo para el modo enum.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AESContext_method_finish:
|
||||
|
||||
- void **finish** **(** **)**
|
||||
|
||||
Cerrar este contexto AES para que pueda ser iniciado de nuevo. Ver :ref:`start<class_AESContext_method_start>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AESContext_method_get_iv_state:
|
||||
|
||||
- :ref:`PoolByteArray<class_PoolByteArray>` **get_iv_state** **(** **)**
|
||||
|
||||
Get the current IV state for this context (IV gets updated when calling :ref:`update<class_AESContext_method_update>`). You normally don't need this function.
|
||||
|
||||
\ **Note:** This function only makes sense when the context is started with :ref:`MODE_CBC_ENCRYPT<class_AESContext_constant_MODE_CBC_ENCRYPT>` or :ref:`MODE_CBC_DECRYPT<class_AESContext_constant_MODE_CBC_DECRYPT>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AESContext_method_start:
|
||||
|
||||
- :ref:`Error<enum_@GlobalScope_Error>` **start** **(** :ref:`Mode<enum_AESContext_Mode>` mode, :ref:`PoolByteArray<class_PoolByteArray>` key, :ref:`PoolByteArray<class_PoolByteArray>` iv=PoolByteArray( ) **)**
|
||||
|
||||
Inicia el contexto AES en el ``mode``. Siempre debe proporcionarse un ``key`` de 16 o 32 bytes, mientras que un ``iv`` (vector de inicialización) de exactamente 16 bytes, sólo se necesitará cuando el ``mode`` es o bien :ref:`MODE_CBC_ENCRYPT<class_AESContext_constant_MODE_CBC_ENCRYPT>` o bien :ref:`MODE_CBC_DECRYPT<class_AESContext_constant_MODE_CBC_DECRYPT>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AESContext_method_update:
|
||||
|
||||
- :ref:`PoolByteArray<class_PoolByteArray>` **update** **(** :ref:`PoolByteArray<class_PoolByteArray>` src **)**
|
||||
|
||||
Run the desired operation for this AES context. Will return a :ref:`PoolByteArray<class_PoolByteArray>` containing the result of encrypting (or decrypting) the given ``src``. See :ref:`start<class_AESContext_method_start>` for mode of operation.
|
||||
|
||||
\ **Note:** The size of ``src`` must be a multiple of 16. Apply some padding if needed.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,241 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimatedSprite.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimatedSprite:
|
||||
|
||||
AnimatedSprite
|
||||
==============
|
||||
|
||||
**Inherits:** :ref:`Node2D<class_Node2D>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Nodo Sprite que puede usar múltiples texturas para la animación.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Animations are created using a :ref:`SpriteFrames<class_SpriteFrames>` resource, which can be configured in the editor via the SpriteFrames panel.
|
||||
|
||||
\ **Note:** You can associate a set of normal maps by creating additional :ref:`SpriteFrames<class_SpriteFrames>` resources with a ``_normal`` suffix. For example, having 2 :ref:`SpriteFrames<class_SpriteFrames>` resources ``run`` and ``run_normal`` will make it so the ``run`` animation uses the normal map.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`2D Sprite animation <../tutorials/2d/2d_sprite_animation>`
|
||||
|
||||
- `2D Dodge The Creeps Demo <https://godotengine.org/asset-library/asset/515>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------------------+---------------------------------------------------------------+---------------------+
|
||||
| :ref:`String<class_String>` | :ref:`animation<class_AnimatedSprite_property_animation>` | ``"default"`` |
|
||||
+-----------------------------------------+---------------------------------------------------------------+---------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`centered<class_AnimatedSprite_property_centered>` | ``true`` |
|
||||
+-----------------------------------------+---------------------------------------------------------------+---------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`flip_h<class_AnimatedSprite_property_flip_h>` | ``false`` |
|
||||
+-----------------------------------------+---------------------------------------------------------------+---------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`flip_v<class_AnimatedSprite_property_flip_v>` | ``false`` |
|
||||
+-----------------------------------------+---------------------------------------------------------------+---------------------+
|
||||
| :ref:`int<class_int>` | :ref:`frame<class_AnimatedSprite_property_frame>` | ``0`` |
|
||||
+-----------------------------------------+---------------------------------------------------------------+---------------------+
|
||||
| :ref:`SpriteFrames<class_SpriteFrames>` | :ref:`frames<class_AnimatedSprite_property_frames>` | |
|
||||
+-----------------------------------------+---------------------------------------------------------------+---------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`offset<class_AnimatedSprite_property_offset>` | ``Vector2( 0, 0 )`` |
|
||||
+-----------------------------------------+---------------------------------------------------------------+---------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`playing<class_AnimatedSprite_property_playing>` | ``false`` |
|
||||
+-----------------------------------------+---------------------------------------------------------------+---------------------+
|
||||
| :ref:`float<class_float>` | :ref:`speed_scale<class_AnimatedSprite_property_speed_scale>` | ``1.0`` |
|
||||
+-----------------------------------------+---------------------------------------------------------------+---------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+------+----------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`play<class_AnimatedSprite_method_play>` **(** :ref:`String<class_String>` anim="", :ref:`bool<class_bool>` backwards=false **)** |
|
||||
+------+----------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`stop<class_AnimatedSprite_method_stop>` **(** **)** |
|
||||
+------+----------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_AnimatedSprite_signal_animation_finished:
|
||||
|
||||
- **animation_finished** **(** **)**
|
||||
|
||||
Se emite cuando la animación termina (cuando reproduce el último fotograma). Si la animación está en bucle, esta señal se emite cada vez que se reproduce el último fotograma.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite_signal_frame_changed:
|
||||
|
||||
- **frame_changed** **(** **)**
|
||||
|
||||
Emitido cuando :ref:`frame<class_AnimatedSprite_property_frame>` cambió.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimatedSprite_property_animation:
|
||||
|
||||
- :ref:`String<class_String>` **animation**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``"default"`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_animation(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_animation() |
|
||||
+-----------+----------------------+
|
||||
|
||||
La animación actual del recurso ``frames``. Si este valor cambia, el contador ``frame`` se reinicia.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite_property_centered:
|
||||
|
||||
- :ref:`bool<class_bool>` **centered**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_centered(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | is_centered() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Si ``true``, la textura se centrará.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite_property_flip_h:
|
||||
|
||||
- :ref:`bool<class_bool>` **flip_h**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_flip_h(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | is_flipped_h() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Si ``true``, la textura se voltea horizontalmente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite_property_flip_v:
|
||||
|
||||
- :ref:`bool<class_bool>` **flip_v**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_flip_v(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | is_flipped_v() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Si ``true``, la textura se voltea verticalmente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite_property_frame:
|
||||
|
||||
- :ref:`int<class_int>` **frame**
|
||||
|
||||
+-----------+------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+------------------+
|
||||
| *Setter* | set_frame(value) |
|
||||
+-----------+------------------+
|
||||
| *Getter* | get_frame() |
|
||||
+-----------+------------------+
|
||||
|
||||
El índice del cuadro de animación mostrado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite_property_frames:
|
||||
|
||||
- :ref:`SpriteFrames<class_SpriteFrames>` **frames**
|
||||
|
||||
+----------+--------------------------+
|
||||
| *Setter* | set_sprite_frames(value) |
|
||||
+----------+--------------------------+
|
||||
| *Getter* | get_sprite_frames() |
|
||||
+----------+--------------------------+
|
||||
|
||||
El recurso :ref:`SpriteFrames<class_SpriteFrames>` que contiene la(s) animación(es).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite_property_offset:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **offset**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``Vector2( 0, 0 )`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_offset(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_offset() |
|
||||
+-----------+---------------------+
|
||||
|
||||
El desplazamiento al dibujar de la textura.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite_property_playing:
|
||||
|
||||
- :ref:`bool<class_bool>` **playing**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_playing(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | is_playing() |
|
||||
+-----------+--------------------+
|
||||
|
||||
Si ``true``, la :ref:`animation<class_AnimatedSprite_property_animation>` se está reproduciendo actualmente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite_property_speed_scale:
|
||||
|
||||
- :ref:`float<class_float>` **speed_scale**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_speed_scale(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_speed_scale() |
|
||||
+-----------+------------------------+
|
||||
|
||||
La velocidad de la animación se multiplica por este valor.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimatedSprite_method_play:
|
||||
|
||||
- void **play** **(** :ref:`String<class_String>` anim="", :ref:`bool<class_bool>` backwards=false **)**
|
||||
|
||||
Reproduce la animación llamada ``anim``. Si no se proporciona ``anim``, se reproduce la animación actual. Si ``backwards`` es ``true``, la animación se reproduce al revés.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite_method_stop:
|
||||
|
||||
- void **stop** **(** **)**
|
||||
|
||||
Detiene la animación actual (no reinicia el contador de fotogramas).
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,153 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimatedSprite3D.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimatedSprite3D:
|
||||
|
||||
AnimatedSprite3D
|
||||
================
|
||||
|
||||
**Inherits:** :ref:`SpriteBase3D<class_SpriteBase3D>` **<** :ref:`GeometryInstance<class_GeometryInstance>` **<** :ref:`VisualInstance<class_VisualInstance>` **<** :ref:`CullInstance<class_CullInstance>` **<** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Nodo de sprites 2D en el mundo 3D, que puede usar múltiples texturas 2D para la animación.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Las animaciones se crean usando un recurso :ref:`SpriteFrames<class_SpriteFrames>`, que puede ser configurado en el editor a través del panel de SpriteFrames.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`2D Sprite animation (also applies to 3D) <../tutorials/2d/2d_sprite_animation>`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------------------+-------------------------------------------------------------+---------------+
|
||||
| :ref:`String<class_String>` | :ref:`animation<class_AnimatedSprite3D_property_animation>` | ``"default"`` |
|
||||
+-----------------------------------------+-------------------------------------------------------------+---------------+
|
||||
| :ref:`int<class_int>` | :ref:`frame<class_AnimatedSprite3D_property_frame>` | ``0`` |
|
||||
+-----------------------------------------+-------------------------------------------------------------+---------------+
|
||||
| :ref:`SpriteFrames<class_SpriteFrames>` | :ref:`frames<class_AnimatedSprite3D_property_frames>` | |
|
||||
+-----------------------------------------+-------------------------------------------------------------+---------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`playing<class_AnimatedSprite3D_property_playing>` | ``false`` |
|
||||
+-----------------------------------------+-------------------------------------------------------------+---------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------+-------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_playing<class_AnimatedSprite3D_method_is_playing>` **(** **)** |const| |
|
||||
+-------------------------+-------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`play<class_AnimatedSprite3D_method_play>` **(** :ref:`String<class_String>` anim="" **)** |
|
||||
+-------------------------+-------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`stop<class_AnimatedSprite3D_method_stop>` **(** **)** |
|
||||
+-------------------------+-------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_AnimatedSprite3D_signal_animation_finished:
|
||||
|
||||
- **animation_finished** **(** **)**
|
||||
|
||||
Se emite cuando la animación termina (cuando reproduce el último fotograma). Si la animación está en bucle, esta señal se emite cada vez que se reproduce el último fotograma.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite3D_signal_frame_changed:
|
||||
|
||||
- **frame_changed** **(** **)**
|
||||
|
||||
Emitido cuando :ref:`frame<class_AnimatedSprite3D_property_frame>` cambió.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimatedSprite3D_property_animation:
|
||||
|
||||
- :ref:`String<class_String>` **animation**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``"default"`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_animation(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_animation() |
|
||||
+-----------+----------------------+
|
||||
|
||||
La animación actual del recurso ``frames``. Si este valor cambia, el contador ``frame`` se reinicia.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite3D_property_frame:
|
||||
|
||||
- :ref:`int<class_int>` **frame**
|
||||
|
||||
+-----------+------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+------------------+
|
||||
| *Setter* | set_frame(value) |
|
||||
+-----------+------------------+
|
||||
| *Getter* | get_frame() |
|
||||
+-----------+------------------+
|
||||
|
||||
El índice del cuadro de animación mostrado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite3D_property_frames:
|
||||
|
||||
- :ref:`SpriteFrames<class_SpriteFrames>` **frames**
|
||||
|
||||
+----------+--------------------------+
|
||||
| *Setter* | set_sprite_frames(value) |
|
||||
+----------+--------------------------+
|
||||
| *Getter* | get_sprite_frames() |
|
||||
+----------+--------------------------+
|
||||
|
||||
El recurso :ref:`SpriteFrames<class_SpriteFrames>` que contiene la(s) animación(es).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite3D_property_playing:
|
||||
|
||||
- :ref:`bool<class_bool>` **playing**
|
||||
|
||||
+-----------+-----------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-----------+
|
||||
|
||||
Si ``true``, la :ref:`animation<class_AnimatedSprite3D_property_animation>` se está reproduciendo actualmente.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimatedSprite3D_method_is_playing:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_playing** **(** **)** |const|
|
||||
|
||||
Devuelve ``true`` si se está reproduciendo una animación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite3D_method_play:
|
||||
|
||||
- void **play** **(** :ref:`String<class_String>` anim="" **)**
|
||||
|
||||
Reproduce la animación llamada ``anim``. Si no se proporciona ``anim``, se reproduce la animación actual.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedSprite3D_method_stop:
|
||||
|
||||
- void **stop** **(** **)**
|
||||
|
||||
Detiene la animación actual (no reinicia el contador de fotogramas).
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,191 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimatedTexture.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimatedTexture:
|
||||
|
||||
AnimatedTexture
|
||||
===============
|
||||
|
||||
**Inherits:** :ref:`Texture<class_Texture>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Textura de conexión para animaciones simples basadas en fotogramas.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
``AnimatedTexture`` is a resource format for frame-based animations, where multiple textures can be chained automatically with a predefined delay for each frame. Unlike :ref:`AnimationPlayer<class_AnimationPlayer>` or :ref:`AnimatedSprite<class_AnimatedSprite>`, it isn't a :ref:`Node<class_Node>`, but has the advantage of being usable anywhere a :ref:`Texture<class_Texture>` resource can be used, e.g. in a :ref:`TileSet<class_TileSet>`.
|
||||
|
||||
The playback of the animation is controlled by the :ref:`fps<class_AnimatedTexture_property_fps>` property as well as each frame's optional delay (see :ref:`set_frame_delay<class_AnimatedTexture_method_set_frame_delay>`). The animation loops, i.e. it will restart at frame 0 automatically after playing the last frame.
|
||||
|
||||
\ ``AnimatedTexture`` currently requires all frame textures to have the same size, otherwise the bigger ones will be cropped to match the smallest one.
|
||||
|
||||
\ **Note:** AnimatedTexture doesn't support using :ref:`AtlasTexture<class_AtlasTexture>`\ s. Each frame needs to be a separate :ref:`Texture<class_Texture>`.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+--------------------------------------------------------------------+----------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`current_frame<class_AnimatedTexture_property_current_frame>` | |
|
||||
+---------------------------+--------------------------------------------------------------------+----------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | flags | ``0`` (overrides :ref:`Texture<class_Texture_property_flags>`) |
|
||||
+---------------------------+--------------------------------------------------------------------+----------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`fps<class_AnimatedTexture_property_fps>` | ``4.0`` |
|
||||
+---------------------------+--------------------------------------------------------------------+----------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`frames<class_AnimatedTexture_property_frames>` | ``1`` |
|
||||
+---------------------------+--------------------------------------------------------------------+----------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`oneshot<class_AnimatedTexture_property_oneshot>` | ``false`` |
|
||||
+---------------------------+--------------------------------------------------------------------+----------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`pause<class_AnimatedTexture_property_pause>` | ``false`` |
|
||||
+---------------------------+--------------------------------------------------------------------+----------------------------------------------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_frame_delay<class_AnimatedTexture_method_get_frame_delay>` **(** :ref:`int<class_int>` frame **)** |const| |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Texture<class_Texture>` | :ref:`get_frame_texture<class_AnimatedTexture_method_get_frame_texture>` **(** :ref:`int<class_int>` frame **)** |const| |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_frame_delay<class_AnimatedTexture_method_set_frame_delay>` **(** :ref:`int<class_int>` frame, :ref:`float<class_float>` delay **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_frame_texture<class_AnimatedTexture_method_set_frame_texture>` **(** :ref:`int<class_int>` frame, :ref:`Texture<class_Texture>` texture **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Constantes
|
||||
--------------------
|
||||
|
||||
.. _class_AnimatedTexture_constant_MAX_FRAMES:
|
||||
|
||||
- **MAX_FRAMES** = **256** --- The maximum number of frames supported by ``AnimatedTexture``. If you need more frames in your animation, use :ref:`AnimationPlayer<class_AnimationPlayer>` or :ref:`AnimatedSprite<class_AnimatedSprite>`.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimatedTexture_property_current_frame:
|
||||
|
||||
- :ref:`int<class_int>` **current_frame**
|
||||
|
||||
+----------+--------------------------+
|
||||
| *Setter* | set_current_frame(value) |
|
||||
+----------+--------------------------+
|
||||
| *Getter* | get_current_frame() |
|
||||
+----------+--------------------------+
|
||||
|
||||
Establece el fotograma actualmente visible de la textura.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedTexture_property_fps:
|
||||
|
||||
- :ref:`float<class_float>` **fps**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``4.0`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_fps(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_fps() |
|
||||
+-----------+----------------+
|
||||
|
||||
Velocidad de animación en fotogramas por segundo. Este valor define el intervalo de tiempo por defecto entre dos fotogramas de la animación, y por lo tanto la duración total del bucle de animación basado en la propiedad :ref:`frames<class_AnimatedTexture_property_frames>`. Un valor de 0 significa que no hay un número predefinido de fotogramas por segundo, la animación se reproducirá de acuerdo con el retardo de fotogramas de cada fotograma (ver :ref:`set_frame_delay<class_AnimatedTexture_method_set_frame_delay>`).
|
||||
|
||||
Por ejemplo, una animación con 8 fotogramas, sin retardo de fotograma y un valor ``fps`` de 2 se ejecutará durante 4 segundos, y cada fotograma durará 0,5 segundos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedTexture_property_frames:
|
||||
|
||||
- :ref:`int<class_int>` **frames**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_frames(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_frames() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Número de fotogramas a usar en la animación. Aunque puedes crear los fotogramas independientemente con :ref:`set_frame_texture<class_AnimatedTexture_method_set_frame_texture>`, necesitas establecer este valor para que la animación tenga en cuenta los nuevos fotogramas. El número máximo de fotogramas es :ref:`MAX_FRAMES<class_AnimatedTexture_constant_MAX_FRAMES>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedTexture_property_oneshot:
|
||||
|
||||
- :ref:`bool<class_bool>` **oneshot**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_oneshot(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | get_oneshot() |
|
||||
+-----------+--------------------+
|
||||
|
||||
Si ``true``, la animación sólo se reproducirá una vez y no volverá al primer fotograma después de llegar al final. Ten en cuenta que al llegar al final no se establecerá :ref:`pause<class_AnimatedTexture_property_pause>` en ``true``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedTexture_property_pause:
|
||||
|
||||
- :ref:`bool<class_bool>` **pause**
|
||||
|
||||
+-----------+------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+------------------+
|
||||
| *Setter* | set_pause(value) |
|
||||
+-----------+------------------+
|
||||
| *Getter* | get_pause() |
|
||||
+-----------+------------------+
|
||||
|
||||
Si ``true``, la animación se detendrá donde se encuentra actualmente (es decir, en :ref:`current_frame<class_AnimatedTexture_property_current_frame>`). La animación continuará desde donde se detuvo al cambiar esta propiedad a ``false``.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimatedTexture_method_get_frame_delay:
|
||||
|
||||
- :ref:`float<class_float>` **get_frame_delay** **(** :ref:`int<class_int>` frame **)** |const|
|
||||
|
||||
Devuelve el valor de retardo del fotograma dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedTexture_method_get_frame_texture:
|
||||
|
||||
- :ref:`Texture<class_Texture>` **get_frame_texture** **(** :ref:`int<class_int>` frame **)** |const|
|
||||
|
||||
Returns the given frame's :ref:`Texture<class_Texture>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedTexture_method_set_frame_delay:
|
||||
|
||||
- void **set_frame_delay** **(** :ref:`int<class_int>` frame, :ref:`float<class_float>` delay **)**
|
||||
|
||||
Establece un retardo adicional (en segundos) entre este fotograma y el siguiente, que se añadirá al intervalo de tiempo definido por :ref:`fps<class_AnimatedTexture_property_fps>`. Por defecto, los fotogramas no tienen definido ningún retardo. Si se define un valor de retardo, el intervalo de tiempo final entre este fotograma y el siguiente será de ``1.0 / fps + retardo``.
|
||||
|
||||
Por ejemplo, para una animación con 3 cuadros, 2 FPS y un retardo de fotograma en el segundo cuadro de 1.2, la reproducción resultante será:
|
||||
|
||||
::
|
||||
|
||||
Fotograma 0: 0.5 s (1 / fps)
|
||||
Fotograma 1: 1.7 s (1 / fps + 1.2)
|
||||
Fotograma 2: 0.5 s (1 / fps)
|
||||
Duración Total : 2.7 segundos
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimatedTexture_method_set_frame_texture:
|
||||
|
||||
- void **set_frame_texture** **(** :ref:`int<class_int>` frame, :ref:`Texture<class_Texture>` texture **)**
|
||||
|
||||
Assigns a :ref:`Texture<class_Texture>` to the given frame. Frame IDs start at 0, so the first frame has ID 0, and the last frame of the animation has ID :ref:`frames<class_AnimatedTexture_property_frames>` - 1.
|
||||
|
||||
You can define any number of textures up to :ref:`MAX_FRAMES<class_AnimatedTexture_constant_MAX_FRAMES>`, but keep in mind that only frames from 0 to :ref:`frames<class_AnimatedTexture_property_frames>` - 1 will be part of the animation.
|
||||
|
||||
.. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
|
||||
.. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
|
||||
.. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
|
||||
@@ -1,788 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the Animation.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_Animation:
|
||||
|
||||
Animation
|
||||
=========
|
||||
|
||||
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Contiene datos usados para animar todo en el motor.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
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 creates an animation that makes the node "Enemy" move to the right by
|
||||
# 100 pixels in 0.5 seconds.
|
||||
var animation = Animation.new()
|
||||
var track_index = animation.add_track(Animation.TYPE_VALUE)
|
||||
animation.track_set_path(track_index, "Enemy:position:x")
|
||||
animation.track_insert_key(track_index, 0.0, 0)
|
||||
animation.track_insert_key(track_index, 0.5, 100)
|
||||
|
||||
Animations are just data containers, and must be added to nodes such as an :ref:`AnimationPlayer<class_AnimationPlayer>` or :ref:`AnimationTreePlayer<class_AnimationTreePlayer>` to be played back. Animation tracks have different types, each with its own set of dedicated methods. Check :ref:`TrackType<enum_Animation_TrackType>` to see available types.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/animation/index`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`length<class_Animation_property_length>` | ``1.0`` |
|
||||
+---------------------------+------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`loop<class_Animation_property_loop>` | ``false`` |
|
||||
+---------------------------+------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`step<class_Animation_property_step>` | ``0.1`` |
|
||||
+---------------------------+------------------------------------------------+-----------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`add_track<class_Animation_method_add_track>` **(** :ref:`TrackType<enum_Animation_TrackType>` type, :ref:`int<class_int>` at_position=-1 **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`animation_track_get_key_animation<class_Animation_method_animation_track_get_key_animation>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`animation_track_insert_key<class_Animation_method_animation_track_insert_key>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`String<class_String>` animation **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`animation_track_set_key_animation<class_Animation_method_animation_track_set_key_animation>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`String<class_String>` animation **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`audio_track_get_key_end_offset<class_Animation_method_audio_track_get_key_end_offset>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`audio_track_get_key_start_offset<class_Animation_method_audio_track_get_key_start_offset>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Resource<class_Resource>` | :ref:`audio_track_get_key_stream<class_Animation_method_audio_track_get_key_stream>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`audio_track_insert_key<class_Animation_method_audio_track_insert_key>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`Resource<class_Resource>` stream, :ref:`float<class_float>` start_offset=0, :ref:`float<class_float>` end_offset=0 **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`audio_track_set_key_end_offset<class_Animation_method_audio_track_set_key_end_offset>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`float<class_float>` offset **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`audio_track_set_key_start_offset<class_Animation_method_audio_track_set_key_start_offset>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`float<class_float>` offset **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`audio_track_set_key_stream<class_Animation_method_audio_track_set_key_stream>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`Resource<class_Resource>` stream **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`bezier_track_get_key_in_handle<class_Animation_method_bezier_track_get_key_in_handle>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`bezier_track_get_key_out_handle<class_Animation_method_bezier_track_get_key_out_handle>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`bezier_track_get_key_value<class_Animation_method_bezier_track_get_key_value>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`bezier_track_insert_key<class_Animation_method_bezier_track_insert_key>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`float<class_float>` value, :ref:`Vector2<class_Vector2>` in_handle=Vector2( 0, 0 ), :ref:`Vector2<class_Vector2>` out_handle=Vector2( 0, 0 ) **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`bezier_track_interpolate<class_Animation_method_bezier_track_interpolate>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`bezier_track_set_key_in_handle<class_Animation_method_bezier_track_set_key_in_handle>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`Vector2<class_Vector2>` in_handle **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`bezier_track_set_key_out_handle<class_Animation_method_bezier_track_set_key_out_handle>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`Vector2<class_Vector2>` out_handle **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`bezier_track_set_key_value<class_Animation_method_bezier_track_set_key_value>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`float<class_float>` value **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear<class_Animation_method_clear>` **(** **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`copy_track<class_Animation_method_copy_track>` **(** :ref:`int<class_int>` track_idx, :ref:`Animation<class_Animation>` to_animation **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`find_track<class_Animation_method_find_track>` **(** :ref:`NodePath<class_NodePath>` path **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_track_count<class_Animation_method_get_track_count>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolIntArray<class_PoolIntArray>` | :ref:`method_track_get_key_indices<class_Animation_method_method_track_get_key_indices>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec, :ref:`float<class_float>` delta **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`method_track_get_name<class_Animation_method_method_track_get_name>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`method_track_get_params<class_Animation_method_method_track_get_params>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_track<class_Animation_method_remove_track>` **(** :ref:`int<class_int>` track_idx **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :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:`bool<class_bool>` exact=false **)** |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| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`InterpolationType<enum_Animation_InterpolationType>` | :ref:`track_get_interpolation_type<class_Animation_method_track_get_interpolation_type>` **(** :ref:`int<class_int>` track_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`track_get_key_count<class_Animation_method_track_get_key_count>` **(** :ref:`int<class_int>` track_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`track_get_key_time<class_Animation_method_track_get_key_time>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`track_get_key_transition<class_Animation_method_track_get_key_transition>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Variant<class_Variant>` | :ref:`track_get_key_value<class_Animation_method_track_get_key_value>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`NodePath<class_NodePath>` | :ref:`track_get_path<class_Animation_method_track_get_path>` **(** :ref:`int<class_int>` track_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`TrackType<enum_Animation_TrackType>` | :ref:`track_get_type<class_Animation_method_track_get_type>` **(** :ref:`int<class_int>` track_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_insert_key<class_Animation_method_track_insert_key>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`Variant<class_Variant>` key, :ref:`float<class_float>` transition=1 **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`track_is_enabled<class_Animation_method_track_is_enabled>` **(** :ref:`int<class_int>` track_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`track_is_imported<class_Animation_method_track_is_imported>` **(** :ref:`int<class_int>` track_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_move_down<class_Animation_method_track_move_down>` **(** :ref:`int<class_int>` track_idx **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_move_to<class_Animation_method_track_move_to>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` to_idx **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_move_up<class_Animation_method_track_move_up>` **(** :ref:`int<class_int>` track_idx **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_remove_key<class_Animation_method_track_remove_key>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_remove_key_at_position<class_Animation_method_track_remove_key_at_position>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` position **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_set_enabled<class_Animation_method_track_set_enabled>` **(** :ref:`int<class_int>` track_idx, :ref:`bool<class_bool>` enabled **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_set_imported<class_Animation_method_track_set_imported>` **(** :ref:`int<class_int>` track_idx, :ref:`bool<class_bool>` imported **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_set_interpolation_loop_wrap<class_Animation_method_track_set_interpolation_loop_wrap>` **(** :ref:`int<class_int>` track_idx, :ref:`bool<class_bool>` interpolation **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_set_interpolation_type<class_Animation_method_track_set_interpolation_type>` **(** :ref:`int<class_int>` track_idx, :ref:`InterpolationType<enum_Animation_InterpolationType>` interpolation **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_set_key_time<class_Animation_method_track_set_key_time>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`float<class_float>` time **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_set_key_transition<class_Animation_method_track_set_key_transition>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`float<class_float>` transition **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_set_key_value<class_Animation_method_track_set_key_value>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key, :ref:`Variant<class_Variant>` value **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_set_path<class_Animation_method_track_set_path>` **(** :ref:`int<class_int>` track_idx, :ref:`NodePath<class_NodePath>` path **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`track_swap<class_Animation_method_track_swap>` **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` with_idx **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`transform_track_insert_key<class_Animation_method_transform_track_insert_key>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`Vector3<class_Vector3>` location, :ref:`Quat<class_Quat>` rotation, :ref:`Vector3<class_Vector3>` scale **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`transform_track_interpolate<class_Animation_method_transform_track_interpolate>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolIntArray<class_PoolIntArray>` | :ref:`value_track_get_key_indices<class_Animation_method_value_track_get_key_indices>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec, :ref:`float<class_float>` delta **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`UpdateMode<enum_Animation_UpdateMode>` | :ref:`value_track_get_update_mode<class_Animation_method_value_track_get_update_mode>` **(** :ref:`int<class_int>` track_idx **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Variant<class_Variant>` | :ref:`value_track_interpolate<class_Animation_method_value_track_interpolate>` **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`value_track_set_update_mode<class_Animation_method_value_track_set_update_mode>` **(** :ref:`int<class_int>` track_idx, :ref:`UpdateMode<enum_Animation_UpdateMode>` mode **)** |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_Animation_signal_tracks_changed:
|
||||
|
||||
- **tracks_changed** **(** **)**
|
||||
|
||||
Emitido cuando hay un cambio en la lista de pistas, por ejemplo, las pistas se añaden, se mueven o han cambiado de camino.
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_Animation_TrackType:
|
||||
|
||||
.. _class_Animation_constant_TYPE_VALUE:
|
||||
|
||||
.. _class_Animation_constant_TYPE_TRANSFORM:
|
||||
|
||||
.. _class_Animation_constant_TYPE_METHOD:
|
||||
|
||||
.. _class_Animation_constant_TYPE_BEZIER:
|
||||
|
||||
.. _class_Animation_constant_TYPE_AUDIO:
|
||||
|
||||
.. _class_Animation_constant_TYPE_ANIMATION:
|
||||
|
||||
enum **TrackType**:
|
||||
|
||||
- **TYPE_VALUE** = **0** --- Las pistas de valores establecen valores en las propiedades de los nodos, pero sólo los que pueden ser interpolados.
|
||||
|
||||
- **TYPE_TRANSFORM** = **1** --- Las pistas de transformación se usan para cambiar las transformaciones locales de los nodos o los huesos del esqueleto. Las transiciones se interpolan.
|
||||
|
||||
- **TYPE_METHOD** = **2** --- El método rastrea las funciones de llamada con argumentos dados por clave.
|
||||
|
||||
- **TYPE_BEZIER** = **3** --- Las pistas de Bezier se usan para interpolar un valor usando curvas personalizadas. También se pueden utilizar para animar sub-propiedades de vectores y colores (por ejemplo, el valor alfa de un :ref:`Color<class_Color>`).
|
||||
|
||||
- **TYPE_AUDIO** = **4** --- Las pistas de audio se utilizan para reproducir un stream de audio con cualquier tipo de :ref:`AudioStreamPlayer<class_AudioStreamPlayer>`. El stream puede ser recortado y previsualizado en la animación.
|
||||
|
||||
- **TYPE_ANIMATION** = **5** --- Las pistas de animación reproducen las animaciones en otros nodos :ref:`AnimationPlayer<class_AnimationPlayer>`.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_Animation_InterpolationType:
|
||||
|
||||
.. _class_Animation_constant_INTERPOLATION_NEAREST:
|
||||
|
||||
.. _class_Animation_constant_INTERPOLATION_LINEAR:
|
||||
|
||||
.. _class_Animation_constant_INTERPOLATION_CUBIC:
|
||||
|
||||
enum **InterpolationType**:
|
||||
|
||||
- **INTERPOLATION_NEAREST** = **0** --- No hay interpolación (valor más cercano).
|
||||
|
||||
- **INTERPOLATION_LINEAR** = **1** --- Interpolación lineal.
|
||||
|
||||
- **INTERPOLATION_CUBIC** = **2** --- Interpolación cúbica.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_Animation_UpdateMode:
|
||||
|
||||
.. _class_Animation_constant_UPDATE_CONTINUOUS:
|
||||
|
||||
.. _class_Animation_constant_UPDATE_DISCRETE:
|
||||
|
||||
.. _class_Animation_constant_UPDATE_TRIGGER:
|
||||
|
||||
.. _class_Animation_constant_UPDATE_CAPTURE:
|
||||
|
||||
enum **UpdateMode**:
|
||||
|
||||
- **UPDATE_CONTINUOUS** = **0** --- Actualización entre fotogramas clave.
|
||||
|
||||
- **UPDATE_DISCRETE** = **1** --- Actualizar los fotogramas clave y mantener el valor.
|
||||
|
||||
- **UPDATE_TRIGGER** = **2** --- Actualización de los fotogramas clave.
|
||||
|
||||
- **UPDATE_CAPTURE** = **3** --- Igual que la interpolación lineal, pero también interpola a partir del valor actual (es decir, dinámicamente en tiempo de ejecución) si la primera clave no está en 0 segundos.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_Animation_property_length:
|
||||
|
||||
- :ref:`float<class_float>` **length**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_length(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_length() |
|
||||
+-----------+-------------------+
|
||||
|
||||
La duración total de la animación (en segundos).
|
||||
|
||||
\ **Nota:** La longitud no está delimitada por la última clave, ya que ésta puede estar antes o después del final para asegurar una correcta interpolación y bucle.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_property_loop:
|
||||
|
||||
- :ref:`bool<class_bool>` **loop**
|
||||
|
||||
+-----------+-----------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-----------------+
|
||||
| *Setter* | set_loop(value) |
|
||||
+-----------+-----------------+
|
||||
| *Getter* | has_loop() |
|
||||
+-----------+-----------------+
|
||||
|
||||
A flag indicating that the animation must loop. This is used for correct interpolation of animation cycles, and for hinting the player that it must restart the animation.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_property_step:
|
||||
|
||||
- :ref:`float<class_float>` **step**
|
||||
|
||||
+-----------+-----------------+
|
||||
| *Default* | ``0.1`` |
|
||||
+-----------+-----------------+
|
||||
| *Setter* | set_step(value) |
|
||||
+-----------+-----------------+
|
||||
| *Getter* | get_step() |
|
||||
+-----------+-----------------+
|
||||
|
||||
El valor del paso de la animación.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_Animation_method_add_track:
|
||||
|
||||
- :ref:`int<class_int>` **add_track** **(** :ref:`TrackType<enum_Animation_TrackType>` type, :ref:`int<class_int>` at_position=-1 **)**
|
||||
|
||||
Añade una pista a la animación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_animation_track_get_key_animation:
|
||||
|
||||
- :ref:`String<class_String>` **animation_track_get_key_animation** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve el nombre de la animación en la clave identificada por ``key_idx``. El ``track_idx`` debe ser el índice de una pista de animación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_animation_track_insert_key:
|
||||
|
||||
- :ref:`int<class_int>` **animation_track_insert_key** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`String<class_String>` animation **)**
|
||||
|
||||
Inserta una clave con el valor ``animation`` en el ``time`` dado (en segundos). El ``track_idx`` debe ser el índice de una pista de animación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_animation_track_set_key_animation:
|
||||
|
||||
- void **animation_track_set_key_animation** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`String<class_String>` animation **)**
|
||||
|
||||
Establece la clave identificada por ``key_idx`` como valor de ``animación``. El ``track_idx`` debe ser el índice de una pista de animación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_audio_track_get_key_end_offset:
|
||||
|
||||
- :ref:`float<class_float>` **audio_track_get_key_end_offset** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve el desplazamiento final de la clave identificada por ``key_idx``. El ``track_idx`` debe ser el índice de una pista de audio.
|
||||
|
||||
El dezplazamiento final es el número de segundos que se cortan al final de la pista de audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_audio_track_get_key_start_offset:
|
||||
|
||||
- :ref:`float<class_float>` **audio_track_get_key_start_offset** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve el desplazamiento inicial de la clave identificada por ``key_idx``. El ``track_idx`` debe ser el índice de una pista de audio.
|
||||
|
||||
El desplazamiento de inicio es el número de segundos cortados al principio de la pista de audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_audio_track_get_key_stream:
|
||||
|
||||
- :ref:`Resource<class_Resource>` **audio_track_get_key_stream** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve el stream de audio de la clave identificada por ``key_idx``. El ``track_idx`` debe ser el índice de una pista de audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_audio_track_insert_key:
|
||||
|
||||
- :ref:`int<class_int>` **audio_track_insert_key** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`Resource<class_Resource>` stream, :ref:`float<class_float>` start_offset=0, :ref:`float<class_float>` end_offset=0 **)**
|
||||
|
||||
Inserta una clave de pista de Audio en el ``time`` dado en segundos. El ``track_idx`` debe ser el índice de una Pista de Audio.
|
||||
|
||||
\ ``stream`` es el recurso de :ref:`AudioStream<class_AudioStream>` para reproducir. ``start_offset`` es el número de segundos que se cortan al principio del stream de audio, mientras que ``end_offset`` está al final.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_audio_track_set_key_end_offset:
|
||||
|
||||
- void **audio_track_set_key_end_offset** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`float<class_float>` offset **)**
|
||||
|
||||
Establece el desplazamiento final de la clave identificada por ``key_idx`` como el valor de ``offset``. El ``track_idx`` debe ser el índice de una pista de audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_audio_track_set_key_start_offset:
|
||||
|
||||
- void **audio_track_set_key_start_offset** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`float<class_float>` offset **)**
|
||||
|
||||
Establece el desplazamiento inicial de la clave identificada por ``key_idx`` como el valor de ``offset``. El ``track_idx`` debe ser el índice de una pista de audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_audio_track_set_key_stream:
|
||||
|
||||
- void **audio_track_set_key_stream** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`Resource<class_Resource>` stream **)**
|
||||
|
||||
Sets the stream of the key identified by ``key_idx`` to value ``stream``. The ``track_idx`` must be the index of an Audio Track.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_bezier_track_get_key_in_handle:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **bezier_track_get_key_in_handle** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve el in handle de la clave identificada por ``key_idx``. El ``track_idx`` debe ser el índice de una pista de Bezier.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_bezier_track_get_key_out_handle:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **bezier_track_get_key_out_handle** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve el out handle de la llave identificada por ``key_idx``. El ``track_idx`` debe ser el índice de una pista de Bezier.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_bezier_track_get_key_value:
|
||||
|
||||
- :ref:`float<class_float>` **bezier_track_get_key_value** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve el valor de la clave identificada por ``key_idx``. El ``track_idx`` debe ser el índice de una pista de Bezier.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_bezier_track_insert_key:
|
||||
|
||||
- :ref:`int<class_int>` **bezier_track_insert_key** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`float<class_float>` value, :ref:`Vector2<class_Vector2>` in_handle=Vector2( 0, 0 ), :ref:`Vector2<class_Vector2>` out_handle=Vector2( 0, 0 ) **)**
|
||||
|
||||
Inserta una CLAVE en una pista de Bezier en el ``time`` dado en segundos. El ``track_idx`` debe ser el índice de una pista de Besier.
|
||||
|
||||
\ ``in_handle`` es el peso del lado izquierdo del punto de la curva de Bezier añadido, ``out_handle`` es el del lado derecho, mientras que ``value`` es el valor actual en este punto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_bezier_track_interpolate:
|
||||
|
||||
- :ref:`float<class_float>` **bezier_track_interpolate** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time **)** |const|
|
||||
|
||||
Devuelve el valor interpolado en el ``time`` dado (en segundos). El ``track_idx`` debe ser el índice de una pista de Bezier.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_bezier_track_set_key_in_handle:
|
||||
|
||||
- void **bezier_track_set_key_in_handle** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`Vector2<class_Vector2>` in_handle **)**
|
||||
|
||||
Establece el in handle de la clave identificada por ``key_idx`` como el valor de ``in_handle``. El ``track_idx`` debe ser el índice de una pista de Bezier.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_bezier_track_set_key_out_handle:
|
||||
|
||||
- void **bezier_track_set_key_out_handle** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`Vector2<class_Vector2>` out_handle **)**
|
||||
|
||||
Establece el out handle de la llave identificada por ``key_idx`` como el valor de ``out_handle``. El ``track_idx`` debe ser el índice de una pista de Bezier.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_bezier_track_set_key_value:
|
||||
|
||||
- void **bezier_track_set_key_value** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`float<class_float>` value **)**
|
||||
|
||||
Establece el valor de la clave identificada por ``key_idx`` al valor dado. El ``track_idx`` debe ser el índice de una pista de Bezier.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_clear:
|
||||
|
||||
- void **clear** **(** **)**
|
||||
|
||||
Limpiar la animacion (limpia todas las pistas y reinicia todo).
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_copy_track:
|
||||
|
||||
- void **copy_track** **(** :ref:`int<class_int>` track_idx, :ref:`Animation<class_Animation>` to_animation **)**
|
||||
|
||||
Añade una nueva pista que es una copia de la pista dada de ``to_animation``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_find_track:
|
||||
|
||||
- :ref:`int<class_int>` **find_track** **(** :ref:`NodePath<class_NodePath>` path **)** |const|
|
||||
|
||||
Devuelve el índice de la pista especificada. Si la pista no se encuentra, devuelve -1.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_get_track_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_track_count** **(** **)** |const|
|
||||
|
||||
Devuelve la cantidad de pistas en la animación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_method_track_get_key_indices:
|
||||
|
||||
- :ref:`PoolIntArray<class_PoolIntArray>` **method_track_get_key_indices** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec, :ref:`float<class_float>` delta **)** |const|
|
||||
|
||||
Devuelve todos los índices clave de una pista de método, dada una posición y tiempo delta.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_method_track_get_name:
|
||||
|
||||
- :ref:`String<class_String>` **method_track_get_name** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve el nombre del método de una pista de método.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_method_track_get_params:
|
||||
|
||||
- :ref:`Array<class_Array>` **method_track_get_params** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve los valores de los argumentos que se llamarán en una pista del método para una clave determinada en una pista determinada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_remove_track:
|
||||
|
||||
- void **remove_track** **(** :ref:`int<class_int>` track_idx **)**
|
||||
|
||||
Elimina una pista especificando el índice de la pista.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_find_key:
|
||||
|
||||
- :ref:`int<class_int>` **track_find_key** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`bool<class_bool>` exact=false **)** |const|
|
||||
|
||||
Encuentra el índice clave por tiempo en una pista determinada. Opcionalmente, sólo lo encuentra si se da la hora exacta.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_get_interpolation_loop_wrap:
|
||||
|
||||
- :ref:`bool<class_bool>` **track_get_interpolation_loop_wrap** **(** :ref:`int<class_int>` track_idx **)** |const|
|
||||
|
||||
Devuelve ``true`` si la pista en ``idx`` envuelve el bucle de interpolación. Las nuevas pistas envuelven el bucle de interpolación por defecto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_get_interpolation_type:
|
||||
|
||||
- :ref:`InterpolationType<enum_Animation_InterpolationType>` **track_get_interpolation_type** **(** :ref:`int<class_int>` track_idx **)** |const|
|
||||
|
||||
Devuelve el tipo de interpolación de una pista determinada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_get_key_count:
|
||||
|
||||
- :ref:`int<class_int>` **track_get_key_count** **(** :ref:`int<class_int>` track_idx **)** |const|
|
||||
|
||||
Devuelve la cantidad de claves en una pista determinada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_get_key_time:
|
||||
|
||||
- :ref:`float<class_float>` **track_get_key_time** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve la hora en la que se encuentra la clave.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_get_key_transition:
|
||||
|
||||
- :ref:`float<class_float>` **track_get_key_transition** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve la curva de transición (relajación) para una clave específica (ver la función matemática incorporada :ref:`@GDScript.ease<class_@GDScript_method_ease>`).
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_get_key_value:
|
||||
|
||||
- :ref:`Variant<class_Variant>` **track_get_key_value** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)** |const|
|
||||
|
||||
Devuelve el valor de una clave determinada en una pista determinada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_get_path:
|
||||
|
||||
- :ref:`NodePath<class_NodePath>` **track_get_path** **(** :ref:`int<class_int>` track_idx **)** |const|
|
||||
|
||||
Obtiene el camino de una pista. Para más información sobre el formato de la ruta, ver :ref:`track_set_path<class_Animation_method_track_set_path>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_get_type:
|
||||
|
||||
- :ref:`TrackType<enum_Animation_TrackType>` **track_get_type** **(** :ref:`int<class_int>` track_idx **)** |const|
|
||||
|
||||
Obtiene el tipo de pista.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_insert_key:
|
||||
|
||||
- void **track_insert_key** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`Variant<class_Variant>` key, :ref:`float<class_float>` transition=1 **)**
|
||||
|
||||
Insertar una clave genérica en una pista determinada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_is_enabled:
|
||||
|
||||
- :ref:`bool<class_bool>` **track_is_enabled** **(** :ref:`int<class_int>` track_idx **)** |const|
|
||||
|
||||
Devuelve ``true`` si la pista en el índice ``idx`` está habilitada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_is_imported:
|
||||
|
||||
- :ref:`bool<class_bool>` **track_is_imported** **(** :ref:`int<class_int>` track_idx **)** |const|
|
||||
|
||||
Devuelve ``true`` si la pista dada es importada. Si no, devuelve ``false``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_move_down:
|
||||
|
||||
- void **track_move_down** **(** :ref:`int<class_int>` track_idx **)**
|
||||
|
||||
Mueve una pista hacia abajo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_move_to:
|
||||
|
||||
- void **track_move_to** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` to_idx **)**
|
||||
|
||||
Cambia la posición del índice de la pista ``idx`` a la definida en ``to_idx``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_move_up:
|
||||
|
||||
- void **track_move_up** **(** :ref:`int<class_int>` track_idx **)**
|
||||
|
||||
Mueve una pista hacia arriba.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_remove_key:
|
||||
|
||||
- void **track_remove_key** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx **)**
|
||||
|
||||
Elimina una clave por índice en una pista dada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_remove_key_at_position:
|
||||
|
||||
- void **track_remove_key_at_position** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` position **)**
|
||||
|
||||
Quita una clave por posición (segundos) en una pista determinada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_set_enabled:
|
||||
|
||||
- void **track_set_enabled** **(** :ref:`int<class_int>` track_idx, :ref:`bool<class_bool>` enabled **)**
|
||||
|
||||
Habilita o deshabilita la pista dada. Las pistas están habilitadas por defecto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_set_imported:
|
||||
|
||||
- void **track_set_imported** **(** :ref:`int<class_int>` track_idx, :ref:`bool<class_bool>` imported **)**
|
||||
|
||||
Establece la pista dada como importada o no.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_set_interpolation_loop_wrap:
|
||||
|
||||
- void **track_set_interpolation_loop_wrap** **(** :ref:`int<class_int>` track_idx, :ref:`bool<class_bool>` interpolation **)**
|
||||
|
||||
Si ``true``, la pista en ``idx`` envuelve el bucle de interpolación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_set_interpolation_type:
|
||||
|
||||
- void **track_set_interpolation_type** **(** :ref:`int<class_int>` track_idx, :ref:`InterpolationType<enum_Animation_InterpolationType>` interpolation **)**
|
||||
|
||||
Establece el tipo de interpolación de una pista determinada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_set_key_time:
|
||||
|
||||
- void **track_set_key_time** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`float<class_float>` time **)**
|
||||
|
||||
Establece la hora de una clave existente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_set_key_transition:
|
||||
|
||||
- void **track_set_key_transition** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key_idx, :ref:`float<class_float>` transition **)**
|
||||
|
||||
Establece la curva de transición (relajación) para una clave específica (ver la función matemática incorporada :ref:`@GDScript.ease<class_@GDScript_method_ease>`).
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_set_key_value:
|
||||
|
||||
- void **track_set_key_value** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` key, :ref:`Variant<class_Variant>` value **)**
|
||||
|
||||
Establece el valor de una clave existente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_set_path:
|
||||
|
||||
- void **track_set_path** **(** :ref:`int<class_int>` track_idx, :ref:`NodePath<class_NodePath>` path **)**
|
||||
|
||||
Sets the path of a track. Paths must be valid scene-tree paths to a node and must be specified starting from the parent node of the node that will reproduce the animation. Tracks that control properties or bones must append their name after the path, separated by ``":"``.
|
||||
|
||||
For example, ``"character/skeleton:ankle"`` or ``"character/mesh:transform/local"``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_track_swap:
|
||||
|
||||
- void **track_swap** **(** :ref:`int<class_int>` track_idx, :ref:`int<class_int>` with_idx **)**
|
||||
|
||||
Intercambia la posición del índice de la pista ``idx`` con la pista ``con_idx``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_transform_track_insert_key:
|
||||
|
||||
- :ref:`int<class_int>` **transform_track_insert_key** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time, :ref:`Vector3<class_Vector3>` location, :ref:`Quat<class_Quat>` rotation, :ref:`Vector3<class_Vector3>` scale **)**
|
||||
|
||||
Inserte una clave de transformación para una pista de transformación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_transform_track_interpolate:
|
||||
|
||||
- :ref:`Array<class_Array>` **transform_track_interpolate** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const|
|
||||
|
||||
Devuelve el valor interpolado de una pista de transformación en un momento dado (en segundos). Una array compuesto por 3 elementos: posición (:ref:`Vector3<class_Vector3>`), rotación (:ref:`Quat<class_Quat>`) y escala (:ref:`Vector3<class_Vector3>`).
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_value_track_get_key_indices:
|
||||
|
||||
- :ref:`PoolIntArray<class_PoolIntArray>` **value_track_get_key_indices** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec, :ref:`float<class_float>` delta **)** |const|
|
||||
|
||||
Devuelve todos los índices clave de una pista de valores, dada una posición y un tiempo delta.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_value_track_get_update_mode:
|
||||
|
||||
- :ref:`UpdateMode<enum_Animation_UpdateMode>` **value_track_get_update_mode** **(** :ref:`int<class_int>` track_idx **)** |const|
|
||||
|
||||
Devuelve el modo de actualización de una pista de valores.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_value_track_interpolate:
|
||||
|
||||
- :ref:`Variant<class_Variant>` **value_track_interpolate** **(** :ref:`int<class_int>` track_idx, :ref:`float<class_float>` time_sec **)** |const|
|
||||
|
||||
Returns the interpolated value at the given time (in seconds). The ``track_idx`` must be the index of a value track.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Animation_method_value_track_set_update_mode:
|
||||
|
||||
- void **value_track_set_update_mode** **(** :ref:`int<class_int>` track_idx, :ref:`UpdateMode<enum_Animation_UpdateMode>` mode **)**
|
||||
|
||||
Establece el modo de actualización (ver :ref:`UpdateMode<enum_Animation_UpdateMode>`) de una pista de valores.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,284 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNode.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNode:
|
||||
|
||||
AnimationNode
|
||||
=============
|
||||
|
||||
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`AnimationNodeAdd2<class_AnimationNodeAdd2>`, :ref:`AnimationNodeAdd3<class_AnimationNodeAdd3>`, :ref:`AnimationNodeBlend2<class_AnimationNodeBlend2>`, :ref:`AnimationNodeBlend3<class_AnimationNodeBlend3>`, :ref:`AnimationNodeOneShot<class_AnimationNodeOneShot>`, :ref:`AnimationNodeOutput<class_AnimationNodeOutput>`, :ref:`AnimationNodeTimeScale<class_AnimationNodeTimeScale>`, :ref:`AnimationNodeTimeSeek<class_AnimationNodeTimeSeek>`, :ref:`AnimationNodeTransition<class_AnimationNodeTransition>`, :ref:`AnimationRootNode<class_AnimationRootNode>`
|
||||
|
||||
Recurso base para los nodos de :ref:`AnimationTree<class_AnimationTree>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Recurso base para los nodos de :ref:`AnimationTree<class_AnimationTree>`. En general, no se usa directamente, pero puedes crear personalizados con fórmulas de mezcla personalizadas.
|
||||
|
||||
Esto se hereda cuando se crean nodos principalmente para su uso en :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`, de lo contrario se debe usar :ref:`AnimationRootNode<class_AnimationRootNode>` en su lugar.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/animation/animation_tree`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------+--------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`filter_enabled<class_AnimationNode_property_filter_enabled>` |
|
||||
+-------------------------+--------------------------------------------------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_input<class_AnimationNode_method_add_input>` **(** :ref:`String<class_String>` name **)** |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`blend_animation<class_AnimationNode_method_blend_animation>` **(** :ref:`String<class_String>` animation, :ref:`float<class_float>` time, :ref:`float<class_float>` delta, :ref:`bool<class_bool>` seeked, :ref:`float<class_float>` blend **)** |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :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:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` optimize=true **)** |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`blend_node<class_AnimationNode_method_blend_node>` **(** :ref:`String<class_String>` name, :ref:`AnimationNode<class_AnimationNode>` node, :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` optimize=true **)** |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_caption<class_AnimationNode_method_get_caption>` **(** **)** |virtual| |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Object<class_Object>` | :ref:`get_child_by_name<class_AnimationNode_method_get_child_by_name>` **(** :ref:`String<class_String>` name **)** |virtual| |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Dictionary<class_Dictionary>` | :ref:`get_child_nodes<class_AnimationNode_method_get_child_nodes>` **(** **)** |virtual| |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :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 **)** |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Variant<class_Variant>` | :ref:`get_parameter<class_AnimationNode_method_get_parameter>` **(** :ref:`String<class_String>` name **)** |const| |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Variant<class_Variant>` | :ref:`get_parameter_default_value<class_AnimationNode_method_get_parameter_default_value>` **(** :ref:`String<class_String>` name **)** |virtual| |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`get_parameter_list<class_AnimationNode_method_get_parameter_list>` **(** **)** |virtual| |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`has_filter<class_AnimationNode_method_has_filter>` **(** **)** |virtual| |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_path_filtered<class_AnimationNode_method_is_path_filtered>` **(** :ref:`NodePath<class_NodePath>` path **)** |const| |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`process<class_AnimationNode_method_process>` **(** :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek **)** |virtual| |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| 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 **)** |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_parameter<class_AnimationNode_method_set_parameter>` **(** :ref:`String<class_String>` name, :ref:`Variant<class_Variant>` value **)** |
|
||||
+-------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_AnimationNode_signal_removed_from_graph:
|
||||
|
||||
- **removed_from_graph** **(** **)**
|
||||
|
||||
Llamado cuando el nodo es eliminado desde el gráfico.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_signal_tree_changed:
|
||||
|
||||
- **tree_changed** **(** **)**
|
||||
|
||||
Emitidos por nodos que heredan de esta clase y que tienen un árbol interno cuando uno de sus nodos cambia. Los nodos que emiten esta señal son :ref:`AnimationNodeBlendSpace1D<class_AnimationNodeBlendSpace1D>`, :ref:`AnimationNodeBlendSpace2D<class_AnimationNodeBlendSpace2D>`, :ref:`AnimationNodeStateMachine<class_AnimationNodeStateMachine>`, y :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AnimationNode_FilterAction:
|
||||
|
||||
.. _class_AnimationNode_constant_FILTER_IGNORE:
|
||||
|
||||
.. _class_AnimationNode_constant_FILTER_PASS:
|
||||
|
||||
.. _class_AnimationNode_constant_FILTER_STOP:
|
||||
|
||||
.. _class_AnimationNode_constant_FILTER_BLEND:
|
||||
|
||||
enum **FilterAction**:
|
||||
|
||||
- **FILTER_IGNORE** = **0** --- No utilice el filtrado.
|
||||
|
||||
- **FILTER_PASS** = **1** --- Las rutas que coincidan con el filtro podrán pasar.
|
||||
|
||||
- **FILTER_STOP** = **2** --- Las rutas que coincidan con el filtro serán descartados.
|
||||
|
||||
- **FILTER_BLEND** = **3** --- Los caminos que coincidan con el filtro se mezclarán (por el valor de mezcla).
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNode_property_filter_enabled:
|
||||
|
||||
- :ref:`bool<class_bool>` **filter_enabled**
|
||||
|
||||
+----------+---------------------------+
|
||||
| *Setter* | set_filter_enabled(value) |
|
||||
+----------+---------------------------+
|
||||
| *Getter* | is_filter_enabled() |
|
||||
+----------+---------------------------+
|
||||
|
||||
Si ``true``, el filtrado está activado.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimationNode_method_add_input:
|
||||
|
||||
- void **add_input** **(** :ref:`String<class_String>` name **)**
|
||||
|
||||
Añade una entrada al nodo. Esto sólo es útil para los nodos creados para su uso en un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_blend_animation:
|
||||
|
||||
- void **blend_animation** **(** :ref:`String<class_String>` animation, :ref:`float<class_float>` time, :ref:`float<class_float>` delta, :ref:`bool<class_bool>` seeked, :ref:`float<class_float>` blend **)**
|
||||
|
||||
Mezclar una animación por cantidad de ``blend`` (el nombre debe ser válido en el :ref:`AnimationPlayer<class_AnimationPlayer>` vinculado). Se puede pasar un ``time`` y un ``delta``, así como el ``seek``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_blend_input:
|
||||
|
||||
- :ref:`float<class_float>` **blend_input** **(** :ref:`int<class_int>` input_index, :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` optimize=true **)**
|
||||
|
||||
Mezcla una entrada. Esto sólo es útil para los nodos creados para un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. El parámetro ``time`` es un delta relativo, a menos que ``seek`` sea ``true``, en cuyo caso es absoluto. Se puede pasar opcionalmente un modo de filtro (véase :ref:`FilterAction<enum_AnimationNode_FilterAction>` para las opciones).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_blend_node:
|
||||
|
||||
- :ref:`float<class_float>` **blend_node** **(** :ref:`String<class_String>` name, :ref:`AnimationNode<class_AnimationNode>` node, :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek, :ref:`float<class_float>` blend, :ref:`FilterAction<enum_AnimationNode_FilterAction>` filter=0, :ref:`bool<class_bool>` optimize=true **)**
|
||||
|
||||
Mezcla otro nodo de animacion (en caso de que este nodo contenga nodos de animación hijos). Esta función es util sólo si hereda de :ref:`AnimationRootNode<class_AnimationRootNode>`. Si no, el editor no mostrará el nodo para añadir.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_get_caption:
|
||||
|
||||
- :ref:`String<class_String>` **get_caption** **(** **)** |virtual|
|
||||
|
||||
Obtiene la leyenda del texto de este nodo (usado por algunos editores).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_get_child_by_name:
|
||||
|
||||
- :ref:`Object<class_Object>` **get_child_by_name** **(** :ref:`String<class_String>` name **)** |virtual|
|
||||
|
||||
Obtiene un nodo hijo por índice (utilizado por los editores que heredan de :ref:`AnimationRootNode<class_AnimationRootNode>`).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_get_child_nodes:
|
||||
|
||||
- :ref:`Dictionary<class_Dictionary>` **get_child_nodes** **(** **)** |virtual|
|
||||
|
||||
Ordena todos los nodos infantiles como un diccionario de ``name: node``. Sólo es útil cuando se hereda :ref:`AnimationRootNode<class_AnimationRootNode>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_get_input_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_input_count** **(** **)** |const|
|
||||
|
||||
Cantidad de entradas en este nodo, sólo útil para los nodos que entran en :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_get_input_name:
|
||||
|
||||
- :ref:`String<class_String>` **get_input_name** **(** :ref:`int<class_int>` input **)**
|
||||
|
||||
Obtiene el nombre de una entrada por índice.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_get_parameter:
|
||||
|
||||
- :ref:`Variant<class_Variant>` **get_parameter** **(** :ref:`String<class_String>` name **)** |const|
|
||||
|
||||
Obtiene el valor de un parámetro. Los parámetros son la memoria local personalizada que se utiliza para tus nodos, dado que un recurso puede ser reutilizado en múltiples árboles.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_get_parameter_default_value:
|
||||
|
||||
- :ref:`Variant<class_Variant>` **get_parameter_default_value** **(** :ref:`String<class_String>` name **)** |virtual|
|
||||
|
||||
Obtiene el valor por defecto de un parametro. Los parametros son personalizados en memoria local utilizados para tus nodos, dado que un recurso puede ser reutilizado en multiples arboles.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_get_parameter_list:
|
||||
|
||||
- :ref:`Array<class_Array>` **get_parameter_list** **(** **)** |virtual|
|
||||
|
||||
Obtiene la información de la propiedad para el parámetro. Los parámetros son la memoria local personalizada que se utiliza para sus nodos, dado que un recurso puede ser reutilizado en múltiples árboles. El formato es similar al del :ref:`Object.get_property_list<class_Object_method_get_property_list>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_has_filter:
|
||||
|
||||
- :ref:`String<class_String>` **has_filter** **(** **)** |virtual|
|
||||
|
||||
Devuelve ``true`` si quieres que el editor del árbol de mezcla muestre la edición del filtro en este nodo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_is_path_filtered:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_path_filtered** **(** :ref:`NodePath<class_NodePath>` path **)** |const|
|
||||
|
||||
Devuelve ``true`` si un camino dado es filtrado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_process:
|
||||
|
||||
- void **process** **(** :ref:`float<class_float>` time, :ref:`bool<class_bool>` seek **)** |virtual|
|
||||
|
||||
Se llama a la devolución de llamada definida por el usuario cuando se procesa un nodo personalizado. El parámetro ``time`` es un delta relativo, a menos que ``seek`` sea ``true``, en cuyo caso es absoluto.
|
||||
|
||||
Aquí, llama a las funciones :ref:`blend_input<class_AnimationNode_method_blend_input>`, :ref:`blend_node<class_AnimationNode_method_blend_node>` o :ref:`blend_animation<class_AnimationNode_method_blend_animation>`. También puedes usar :ref:`get_parameter<class_AnimationNode_method_get_parameter>` y :ref:`set_parameter<class_AnimationNode_method_set_parameter>` para modificar la memoria local.
|
||||
|
||||
Esta función debería devolver el tiempo que queda para que termine la animación actual (si no estás seguro, pasa el valor de la mezcla principal que se está llamando).Devuelve el tipo de interpolacion dada una pista.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_remove_input:
|
||||
|
||||
- void **remove_input** **(** :ref:`int<class_int>` index **)**
|
||||
|
||||
Elimina una entrada, llama a esto sólo cuando está inactivo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_set_filter_path:
|
||||
|
||||
- void **set_filter_path** **(** :ref:`NodePath<class_NodePath>` path, :ref:`bool<class_bool>` enable **)**
|
||||
|
||||
Añade o elimina una ruta para el filtro.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNode_method_set_parameter:
|
||||
|
||||
- void **set_parameter** **(** :ref:`String<class_String>` name, :ref:`Variant<class_Variant>` value **)**
|
||||
|
||||
Establece un parámetro personalizado. Estos se usan como almacenamiento local, porque los recursos pueden ser reutilizados a través del árbol o las escenas.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,52 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeAdd2.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeAdd2:
|
||||
|
||||
AnimationNodeAdd2
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Mezcla dos animaciones sumándolas dentro de un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Un recurso para añadir a un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. Mezcla dos animaciones sumadas en base a un valor de cantidad en el rango de ``[0.0, 1.0]``.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/animation/animation_tree`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------+----------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`sync<class_AnimationNodeAdd2_property_sync>` | ``false`` |
|
||||
+-------------------------+----------------------------------------------------+-----------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeAdd2_property_sync:
|
||||
|
||||
- :ref:`bool<class_bool>` **sync**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_use_sync(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | is_using_sync() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Si ``true``, establece la optimización ``optimization`` a ``false`` al llamar al :ref:`AnimationNode.blend_input<class_AnimationNode_method_blend_input>`, obligando a las animaciones mezcladas a actualizar cada fotograma.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,62 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeAdd3.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeAdd3:
|
||||
|
||||
AnimationNodeAdd3
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Mezcla dos de tres animaciones sumandolas dentro de un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Un recurso para añadir a un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. Mezcla dos animaciones juntas sumándolas de tres en base a un valor en el rango de ``[-1.0, 1.0]``.
|
||||
|
||||
Este nodo tiene tres entradas:
|
||||
|
||||
- La animación base para sumar a
|
||||
|
||||
- Una animación - agregar para mezclar cuando la cantidad de mezcla está en el rango de ``[-1.0, 0.0]``.
|
||||
|
||||
- Una animación +agregar para mezclar cuando la cantidad de mezcla está en el rango de ``[0.0, 1.0]``
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
|
||||
|
||||
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------+----------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`sync<class_AnimationNodeAdd3_property_sync>` | ``false`` |
|
||||
+-------------------------+----------------------------------------------------+-----------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeAdd3_property_sync:
|
||||
|
||||
- :ref:`bool<class_bool>` **sync**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_use_sync(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | is_using_sync() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Si ``true``, establece la optimización ``optimization`` a ``false`` al llamar al :ref:`AnimationNode.blend_input<class_AnimationNode_method_blend_input>`, obligando a las animaciones mezcladas a actualizar cada fotograma.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,56 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeAnimation.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeAnimation:
|
||||
|
||||
AnimationNodeAnimation
|
||||
======================
|
||||
|
||||
**Inherits:** :ref:`AnimationRootNode<class_AnimationRootNode>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Introducir la animación para usarla en un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Un recurso para añadir a un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. Sólo tiene un conjunto de salida usando la propiedad :ref:`animation<class_AnimationNodeAnimation_property_animation>`. Úsalo como una entrada para el :ref:`AnimationNode<class_AnimationNode>` que mezcla las animaciones entre sí.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
|
||||
|
||||
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__
|
||||
|
||||
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------+-------------------------------------------------------------------+--------+
|
||||
| :ref:`String<class_String>` | :ref:`animation<class_AnimationNodeAnimation_property_animation>` | ``""`` |
|
||||
+-----------------------------+-------------------------------------------------------------------+--------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeAnimation_property_animation:
|
||||
|
||||
- :ref:`String<class_String>` **animation**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``""`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_animation(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_animation() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Animación para usar como salida. Es una de las animaciones proporcionadas por :ref:`AnimationTree.anim_player<class_AnimationTree_property_anim_player>`.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,56 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeBlend2.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeBlend2:
|
||||
|
||||
AnimationNodeBlend2
|
||||
===================
|
||||
|
||||
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Mezcla dos animaciones linealmente dentro de un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Un recurso para añadir a un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. Mezcla dos animaciones linealmente basadas en un valor de cantidad en el rango de ``[0.0, 1.0]``.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
|
||||
|
||||
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__
|
||||
|
||||
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------+------------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`sync<class_AnimationNodeBlend2_property_sync>` | ``false`` |
|
||||
+-------------------------+------------------------------------------------------+-----------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeBlend2_property_sync:
|
||||
|
||||
- :ref:`bool<class_bool>` **sync**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_use_sync(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | is_using_sync() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Si ``true``, establece la optimización ``optimization`` a ``false`` al llamar al :ref:`AnimationNode.blend_input<class_AnimationNode_method_blend_input>`, obligando a las animaciones mezcladas a actualizar cada fotograma.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,60 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeBlend3.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeBlend3:
|
||||
|
||||
AnimationNodeBlend3
|
||||
===================
|
||||
|
||||
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Mezcla dos de tres animaciones linealmente dentro de un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Un recurso para añadir a un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. Mezcla dos animaciones juntas linealmente de tres basadas en un valor en el rango de ``[-1.0, 1.0]``.
|
||||
|
||||
Este nodo tiene tres entradas:
|
||||
|
||||
- La animación base
|
||||
|
||||
- Una - animación de mezcla para mezclar cuando la cantidad de mezcla está en el rango de ``[-1.0, 0.0]``.
|
||||
|
||||
- Una + animación de mezcla para mezclar cuando la cantidad de mezcla está en el rango de ``[0.0, 1.0]``
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/animation/animation_tree`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------+------------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`sync<class_AnimationNodeBlend3_property_sync>` | ``false`` |
|
||||
+-------------------------+------------------------------------------------------+-----------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeBlend3_property_sync:
|
||||
|
||||
- :ref:`bool<class_bool>` **sync**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_use_sync(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | is_using_sync() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Si ``true``, establece la optimización ``optimization`` a ``false`` al llamar al :ref:`AnimationNode.blend_input<class_AnimationNode_method_blend_input>`, obligando a las animaciones mezcladas a actualizar cada fotograma.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,188 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeBlendSpace1D.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D:
|
||||
|
||||
AnimationNodeBlendSpace1D
|
||||
=========================
|
||||
|
||||
**Inherits:** :ref:`AnimationRootNode<class_AnimationRootNode>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Mezcla linealmente entre dos de cualquier número de :ref:`AnimationNode<class_AnimationNode>` de cualquier tipo colocado en un eje virtual.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Un recurso para añadir a un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
Es un eje virtual en el que puedes añadir cualquier tipo de :ref:`AnimationNode<class_AnimationNode>` usando el :ref:`add_blend_point<class_AnimationNodeBlendSpace1D_method_add_blend_point>`.
|
||||
|
||||
Produce la mezcla lineal de los dos :ref:`AnimationNode<class_AnimationNode>`\ s más cercana al valor actual del nodo.
|
||||
|
||||
Puedes establecer las extensiones del eje usando el :ref:`min_space<class_AnimationNodeBlendSpace1D_property_min_space>` y el :ref:`max_space<class_AnimationNodeBlendSpace1D_property_max_space>`.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/animation/animation_tree`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------+--------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`max_space<class_AnimationNodeBlendSpace1D_property_max_space>` | ``1.0`` |
|
||||
+-----------------------------+--------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`min_space<class_AnimationNodeBlendSpace1D_property_min_space>` | ``-1.0`` |
|
||||
+-----------------------------+--------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`snap<class_AnimationNodeBlendSpace1D_property_snap>` | ``0.1`` |
|
||||
+-----------------------------+--------------------------------------------------------------------------+-------------+
|
||||
| :ref:`String<class_String>` | :ref:`value_label<class_AnimationNodeBlendSpace1D_property_value_label>` | ``"value"`` |
|
||||
+-----------------------------+--------------------------------------------------------------------------+-------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_blend_point<class_AnimationNodeBlendSpace1D_method_add_blend_point>` **(** :ref:`AnimationRootNode<class_AnimationRootNode>` node, :ref:`float<class_float>` pos, :ref:`int<class_int>` at_index=-1 **)** |
|
||||
+---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_blend_point_count<class_AnimationNodeBlendSpace1D_method_get_blend_point_count>` **(** **)** |const| |
|
||||
+---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AnimationRootNode<class_AnimationRootNode>` | :ref:`get_blend_point_node<class_AnimationNodeBlendSpace1D_method_get_blend_point_node>` **(** :ref:`int<class_int>` point **)** |const| |
|
||||
+---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_blend_point_position<class_AnimationNodeBlendSpace1D_method_get_blend_point_position>` **(** :ref:`int<class_int>` point **)** |const| |
|
||||
+---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_blend_point<class_AnimationNodeBlendSpace1D_method_remove_blend_point>` **(** :ref:`int<class_int>` point **)** |
|
||||
+---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_blend_point_node<class_AnimationNodeBlendSpace1D_method_set_blend_point_node>` **(** :ref:`int<class_int>` point, :ref:`AnimationRootNode<class_AnimationRootNode>` node **)** |
|
||||
+---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_blend_point_position<class_AnimationNodeBlendSpace1D_method_set_blend_point_position>` **(** :ref:`int<class_int>` point, :ref:`float<class_float>` pos **)** |
|
||||
+---------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D_property_max_space:
|
||||
|
||||
- :ref:`float<class_float>` **max_space**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_max_space(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_max_space() |
|
||||
+-----------+----------------------+
|
||||
|
||||
El límite superior del eje del espacio de mezcla para la posición de los puntos. Ver :ref:`add_blend_point<class_AnimationNodeBlendSpace1D_method_add_blend_point>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D_property_min_space:
|
||||
|
||||
- :ref:`float<class_float>` **min_space**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``-1.0`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_min_space(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_min_space() |
|
||||
+-----------+----------------------+
|
||||
|
||||
El límite inferior del eje del espacio de mezcla para la posición de los puntos. Ver :ref:`add_blend_point<class_AnimationNodeBlendSpace1D_method_add_blend_point>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D_property_snap:
|
||||
|
||||
- :ref:`float<class_float>` **snap**
|
||||
|
||||
+-----------+-----------------+
|
||||
| *Default* | ``0.1`` |
|
||||
+-----------+-----------------+
|
||||
| *Setter* | set_snap(value) |
|
||||
+-----------+-----------------+
|
||||
| *Getter* | get_snap() |
|
||||
+-----------+-----------------+
|
||||
|
||||
Incremento de la posición a la que se ajusta cuando se mueve un punto en el eje.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D_property_value_label:
|
||||
|
||||
- :ref:`String<class_String>` **value_label**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``"value"`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_value_label(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_value_label() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Etiqueta del eje virtual del espacio de mezcla.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D_method_add_blend_point:
|
||||
|
||||
- void **add_blend_point** **(** :ref:`AnimationRootNode<class_AnimationRootNode>` node, :ref:`float<class_float>` pos, :ref:`int<class_int>` at_index=-1 **)**
|
||||
|
||||
Añade un nuevo punto que representa un ``node`` en el eje virtual en una posición dada fijada por ``pos``. Se puede insertar en un índice específico usando el argumento ``at_index``. Si utilizas el valor por defecto de ``at_index``, el punto se inserta al final del array de puntos de mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D_method_get_blend_point_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_blend_point_count** **(** **)** |const|
|
||||
|
||||
Devuelve el número de puntos en el eje de la mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D_method_get_blend_point_node:
|
||||
|
||||
- :ref:`AnimationRootNode<class_AnimationRootNode>` **get_blend_point_node** **(** :ref:`int<class_int>` point **)** |const|
|
||||
|
||||
Devuelve el :ref:`AnimationNode<class_AnimationNode>` referenciado por el punto en el índice ``point``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D_method_get_blend_point_position:
|
||||
|
||||
- :ref:`float<class_float>` **get_blend_point_position** **(** :ref:`int<class_int>` point **)** |const|
|
||||
|
||||
Devuelve la posición del punto en el índice ``point``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D_method_remove_blend_point:
|
||||
|
||||
- void **remove_blend_point** **(** :ref:`int<class_int>` point **)**
|
||||
|
||||
Elimina el punto en el índice ``point`` del eje de la mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D_method_set_blend_point_node:
|
||||
|
||||
- void **set_blend_point_node** **(** :ref:`int<class_int>` point, :ref:`AnimationRootNode<class_AnimationRootNode>` node **)**
|
||||
|
||||
Cambia el :ref:`AnimationNode<class_AnimationNode>` al que se refiere el punto en el índice ``point``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace1D_method_set_blend_point_position:
|
||||
|
||||
- void **set_blend_point_position** **(** :ref:`int<class_int>` point, :ref:`float<class_float>` pos **)**
|
||||
|
||||
Actualiza la posición del punto en el índice ``point`` en el eje de la mezcla.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,310 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeBlendSpace2D.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D:
|
||||
|
||||
AnimationNodeBlendSpace2D
|
||||
=========================
|
||||
|
||||
**Inherits:** :ref:`AnimationRootNode<class_AnimationRootNode>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Se mezcla linealmente entre tres :ref:`AnimationNode<class_AnimationNode>` de cualquier tipo colocados en un espacio 2D.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Un recurso para añadir a un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
Este nodo te permite mezclar linealmente entre tres animaciones usando un peso :ref:`Vector2<class_Vector2>`.
|
||||
|
||||
Puedes añadir vértices al espacio de mezcla con :ref:`add_blend_point<class_AnimationNodeBlendSpace2D_method_add_blend_point>` y triangularlo automáticamente estableciendo :ref:`auto_triangles<class_AnimationNodeBlendSpace2D_property_auto_triangles>` a ``true``. De lo contrario, usa :ref:`add_triangle<class_AnimationNodeBlendSpace2D_method_add_triangle>` y :ref:`remove_triangle<class_AnimationNodeBlendSpace2D_method_remove_triangle>` para crear el espacio de mezcla a mano.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
|
||||
|
||||
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`auto_triangles<class_AnimationNodeBlendSpace2D_property_auto_triangles>` | ``true`` |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`BlendMode<enum_AnimationNodeBlendSpace2D_BlendMode>` | :ref:`blend_mode<class_AnimationNodeBlendSpace2D_property_blend_mode>` | ``0`` |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`max_space<class_AnimationNodeBlendSpace2D_property_max_space>` | ``Vector2( 1, 1 )`` |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`min_space<class_AnimationNodeBlendSpace2D_property_min_space>` | ``Vector2( -1, -1 )`` |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`snap<class_AnimationNodeBlendSpace2D_property_snap>` | ``Vector2( 0.1, 0.1 )`` |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`x_label<class_AnimationNodeBlendSpace2D_property_x_label>` | ``"x"`` |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`y_label<class_AnimationNodeBlendSpace2D_property_y_label>` | ``"y"`` |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+-------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_blend_point<class_AnimationNodeBlendSpace2D_method_add_blend_point>` **(** :ref:`AnimationRootNode<class_AnimationRootNode>` node, :ref:`Vector2<class_Vector2>` pos, :ref:`int<class_int>` at_index=-1 **)** |
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_triangle<class_AnimationNodeBlendSpace2D_method_add_triangle>` **(** :ref:`int<class_int>` x, :ref:`int<class_int>` y, :ref:`int<class_int>` z, :ref:`int<class_int>` at_index=-1 **)** |
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_blend_point_count<class_AnimationNodeBlendSpace2D_method_get_blend_point_count>` **(** **)** |const| |
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AnimationRootNode<class_AnimationRootNode>` | :ref:`get_blend_point_node<class_AnimationNodeBlendSpace2D_method_get_blend_point_node>` **(** :ref:`int<class_int>` point **)** |const| |
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`get_blend_point_position<class_AnimationNodeBlendSpace2D_method_get_blend_point_position>` **(** :ref:`int<class_int>` point **)** |const| |
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_triangle_count<class_AnimationNodeBlendSpace2D_method_get_triangle_count>` **(** **)** |const| |
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_triangle_point<class_AnimationNodeBlendSpace2D_method_get_triangle_point>` **(** :ref:`int<class_int>` triangle, :ref:`int<class_int>` point **)** |
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_blend_point<class_AnimationNodeBlendSpace2D_method_remove_blend_point>` **(** :ref:`int<class_int>` point **)** |
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_triangle<class_AnimationNodeBlendSpace2D_method_remove_triangle>` **(** :ref:`int<class_int>` triangle **)** |
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_blend_point_node<class_AnimationNodeBlendSpace2D_method_set_blend_point_node>` **(** :ref:`int<class_int>` point, :ref:`AnimationRootNode<class_AnimationRootNode>` node **)** |
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_blend_point_position<class_AnimationNodeBlendSpace2D_method_set_blend_point_position>` **(** :ref:`int<class_int>` point, :ref:`Vector2<class_Vector2>` pos **)** |
|
||||
+---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_signal_triangles_updated:
|
||||
|
||||
- **triangles_updated** **(** **)**
|
||||
|
||||
Emitida cada vez que los triángulos del espacio de mezcla se crean, se eliminan, o cuando uno de sus vértices cambia de posición.
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AnimationNodeBlendSpace2D_BlendMode:
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_constant_BLEND_MODE_INTERPOLATED:
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_constant_BLEND_MODE_DISCRETE:
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_constant_BLEND_MODE_DISCRETE_CARRY:
|
||||
|
||||
enum **BlendMode**:
|
||||
|
||||
- **BLEND_MODE_INTERPOLATED** = **0** --- La interpolación entre las animaciones es lineal.
|
||||
|
||||
- **BLEND_MODE_DISCRETE** = **1** --- El espacio de mezcla reproduce la animación del nodo más cercano a la posición de mezcla. Es útil para las animaciones 2D fotograma a fotograma.
|
||||
|
||||
- **BLEND_MODE_DISCRETE_CARRY** = **2** --- Similar a :ref:`BLEND_MODE_DISCRETE<class_AnimationNodeBlendSpace2D_constant_BLEND_MODE_DISCRETE>`, pero inicia la nueva animación en la posición de reproducción de la última animación.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_property_auto_triangles:
|
||||
|
||||
- :ref:`bool<class_bool>` **auto_triangles**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_auto_triangles(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_auto_triangles() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
Si ``true``, el espacio de mezcla se triangula automáticamente. La malla se actualiza cada vez que añades o eliminas puntos con :ref:`add_blend_point<class_AnimationNodeBlendSpace2D_method_add_blend_point>` y :ref:`remove_blend_point<class_AnimationNodeBlendSpace2D_method_remove_blend_point>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_property_blend_mode:
|
||||
|
||||
- :ref:`BlendMode<enum_AnimationNodeBlendSpace2D_BlendMode>` **blend_mode**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_blend_mode(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_blend_mode() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Controla la interpolación entre las animaciones. Ver las constantes de :ref:`BlendMode<enum_AnimationNodeBlendSpace2D_BlendMode>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_property_max_space:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **max_space**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``Vector2( 1, 1 )`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_max_space(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_max_space() |
|
||||
+-----------+----------------------+
|
||||
|
||||
El límite superior de los ejes X e Y del espacio de mezcla para la posición de los puntos. Ver :ref:`add_blend_point<class_AnimationNodeBlendSpace2D_method_add_blend_point>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_property_min_space:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **min_space**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``Vector2( -1, -1 )`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_min_space(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_min_space() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
El límite inferior de los ejes X e Y del espacio de mezcla para la posición de los puntos. Ver :ref:`add_blend_point<class_AnimationNodeBlendSpace2D_method_add_blend_point>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_property_snap:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **snap**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``Vector2( 0.1, 0.1 )`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_snap(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_snap() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
Incremento de la posición a la que se ajusta cuando se mueve un punto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_property_x_label:
|
||||
|
||||
- :ref:`String<class_String>` **x_label**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``"x"`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_x_label(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | get_x_label() |
|
||||
+-----------+--------------------+
|
||||
|
||||
Nombre del eje X del espacio de la mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_property_y_label:
|
||||
|
||||
- :ref:`String<class_String>` **y_label**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``"y"`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_y_label(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | get_y_label() |
|
||||
+-----------+--------------------+
|
||||
|
||||
El nombre del eje Y del espacio de mezcla.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_method_add_blend_point:
|
||||
|
||||
- void **add_blend_point** **(** :ref:`AnimationRootNode<class_AnimationRootNode>` node, :ref:`Vector2<class_Vector2>` pos, :ref:`int<class_int>` at_index=-1 **)**
|
||||
|
||||
Añade un nuevo punto que representa un nodo ``pos`` en la posición establecida por ``pos``. Se puede insertar en un índice específico usando el argumento ``at_index``. Si utilizas el valor por defecto de ``at_index``, el punto se inserta al final del array de puntos de mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_method_add_triangle:
|
||||
|
||||
- void **add_triangle** **(** :ref:`int<class_int>` x, :ref:`int<class_int>` y, :ref:`int<class_int>` z, :ref:`int<class_int>` at_index=-1 **)**
|
||||
|
||||
Crea un nuevo triángulo usando tres puntos ``x``, ``y``, y ``z``. Los triángulos pueden superponerse. Puedes insertar el triángulo en un índice específico usando el argumento ``at_index``. Si utilizas el valor por defecto de ``at_index``, el punto se inserta al final del array de puntos de mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_method_get_blend_point_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_blend_point_count** **(** **)** |const|
|
||||
|
||||
Devuelve el número de puntos en el espacio de mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_method_get_blend_point_node:
|
||||
|
||||
- :ref:`AnimationRootNode<class_AnimationRootNode>` **get_blend_point_node** **(** :ref:`int<class_int>` point **)** |const|
|
||||
|
||||
Devuelve el :ref:`AnimationRootNode<class_AnimationRootNode>` referenciado por el punto en el índice ``point``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_method_get_blend_point_position:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **get_blend_point_position** **(** :ref:`int<class_int>` point **)** |const|
|
||||
|
||||
Devuelve la posición del punto en el índice ``point``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_method_get_triangle_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_triangle_count** **(** **)** |const|
|
||||
|
||||
Devuelve el número de triángulos en el espacio de mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_method_get_triangle_point:
|
||||
|
||||
- :ref:`int<class_int>` **get_triangle_point** **(** :ref:`int<class_int>` triangle, :ref:`int<class_int>` point **)**
|
||||
|
||||
Devuelve la posición del punto en el índice ``point`` en el triángulo del índice ``triangle``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_method_remove_blend_point:
|
||||
|
||||
- void **remove_blend_point** **(** :ref:`int<class_int>` point **)**
|
||||
|
||||
Elimina el punto en el índice ``point`` del espacio de mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_method_remove_triangle:
|
||||
|
||||
- void **remove_triangle** **(** :ref:`int<class_int>` triangle **)**
|
||||
|
||||
Elimina el triángulo en el índice ``triangle`` del espacio de mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_method_set_blend_point_node:
|
||||
|
||||
- void **set_blend_point_node** **(** :ref:`int<class_int>` point, :ref:`AnimationRootNode<class_AnimationRootNode>` node **)**
|
||||
|
||||
Cambia el :ref:`AnimationNode<class_AnimationNode>` al que se refiere el punto en el índice ``point``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendSpace2D_method_set_blend_point_position:
|
||||
|
||||
- void **set_blend_point_position** **(** :ref:`int<class_int>` point, :ref:`Vector2<class_Vector2>` pos **)**
|
||||
|
||||
Actualiza la posición del punto en el índice ``point`` en el eje de la mezcla.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,175 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeBlendTree.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeBlendTree:
|
||||
|
||||
AnimationNodeBlendTree
|
||||
======================
|
||||
|
||||
**Inherits:** :ref:`AnimationRootNode<class_AnimationRootNode>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
:ref:`AnimationTree<class_AnimationTree>` es un recurso de nodos que contiene muchos nodos de tipo mezcla.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Este nodo puede contener un subárbol de cualquier otro tipo de nodos de mezcla, como mix, blend2, blend3, one shot, etc. Esta es una de los nodos raíces más utilizados.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/animation/animation_tree`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------------+-------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`graph_offset<class_AnimationNodeBlendTree_property_graph_offset>` | ``Vector2( 0, 0 )`` |
|
||||
+-------------------------------+-------------------------------------------------------------------------+---------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_node<class_AnimationNodeBlendTree_method_add_node>` **(** :ref:`String<class_String>` name, :ref:`AnimationNode<class_AnimationNode>` node, :ref:`Vector2<class_Vector2>` position=Vector2( 0, 0 ) **)** |
|
||||
+-------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`connect_node<class_AnimationNodeBlendTree_method_connect_node>` **(** :ref:`String<class_String>` input_node, :ref:`int<class_int>` input_index, :ref:`String<class_String>` output_node **)** |
|
||||
+-------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`disconnect_node<class_AnimationNodeBlendTree_method_disconnect_node>` **(** :ref:`String<class_String>` input_node, :ref:`int<class_int>` input_index **)** |
|
||||
+-------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AnimationNode<class_AnimationNode>` | :ref:`get_node<class_AnimationNodeBlendTree_method_get_node>` **(** :ref:`String<class_String>` name **)** |const| |
|
||||
+-------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`get_node_position<class_AnimationNodeBlendTree_method_get_node_position>` **(** :ref:`String<class_String>` name **)** |const| |
|
||||
+-------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`has_node<class_AnimationNodeBlendTree_method_has_node>` **(** :ref:`String<class_String>` name **)** |const| |
|
||||
+-------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_node<class_AnimationNodeBlendTree_method_remove_node>` **(** :ref:`String<class_String>` name **)** |
|
||||
+-------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`rename_node<class_AnimationNodeBlendTree_method_rename_node>` **(** :ref:`String<class_String>` name, :ref:`String<class_String>` new_name **)** |
|
||||
+-------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_node_position<class_AnimationNodeBlendTree_method_set_node_position>` **(** :ref:`String<class_String>` name, :ref:`Vector2<class_Vector2>` position **)** |
|
||||
+-------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Constantes
|
||||
--------------------
|
||||
|
||||
.. _class_AnimationNodeBlendTree_constant_CONNECTION_OK:
|
||||
|
||||
.. _class_AnimationNodeBlendTree_constant_CONNECTION_ERROR_NO_INPUT:
|
||||
|
||||
.. _class_AnimationNodeBlendTree_constant_CONNECTION_ERROR_NO_INPUT_INDEX:
|
||||
|
||||
.. _class_AnimationNodeBlendTree_constant_CONNECTION_ERROR_NO_OUTPUT:
|
||||
|
||||
.. _class_AnimationNodeBlendTree_constant_CONNECTION_ERROR_SAME_NODE:
|
||||
|
||||
.. _class_AnimationNodeBlendTree_constant_CONNECTION_ERROR_CONNECTION_EXISTS:
|
||||
|
||||
- **CONNECTION_OK** = **0** --- La conexion tuvo éxito.
|
||||
|
||||
- **CONNECTION_ERROR_NO_INPUT** = **1** --- El nodo entrada es ``null``.
|
||||
|
||||
- **CONNECTION_ERROR_NO_INPUT_INDEX** = **2** --- El puerto de entrada especificado está fuera de rango.
|
||||
|
||||
- **CONNECTION_ERROR_NO_OUTPUT** = **3** --- El nodo salida es ``null``.
|
||||
|
||||
- **CONNECTION_ERROR_SAME_NODE** = **4** --- Los nodos de entrada y salida son los mismos.
|
||||
|
||||
- **CONNECTION_ERROR_CONNECTION_EXISTS** = **5** --- La conexion ya existe.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeBlendTree_property_graph_offset:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **graph_offset**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``Vector2( 0, 0 )`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_graph_offset(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_graph_offset() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
El dezplazamiento global de todos los subnodos.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeBlendTree_method_add_node:
|
||||
|
||||
- void **add_node** **(** :ref:`String<class_String>` name, :ref:`AnimationNode<class_AnimationNode>` node, :ref:`Vector2<class_Vector2>` position=Vector2( 0, 0 ) **)**
|
||||
|
||||
Añade un :ref:`AnimationNode<class_AnimationNode>` en la\ ``position`` dada. El ``name`` se utiliza para identificar el subnodo creado a posteriori.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendTree_method_connect_node:
|
||||
|
||||
- void **connect_node** **(** :ref:`String<class_String>` input_node, :ref:`int<class_int>` input_index, :ref:`String<class_String>` output_node **)**
|
||||
|
||||
Conecta la salida de un :ref:`AnimationNode<class_AnimationNode>` como entrada de otro :ref:`AnimationNode<class_AnimationNode>`, en el puerto de entrada especificado por ``input_index``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendTree_method_disconnect_node:
|
||||
|
||||
- void **disconnect_node** **(** :ref:`String<class_String>` input_node, :ref:`int<class_int>` input_index **)**
|
||||
|
||||
Desconecta el nodo conectado a la entrada especificada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendTree_method_get_node:
|
||||
|
||||
- :ref:`AnimationNode<class_AnimationNode>` **get_node** **(** :ref:`String<class_String>` name **)** |const|
|
||||
|
||||
Devuelve el subnodo con el ``name`` especificado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendTree_method_get_node_position:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **get_node_position** **(** :ref:`String<class_String>` name **)** |const|
|
||||
|
||||
Devuelve la posición del subnodo con el ``name`` especificado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendTree_method_has_node:
|
||||
|
||||
- :ref:`bool<class_bool>` **has_node** **(** :ref:`String<class_String>` name **)** |const|
|
||||
|
||||
Devuelve ``true`` si existe un subnodo con el ``name`` especificado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendTree_method_remove_node:
|
||||
|
||||
- void **remove_node** **(** :ref:`String<class_String>` name **)**
|
||||
|
||||
Elimina un subnodo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendTree_method_rename_node:
|
||||
|
||||
- void **rename_node** **(** :ref:`String<class_String>` name, :ref:`String<class_String>` new_name **)**
|
||||
|
||||
Cambia el nombre de un subnodo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeBlendTree_method_set_node_position:
|
||||
|
||||
- void **set_node_position** **(** :ref:`String<class_String>` name, :ref:`Vector2<class_Vector2>` position **)**
|
||||
|
||||
Modifica la posición de un subnodo.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,175 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeOneShot.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeOneShot:
|
||||
|
||||
AnimationNodeOneShot
|
||||
====================
|
||||
|
||||
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Reproduce una animacion una vez en :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Un recurso para añadir a un :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. Este nodo ejecutara una subanimacion y devolvera cuando termine. Mezcla de tiempos para desvanecer y aparecer pueden ser personalizados, incluido filtros.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
|
||||
|
||||
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`autorestart<class_AnimationNodeOneShot_property_autorestart>` | ``false`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`autorestart_delay<class_AnimationNodeOneShot_property_autorestart_delay>` | ``1.0`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`autorestart_random_delay<class_AnimationNodeOneShot_property_autorestart_random_delay>` | ``0.0`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`fadein_time<class_AnimationNodeOneShot_property_fadein_time>` | ``0.1`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`fadeout_time<class_AnimationNodeOneShot_property_fadeout_time>` | ``0.1`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`sync<class_AnimationNodeOneShot_property_sync>` | ``false`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------+-----------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`MixMode<enum_AnimationNodeOneShot_MixMode>` | :ref:`get_mix_mode<class_AnimationNodeOneShot_method_get_mix_mode>` **(** **)** |const| |
|
||||
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_mix_mode<class_AnimationNodeOneShot_method_set_mix_mode>` **(** :ref:`MixMode<enum_AnimationNodeOneShot_MixMode>` mode **)** |
|
||||
+---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AnimationNodeOneShot_MixMode:
|
||||
|
||||
.. _class_AnimationNodeOneShot_constant_MIX_MODE_BLEND:
|
||||
|
||||
.. _class_AnimationNodeOneShot_constant_MIX_MODE_ADD:
|
||||
|
||||
enum **MixMode**:
|
||||
|
||||
- **MIX_MODE_BLEND** = **0**
|
||||
|
||||
- **MIX_MODE_ADD** = **1**
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeOneShot_property_autorestart:
|
||||
|
||||
- :ref:`bool<class_bool>` **autorestart**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_autorestart(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | has_autorestart() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Si ``true``, las subanimaciones se reiniciaran automaticamente despues de acabar.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeOneShot_property_autorestart_delay:
|
||||
|
||||
- :ref:`float<class_float>` **autorestart_delay**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_autorestart_delay(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_autorestart_delay() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
El retardo con el cual un reinicio automatico es lanzado, en segundos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeOneShot_property_autorestart_random_delay:
|
||||
|
||||
- :ref:`float<class_float>` **autorestart_random_delay**
|
||||
|
||||
+-----------+-------------------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-------------------------------------+
|
||||
| *Setter* | set_autorestart_random_delay(value) |
|
||||
+-----------+-------------------------------------+
|
||||
| *Getter* | get_autorestart_random_delay() |
|
||||
+-----------+-------------------------------------+
|
||||
|
||||
Si :ref:`autorestart<class_AnimationNodeOneShot_property_autorestart>` es ``true``, un retardo aleatorio adicional (en segundos) entre 0 y este valor sera añadido al [member autorestart_delay.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeOneShot_property_fadein_time:
|
||||
|
||||
- :ref:`float<class_float>` **fadein_time**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``0.1`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_fadein_time(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_fadein_time() |
|
||||
+-----------+------------------------+
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeOneShot_property_fadeout_time:
|
||||
|
||||
- :ref:`float<class_float>` **fadeout_time**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``0.1`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_fadeout_time(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_fadeout_time() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeOneShot_property_sync:
|
||||
|
||||
- :ref:`bool<class_bool>` **sync**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_use_sync(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | is_using_sync() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeOneShot_method_get_mix_mode:
|
||||
|
||||
- :ref:`MixMode<enum_AnimationNodeOneShot_MixMode>` **get_mix_mode** **(** **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeOneShot_method_set_mix_mode:
|
||||
|
||||
- void **set_mix_mode** **(** :ref:`MixMode<enum_AnimationNodeOneShot_MixMode>` mode **)**
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,27 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeOutput.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeOutput:
|
||||
|
||||
AnimationNodeOutput
|
||||
===================
|
||||
|
||||
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Nodo de salida generica para ser añadido a :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
|
||||
|
||||
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__
|
||||
|
||||
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,271 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeStateMachine.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeStateMachine:
|
||||
|
||||
AnimationNodeStateMachine
|
||||
=========================
|
||||
|
||||
**Inherits:** :ref:`AnimationRootNode<class_AnimationRootNode>` **<** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Maquina de estado para el control de animaciones.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Contiene multiples nodos representando los estados de la animacion, conectados en un grafico. Las transiciones de nodos puedes ser configurado para ocurrir automaticamente o por codigo, usando un algoritmo de shortest-path(ruta mas corta). Recupera el objeto :ref:`AnimationNodeStateMachinePlayback<class_AnimationNodeStateMachinePlayback>` desde el nodo de :ref:`AnimationTree<class_AnimationTree>` para controlarlo programaticamente.
|
||||
|
||||
\ **Ejemplo:**\
|
||||
|
||||
::
|
||||
|
||||
var maquina_estado = $AnimationTree.get("paratamers/playback")
|
||||
maquina_estado.travel("algun estado" )
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/animation/animation_tree`
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_node<class_AnimationNodeStateMachine_method_add_node>` **(** :ref:`String<class_String>` name, :ref:`AnimationNode<class_AnimationNode>` node, :ref:`Vector2<class_Vector2>` position=Vector2( 0, 0 ) **)** |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_transition<class_AnimationNodeStateMachine_method_add_transition>` **(** :ref:`String<class_String>` from, :ref:`String<class_String>` to, :ref:`AnimationNodeStateMachineTransition<class_AnimationNodeStateMachineTransition>` transition **)** |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_end_node<class_AnimationNodeStateMachine_method_get_end_node>` **(** **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`get_graph_offset<class_AnimationNodeStateMachine_method_get_graph_offset>` **(** **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AnimationNode<class_AnimationNode>` | :ref:`get_node<class_AnimationNodeStateMachine_method_get_node>` **(** :ref:`String<class_String>` name **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_node_name<class_AnimationNodeStateMachine_method_get_node_name>` **(** :ref:`AnimationNode<class_AnimationNode>` node **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`get_node_position<class_AnimationNodeStateMachine_method_get_node_position>` **(** :ref:`String<class_String>` name **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_start_node<class_AnimationNodeStateMachine_method_get_start_node>` **(** **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AnimationNodeStateMachineTransition<class_AnimationNodeStateMachineTransition>` | :ref:`get_transition<class_AnimationNodeStateMachine_method_get_transition>` **(** :ref:`int<class_int>` idx **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_transition_count<class_AnimationNodeStateMachine_method_get_transition_count>` **(** **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_transition_from<class_AnimationNodeStateMachine_method_get_transition_from>` **(** :ref:`int<class_int>` idx **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_transition_to<class_AnimationNodeStateMachine_method_get_transition_to>` **(** :ref:`int<class_int>` idx **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`has_node<class_AnimationNodeStateMachine_method_has_node>` **(** :ref:`String<class_String>` name **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`has_transition<class_AnimationNodeStateMachine_method_has_transition>` **(** :ref:`String<class_String>` from, :ref:`String<class_String>` to **)** |const| |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_node<class_AnimationNodeStateMachine_method_remove_node>` **(** :ref:`String<class_String>` name **)** |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_transition<class_AnimationNodeStateMachine_method_remove_transition>` **(** :ref:`String<class_String>` from, :ref:`String<class_String>` to **)** |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_transition_by_index<class_AnimationNodeStateMachine_method_remove_transition_by_index>` **(** :ref:`int<class_int>` idx **)** |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`rename_node<class_AnimationNodeStateMachine_method_rename_node>` **(** :ref:`String<class_String>` name, :ref:`String<class_String>` new_name **)** |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`replace_node<class_AnimationNodeStateMachine_method_replace_node>` **(** :ref:`String<class_String>` name, :ref:`AnimationNode<class_AnimationNode>` node **)** |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_end_node<class_AnimationNodeStateMachine_method_set_end_node>` **(** :ref:`String<class_String>` name **)** |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_graph_offset<class_AnimationNodeStateMachine_method_set_graph_offset>` **(** :ref:`Vector2<class_Vector2>` offset **)** |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_node_position<class_AnimationNodeStateMachine_method_set_node_position>` **(** :ref:`String<class_String>` name, :ref:`Vector2<class_Vector2>` position **)** |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_start_node<class_AnimationNodeStateMachine_method_set_start_node>` **(** :ref:`String<class_String>` name **)** |
|
||||
+---------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_add_node:
|
||||
|
||||
- void **add_node** **(** :ref:`String<class_String>` name, :ref:`AnimationNode<class_AnimationNode>` node, :ref:`Vector2<class_Vector2>` position=Vector2( 0, 0 ) **)**
|
||||
|
||||
Añade un nuevo nodo al grafico. La ``position`` es usado para la visualizacion en el editor.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_add_transition:
|
||||
|
||||
- void **add_transition** **(** :ref:`String<class_String>` from, :ref:`String<class_String>` to, :ref:`AnimationNodeStateMachineTransition<class_AnimationNodeStateMachineTransition>` transition **)**
|
||||
|
||||
Añade una transicion entre los nodos dados.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_get_end_node:
|
||||
|
||||
- :ref:`String<class_String>` **get_end_node** **(** **)** |const|
|
||||
|
||||
Devuelve el nodo final de un grafico.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_get_graph_offset:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **get_graph_offset** **(** **)** |const|
|
||||
|
||||
Devuelve el dezplazamiento del dibujo de un grafico. Utilizado para visualizaciones en el editor.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_get_node:
|
||||
|
||||
- :ref:`AnimationNode<class_AnimationNode>` **get_node** **(** :ref:`String<class_String>` name **)** |const|
|
||||
|
||||
Devuelve el nodo animacion con el nombre dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_get_node_name:
|
||||
|
||||
- :ref:`String<class_String>` **get_node_name** **(** :ref:`AnimationNode<class_AnimationNode>` node **)** |const|
|
||||
|
||||
Devuelve el node del nombre de la animacion dada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_get_node_position:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **get_node_position** **(** :ref:`String<class_String>` name **)** |const|
|
||||
|
||||
Devuelve las coordenadas del nodo dado. Util para visualizaciones en el editor.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_get_start_node:
|
||||
|
||||
- :ref:`String<class_String>` **get_start_node** **(** **)** |const|
|
||||
|
||||
Devuelve el nodo final de un grafico.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_get_transition:
|
||||
|
||||
- :ref:`AnimationNodeStateMachineTransition<class_AnimationNodeStateMachineTransition>` **get_transition** **(** :ref:`int<class_int>` idx **)** |const|
|
||||
|
||||
Devuelve la transicion dada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_get_transition_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_transition_count** **(** **)** |const|
|
||||
|
||||
Devuelve el numero de conexiones en el grafico.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_get_transition_from:
|
||||
|
||||
- :ref:`String<class_String>` **get_transition_from** **(** :ref:`int<class_int>` idx **)** |const|
|
||||
|
||||
Devuelve el nodo de comienzo de la transicion dada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_get_transition_to:
|
||||
|
||||
- :ref:`String<class_String>` **get_transition_to** **(** :ref:`int<class_int>` idx **)** |const|
|
||||
|
||||
Devuelve el nodo final de la transicion dada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_has_node:
|
||||
|
||||
- :ref:`bool<class_bool>` **has_node** **(** :ref:`String<class_String>` name **)** |const|
|
||||
|
||||
Devuelve ``true`` si el grafico contiene el nodo dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_has_transition:
|
||||
|
||||
- :ref:`bool<class_bool>` **has_transition** **(** :ref:`String<class_String>` from, :ref:`String<class_String>` to **)** |const|
|
||||
|
||||
Devuelve ``true`` si hay una transicion entre los nodos dados.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_remove_node:
|
||||
|
||||
- void **remove_node** **(** :ref:`String<class_String>` name **)**
|
||||
|
||||
Elimina el nodo dado desde un grafico.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_remove_transition:
|
||||
|
||||
- void **remove_transition** **(** :ref:`String<class_String>` from, :ref:`String<class_String>` to **)**
|
||||
|
||||
Elimina la transicion entre los dos nodos especificados.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_remove_transition_by_index:
|
||||
|
||||
- void **remove_transition_by_index** **(** :ref:`int<class_int>` idx **)**
|
||||
|
||||
Elimina la transicion dado un indice.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_rename_node:
|
||||
|
||||
- void **rename_node** **(** :ref:`String<class_String>` name, :ref:`String<class_String>` new_name **)**
|
||||
|
||||
Renombra en nodo dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_replace_node:
|
||||
|
||||
- void **replace_node** **(** :ref:`String<class_String>` name, :ref:`AnimationNode<class_AnimationNode>` node **)**
|
||||
|
||||
Replaces the node and keeps its transitions unchanged.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_set_end_node:
|
||||
|
||||
- void **set_end_node** **(** :ref:`String<class_String>` name **)**
|
||||
|
||||
Coloca el nodo dada como es punto final del grafico.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_set_graph_offset:
|
||||
|
||||
- void **set_graph_offset** **(** :ref:`Vector2<class_Vector2>` offset **)**
|
||||
|
||||
Coloca el desplazamiento de dibujo del grafico. Utilizado para visualizaciones en el editor.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_set_node_position:
|
||||
|
||||
- void **set_node_position** **(** :ref:`String<class_String>` name, :ref:`Vector2<class_Vector2>` position **)**
|
||||
|
||||
Coloca las coordenadas del nodo. Utilizado para las visualizaciones en el editor.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachine_method_set_start_node:
|
||||
|
||||
- void **set_start_node** **(** :ref:`String<class_String>` name **)**
|
||||
|
||||
Coloca el nodo dado como el punto de comienzo del grafico.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,126 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeStateMachinePlayback.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeStateMachinePlayback:
|
||||
|
||||
AnimationNodeStateMachinePlayback
|
||||
=================================
|
||||
|
||||
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Control de reproduccion para el :ref:`AnimationNodeStateMachine<class_AnimationNodeStateMachine>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Permite el control de los estados de maquina de :ref:`AnimationTree<class_AnimationTree>` creados con :ref:`AnimationNodeStateMachine<class_AnimationNodeStateMachine>`. Recupero con ``$AnimationTree.get("parameters/playback")``.
|
||||
|
||||
\ **Ejemplo**\
|
||||
|
||||
::
|
||||
|
||||
var maquina_estados = $AnimationTree.get("parameters/playback")
|
||||
maquina_estados.travel("algun_estado")
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/animation/animation_tree`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------+-------------------------+---------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | resource_local_to_scene | ``true`` (overrides :ref:`Resource<class_Resource_property_resource_local_to_scene>`) |
|
||||
+-------------------------+-------------------------+---------------------------------------------------------------------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_current_length<class_AnimationNodeStateMachinePlayback_method_get_current_length>` **(** **)** |const| |
|
||||
+-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :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:`PoolStringArray<class_PoolStringArray>` | :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:`start<class_AnimationNodeStateMachinePlayback_method_start>` **(** :ref:`String<class_String>` node **)** |
|
||||
+-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`stop<class_AnimationNodeStateMachinePlayback_method_stop>` **(** **)** |
|
||||
+-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`travel<class_AnimationNodeStateMachinePlayback_method_travel>` **(** :ref:`String<class_String>` to_node **)** |
|
||||
+-----------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeStateMachinePlayback_method_get_current_length:
|
||||
|
||||
- :ref:`float<class_float>` **get_current_length** **(** **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachinePlayback_method_get_current_node:
|
||||
|
||||
- :ref:`String<class_String>` **get_current_node** **(** **)** |const|
|
||||
|
||||
Devuelve el estado de la animacion que se esta reproduciendo actualmente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachinePlayback_method_get_current_play_position:
|
||||
|
||||
- :ref:`float<class_float>` **get_current_play_position** **(** **)** |const|
|
||||
|
||||
Returns the playback position within the current animation state.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachinePlayback_method_get_travel_path:
|
||||
|
||||
- :ref:`PoolStringArray<class_PoolStringArray>` **get_travel_path** **(** **)** |const|
|
||||
|
||||
Devuelve la ruta de viaje actual calculada internamente por el algorithmo A\*.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachinePlayback_method_is_playing:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_playing** **(** **)** |const|
|
||||
|
||||
Devuelve ``true`` si una animacion esta reproduciendose.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachinePlayback_method_start:
|
||||
|
||||
- void **start** **(** :ref:`String<class_String>` node **)**
|
||||
|
||||
Empieza a ejecutar la animacion dada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachinePlayback_method_stop:
|
||||
|
||||
- void **stop** **(** **)**
|
||||
|
||||
Para la animacion en ejecucion.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachinePlayback_method_travel:
|
||||
|
||||
- void **travel** **(** :ref:`String<class_String>` to_node **)**
|
||||
|
||||
Las transiciones desde el estado actual a otro, siguiendo la ruta mas corta.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,169 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeStateMachineTransition.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeStateMachineTransition:
|
||||
|
||||
AnimationNodeStateMachineTransition
|
||||
===================================
|
||||
|
||||
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/animation/animation_tree`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`String<class_String>` | :ref:`advance_condition<class_AnimationNodeStateMachineTransition_property_advance_condition>` | ``""`` |
|
||||
+------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`auto_advance<class_AnimationNodeStateMachineTransition_property_auto_advance>` | ``false`` |
|
||||
+------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`disabled<class_AnimationNodeStateMachineTransition_property_disabled>` | ``false`` |
|
||||
+------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`int<class_int>` | :ref:`priority<class_AnimationNodeStateMachineTransition_property_priority>` | ``1`` |
|
||||
+------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`SwitchMode<enum_AnimationNodeStateMachineTransition_SwitchMode>` | :ref:`switch_mode<class_AnimationNodeStateMachineTransition_property_switch_mode>` | ``0`` |
|
||||
+------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`xfade_time<class_AnimationNodeStateMachineTransition_property_xfade_time>` | ``0.0`` |
|
||||
+------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+-----------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_AnimationNodeStateMachineTransition_signal_advance_condition_changed:
|
||||
|
||||
- **advance_condition_changed** **(** **)**
|
||||
|
||||
Emitido cuando :ref:`advance_condition<class_AnimationNodeStateMachineTransition_property_advance_condition>` es cambiada.
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AnimationNodeStateMachineTransition_SwitchMode:
|
||||
|
||||
.. _class_AnimationNodeStateMachineTransition_constant_SWITCH_MODE_IMMEDIATE:
|
||||
|
||||
.. _class_AnimationNodeStateMachineTransition_constant_SWITCH_MODE_SYNC:
|
||||
|
||||
.. _class_AnimationNodeStateMachineTransition_constant_SWITCH_MODE_AT_END:
|
||||
|
||||
enum **SwitchMode**:
|
||||
|
||||
- **SWITCH_MODE_IMMEDIATE** = **0** --- Intercambia a el proximo estado inmediatamente. El actual estado terminara y se mezclara en el comienzo del nuevo.
|
||||
|
||||
- **SWITCH_MODE_SYNC** = **1** --- Intercambia a el proximo estado inmediatamente, pero buscara el nuevo estado a la reproduccion de la posicion del antiguo estado.
|
||||
|
||||
- **SWITCH_MODE_AT_END** = **2** --- Espera a que termine el actual estado en reproduccion, entonces intercambia con el principio de la proxima animacion.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeStateMachineTransition_property_advance_condition:
|
||||
|
||||
- :ref:`String<class_String>` **advance_condition**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``""`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_advance_condition(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_advance_condition() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
Turn on auto advance when this condition is set. The provided name will become a boolean parameter on the :ref:`AnimationTree<class_AnimationTree>` that can be controlled from code (see `#controlling-from-code <../tutorials/animation/animation_tree.html#controlling-from-code>`__ in :doc:`../tutorials/animation/animation_tree`). For example, if :ref:`AnimationTree.tree_root<class_AnimationTree_property_tree_root>` is an :ref:`AnimationNodeStateMachine<class_AnimationNodeStateMachine>` and :ref:`advance_condition<class_AnimationNodeStateMachineTransition_property_advance_condition>` is set to ``"idle"``:
|
||||
|
||||
::
|
||||
|
||||
$animation_tree["parameters/conditions/idle"] = is_on_floor and (linear_velocity.x == 0)
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachineTransition_property_auto_advance:
|
||||
|
||||
- :ref:`bool<class_bool>` **auto_advance**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_auto_advance(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | has_auto_advance() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
Enciende la transicion automaticamente cuando este estado es alcanzado. Esto funcion mejor con :ref:`SWITCH_MODE_AT_END<class_AnimationNodeStateMachineTransition_constant_SWITCH_MODE_AT_END>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachineTransition_property_disabled:
|
||||
|
||||
- :ref:`bool<class_bool>` **disabled**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_disabled(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | is_disabled() |
|
||||
+-----------+---------------------+
|
||||
|
||||
No utilices esta transicion durante :ref:`AnimationNodeStateMachinePlayback.travel<class_AnimationNodeStateMachinePlayback_method_travel>` o :ref:`auto_advance<class_AnimationNodeStateMachineTransition_property_auto_advance>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachineTransition_property_priority:
|
||||
|
||||
- :ref:`int<class_int>` **priority**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_priority(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_priority() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Transiciones de prioridad baja son preferidas cuando se viaja a traves de un arbol :ref:`AnimationNodeStateMachinePlayback.travel<class_AnimationNodeStateMachinePlayback_method_travel>` o :ref:`auto_advance<class_AnimationNodeStateMachineTransition_property_auto_advance>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachineTransition_property_switch_mode:
|
||||
|
||||
- :ref:`SwitchMode<enum_AnimationNodeStateMachineTransition_SwitchMode>` **switch_mode**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_switch_mode(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_switch_mode() |
|
||||
+-----------+------------------------+
|
||||
|
||||
El tipo de transicion.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeStateMachineTransition_property_xfade_time:
|
||||
|
||||
- :ref:`float<class_float>` **xfade_time**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_xfade_time(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_xfade_time() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
El tiempo de paso de este estado al siguiente.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,30 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeTimeScale.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeTimeScale:
|
||||
|
||||
AnimationNodeTimeScale
|
||||
======================
|
||||
|
||||
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Un nodo de animacion de tiempo escalada para ser utilizado con :ref:`AnimationTree<class_AnimationTree>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Permite escalar la velocidad de la animacion (o revertirla) en cualquiera de los nodos hijos. Colocandolo a 0 pausara la animacion.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
|
||||
|
||||
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,40 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeTimeSeek.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeTimeSeek:
|
||||
|
||||
AnimationNodeTimeSeek
|
||||
=====================
|
||||
|
||||
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Una nodo de animacion de busqueda de tiempo para ser usado con :ref:`AnimationTree<class_AnimationTree>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
This node can be used to cause a seek command to happen to any sub-children of the animation graph. Use this node type to play an :ref:`Animation<class_Animation>` from the start or a certain playback position inside the :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`. After setting the time and changing the animation playback, the seek node automatically goes into sleep mode on the next process frame by setting its ``seek_position`` value to ``-1.0``.
|
||||
|
||||
::
|
||||
|
||||
# Play child animation from the start.
|
||||
animation_tree.set("parameters/Seek/seek_position", 0.0)
|
||||
# Alternative syntax (same result as above).
|
||||
animation_tree["parameters/Seek/seek_position"] = 0.0
|
||||
|
||||
# Play child animation from 12 second timestamp.
|
||||
animation_tree.set("parameters/Seek/seek_position", 12.0)
|
||||
# Alternative syntax (same result as above).
|
||||
animation_tree["parameters/Seek/seek_position"] = 12.0
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../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.)`
|
||||
.. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
|
||||
@@ -1,112 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationNodeTransition.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationNodeTransition:
|
||||
|
||||
AnimationNodeTransition
|
||||
=======================
|
||||
|
||||
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Un nodo de transicion generica para :ref:`AnimationTree<class_AnimationTree>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Simple estado de maquina para casos que no requieren un :ref:`AnimationNodeStateMachine<class_AnimationNodeStateMachine>`. Las animaciones pueden ser conectadas a las salidas y tiempos de transicion pueden ser especificados.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`AnimationTree <../tutorials/animation/animation_tree>`
|
||||
|
||||
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__
|
||||
|
||||
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`int<class_int>` | :ref:`input_count<class_AnimationNodeTransition_property_input_count>` | ``0`` |
|
||||
+---------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`xfade_time<class_AnimationNodeTransition_property_xfade_time>` | ``0.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------+---------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_input_caption<class_AnimationNodeTransition_method_get_input_caption>` **(** :ref:`int<class_int>` input **)** |const| |
|
||||
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_input_set_as_auto_advance<class_AnimationNodeTransition_method_is_input_set_as_auto_advance>` **(** :ref:`int<class_int>` input **)** |const| |
|
||||
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_input_as_auto_advance<class_AnimationNodeTransition_method_set_input_as_auto_advance>` **(** :ref:`int<class_int>` input, :ref:`bool<class_bool>` enable **)** |
|
||||
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_input_caption<class_AnimationNodeTransition_method_set_input_caption>` **(** :ref:`int<class_int>` input, :ref:`String<class_String>` caption **)** |
|
||||
+-----------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeTransition_property_input_count:
|
||||
|
||||
- :ref:`int<class_int>` **input_count**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_enabled_inputs(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_enabled_inputs() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
El numero de puertos de entrada disponibles para este nodo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeTransition_property_xfade_time:
|
||||
|
||||
- :ref:`float<class_float>` **xfade_time**
|
||||
|
||||
+-----------+----------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+----------------------------+
|
||||
| *Setter* | set_cross_fade_time(value) |
|
||||
+-----------+----------------------------+
|
||||
| *Getter* | get_cross_fade_time() |
|
||||
+-----------+----------------------------+
|
||||
|
||||
Desvanecimiento en tiempo(en segundos) entre cada animacione conectada a las salidas.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimationNodeTransition_method_get_input_caption:
|
||||
|
||||
- :ref:`String<class_String>` **get_input_caption** **(** :ref:`int<class_int>` input **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeTransition_method_is_input_set_as_auto_advance:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_input_set_as_auto_advance** **(** :ref:`int<class_int>` input **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeTransition_method_set_input_as_auto_advance:
|
||||
|
||||
- void **set_input_as_auto_advance** **(** :ref:`int<class_int>` input, :ref:`bool<class_bool>` enable **)**
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationNodeTransition_method_set_input_caption:
|
||||
|
||||
- void **set_input_caption** **(** :ref:`int<class_int>` input, :ref:`String<class_String>` caption **)**
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,554 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationPlayer.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationPlayer:
|
||||
|
||||
AnimationPlayer
|
||||
===============
|
||||
|
||||
**Inherits:** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Contenedor y reproductor de recursos de :ref:`Animation<class_Animation>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Un reproductor de animacion es utilizado para reproduccion de proposito general de recursos de :ref:`Animation<class_Animation>`. Esto contiene un diccionario de animaciones (referenciada por nombre) y tiempos de mezcla personalizados entre sus transiciones. Adicionalmente, los animaciones pueden ser reproducidas y mezcladas en diferentes canales.
|
||||
|
||||
\ ``AnimationPlayer`` es mas conveniente que :ref:`Tween<class_Tween>` para animaciones donde tu sabes los valores finales por adelantado. Por ejemplo desvanecer una pantalla y que vuelva a aparecer es un trabajo mas facil de hacer con un nodo ``AnimationPlayer`` gracias a las herramientas de animacion suministradas por el editor. Este ejemplo partircular puede tambien ser implementado con un node :ref:`Tween<class_Tween>`, pero requiere hacer todo por codigo.
|
||||
|
||||
Actualizar las propiedades de la animacion objetivo ocurren en tiempo de ejecucion.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Animation tutorial index <../tutorials/animation/index>`
|
||||
|
||||
- :doc:`2D Sprite animation <../tutorials/2d/2d_sprite_animation>`
|
||||
|
||||
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`String<class_String>` | :ref:`assigned_animation<class_AnimationPlayer_property_assigned_animation>` | |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`String<class_String>` | :ref:`autoplay<class_AnimationPlayer_property_autoplay>` | ``""`` |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`String<class_String>` | :ref:`current_animation<class_AnimationPlayer_property_current_animation>` | ``""`` |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`float<class_float>` | :ref:`current_animation_length<class_AnimationPlayer_property_current_animation_length>` | |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`float<class_float>` | :ref:`current_animation_position<class_AnimationPlayer_property_current_animation_position>` | |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`AnimationMethodCallMode<enum_AnimationPlayer_AnimationMethodCallMode>` | :ref:`method_call_mode<class_AnimationPlayer_property_method_call_mode>` | ``0`` |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`playback_active<class_AnimationPlayer_property_playback_active>` | |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`float<class_float>` | :ref:`playback_default_blend_time<class_AnimationPlayer_property_playback_default_blend_time>` | ``0.0`` |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`AnimationProcessMode<enum_AnimationPlayer_AnimationProcessMode>` | :ref:`playback_process_mode<class_AnimationPlayer_property_playback_process_mode>` | ``1`` |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`float<class_float>` | :ref:`playback_speed<class_AnimationPlayer_property_playback_speed>` | ``1.0`` |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`reset_on_save<class_AnimationPlayer_property_reset_on_save>` | ``true`` |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`NodePath<class_NodePath>` | :ref:`root_node<class_AnimationPlayer_property_root_node>` | ``NodePath("..")`` |
|
||||
+------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------+--------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Error<enum_@GlobalScope_Error>` | :ref:`add_animation<class_AnimationPlayer_method_add_animation>` **(** :ref:`String<class_String>` name, :ref:`Animation<class_Animation>` animation **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`advance<class_AnimationPlayer_method_advance>` **(** :ref:`float<class_float>` delta **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`animation_get_next<class_AnimationPlayer_method_animation_get_next>` **(** :ref:`String<class_String>` anim_from **)** |const| |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`animation_set_next<class_AnimationPlayer_method_animation_set_next>` **(** :ref:`String<class_String>` anim_from, :ref:`String<class_String>` anim_to **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear_caches<class_AnimationPlayer_method_clear_caches>` **(** **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear_queue<class_AnimationPlayer_method_clear_queue>` **(** **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`find_animation<class_AnimationPlayer_method_find_animation>` **(** :ref:`Animation<class_Animation>` animation **)** |const| |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Animation<class_Animation>` | :ref:`get_animation<class_AnimationPlayer_method_get_animation>` **(** :ref:`String<class_String>` name **)** |const| |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolStringArray<class_PoolStringArray>` | :ref:`get_animation_list<class_AnimationPlayer_method_get_animation_list>` **(** **)** |const| |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_blend_time<class_AnimationPlayer_method_get_blend_time>` **(** :ref:`String<class_String>` anim_from, :ref:`String<class_String>` anim_to **)** |const| |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_playing_speed<class_AnimationPlayer_method_get_playing_speed>` **(** **)** |const| |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolStringArray<class_PoolStringArray>` | :ref:`get_queue<class_AnimationPlayer_method_get_queue>` **(** **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`has_animation<class_AnimationPlayer_method_has_animation>` **(** :ref:`String<class_String>` name **)** |const| |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_playing<class_AnimationPlayer_method_is_playing>` **(** **)** |const| |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`play<class_AnimationPlayer_method_play>` **(** :ref:`String<class_String>` name="", :ref:`float<class_float>` custom_blend=-1, :ref:`float<class_float>` custom_speed=1.0, :ref:`bool<class_bool>` from_end=false **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`play_backwards<class_AnimationPlayer_method_play_backwards>` **(** :ref:`String<class_String>` name="", :ref:`float<class_float>` custom_blend=-1 **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`queue<class_AnimationPlayer_method_queue>` **(** :ref:`String<class_String>` name **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_animation<class_AnimationPlayer_method_remove_animation>` **(** :ref:`String<class_String>` name **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`rename_animation<class_AnimationPlayer_method_rename_animation>` **(** :ref:`String<class_String>` name, :ref:`String<class_String>` newname **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`seek<class_AnimationPlayer_method_seek>` **(** :ref:`float<class_float>` seconds, :ref:`bool<class_bool>` update=false **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_blend_time<class_AnimationPlayer_method_set_blend_time>` **(** :ref:`String<class_String>` anim_from, :ref:`String<class_String>` anim_to, :ref:`float<class_float>` sec **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`stop<class_AnimationPlayer_method_stop>` **(** :ref:`bool<class_bool>` reset=true **)** |
|
||||
+-----------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_AnimationPlayer_signal_animation_changed:
|
||||
|
||||
- **animation_changed** **(** :ref:`String<class_String>` old_name, :ref:`String<class_String>` new_name **)**
|
||||
|
||||
Emitted when a queued animation plays after the previous animation was finished. See :ref:`queue<class_AnimationPlayer_method_queue>`.
|
||||
|
||||
\ **Note:** The signal is not emitted when the animation is changed via :ref:`play<class_AnimationPlayer_method_play>` or from :ref:`AnimationTree<class_AnimationTree>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_signal_animation_finished:
|
||||
|
||||
- **animation_finished** **(** :ref:`String<class_String>` anim_name **)**
|
||||
|
||||
Notifica cuando una animación ha terminado de reproducirse.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_signal_animation_started:
|
||||
|
||||
- **animation_started** **(** :ref:`String<class_String>` anim_name **)**
|
||||
|
||||
Notifica cuando una animación comienza a reproducirse.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_signal_caches_cleared:
|
||||
|
||||
- **caches_cleared** **(** **)**
|
||||
|
||||
Notifica cuando las cachés se han limpiado, ya sea automáticamente o manualmente a través del :ref:`clear_caches<class_AnimationPlayer_method_clear_caches>`.
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AnimationPlayer_AnimationProcessMode:
|
||||
|
||||
.. _class_AnimationPlayer_constant_ANIMATION_PROCESS_PHYSICS:
|
||||
|
||||
.. _class_AnimationPlayer_constant_ANIMATION_PROCESS_IDLE:
|
||||
|
||||
.. _class_AnimationPlayer_constant_ANIMATION_PROCESS_MANUAL:
|
||||
|
||||
enum **AnimationProcessMode**:
|
||||
|
||||
- **ANIMATION_PROCESS_PHYSICS** = **0** --- Animación del proceso durante el proceso de la física. Esto es especialmente útil cuando se animan los cuerpos físicos.
|
||||
|
||||
- **ANIMATION_PROCESS_IDLE** = **1** --- Animación del proceso durante el proceso de inactividad.
|
||||
|
||||
- **ANIMATION_PROCESS_MANUAL** = **2** --- No procese la animación. Utilice :ref:`advance<class_AnimationPlayer_method_advance>` para procesar la animación manualmente.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_AnimationPlayer_AnimationMethodCallMode:
|
||||
|
||||
.. _class_AnimationPlayer_constant_ANIMATION_METHOD_CALL_DEFERRED:
|
||||
|
||||
.. _class_AnimationPlayer_constant_ANIMATION_METHOD_CALL_IMMEDIATE:
|
||||
|
||||
enum **AnimationMethodCallMode**:
|
||||
|
||||
- **ANIMATION_METHOD_CALL_DEFERRED** = **0** --- Metodos de procesos por lotes llamados durante el proceso de animación, y despues que los eventos son procesados hacer los llamados. Esto evita los errores que implican borrar nodos o modificar el AnimationPlayer mientras se está reproduciendo.
|
||||
|
||||
- **ANIMATION_METHOD_CALL_IMMEDIATE** = **1** --- Hace llamadas a método inmediatamente cuando se alcanza en la animación.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationPlayer_property_assigned_animation:
|
||||
|
||||
- :ref:`String<class_String>` **assigned_animation**
|
||||
|
||||
+----------+-------------------------------+
|
||||
| *Setter* | set_assigned_animation(value) |
|
||||
+----------+-------------------------------+
|
||||
| *Getter* | get_assigned_animation() |
|
||||
+----------+-------------------------------+
|
||||
|
||||
Si se está reproduciendo, la animación actual; si no, la última animación reproducida. Cuando se establece, cambiaría la animación, pero no la reproduciría a menos que se esté reproduciendo actualmente. Ver también :ref:`current_animation<class_AnimationPlayer_property_current_animation>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_property_autoplay:
|
||||
|
||||
- :ref:`String<class_String>` **autoplay**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``""`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_autoplay(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_autoplay() |
|
||||
+-----------+---------------------+
|
||||
|
||||
El nombre de la animación que se reproducirá cuando se cargue la escena.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_property_current_animation:
|
||||
|
||||
- :ref:`String<class_String>` **current_animation**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``""`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_current_animation(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_current_animation() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
The name of the currently playing animation. If no animation is playing, the property's value is an empty string. Changing this value does not restart the animation. See :ref:`play<class_AnimationPlayer_method_play>` for more information on playing animations.
|
||||
|
||||
\ **Note:** While this property appears in the inspector, it's not meant to be edited, and it's not saved in the scene. This property is mainly used to get the currently playing animation, and internally for animation playback tracks. For more information, see :ref:`Animation<class_Animation>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_property_current_animation_length:
|
||||
|
||||
- :ref:`float<class_float>` **current_animation_length**
|
||||
|
||||
+----------+--------------------------------+
|
||||
| *Getter* | get_current_animation_length() |
|
||||
+----------+--------------------------------+
|
||||
|
||||
La duración (en segundos) de la animación que se está reproduciendo actualmente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_property_current_animation_position:
|
||||
|
||||
- :ref:`float<class_float>` **current_animation_position**
|
||||
|
||||
+----------+----------------------------------+
|
||||
| *Getter* | get_current_animation_position() |
|
||||
+----------+----------------------------------+
|
||||
|
||||
La posición (en segundos) de la animación que se está reproduciendo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_property_method_call_mode:
|
||||
|
||||
- :ref:`AnimationMethodCallMode<enum_AnimationPlayer_AnimationMethodCallMode>` **method_call_mode**
|
||||
|
||||
+-----------+-----------------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+-----------------------------+
|
||||
| *Setter* | set_method_call_mode(value) |
|
||||
+-----------+-----------------------------+
|
||||
| *Getter* | get_method_call_mode() |
|
||||
+-----------+-----------------------------+
|
||||
|
||||
El modo de llamada a utilizar para las Call Method Tracks.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_property_playback_active:
|
||||
|
||||
- :ref:`bool<class_bool>` **playback_active**
|
||||
|
||||
+----------+-------------------+
|
||||
| *Setter* | set_active(value) |
|
||||
+----------+-------------------+
|
||||
| *Getter* | is_active() |
|
||||
+----------+-------------------+
|
||||
|
||||
Si ``true``, actualiza las animaciones en respuesta a las notificaciones relacionadas con el proceso.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_property_playback_default_blend_time:
|
||||
|
||||
- :ref:`float<class_float>` **playback_default_blend_time**
|
||||
|
||||
+-----------+-------------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-------------------------------+
|
||||
| *Setter* | set_default_blend_time(value) |
|
||||
+-----------+-------------------------------+
|
||||
| *Getter* | get_default_blend_time() |
|
||||
+-----------+-------------------------------+
|
||||
|
||||
El tiempo por defecto para mezclar las animaciones. Va de 0 a 4096 con una precisión de 0,01.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_property_playback_process_mode:
|
||||
|
||||
- :ref:`AnimationProcessMode<enum_AnimationPlayer_AnimationProcessMode>` **playback_process_mode**
|
||||
|
||||
+-----------+-----------------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+-----------------------------------+
|
||||
| *Setter* | set_animation_process_mode(value) |
|
||||
+-----------+-----------------------------------+
|
||||
| *Getter* | get_animation_process_mode() |
|
||||
+-----------+-----------------------------------+
|
||||
|
||||
La notificación de proceso en la que se actualizan las animaciones.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_property_playback_speed:
|
||||
|
||||
- :ref:`float<class_float>` **playback_speed**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_speed_scale(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_speed_scale() |
|
||||
+-----------+------------------------+
|
||||
|
||||
La relación de escala de velocidad. Por ejemplo, si este valor es 1, entonces la animación se reproduce a velocidad normal. Si es 0,5, entonces se reproduce a media velocidad. Si es 2, entonces se reproduce a doble velocidad.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_property_reset_on_save:
|
||||
|
||||
- :ref:`bool<class_bool>` **reset_on_save**
|
||||
|
||||
+-----------+----------------------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+----------------------------------+
|
||||
| *Setter* | set_reset_on_save_enabled(value) |
|
||||
+-----------+----------------------------------+
|
||||
| *Getter* | is_reset_on_save_enabled() |
|
||||
+-----------+----------------------------------+
|
||||
|
||||
This is used by the editor. If set to ``true``, the scene will be saved with the effects of the reset animation applied (as if it had been seeked to time 0), then reverted after saving.
|
||||
|
||||
In other words, the saved scene file will contain the "default pose", as defined by the reset animation, if any, with the editor keeping the values that the nodes had before saving.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_property_root_node:
|
||||
|
||||
- :ref:`NodePath<class_NodePath>` **root_node**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``NodePath("..")`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_root(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | get_root() |
|
||||
+-----------+--------------------+
|
||||
|
||||
El nodo desde el cual viajarán las referencias de la ruta de nodos.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimationPlayer_method_add_animation:
|
||||
|
||||
- :ref:`Error<enum_@GlobalScope_Error>` **add_animation** **(** :ref:`String<class_String>` name, :ref:`Animation<class_Animation>` animation **)**
|
||||
|
||||
Añade una ``animation`` al reproductor con la llave ``name``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_advance:
|
||||
|
||||
- void **advance** **(** :ref:`float<class_float>` delta **)**
|
||||
|
||||
Cambia la positicon en la linea de tiempo de las animaciones e inmediatamente actualiza la animacion. ``delta`` es el tiempo en segundos a cambiar. Eventos entre el frame actual y ``delta`` son manejados.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_animation_get_next:
|
||||
|
||||
- :ref:`String<class_String>` **animation_get_next** **(** :ref:`String<class_String>` anim_from **)** |const|
|
||||
|
||||
Devuelve el nombre de la proxima animacion en la cola.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_animation_set_next:
|
||||
|
||||
- void **animation_set_next** **(** :ref:`String<class_String>` anim_from, :ref:`String<class_String>` anim_to **)**
|
||||
|
||||
Lanza la animacion ``anim_to`` cuando la animacion ``anim_from`` se completa.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_clear_caches:
|
||||
|
||||
- void **clear_caches** **(** **)**
|
||||
|
||||
``AnimationPlayer`` cachea nodos animados. Puede no notarse si un nodo desaparece;\ :ref:`clear_caches<class_AnimationPlayer_method_clear_caches>` fuerza a la cache a actualizarse de nuevo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_clear_queue:
|
||||
|
||||
- void **clear_queue** **(** **)**
|
||||
|
||||
Limpia todas las colas, animaciones no reproducidas.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_find_animation:
|
||||
|
||||
- :ref:`String<class_String>` **find_animation** **(** :ref:`Animation<class_Animation>` animation **)** |const|
|
||||
|
||||
Devuelve el nombre de ``animation`` or una string vacia si no se encuentra.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_get_animation:
|
||||
|
||||
- :ref:`Animation<class_Animation>` **get_animation** **(** :ref:`String<class_String>` name **)** |const|
|
||||
|
||||
Devuelve la :ref:`Animation<class_Animation>` con clave ``name`` or ``null`` si no se encuentra.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_get_animation_list:
|
||||
|
||||
- :ref:`PoolStringArray<class_PoolStringArray>` **get_animation_list** **(** **)** |const|
|
||||
|
||||
Devuelve la lista de nombres de animaciones almacenadas.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_get_blend_time:
|
||||
|
||||
- :ref:`float<class_float>` **get_blend_time** **(** :ref:`String<class_String>` anim_from, :ref:`String<class_String>` anim_to **)** |const|
|
||||
|
||||
Obtiene el nombre de mezcla (en segundos) entre dos animaciones, referenciado por sus nombres.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_get_playing_speed:
|
||||
|
||||
- :ref:`float<class_float>` **get_playing_speed** **(** **)** |const|
|
||||
|
||||
Obtiene la velocidad de ejecucion de la animacion actual o 0 sino esta siendo reproducida. Esta velocidad es la propiedad :ref:`playback_speed<class_AnimationPlayer_property_playback_speed>` multiplicada por el argumento ``custom_speed`` especificado cuando se llama al metodo :ref:`play<class_AnimationPlayer_method_play>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_get_queue:
|
||||
|
||||
- :ref:`PoolStringArray<class_PoolStringArray>` **get_queue** **(** **)**
|
||||
|
||||
Devuelve una lista de los nombres de las animaciones que están actualmente en cola para ser reproducidas.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_has_animation:
|
||||
|
||||
- :ref:`bool<class_bool>` **has_animation** **(** :ref:`String<class_String>` name **)** |const|
|
||||
|
||||
Devuelve ``true`` si el ``AnimationPlayer`` almacena una :ref:`Animation<class_Animation>` con la clave ``name``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_is_playing:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_playing** **(** **)** |const|
|
||||
|
||||
Devuelve ``true`` si se esta reproduciendo una animación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_play:
|
||||
|
||||
- void **play** **(** :ref:`String<class_String>` name="", :ref:`float<class_float>` custom_blend=-1, :ref:`float<class_float>` custom_speed=1.0, :ref:`bool<class_bool>` from_end=false **)**
|
||||
|
||||
Reproduce la animación con la clave ``name``. Se pueden establecer tiempos de mezcla y velocidad personalizados. Si ``custom_speed`` es negativo y ``from_end`` es ``true``, la animación se reproducirá hacia atrás (lo que equivale a llamar a :ref:`play_backwards<class_AnimationPlayer_method_play_backwards>`).
|
||||
|
||||
El ``AnimationPlayer`` mantiene un registro de su animación actual o la última que se ha reproducido con :ref:`assigned_animation<class_AnimationPlayer_property_assigned_animation>`. Si se llama a este método con ese mismo nombre de animación ``name``, o sin el parámetro ``name``, la animación asignada se reproducirá de nuevo si se ha detenido, o se reiniciará si se ha detenido (ver :ref:`stop<class_AnimationPlayer_method_stop>` tanto para la pausa como para la parada). Si la animación ya se estaba reproduciendo, seguirá reproduciéndose.
|
||||
|
||||
\ **Nota:** La animación se actualizará la próxima vez que se procese el ``AnimationPlayer``. Si se actualizan otras variables al mismo tiempo que esta llamada, puede que se actualicen demasiado pronto. Para ejecutar la actualización inmediatamente, llame a ``advance(0)``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_play_backwards:
|
||||
|
||||
- void **play_backwards** **(** :ref:`String<class_String>` name="", :ref:`float<class_float>` custom_blend=-1 **)**
|
||||
|
||||
Reproduce la animación con la clave ``name`` al revés.
|
||||
|
||||
Este método es una abreviatura de :ref:`play<class_AnimationPlayer_method_play>` con ``custom_speed = -1.0`` y ``from_end = true``, por lo que para mayor información vea su descripción.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_queue:
|
||||
|
||||
- void **queue** **(** :ref:`String<class_String>` name **)**
|
||||
|
||||
Pone en cola una animación para su reproducción una vez que la actual haya terminado.
|
||||
|
||||
\ **Nota:** Si una animación en bucle se está reproduciendo actualmente, la animación en cola nunca se reproducirá a menos que la animación en bucle se detenga de alguna manera.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_remove_animation:
|
||||
|
||||
- void **remove_animation** **(** :ref:`String<class_String>` name **)**
|
||||
|
||||
Elimina la animación con la clave ``name``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_rename_animation:
|
||||
|
||||
- void **rename_animation** **(** :ref:`String<class_String>` name, :ref:`String<class_String>` newname **)**
|
||||
|
||||
Renombra una animación existente con la clave ``name`` a ``newname``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_seek:
|
||||
|
||||
- void **seek** **(** :ref:`float<class_float>` seconds, :ref:`bool<class_bool>` update=false **)**
|
||||
|
||||
Busca la animación hasta el punto en el tiempo de ``seconds``. Si ``update`` es ``true``, la animación se actualiza también, de lo contrario se actualiza en el momento del proceso. Los eventos entre el fotograma actual y ``seconds`` se saltan.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_set_blend_time:
|
||||
|
||||
- void **set_blend_time** **(** :ref:`String<class_String>` anim_from, :ref:`String<class_String>` anim_to, :ref:`float<class_float>` sec **)**
|
||||
|
||||
Especifica un tiempo de mezcla (en segundos) entre dos animaciones, referenciadas por sus nombres.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationPlayer_method_stop:
|
||||
|
||||
- void **stop** **(** :ref:`bool<class_bool>` reset=true **)**
|
||||
|
||||
Detiene o pausa la animación que se está reproduciendo. Si ``reset`` es ``true``, la posición de la animación se restablece a ``0`` y la velocidad de reproducción se restablece a ``1.0``.
|
||||
|
||||
Si ``reset`` es ``false``, se mantendrá la :ref:`current_animation_position<class_AnimationPlayer_property_current_animation_position>` y llamará a :ref:`play<class_AnimationPlayer_method_play>` o :ref:`play_backwards<class_AnimationPlayer_method_play_backwards>` sin argumentos o con el mismo nombre de animación que :ref:`assigned_animation<class_AnimationPlayer_property_assigned_animation>` reanudará la animación.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,20 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationRootNode.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationRootNode:
|
||||
|
||||
AnimationRootNode
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`AnimationNode<class_AnimationNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`AnimationNodeAnimation<class_AnimationNodeAnimation>`, :ref:`AnimationNodeBlendSpace1D<class_AnimationNodeBlendSpace1D>`, :ref:`AnimationNodeBlendSpace2D<class_AnimationNodeBlendSpace2D>`, :ref:`AnimationNodeBlendTree<class_AnimationNodeBlendTree>`, :ref:`AnimationNodeStateMachine<class_AnimationNodeStateMachine>`
|
||||
|
||||
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,18 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationTrackEditPlugin.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationTrackEditPlugin:
|
||||
|
||||
AnimationTrackEditPlugin
|
||||
========================
|
||||
|
||||
**Inherits:** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
|
||||
|
||||
.. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
|
||||
.. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
|
||||
.. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
|
||||
@@ -1,181 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationTree.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationTree:
|
||||
|
||||
AnimationTree
|
||||
=============
|
||||
|
||||
**Inherits:** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Un nodo para ser usado para transiciones de animación avanzadas en un :ref:`AnimationPlayer<class_AnimationPlayer>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
A node to be 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.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Using AnimationTree <../tutorials/animation/animation_tree>`
|
||||
|
||||
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+----------------------------------------------------------------------+--------------------------------------------------------------------------+------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`active<class_AnimationTree_property_active>` | ``false`` |
|
||||
+----------------------------------------------------------------------+--------------------------------------------------------------------------+------------------+
|
||||
| :ref:`NodePath<class_NodePath>` | :ref:`anim_player<class_AnimationTree_property_anim_player>` | ``NodePath("")`` |
|
||||
+----------------------------------------------------------------------+--------------------------------------------------------------------------+------------------+
|
||||
| :ref:`AnimationProcessMode<enum_AnimationTree_AnimationProcessMode>` | :ref:`process_mode<class_AnimationTree_property_process_mode>` | ``1`` |
|
||||
+----------------------------------------------------------------------+--------------------------------------------------------------------------+------------------+
|
||||
| :ref:`NodePath<class_NodePath>` | :ref:`root_motion_track<class_AnimationTree_property_root_motion_track>` | ``NodePath("")`` |
|
||||
+----------------------------------------------------------------------+--------------------------------------------------------------------------+------------------+
|
||||
| :ref:`AnimationNode<class_AnimationNode>` | :ref:`tree_root<class_AnimationTree_property_tree_root>` | |
|
||||
+----------------------------------------------------------------------+--------------------------------------------------------------------------+------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-----------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`advance<class_AnimationTree_method_advance>` **(** :ref:`float<class_float>` delta **)** |
|
||||
+-----------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Transform<class_Transform>` | :ref:`get_root_motion_transform<class_AnimationTree_method_get_root_motion_transform>` **(** **)** |const| |
|
||||
+-----------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`rename_parameter<class_AnimationTree_method_rename_parameter>` **(** :ref:`String<class_String>` old_name, :ref:`String<class_String>` new_name **)** |
|
||||
+-----------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AnimationTree_AnimationProcessMode:
|
||||
|
||||
.. _class_AnimationTree_constant_ANIMATION_PROCESS_PHYSICS:
|
||||
|
||||
.. _class_AnimationTree_constant_ANIMATION_PROCESS_IDLE:
|
||||
|
||||
.. _class_AnimationTree_constant_ANIMATION_PROCESS_MANUAL:
|
||||
|
||||
enum **AnimationProcessMode**:
|
||||
|
||||
- **ANIMATION_PROCESS_PHYSICS** = **0** --- Las animaciones progresarán durante el fotograma de la física (es decir, :ref:`Node._physics_process<class_Node_method__physics_process>`).
|
||||
|
||||
- **ANIMATION_PROCESS_IDLE** = **1** --- Las animaciones progresarán durante el fotograma inactivo (es decir, :ref:`Node._process<class_Node_method__process>`).
|
||||
|
||||
- **ANIMATION_PROCESS_MANUAL** = **2** --- Las animaciones sólo progresarán manualmente (ver :ref:`advance<class_AnimationTree_method_advance>`).
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationTree_property_active:
|
||||
|
||||
- :ref:`bool<class_bool>` **active**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_active(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | is_active() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Si ``true``, el ``AnimationTree`` se procesará.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTree_property_anim_player:
|
||||
|
||||
- :ref:`NodePath<class_NodePath>` **anim_player**
|
||||
|
||||
+-----------+-----------------------------+
|
||||
| *Default* | ``NodePath("")`` |
|
||||
+-----------+-----------------------------+
|
||||
| *Setter* | set_animation_player(value) |
|
||||
+-----------+-----------------------------+
|
||||
| *Getter* | get_animation_player() |
|
||||
+-----------+-----------------------------+
|
||||
|
||||
La ruta al :ref:`AnimationPlayer<class_AnimationPlayer>` utilizada para la animacion.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTree_property_process_mode:
|
||||
|
||||
- :ref:`AnimationProcessMode<enum_AnimationTree_AnimationProcessMode>` **process_mode**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_process_mode(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_process_mode() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
El modo de proceso de este ``AnimationTree``. Ver :ref:`AnimationProcessMode<enum_AnimationTree_AnimationProcessMode>` para los modos disponibles.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTree_property_root_motion_track:
|
||||
|
||||
- :ref:`NodePath<class_NodePath>` **root_motion_track**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``NodePath("")`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_root_motion_track(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_root_motion_track() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
The path to the Animation track used for root motion. Paths must be valid scene-tree paths to a node, and must be specified starting from the parent node of the node that will reproduce the animation. To specify a track that controls properties or bones, append its name after the path, separated by ``":"``. For example, ``"character/skeleton:ankle"`` or ``"character/mesh:transform/local"``.
|
||||
|
||||
If the track has type :ref:`Animation.TYPE_TRANSFORM<class_Animation_constant_TYPE_TRANSFORM>`, the transformation will be cancelled visually, and the animation will appear to stay in place. See also :ref:`get_root_motion_transform<class_AnimationTree_method_get_root_motion_transform>` and :ref:`RootMotionView<class_RootMotionView>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTree_property_tree_root:
|
||||
|
||||
- :ref:`AnimationNode<class_AnimationNode>` **tree_root**
|
||||
|
||||
+----------+----------------------+
|
||||
| *Setter* | set_tree_root(value) |
|
||||
+----------+----------------------+
|
||||
| *Getter* | get_tree_root() |
|
||||
+----------+----------------------+
|
||||
|
||||
El nodo de animación raíz de este ``AnimationTree``. Ver :ref:`AnimationNode<class_AnimationNode>`.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimationTree_method_advance:
|
||||
|
||||
- void **advance** **(** :ref:`float<class_float>` delta **)**
|
||||
|
||||
Avanza manualmente las animaciones en el tiempo especificado (en segundos).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTree_method_get_root_motion_transform:
|
||||
|
||||
- :ref:`Transform<class_Transform>` **get_root_motion_transform** **(** **)** |const|
|
||||
|
||||
Retrieve the motion of the :ref:`root_motion_track<class_AnimationTree_property_root_motion_track>` as a :ref:`Transform<class_Transform>` that can be used elsewhere. If :ref:`root_motion_track<class_AnimationTree_property_root_motion_track>` is not a path to a track of type :ref:`Animation.TYPE_TRANSFORM<class_Animation_constant_TYPE_TRANSFORM>`, returns an identity transformation. See also :ref:`root_motion_track<class_AnimationTree_property_root_motion_track>` and :ref:`RootMotionView<class_RootMotionView>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTree_method_rename_parameter:
|
||||
|
||||
- void **rename_parameter** **(** :ref:`String<class_String>` old_name, :ref:`String<class_String>` new_name **)**
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,771 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AnimationTreePlayer.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AnimationTreePlayer:
|
||||
|
||||
AnimationTreePlayer
|
||||
===================
|
||||
|
||||
**Inherits:** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
*Deprecated.* Animation player that uses a node graph for blending animations. Superseded by :ref:`AnimationTree<class_AnimationTree>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
*Deprecated.* A node graph tool for blending multiple animations bound to an :ref:`AnimationPlayer<class_AnimationPlayer>`. Especially useful for animating characters or other skeleton-based rigs. It can combine several animations to form a desired pose.
|
||||
|
||||
It takes :ref:`Animation<class_Animation>`\ s from an :ref:`AnimationPlayer<class_AnimationPlayer>` node and mixes them depending on the graph.
|
||||
|
||||
See :ref:`AnimationTree<class_AnimationTree>` for a more full-featured replacement of this node.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/animation/animation_tree`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+----------------------------------------------------------------------------+----------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`active<class_AnimationTreePlayer_property_active>` | ``false`` |
|
||||
+----------------------------------------------------------------------------+----------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`NodePath<class_NodePath>` | :ref:`base_path<class_AnimationTreePlayer_property_base_path>` | ``NodePath("..")`` |
|
||||
+----------------------------------------------------------------------------+----------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`NodePath<class_NodePath>` | :ref:`master_player<class_AnimationTreePlayer_property_master_player>` | ``NodePath("")`` |
|
||||
+----------------------------------------------------------------------------+----------------------------------------------------------------------------------------+--------------------+
|
||||
| :ref:`AnimationProcessMode<enum_AnimationTreePlayer_AnimationProcessMode>` | :ref:`playback_process_mode<class_AnimationTreePlayer_property_playback_process_mode>` | ``1`` |
|
||||
+----------------------------------------------------------------------------+----------------------------------------------------------------------------------------+--------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_node<class_AnimationTreePlayer_method_add_node>` **(** :ref:`NodeType<enum_AnimationTreePlayer_NodeType>` type, :ref:`String<class_String>` id **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`advance<class_AnimationTreePlayer_method_advance>` **(** :ref:`float<class_float>` delta **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Animation<class_Animation>` | :ref:`animation_node_get_animation<class_AnimationTreePlayer_method_animation_node_get_animation>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`animation_node_get_master_animation<class_AnimationTreePlayer_method_animation_node_get_master_animation>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`animation_node_get_position<class_AnimationTreePlayer_method_animation_node_get_position>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`animation_node_set_animation<class_AnimationTreePlayer_method_animation_node_set_animation>` **(** :ref:`String<class_String>` id, :ref:`Animation<class_Animation>` animation **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`animation_node_set_filter_path<class_AnimationTreePlayer_method_animation_node_set_filter_path>` **(** :ref:`String<class_String>` id, :ref:`NodePath<class_NodePath>` path, :ref:`bool<class_bool>` enable **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`animation_node_set_master_animation<class_AnimationTreePlayer_method_animation_node_set_master_animation>` **(** :ref:`String<class_String>` id, :ref:`String<class_String>` source **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`are_nodes_connected<class_AnimationTreePlayer_method_are_nodes_connected>` **(** :ref:`String<class_String>` id, :ref:`String<class_String>` dst_id, :ref:`int<class_int>` dst_input_idx **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`blend2_node_get_amount<class_AnimationTreePlayer_method_blend2_node_get_amount>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`blend2_node_set_amount<class_AnimationTreePlayer_method_blend2_node_set_amount>` **(** :ref:`String<class_String>` id, :ref:`float<class_float>` blend **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`blend2_node_set_filter_path<class_AnimationTreePlayer_method_blend2_node_set_filter_path>` **(** :ref:`String<class_String>` id, :ref:`NodePath<class_NodePath>` path, :ref:`bool<class_bool>` enable **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`blend3_node_get_amount<class_AnimationTreePlayer_method_blend3_node_get_amount>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`blend3_node_set_amount<class_AnimationTreePlayer_method_blend3_node_set_amount>` **(** :ref:`String<class_String>` id, :ref:`float<class_float>` blend **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`blend4_node_get_amount<class_AnimationTreePlayer_method_blend4_node_get_amount>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`blend4_node_set_amount<class_AnimationTreePlayer_method_blend4_node_set_amount>` **(** :ref:`String<class_String>` id, :ref:`Vector2<class_Vector2>` blend **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Error<enum_@GlobalScope_Error>` | :ref:`connect_nodes<class_AnimationTreePlayer_method_connect_nodes>` **(** :ref:`String<class_String>` id, :ref:`String<class_String>` dst_id, :ref:`int<class_int>` dst_input_idx **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`disconnect_nodes<class_AnimationTreePlayer_method_disconnect_nodes>` **(** :ref:`String<class_String>` id, :ref:`int<class_int>` dst_input_idx **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolStringArray<class_PoolStringArray>` | :ref:`get_node_list<class_AnimationTreePlayer_method_get_node_list>` **(** **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`mix_node_get_amount<class_AnimationTreePlayer_method_mix_node_get_amount>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`mix_node_set_amount<class_AnimationTreePlayer_method_mix_node_set_amount>` **(** :ref:`String<class_String>` id, :ref:`float<class_float>` ratio **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`node_exists<class_AnimationTreePlayer_method_node_exists>` **(** :ref:`String<class_String>` node **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`node_get_input_count<class_AnimationTreePlayer_method_node_get_input_count>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`node_get_input_source<class_AnimationTreePlayer_method_node_get_input_source>` **(** :ref:`String<class_String>` id, :ref:`int<class_int>` idx **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`node_get_position<class_AnimationTreePlayer_method_node_get_position>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`NodeType<enum_AnimationTreePlayer_NodeType>` | :ref:`node_get_type<class_AnimationTreePlayer_method_node_get_type>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Error<enum_@GlobalScope_Error>` | :ref:`node_rename<class_AnimationTreePlayer_method_node_rename>` **(** :ref:`String<class_String>` node, :ref:`String<class_String>` new_name **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`node_set_position<class_AnimationTreePlayer_method_node_set_position>` **(** :ref:`String<class_String>` id, :ref:`Vector2<class_Vector2>` screen_position **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`oneshot_node_get_autorestart_delay<class_AnimationTreePlayer_method_oneshot_node_get_autorestart_delay>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`oneshot_node_get_autorestart_random_delay<class_AnimationTreePlayer_method_oneshot_node_get_autorestart_random_delay>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`oneshot_node_get_fadein_time<class_AnimationTreePlayer_method_oneshot_node_get_fadein_time>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`oneshot_node_get_fadeout_time<class_AnimationTreePlayer_method_oneshot_node_get_fadeout_time>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`oneshot_node_has_autorestart<class_AnimationTreePlayer_method_oneshot_node_has_autorestart>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`oneshot_node_is_active<class_AnimationTreePlayer_method_oneshot_node_is_active>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`oneshot_node_set_autorestart<class_AnimationTreePlayer_method_oneshot_node_set_autorestart>` **(** :ref:`String<class_String>` id, :ref:`bool<class_bool>` enable **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`oneshot_node_set_autorestart_delay<class_AnimationTreePlayer_method_oneshot_node_set_autorestart_delay>` **(** :ref:`String<class_String>` id, :ref:`float<class_float>` delay_sec **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`oneshot_node_set_autorestart_random_delay<class_AnimationTreePlayer_method_oneshot_node_set_autorestart_random_delay>` **(** :ref:`String<class_String>` id, :ref:`float<class_float>` rand_sec **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`oneshot_node_set_fadein_time<class_AnimationTreePlayer_method_oneshot_node_set_fadein_time>` **(** :ref:`String<class_String>` id, :ref:`float<class_float>` time_sec **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`oneshot_node_set_fadeout_time<class_AnimationTreePlayer_method_oneshot_node_set_fadeout_time>` **(** :ref:`String<class_String>` id, :ref:`float<class_float>` time_sec **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`oneshot_node_set_filter_path<class_AnimationTreePlayer_method_oneshot_node_set_filter_path>` **(** :ref:`String<class_String>` id, :ref:`NodePath<class_NodePath>` path, :ref:`bool<class_bool>` enable **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`oneshot_node_start<class_AnimationTreePlayer_method_oneshot_node_start>` **(** :ref:`String<class_String>` id **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`oneshot_node_stop<class_AnimationTreePlayer_method_oneshot_node_stop>` **(** :ref:`String<class_String>` id **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`recompute_caches<class_AnimationTreePlayer_method_recompute_caches>` **(** **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_node<class_AnimationTreePlayer_method_remove_node>` **(** :ref:`String<class_String>` id **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`reset<class_AnimationTreePlayer_method_reset>` **(** **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`timescale_node_get_scale<class_AnimationTreePlayer_method_timescale_node_get_scale>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`timescale_node_set_scale<class_AnimationTreePlayer_method_timescale_node_set_scale>` **(** :ref:`String<class_String>` id, :ref:`float<class_float>` scale **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`timeseek_node_seek<class_AnimationTreePlayer_method_timeseek_node_seek>` **(** :ref:`String<class_String>` id, :ref:`float<class_float>` seconds **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`transition_node_delete_input<class_AnimationTreePlayer_method_transition_node_delete_input>` **(** :ref:`String<class_String>` id, :ref:`int<class_int>` input_idx **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`transition_node_get_current<class_AnimationTreePlayer_method_transition_node_get_current>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`transition_node_get_input_count<class_AnimationTreePlayer_method_transition_node_get_input_count>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`transition_node_get_xfade_time<class_AnimationTreePlayer_method_transition_node_get_xfade_time>` **(** :ref:`String<class_String>` id **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`transition_node_has_input_auto_advance<class_AnimationTreePlayer_method_transition_node_has_input_auto_advance>` **(** :ref:`String<class_String>` id, :ref:`int<class_int>` input_idx **)** |const| |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`transition_node_set_current<class_AnimationTreePlayer_method_transition_node_set_current>` **(** :ref:`String<class_String>` id, :ref:`int<class_int>` input_idx **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`transition_node_set_input_auto_advance<class_AnimationTreePlayer_method_transition_node_set_input_auto_advance>` **(** :ref:`String<class_String>` id, :ref:`int<class_int>` input_idx, :ref:`bool<class_bool>` enable **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`transition_node_set_input_count<class_AnimationTreePlayer_method_transition_node_set_input_count>` **(** :ref:`String<class_String>` id, :ref:`int<class_int>` count **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`transition_node_set_xfade_time<class_AnimationTreePlayer_method_transition_node_set_xfade_time>` **(** :ref:`String<class_String>` id, :ref:`float<class_float>` time_sec **)** |
|
||||
+----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AnimationTreePlayer_NodeType:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_NODE_OUTPUT:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_NODE_ANIMATION:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_NODE_ONESHOT:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_NODE_MIX:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_NODE_BLEND2:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_NODE_BLEND3:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_NODE_BLEND4:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_NODE_TIMESCALE:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_NODE_TIMESEEK:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_NODE_TRANSITION:
|
||||
|
||||
enum **NodeType**:
|
||||
|
||||
- **NODE_OUTPUT** = **0** --- Output node.
|
||||
|
||||
- **NODE_ANIMATION** = **1** --- Animation node.
|
||||
|
||||
- **NODE_ONESHOT** = **2** --- OneShot node.
|
||||
|
||||
- **NODE_MIX** = **3** --- Mix node.
|
||||
|
||||
- **NODE_BLEND2** = **4** --- Blend2 node.
|
||||
|
||||
- **NODE_BLEND3** = **5** --- Blend3 node.
|
||||
|
||||
- **NODE_BLEND4** = **6** --- Blend4 node.
|
||||
|
||||
- **NODE_TIMESCALE** = **7** --- TimeScale node.
|
||||
|
||||
- **NODE_TIMESEEK** = **8** --- TimeSeek node.
|
||||
|
||||
- **NODE_TRANSITION** = **9** --- Transition node.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_AnimationTreePlayer_AnimationProcessMode:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_ANIMATION_PROCESS_PHYSICS:
|
||||
|
||||
.. _class_AnimationTreePlayer_constant_ANIMATION_PROCESS_IDLE:
|
||||
|
||||
enum **AnimationProcessMode**:
|
||||
|
||||
- **ANIMATION_PROCESS_PHYSICS** = **0** --- Animación del proceso durante el proceso de la física. Esto es especialmente útil cuando se animan los cuerpos físicos.
|
||||
|
||||
- **ANIMATION_PROCESS_IDLE** = **1** --- Animación del proceso durante el proceso de inactividad.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AnimationTreePlayer_property_active:
|
||||
|
||||
- :ref:`bool<class_bool>` **active**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_active(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | is_active() |
|
||||
+-----------+-------------------+
|
||||
|
||||
If ``true``, the ``AnimationTreePlayer`` is able to play animations.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_property_base_path:
|
||||
|
||||
- :ref:`NodePath<class_NodePath>` **base_path**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``NodePath("..")`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_base_path(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_base_path() |
|
||||
+-----------+----------------------+
|
||||
|
||||
The node from which to relatively access other nodes.
|
||||
|
||||
It accesses the bones, so it should point to the same node the :ref:`AnimationPlayer<class_AnimationPlayer>` would point its Root Node at.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_property_master_player:
|
||||
|
||||
- :ref:`NodePath<class_NodePath>` **master_player**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``NodePath("")`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_master_player(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_master_player() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
The path to the :ref:`AnimationPlayer<class_AnimationPlayer>` from which this ``AnimationTreePlayer`` binds animations to animation nodes.
|
||||
|
||||
Once set, :ref:`Animation<class_Animation>` nodes can be added to the ``AnimationTreePlayer``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_property_playback_process_mode:
|
||||
|
||||
- :ref:`AnimationProcessMode<enum_AnimationTreePlayer_AnimationProcessMode>` **playback_process_mode**
|
||||
|
||||
+-----------+-----------------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+-----------------------------------+
|
||||
| *Setter* | set_animation_process_mode(value) |
|
||||
+-----------+-----------------------------------+
|
||||
| *Getter* | get_animation_process_mode() |
|
||||
+-----------+-----------------------------------+
|
||||
|
||||
The thread in which to update animations.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AnimationTreePlayer_method_add_node:
|
||||
|
||||
- void **add_node** **(** :ref:`NodeType<enum_AnimationTreePlayer_NodeType>` type, :ref:`String<class_String>` id **)**
|
||||
|
||||
Adds a ``type`` node to the graph with name ``id``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_advance:
|
||||
|
||||
- void **advance** **(** :ref:`float<class_float>` delta **)**
|
||||
|
||||
Shifts position in the animation timeline. ``delta`` is the time in seconds to shift. Events between the current frame and ``delta`` are handled.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_animation_node_get_animation:
|
||||
|
||||
- :ref:`Animation<class_Animation>` **animation_node_get_animation** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the :ref:`AnimationPlayer<class_AnimationPlayer>`'s :ref:`Animation<class_Animation>` bound to the ``AnimationTreePlayer``'s animation node with name ``id``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_animation_node_get_master_animation:
|
||||
|
||||
- :ref:`String<class_String>` **animation_node_get_master_animation** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the name of the :ref:`master_player<class_AnimationTreePlayer_property_master_player>`'s :ref:`Animation<class_Animation>` bound to this animation node.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_animation_node_get_position:
|
||||
|
||||
- :ref:`float<class_float>` **animation_node_get_position** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the absolute playback timestamp of the animation node with name ``id``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_animation_node_set_animation:
|
||||
|
||||
- void **animation_node_set_animation** **(** :ref:`String<class_String>` id, :ref:`Animation<class_Animation>` animation **)**
|
||||
|
||||
Binds a new :ref:`Animation<class_Animation>` from the :ref:`master_player<class_AnimationTreePlayer_property_master_player>` to the ``AnimationTreePlayer``'s animation node with name ``id``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_animation_node_set_filter_path:
|
||||
|
||||
- void **animation_node_set_filter_path** **(** :ref:`String<class_String>` id, :ref:`NodePath<class_NodePath>` path, :ref:`bool<class_bool>` enable **)**
|
||||
|
||||
If ``enable`` is ``true``, the animation node with ID ``id`` turns off the track modifying the property at ``path``. The modified node's children continue to animate.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_animation_node_set_master_animation:
|
||||
|
||||
- void **animation_node_set_master_animation** **(** :ref:`String<class_String>` id, :ref:`String<class_String>` source **)**
|
||||
|
||||
Binds the :ref:`Animation<class_Animation>` named ``source`` from :ref:`master_player<class_AnimationTreePlayer_property_master_player>` to the animation node ``id``. Recalculates caches.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_are_nodes_connected:
|
||||
|
||||
- :ref:`bool<class_bool>` **are_nodes_connected** **(** :ref:`String<class_String>` id, :ref:`String<class_String>` dst_id, :ref:`int<class_int>` dst_input_idx **)** |const|
|
||||
|
||||
Returns whether node ``id`` and ``dst_id`` are connected at the specified slot.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_blend2_node_get_amount:
|
||||
|
||||
- :ref:`float<class_float>` **blend2_node_get_amount** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the blend amount of a Blend2 node given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_blend2_node_set_amount:
|
||||
|
||||
- void **blend2_node_set_amount** **(** :ref:`String<class_String>` id, :ref:`float<class_float>` blend **)**
|
||||
|
||||
Sets the blend amount of a Blend2 node given its name and value.
|
||||
|
||||
A Blend2 node blends two animations (A and B) with the amount between 0 and 1.
|
||||
|
||||
At 0, output is input A. Towards 1, the influence of A gets lessened, the influence of B gets raised. At 1, output is input B.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_blend2_node_set_filter_path:
|
||||
|
||||
- void **blend2_node_set_filter_path** **(** :ref:`String<class_String>` id, :ref:`NodePath<class_NodePath>` path, :ref:`bool<class_bool>` enable **)**
|
||||
|
||||
If ``enable`` is ``true``, the Blend2 node with name ``id`` turns off the track modifying the property at ``path``. The modified node's children continue to animate.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_blend3_node_get_amount:
|
||||
|
||||
- :ref:`float<class_float>` **blend3_node_get_amount** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the blend amount of a Blend3 node given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_blend3_node_set_amount:
|
||||
|
||||
- void **blend3_node_set_amount** **(** :ref:`String<class_String>` id, :ref:`float<class_float>` blend **)**
|
||||
|
||||
Sets the blend amount of a Blend3 node given its name and value.
|
||||
|
||||
A Blend3 Node blends three animations (A, B-, B+) with the amount between -1 and 1.
|
||||
|
||||
At -1, output is input B-. From -1 to 0, the influence of B- gets lessened, the influence of A gets raised and the influence of B+ is 0. At 0, output is input A. From 0 to 1, the influence of A gets lessened, the influence of B+ gets raised and the influence of B+ is 0. At 1, output is input B+.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_blend4_node_get_amount:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **blend4_node_get_amount** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the blend amount of a Blend4 node given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_blend4_node_set_amount:
|
||||
|
||||
- void **blend4_node_set_amount** **(** :ref:`String<class_String>` id, :ref:`Vector2<class_Vector2>` blend **)**
|
||||
|
||||
Sets the blend amount of a Blend4 node given its name and value.
|
||||
|
||||
A Blend4 Node blends two pairs of animations.
|
||||
|
||||
The two pairs are blended like Blend2 and then added together.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_connect_nodes:
|
||||
|
||||
- :ref:`Error<enum_@GlobalScope_Error>` **connect_nodes** **(** :ref:`String<class_String>` id, :ref:`String<class_String>` dst_id, :ref:`int<class_int>` dst_input_idx **)**
|
||||
|
||||
Connects node ``id`` to ``dst_id`` at the specified input slot.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_disconnect_nodes:
|
||||
|
||||
- void **disconnect_nodes** **(** :ref:`String<class_String>` id, :ref:`int<class_int>` dst_input_idx **)**
|
||||
|
||||
Disconnects nodes connected to ``id`` at the specified input slot.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_get_node_list:
|
||||
|
||||
- :ref:`PoolStringArray<class_PoolStringArray>` **get_node_list** **(** **)**
|
||||
|
||||
Returns a :ref:`PoolStringArray<class_PoolStringArray>` containing the name of all nodes.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_mix_node_get_amount:
|
||||
|
||||
- :ref:`float<class_float>` **mix_node_get_amount** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the mix amount of a Mix node given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_mix_node_set_amount:
|
||||
|
||||
- void **mix_node_set_amount** **(** :ref:`String<class_String>` id, :ref:`float<class_float>` ratio **)**
|
||||
|
||||
Sets the mix amount of a Mix node given its name and value.
|
||||
|
||||
A Mix node adds input b to input a by the amount given by ratio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_node_exists:
|
||||
|
||||
- :ref:`bool<class_bool>` **node_exists** **(** :ref:`String<class_String>` node **)** |const|
|
||||
|
||||
Check if a node exists (by name).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_node_get_input_count:
|
||||
|
||||
- :ref:`int<class_int>` **node_get_input_count** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the input count for a given node. Different types of nodes have different amount of inputs.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_node_get_input_source:
|
||||
|
||||
- :ref:`String<class_String>` **node_get_input_source** **(** :ref:`String<class_String>` id, :ref:`int<class_int>` idx **)** |const|
|
||||
|
||||
Returns the input source for a given node input.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_node_get_position:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **node_get_position** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns position of a node in the graph given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_node_get_type:
|
||||
|
||||
- :ref:`NodeType<enum_AnimationTreePlayer_NodeType>` **node_get_type** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Gets the node type, will return from :ref:`NodeType<enum_AnimationTreePlayer_NodeType>` enum.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_node_rename:
|
||||
|
||||
- :ref:`Error<enum_@GlobalScope_Error>` **node_rename** **(** :ref:`String<class_String>` node, :ref:`String<class_String>` new_name **)**
|
||||
|
||||
Renames a node in the graph.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_node_set_position:
|
||||
|
||||
- void **node_set_position** **(** :ref:`String<class_String>` id, :ref:`Vector2<class_Vector2>` screen_position **)**
|
||||
|
||||
Sets the position of a node in the graph given its name and position.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_get_autorestart_delay:
|
||||
|
||||
- :ref:`float<class_float>` **oneshot_node_get_autorestart_delay** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the autostart delay of a OneShot node given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_get_autorestart_random_delay:
|
||||
|
||||
- :ref:`float<class_float>` **oneshot_node_get_autorestart_random_delay** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the autostart random delay of a OneShot node given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_get_fadein_time:
|
||||
|
||||
- :ref:`float<class_float>` **oneshot_node_get_fadein_time** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the fade in time of a OneShot node given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_get_fadeout_time:
|
||||
|
||||
- :ref:`float<class_float>` **oneshot_node_get_fadeout_time** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the fade out time of a OneShot node given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_has_autorestart:
|
||||
|
||||
- :ref:`bool<class_bool>` **oneshot_node_has_autorestart** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns whether a OneShot node will auto restart given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_is_active:
|
||||
|
||||
- :ref:`bool<class_bool>` **oneshot_node_is_active** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns whether a OneShot node is active given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_set_autorestart:
|
||||
|
||||
- void **oneshot_node_set_autorestart** **(** :ref:`String<class_String>` id, :ref:`bool<class_bool>` enable **)**
|
||||
|
||||
Sets the autorestart property of a OneShot node given its name and value.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_set_autorestart_delay:
|
||||
|
||||
- void **oneshot_node_set_autorestart_delay** **(** :ref:`String<class_String>` id, :ref:`float<class_float>` delay_sec **)**
|
||||
|
||||
Sets the autorestart delay of a OneShot node given its name and value in seconds.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_set_autorestart_random_delay:
|
||||
|
||||
- void **oneshot_node_set_autorestart_random_delay** **(** :ref:`String<class_String>` id, :ref:`float<class_float>` rand_sec **)**
|
||||
|
||||
Sets the autorestart random delay of a OneShot node given its name and value in seconds.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_set_fadein_time:
|
||||
|
||||
- void **oneshot_node_set_fadein_time** **(** :ref:`String<class_String>` id, :ref:`float<class_float>` time_sec **)**
|
||||
|
||||
Sets the fade in time of a OneShot node given its name and value in seconds.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_set_fadeout_time:
|
||||
|
||||
- void **oneshot_node_set_fadeout_time** **(** :ref:`String<class_String>` id, :ref:`float<class_float>` time_sec **)**
|
||||
|
||||
Sets the fade out time of a OneShot node given its name and value in seconds.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_set_filter_path:
|
||||
|
||||
- void **oneshot_node_set_filter_path** **(** :ref:`String<class_String>` id, :ref:`NodePath<class_NodePath>` path, :ref:`bool<class_bool>` enable **)**
|
||||
|
||||
If ``enable`` is ``true``, the OneShot node with ID ``id`` turns off the track modifying the property at ``path``. The modified node's children continue to animate.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_start:
|
||||
|
||||
- void **oneshot_node_start** **(** :ref:`String<class_String>` id **)**
|
||||
|
||||
Starts a OneShot node given its name.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_oneshot_node_stop:
|
||||
|
||||
- void **oneshot_node_stop** **(** :ref:`String<class_String>` id **)**
|
||||
|
||||
Stops the OneShot node with name ``id``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_recompute_caches:
|
||||
|
||||
- void **recompute_caches** **(** **)**
|
||||
|
||||
Manually recalculates the cache of track information generated from animation nodes. Needed when external sources modify the animation nodes' state.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_remove_node:
|
||||
|
||||
- void **remove_node** **(** :ref:`String<class_String>` id **)**
|
||||
|
||||
Removes the animation node with name ``id``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_reset:
|
||||
|
||||
- void **reset** **(** **)**
|
||||
|
||||
Resets this ``AnimationTreePlayer``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_timescale_node_get_scale:
|
||||
|
||||
- :ref:`float<class_float>` **timescale_node_get_scale** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the time scale value of the TimeScale node with name ``id``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_timescale_node_set_scale:
|
||||
|
||||
- void **timescale_node_set_scale** **(** :ref:`String<class_String>` id, :ref:`float<class_float>` scale **)**
|
||||
|
||||
Sets the time scale of the TimeScale node with name ``id`` to ``scale``.
|
||||
|
||||
The TimeScale node is used to speed :ref:`Animation<class_Animation>`\ s up if the scale is above 1 or slow them down if it is below 1.
|
||||
|
||||
If applied after a blend or mix, affects all input animations to that blend or mix.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_timeseek_node_seek:
|
||||
|
||||
- void **timeseek_node_seek** **(** :ref:`String<class_String>` id, :ref:`float<class_float>` seconds **)**
|
||||
|
||||
Sets the time seek value of the TimeSeek node with name ``id`` to ``seconds``.
|
||||
|
||||
This functions as a seek in the :ref:`Animation<class_Animation>` or the blend or mix of :ref:`Animation<class_Animation>`\ s input in it.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_transition_node_delete_input:
|
||||
|
||||
- void **transition_node_delete_input** **(** :ref:`String<class_String>` id, :ref:`int<class_int>` input_idx **)**
|
||||
|
||||
Deletes the input at ``input_idx`` for the transition node with name ``id``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_transition_node_get_current:
|
||||
|
||||
- :ref:`int<class_int>` **transition_node_get_current** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the index of the currently evaluated input for the transition node with name ``id``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_transition_node_get_input_count:
|
||||
|
||||
- :ref:`int<class_int>` **transition_node_get_input_count** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the number of inputs for the transition node with name ``id``. You can add inputs by right-clicking on the transition node.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_transition_node_get_xfade_time:
|
||||
|
||||
- :ref:`float<class_float>` **transition_node_get_xfade_time** **(** :ref:`String<class_String>` id **)** |const|
|
||||
|
||||
Returns the cross fade time for the transition node with name ``id``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_transition_node_has_input_auto_advance:
|
||||
|
||||
- :ref:`bool<class_bool>` **transition_node_has_input_auto_advance** **(** :ref:`String<class_String>` id, :ref:`int<class_int>` input_idx **)** |const|
|
||||
|
||||
Returns ``true`` if the input at ``input_idx`` on the transition node with name ``id`` is set to automatically advance to the next input upon completion.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_transition_node_set_current:
|
||||
|
||||
- void **transition_node_set_current** **(** :ref:`String<class_String>` id, :ref:`int<class_int>` input_idx **)**
|
||||
|
||||
The transition node with name ``id`` sets its current input at ``input_idx``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_transition_node_set_input_auto_advance:
|
||||
|
||||
- void **transition_node_set_input_auto_advance** **(** :ref:`String<class_String>` id, :ref:`int<class_int>` input_idx, :ref:`bool<class_bool>` enable **)**
|
||||
|
||||
The transition node with name ``id`` advances to its next input automatically when the input at ``input_idx`` completes.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_transition_node_set_input_count:
|
||||
|
||||
- void **transition_node_set_input_count** **(** :ref:`String<class_String>` id, :ref:`int<class_int>` count **)**
|
||||
|
||||
Resizes the number of inputs available for the transition node with name ``id``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AnimationTreePlayer_method_transition_node_set_xfade_time:
|
||||
|
||||
- void **transition_node_set_xfade_time** **(** :ref:`String<class_String>` id, :ref:`float<class_float>` time_sec **)**
|
||||
|
||||
The transition node with name ``id`` sets its cross fade time to ``time_sec``.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,516 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the Area.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_Area:
|
||||
|
||||
Area
|
||||
====
|
||||
|
||||
**Inherits:** :ref:`CollisionObject<class_CollisionObject>` **<** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
3D area for detection and physics and audio influence.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
3D area that detects :ref:`CollisionObject<class_CollisionObject>` nodes overlapping, entering, or exiting. Can also alter or override local physics parameters (gravity, damping) and route audio to custom audio buses.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__
|
||||
|
||||
- `GUI in 3D Demo <https://godotengine.org/asset-library/asset/127>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`angular_damp<class_Area_property_angular_damp>` | ``0.1`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`audio_bus_name<class_Area_property_audio_bus_name>` | ``"Master"`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`audio_bus_override<class_Area_property_audio_bus_override>` | ``false`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`gravity<class_Area_property_gravity>` | ``9.8`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`gravity_distance_scale<class_Area_property_gravity_distance_scale>` | ``0.0`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`gravity_point<class_Area_property_gravity_point>` | ``false`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`gravity_vec<class_Area_property_gravity_vec>` | ``Vector3( 0, -1, 0 )`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`linear_damp<class_Area_property_linear_damp>` | ``0.1`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`monitorable<class_Area_property_monitorable>` | ``true`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`monitoring<class_Area_property_monitoring>` | ``true`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`priority<class_Area_property_priority>` | ``0.0`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`reverb_bus_amount<class_Area_property_reverb_bus_amount>` | ``0.0`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`reverb_bus_enable<class_Area_property_reverb_bus_enable>` | ``false`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`reverb_bus_name<class_Area_property_reverb_bus_name>` | ``"Master"`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`reverb_bus_uniformity<class_Area_property_reverb_bus_uniformity>` | ``0.0`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
| :ref:`SpaceOverride<enum_Area_SpaceOverride>` | :ref:`space_override<class_Area_property_space_override>` | ``0`` |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------+-------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------+--------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`get_overlapping_areas<class_Area_method_get_overlapping_areas>` **(** **)** |const| |
|
||||
+---------------------------+--------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`get_overlapping_bodies<class_Area_method_get_overlapping_bodies>` **(** **)** |const| |
|
||||
+---------------------------+--------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`overlaps_area<class_Area_method_overlaps_area>` **(** :ref:`Node<class_Node>` area **)** |const| |
|
||||
+---------------------------+--------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`overlaps_body<class_Area_method_overlaps_body>` **(** :ref:`Node<class_Node>` body **)** |const| |
|
||||
+---------------------------+--------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_Area_signal_area_entered:
|
||||
|
||||
- **area_entered** **(** :ref:`Area<class_Area>` area **)**
|
||||
|
||||
Emitted when another Area enters this Area. Requires :ref:`monitoring<class_Area_property_monitoring>` to be set to ``true``.
|
||||
|
||||
\ ``area`` the other Area.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_signal_area_exited:
|
||||
|
||||
- **area_exited** **(** :ref:`Area<class_Area>` area **)**
|
||||
|
||||
Emitted when another Area exits this Area. Requires :ref:`monitoring<class_Area_property_monitoring>` to be set to ``true``.
|
||||
|
||||
\ ``area`` the other Area.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_signal_area_shape_entered:
|
||||
|
||||
- **area_shape_entered** **(** :ref:`RID<class_RID>` area_rid, :ref:`Area<class_Area>` area, :ref:`int<class_int>` area_shape_index, :ref:`int<class_int>` local_shape_index **)**
|
||||
|
||||
Emitted when one of another Area's :ref:`Shape<class_Shape>`\ s enters one of this Area's :ref:`Shape<class_Shape>`\ s. Requires :ref:`monitoring<class_Area_property_monitoring>` to be set to ``true``.
|
||||
|
||||
\ ``area_rid`` the :ref:`RID<class_RID>` of the other Area's :ref:`CollisionObject<class_CollisionObject>` used by the :ref:`PhysicsServer<class_PhysicsServer>`.
|
||||
|
||||
\ ``area`` the other Area.
|
||||
|
||||
\ ``area_shape_index`` the index of the :ref:`Shape<class_Shape>` of the other Area used by the :ref:`PhysicsServer<class_PhysicsServer>`. Get the :ref:`CollisionShape<class_CollisionShape>` node with ``area.shape_owner_get_owner(area_shape_index)``.
|
||||
|
||||
\ ``local_shape_index`` the index of the :ref:`Shape<class_Shape>` of this Area used by the :ref:`PhysicsServer<class_PhysicsServer>`. Get the :ref:`CollisionShape<class_CollisionShape>` node with ``self.shape_owner_get_owner(local_shape_index)``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_signal_area_shape_exited:
|
||||
|
||||
- **area_shape_exited** **(** :ref:`RID<class_RID>` area_rid, :ref:`Area<class_Area>` area, :ref:`int<class_int>` area_shape_index, :ref:`int<class_int>` local_shape_index **)**
|
||||
|
||||
Emitted when one of another Area's :ref:`Shape<class_Shape>`\ s enters one of this Area's :ref:`Shape<class_Shape>`\ s. Requires :ref:`monitoring<class_Area_property_monitoring>` to be set to ``true``.
|
||||
|
||||
\ ``area_rid`` the :ref:`RID<class_RID>` of the other Area's :ref:`CollisionObject<class_CollisionObject>` used by the :ref:`PhysicsServer<class_PhysicsServer>`.
|
||||
|
||||
\ ``area`` the other Area.
|
||||
|
||||
\ ``area_shape_index`` the index of the :ref:`Shape<class_Shape>` of the other Area used by the :ref:`PhysicsServer<class_PhysicsServer>`. Get the :ref:`CollisionShape<class_CollisionShape>` node with ``area.shape_owner_get_owner(area_shape_index)``.
|
||||
|
||||
\ ``local_shape_index`` the index of the :ref:`Shape<class_Shape>` of this Area used by the :ref:`PhysicsServer<class_PhysicsServer>`. Get the :ref:`CollisionShape<class_CollisionShape>` node with ``self.shape_owner_get_owner(local_shape_index)``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_signal_body_entered:
|
||||
|
||||
- **body_entered** **(** :ref:`Node<class_Node>` body **)**
|
||||
|
||||
Emitted when a :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`GridMap<class_GridMap>` enters this Area. Requires :ref:`monitoring<class_Area_property_monitoring>` to be set to ``true``. :ref:`GridMap<class_GridMap>`\ s are detected if the :ref:`MeshLibrary<class_MeshLibrary>` has Collision :ref:`Shape<class_Shape>`\ s.
|
||||
|
||||
\ ``body`` the :ref:`Node<class_Node>`, if it exists in the tree, of the other :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`GridMap<class_GridMap>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_signal_body_exited:
|
||||
|
||||
- **body_exited** **(** :ref:`Node<class_Node>` body **)**
|
||||
|
||||
Emitted when a :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`GridMap<class_GridMap>` exits this Area. Requires :ref:`monitoring<class_Area_property_monitoring>` to be set to ``true``. :ref:`GridMap<class_GridMap>`\ s are detected if the :ref:`MeshLibrary<class_MeshLibrary>` has Collision :ref:`Shape<class_Shape>`\ s.
|
||||
|
||||
\ ``body`` the :ref:`Node<class_Node>`, if it exists in the tree, of the other :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`GridMap<class_GridMap>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_signal_body_shape_entered:
|
||||
|
||||
- **body_shape_entered** **(** :ref:`RID<class_RID>` body_rid, :ref:`Node<class_Node>` body, :ref:`int<class_int>` body_shape_index, :ref:`int<class_int>` local_shape_index **)**
|
||||
|
||||
Emitted when one of a :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`GridMap<class_GridMap>`'s :ref:`Shape<class_Shape>`\ s enters one of this Area's :ref:`Shape<class_Shape>`\ s. Requires :ref:`monitoring<class_Area_property_monitoring>` to be set to ``true``. :ref:`GridMap<class_GridMap>`\ s are detected if the :ref:`MeshLibrary<class_MeshLibrary>` has Collision :ref:`Shape<class_Shape>`\ s.
|
||||
|
||||
\ ``body_rid`` the :ref:`RID<class_RID>` of the :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`MeshLibrary<class_MeshLibrary>`'s :ref:`CollisionObject<class_CollisionObject>` used by the :ref:`PhysicsServer<class_PhysicsServer>`.
|
||||
|
||||
\ ``body`` the :ref:`Node<class_Node>`, if it exists in the tree, of the :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`GridMap<class_GridMap>`.
|
||||
|
||||
\ ``body_shape_index`` the index of the :ref:`Shape<class_Shape>` of the :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`GridMap<class_GridMap>` used by the :ref:`PhysicsServer<class_PhysicsServer>`. Get the :ref:`CollisionShape<class_CollisionShape>` node with ``body.shape_owner_get_owner(body_shape_index)``.
|
||||
|
||||
\ ``local_shape_index`` the index of the :ref:`Shape<class_Shape>` of this Area used by the :ref:`PhysicsServer<class_PhysicsServer>`. Get the :ref:`CollisionShape<class_CollisionShape>` node with ``self.shape_owner_get_owner(local_shape_index)``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_signal_body_shape_exited:
|
||||
|
||||
- **body_shape_exited** **(** :ref:`RID<class_RID>` body_rid, :ref:`Node<class_Node>` body, :ref:`int<class_int>` body_shape_index, :ref:`int<class_int>` local_shape_index **)**
|
||||
|
||||
Emitted when one of a :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`GridMap<class_GridMap>`'s :ref:`Shape<class_Shape>`\ s enters one of this Area's :ref:`Shape<class_Shape>`\ s. Requires :ref:`monitoring<class_Area_property_monitoring>` to be set to ``true``. :ref:`GridMap<class_GridMap>`\ s are detected if the :ref:`MeshLibrary<class_MeshLibrary>` has Collision :ref:`Shape<class_Shape>`\ s.
|
||||
|
||||
\ ``body_rid`` the :ref:`RID<class_RID>` of the :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`MeshLibrary<class_MeshLibrary>`'s :ref:`CollisionObject<class_CollisionObject>` used by the :ref:`PhysicsServer<class_PhysicsServer>`.
|
||||
|
||||
\ ``body`` the :ref:`Node<class_Node>`, if it exists in the tree, of the :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`GridMap<class_GridMap>`.
|
||||
|
||||
\ ``body_shape_index`` the index of the :ref:`Shape<class_Shape>` of the :ref:`PhysicsBody<class_PhysicsBody>` or :ref:`GridMap<class_GridMap>` used by the :ref:`PhysicsServer<class_PhysicsServer>`. Get the :ref:`CollisionShape<class_CollisionShape>` node with ``body.shape_owner_get_owner(body_shape_index)``.
|
||||
|
||||
\ ``local_shape_index`` the index of the :ref:`Shape<class_Shape>` of this Area used by the :ref:`PhysicsServer<class_PhysicsServer>`. Get the :ref:`CollisionShape<class_CollisionShape>` node with ``self.shape_owner_get_owner(local_shape_index)``.
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_Area_SpaceOverride:
|
||||
|
||||
.. _class_Area_constant_SPACE_OVERRIDE_DISABLED:
|
||||
|
||||
.. _class_Area_constant_SPACE_OVERRIDE_COMBINE:
|
||||
|
||||
.. _class_Area_constant_SPACE_OVERRIDE_COMBINE_REPLACE:
|
||||
|
||||
.. _class_Area_constant_SPACE_OVERRIDE_REPLACE:
|
||||
|
||||
.. _class_Area_constant_SPACE_OVERRIDE_REPLACE_COMBINE:
|
||||
|
||||
enum **SpaceOverride**:
|
||||
|
||||
- **SPACE_OVERRIDE_DISABLED** = **0** --- Esta zona no afecta a la gravedad/amortiguación.
|
||||
|
||||
- **SPACE_OVERRIDE_COMBINE** = **1** --- Esta área añade sus valores de gravedad/amortiguación a lo que se ha calculado hasta ahora (en el orden :ref:`priority<class_Area_property_priority>`).
|
||||
|
||||
- **SPACE_OVERRIDE_COMBINE_REPLACE** = **2** --- Esta área añade sus valores de gravedad/amortiguación a lo que se ha calculado hasta ahora (en el orden :ref:`priority<class_Area_property_priority>`), ignorando cualquier área de menor prioridad.
|
||||
|
||||
- **SPACE_OVERRIDE_REPLACE** = **3** --- Esta área reemplaza cualquier gravedad/amortiguación, incluso las predeterminadas, ignorando cualquier área de menor prioridad.
|
||||
|
||||
- **SPACE_OVERRIDE_REPLACE_COMBINE** = **4** --- Esta área reemplaza cualquier gravedad/amortiguación calculada hasta ahora (en orden de :ref:`priority<class_Area_property_priority>`), pero sigue calculando el resto de las áreas.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_Area_property_angular_damp:
|
||||
|
||||
- :ref:`float<class_float>` **angular_damp**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``0.1`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_angular_damp(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_angular_damp() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
The rate at which objects stop spinning in this area. Represents the angular velocity lost per second.
|
||||
|
||||
See :ref:`ProjectSettings.physics/3d/default_angular_damp<class_ProjectSettings_property_physics/3d/default_angular_damp>` for more details about damping.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_audio_bus_name:
|
||||
|
||||
- :ref:`String<class_String>` **audio_bus_name**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``"Master"`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_audio_bus(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_audio_bus() |
|
||||
+-----------+----------------------+
|
||||
|
||||
El nombre del bus de audio de la zona.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_audio_bus_override:
|
||||
|
||||
- :ref:`bool<class_bool>` **audio_bus_override**
|
||||
|
||||
+-----------+-------------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-------------------------------+
|
||||
| *Setter* | set_audio_bus_override(value) |
|
||||
+-----------+-------------------------------+
|
||||
| *Getter* | is_overriding_audio_bus() |
|
||||
+-----------+-------------------------------+
|
||||
|
||||
Si ``true``, el área del bus de audio sobrescribe el bus de audio por defecto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_gravity:
|
||||
|
||||
- :ref:`float<class_float>` **gravity**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``9.8`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_gravity(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | get_gravity() |
|
||||
+-----------+--------------------+
|
||||
|
||||
The area's gravity intensity (in meters per second squared). This value multiplies the gravity vector. This is useful to alter the force of gravity without altering its direction.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_gravity_distance_scale:
|
||||
|
||||
- :ref:`float<class_float>` **gravity_distance_scale**
|
||||
|
||||
+-----------+-----------------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-----------------------------------+
|
||||
| *Setter* | set_gravity_distance_scale(value) |
|
||||
+-----------+-----------------------------------+
|
||||
| *Getter* | get_gravity_distance_scale() |
|
||||
+-----------+-----------------------------------+
|
||||
|
||||
El factor de caída para la gravedad puntual. Cuanto mayor es el valor, más rápido disminuye la gravedad con la distancia.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_gravity_point:
|
||||
|
||||
- :ref:`bool<class_bool>` **gravity_point**
|
||||
|
||||
+-----------+-----------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-----------------------------+
|
||||
| *Setter* | set_gravity_is_point(value) |
|
||||
+-----------+-----------------------------+
|
||||
| *Getter* | is_gravity_a_point() |
|
||||
+-----------+-----------------------------+
|
||||
|
||||
Si ``true``, la gravedad se calcula a partir de un punto (establecido mediante :ref:`gravity_vec<class_Area_property_gravity_vec>`). Ver también :ref:`space_override<class_Area_property_space_override>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_gravity_vec:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **gravity_vec**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``Vector3( 0, -1, 0 )`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_gravity_vector(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_gravity_vector() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
El vector de gravedad del área (no normalizado). Si la gravedad es un punto (véase :ref:`gravity_point<class_Area_property_gravity_point>`), éste será el punto de atracción.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_linear_damp:
|
||||
|
||||
- :ref:`float<class_float>` **linear_damp**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``0.1`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_linear_damp(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_linear_damp() |
|
||||
+-----------+------------------------+
|
||||
|
||||
The rate at which objects stop moving in this area. Represents the linear velocity lost per second.
|
||||
|
||||
See :ref:`ProjectSettings.physics/3d/default_linear_damp<class_ProjectSettings_property_physics/3d/default_linear_damp>` for more details about damping.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_monitorable:
|
||||
|
||||
- :ref:`bool<class_bool>` **monitorable**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_monitorable(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | is_monitorable() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Si ``true``, otras áreas de monitoreo pueden detectar esta área.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_monitoring:
|
||||
|
||||
- :ref:`bool<class_bool>` **monitoring**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_monitoring(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | is_monitoring() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Si ``true``, el área detecta cuerpos o áreas que entran y salen de ella.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_priority:
|
||||
|
||||
- :ref:`float<class_float>` **priority**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_priority(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_priority() |
|
||||
+-----------+---------------------+
|
||||
|
||||
La prioridad de la zona. Las áreas de mayor prioridad se procesan primero.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_reverb_bus_amount:
|
||||
|
||||
- :ref:`float<class_float>` **reverb_bus_amount**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_reverb_amount(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_reverb_amount() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
El grado en que esta área aplica reverberación a su audio asociado. Va de ``0`` a ``1`` con una precisión de ``0.1``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_reverb_bus_enable:
|
||||
|
||||
- :ref:`bool<class_bool>` **reverb_bus_enable**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_use_reverb_bus(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | is_using_reverb_bus() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
Si ``true``, el área aplica reverberación a su audio asociado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_reverb_bus_name:
|
||||
|
||||
- :ref:`String<class_String>` **reverb_bus_name**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``"Master"`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_reverb_bus(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_reverb_bus() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
El nombre del bus de reverberación que se usará para el audio asociado a esta área.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_reverb_bus_uniformity:
|
||||
|
||||
- :ref:`float<class_float>` **reverb_bus_uniformity**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_reverb_uniformity(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_reverb_uniformity() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
El grado de reverberación de esta área es un efecto uniforme. Va de ``0`` a ``1`` con una precisión de ``0,1``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_property_space_override:
|
||||
|
||||
- :ref:`SpaceOverride<enum_Area_SpaceOverride>` **space_override**
|
||||
|
||||
+-----------+--------------------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+--------------------------------+
|
||||
| *Setter* | set_space_override_mode(value) |
|
||||
+-----------+--------------------------------+
|
||||
| *Getter* | get_space_override_mode() |
|
||||
+-----------+--------------------------------+
|
||||
|
||||
Modo de sobreescritura para los cálculos de gravedad y amortiguación dentro de esta área. Ver :ref:`SpaceOverride<enum_Area_SpaceOverride>` para los posibles valores.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_Area_method_get_overlapping_areas:
|
||||
|
||||
- :ref:`Array<class_Array>` **get_overlapping_areas** **(** **)** |const|
|
||||
|
||||
Returns a list of intersecting ``Area``\ s. The overlapping area's :ref:`CollisionObject.collision_layer<class_CollisionObject_property_collision_layer>` must be part of this area's :ref:`CollisionObject.collision_mask<class_CollisionObject_property_collision_mask>` in order to be detected.
|
||||
|
||||
For performance reasons (collisions are all processed at the same time) this list is modified once during the physics step, not immediately after objects are moved. Consider using signals instead.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_method_get_overlapping_bodies:
|
||||
|
||||
- :ref:`Array<class_Array>` **get_overlapping_bodies** **(** **)** |const|
|
||||
|
||||
Returns a list of intersecting :ref:`PhysicsBody<class_PhysicsBody>`\ s. The overlapping body's :ref:`CollisionObject.collision_layer<class_CollisionObject_property_collision_layer>` must be part of this area's :ref:`CollisionObject.collision_mask<class_CollisionObject_property_collision_mask>` in order to be detected.
|
||||
|
||||
For performance reasons (collisions are all processed at the same time) this list is modified once during the physics step, not immediately after objects are moved. Consider using signals instead.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_method_overlaps_area:
|
||||
|
||||
- :ref:`bool<class_bool>` **overlaps_area** **(** :ref:`Node<class_Node>` area **)** |const|
|
||||
|
||||
If ``true``, the given area overlaps the Area.
|
||||
|
||||
\ **Note:** The result of this test is not immediate after moving objects. For performance, list of overlaps is updated once per frame and before the physics step. Consider using signals instead.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area_method_overlaps_body:
|
||||
|
||||
- :ref:`bool<class_bool>` **overlaps_body** **(** :ref:`Node<class_Node>` body **)** |const|
|
||||
|
||||
If ``true``, the given physics body overlaps the Area.
|
||||
|
||||
\ **Note:** The result of this test is not immediate after moving objects. For performance, list of overlaps is updated once per frame and before the physics step. Consider using signals instead.
|
||||
|
||||
The ``body`` argument can either be a :ref:`PhysicsBody<class_PhysicsBody>` or a :ref:`GridMap<class_GridMap>` instance (while GridMaps are not physics body themselves, they register their tiles with collision shapes as a virtual physics body).
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,448 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the Area2D.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_Area2D:
|
||||
|
||||
Area2D
|
||||
======
|
||||
|
||||
**Inherits:** :ref:`CollisionObject2D<class_CollisionObject2D>` **<** :ref:`Node2D<class_Node2D>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
2D area for detection and physics and audio influence.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
2D area that detects :ref:`CollisionObject2D<class_CollisionObject2D>` nodes overlapping, entering, or exiting. Can also alter or override local physics parameters (gravity, damping) and route audio to a custom audio bus.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Using Area2D <../tutorials/physics/using_area_2d>`
|
||||
|
||||
- `2D Dodge The Creeps Demo <https://godotengine.org/asset-library/asset/515>`__
|
||||
|
||||
- `2D Pong Demo <https://godotengine.org/asset-library/asset/121>`__
|
||||
|
||||
- `2D Platformer Demo <https://godotengine.org/asset-library/asset/120>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`float<class_float>` | :ref:`angular_damp<class_Area2D_property_angular_damp>` | ``1.0`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`String<class_String>` | :ref:`audio_bus_name<class_Area2D_property_audio_bus_name>` | ``"Master"`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`audio_bus_override<class_Area2D_property_audio_bus_override>` | ``false`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`float<class_float>` | :ref:`gravity<class_Area2D_property_gravity>` | ``98.0`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`float<class_float>` | :ref:`gravity_distance_scale<class_Area2D_property_gravity_distance_scale>` | ``0.0`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`gravity_point<class_Area2D_property_gravity_point>` | ``false`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`gravity_vec<class_Area2D_property_gravity_vec>` | ``Vector2( 0, 1 )`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`float<class_float>` | :ref:`linear_damp<class_Area2D_property_linear_damp>` | ``0.1`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`monitorable<class_Area2D_property_monitorable>` | ``true`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`monitoring<class_Area2D_property_monitoring>` | ``true`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`float<class_float>` | :ref:`priority<class_Area2D_property_priority>` | ``0.0`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
| :ref:`SpaceOverride<enum_Area2D_SpaceOverride>` | :ref:`space_override<class_Area2D_property_space_override>` | ``0`` |
|
||||
+-------------------------------------------------+-----------------------------------------------------------------------------+---------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------+----------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`get_overlapping_areas<class_Area2D_method_get_overlapping_areas>` **(** **)** |const| |
|
||||
+---------------------------+----------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`get_overlapping_bodies<class_Area2D_method_get_overlapping_bodies>` **(** **)** |const| |
|
||||
+---------------------------+----------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`overlaps_area<class_Area2D_method_overlaps_area>` **(** :ref:`Node<class_Node>` area **)** |const| |
|
||||
+---------------------------+----------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`overlaps_body<class_Area2D_method_overlaps_body>` **(** :ref:`Node<class_Node>` body **)** |const| |
|
||||
+---------------------------+----------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_Area2D_signal_area_entered:
|
||||
|
||||
- **area_entered** **(** :ref:`Area2D<class_Area2D>` area **)**
|
||||
|
||||
Emitted when another Area2D enters this Area2D. Requires :ref:`monitoring<class_Area2D_property_monitoring>` to be set to ``true``.
|
||||
|
||||
\ ``area`` the other Area2D.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_signal_area_exited:
|
||||
|
||||
- **area_exited** **(** :ref:`Area2D<class_Area2D>` area **)**
|
||||
|
||||
Emitted when another Area2D exits this Area2D. Requires :ref:`monitoring<class_Area2D_property_monitoring>` to be set to ``true``.
|
||||
|
||||
\ ``area`` the other Area2D.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_signal_area_shape_entered:
|
||||
|
||||
- **area_shape_entered** **(** :ref:`RID<class_RID>` area_rid, :ref:`Area2D<class_Area2D>` area, :ref:`int<class_int>` area_shape_index, :ref:`int<class_int>` local_shape_index **)**
|
||||
|
||||
Emitted when one of another Area2D's :ref:`Shape2D<class_Shape2D>`\ s enters one of this Area2D's :ref:`Shape2D<class_Shape2D>`\ s. Requires :ref:`monitoring<class_Area2D_property_monitoring>` to be set to ``true``.
|
||||
|
||||
\ ``area_rid`` the :ref:`RID<class_RID>` of the other Area2D's :ref:`CollisionObject2D<class_CollisionObject2D>` used by the :ref:`Physics2DServer<class_Physics2DServer>`.
|
||||
|
||||
\ ``area`` the other Area2D.
|
||||
|
||||
\ ``area_shape_index`` the index of the :ref:`Shape2D<class_Shape2D>` of the other Area2D used by the :ref:`Physics2DServer<class_Physics2DServer>`. Get the :ref:`CollisionShape2D<class_CollisionShape2D>` node with ``area.shape_owner_get_owner(area_shape_index)``.
|
||||
|
||||
\ ``local_shape_index`` the index of the :ref:`Shape2D<class_Shape2D>` of this Area2D used by the :ref:`Physics2DServer<class_Physics2DServer>`. Get the :ref:`CollisionShape2D<class_CollisionShape2D>` node with ``self.shape_owner_get_owner(local_shape_index)``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_signal_area_shape_exited:
|
||||
|
||||
- **area_shape_exited** **(** :ref:`RID<class_RID>` area_rid, :ref:`Area2D<class_Area2D>` area, :ref:`int<class_int>` area_shape_index, :ref:`int<class_int>` local_shape_index **)**
|
||||
|
||||
Emitted when one of another Area2D's :ref:`Shape2D<class_Shape2D>`\ s exits one of this Area2D's :ref:`Shape2D<class_Shape2D>`\ s. Requires :ref:`monitoring<class_Area2D_property_monitoring>` to be set to ``true``.
|
||||
|
||||
\ ``area_rid`` the :ref:`RID<class_RID>` of the other Area2D's :ref:`CollisionObject2D<class_CollisionObject2D>` used by the :ref:`Physics2DServer<class_Physics2DServer>`.
|
||||
|
||||
\ ``area`` the other Area2D.
|
||||
|
||||
\ ``area_shape_index`` the index of the :ref:`Shape2D<class_Shape2D>` of the other Area2D used by the :ref:`Physics2DServer<class_Physics2DServer>`. Get the :ref:`CollisionShape2D<class_CollisionShape2D>` node with ``area.shape_owner_get_owner(area_shape_index)``.
|
||||
|
||||
\ ``local_shape_index`` the index of the :ref:`Shape2D<class_Shape2D>` of this Area2D used by the :ref:`Physics2DServer<class_Physics2DServer>`. Get the :ref:`CollisionShape2D<class_CollisionShape2D>` node with ``self.shape_owner_get_owner(local_shape_index)``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_signal_body_entered:
|
||||
|
||||
- **body_entered** **(** :ref:`Node<class_Node>` body **)**
|
||||
|
||||
Emitted when a :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileMap<class_TileMap>` enters this Area2D. Requires :ref:`monitoring<class_Area2D_property_monitoring>` to be set to ``true``. :ref:`TileMap<class_TileMap>`\ s are detected if the :ref:`TileSet<class_TileSet>` has Collision :ref:`Shape2D<class_Shape2D>`\ s.
|
||||
|
||||
\ ``body`` the :ref:`Node<class_Node>`, if it exists in the tree, of the other :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileMap<class_TileMap>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_signal_body_exited:
|
||||
|
||||
- **body_exited** **(** :ref:`Node<class_Node>` body **)**
|
||||
|
||||
Emitted when a :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileMap<class_TileMap>` exits this Area2D. Requires :ref:`monitoring<class_Area2D_property_monitoring>` to be set to ``true``. :ref:`TileMap<class_TileMap>`\ s are detected if the :ref:`TileSet<class_TileSet>` has Collision :ref:`Shape2D<class_Shape2D>`\ s.
|
||||
|
||||
\ ``body`` the :ref:`Node<class_Node>`, if it exists in the tree, of the other :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileMap<class_TileMap>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_signal_body_shape_entered:
|
||||
|
||||
- **body_shape_entered** **(** :ref:`RID<class_RID>` body_rid, :ref:`Node<class_Node>` body, :ref:`int<class_int>` body_shape_index, :ref:`int<class_int>` local_shape_index **)**
|
||||
|
||||
Emitted when one of a :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileMap<class_TileMap>`'s :ref:`Shape2D<class_Shape2D>`\ s enters one of this Area2D's :ref:`Shape2D<class_Shape2D>`\ s. Requires :ref:`monitoring<class_Area2D_property_monitoring>` to be set to ``true``. :ref:`TileMap<class_TileMap>`\ s are detected if the :ref:`TileSet<class_TileSet>` has Collision :ref:`Shape2D<class_Shape2D>`\ s.
|
||||
|
||||
\ ``body_rid`` the :ref:`RID<class_RID>` of the :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileSet<class_TileSet>`'s :ref:`CollisionObject2D<class_CollisionObject2D>` used by the :ref:`Physics2DServer<class_Physics2DServer>`.
|
||||
|
||||
\ ``body`` the :ref:`Node<class_Node>`, if it exists in the tree, of the :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileMap<class_TileMap>`.
|
||||
|
||||
\ ``body_shape_index`` the index of the :ref:`Shape2D<class_Shape2D>` of the :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileMap<class_TileMap>` used by the :ref:`Physics2DServer<class_Physics2DServer>`. Get the :ref:`CollisionShape2D<class_CollisionShape2D>` node with ``body.shape_owner_get_owner(body_shape_index)``.
|
||||
|
||||
\ ``local_shape_index`` the index of the :ref:`Shape2D<class_Shape2D>` of this Area2D used by the :ref:`Physics2DServer<class_Physics2DServer>`. Get the :ref:`CollisionShape2D<class_CollisionShape2D>` node with ``self.shape_owner_get_owner(local_shape_index)``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_signal_body_shape_exited:
|
||||
|
||||
- **body_shape_exited** **(** :ref:`RID<class_RID>` body_rid, :ref:`Node<class_Node>` body, :ref:`int<class_int>` body_shape_index, :ref:`int<class_int>` local_shape_index **)**
|
||||
|
||||
Emitted when one of a :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileMap<class_TileMap>`'s :ref:`Shape2D<class_Shape2D>`\ s exits one of this Area2D's :ref:`Shape2D<class_Shape2D>`\ s. Requires :ref:`monitoring<class_Area2D_property_monitoring>` to be set to ``true``. :ref:`TileMap<class_TileMap>`\ s are detected if the :ref:`TileSet<class_TileSet>` has Collision :ref:`Shape2D<class_Shape2D>`\ s.
|
||||
|
||||
\ ``body_rid`` the :ref:`RID<class_RID>` of the :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileSet<class_TileSet>`'s :ref:`CollisionObject2D<class_CollisionObject2D>` used by the :ref:`Physics2DServer<class_Physics2DServer>`.
|
||||
|
||||
\ ``body`` the :ref:`Node<class_Node>`, if it exists in the tree, of the :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileMap<class_TileMap>`.
|
||||
|
||||
\ ``body_shape_index`` the index of the :ref:`Shape2D<class_Shape2D>` of the :ref:`PhysicsBody2D<class_PhysicsBody2D>` or :ref:`TileMap<class_TileMap>` used by the :ref:`Physics2DServer<class_Physics2DServer>`. Get the :ref:`CollisionShape2D<class_CollisionShape2D>` node with ``body.shape_owner_get_owner(body_shape_index)``.
|
||||
|
||||
\ ``local_shape_index`` the index of the :ref:`Shape2D<class_Shape2D>` of this Area2D used by the :ref:`Physics2DServer<class_Physics2DServer>`. Get the :ref:`CollisionShape2D<class_CollisionShape2D>` node with ``self.shape_owner_get_owner(local_shape_index)``.
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_Area2D_SpaceOverride:
|
||||
|
||||
.. _class_Area2D_constant_SPACE_OVERRIDE_DISABLED:
|
||||
|
||||
.. _class_Area2D_constant_SPACE_OVERRIDE_COMBINE:
|
||||
|
||||
.. _class_Area2D_constant_SPACE_OVERRIDE_COMBINE_REPLACE:
|
||||
|
||||
.. _class_Area2D_constant_SPACE_OVERRIDE_REPLACE:
|
||||
|
||||
.. _class_Area2D_constant_SPACE_OVERRIDE_REPLACE_COMBINE:
|
||||
|
||||
enum **SpaceOverride**:
|
||||
|
||||
- **SPACE_OVERRIDE_DISABLED** = **0** --- Esta zona no afecta a la gravedad/amortiguación.
|
||||
|
||||
- **SPACE_OVERRIDE_COMBINE** = **1** --- Esta área añade sus valores de gravedad/amortiguación a lo que se ha calculado hasta ahora (en el orden :ref:`priority<class_Area2D_property_priority>`).
|
||||
|
||||
- **SPACE_OVERRIDE_COMBINE_REPLACE** = **2** --- Esta área añade sus valores de gravedad/amortiguación a lo que se ha calculado hasta ahora (en el orden :ref:`priority<class_Area2D_property_priority>`), ignorando cualquier área de menor prioridad.
|
||||
|
||||
- **SPACE_OVERRIDE_REPLACE** = **3** --- Esta área reemplaza cualquier gravedad/amortiguación, incluso las predeterminadas, ignorando cualquier área de menor prioridad.
|
||||
|
||||
- **SPACE_OVERRIDE_REPLACE_COMBINE** = **4** --- Esta área reemplaza cualquier gravedad/amortiguación calculada hasta ahora (en orden de :ref:`priority<class_Area2D_property_priority>`), pero sigue calculando el resto de las áreas.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_Area2D_property_angular_damp:
|
||||
|
||||
- :ref:`float<class_float>` **angular_damp**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_angular_damp(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_angular_damp() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
The rate at which objects stop spinning in this area. Represents the angular velocity lost per second.
|
||||
|
||||
See :ref:`ProjectSettings.physics/2d/default_angular_damp<class_ProjectSettings_property_physics/2d/default_angular_damp>` for more details about damping.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_property_audio_bus_name:
|
||||
|
||||
- :ref:`String<class_String>` **audio_bus_name**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``"Master"`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_audio_bus_name(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_audio_bus_name() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
El nombre del bus de audio de la zona.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_property_audio_bus_override:
|
||||
|
||||
- :ref:`bool<class_bool>` **audio_bus_override**
|
||||
|
||||
+-----------+-------------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-------------------------------+
|
||||
| *Setter* | set_audio_bus_override(value) |
|
||||
+-----------+-------------------------------+
|
||||
| *Getter* | is_overriding_audio_bus() |
|
||||
+-----------+-------------------------------+
|
||||
|
||||
Si ``true``, el área del bus de audio sobrescribe el bus de audio por defecto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_property_gravity:
|
||||
|
||||
- :ref:`float<class_float>` **gravity**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``98.0`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_gravity(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | get_gravity() |
|
||||
+-----------+--------------------+
|
||||
|
||||
The area's gravity intensity (in pixels per second squared). This value multiplies the gravity vector. This is useful to alter the force of gravity without altering its direction.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_property_gravity_distance_scale:
|
||||
|
||||
- :ref:`float<class_float>` **gravity_distance_scale**
|
||||
|
||||
+-----------+-----------------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-----------------------------------+
|
||||
| *Setter* | set_gravity_distance_scale(value) |
|
||||
+-----------+-----------------------------------+
|
||||
| *Getter* | get_gravity_distance_scale() |
|
||||
+-----------+-----------------------------------+
|
||||
|
||||
El factor de caída para la gravedad puntual. Cuanto mayor es el valor, más rápido disminuye la gravedad con la distancia.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_property_gravity_point:
|
||||
|
||||
- :ref:`bool<class_bool>` **gravity_point**
|
||||
|
||||
+-----------+-----------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-----------------------------+
|
||||
| *Setter* | set_gravity_is_point(value) |
|
||||
+-----------+-----------------------------+
|
||||
| *Getter* | is_gravity_a_point() |
|
||||
+-----------+-----------------------------+
|
||||
|
||||
Si ``true``, la gravedad se calcula a partir de un punto (establecido mediante :ref:`gravity_vec<class_Area2D_property_gravity_vec>`). Ver también :ref:`space_override<class_Area2D_property_space_override>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_property_gravity_vec:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **gravity_vec**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``Vector2( 0, 1 )`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_gravity_vector(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_gravity_vector() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
El vector de gravedad del área (no normalizado). Si la gravedad es un punto (véase :ref:`gravity_point<class_Area2D_property_gravity_point>`), éste será el punto de atracción.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_property_linear_damp:
|
||||
|
||||
- :ref:`float<class_float>` **linear_damp**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``0.1`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_linear_damp(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_linear_damp() |
|
||||
+-----------+------------------------+
|
||||
|
||||
The rate at which objects stop moving in this area. Represents the linear velocity lost per second.
|
||||
|
||||
See :ref:`ProjectSettings.physics/2d/default_linear_damp<class_ProjectSettings_property_physics/2d/default_linear_damp>` for more details about damping.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_property_monitorable:
|
||||
|
||||
- :ref:`bool<class_bool>` **monitorable**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_monitorable(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | is_monitorable() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Si ``true``, otras áreas de monitoreo pueden detectar esta área.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_property_monitoring:
|
||||
|
||||
- :ref:`bool<class_bool>` **monitoring**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_monitoring(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | is_monitoring() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Si ``true``, el área detecta cuerpos o áreas que entran y salen de ella.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_property_priority:
|
||||
|
||||
- :ref:`float<class_float>` **priority**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_priority(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_priority() |
|
||||
+-----------+---------------------+
|
||||
|
||||
La prioridad de la zona. Las áreas de mayor prioridad se procesan primero.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_property_space_override:
|
||||
|
||||
- :ref:`SpaceOverride<enum_Area2D_SpaceOverride>` **space_override**
|
||||
|
||||
+-----------+--------------------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+--------------------------------+
|
||||
| *Setter* | set_space_override_mode(value) |
|
||||
+-----------+--------------------------------+
|
||||
| *Getter* | get_space_override_mode() |
|
||||
+-----------+--------------------------------+
|
||||
|
||||
Modo de sobreescritura para los cálculos de gravedad y amortiguación dentro de esta área. Ver :ref:`SpaceOverride<enum_Area2D_SpaceOverride>` para los posibles valores.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_Area2D_method_get_overlapping_areas:
|
||||
|
||||
- :ref:`Array<class_Array>` **get_overlapping_areas** **(** **)** |const|
|
||||
|
||||
Returns a list of intersecting ``Area2D``\ s. The overlapping area's :ref:`CollisionObject2D.collision_layer<class_CollisionObject2D_property_collision_layer>` must be part of this area's :ref:`CollisionObject2D.collision_mask<class_CollisionObject2D_property_collision_mask>` in order to be detected.
|
||||
|
||||
For performance reasons (collisions are all processed at the same time) this list is modified once during the physics step, not immediately after objects are moved. Consider using signals instead.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_method_get_overlapping_bodies:
|
||||
|
||||
- :ref:`Array<class_Array>` **get_overlapping_bodies** **(** **)** |const|
|
||||
|
||||
Returns a list of intersecting :ref:`PhysicsBody2D<class_PhysicsBody2D>`\ s. The overlapping body's :ref:`CollisionObject2D.collision_layer<class_CollisionObject2D_property_collision_layer>` must be part of this area's :ref:`CollisionObject2D.collision_mask<class_CollisionObject2D_property_collision_mask>` in order to be detected.
|
||||
|
||||
For performance reasons (collisions are all processed at the same time) this list is modified once during the physics step, not immediately after objects are moved. Consider using signals instead.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_method_overlaps_area:
|
||||
|
||||
- :ref:`bool<class_bool>` **overlaps_area** **(** :ref:`Node<class_Node>` area **)** |const|
|
||||
|
||||
If ``true``, the given area overlaps the Area2D.
|
||||
|
||||
\ **Note:** The result of this test is not immediate after moving objects. For performance, the list of overlaps is updated once per frame and before the physics step. Consider using signals instead.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Area2D_method_overlaps_body:
|
||||
|
||||
- :ref:`bool<class_bool>` **overlaps_body** **(** :ref:`Node<class_Node>` body **)** |const|
|
||||
|
||||
If ``true``, the given physics body overlaps the Area2D.
|
||||
|
||||
\ **Note:** The result of this test is not immediate after moving objects. For performance, list of overlaps is updated once per frame and before the physics step. Consider using signals instead.
|
||||
|
||||
The ``body`` argument can either be a :ref:`PhysicsBody2D<class_PhysicsBody2D>` or a :ref:`TileMap<class_TileMap>` instance (while TileMaps are not physics bodies themselves, they register their tiles with collision shapes as a virtual physics body).
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,529 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the Array.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_Array:
|
||||
|
||||
Array
|
||||
=====
|
||||
|
||||
A generic array datatype.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
A generic array that can contain several elements of any type, accessible by a numerical index starting at 0. Negative indices can be used to count from the back, like in Python (-1 is the last element, -2 is the second to last, etc.).
|
||||
|
||||
\ **Example:**\
|
||||
|
||||
::
|
||||
|
||||
var array = ["One", 2, 3, "Four"]
|
||||
print(array[0]) # One.
|
||||
print(array[2]) # 3.
|
||||
print(array[-1]) # Four.
|
||||
array[2] = "Three"
|
||||
print(array[-2]) # Three.
|
||||
|
||||
Arrays can be concatenated using the ``+`` operator:
|
||||
|
||||
::
|
||||
|
||||
var array1 = ["One", 2]
|
||||
var array2 = [3, "Four"]
|
||||
print(array1 + array2) # ["One", 2, 3, "Four"]
|
||||
|
||||
\ **Note:** Concatenating with the ``+=`` operator will create a new array, which has a cost. If you want to append another array to an existing array, :ref:`append_array<class_Array_method_append_array>` is more efficient.
|
||||
|
||||
\ **Note:** Arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use :ref:`duplicate<class_Array_method_duplicate>`.
|
||||
|
||||
\ **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.
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`Array<class_Array_method_Array>` **(** :ref:`PoolColorArray<class_PoolColorArray>` from **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`Array<class_Array_method_Array>` **(** :ref:`PoolVector3Array<class_PoolVector3Array>` from **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`Array<class_Array_method_Array>` **(** :ref:`PoolVector2Array<class_PoolVector2Array>` from **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`Array<class_Array_method_Array>` **(** :ref:`PoolStringArray<class_PoolStringArray>` from **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`Array<class_Array_method_Array>` **(** :ref:`PoolRealArray<class_PoolRealArray>` from **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`Array<class_Array_method_Array>` **(** :ref:`PoolIntArray<class_PoolIntArray>` from **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`Array<class_Array_method_Array>` **(** :ref:`PoolByteArray<class_PoolByteArray>` from **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`append<class_Array_method_append>` **(** :ref:`Variant<class_Variant>` value **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`append_array<class_Array_method_append_array>` **(** :ref:`Array<class_Array>` array **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Variant<class_Variant>` | :ref:`back<class_Array_method_back>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`bsearch<class_Array_method_bsearch>` **(** :ref:`Variant<class_Variant>` value, :ref:`bool<class_bool>` before=true **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`bsearch_custom<class_Array_method_bsearch_custom>` **(** :ref:`Variant<class_Variant>` value, :ref:`Object<class_Object>` obj, :ref:`String<class_String>` func, :ref:`bool<class_bool>` before=true **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear<class_Array_method_clear>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`count<class_Array_method_count>` **(** :ref:`Variant<class_Variant>` value **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`duplicate<class_Array_method_duplicate>` **(** :ref:`bool<class_bool>` deep=false **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`empty<class_Array_method_empty>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`erase<class_Array_method_erase>` **(** :ref:`Variant<class_Variant>` value **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`find<class_Array_method_find>` **(** :ref:`Variant<class_Variant>` what, :ref:`int<class_int>` from=0 **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`find_last<class_Array_method_find_last>` **(** :ref:`Variant<class_Variant>` value **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Variant<class_Variant>` | :ref:`front<class_Array_method_front>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`has<class_Array_method_has>` **(** :ref:`Variant<class_Variant>` value **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`hash<class_Array_method_hash>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`insert<class_Array_method_insert>` **(** :ref:`int<class_int>` position, :ref:`Variant<class_Variant>` value **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`invert<class_Array_method_invert>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Variant<class_Variant>` | :ref:`max<class_Array_method_max>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Variant<class_Variant>` | :ref:`min<class_Array_method_min>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Variant<class_Variant>` | :ref:`pop_at<class_Array_method_pop_at>` **(** :ref:`int<class_int>` position **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Variant<class_Variant>` | :ref:`pop_back<class_Array_method_pop_back>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Variant<class_Variant>` | :ref:`pop_front<class_Array_method_pop_front>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`push_back<class_Array_method_push_back>` **(** :ref:`Variant<class_Variant>` value **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`push_front<class_Array_method_push_front>` **(** :ref:`Variant<class_Variant>` value **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove<class_Array_method_remove>` **(** :ref:`int<class_int>` position **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`resize<class_Array_method_resize>` **(** :ref:`int<class_int>` size **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`rfind<class_Array_method_rfind>` **(** :ref:`Variant<class_Variant>` what, :ref:`int<class_int>` from=-1 **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`shuffle<class_Array_method_shuffle>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`size<class_Array_method_size>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`slice<class_Array_method_slice>` **(** :ref:`int<class_int>` begin, :ref:`int<class_int>` end, :ref:`int<class_int>` step=1, :ref:`bool<class_bool>` deep=false **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`sort<class_Array_method_sort>` **(** **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`sort_custom<class_Array_method_sort_custom>` **(** :ref:`Object<class_Object>` obj, :ref:`String<class_String>` func **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_Array_method_Array:
|
||||
|
||||
- :ref:`Array<class_Array>` **Array** **(** :ref:`PoolColorArray<class_PoolColorArray>` from **)**
|
||||
|
||||
Constructs an array from a :ref:`PoolColorArray<class_PoolColorArray>`.
|
||||
|
||||
----
|
||||
|
||||
- :ref:`Array<class_Array>` **Array** **(** :ref:`PoolVector3Array<class_PoolVector3Array>` from **)**
|
||||
|
||||
Constructs an array from a :ref:`PoolVector3Array<class_PoolVector3Array>`.
|
||||
|
||||
----
|
||||
|
||||
- :ref:`Array<class_Array>` **Array** **(** :ref:`PoolVector2Array<class_PoolVector2Array>` from **)**
|
||||
|
||||
Constructs an array from a :ref:`PoolVector2Array<class_PoolVector2Array>`.
|
||||
|
||||
----
|
||||
|
||||
- :ref:`Array<class_Array>` **Array** **(** :ref:`PoolStringArray<class_PoolStringArray>` from **)**
|
||||
|
||||
Constructs an array from a :ref:`PoolStringArray<class_PoolStringArray>`.
|
||||
|
||||
----
|
||||
|
||||
- :ref:`Array<class_Array>` **Array** **(** :ref:`PoolRealArray<class_PoolRealArray>` from **)**
|
||||
|
||||
Constructs an array from a :ref:`PoolRealArray<class_PoolRealArray>`.
|
||||
|
||||
----
|
||||
|
||||
- :ref:`Array<class_Array>` **Array** **(** :ref:`PoolIntArray<class_PoolIntArray>` from **)**
|
||||
|
||||
Constructs an array from a :ref:`PoolIntArray<class_PoolIntArray>`.
|
||||
|
||||
----
|
||||
|
||||
- :ref:`Array<class_Array>` **Array** **(** :ref:`PoolByteArray<class_PoolByteArray>` from **)**
|
||||
|
||||
Constructs an array from a :ref:`PoolByteArray<class_PoolByteArray>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_append:
|
||||
|
||||
- void **append** **(** :ref:`Variant<class_Variant>` value **)**
|
||||
|
||||
Concatena un elemento al final del array (alias de :ref:`push_back<class_Array_method_push_back>`).
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_append_array:
|
||||
|
||||
- void **append_array** **(** :ref:`Array<class_Array>` array **)**
|
||||
|
||||
Appends another array at the end of this array.
|
||||
|
||||
::
|
||||
|
||||
var array1 = [1, 2, 3]
|
||||
var array2 = [4, 5, 6]
|
||||
array1.append_array(array2)
|
||||
print(array1) # Prints [1, 2, 3, 4, 5, 6].
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_back:
|
||||
|
||||
- :ref:`Variant<class_Variant>` **back** **(** **)**
|
||||
|
||||
Returns the last element of the array. Prints an error and returns ``null`` if the array is empty.
|
||||
|
||||
\ **Note:** Calling this function is not the same as writing ``array[-1]``. If the array is empty, accessing by index will pause project execution when running from the editor.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_bsearch:
|
||||
|
||||
- :ref:`int<class_int>` **bsearch** **(** :ref:`Variant<class_Variant>` value, :ref:`bool<class_bool>` before=true **)**
|
||||
|
||||
Encuentra el indice de un valor existente (o el indice de insercion que mantiene el ordenamiento, si el valor no esta todavia presente en el array) usando busqueda binario. Opcionalmente, un especificador ``before`` puede ser pasado. Si ``false``, el indice devuelto vendra despues de todas las entradas existentes del valor en el array.
|
||||
|
||||
\ **Nota:** Llama al :ref:`bsearch<class_Array_method_bsearch>` en un array sin ordenar causara comportamientos inesperados.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_bsearch_custom:
|
||||
|
||||
- :ref:`int<class_int>` **bsearch_custom** **(** :ref:`Variant<class_Variant>` value, :ref:`Object<class_Object>` obj, :ref:`String<class_String>` func, :ref:`bool<class_bool>` before=true **)**
|
||||
|
||||
Finds the index of an existing value (or the insertion index that maintains sorting order, if the value is not yet present in the array) using binary search and a custom comparison method declared in the ``obj``. Optionally, a ``before`` specifier can be passed. If ``false``, the returned index comes after all existing entries of the value in the array. The custom method receives two arguments (an element from the array and the value searched for) and must return ``true`` if the first argument is less than the second, and return ``false`` otherwise.
|
||||
|
||||
::
|
||||
|
||||
func cardinal_to_algebraic(a):
|
||||
match a:
|
||||
"one":
|
||||
return 1
|
||||
"two":
|
||||
return 2
|
||||
"three":
|
||||
return 3
|
||||
"four":
|
||||
return 4
|
||||
_:
|
||||
return 0
|
||||
|
||||
func compare(a, b):
|
||||
return cardinal_to_algebraic(a) < cardinal_to_algebraic(b)
|
||||
|
||||
func _ready():
|
||||
var a = ["one", "two", "three", "four"]
|
||||
# `compare` is defined in this object, so we use `self` as the `obj` parameter.
|
||||
print(a.bsearch_custom("three", self, "compare", true)) # Expected value is 2.
|
||||
|
||||
\ **Note:** Calling :ref:`bsearch_custom<class_Array_method_bsearch_custom>` on an unsorted array results in unexpected behavior.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_clear:
|
||||
|
||||
- void **clear** **(** **)**
|
||||
|
||||
Limpia el array. Esto es equivalente a usar :ref:`resize<class_Array_method_resize>` con un tamaño de ``0``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_count:
|
||||
|
||||
- :ref:`int<class_int>` **count** **(** :ref:`Variant<class_Variant>` value **)**
|
||||
|
||||
Devuelve el numer de veces que un elemento es encuentra en el array.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_duplicate:
|
||||
|
||||
- :ref:`Array<class_Array>` **duplicate** **(** :ref:`bool<class_bool>` deep=false **)**
|
||||
|
||||
Devuelve una copia del array.
|
||||
|
||||
Si ``deep`` es ``true``, a copia profunda es ejecutada: todos los arrays anidados y diccionarios son duplicados y no seran compartidos con el array original. Si ``false``, una copia superificial es dada y las referencias a los arrays anidados y los diccionarios son mantenidos, por lo que modificar un sub-array or diccionario en la copia tambien cambiara estas referencias en el array fuente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_empty:
|
||||
|
||||
- :ref:`bool<class_bool>` **empty** **(** **)**
|
||||
|
||||
Devuelve ``true`` si el array es vacio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_erase:
|
||||
|
||||
- void **erase** **(** :ref:`Variant<class_Variant>` value **)**
|
||||
|
||||
Removes the first occurrence of a value from the array. To remove an element by index, use :ref:`remove<class_Array_method_remove>` instead.
|
||||
|
||||
\ **Note:** This method acts in-place and doesn't return a value.
|
||||
|
||||
\ **Note:** On large arrays, this method will be slower if the removed element is close to the beginning of the array (index 0). This is because all elements placed after the removed element have to be reindexed.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_find:
|
||||
|
||||
- :ref:`int<class_int>` **find** **(** :ref:`Variant<class_Variant>` what, :ref:`int<class_int>` from=0 **)**
|
||||
|
||||
Busca el array por un valor y devuelve su indice o ``-1`` sino se encuentra. Opcionalmente, el indice de busqueda inicial puede ser pasado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_find_last:
|
||||
|
||||
- :ref:`int<class_int>` **find_last** **(** :ref:`Variant<class_Variant>` value **)**
|
||||
|
||||
Busca el array en orden inverso por un valor y devuelve su indice o ``-1`` sino es encontrado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_front:
|
||||
|
||||
- :ref:`Variant<class_Variant>` **front** **(** **)**
|
||||
|
||||
Returns the first element of the array. Prints an error and returns ``null`` if the array is empty.
|
||||
|
||||
\ **Note:** Calling this function is not the same as writing ``array[0]``. If the array is empty, accessing by index will pause project execution when running from the editor.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_has:
|
||||
|
||||
- :ref:`bool<class_bool>` **has** **(** :ref:`Variant<class_Variant>` value **)**
|
||||
|
||||
Returns ``true`` if the array contains the given value.
|
||||
|
||||
::
|
||||
|
||||
["inside", 7].has("inside") # True
|
||||
["inside", 7].has("outside") # False
|
||||
["inside", 7].has(7) # True
|
||||
["inside", 7].has("7") # False
|
||||
|
||||
\ **Note:** This is equivalent to using the ``in`` operator as follows:
|
||||
|
||||
::
|
||||
|
||||
# Will evaluate to `true`.
|
||||
if 2 in [2, 4, 6, 8]:
|
||||
pass
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_hash:
|
||||
|
||||
- :ref:`int<class_int>` **hash** **(** **)**
|
||||
|
||||
Returns a hashed integer value representing the array and its contents.
|
||||
|
||||
\ **Note:** Arrays with equal contents can still produce different hashes. Only the exact same arrays will produce the same hashed integer value.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_insert:
|
||||
|
||||
- void **insert** **(** :ref:`int<class_int>` position, :ref:`Variant<class_Variant>` value **)**
|
||||
|
||||
Inserta un nuevo elemento en la posisción dada en el array. La posición debe ser valida, o al final de el array(``pos == size()``.
|
||||
|
||||
\ **Note:** este metodo actua en el lugar y no devuelve ningún valor.
|
||||
|
||||
\ **Note:** en arrays largos, este metodo va a ser mas lento si el elemento incertado esta cerca al inicio del array (índice 0). Esto es por que todos los elementos despues del elemento incertado tienen que ser reindisados.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_invert:
|
||||
|
||||
- void **invert** **(** **)**
|
||||
|
||||
Invierte el orden de los elementos en el array.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_max:
|
||||
|
||||
- :ref:`Variant<class_Variant>` **max** **(** **)**
|
||||
|
||||
Devuelve el maximo valor contenido en el array si todos los elementos son de tipos comparables. Si los elementos no pueden ser comparados, ``null`` es devuelto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_min:
|
||||
|
||||
- :ref:`Variant<class_Variant>` **min** **(** **)**
|
||||
|
||||
Devuelve el minimo valor contenido en el array si todos los elementos son de tipos comparables. Si los elementos no pueden ser comparados, ``null`` es devuelto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_pop_at:
|
||||
|
||||
- :ref:`Variant<class_Variant>` **pop_at** **(** :ref:`int<class_int>` position **)**
|
||||
|
||||
Removes and returns the element of the array at index ``position``. If negative, ``position`` is considered relative to the end of the array. Leaves the array untouched and returns ``null`` if the array is empty or if it's accessed out of bounds. An error message is printed when the array is accessed out of bounds, but not when the array is empty.
|
||||
|
||||
\ **Note:** On large arrays, this method can be slower than :ref:`pop_back<class_Array_method_pop_back>` as it will reindex the array's elements that are located after the removed element. The larger the array and the lower the index of the removed element, the slower :ref:`pop_at<class_Array_method_pop_at>` will be.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_pop_back:
|
||||
|
||||
- :ref:`Variant<class_Variant>` **pop_back** **(** **)**
|
||||
|
||||
Removes and returns the last element of the array. Returns ``null`` if the array is empty, without printing an error message. See also :ref:`pop_front<class_Array_method_pop_front>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_pop_front:
|
||||
|
||||
- :ref:`Variant<class_Variant>` **pop_front** **(** **)**
|
||||
|
||||
Removes and returns the first element of the array. Returns ``null`` if the array is empty, without printing an error message. See also :ref:`pop_back<class_Array_method_pop_back>`.
|
||||
|
||||
\ **Note:** On large arrays, this method is much slower than :ref:`pop_back<class_Array_method_pop_back>` as it will reindex all the array's elements every time it's called. The larger the array, the slower :ref:`pop_front<class_Array_method_pop_front>` will be.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_push_back:
|
||||
|
||||
- void **push_back** **(** :ref:`Variant<class_Variant>` value **)**
|
||||
|
||||
Appends an element at the end of the array. See also :ref:`push_front<class_Array_method_push_front>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_push_front:
|
||||
|
||||
- void **push_front** **(** :ref:`Variant<class_Variant>` value **)**
|
||||
|
||||
Adds an element at the beginning of the array. See also :ref:`push_back<class_Array_method_push_back>`.
|
||||
|
||||
\ **Note:** On large arrays, this method is much slower than :ref:`push_back<class_Array_method_push_back>` as it will reindex all the array's elements every time it's called. The larger the array, the slower :ref:`push_front<class_Array_method_push_front>` will be.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_remove:
|
||||
|
||||
- void **remove** **(** :ref:`int<class_int>` position **)**
|
||||
|
||||
Removes an element from the array by index. If the index does not exist in the array, nothing happens. To remove an element by searching for its value, use :ref:`erase<class_Array_method_erase>` instead.
|
||||
|
||||
\ **Note:** This method acts in-place and doesn't return a value.
|
||||
|
||||
\ **Note:** On large arrays, this method will be slower if the removed element is close to the beginning of the array (index 0). This is because all elements placed after the removed element have to be reindexed.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_resize:
|
||||
|
||||
- void **resize** **(** :ref:`int<class_int>` size **)**
|
||||
|
||||
Cambiar el tamaño del array para contener un numero diferente de elementos. Si el array es menor, los elementos so limipiados, si mayor, los nuevos elementos son ``null``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_rfind:
|
||||
|
||||
- :ref:`int<class_int>` **rfind** **(** :ref:`Variant<class_Variant>` what, :ref:`int<class_int>` from=-1 **)**
|
||||
|
||||
Busca el array en orden inverso. Opcionalmente, un indice de comienzo de busqueda puede ser pasado. Si negacion, el indice de comienzo es considerado relativo al final del array.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_shuffle:
|
||||
|
||||
- void **shuffle** **(** **)**
|
||||
|
||||
Baraja el array de forma que los items tengan un orden aleatorio. Este metodo uso el generador de numeros globales aleatorios comun de metodos como :ref:`@GDScript.randi<class_@GDScript_method_randi>`. Llamar :ref:`@GDScript.randomize<class_@GDScript_method_randomize>` para asegurar que una nueva semilla sea utilizada cada vez si tu no quieres reproducir el orden de los items.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_size:
|
||||
|
||||
- :ref:`int<class_int>` **size** **(** **)**
|
||||
|
||||
Devuelve el numer de elementos en el array.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_slice:
|
||||
|
||||
- :ref:`Array<class_Array>` **slice** **(** :ref:`int<class_int>` begin, :ref:`int<class_int>` end, :ref:`int<class_int>` step=1, :ref:`bool<class_bool>` deep=false **)**
|
||||
|
||||
Duplica el subset descrito en la funcion y lo devuelve en un array, copiando profundamente el array si ``deep`` es ``true``. Bajos y altos indices estan incluidos, cone el ``step]`` describiendo el cambio entre indices mientras se trocean.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_sort:
|
||||
|
||||
- void **sort** **(** **)**
|
||||
|
||||
Ordena el array.
|
||||
|
||||
\ **Nota:** Las strings son ordenadas en orden alfabetico ( opuesto al orden natural). Esto puede llevar a comportamientos inesperados cuando se ordene un array de strings con una sequencia de numeros, considera lo siguiente:
|
||||
|
||||
::
|
||||
|
||||
var strings = ["string1", "string2", "string10", "string11"]
|
||||
strings.sort()
|
||||
print(strings) # Imprime [string1, string10, string11, string2]
|
||||
|
||||
----
|
||||
|
||||
.. _class_Array_method_sort_custom:
|
||||
|
||||
- void **sort_custom** **(** :ref:`Object<class_Object>` obj, :ref:`String<class_String>` func **)**
|
||||
|
||||
Sorts the array using a custom method. The arguments are an object that holds the method and the name of such method. The custom method receives two arguments (a pair of elements from the array) and must return either ``true`` or ``false``.
|
||||
|
||||
For two elements ``a`` and ``b``, if the given method returns ``true``, element ``b`` will be after element ``a`` in the array.
|
||||
|
||||
\ **Note:** You cannot randomize the return value as the heapsort algorithm expects a deterministic result. Doing so will result in unexpected behavior.
|
||||
|
||||
::
|
||||
|
||||
class MyCustomSorter:
|
||||
static func sort_ascending(a, b):
|
||||
if a[0] < b[0]:
|
||||
return true
|
||||
return false
|
||||
|
||||
var my_items = [[5, "Potato"], [9, "Rice"], [4, "Tomato"]]
|
||||
my_items.sort_custom(MyCustomSorter, "sort_ascending")
|
||||
print(my_items) # Prints [[4, Tomato], [5, Potato], [9, Rice]].
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,386 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the ArrayMesh.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_ArrayMesh:
|
||||
|
||||
ArrayMesh
|
||||
=========
|
||||
|
||||
**Inherits:** :ref:`Mesh<class_Mesh>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Tipo :ref:`Mesh<class_Mesh>` que provee la funcionalidad para construir una superficie desde arrays.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
The ``ArrayMesh`` is used to construct a :ref:`Mesh<class_Mesh>` by specifying the attributes as arrays.
|
||||
|
||||
The most basic example is the creation of a single triangle:
|
||||
|
||||
::
|
||||
|
||||
var vertices = PoolVector3Array()
|
||||
vertices.push_back(Vector3(0, 1, 0))
|
||||
vertices.push_back(Vector3(1, 0, 0))
|
||||
vertices.push_back(Vector3(0, 0, 1))
|
||||
# Initialize the ArrayMesh.
|
||||
var arr_mesh = ArrayMesh.new()
|
||||
var arrays = []
|
||||
arrays.resize(ArrayMesh.ARRAY_MAX)
|
||||
arrays[ArrayMesh.ARRAY_VERTEX] = vertices
|
||||
# Create the Mesh.
|
||||
arr_mesh.add_surface_from_arrays(Mesh.PRIMITIVE_TRIANGLES, arrays)
|
||||
var m = MeshInstance.new()
|
||||
m.mesh = arr_mesh
|
||||
|
||||
The :ref:`MeshInstance<class_MeshInstance>` is ready to be added to the :ref:`SceneTree<class_SceneTree>` to be shown.
|
||||
|
||||
See also :ref:`ImmediateGeometry<class_ImmediateGeometry>`, :ref:`MeshDataTool<class_MeshDataTool>` and :ref:`SurfaceTool<class_SurfaceTool>` for procedural geometry generation.
|
||||
|
||||
\ **Note:** Godot uses clockwise `winding order <https://learnopengl.com/Advanced-OpenGL/Face-culling>`__ for front faces of triangle primitive modes.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/3d/procedural_geometry/arraymesh`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------------------------------+--------------------------------------------------------------------+------------------------------+
|
||||
| :ref:`BlendShapeMode<enum_Mesh_BlendShapeMode>` | :ref:`blend_shape_mode<class_ArrayMesh_property_blend_shape_mode>` | ``1`` |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------+------------------------------+
|
||||
| :ref:`AABB<class_AABB>` | :ref:`custom_aabb<class_ArrayMesh_property_custom_aabb>` | ``AABB( 0, 0, 0, 0, 0, 0 )`` |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------+------------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_blend_shape<class_ArrayMesh_method_add_blend_shape>` **(** :ref:`String<class_String>` name **)** |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_surface_from_arrays<class_ArrayMesh_method_add_surface_from_arrays>` **(** :ref:`PrimitiveType<enum_Mesh_PrimitiveType>` primitive, :ref:`Array<class_Array>` arrays, :ref:`Array<class_Array>` blend_shapes=[ ], :ref:`int<class_int>` compress_flags=2194432 **)** |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear_blend_shapes<class_ArrayMesh_method_clear_blend_shapes>` **(** **)** |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear_surfaces<class_ArrayMesh_method_clear_surfaces>` **(** **)** |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_blend_shape_count<class_ArrayMesh_method_get_blend_shape_count>` **(** **)** |const| |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_blend_shape_name<class_ArrayMesh_method_get_blend_shape_name>` **(** :ref:`int<class_int>` index **)** |const| |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Error<enum_@GlobalScope_Error>` | :ref:`lightmap_unwrap<class_ArrayMesh_method_lightmap_unwrap>` **(** :ref:`Transform<class_Transform>` transform, :ref:`float<class_float>` texel_size **)** |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`regen_normalmaps<class_ArrayMesh_method_regen_normalmaps>` **(** **)** |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_blend_shape_name<class_ArrayMesh_method_set_blend_shape_name>` **(** :ref:`int<class_int>` index, :ref:`String<class_String>` name **)** |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`surface_find_by_name<class_ArrayMesh_method_surface_find_by_name>` **(** :ref:`String<class_String>` name **)** |const| |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`surface_get_array_index_len<class_ArrayMesh_method_surface_get_array_index_len>` **(** :ref:`int<class_int>` surf_idx **)** |const| |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`surface_get_array_len<class_ArrayMesh_method_surface_get_array_len>` **(** :ref:`int<class_int>` surf_idx **)** |const| |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`surface_get_format<class_ArrayMesh_method_surface_get_format>` **(** :ref:`int<class_int>` surf_idx **)** |const| |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`surface_get_name<class_ArrayMesh_method_surface_get_name>` **(** :ref:`int<class_int>` surf_idx **)** |const| |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PrimitiveType<enum_Mesh_PrimitiveType>` | :ref:`surface_get_primitive_type<class_ArrayMesh_method_surface_get_primitive_type>` **(** :ref:`int<class_int>` surf_idx **)** |const| |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`surface_remove<class_ArrayMesh_method_surface_remove>` **(** :ref:`int<class_int>` surf_idx **)** |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`surface_set_name<class_ArrayMesh_method_surface_set_name>` **(** :ref:`int<class_int>` surf_idx, :ref:`String<class_String>` name **)** |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`surface_update_region<class_ArrayMesh_method_surface_update_region>` **(** :ref:`int<class_int>` surf_idx, :ref:`int<class_int>` offset, :ref:`PoolByteArray<class_PoolByteArray>` data **)** |
|
||||
+-----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_ArrayMesh_ArrayType:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_VERTEX:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_NORMAL:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_TANGENT:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_COLOR:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_TEX_UV:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_TEX_UV2:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_BONES:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_WEIGHTS:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_INDEX:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_MAX:
|
||||
|
||||
enum **ArrayType**:
|
||||
|
||||
- **ARRAY_VERTEX** = **0** --- :ref:`PoolVector3Array<class_PoolVector3Array>`, :ref:`PoolVector2Array<class_PoolVector2Array>`, or :ref:`Array<class_Array>` of vertex positions.
|
||||
|
||||
- **ARRAY_NORMAL** = **1** --- :ref:`PoolVector3Array<class_PoolVector3Array>` of vertex normals.
|
||||
|
||||
- **ARRAY_TANGENT** = **2** --- :ref:`PoolRealArray<class_PoolRealArray>` of vertex tangents. Each element in groups of 4 floats, first 3 floats determine the tangent, and the last the binormal direction as -1 or 1.
|
||||
|
||||
- **ARRAY_COLOR** = **3** --- :ref:`PoolColorArray<class_PoolColorArray>` of vertex colors.
|
||||
|
||||
- **ARRAY_TEX_UV** = **4** --- :ref:`PoolVector2Array<class_PoolVector2Array>` for UV coordinates.
|
||||
|
||||
- **ARRAY_TEX_UV2** = **5** --- :ref:`PoolVector2Array<class_PoolVector2Array>` for second UV coordinates.
|
||||
|
||||
- **ARRAY_BONES** = **6** --- :ref:`PoolRealArray<class_PoolRealArray>` or :ref:`PoolIntArray<class_PoolIntArray>` of bone indices. Each element in groups of 4 floats.
|
||||
|
||||
- **ARRAY_WEIGHTS** = **7** --- :ref:`PoolRealArray<class_PoolRealArray>` of bone weights. Each element in groups of 4 floats.
|
||||
|
||||
- **ARRAY_INDEX** = **8** --- :ref:`PoolIntArray<class_PoolIntArray>` of integers used as indices referencing vertices, colors, normals, tangents, and textures. All of those arrays must have the same number of elements as the vertex array. No index can be beyond the vertex array size. When this index array is present, it puts the function into "index mode," where the index selects the \*i\*'th vertex, normal, tangent, color, UV, etc. This means if you want to have different normals or colors along an edge, you have to duplicate the vertices.
|
||||
|
||||
For triangles, the index array is interpreted as triples, referring to the vertices of each triangle. For lines, the index array is in pairs indicating the start and end of each line.
|
||||
|
||||
- **ARRAY_MAX** = **9** --- Representa el tamaño del enum :ref:`ArrayType<enum_ArrayMesh_ArrayType>`.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_ArrayMesh_ArrayFormat:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_FORMAT_VERTEX:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_FORMAT_NORMAL:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_FORMAT_TANGENT:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_FORMAT_COLOR:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_FORMAT_TEX_UV:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_FORMAT_TEX_UV2:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_FORMAT_BONES:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_FORMAT_WEIGHTS:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_FORMAT_INDEX:
|
||||
|
||||
enum **ArrayFormat**:
|
||||
|
||||
- **ARRAY_FORMAT_VERTEX** = **1** --- El formato de Arary incluira vertices (obligatorio).
|
||||
|
||||
- **ARRAY_FORMAT_NORMAL** = **2** --- El format de array incluira normales.
|
||||
|
||||
- **ARRAY_FORMAT_TANGENT** = **4** --- El formato de array incluira tangentes.
|
||||
|
||||
- **ARRAY_FORMAT_COLOR** = **8** --- El formato de array incluira un array de colores.
|
||||
|
||||
- **ARRAY_FORMAT_TEX_UV** = **16** --- El formato de array incluira UVs.
|
||||
|
||||
- **ARRAY_FORMAT_TEX_UV2** = **32** --- El formato de array incluira otr array de UVs.
|
||||
|
||||
- **ARRAY_FORMAT_BONES** = **64** --- El formato de array incluira indices de hueso.
|
||||
|
||||
- **ARRAY_FORMAT_WEIGHTS** = **128** --- El formato de array incluira pesos de hueso.
|
||||
|
||||
- **ARRAY_FORMAT_INDEX** = **256** --- El array de indices sera utilizado.
|
||||
|
||||
Constantes
|
||||
--------------------
|
||||
|
||||
.. _class_ArrayMesh_constant_NO_INDEX_ARRAY:
|
||||
|
||||
.. _class_ArrayMesh_constant_ARRAY_WEIGHTS_SIZE:
|
||||
|
||||
- **NO_INDEX_ARRAY** = **-1** --- Valor por defecto usado para un index_array_len cuando no hay indices.
|
||||
|
||||
- **ARRAY_WEIGHTS_SIZE** = **4** --- Cantidad de pesos/hueso indices por vertice (siempre 4).
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_ArrayMesh_property_blend_shape_mode:
|
||||
|
||||
- :ref:`BlendShapeMode<enum_Mesh_BlendShapeMode>` **blend_shape_mode**
|
||||
|
||||
+-----------+-----------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+-----------------------------+
|
||||
| *Setter* | set_blend_shape_mode(value) |
|
||||
+-----------+-----------------------------+
|
||||
| *Getter* | get_blend_shape_mode() |
|
||||
+-----------+-----------------------------+
|
||||
|
||||
Coloca el modo de mezcla de forma a :ref:`BlendShapeMode<enum_Mesh_BlendShapeMode>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_property_custom_aabb:
|
||||
|
||||
- :ref:`AABB<class_AABB>` **custom_aabb**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``AABB( 0, 0, 0, 0, 0, 0 )`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_custom_aabb(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_custom_aabb() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
Sobreescribe el :ref:`AABB<class_AABB>` con uno definido por usuario para el uso con el tronco(frustum). Especialmente util para evitar inesperadas selecciones cuando se use un shader a vertices desplazados.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_ArrayMesh_method_add_blend_shape:
|
||||
|
||||
- void **add_blend_shape** **(** :ref:`String<class_String>` name **)**
|
||||
|
||||
Añade un nombre a una forma de mezcla que se añadira con :ref:`add_surface_from_arrays<class_ArrayMesh_method_add_surface_from_arrays>`. Debe ser llamada antes que la superficie sea añadida.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_add_surface_from_arrays:
|
||||
|
||||
- void **add_surface_from_arrays** **(** :ref:`PrimitiveType<enum_Mesh_PrimitiveType>` primitive, :ref:`Array<class_Array>` arrays, :ref:`Array<class_Array>` blend_shapes=[ ], :ref:`int<class_int>` compress_flags=2194432 **)**
|
||||
|
||||
Creates a new surface.
|
||||
|
||||
Surfaces are created to be rendered using a ``primitive``, which may be any of the types defined in :ref:`PrimitiveType<enum_Mesh_PrimitiveType>`. (As a note, when using indices, it is recommended to only use points, lines, or triangles.) :ref:`Mesh.get_surface_count<class_Mesh_method_get_surface_count>` will become the ``surf_idx`` for this new surface.
|
||||
|
||||
The ``arrays`` argument is an array of arrays. See :ref:`ArrayType<enum_ArrayMesh_ArrayType>` for the values used in this array. For example, ``arrays[0]`` is the array of vertices. That first vertex sub-array is always required; the others are optional. Adding an index array puts this function into "index mode" where the vertex and other arrays become the sources of data and the index array defines the vertex order. All sub-arrays must have the same length as the vertex array or be empty, except for :ref:`ARRAY_INDEX<class_ArrayMesh_constant_ARRAY_INDEX>` if it is used.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_clear_blend_shapes:
|
||||
|
||||
- void **clear_blend_shapes** **(** **)**
|
||||
|
||||
Elimina todos las formas de mezcla de este ``ArrayMesh``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_clear_surfaces:
|
||||
|
||||
- void **clear_surfaces** **(** **)**
|
||||
|
||||
Elimina todas las superificies de este ``ArrayMesh``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_get_blend_shape_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_blend_shape_count** **(** **)** |const|
|
||||
|
||||
Devuelve el numero de formas de mezcla que el ``ArrayMesh`` posee.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_get_blend_shape_name:
|
||||
|
||||
- :ref:`String<class_String>` **get_blend_shape_name** **(** :ref:`int<class_int>` index **)** |const|
|
||||
|
||||
Devuelve el nombre de la forma de mezcla de este indice.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_lightmap_unwrap:
|
||||
|
||||
- :ref:`Error<enum_@GlobalScope_Error>` **lightmap_unwrap** **(** :ref:`Transform<class_Transform>` transform, :ref:`float<class_float>` texel_size **)**
|
||||
|
||||
Ejecutara un desenvolver UV en el ``ArrayMesh`` para preparar la malla para iluminacion de mapas.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_regen_normalmaps:
|
||||
|
||||
- void **regen_normalmaps** **(** **)**
|
||||
|
||||
Regenerara los mapas de normales para el ``ArrayMesh``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_set_blend_shape_name:
|
||||
|
||||
- void **set_blend_shape_name** **(** :ref:`int<class_int>` index, :ref:`String<class_String>` name **)**
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_surface_find_by_name:
|
||||
|
||||
- :ref:`int<class_int>` **surface_find_by_name** **(** :ref:`String<class_String>` name **)** |const|
|
||||
|
||||
Devuelve el indice de la primer superficie con este nombre mantenido dentro de este ``ArrayMesh``. Si no es encontrado, -1 es devuelto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_surface_get_array_index_len:
|
||||
|
||||
- :ref:`int<class_int>` **surface_get_array_index_len** **(** :ref:`int<class_int>` surf_idx **)** |const|
|
||||
|
||||
Devuelve la longitud en indices del array de indices de la superificie solicitada( ver :ref:`add_surface_from_arrays<class_ArrayMesh_method_add_surface_from_arrays>`).
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_surface_get_array_len:
|
||||
|
||||
- :ref:`int<class_int>` **surface_get_array_len** **(** :ref:`int<class_int>` surf_idx **)** |const|
|
||||
|
||||
Devuelve la longitud en vertices del array de vertice en la superficie solicitada (ver\ :ref:`add_surface_from_arrays<class_ArrayMesh_method_add_surface_from_arrays>`).
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_surface_get_format:
|
||||
|
||||
- :ref:`int<class_int>` **surface_get_format** **(** :ref:`int<class_int>` surf_idx **)** |const|
|
||||
|
||||
Devuelve la mascara de formato de la superficie solicitada (ver\ :ref:`add_surface_from_arrays<class_ArrayMesh_method_add_surface_from_arrays>`).
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_surface_get_name:
|
||||
|
||||
- :ref:`String<class_String>` **surface_get_name** **(** :ref:`int<class_int>` surf_idx **)** |const|
|
||||
|
||||
Obtiene el nombre asignado a esta superficie.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_surface_get_primitive_type:
|
||||
|
||||
- :ref:`PrimitiveType<enum_Mesh_PrimitiveType>` **surface_get_primitive_type** **(** :ref:`int<class_int>` surf_idx **)** |const|
|
||||
|
||||
Devuelve el tipo primitivo de la superficie solicitada (ver :ref:`add_surface_from_arrays<class_ArrayMesh_method_add_surface_from_arrays>`).
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_surface_remove:
|
||||
|
||||
- void **surface_remove** **(** :ref:`int<class_int>` surf_idx **)**
|
||||
|
||||
Removes a surface at position ``surf_idx``, shifting greater surfaces one ``surf_idx`` slot down.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_surface_set_name:
|
||||
|
||||
- void **surface_set_name** **(** :ref:`int<class_int>` surf_idx, :ref:`String<class_String>` name **)**
|
||||
|
||||
Obtiene un nombre para una superficie dada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ArrayMesh_method_surface_update_region:
|
||||
|
||||
- void **surface_update_region** **(** :ref:`int<class_int>` surf_idx, :ref:`int<class_int>` offset, :ref:`PoolByteArray<class_PoolByteArray>` data **)**
|
||||
|
||||
Actualiza una region especifica de la malla de arrays en la GPU.
|
||||
|
||||
\ **Aviso:** Solo usarlo si sabes lo que haces. Puedes causar el programa deje de funcionar al llamar esta funcion con argumentos incorrectos.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,116 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the ARVRAnchor.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_ARVRAnchor:
|
||||
|
||||
ARVRAnchor
|
||||
==========
|
||||
|
||||
**Inherits:** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Un punto de anclaje en el espacio AR.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
The ``ARVRAnchor`` point is a spatial node that maps a real world location identified by the AR platform to a position within the game world. For example, as long as plane detection in ARKit is on, ARKit will identify and update the position of planes (tables, floors, etc) and create anchors for them.
|
||||
|
||||
This node is mapped to one of the anchors through its unique ID. When you receive a signal that a new anchor is available, you should add this node to your scene for that anchor. You can predefine nodes and set the ID; the nodes will simply remain on 0,0,0 until a plane is recognized.
|
||||
|
||||
Keep in mind that, as long as plane detection is enabled, the size, placing and orientation of an anchor will be updated as the detection logic learns more about the real world out there especially if only part of the surface is in view.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------+-------------------------------------------------------+-------+
|
||||
| :ref:`int<class_int>` | :ref:`anchor_id<class_ARVRAnchor_property_anchor_id>` | ``1`` |
|
||||
+-----------------------+-------------------------------------------------------+-------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------+-------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_anchor_name<class_ARVRAnchor_method_get_anchor_name>` **(** **)** |const| |
|
||||
+-------------------------------+-------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`get_is_active<class_ARVRAnchor_method_get_is_active>` **(** **)** |const| |
|
||||
+-------------------------------+-------------------------------------------------------------------------------------+
|
||||
| :ref:`Mesh<class_Mesh>` | :ref:`get_mesh<class_ARVRAnchor_method_get_mesh>` **(** **)** |const| |
|
||||
+-------------------------------+-------------------------------------------------------------------------------------+
|
||||
| :ref:`Plane<class_Plane>` | :ref:`get_plane<class_ARVRAnchor_method_get_plane>` **(** **)** |const| |
|
||||
+-------------------------------+-------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`get_size<class_ARVRAnchor_method_get_size>` **(** **)** |const| |
|
||||
+-------------------------------+-------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_ARVRAnchor_signal_mesh_updated:
|
||||
|
||||
- **mesh_updated** **(** :ref:`Mesh<class_Mesh>` mesh **)**
|
||||
|
||||
Emitida cuando la malla asociada al ancla cambia o cuando se dispone de ella. Esto es especialmente importante para la topología que está siendo constantemente ``mesh_updated``.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_ARVRAnchor_property_anchor_id:
|
||||
|
||||
- :ref:`int<class_int>` **anchor_id**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_anchor_id(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_anchor_id() |
|
||||
+-----------+----------------------+
|
||||
|
||||
La identificación del ancla. Puedes establecer esto antes de que el ancla misma exista. El primer ancla obtiene un ID de ``1``, el segundo un ID de ``2``, etc. Cuando se quitan las anclas, el motor puede asignar el ID correspondiente a las nuevas anclas. La situación más común en la que las anclas "desaparecen" es cuando el servidor AR identifica que dos anclas representan partes diferentes del mismo plano y las fusiona.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_ARVRAnchor_method_get_anchor_name:
|
||||
|
||||
- :ref:`String<class_String>` **get_anchor_name** **(** **)** |const|
|
||||
|
||||
Devuelve el nombre dado a este anclaje.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRAnchor_method_get_is_active:
|
||||
|
||||
- :ref:`bool<class_bool>` **get_is_active** **(** **)** |const|
|
||||
|
||||
Devuelve ``true`` si el ancla está siendo rastreada y ``false`` si no se conoce actualmente ninguna ancla con esta identificación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRAnchor_method_get_mesh:
|
||||
|
||||
- :ref:`Mesh<class_Mesh>` **get_mesh** **(** **)** |const|
|
||||
|
||||
If provided by the :ref:`ARVRInterface<class_ARVRInterface>`, this returns a mesh object for the anchor. For an anchor, this can be a shape related to the object being tracked or it can be a mesh that provides topology related to the anchor and can be used to create shadows/reflections on surfaces or for generating collision shapes.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRAnchor_method_get_plane:
|
||||
|
||||
- :ref:`Plane<class_Plane>` **get_plane** **(** **)** |const|
|
||||
|
||||
Devuelve un avión alineado con nuestro ancla; útil para pruebas de intersección.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRAnchor_method_get_size:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **get_size** **(** **)** |const|
|
||||
|
||||
Devuelve el tamaño estimado del avión que fue detectado. Digamos que cuando el ancla se relaciona con una mesa en el mundo real, este es el tamaño estimado de la superficie de esa mesa.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,30 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the ARVRCamera.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_ARVRCamera:
|
||||
|
||||
ARVRCamera
|
||||
==========
|
||||
|
||||
**Inherits:** :ref:`Camera<class_Camera>` **<** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Un nodo de cámara con unas cuantas desviaciones para AR/VR aplicadas, como el seguimiento de la ubicación.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
This is a helper spatial node for our camera; note that, if stereoscopic rendering is applicable (VR-HMD), most of the camera properties are ignored, as the HMD information overrides them. The only properties that can be trusted are the near and far planes.
|
||||
|
||||
The position and orientation of this node is automatically updated by the ARVR Server to represent the location of the HMD if such tracking is available and can thus be used by game logic. Note that, in contrast to the ARVR Controller, the render thread has access to the most up-to-date tracking data of the HMD and the location of the ARVRCamera can lag a few milliseconds behind what is used for rendering as a result.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/vr/index`
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,183 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the ARVRController.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_ARVRController:
|
||||
|
||||
ARVRController
|
||||
==============
|
||||
|
||||
**Inherits:** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Un nodo espacial que representa un controlador de seguimiento espacial.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
This is a helper spatial node that is linked to the tracking of controllers. It also offers several handy passthroughs to the state of buttons and such on the controllers.
|
||||
|
||||
Controllers are linked by their ID. You can create controller nodes before the controllers are available. If your game always uses two controllers (one for each hand), you can predefine the controllers with ID 1 and 2; they will become active as soon as the controllers are identified. If you expect additional controllers to be used, you should react to the signals and add ARVRController nodes to your scene.
|
||||
|
||||
The position of the controller node is automatically updated by the :ref:`ARVRServer<class_ARVRServer>`. This makes this node ideal to add child nodes to visualize the controller.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/vr/index`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+-------------------------------------------------------------------+---------+
|
||||
| :ref:`int<class_int>` | :ref:`controller_id<class_ARVRController_property_controller_id>` | ``1`` |
|
||||
+---------------------------+-------------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`rumble<class_ARVRController_property_rumble>` | ``0.0`` |
|
||||
+---------------------------+-------------------------------------------------------------------+---------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_controller_name<class_ARVRController_method_get_controller_name>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`TrackerHand<enum_ARVRPositionalTracker_TrackerHand>` | :ref:`get_hand<class_ARVRController_method_get_hand>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`get_is_active<class_ARVRController_method_get_is_active>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_joystick_axis<class_ARVRController_method_get_joystick_axis>` **(** :ref:`int<class_int>` axis **)** |const| |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_joystick_id<class_ARVRController_method_get_joystick_id>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Mesh<class_Mesh>` | :ref:`get_mesh<class_ARVRController_method_get_mesh>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`is_button_pressed<class_ARVRController_method_is_button_pressed>` **(** :ref:`int<class_int>` button **)** |const| |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_ARVRController_signal_button_pressed:
|
||||
|
||||
- **button_pressed** **(** :ref:`int<class_int>` button **)**
|
||||
|
||||
Se emite cuando se presiona un botón de este controlador.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRController_signal_button_release:
|
||||
|
||||
- **button_release** **(** :ref:`int<class_int>` button **)**
|
||||
|
||||
Se emite cuando se libera un botón de este controlador.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRController_signal_mesh_updated:
|
||||
|
||||
- **mesh_updated** **(** :ref:`Mesh<class_Mesh>` mesh **)**
|
||||
|
||||
Emitido cuando la malla asociada al controlador cambia o cuando uno se hace disponible. En términos generales, esta será una malla estática después de estar disponible.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_ARVRController_property_controller_id:
|
||||
|
||||
- :ref:`int<class_int>` **controller_id**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_controller_id(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_controller_id() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
The controller's ID.
|
||||
|
||||
A controller ID of 0 is unbound and will always result in an inactive node. Controller ID 1 is reserved for the first controller that identifies itself as the left-hand controller and ID 2 is reserved for the first controller that identifies itself as the right-hand controller.
|
||||
|
||||
For any other controller that the :ref:`ARVRServer<class_ARVRServer>` detects, we continue with controller ID 3.
|
||||
|
||||
When a controller is turned off, its slot is freed. This ensures controllers will keep the same ID even when controllers with lower IDs are turned off.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRController_property_rumble:
|
||||
|
||||
- :ref:`float<class_float>` **rumble**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_rumble(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_rumble() |
|
||||
+-----------+-------------------+
|
||||
|
||||
The degree to which the controller vibrates. Ranges from ``0.0`` to ``1.0`` with precision ``.01``. If changed, updates :ref:`ARVRPositionalTracker.rumble<class_ARVRPositionalTracker_property_rumble>` accordingly.
|
||||
|
||||
This is a useful property to animate if you want the controller to vibrate for a limited duration.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_ARVRController_method_get_controller_name:
|
||||
|
||||
- :ref:`String<class_String>` **get_controller_name** **(** **)** |const|
|
||||
|
||||
Si está activo, devuelve el nombre del controlador asociado si lo proporciona el SDK AR/VR utilizado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRController_method_get_hand:
|
||||
|
||||
- :ref:`TrackerHand<enum_ARVRPositionalTracker_TrackerHand>` **get_hand** **(** **)** |const|
|
||||
|
||||
Returns the hand holding this controller, if known. See :ref:`TrackerHand<enum_ARVRPositionalTracker_TrackerHand>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRController_method_get_is_active:
|
||||
|
||||
- :ref:`bool<class_bool>` **get_is_active** **(** **)** |const|
|
||||
|
||||
Returns ``true`` if the bound controller is active. ARVR systems attempt to track active controllers.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRController_method_get_joystick_axis:
|
||||
|
||||
- :ref:`float<class_float>` **get_joystick_axis** **(** :ref:`int<class_int>` axis **)** |const|
|
||||
|
||||
Devuelve el valor del eje dado para cosas como disparadores, touchpads, etc. que están incrustados en el controlador.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRController_method_get_joystick_id:
|
||||
|
||||
- :ref:`int<class_int>` **get_joystick_id** **(** **)** |const|
|
||||
|
||||
Returns the ID of the joystick object bound to this. Every controller tracked by the :ref:`ARVRServer<class_ARVRServer>` that has buttons and axis will also be registered as a joystick within Godot. This means that all the normal joystick tracking and input mapping will work for buttons and axis found on the AR/VR controllers. This ID is purely offered as information so you can link up the controller with its joystick entry.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRController_method_get_mesh:
|
||||
|
||||
- :ref:`Mesh<class_Mesh>` **get_mesh** **(** **)** |const|
|
||||
|
||||
If provided by the :ref:`ARVRInterface<class_ARVRInterface>`, this returns a mesh associated with the controller. This can be used to visualize the controller.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRController_method_is_button_pressed:
|
||||
|
||||
- :ref:`int<class_int>` **is_button_pressed** **(** :ref:`int<class_int>` button **)** |const|
|
||||
|
||||
Returns ``true`` if the button at index ``button`` is pressed. See :ref:`JoystickList<enum_@GlobalScope_JoystickList>`, in particular the ``JOY_VR_*`` constants.
|
||||
|
||||
.. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
|
||||
.. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
|
||||
.. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
|
||||
@@ -1,257 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the ARVRInterface.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_ARVRInterface:
|
||||
|
||||
ARVRInterface
|
||||
=============
|
||||
|
||||
**Inherits:** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`ARVRInterfaceGDNative<class_ARVRInterfaceGDNative>`, :ref:`MobileVRInterface<class_MobileVRInterface>`, :ref:`WebXRInterface<class_WebXRInterface>`
|
||||
|
||||
Clase base para la implementación de una interfaz AR/VR.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
This class needs to be implemented to make an AR or VR platform available to Godot and these should be implemented as C++ modules or GDNative modules (note that for GDNative the subclass ARVRScriptInterface should be used). Part of the interface is exposed to GDScript so you can detect, enable and configure an AR or VR platform.
|
||||
|
||||
Interfaces should be written in such a way that simply enabling them will give us a working setup. You can query the available interfaces through :ref:`ARVRServer<class_ARVRServer>`.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/vr/index`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------+----------------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`ar_is_anchor_detection_enabled<class_ARVRInterface_property_ar_is_anchor_detection_enabled>` | ``false`` |
|
||||
+-------------------------+----------------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`interface_is_initialized<class_ARVRInterface_property_interface_is_initialized>` | ``false`` |
|
||||
+-------------------------+----------------------------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`interface_is_primary<class_ARVRInterface_property_interface_is_primary>` | ``false`` |
|
||||
+-------------------------+----------------------------------------------------------------------------------------------------+-----------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+------------------------------------------------------------+------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_camera_feed_id<class_ARVRInterface_method_get_camera_feed_id>` **(** **)** |
|
||||
+------------------------------------------------------------+------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_capabilities<class_ARVRInterface_method_get_capabilities>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_name<class_ARVRInterface_method_get_name>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`get_render_targetsize<class_ARVRInterface_method_get_render_targetsize>` **(** **)** |
|
||||
+------------------------------------------------------------+------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Tracking_status<enum_ARVRInterface_Tracking_status>` | :ref:`get_tracking_status<class_ARVRInterface_method_get_tracking_status>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`initialize<class_ARVRInterface_method_initialize>` **(** **)** |
|
||||
+------------------------------------------------------------+------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_stereo<class_ARVRInterface_method_is_stereo>` **(** **)** |
|
||||
+------------------------------------------------------------+------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`uninitialize<class_ARVRInterface_method_uninitialize>` **(** **)** |
|
||||
+------------------------------------------------------------+------------------------------------------------------------------------------------------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_ARVRInterface_Capabilities:
|
||||
|
||||
.. _class_ARVRInterface_constant_ARVR_NONE:
|
||||
|
||||
.. _class_ARVRInterface_constant_ARVR_MONO:
|
||||
|
||||
.. _class_ARVRInterface_constant_ARVR_STEREO:
|
||||
|
||||
.. _class_ARVRInterface_constant_ARVR_AR:
|
||||
|
||||
.. _class_ARVRInterface_constant_ARVR_EXTERNAL:
|
||||
|
||||
enum **Capabilities**:
|
||||
|
||||
- **ARVR_NONE** = **0** --- No ARVR capabilities.
|
||||
|
||||
- **ARVR_MONO** = **1** --- Esta interfaz puede funcionar con una salida de renderizado normal (AR no basada en HMD).
|
||||
|
||||
- **ARVR_STEREO** = **2** --- Esta interfaz soporta la renderización estereoscópica.
|
||||
|
||||
- **ARVR_AR** = **4** --- Esta interfaz soporta AR (video de fondo y seguimiento en el mundo real).
|
||||
|
||||
- **ARVR_EXTERNAL** = **8** --- Esta interfaz da salida a un dispositivo externo. Si se utiliza la vista principal, la salida en pantalla es un búfer sin modificar del ojo izquierdo o derecho (se estira si el tamaño de la vista no se cambia a la misma relación de aspecto de :ref:`get_render_targetsize<class_ARVRInterface_method_get_render_targetsize>`). El uso de un nodo de vista separado libera la vista principal para otros propósitos.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_ARVRInterface_Eyes:
|
||||
|
||||
.. _class_ARVRInterface_constant_EYE_MONO:
|
||||
|
||||
.. _class_ARVRInterface_constant_EYE_LEFT:
|
||||
|
||||
.. _class_ARVRInterface_constant_EYE_RIGHT:
|
||||
|
||||
enum **Eyes**:
|
||||
|
||||
- **EYE_MONO** = **0** --- Salida mono, se utiliza principalmente de forma interna cuando se recupera la información de posicionamiento para nuestro nodo de cámara o cuando la representación estereoscópica no es compatible.
|
||||
|
||||
- **EYE_LEFT** = **1** --- Salida del ojo izquierdo, se utiliza principalmente de forma interna al renderizar la imagen para el ojo izquierdo y obtener información de posicionamiento y proyección.
|
||||
|
||||
- **EYE_RIGHT** = **2** --- Salida del ojo derecho, se utiliza principalmente de forma interna al renderizar la imagen para el ojo derecho y obtener información de posicionamiento y proyección.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_ARVRInterface_Tracking_status:
|
||||
|
||||
.. _class_ARVRInterface_constant_ARVR_NORMAL_TRACKING:
|
||||
|
||||
.. _class_ARVRInterface_constant_ARVR_EXCESSIVE_MOTION:
|
||||
|
||||
.. _class_ARVRInterface_constant_ARVR_INSUFFICIENT_FEATURES:
|
||||
|
||||
.. _class_ARVRInterface_constant_ARVR_UNKNOWN_TRACKING:
|
||||
|
||||
.. _class_ARVRInterface_constant_ARVR_NOT_TRACKING:
|
||||
|
||||
enum **Tracking_status**:
|
||||
|
||||
- **ARVR_NORMAL_TRACKING** = **0** --- El rastreo se está comportando como se esperaba.
|
||||
|
||||
- **ARVR_EXCESSIVE_MOTION** = **1** --- El rastreo se ve obstaculizado por un movimiento excesivo (el jugador se mueve más rápido de lo que el rastreo puede mantener).
|
||||
|
||||
- **ARVR_INSUFFICIENT_FEATURES** = **2** --- El rastreo se ve obstaculizado por características insuficientes, está demasiado oscuro (para el rastreo basado en la cámara), el reproductor está bloqueado, etc.
|
||||
|
||||
- **ARVR_UNKNOWN_TRACKING** = **3** --- No conocemos el estado del rastreo o esta interfaz no proporciona información.
|
||||
|
||||
- **ARVR_NOT_TRACKING** = **4** --- El rastreo no funciona (cámara no enchufada u oscurecida, faros apagados, etc.).
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_ARVRInterface_property_ar_is_anchor_detection_enabled:
|
||||
|
||||
- :ref:`bool<class_bool>` **ar_is_anchor_detection_enabled**
|
||||
|
||||
+-----------+----------------------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+----------------------------------------+
|
||||
| *Setter* | set_anchor_detection_is_enabled(value) |
|
||||
+-----------+----------------------------------------+
|
||||
| *Getter* | get_anchor_detection_is_enabled() |
|
||||
+-----------+----------------------------------------+
|
||||
|
||||
En una interfaz AR, ``true`` si la detección de anclas está activada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRInterface_property_interface_is_initialized:
|
||||
|
||||
- :ref:`bool<class_bool>` **interface_is_initialized**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_is_initialized(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | is_initialized() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
``true`` si esta interfaz ha sido inicializada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRInterface_property_interface_is_primary:
|
||||
|
||||
- :ref:`bool<class_bool>` **interface_is_primary**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_is_primary(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | is_primary() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
``true`` si esta es la interfaz primaria.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_ARVRInterface_method_get_camera_feed_id:
|
||||
|
||||
- :ref:`int<class_int>` **get_camera_feed_id** **(** **)**
|
||||
|
||||
Si se trata de una interfaz AR que requiere mostrar una alimentación de la cámara como fondo, este método devuelve el ID de la alimentación en el :ref:`CameraServer<class_CameraServer>` para esta interfaz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRInterface_method_get_capabilities:
|
||||
|
||||
- :ref:`int<class_int>` **get_capabilities** **(** **)** |const|
|
||||
|
||||
Devuelve una combinación de flags :ref:`Capabilities<enum_ARVRInterface_Capabilities>` que proporcionan información sobre las capacidades de esta interfaz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRInterface_method_get_name:
|
||||
|
||||
- :ref:`String<class_String>` **get_name** **(** **)** |const|
|
||||
|
||||
Devuelve el nombre de esta interfaz (OpenVR, OpenHMD, ARKit, etc.).
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRInterface_method_get_render_targetsize:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **get_render_targetsize** **(** **)**
|
||||
|
||||
Devuelve la resolución a la que deberíamos renderizar nuestros resultados intermedios antes de que cosas como la distorsión de la lente sean aplicadas por la plataforma VR.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRInterface_method_get_tracking_status:
|
||||
|
||||
- :ref:`Tracking_status<enum_ARVRInterface_Tracking_status>` **get_tracking_status** **(** **)** |const|
|
||||
|
||||
Si se apoya, devuelve el estado de nuestro rastreo. Esto le permitirá proporcionar información al usuario sobre si hay problemas con el rastreo posicional.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRInterface_method_initialize:
|
||||
|
||||
- :ref:`bool<class_bool>` **initialize** **(** **)**
|
||||
|
||||
Llama a esto para inicializar esta interfaz. La primera interfaz que se inicializa se identifica como la interfaz principal y se utilizará para la prestación de servicios.
|
||||
|
||||
Después de inicializar la interfaz que quieres usar, necesitas habilitar el modo AR/VR de una ventana y la renderización debe comenzar.
|
||||
|
||||
\ **Nota:** Debes habilitar el modo AR/VR en la vista principal para cualquier dispositivo que utilice la salida principal de Godot, como por ejemplo para la RV móvil.
|
||||
|
||||
Si lo haces para una plataforma que maneja su propia salida (como OpenVR), Godot mostrará un solo ojo sin distorsión en la pantalla. Alternativamente, puedes añadir un nodo de puerto de visión separado a tu escena y habilitar la AR/VR en ese puerto de visión. Se utilizará para la salida al HMD, dejándote libre para hacer lo que quieras en la ventana principal, como usar una cámara separada como cámara de espectador o renderizar algo completamente diferente.
|
||||
|
||||
Mientras que actualmente no se utiliza, puede activar interfaces adicionales. Puede que quieras hacer esto si quieres rastrear los controladores de otras plataformas. Sin embargo, en este momento sólo una interfaz puede renderizar a un HMD.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRInterface_method_is_stereo:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_stereo** **(** **)**
|
||||
|
||||
Devuelve ``true`` si la salida actual de esta interfaz está en estéreo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRInterface_method_uninitialize:
|
||||
|
||||
- void **uninitialize** **(** **)**
|
||||
|
||||
Apaga la interfaz.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,23 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the ARVRInterfaceGDNative.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_ARVRInterfaceGDNative:
|
||||
|
||||
ARVRInterfaceGDNative
|
||||
=====================
|
||||
|
||||
**Inherits:** :ref:`ARVRInterface<class_ARVRInterface>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
GDNative wrapper for an ARVR interface.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
This is a wrapper class for GDNative implementations of the ARVR interface. To use a GDNative ARVR interface, simply instantiate this object and set your GDNative library containing the ARVR interface implementation.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,60 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the ARVROrigin.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_ARVROrigin:
|
||||
|
||||
ARVROrigin
|
||||
==========
|
||||
|
||||
**Inherits:** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
El punto de origen en AR/VR.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
This is a special node within the AR/VR system that maps the physical location of the center of our tracking space to the virtual location within our game world.
|
||||
|
||||
There should be only one of these nodes in your scene and you must have one. All the ARVRCamera, ARVRController and ARVRAnchor nodes should be direct children of this node for spatial tracking to work correctly.
|
||||
|
||||
It is the position of this node that you update when your character needs to move through your game world while we're not moving in the real world. Movement in the real world is always in relation to this origin point.
|
||||
|
||||
For example, if your character is driving a car, the ARVROrigin node should be a child node of this car. Or, if you're implementing a teleport system to move your character, you should change the position of this node.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/vr/index`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+-----------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`world_scale<class_ARVROrigin_property_world_scale>` | ``1.0`` |
|
||||
+---------------------------+-----------------------------------------------------------+---------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_ARVROrigin_property_world_scale:
|
||||
|
||||
- :ref:`float<class_float>` **world_scale**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_world_scale(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_world_scale() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Allows you to adjust the scale to your game's units. Most AR/VR platforms assume a scale of 1 game world unit = 1 real world meter.
|
||||
|
||||
\ **Note:** This method is a passthrough to the :ref:`ARVRServer<class_ARVRServer>` itself.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,191 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the ARVRPositionalTracker.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_ARVRPositionalTracker:
|
||||
|
||||
ARVRPositionalTracker
|
||||
=====================
|
||||
|
||||
**Inherits:** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Un objeto rastreado.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
An instance of this object represents a device that is tracked, such as a controller or anchor point. HMDs aren't represented here as they are handled internally.
|
||||
|
||||
As controllers are turned on and the AR/VR interface detects them, instances of this object are automatically added to this list of active tracking objects accessible through the :ref:`ARVRServer<class_ARVRServer>`.
|
||||
|
||||
The :ref:`ARVRController<class_ARVRController>` and :ref:`ARVRAnchor<class_ARVRAnchor>` both consume objects of this type and should be used in your project. The positional trackers are just under-the-hood objects that make this all work. These are mostly exposed so that GDNative-based interfaces can interact with them.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/vr/index`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`rumble<class_ARVRPositionalTracker_property_rumble>` | ``0.0`` |
|
||||
+---------------------------+------------------------------------------------------------+---------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`TrackerHand<enum_ARVRPositionalTracker_TrackerHand>` | :ref:`get_hand<class_ARVRPositionalTracker_method_get_hand>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_joy_id<class_ARVRPositionalTracker_method_get_joy_id>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Mesh<class_Mesh>` | :ref:`get_mesh<class_ARVRPositionalTracker_method_get_mesh>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_name<class_ARVRPositionalTracker_method_get_name>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Basis<class_Basis>` | :ref:`get_orientation<class_ARVRPositionalTracker_method_get_orientation>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`get_position<class_ARVRPositionalTracker_method_get_position>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_tracker_id<class_ARVRPositionalTracker_method_get_tracker_id>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`get_tracks_orientation<class_ARVRPositionalTracker_method_get_tracks_orientation>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`get_tracks_position<class_ARVRPositionalTracker_method_get_tracks_position>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Transform<class_Transform>` | :ref:`get_transform<class_ARVRPositionalTracker_method_get_transform>` **(** :ref:`bool<class_bool>` adjust_by_reference_frame **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`TrackerType<enum_ARVRServer_TrackerType>` | :ref:`get_type<class_ARVRPositionalTracker_method_get_type>` **(** **)** |const| |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_ARVRPositionalTracker_TrackerHand:
|
||||
|
||||
.. _class_ARVRPositionalTracker_constant_TRACKER_HAND_UNKNOWN:
|
||||
|
||||
.. _class_ARVRPositionalTracker_constant_TRACKER_LEFT_HAND:
|
||||
|
||||
.. _class_ARVRPositionalTracker_constant_TRACKER_RIGHT_HAND:
|
||||
|
||||
enum **TrackerHand**:
|
||||
|
||||
- **TRACKER_HAND_UNKNOWN** = **0** --- La mano con la que se sostiene este rastreador es desconocida o no aplicable.
|
||||
|
||||
- **TRACKER_LEFT_HAND** = **1** --- Este rastreador es el controlador de la mano izquierda.
|
||||
|
||||
- **TRACKER_RIGHT_HAND** = **2** --- Este rastreador es el controlador de la mano derecha.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_ARVRPositionalTracker_property_rumble:
|
||||
|
||||
- :ref:`float<class_float>` **rumble**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_rumble(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_rumble() |
|
||||
+-----------+-------------------+
|
||||
|
||||
El grado en que el rastreador retumba. Va desde ``0.0`` hasta ``1.0`` con precisión ``.01``.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_ARVRPositionalTracker_method_get_hand:
|
||||
|
||||
- :ref:`TrackerHand<enum_ARVRPositionalTracker_TrackerHand>` **get_hand** **(** **)** |const|
|
||||
|
||||
Devuelve la mano que sostiene este rastreador, si se conoce. Ver las constantes de :ref:`TrackerHand<enum_ARVRPositionalTracker_TrackerHand>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRPositionalTracker_method_get_joy_id:
|
||||
|
||||
- :ref:`int<class_int>` **get_joy_id** **(** **)** |const|
|
||||
|
||||
Si se trata de un controlador que está siendo rastreado, el controlador también será representado por una entrada de joystick con esta identificación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRPositionalTracker_method_get_mesh:
|
||||
|
||||
- :ref:`Mesh<class_Mesh>` **get_mesh** **(** **)** |const|
|
||||
|
||||
Devuelve la malla relacionada con un controlador o punto de anclaje, si lo hay.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRPositionalTracker_method_get_name:
|
||||
|
||||
- :ref:`String<class_String>` **get_name** **(** **)** |const|
|
||||
|
||||
Devuelve el nombre del controlador o del punto de anclaje si está disponible.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRPositionalTracker_method_get_orientation:
|
||||
|
||||
- :ref:`Basis<class_Basis>` **get_orientation** **(** **)** |const|
|
||||
|
||||
Devuelve la matriz de orientación del controlador.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRPositionalTracker_method_get_position:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **get_position** **(** **)** |const|
|
||||
|
||||
Devuelve la posición del controlador espacio-mundo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRPositionalTracker_method_get_tracker_id:
|
||||
|
||||
- :ref:`int<class_int>` **get_tracker_id** **(** **)** |const|
|
||||
|
||||
Returns the internal tracker ID. This uniquely identifies the tracker per tracker type and matches the ID you need to specify for nodes such as the :ref:`ARVRController<class_ARVRController>` and :ref:`ARVRAnchor<class_ARVRAnchor>` nodes.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRPositionalTracker_method_get_tracks_orientation:
|
||||
|
||||
- :ref:`bool<class_bool>` **get_tracks_orientation** **(** **)** |const|
|
||||
|
||||
Devuelve ``true`` si este dispositivo rastrea la orientación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRPositionalTracker_method_get_tracks_position:
|
||||
|
||||
- :ref:`bool<class_bool>` **get_tracks_position** **(** **)** |const|
|
||||
|
||||
Devuelve ``true`` si este dispositivo rastrea la posición.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRPositionalTracker_method_get_transform:
|
||||
|
||||
- :ref:`Transform<class_Transform>` **get_transform** **(** :ref:`bool<class_bool>` adjust_by_reference_frame **)** |const|
|
||||
|
||||
Devuelve la transformación combinando la orientación y la posición de este dispositivo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRPositionalTracker_method_get_type:
|
||||
|
||||
- :ref:`TrackerType<enum_ARVRServer_TrackerType>` **get_type** **(** **)** |const|
|
||||
|
||||
Devuelve el tipo de rastreador.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,336 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the ARVRServer.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_ARVRServer:
|
||||
|
||||
ARVRServer
|
||||
==========
|
||||
|
||||
**Inherits:** :ref:`Object<class_Object>`
|
||||
|
||||
Servidor para las funciones de AR y VR.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
El servidor AR/VR es el corazón de nuestra solución de Realidad Virtual y Avanzada y maneja todo el procesamiento.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/vr/index`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------------------------+-----------------------------------------------------------------------+---------+
|
||||
| :ref:`ARVRInterface<class_ARVRInterface>` | :ref:`primary_interface<class_ARVRServer_property_primary_interface>` | |
|
||||
+-------------------------------------------+-----------------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`world_scale<class_ARVRServer_property_world_scale>` | ``1.0`` |
|
||||
+-------------------------------------------+-----------------------------------------------------------------------+---------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_interface<class_ARVRServer_method_add_interface>` **(** :ref:`ARVRInterface<class_ARVRInterface>` interface **)** |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_tracker<class_ARVRServer_method_add_tracker>` **(** :ref:`ARVRPositionalTracker<class_ARVRPositionalTracker>` tracker **)** |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`center_on_hmd<class_ARVRServer_method_center_on_hmd>` **(** :ref:`RotationMode<enum_ARVRServer_RotationMode>` rotation_mode, :ref:`bool<class_bool>` keep_height **)** |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear_primary_interface_if<class_ARVRServer_method_clear_primary_interface_if>` **(** :ref:`ARVRInterface<class_ARVRInterface>` interface **)** |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`ARVRInterface<class_ARVRInterface>` | :ref:`find_interface<class_ARVRServer_method_find_interface>` **(** :ref:`String<class_String>` name **)** |const| |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Transform<class_Transform>` | :ref:`get_hmd_transform<class_ARVRServer_method_get_hmd_transform>` **(** **)** |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`ARVRInterface<class_ARVRInterface>` | :ref:`get_interface<class_ARVRServer_method_get_interface>` **(** :ref:`int<class_int>` idx **)** |const| |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_interface_count<class_ARVRServer_method_get_interface_count>` **(** **)** |const| |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`get_interfaces<class_ARVRServer_method_get_interfaces>` **(** **)** |const| |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_last_commit_usec<class_ARVRServer_method_get_last_commit_usec>` **(** **)** |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_last_frame_usec<class_ARVRServer_method_get_last_frame_usec>` **(** **)** |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_last_process_usec<class_ARVRServer_method_get_last_process_usec>` **(** **)** |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Transform<class_Transform>` | :ref:`get_reference_frame<class_ARVRServer_method_get_reference_frame>` **(** **)** |const| |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`ARVRPositionalTracker<class_ARVRPositionalTracker>` | :ref:`get_tracker<class_ARVRServer_method_get_tracker>` **(** :ref:`int<class_int>` idx **)** |const| |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_tracker_count<class_ARVRServer_method_get_tracker_count>` **(** **)** |const| |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_interface<class_ARVRServer_method_remove_interface>` **(** :ref:`ARVRInterface<class_ARVRInterface>` interface **)** |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_tracker<class_ARVRServer_method_remove_tracker>` **(** :ref:`ARVRPositionalTracker<class_ARVRPositionalTracker>` tracker **)** |
|
||||
+-----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_ARVRServer_signal_interface_added:
|
||||
|
||||
- **interface_added** **(** :ref:`String<class_String>` interface_name **)**
|
||||
|
||||
Emitido cuando se ha añadido una nueva interfaz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_signal_interface_removed:
|
||||
|
||||
- **interface_removed** **(** :ref:`String<class_String>` interface_name **)**
|
||||
|
||||
Emitido cuando se quita una interfaz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_signal_tracker_added:
|
||||
|
||||
- **tracker_added** **(** :ref:`String<class_String>` tracker_name, :ref:`int<class_int>` type, :ref:`int<class_int>` id **)**
|
||||
|
||||
Emitted when a new tracker has been added. If you don't use a fixed number of controllers or if you're using :ref:`ARVRAnchor<class_ARVRAnchor>`\ s for an AR solution, it is important to react to this signal to add the appropriate :ref:`ARVRController<class_ARVRController>` or :ref:`ARVRAnchor<class_ARVRAnchor>` nodes related to this new tracker.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_signal_tracker_removed:
|
||||
|
||||
- **tracker_removed** **(** :ref:`String<class_String>` tracker_name, :ref:`int<class_int>` type, :ref:`int<class_int>` id **)**
|
||||
|
||||
Emitted when a tracker is removed. You should remove any :ref:`ARVRController<class_ARVRController>` or :ref:`ARVRAnchor<class_ARVRAnchor>` points if applicable. This is not mandatory, the nodes simply become inactive and will be made active again when a new tracker becomes available (i.e. a new controller is switched on that takes the place of the previous one).
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_ARVRServer_TrackerType:
|
||||
|
||||
.. _class_ARVRServer_constant_TRACKER_CONTROLLER:
|
||||
|
||||
.. _class_ARVRServer_constant_TRACKER_BASESTATION:
|
||||
|
||||
.. _class_ARVRServer_constant_TRACKER_ANCHOR:
|
||||
|
||||
.. _class_ARVRServer_constant_TRACKER_ANY_KNOWN:
|
||||
|
||||
.. _class_ARVRServer_constant_TRACKER_UNKNOWN:
|
||||
|
||||
.. _class_ARVRServer_constant_TRACKER_ANY:
|
||||
|
||||
enum **TrackerType**:
|
||||
|
||||
- **TRACKER_CONTROLLER** = **1** --- El rastreador rastrea la ubicación de un controlador.
|
||||
|
||||
- **TRACKER_BASESTATION** = **2** --- El rastreador rastrea la ubicación de una estación base.
|
||||
|
||||
- **TRACKER_ANCHOR** = **4** --- El rastreador rastrea la ubicación y el tamaño de un ancla AR.
|
||||
|
||||
- **TRACKER_ANY_KNOWN** = **127** --- Se utiliza internamente para filtrar los rastreadores de cualquier tipo conocido.
|
||||
|
||||
- **TRACKER_UNKNOWN** = **128** --- Se usa internamente si aún no hemos establecido el tipo de rastreador.
|
||||
|
||||
- **TRACKER_ANY** = **255** --- Se utiliza internamente para seleccionar todos los rastreadores.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_ARVRServer_RotationMode:
|
||||
|
||||
.. _class_ARVRServer_constant_RESET_FULL_ROTATION:
|
||||
|
||||
.. _class_ARVRServer_constant_RESET_BUT_KEEP_TILT:
|
||||
|
||||
.. _class_ARVRServer_constant_DONT_RESET_ROTATION:
|
||||
|
||||
enum **RotationMode**:
|
||||
|
||||
- **RESET_FULL_ROTATION** = **0** --- Reajustar completamente la orientación del HMD. Independientemente de la dirección en la que el usuario está mirando en el mundo real. El usuario mirará hacia adelante en el mundo virtual.
|
||||
|
||||
- **RESET_BUT_KEEP_TILT** = **1** --- Restablece la orientación pero mantiene la inclinación del dispositivo. Así que si estamos mirando hacia abajo, seguimos mirando hacia abajo pero la orientación se reajustará.
|
||||
|
||||
- **DONT_RESET_ROTATION** = **2** --- No reajusta la orientación del HMD, sólo la posición del jugador se centra.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_ARVRServer_property_primary_interface:
|
||||
|
||||
- :ref:`ARVRInterface<class_ARVRInterface>` **primary_interface**
|
||||
|
||||
+----------+------------------------------+
|
||||
| *Setter* | set_primary_interface(value) |
|
||||
+----------+------------------------------+
|
||||
| *Getter* | get_primary_interface() |
|
||||
+----------+------------------------------+
|
||||
|
||||
The primary :ref:`ARVRInterface<class_ARVRInterface>` currently bound to the ``ARVRServer``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_property_world_scale:
|
||||
|
||||
- :ref:`float<class_float>` **world_scale**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_world_scale(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_world_scale() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Permite ajustar la escala a las unidades de su juego. La mayoría de las plataformas AR/VR asumen una escala de 1 unidad del mundo del juego = 1 metro del mundo real.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_ARVRServer_method_add_interface:
|
||||
|
||||
- void **add_interface** **(** :ref:`ARVRInterface<class_ARVRInterface>` interface **)**
|
||||
|
||||
Registers an :ref:`ARVRInterface<class_ARVRInterface>` object.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_add_tracker:
|
||||
|
||||
- void **add_tracker** **(** :ref:`ARVRPositionalTracker<class_ARVRPositionalTracker>` tracker **)**
|
||||
|
||||
Registers a new :ref:`ARVRPositionalTracker<class_ARVRPositionalTracker>` that tracks a spatial location in real space.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_center_on_hmd:
|
||||
|
||||
- void **center_on_hmd** **(** :ref:`RotationMode<enum_ARVRServer_RotationMode>` rotation_mode, :ref:`bool<class_bool>` keep_height **)**
|
||||
|
||||
Esta es una función importante para entender correctamente. Las plataformas AR y VR manejan la posición de forma ligeramente diferente.
|
||||
|
||||
Para las plataformas que no ofrecen seguimiento espacial, nuestro punto de origen (0,0,0) es la ubicación de nuestro HMD, pero tienes poco control sobre la dirección a la que se dirige el jugador en el mundo real.
|
||||
|
||||
Para las plataformas que sí ofrecen rastreo espacial, nuestro punto de origen depende mucho del sistema. Para OpenVR, nuestro punto de origen suele ser el centro del espacio de seguimiento, en el suelo. Para otras plataformas, a menudo es la ubicación de la cámara de seguimiento.
|
||||
|
||||
Este método permite centrar el rastreador en la ubicación del HMD. Tomará la ubicación actual del HMD y la usará para ajustar todos los datos de rastreo; en esencia, realineará el mundo real con la posición actual de su jugador en el mundo del juego.
|
||||
|
||||
Para que este método produzca resultados utilizables, la información de rastreo debe estar disponible. Esto a menudo toma unos cuantos fotogramas después de comenzar el juego.
|
||||
|
||||
Deberías llamar a este método después de que hayan pasado unos segundos. Por ejemplo, cuando el usuario solicita un reajuste de la pantalla manteniendo un botón designado en un controlador durante un corto período de tiempo, o cuando se implementa un mecanismo de teletransporte.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_clear_primary_interface_if:
|
||||
|
||||
- void **clear_primary_interface_if** **(** :ref:`ARVRInterface<class_ARVRInterface>` interface **)**
|
||||
|
||||
Clears our current primary interface if it is set to the provided interface.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_find_interface:
|
||||
|
||||
- :ref:`ARVRInterface<class_ARVRInterface>` **find_interface** **(** :ref:`String<class_String>` name **)** |const|
|
||||
|
||||
Encuentra una interfaz por su nombre. Por ejemplo, si su proyecto utiliza las capacidades de una plataforma AR/VR, puede encontrar la interfaz de esa plataforma por su nombre e inicializarla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_get_hmd_transform:
|
||||
|
||||
- :ref:`Transform<class_Transform>` **get_hmd_transform** **(** **)**
|
||||
|
||||
Devuelve la transformación de la interfaz primaria.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_get_interface:
|
||||
|
||||
- :ref:`ARVRInterface<class_ARVRInterface>` **get_interface** **(** :ref:`int<class_int>` idx **)** |const|
|
||||
|
||||
Devuelve la interfaz registrada en un índice determinado en nuestra lista de interfaces.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_get_interface_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_interface_count** **(** **)** |const|
|
||||
|
||||
Devuelve el número de interfaces registradas actualmente en el servidor AR/VR. Si su proyecto soporta múltiples plataformas AR/VR, puede mirar a través de la interfaz disponible, y presentar al usuario una selección o simplemente tratar de inicializar cada interfaz y usar la primera que devuelva ``true``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_get_interfaces:
|
||||
|
||||
- :ref:`Array<class_Array>` **get_interfaces** **(** **)** |const|
|
||||
|
||||
Devuelve una lista de las interfaces disponibles, el ID y el nombre de cada interfaz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_get_last_commit_usec:
|
||||
|
||||
- :ref:`int<class_int>` **get_last_commit_usec** **(** **)**
|
||||
|
||||
Returns the absolute timestamp (in μs) of the last ``ARVRServer`` commit of the AR/VR eyes to :ref:`VisualServer<class_VisualServer>`. The value comes from an internal call to :ref:`OS.get_ticks_usec<class_OS_method_get_ticks_usec>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_get_last_frame_usec:
|
||||
|
||||
- :ref:`int<class_int>` **get_last_frame_usec** **(** **)**
|
||||
|
||||
Devuelve la duración (en μs) del último fotograma. Esto se calcula como la diferencia entre :ref:`get_last_commit_usec<class_ARVRServer_method_get_last_commit_usec>` y :ref:`get_last_process_usec<class_ARVRServer_method_get_last_process_usec>` al hacer la confirmación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_get_last_process_usec:
|
||||
|
||||
- :ref:`int<class_int>` **get_last_process_usec** **(** **)**
|
||||
|
||||
Returns the absolute timestamp (in μs) of the last ``ARVRServer`` process callback. The value comes from an internal call to :ref:`OS.get_ticks_usec<class_OS_method_get_ticks_usec>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_get_reference_frame:
|
||||
|
||||
- :ref:`Transform<class_Transform>` **get_reference_frame** **(** **)** |const|
|
||||
|
||||
Devuelve la transformación del fotograma de referencia. Mayormente usada internamente y expuesta para las interfaces de construcción GDNative.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_get_tracker:
|
||||
|
||||
- :ref:`ARVRPositionalTracker<class_ARVRPositionalTracker>` **get_tracker** **(** :ref:`int<class_int>` idx **)** |const|
|
||||
|
||||
Devuelve el rastreador de posición en la identificación dada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_get_tracker_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_tracker_count** **(** **)** |const|
|
||||
|
||||
Devuelve el número de rastreadores registrados actualmente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_remove_interface:
|
||||
|
||||
- void **remove_interface** **(** :ref:`ARVRInterface<class_ARVRInterface>` interface **)**
|
||||
|
||||
Removes this interface.
|
||||
|
||||
----
|
||||
|
||||
.. _class_ARVRServer_method_remove_tracker:
|
||||
|
||||
- void **remove_tracker** **(** :ref:`ARVRPositionalTracker<class_ARVRPositionalTracker>` tracker **)**
|
||||
|
||||
Removes this positional tracker.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,144 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AspectRatioContainer.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AspectRatioContainer:
|
||||
|
||||
AspectRatioContainer
|
||||
====================
|
||||
|
||||
**Inherits:** :ref:`Container<class_Container>` **<** :ref:`Control<class_Control>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Container that preserves its child controls' aspect ratio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Arranges child controls in a way to preserve their aspect ratio automatically whenever the container is resized. Solves the problem where the container size is dynamic and the contents' size needs to adjust accordingly without losing proportions.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------------------------------------+---------------------------------------------------------------------------------------+---------+
|
||||
| :ref:`AlignMode<enum_AspectRatioContainer_AlignMode>` | :ref:`alignment_horizontal<class_AspectRatioContainer_property_alignment_horizontal>` | ``1`` |
|
||||
+-----------------------------------------------------------+---------------------------------------------------------------------------------------+---------+
|
||||
| :ref:`AlignMode<enum_AspectRatioContainer_AlignMode>` | :ref:`alignment_vertical<class_AspectRatioContainer_property_alignment_vertical>` | ``1`` |
|
||||
+-----------------------------------------------------------+---------------------------------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`ratio<class_AspectRatioContainer_property_ratio>` | ``1.0`` |
|
||||
+-----------------------------------------------------------+---------------------------------------------------------------------------------------+---------+
|
||||
| :ref:`StretchMode<enum_AspectRatioContainer_StretchMode>` | :ref:`stretch_mode<class_AspectRatioContainer_property_stretch_mode>` | ``2`` |
|
||||
+-----------------------------------------------------------+---------------------------------------------------------------------------------------+---------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AspectRatioContainer_StretchMode:
|
||||
|
||||
.. _class_AspectRatioContainer_constant_STRETCH_WIDTH_CONTROLS_HEIGHT:
|
||||
|
||||
.. _class_AspectRatioContainer_constant_STRETCH_HEIGHT_CONTROLS_WIDTH:
|
||||
|
||||
.. _class_AspectRatioContainer_constant_STRETCH_FIT:
|
||||
|
||||
.. _class_AspectRatioContainer_constant_STRETCH_COVER:
|
||||
|
||||
enum **StretchMode**:
|
||||
|
||||
- **STRETCH_WIDTH_CONTROLS_HEIGHT** = **0** --- The height of child controls is automatically adjusted based on the width of the container.
|
||||
|
||||
- **STRETCH_HEIGHT_CONTROLS_WIDTH** = **1** --- The width of child controls is automatically adjusted based on the height of the container.
|
||||
|
||||
- **STRETCH_FIT** = **2** --- The bounding rectangle of child controls is automatically adjusted to fit inside the container while keeping the aspect ratio.
|
||||
|
||||
- **STRETCH_COVER** = **3** --- The width and height of child controls is automatically adjusted to make their bounding rectangle cover the entire area of the container while keeping the aspect ratio.
|
||||
|
||||
When the bounding rectangle of child controls exceed the container's size and :ref:`Control.rect_clip_content<class_Control_property_rect_clip_content>` is enabled, this allows to show only the container's area restricted by its own bounding rectangle.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_AspectRatioContainer_AlignMode:
|
||||
|
||||
.. _class_AspectRatioContainer_constant_ALIGN_BEGIN:
|
||||
|
||||
.. _class_AspectRatioContainer_constant_ALIGN_CENTER:
|
||||
|
||||
.. _class_AspectRatioContainer_constant_ALIGN_END:
|
||||
|
||||
enum **AlignMode**:
|
||||
|
||||
- **ALIGN_BEGIN** = **0** --- Aligns child controls with the beginning (left or top) of the container.
|
||||
|
||||
- **ALIGN_CENTER** = **1** --- Aligns child controls with the center of the container.
|
||||
|
||||
- **ALIGN_END** = **2** --- Aligns child controls with the end (right or bottom) of the container.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AspectRatioContainer_property_alignment_horizontal:
|
||||
|
||||
- :ref:`AlignMode<enum_AspectRatioContainer_AlignMode>` **alignment_horizontal**
|
||||
|
||||
+-----------+---------------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+---------------------------------+
|
||||
| *Setter* | set_alignment_horizontal(value) |
|
||||
+-----------+---------------------------------+
|
||||
| *Getter* | get_alignment_horizontal() |
|
||||
+-----------+---------------------------------+
|
||||
|
||||
Specifies the horizontal relative position of child controls.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AspectRatioContainer_property_alignment_vertical:
|
||||
|
||||
- :ref:`AlignMode<enum_AspectRatioContainer_AlignMode>` **alignment_vertical**
|
||||
|
||||
+-----------+-------------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+-------------------------------+
|
||||
| *Setter* | set_alignment_vertical(value) |
|
||||
+-----------+-------------------------------+
|
||||
| *Getter* | get_alignment_vertical() |
|
||||
+-----------+-------------------------------+
|
||||
|
||||
Specifies the vertical relative position of child controls.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AspectRatioContainer_property_ratio:
|
||||
|
||||
- :ref:`float<class_float>` **ratio**
|
||||
|
||||
+-----------+------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------+
|
||||
| *Setter* | set_ratio(value) |
|
||||
+-----------+------------------+
|
||||
| *Getter* | get_ratio() |
|
||||
+-----------+------------------+
|
||||
|
||||
The aspect ratio to enforce on child controls. This is the width divided by the height. The ratio depends on the :ref:`stretch_mode<class_AspectRatioContainer_property_stretch_mode>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AspectRatioContainer_property_stretch_mode:
|
||||
|
||||
- :ref:`StretchMode<enum_AspectRatioContainer_StretchMode>` **stretch_mode**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``2`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_stretch_mode(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_stretch_mode() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
The stretch mode used to align child controls.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,362 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AStar.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AStar:
|
||||
|
||||
AStar
|
||||
=====
|
||||
|
||||
**Inherits:** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
An implementation of A\* to find the shortest paths among connected points in space.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
A\* (A star) is a computer algorithm that is widely used in pathfinding and graph traversal, the process of plotting short paths among vertices (points), passing through a given set of edges (segments). It enjoys widespread use due to its performance and accuracy. Godot's A\* implementation uses points in three-dimensional space and Euclidean distances by default.
|
||||
|
||||
You must add points manually with :ref:`add_point<class_AStar_method_add_point>` and create segments manually with :ref:`connect_points<class_AStar_method_connect_points>`. Then you can test if there is a path between two points with the :ref:`are_points_connected<class_AStar_method_are_points_connected>` function, get a path containing indices by :ref:`get_id_path<class_AStar_method_get_id_path>`, or one containing actual coordinates with :ref:`get_point_path<class_AStar_method_get_point_path>`.
|
||||
|
||||
It is also possible to use non-Euclidean distances. To do so, create a class that extends ``AStar`` and override methods :ref:`_compute_cost<class_AStar_method__compute_cost>` and :ref:`_estimate_cost<class_AStar_method__estimate_cost>`. Both take two indices and return a length, as is shown in the following example.
|
||||
|
||||
::
|
||||
|
||||
class MyAStar:
|
||||
extends AStar
|
||||
|
||||
func _compute_cost(u, v):
|
||||
return abs(u - v)
|
||||
|
||||
func _estimate_cost(u, v):
|
||||
return min(0, abs(u - v) - 1)
|
||||
|
||||
\ :ref:`_estimate_cost<class_AStar_method__estimate_cost>` should return a lower bound of the distance, i.e. ``_estimate_cost(u, v) <= _compute_cost(u, v)``. This serves as a hint to the algorithm because the custom ``_compute_cost`` might be computation-heavy. If this is not the case, make :ref:`_estimate_cost<class_AStar_method__estimate_cost>` return the same value as :ref:`_compute_cost<class_AStar_method__compute_cost>` to provide the algorithm with the most accurate information.
|
||||
|
||||
If the default :ref:`_estimate_cost<class_AStar_method__estimate_cost>` and :ref:`_compute_cost<class_AStar_method__compute_cost>` methods are used, or if the supplied :ref:`_estimate_cost<class_AStar_method__estimate_cost>` method returns a lower bound of the cost, then the paths returned by A\* will be the lowest-cost paths. Here, the cost of a path equals the sum of the :ref:`_compute_cost<class_AStar_method__compute_cost>` results of all segments in the path multiplied by the ``weight_scale``\ s of the endpoints of the respective segments. If the default methods are used and the ``weight_scale``\ s of all points are set to ``1.0``, then this equals the sum of Euclidean distances of all segments in the path.
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`_compute_cost<class_AStar_method__compute_cost>` **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |virtual| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`_estimate_cost<class_AStar_method__estimate_cost>` **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |virtual| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_point<class_AStar_method_add_point>` **(** :ref:`int<class_int>` id, :ref:`Vector3<class_Vector3>` position, :ref:`float<class_float>` weight_scale=1.0 **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`are_points_connected<class_AStar_method_are_points_connected>` **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id, :ref:`bool<class_bool>` bidirectional=true **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear<class_AStar_method_clear>` **(** **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`connect_points<class_AStar_method_connect_points>` **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id, :ref:`bool<class_bool>` bidirectional=true **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`disconnect_points<class_AStar_method_disconnect_points>` **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id, :ref:`bool<class_bool>` bidirectional=true **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_available_point_id<class_AStar_method_get_available_point_id>` **(** **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_closest_point<class_AStar_method_get_closest_point>` **(** :ref:`Vector3<class_Vector3>` to_position, :ref:`bool<class_bool>` include_disabled=false **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`get_closest_position_in_segment<class_AStar_method_get_closest_position_in_segment>` **(** :ref:`Vector3<class_Vector3>` to_position **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolIntArray<class_PoolIntArray>` | :ref:`get_id_path<class_AStar_method_get_id_path>` **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_point_capacity<class_AStar_method_get_point_capacity>` **(** **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolIntArray<class_PoolIntArray>` | :ref:`get_point_connections<class_AStar_method_get_point_connections>` **(** :ref:`int<class_int>` id **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_point_count<class_AStar_method_get_point_count>` **(** **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolVector3Array<class_PoolVector3Array>` | :ref:`get_point_path<class_AStar_method_get_point_path>` **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`get_point_position<class_AStar_method_get_point_position>` **(** :ref:`int<class_int>` id **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_point_weight_scale<class_AStar_method_get_point_weight_scale>` **(** :ref:`int<class_int>` id **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`get_points<class_AStar_method_get_points>` **(** **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`has_point<class_AStar_method_has_point>` **(** :ref:`int<class_int>` id **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_point_disabled<class_AStar_method_is_point_disabled>` **(** :ref:`int<class_int>` id **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_point<class_AStar_method_remove_point>` **(** :ref:`int<class_int>` id **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`reserve_space<class_AStar_method_reserve_space>` **(** :ref:`int<class_int>` num_nodes **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_point_disabled<class_AStar_method_set_point_disabled>` **(** :ref:`int<class_int>` id, :ref:`bool<class_bool>` disabled=true **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_point_position<class_AStar_method_set_point_position>` **(** :ref:`int<class_int>` id, :ref:`Vector3<class_Vector3>` position **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_point_weight_scale<class_AStar_method_set_point_weight_scale>` **(** :ref:`int<class_int>` id, :ref:`float<class_float>` weight_scale **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AStar_method__compute_cost:
|
||||
|
||||
- :ref:`float<class_float>` **_compute_cost** **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |virtual|
|
||||
|
||||
Llamado cuando se calcula el coste entre dos puntos conectados.
|
||||
|
||||
Nota que esta funcion esta oculta en la clase ``AStar`` por defecto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method__estimate_cost:
|
||||
|
||||
- :ref:`float<class_float>` **_estimate_cost** **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |virtual|
|
||||
|
||||
Llamado cuando se estima el coste entre un punto y la ruta del punto final.
|
||||
|
||||
Nota que esta funcion esta oculto en la clase ``AStar`` por defecto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_add_point:
|
||||
|
||||
- void **add_point** **(** :ref:`int<class_int>` id, :ref:`Vector3<class_Vector3>` position, :ref:`float<class_float>` weight_scale=1.0 **)**
|
||||
|
||||
Adds a new point at the given position with the given identifier. The ``id`` must be 0 or larger, and the ``weight_scale`` must be 1 or larger.
|
||||
|
||||
The ``weight_scale`` is multiplied by the result of :ref:`_compute_cost<class_AStar_method__compute_cost>` when determining the overall cost of traveling across a segment from a neighboring point to this point. Thus, all else being equal, the algorithm prefers points with lower ``weight_scale``\ s to form a path.
|
||||
|
||||
::
|
||||
|
||||
var astar = AStar.new()
|
||||
astar.add_point(1, Vector3(1, 0, 0), 4) # Adds the point (1, 0, 0) with weight_scale 4 and id 1
|
||||
|
||||
If there already exists a point for the given ``id``, its position and weight scale are updated to the given values.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_are_points_connected:
|
||||
|
||||
- :ref:`bool<class_bool>` **are_points_connected** **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id, :ref:`bool<class_bool>` bidirectional=true **)** |const|
|
||||
|
||||
Devuelve si dos puntos dados estan directamente conectados por un segmento. Si ``bidirectional`` es ``false``, devuelve si el movimiento desde ``id`` a ``to_id`` es posible a traves del segmento.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_clear:
|
||||
|
||||
- void **clear** **(** **)**
|
||||
|
||||
Limpia todos los puntos y segmentos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_connect_points:
|
||||
|
||||
- void **connect_points** **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id, :ref:`bool<class_bool>` bidirectional=true **)**
|
||||
|
||||
Crea un segmento entre los puntos dados. Si ``bidirectional`` es ``false``, solo el movimiento desde ``id`` a ``to_id`` es permitido, no la direccion inversa.
|
||||
|
||||
::
|
||||
|
||||
var astar = AStar.new()
|
||||
astar.add_point(1, Vector3(1, 1, 0))
|
||||
astar.add_point(2, Vector3(0, 5, 0))
|
||||
astar.connect_points(1,2, false)
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_disconnect_points:
|
||||
|
||||
- void **disconnect_points** **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id, :ref:`bool<class_bool>` bidirectional=true **)**
|
||||
|
||||
Elimina el segmento entre los puntos dados. Si ``bidirectional`` es ``false``, solo el movimiento desde ``id`` a ``to_id`` es prevenido, y una segmento unidireccional posiblemente se mantiene.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_get_available_point_id:
|
||||
|
||||
- :ref:`int<class_int>` **get_available_point_id** **(** **)** |const|
|
||||
|
||||
Devuelve el punto de Ide proximo disponible con ningun punto asociado a el.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_get_closest_point:
|
||||
|
||||
- :ref:`int<class_int>` **get_closest_point** **(** :ref:`Vector3<class_Vector3>` to_position, :ref:`bool<class_bool>` include_disabled=false **)** |const|
|
||||
|
||||
Devuelve el ID del punto mas cercano a ``to_position``, opcionalmente tomando puntos deshabilitados en cuenta. Devuelve ``-1`` si no hay puntos el grupo(pool) de puntos.
|
||||
|
||||
\ **Nota:** Si varios puntos son los más cercanos a ``to_position``, el pundo con el menor ID será devuelto, asegurando un resultado deterministico.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_get_closest_position_in_segment:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **get_closest_position_in_segment** **(** :ref:`Vector3<class_Vector3>` to_position **)** |const|
|
||||
|
||||
Devuelve la posicion mas cercana a ``to_position`` que reside dentro de un segmento entre dos puntos conectados.
|
||||
|
||||
::
|
||||
|
||||
var astar = AStar.new()
|
||||
astar.add_point(1, Vector3(0, 0, 0))
|
||||
astar.add_point(2, Vector3(0, 5, 0))
|
||||
astar.connect_points(1,2)
|
||||
var res = astar.get_closest_position_in_segment(Vector3(3, 3, 0)) # Devuelve (0, 3, 0)
|
||||
|
||||
El resultado esta en el segmento que va desde ``y = 0`` a ``y = 5``. Es la posicion mas cercana el segmento de un punto dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_get_id_path:
|
||||
|
||||
- :ref:`PoolIntArray<class_PoolIntArray>` **get_id_path** **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)**
|
||||
|
||||
Devuelve un array con los IDs de los puntos que forman la ruta encontrada por un A estrella entre los puntos dados. El array es ordenado desde el punto de comienzo al punto final de la ruta.
|
||||
|
||||
::
|
||||
|
||||
var astar = AStar.new()
|
||||
astar.add_point(1, Vector3(0, 0, 0))
|
||||
asta.add_point(2, Vector3(0, 1, 0), 1) # Peso por defecto es 1
|
||||
astar.add_point(3, Vector3(1, 1, 0))
|
||||
astar.add_point(4, Vector3(2, 0, 0))
|
||||
|
||||
astar.connect_points(1, 2, false)
|
||||
astar.connect_points(2, 3, false)
|
||||
astar.connect_points(4, 3, false)
|
||||
astar.connect_points(1, 4, false)
|
||||
|
||||
var res = astar.get_id_path(1, 3) # Devuelve [1, 2, 3]
|
||||
|
||||
Si tu cambiar el peso del segundo punto a 3, entonces el resultado sera ``[1, 4, 3]``, porque ahora aunque la distanica es mayor, es mas facil (menos coste) ir a traves de 4 que a traves del punto 2.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_get_point_capacity:
|
||||
|
||||
- :ref:`int<class_int>` **get_point_capacity** **(** **)** |const|
|
||||
|
||||
Devuelve la capacidad de la estructura que respalda los puntos, usado junto con ``reserve_space``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_get_point_connections:
|
||||
|
||||
- :ref:`PoolIntArray<class_PoolIntArray>` **get_point_connections** **(** :ref:`int<class_int>` id **)**
|
||||
|
||||
Devuelve un array con los IDs de los puntos que forman la conneccion con el punto dado.
|
||||
|
||||
::
|
||||
|
||||
var astar = AStar.new()
|
||||
astar.add_point(1, Vector3(0, 0, 0))
|
||||
astar.add_point(2, Vector1(0, 1, 0))
|
||||
astar.add_point(3, Vector3(1, 1, 0))
|
||||
astar.add_point(4, Vector3(2, 0, 0))
|
||||
|
||||
astar.connect_points(1, 2, true)
|
||||
astar.connect_points(1, 3, true)
|
||||
|
||||
var vecinos = astar.get_point_connections() # Devuelve [2, 3]
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_get_point_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_point_count** **(** **)** |const|
|
||||
|
||||
Devuelve el numero de puntos actualmente en el grupo(pool) de puntos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_get_point_path:
|
||||
|
||||
- :ref:`PoolVector3Array<class_PoolVector3Array>` **get_point_path** **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)**
|
||||
|
||||
Returns an array with the points that are in the path found by AStar between the given points. The array is ordered from the starting point to the ending point of the path.
|
||||
|
||||
\ **Note:** This method is not thread-safe. If called from a :ref:`Thread<class_Thread>`, it will return an empty :ref:`PoolVector3Array<class_PoolVector3Array>` and will print an error message.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_get_point_position:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **get_point_position** **(** :ref:`int<class_int>` id **)** |const|
|
||||
|
||||
Devuelve la posicion del punto asociado con el ``id`` dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_get_point_weight_scale:
|
||||
|
||||
- :ref:`float<class_float>` **get_point_weight_scale** **(** :ref:`int<class_int>` id **)** |const|
|
||||
|
||||
Devuelve el peso del punto asociado con el ``id`` dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_get_points:
|
||||
|
||||
- :ref:`Array<class_Array>` **get_points** **(** **)**
|
||||
|
||||
Devuelve un array con todos los puntos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_has_point:
|
||||
|
||||
- :ref:`bool<class_bool>` **has_point** **(** :ref:`int<class_int>` id **)** |const|
|
||||
|
||||
Devuelve si un punto asociado con el ``id`` existe.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_is_point_disabled:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_point_disabled** **(** :ref:`int<class_int>` id **)** |const|
|
||||
|
||||
Devuelve si un punto esta deshabilitado or no para el buscador de rutas. Por defecto, todos los puntos estan habilitados.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_remove_point:
|
||||
|
||||
- void **remove_point** **(** :ref:`int<class_int>` id **)**
|
||||
|
||||
Elimina el punto asociado con el ``id`` dado del grupo(pool) de puntos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_reserve_space:
|
||||
|
||||
- void **reserve_space** **(** :ref:`int<class_int>` num_nodes **)**
|
||||
|
||||
Espacio de reserva interna para puntos ``num_nodes``, util si tu estas añadiendo un gran numero de puntos a la vez, para un grid por ejemplo. Las nuevas capacidades debes ser mayores o iguales que la anterior capacidad.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_set_point_disabled:
|
||||
|
||||
- void **set_point_disabled** **(** :ref:`int<class_int>` id, :ref:`bool<class_bool>` disabled=true **)**
|
||||
|
||||
Deshabilita o habilita el punto especificado para el buscador de rutas. Util para crear obstaculos temporales.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_set_point_position:
|
||||
|
||||
- void **set_point_position** **(** :ref:`int<class_int>` id, :ref:`Vector3<class_Vector3>` position **)**
|
||||
|
||||
Coloca la ``position`` para el punto con el ``id`` dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar_method_set_point_weight_scale:
|
||||
|
||||
- void **set_point_weight_scale** **(** :ref:`int<class_int>` id, :ref:`float<class_float>` weight_scale **)**
|
||||
|
||||
Sets the ``weight_scale`` for the point with the given ``id``. The ``weight_scale`` is multiplied by the result of :ref:`_compute_cost<class_AStar_method__compute_cost>` when determining the overall cost of traveling across a segment from a neighboring point to this point.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,343 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AStar2D.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AStar2D:
|
||||
|
||||
AStar2D
|
||||
=======
|
||||
|
||||
**Inherits:** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Representacion de la clase AStar que usa vectores 2D como lados.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Este es un envoltorio para la clase :ref:`AStar<class_AStar>` el cual usa vectores 2D en vez de 3D Vectors.
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`_compute_cost<class_AStar2D_method__compute_cost>` **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |virtual| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`_estimate_cost<class_AStar2D_method__estimate_cost>` **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |virtual| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_point<class_AStar2D_method_add_point>` **(** :ref:`int<class_int>` id, :ref:`Vector2<class_Vector2>` position, :ref:`float<class_float>` weight_scale=1.0 **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`are_points_connected<class_AStar2D_method_are_points_connected>` **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear<class_AStar2D_method_clear>` **(** **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`connect_points<class_AStar2D_method_connect_points>` **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id, :ref:`bool<class_bool>` bidirectional=true **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`disconnect_points<class_AStar2D_method_disconnect_points>` **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_available_point_id<class_AStar2D_method_get_available_point_id>` **(** **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_closest_point<class_AStar2D_method_get_closest_point>` **(** :ref:`Vector2<class_Vector2>` to_position, :ref:`bool<class_bool>` include_disabled=false **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`get_closest_position_in_segment<class_AStar2D_method_get_closest_position_in_segment>` **(** :ref:`Vector2<class_Vector2>` to_position **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolIntArray<class_PoolIntArray>` | :ref:`get_id_path<class_AStar2D_method_get_id_path>` **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_point_capacity<class_AStar2D_method_get_point_capacity>` **(** **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolIntArray<class_PoolIntArray>` | :ref:`get_point_connections<class_AStar2D_method_get_point_connections>` **(** :ref:`int<class_int>` id **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_point_count<class_AStar2D_method_get_point_count>` **(** **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolVector2Array<class_PoolVector2Array>` | :ref:`get_point_path<class_AStar2D_method_get_point_path>` **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`get_point_position<class_AStar2D_method_get_point_position>` **(** :ref:`int<class_int>` id **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_point_weight_scale<class_AStar2D_method_get_point_weight_scale>` **(** :ref:`int<class_int>` id **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`get_points<class_AStar2D_method_get_points>` **(** **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`has_point<class_AStar2D_method_has_point>` **(** :ref:`int<class_int>` id **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_point_disabled<class_AStar2D_method_is_point_disabled>` **(** :ref:`int<class_int>` id **)** |const| |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_point<class_AStar2D_method_remove_point>` **(** :ref:`int<class_int>` id **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`reserve_space<class_AStar2D_method_reserve_space>` **(** :ref:`int<class_int>` num_nodes **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_point_disabled<class_AStar2D_method_set_point_disabled>` **(** :ref:`int<class_int>` id, :ref:`bool<class_bool>` disabled=true **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_point_position<class_AStar2D_method_set_point_position>` **(** :ref:`int<class_int>` id, :ref:`Vector2<class_Vector2>` position **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_point_weight_scale<class_AStar2D_method_set_point_weight_scale>` **(** :ref:`int<class_int>` id, :ref:`float<class_float>` weight_scale **)** |
|
||||
+-------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AStar2D_method__compute_cost:
|
||||
|
||||
- :ref:`float<class_float>` **_compute_cost** **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |virtual|
|
||||
|
||||
Llamado cuando se calcula el coste entre dos puntos conectados.
|
||||
|
||||
Nota que esta funcion esta oculta en la clase ``AStar2D`` por defecto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method__estimate_cost:
|
||||
|
||||
- :ref:`float<class_float>` **_estimate_cost** **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)** |virtual|
|
||||
|
||||
Llamado cuando se calcula el coste entre un punto el final de un punto de una ruta.
|
||||
|
||||
Nota que esta funcion esta oculta en la clase ``AStar2D`` por defecto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_add_point:
|
||||
|
||||
- void **add_point** **(** :ref:`int<class_int>` id, :ref:`Vector2<class_Vector2>` position, :ref:`float<class_float>` weight_scale=1.0 **)**
|
||||
|
||||
Adds a new point at the given position with the given identifier. The ``id`` must be 0 or larger, and the ``weight_scale`` must be 1 or larger.
|
||||
|
||||
The ``weight_scale`` is multiplied by the result of :ref:`_compute_cost<class_AStar2D_method__compute_cost>` when determining the overall cost of traveling across a segment from a neighboring point to this point. Thus, all else being equal, the algorithm prefers points with lower ``weight_scale``\ s to form a path.
|
||||
|
||||
::
|
||||
|
||||
var astar = AStar2D.new()
|
||||
astar.add_point(1, Vector2(1, 0), 4) # Adds the point (1, 0) with weight_scale 4 and id 1
|
||||
|
||||
If there already exists a point for the given ``id``, its position and weight scale are updated to the given values.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_are_points_connected:
|
||||
|
||||
- :ref:`bool<class_bool>` **are_points_connected** **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id **)** |const|
|
||||
|
||||
Devuelve si hay una conexion/segmento entre los puntos dados.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_clear:
|
||||
|
||||
- void **clear** **(** **)**
|
||||
|
||||
Limpia todos los puntos y segmentos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_connect_points:
|
||||
|
||||
- void **connect_points** **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id, :ref:`bool<class_bool>` bidirectional=true **)**
|
||||
|
||||
Crea un segmento entre los puntos dados. Si ``bidirectional`` es ``false``, solo el movimiento desde ``id`` a ``to_id`` es permitido, no la direccion inversa.
|
||||
|
||||
::
|
||||
|
||||
var astar = AStar2D.new()
|
||||
astar.add_point(1, Vector2(1, 1))
|
||||
astar.add_point(2, Vector(0, 5))
|
||||
astar.connect_points(1, 2, false)
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_disconnect_points:
|
||||
|
||||
- void **disconnect_points** **(** :ref:`int<class_int>` id, :ref:`int<class_int>` to_id **)**
|
||||
|
||||
Elimina el segmento entre los puntos dados.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_get_available_point_id:
|
||||
|
||||
- :ref:`int<class_int>` **get_available_point_id** **(** **)** |const|
|
||||
|
||||
Devuelve el punto de Ide proximo disponible con ningun punto asociado a el.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_get_closest_point:
|
||||
|
||||
- :ref:`int<class_int>` **get_closest_point** **(** :ref:`Vector2<class_Vector2>` to_position, :ref:`bool<class_bool>` include_disabled=false **)** |const|
|
||||
|
||||
Devuelve el ID del punto mas cercano a ``to_position``, opcionalmente tomando puntos deshabilitados en cuenta. Devuelve ``-1`` si no hay puntos el grupo(pool) de puntos.
|
||||
|
||||
\ **Nota:** Si varios puntos son los más cercanos a ``to_position``, el pundo con el menor ID será devuelto, asegurando un resultado deterministico.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_get_closest_position_in_segment:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **get_closest_position_in_segment** **(** :ref:`Vector2<class_Vector2>` to_position **)** |const|
|
||||
|
||||
Devuelve el punto mas cercano a ``to_position`` que reside dentro de un segmento entre dos puntos conectados.
|
||||
|
||||
::
|
||||
|
||||
var astar = AStar2D.new()
|
||||
astar.add_point(1, Vector2(0, 0))
|
||||
astar.add_point(2, Vector2(0, 5))
|
||||
astar.connect_points(1,2)
|
||||
var res = astar.get_closest_position_in_segment(Vector2(3, 3)) # Devuelve (0, 3)
|
||||
|
||||
El resultado esta dentro del segmento que van desde ``y = 0`` a ``y = 5``. Es la posicion mas cercana en el segmento al punto dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_get_id_path:
|
||||
|
||||
- :ref:`PoolIntArray<class_PoolIntArray>` **get_id_path** **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)**
|
||||
|
||||
Devuelve un array con los IDs de los puntos que forman la ruta encontrada por AStar2D entre los puntos dados. El array es ordenado desde el punto inicial al punto final de la ruta.
|
||||
|
||||
::
|
||||
|
||||
var astar = AStar2D.new()
|
||||
astar.add_point(1, Vector2(0,0))
|
||||
astar.add_point(2, Vertor2(0, 1), 1) # Por defecto el peso es 1
|
||||
astar.add_point(3, Vector2(1, 1))
|
||||
astar.add_point(4, Vector2(2,0))
|
||||
|
||||
astar.connect_points(1, 2, false)
|
||||
astar.connect_points(2, 3, false)
|
||||
astar.connect_points(4, 3, false)
|
||||
astar.connect_points(1, 4, false)
|
||||
|
||||
var res = astar.get_id_path(1, 3) # Devuelve [1, 2, 3]
|
||||
|
||||
Si tu cambias el peso del segundo punto a 3, entonces el resultado sera ``[1, 4, 3]``, porque ahora aunque la distancia es mayor, cuesta menos ir a traves del punto 4 que des punto 2.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_get_point_capacity:
|
||||
|
||||
- :ref:`int<class_int>` **get_point_capacity** **(** **)** |const|
|
||||
|
||||
Devuelve la capacidad de la estructura que respalda los puntos, usado junto con ``reserve_space``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_get_point_connections:
|
||||
|
||||
- :ref:`PoolIntArray<class_PoolIntArray>` **get_point_connections** **(** :ref:`int<class_int>` id **)**
|
||||
|
||||
Devuelve un array con los IDs de los puntos que forman la conexion con los puntos dados.
|
||||
|
||||
::
|
||||
|
||||
var astar = AStar2D.new()
|
||||
astar.add_point(1, Vector2(0, 0))
|
||||
astar.add_point(2, Vector2(0, 1))
|
||||
astar.add_point(3, Vector2(1, 1))
|
||||
astar.add_point(4, Vector2(2, 0))
|
||||
|
||||
astar.connect_points(1, 2, true)
|
||||
astar.connect_points(1, 3, true)
|
||||
|
||||
var vecinos = astar.get_point_connections(1) # Devuelve [2, 3]
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_get_point_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_point_count** **(** **)** |const|
|
||||
|
||||
Devuelve el numero de puntos actualmente en el grupo(pool) de puntos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_get_point_path:
|
||||
|
||||
- :ref:`PoolVector2Array<class_PoolVector2Array>` **get_point_path** **(** :ref:`int<class_int>` from_id, :ref:`int<class_int>` to_id **)**
|
||||
|
||||
Returns an array with the points that are in the path found by AStar2D between the given points. The array is ordered from the starting point to the ending point of the path.
|
||||
|
||||
\ **Note:** This method is not thread-safe. If called from a :ref:`Thread<class_Thread>`, it will return an empty :ref:`PoolVector2Array<class_PoolVector2Array>` and will print an error message.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_get_point_position:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **get_point_position** **(** :ref:`int<class_int>` id **)** |const|
|
||||
|
||||
Devuelve la posicion del punto asociado con el ``id`` dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_get_point_weight_scale:
|
||||
|
||||
- :ref:`float<class_float>` **get_point_weight_scale** **(** :ref:`int<class_int>` id **)** |const|
|
||||
|
||||
Devuelve el peso del punto asociado con el ``id`` dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_get_points:
|
||||
|
||||
- :ref:`Array<class_Array>` **get_points** **(** **)**
|
||||
|
||||
Devuelve un array con todos los puntos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_has_point:
|
||||
|
||||
- :ref:`bool<class_bool>` **has_point** **(** :ref:`int<class_int>` id **)** |const|
|
||||
|
||||
Devuelve si un punto asociado con el ``id`` existe.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_is_point_disabled:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_point_disabled** **(** :ref:`int<class_int>` id **)** |const|
|
||||
|
||||
Devuelve si un punto esta deshabilitado or no para el buscador de rutas. Por defecto, todos los puntos estan habilitados.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_remove_point:
|
||||
|
||||
- void **remove_point** **(** :ref:`int<class_int>` id **)**
|
||||
|
||||
Elimina el punto asociado con el ``id`` dado del grupo(pool) de puntos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_reserve_space:
|
||||
|
||||
- void **reserve_space** **(** :ref:`int<class_int>` num_nodes **)**
|
||||
|
||||
Espacio de reserva interna para puntos ``num_nodes``, util si tu estas añadiendo un gran numero de puntos a la vez, para un grid por ejemplo. Las nuevas capacidades debes ser mayores o iguales que la anterior capacidad.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_set_point_disabled:
|
||||
|
||||
- void **set_point_disabled** **(** :ref:`int<class_int>` id, :ref:`bool<class_bool>` disabled=true **)**
|
||||
|
||||
Deshabilita o habilita el punto especificado para el buscador de rutas. Util para crear obstaculos temporales.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_set_point_position:
|
||||
|
||||
- void **set_point_position** **(** :ref:`int<class_int>` id, :ref:`Vector2<class_Vector2>` position **)**
|
||||
|
||||
Coloca la ``position`` para el punto con el ``id`` dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AStar2D_method_set_point_weight_scale:
|
||||
|
||||
- void **set_point_weight_scale** **(** :ref:`int<class_int>` id, :ref:`float<class_float>` weight_scale **)**
|
||||
|
||||
Sets the ``weight_scale`` for the point with the given ``id``. The ``weight_scale`` is multiplied by the result of :ref:`_compute_cost<class_AStar2D_method__compute_cost>` when determining the overall cost of traveling across a segment from a neighboring point to this point.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,105 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AtlasTexture.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AtlasTexture:
|
||||
|
||||
AtlasTexture
|
||||
============
|
||||
|
||||
**Inherits:** :ref:`Texture<class_Texture>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Crops out one part of a texture, such as a texture from a texture atlas.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
:ref:`Texture<class_Texture>` resource that crops out one part of the :ref:`atlas<class_AtlasTexture_property_atlas>` texture, defined by :ref:`region<class_AtlasTexture_property_region>`. The main use case is cropping out textures from a texture atlas, which is a big texture file that packs multiple smaller textures. Consists of a :ref:`Texture<class_Texture>` for the :ref:`atlas<class_AtlasTexture_property_atlas>`, a :ref:`region<class_AtlasTexture_property_region>` that defines the area of :ref:`atlas<class_AtlasTexture_property_atlas>` to use, and a :ref:`margin<class_AtlasTexture_property_margin>` that defines the border width.
|
||||
|
||||
\ ``AtlasTexture`` cannot be used in an :ref:`AnimatedTexture<class_AnimatedTexture>`, cannot be tiled in nodes such as :ref:`TextureRect<class_TextureRect>`, and does not work properly if used inside of other ``AtlasTexture`` resources. Multiple ``AtlasTexture`` resources can be used to crop multiple textures from the atlas. Using a texture atlas helps to optimize video memory costs and render calls compared to using multiple small files.
|
||||
|
||||
\ **Note:** AtlasTextures don't support repetition. The :ref:`Texture.FLAG_REPEAT<class_Texture_constant_FLAG_REPEAT>` and :ref:`Texture.FLAG_MIRRORED_REPEAT<class_Texture_constant_FLAG_MIRRORED_REPEAT>` flags are ignored when using an AtlasTexture.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------------+-------------------------------------------------------------+----------------------------------------------------------------+
|
||||
| :ref:`Texture<class_Texture>` | :ref:`atlas<class_AtlasTexture_property_atlas>` | |
|
||||
+-------------------------------+-------------------------------------------------------------+----------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`filter_clip<class_AtlasTexture_property_filter_clip>` | ``false`` |
|
||||
+-------------------------------+-------------------------------------------------------------+----------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | flags | ``0`` (overrides :ref:`Texture<class_Texture_property_flags>`) |
|
||||
+-------------------------------+-------------------------------------------------------------+----------------------------------------------------------------+
|
||||
| :ref:`Rect2<class_Rect2>` | :ref:`margin<class_AtlasTexture_property_margin>` | ``Rect2( 0, 0, 0, 0 )`` |
|
||||
+-------------------------------+-------------------------------------------------------------+----------------------------------------------------------------+
|
||||
| :ref:`Rect2<class_Rect2>` | :ref:`region<class_AtlasTexture_property_region>` | ``Rect2( 0, 0, 0, 0 )`` |
|
||||
+-------------------------------+-------------------------------------------------------------+----------------------------------------------------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AtlasTexture_property_atlas:
|
||||
|
||||
- :ref:`Texture<class_Texture>` **atlas**
|
||||
|
||||
+----------+------------------+
|
||||
| *Setter* | set_atlas(value) |
|
||||
+----------+------------------+
|
||||
| *Getter* | get_atlas() |
|
||||
+----------+------------------+
|
||||
|
||||
The texture that contains the atlas. Can be any :ref:`Texture<class_Texture>` subtype.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AtlasTexture_property_filter_clip:
|
||||
|
||||
- :ref:`bool<class_bool>` **filter_clip**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_filter_clip(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | has_filter_clip() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Si ``true``, recorta el area fuera de la region para evitar el sangrado de pixeles de textura alrededor.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AtlasTexture_property_margin:
|
||||
|
||||
- :ref:`Rect2<class_Rect2>` **margin**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``Rect2( 0, 0, 0, 0 )`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_margin(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_margin() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
El margen alrededor de la region. El parametro :ref:`Rect2<class_Rect2>`\ :ref:`Rect2.size<class_Rect2_property_size>` ( "w" y "h" en el editor) cambia el tamaño de la textura para que encaje dentro del margen.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AtlasTexture_property_region:
|
||||
|
||||
- :ref:`Rect2<class_Rect2>` **region**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``Rect2( 0, 0, 0, 0 )`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_region(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_region() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
La region utilizada del AtlasTexture.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,23 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioBusLayout.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioBusLayout:
|
||||
|
||||
AudioBusLayout
|
||||
==============
|
||||
|
||||
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Almacena informacion sobre los buses de audio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Almacena posicion, muteado, solo, bypass, efectos, posicion de efecto, volumen, y las conexiones entre buses. Ver :ref:`AudioServer<class_AudioServer>` para su uso.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,30 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffect.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffect:
|
||||
|
||||
AudioEffect
|
||||
===========
|
||||
|
||||
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`AudioEffectAmplify<class_AudioEffectAmplify>`, :ref:`AudioEffectCapture<class_AudioEffectCapture>`, :ref:`AudioEffectChorus<class_AudioEffectChorus>`, :ref:`AudioEffectCompressor<class_AudioEffectCompressor>`, :ref:`AudioEffectDelay<class_AudioEffectDelay>`, :ref:`AudioEffectDistortion<class_AudioEffectDistortion>`, :ref:`AudioEffectEQ<class_AudioEffectEQ>`, :ref:`AudioEffectFilter<class_AudioEffectFilter>`, :ref:`AudioEffectLimiter<class_AudioEffectLimiter>`, :ref:`AudioEffectPanner<class_AudioEffectPanner>`, :ref:`AudioEffectPhaser<class_AudioEffectPhaser>`, :ref:`AudioEffectPitchShift<class_AudioEffectPitchShift>`, :ref:`AudioEffectRecord<class_AudioEffectRecord>`, :ref:`AudioEffectReverb<class_AudioEffectReverb>`, :ref:`AudioEffectSpectrumAnalyzer<class_AudioEffectSpectrumAnalyzer>`, :ref:`AudioEffectStereoEnhance<class_AudioEffectStereoEnhance>`
|
||||
|
||||
Efecto de audio para audio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Recurso base para el bus de audio. Aplica un efecto de audio en el bus en que el recurso es aplicado.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- `Audio Mic Record Demo <https://godotengine.org/asset-library/asset/527>`__
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,49 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectAmplify.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectAmplify:
|
||||
|
||||
AudioEffectAmplify
|
||||
==================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añado un efecto de amplificacion de audio a un bus de audio.
|
||||
|
||||
Aumenta o reduce el volumen del bus de audio seleccionado.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Aumenta o reduce el volumen que se dirige a traves del bus de audio.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+---------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`volume_db<class_AudioEffectAmplify_property_volume_db>` | ``0.0`` |
|
||||
+---------------------------+---------------------------------------------------------------+---------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectAmplify_property_volume_db:
|
||||
|
||||
- :ref:`float<class_float>` **volume_db**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_volume_db(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_volume_db() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Cantidad de amplificacion en decibelios. Valores positivos hacen el sonido mas fuerte, valores negativos mas debiles. Valores pueden alcanzar el rango de -80 a 24.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,23 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectBandLimitFilter.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectBandLimitFilter:
|
||||
|
||||
AudioEffectBandLimitFilter
|
||||
==========================
|
||||
|
||||
**Inherits:** :ref:`AudioEffectFilter<class_AudioEffectFilter>` **<** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un filtro de limite de banda al bus de audio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Limita la frecuencia en un rango alrededor de :ref:`AudioEffectFilter.cutoff_hz<class_AudioEffectFilter_property_cutoff_hz>` y permite frecuencia fuera de este rango pasar.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,23 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectBandPassFilter.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectBandPassFilter:
|
||||
|
||||
AudioEffectBandPassFilter
|
||||
=========================
|
||||
|
||||
**Inherits:** :ref:`AudioEffectFilter<class_AudioEffectFilter>` **<** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un filtro de paso de banda al bus de audio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Atenua las frecuencias dentro de un rango alrededor del :ref:`AudioEffectFilter.cutoff_hz<class_AudioEffectFilter_property_cutoff_hz>` y recorta la frecuencias fuera de esta banda.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,127 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectCapture.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectCapture:
|
||||
|
||||
AudioEffectCapture
|
||||
==================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Captures audio from an audio bus in real-time.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
AudioEffectCapture is an AudioEffect which copies all audio frames from the attached audio effect bus into its internal ring buffer.
|
||||
|
||||
Application code should consume these audio frames from this ring buffer using :ref:`get_buffer<class_AudioEffectCapture_method_get_buffer>` and process it as needed, for example to capture data from a microphone, implement application defined effects, or to transmit audio over the network.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+-----------------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`buffer_length<class_AudioEffectCapture_property_buffer_length>` | ``0.1`` |
|
||||
+---------------------------+-----------------------------------------------------------------------+---------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`can_get_buffer<class_AudioEffectCapture_method_can_get_buffer>` **(** :ref:`int<class_int>` frames **)** |const| |
|
||||
+-------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear_buffer<class_AudioEffectCapture_method_clear_buffer>` **(** **)** |
|
||||
+-------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`PoolVector2Array<class_PoolVector2Array>` | :ref:`get_buffer<class_AudioEffectCapture_method_get_buffer>` **(** :ref:`int<class_int>` frames **)** |
|
||||
+-------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_buffer_length_frames<class_AudioEffectCapture_method_get_buffer_length_frames>` **(** **)** |const| |
|
||||
+-------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_discarded_frames<class_AudioEffectCapture_method_get_discarded_frames>` **(** **)** |const| |
|
||||
+-------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_frames_available<class_AudioEffectCapture_method_get_frames_available>` **(** **)** |const| |
|
||||
+-------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_pushed_frames<class_AudioEffectCapture_method_get_pushed_frames>` **(** **)** |const| |
|
||||
+-------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectCapture_property_buffer_length:
|
||||
|
||||
- :ref:`float<class_float>` **buffer_length**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``0.1`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_buffer_length(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_buffer_length() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
Length of the internal ring buffer, in seconds. Setting the buffer length will have no effect if already initialized.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectCapture_method_can_get_buffer:
|
||||
|
||||
- :ref:`bool<class_bool>` **can_get_buffer** **(** :ref:`int<class_int>` frames **)** |const|
|
||||
|
||||
Returns ``true`` if at least ``frames`` audio frames are available to read in the internal ring buffer.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCapture_method_clear_buffer:
|
||||
|
||||
- void **clear_buffer** **(** **)**
|
||||
|
||||
Clears the internal ring buffer.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCapture_method_get_buffer:
|
||||
|
||||
- :ref:`PoolVector2Array<class_PoolVector2Array>` **get_buffer** **(** :ref:`int<class_int>` frames **)**
|
||||
|
||||
Gets the next ``frames`` audio samples from the internal ring buffer.
|
||||
|
||||
Returns a :ref:`PoolVector2Array<class_PoolVector2Array>` containing exactly ``frames`` audio samples if available, or an empty :ref:`PoolVector2Array<class_PoolVector2Array>` if insufficient data was available.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCapture_method_get_buffer_length_frames:
|
||||
|
||||
- :ref:`int<class_int>` **get_buffer_length_frames** **(** **)** |const|
|
||||
|
||||
Returns the total size of the internal ring buffer in frames.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCapture_method_get_discarded_frames:
|
||||
|
||||
- :ref:`int<class_int>` **get_discarded_frames** **(** **)** |const|
|
||||
|
||||
Returns the number of audio frames discarded from the audio bus due to full buffer.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCapture_method_get_frames_available:
|
||||
|
||||
- :ref:`int<class_int>` **get_frames_available** **(** **)** |const|
|
||||
|
||||
Returns the number of frames available to read using :ref:`get_buffer<class_AudioEffectCapture_method_get_buffer>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCapture_method_get_pushed_frames:
|
||||
|
||||
- :ref:`int<class_int>` **get_pushed_frames** **(** **)** |const|
|
||||
|
||||
Returns the number of audio frames inserted from the audio bus.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,593 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectChorus.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectChorus:
|
||||
|
||||
AudioEffectChorus
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un efecto de audio de coro.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Añade un efecto de audio de coro. El efecto aplica un filtro con voces para duplicar la fuente de audio y manipularlo a traves del filtro.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`dry<class_AudioEffectChorus_property_dry>` | ``1.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/1/cutoff_hz<class_AudioEffectChorus_property_voice/1/cutoff_hz>` | ``8000.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/1/delay_ms<class_AudioEffectChorus_property_voice/1/delay_ms>` | ``15.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/1/depth_ms<class_AudioEffectChorus_property_voice/1/depth_ms>` | ``2.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/1/level_db<class_AudioEffectChorus_property_voice/1/level_db>` | ``0.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/1/pan<class_AudioEffectChorus_property_voice/1/pan>` | ``-0.5`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/1/rate_hz<class_AudioEffectChorus_property_voice/1/rate_hz>` | ``0.8`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/2/cutoff_hz<class_AudioEffectChorus_property_voice/2/cutoff_hz>` | ``8000.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/2/delay_ms<class_AudioEffectChorus_property_voice/2/delay_ms>` | ``20.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/2/depth_ms<class_AudioEffectChorus_property_voice/2/depth_ms>` | ``3.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/2/level_db<class_AudioEffectChorus_property_voice/2/level_db>` | ``0.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/2/pan<class_AudioEffectChorus_property_voice/2/pan>` | ``0.5`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/2/rate_hz<class_AudioEffectChorus_property_voice/2/rate_hz>` | ``1.2`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/3/cutoff_hz<class_AudioEffectChorus_property_voice/3/cutoff_hz>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/3/delay_ms<class_AudioEffectChorus_property_voice/3/delay_ms>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/3/depth_ms<class_AudioEffectChorus_property_voice/3/depth_ms>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/3/level_db<class_AudioEffectChorus_property_voice/3/level_db>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/3/pan<class_AudioEffectChorus_property_voice/3/pan>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/3/rate_hz<class_AudioEffectChorus_property_voice/3/rate_hz>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/4/cutoff_hz<class_AudioEffectChorus_property_voice/4/cutoff_hz>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/4/delay_ms<class_AudioEffectChorus_property_voice/4/delay_ms>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/4/depth_ms<class_AudioEffectChorus_property_voice/4/depth_ms>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/4/level_db<class_AudioEffectChorus_property_voice/4/level_db>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/4/pan<class_AudioEffectChorus_property_voice/4/pan>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`voice/4/rate_hz<class_AudioEffectChorus_property_voice/4/rate_hz>` | |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`int<class_int>` | :ref:`voice_count<class_AudioEffectChorus_property_voice_count>` | ``2`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`wet<class_AudioEffectChorus_property_wet>` | ``0.5`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_voice_cutoff_hz<class_AudioEffectChorus_method_get_voice_cutoff_hz>` **(** :ref:`int<class_int>` voice_idx **)** |const| |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_voice_delay_ms<class_AudioEffectChorus_method_get_voice_delay_ms>` **(** :ref:`int<class_int>` voice_idx **)** |const| |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_voice_depth_ms<class_AudioEffectChorus_method_get_voice_depth_ms>` **(** :ref:`int<class_int>` voice_idx **)** |const| |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_voice_level_db<class_AudioEffectChorus_method_get_voice_level_db>` **(** :ref:`int<class_int>` voice_idx **)** |const| |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_voice_pan<class_AudioEffectChorus_method_get_voice_pan>` **(** :ref:`int<class_int>` voice_idx **)** |const| |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_voice_rate_hz<class_AudioEffectChorus_method_get_voice_rate_hz>` **(** :ref:`int<class_int>` voice_idx **)** |const| |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_voice_cutoff_hz<class_AudioEffectChorus_method_set_voice_cutoff_hz>` **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` cutoff_hz **)** |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_voice_delay_ms<class_AudioEffectChorus_method_set_voice_delay_ms>` **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` delay_ms **)** |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_voice_depth_ms<class_AudioEffectChorus_method_set_voice_depth_ms>` **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` depth_ms **)** |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_voice_level_db<class_AudioEffectChorus_method_set_voice_level_db>` **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` level_db **)** |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_voice_pan<class_AudioEffectChorus_method_set_voice_pan>` **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` pan **)** |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_voice_rate_hz<class_AudioEffectChorus_method_set_voice_rate_hz>` **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` rate_hz **)** |
|
||||
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectChorus_property_dry:
|
||||
|
||||
- :ref:`float<class_float>` **dry**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_dry(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_dry() |
|
||||
+-----------+----------------+
|
||||
|
||||
La señal en bruto del efecto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/1/cutoff_hz:
|
||||
|
||||
- :ref:`float<class_float>` **voice/1/cutoff_hz**
|
||||
|
||||
+-----------+----------------------------+
|
||||
| *Default* | ``8000.0`` |
|
||||
+-----------+----------------------------+
|
||||
| *Setter* | set_voice_cutoff_hz(value) |
|
||||
+-----------+----------------------------+
|
||||
| *Getter* | get_voice_cutoff_hz() |
|
||||
+-----------+----------------------------+
|
||||
|
||||
La frecuencia de corte de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/1/delay_ms:
|
||||
|
||||
- :ref:`float<class_float>` **voice/1/delay_ms**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``15.0`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_voice_delay_ms(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_voice_delay_ms() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
El retraso de la señal de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/1/depth_ms:
|
||||
|
||||
- :ref:`float<class_float>` **voice/1/depth_ms**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``2.0`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_voice_depth_ms(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_voice_depth_ms() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
El filtro de profundidad de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/1/level_db:
|
||||
|
||||
- :ref:`float<class_float>` **voice/1/level_db**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_voice_level_db(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_voice_level_db() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
El volumen de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/1/pan:
|
||||
|
||||
- :ref:`float<class_float>` **voice/1/pan**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``-0.5`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_voice_pan(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_voice_pan() |
|
||||
+-----------+----------------------+
|
||||
|
||||
El nivel de distribucion de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/1/rate_hz:
|
||||
|
||||
- :ref:`float<class_float>` **voice/1/rate_hz**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``0.8`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_voice_rate_hz(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_voice_rate_hz() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
El ratio del filtro de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/2/cutoff_hz:
|
||||
|
||||
- :ref:`float<class_float>` **voice/2/cutoff_hz**
|
||||
|
||||
+-----------+----------------------------+
|
||||
| *Default* | ``8000.0`` |
|
||||
+-----------+----------------------------+
|
||||
| *Setter* | set_voice_cutoff_hz(value) |
|
||||
+-----------+----------------------------+
|
||||
| *Getter* | get_voice_cutoff_hz() |
|
||||
+-----------+----------------------------+
|
||||
|
||||
La frecuencia de corte de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/2/delay_ms:
|
||||
|
||||
- :ref:`float<class_float>` **voice/2/delay_ms**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``20.0`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_voice_delay_ms(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_voice_delay_ms() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
El retraso de la señal de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/2/depth_ms:
|
||||
|
||||
- :ref:`float<class_float>` **voice/2/depth_ms**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``3.0`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_voice_depth_ms(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_voice_depth_ms() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
El filtro de profundidad de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/2/level_db:
|
||||
|
||||
- :ref:`float<class_float>` **voice/2/level_db**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_voice_level_db(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_voice_level_db() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
El volumen de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/2/pan:
|
||||
|
||||
- :ref:`float<class_float>` **voice/2/pan**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``0.5`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_voice_pan(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_voice_pan() |
|
||||
+-----------+----------------------+
|
||||
|
||||
El nivel de distribucion de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/2/rate_hz:
|
||||
|
||||
- :ref:`float<class_float>` **voice/2/rate_hz**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``1.2`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_voice_rate_hz(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_voice_rate_hz() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
El ratio del filtro de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/3/cutoff_hz:
|
||||
|
||||
- :ref:`float<class_float>` **voice/3/cutoff_hz**
|
||||
|
||||
+----------+----------------------------+
|
||||
| *Setter* | set_voice_cutoff_hz(value) |
|
||||
+----------+----------------------------+
|
||||
| *Getter* | get_voice_cutoff_hz() |
|
||||
+----------+----------------------------+
|
||||
|
||||
La frecuencia de corte de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/3/delay_ms:
|
||||
|
||||
- :ref:`float<class_float>` **voice/3/delay_ms**
|
||||
|
||||
+----------+---------------------------+
|
||||
| *Setter* | set_voice_delay_ms(value) |
|
||||
+----------+---------------------------+
|
||||
| *Getter* | get_voice_delay_ms() |
|
||||
+----------+---------------------------+
|
||||
|
||||
El retraso de la señal de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/3/depth_ms:
|
||||
|
||||
- :ref:`float<class_float>` **voice/3/depth_ms**
|
||||
|
||||
+----------+---------------------------+
|
||||
| *Setter* | set_voice_depth_ms(value) |
|
||||
+----------+---------------------------+
|
||||
| *Getter* | get_voice_depth_ms() |
|
||||
+----------+---------------------------+
|
||||
|
||||
El filtro de profundidad de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/3/level_db:
|
||||
|
||||
- :ref:`float<class_float>` **voice/3/level_db**
|
||||
|
||||
+----------+---------------------------+
|
||||
| *Setter* | set_voice_level_db(value) |
|
||||
+----------+---------------------------+
|
||||
| *Getter* | get_voice_level_db() |
|
||||
+----------+---------------------------+
|
||||
|
||||
El volumen de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/3/pan:
|
||||
|
||||
- :ref:`float<class_float>` **voice/3/pan**
|
||||
|
||||
+----------+----------------------+
|
||||
| *Setter* | set_voice_pan(value) |
|
||||
+----------+----------------------+
|
||||
| *Getter* | get_voice_pan() |
|
||||
+----------+----------------------+
|
||||
|
||||
El nivel de distribucion de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/3/rate_hz:
|
||||
|
||||
- :ref:`float<class_float>` **voice/3/rate_hz**
|
||||
|
||||
+----------+--------------------------+
|
||||
| *Setter* | set_voice_rate_hz(value) |
|
||||
+----------+--------------------------+
|
||||
| *Getter* | get_voice_rate_hz() |
|
||||
+----------+--------------------------+
|
||||
|
||||
El ratio del filtro de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/4/cutoff_hz:
|
||||
|
||||
- :ref:`float<class_float>` **voice/4/cutoff_hz**
|
||||
|
||||
+----------+----------------------------+
|
||||
| *Setter* | set_voice_cutoff_hz(value) |
|
||||
+----------+----------------------------+
|
||||
| *Getter* | get_voice_cutoff_hz() |
|
||||
+----------+----------------------------+
|
||||
|
||||
La frecuencia de corte de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/4/delay_ms:
|
||||
|
||||
- :ref:`float<class_float>` **voice/4/delay_ms**
|
||||
|
||||
+----------+---------------------------+
|
||||
| *Setter* | set_voice_delay_ms(value) |
|
||||
+----------+---------------------------+
|
||||
| *Getter* | get_voice_delay_ms() |
|
||||
+----------+---------------------------+
|
||||
|
||||
El retraso de la señal de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/4/depth_ms:
|
||||
|
||||
- :ref:`float<class_float>` **voice/4/depth_ms**
|
||||
|
||||
+----------+---------------------------+
|
||||
| *Setter* | set_voice_depth_ms(value) |
|
||||
+----------+---------------------------+
|
||||
| *Getter* | get_voice_depth_ms() |
|
||||
+----------+---------------------------+
|
||||
|
||||
El filtro de profundidad de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/4/level_db:
|
||||
|
||||
- :ref:`float<class_float>` **voice/4/level_db**
|
||||
|
||||
+----------+---------------------------+
|
||||
| *Setter* | set_voice_level_db(value) |
|
||||
+----------+---------------------------+
|
||||
| *Getter* | get_voice_level_db() |
|
||||
+----------+---------------------------+
|
||||
|
||||
El volumen de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/4/pan:
|
||||
|
||||
- :ref:`float<class_float>` **voice/4/pan**
|
||||
|
||||
+----------+----------------------+
|
||||
| *Setter* | set_voice_pan(value) |
|
||||
+----------+----------------------+
|
||||
| *Getter* | get_voice_pan() |
|
||||
+----------+----------------------+
|
||||
|
||||
El nivel de distribucion de la voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice/4/rate_hz:
|
||||
|
||||
- :ref:`float<class_float>` **voice/4/rate_hz**
|
||||
|
||||
+----------+--------------------------+
|
||||
| *Setter* | set_voice_rate_hz(value) |
|
||||
+----------+--------------------------+
|
||||
| *Getter* | get_voice_rate_hz() |
|
||||
+----------+--------------------------+
|
||||
|
||||
El ratio del filtro de voz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_voice_count:
|
||||
|
||||
- :ref:`int<class_int>` **voice_count**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``2`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_voice_count(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_voice_count() |
|
||||
+-----------+------------------------+
|
||||
|
||||
La cantidad de voces en el efecto.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_property_wet:
|
||||
|
||||
- :ref:`float<class_float>` **wet**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``0.5`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_wet(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_wet() |
|
||||
+-----------+----------------+
|
||||
|
||||
La señal procesada del efecto.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectChorus_method_get_voice_cutoff_hz:
|
||||
|
||||
- :ref:`float<class_float>` **get_voice_cutoff_hz** **(** :ref:`int<class_int>` voice_idx **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_method_get_voice_delay_ms:
|
||||
|
||||
- :ref:`float<class_float>` **get_voice_delay_ms** **(** :ref:`int<class_int>` voice_idx **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_method_get_voice_depth_ms:
|
||||
|
||||
- :ref:`float<class_float>` **get_voice_depth_ms** **(** :ref:`int<class_int>` voice_idx **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_method_get_voice_level_db:
|
||||
|
||||
- :ref:`float<class_float>` **get_voice_level_db** **(** :ref:`int<class_int>` voice_idx **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_method_get_voice_pan:
|
||||
|
||||
- :ref:`float<class_float>` **get_voice_pan** **(** :ref:`int<class_int>` voice_idx **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_method_get_voice_rate_hz:
|
||||
|
||||
- :ref:`float<class_float>` **get_voice_rate_hz** **(** :ref:`int<class_int>` voice_idx **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_method_set_voice_cutoff_hz:
|
||||
|
||||
- void **set_voice_cutoff_hz** **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` cutoff_hz **)**
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_method_set_voice_delay_ms:
|
||||
|
||||
- void **set_voice_delay_ms** **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` delay_ms **)**
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_method_set_voice_depth_ms:
|
||||
|
||||
- void **set_voice_depth_ms** **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` depth_ms **)**
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_method_set_voice_level_db:
|
||||
|
||||
- void **set_voice_level_db** **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` level_db **)**
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_method_set_voice_pan:
|
||||
|
||||
- void **set_voice_pan** **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` pan **)**
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectChorus_method_set_voice_rate_hz:
|
||||
|
||||
- void **set_voice_rate_hz** **(** :ref:`int<class_int>` voice_idx, :ref:`float<class_float>` rate_hz **)**
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,167 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectCompressor.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectCompressor:
|
||||
|
||||
AudioEffectCompressor
|
||||
=====================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un efecto de audio de compresion al bus de audio.
|
||||
|
||||
Reduces los sonidos que exceden un cierto umbral de sonido, suaviza la dinamica y aumenta el volumen total.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
El compresor de rango dinamico disminuye el nivel de sonido cuando la amplitud se va por encima de cierto umbral en decibelios. Uno de los principales usos de un compresor es para incrementar el rango dinamico recortado tan poco como sea posible( cuando el sonido pasa los 0dB).
|
||||
|
||||
El compresor tiene muchos usos en la mezcla:
|
||||
|
||||
- En el bus Maestro comprime la salida completa (Aunque un :ref:`AudioEffectLimiter<class_AudioEffectLimiter>` es probablemente mejor).
|
||||
|
||||
- En los canales de voces asegura que los sonidos estan balanceados lo maximo posible.
|
||||
|
||||
-Encadenado. Esto puede reducir el nivel de sonido encadenado con otro bus de audio para la deteccion de umbral. Esta tecnica es comun en la mezcla de videojuegos del nivel de musica y SFX mientras que las voces son escuchadas.
|
||||
|
||||
- Acentua transitorios usando un ataque amplio, haciendo los efectos mas contundentes.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------+--------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`attack_us<class_AudioEffectCompressor_property_attack_us>` | ``20.0`` |
|
||||
+-----------------------------+--------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`gain<class_AudioEffectCompressor_property_gain>` | ``0.0`` |
|
||||
+-----------------------------+--------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`mix<class_AudioEffectCompressor_property_mix>` | ``1.0`` |
|
||||
+-----------------------------+--------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`ratio<class_AudioEffectCompressor_property_ratio>` | ``4.0`` |
|
||||
+-----------------------------+--------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`release_ms<class_AudioEffectCompressor_property_release_ms>` | ``250.0`` |
|
||||
+-----------------------------+--------------------------------------------------------------------+-----------+
|
||||
| :ref:`String<class_String>` | :ref:`sidechain<class_AudioEffectCompressor_property_sidechain>` | ``""`` |
|
||||
+-----------------------------+--------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`threshold<class_AudioEffectCompressor_property_threshold>` | ``0.0`` |
|
||||
+-----------------------------+--------------------------------------------------------------------+-----------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectCompressor_property_attack_us:
|
||||
|
||||
- :ref:`float<class_float>` **attack_us**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``20.0`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_attack_us(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_attack_us() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Tiempo de reaccion del compreso cuando la señal excede el umbral, en microsegundos. El valor puede variar entre 20 y 2000.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCompressor_property_gain:
|
||||
|
||||
- :ref:`float<class_float>` **gain**
|
||||
|
||||
+-----------+-----------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-----------------+
|
||||
| *Setter* | set_gain(value) |
|
||||
+-----------+-----------------+
|
||||
| *Getter* | get_gain() |
|
||||
+-----------+-----------------+
|
||||
|
||||
Ganancia aplicada a la señal de salida.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCompressor_property_mix:
|
||||
|
||||
- :ref:`float<class_float>` **mix**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_mix(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_mix() |
|
||||
+-----------+----------------+
|
||||
|
||||
Balance entre la señal original y el efecto de señal. Valores pueden variar desde 0 (totalmente seco) a 1 (totalmente humedo).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCompressor_property_ratio:
|
||||
|
||||
- :ref:`float<class_float>` **ratio**
|
||||
|
||||
+-----------+------------------+
|
||||
| *Default* | ``4.0`` |
|
||||
+-----------+------------------+
|
||||
| *Setter* | set_ratio(value) |
|
||||
+-----------+------------------+
|
||||
| *Getter* | get_ratio() |
|
||||
+-----------+------------------+
|
||||
|
||||
La cantidad de compresion aplicada al audio una ves pasa el nivel del umbral. A mas alto el ratio, mas compresion a las partes altas se hara. Valores se encuentran entre 1 y 48.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCompressor_property_release_ms:
|
||||
|
||||
- :ref:`float<class_float>` **release_ms**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``250.0`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_release_ms(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_release_ms() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Tiempo de retraso del compresor para parar de reducir la señal despues de que el nivel caiga por debajo del umbral, en milisegundos. El valor puede variar entre 20 y 2000.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCompressor_property_sidechain:
|
||||
|
||||
- :ref:`String<class_String>` **sidechain**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``""`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_sidechain(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_sidechain() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Reduce el nivel de sonido usando otro bus de audio para la deteccion del umbral.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectCompressor_property_threshold:
|
||||
|
||||
- :ref:`float<class_float>` **threshold**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_threshold(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_threshold() |
|
||||
+-----------+----------------------+
|
||||
|
||||
El nivel por encima por el cual la compresion es aplicada al audio. El valor puede variar entre -60 y 0.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,265 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectDelay.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectDelay:
|
||||
|
||||
AudioEffectDelay
|
||||
================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un efecto de retraso al bus de audio. Reproduce la señal de entrada despues de un periodo de tiempo.
|
||||
|
||||
Dos opciones de retardo y de retroalimentacion.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Reproduce la señal de entrada después de un período de tiempo. La señal retardada puede ser reproducida varias veces para crear el sonido de un eco repetitivo y en decadencia. Los efectos de retardo van desde un sutil efecto de eco hasta una pronunciada mezcla de los sonidos anteriores con los nuevos sonidos.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`dry<class_AudioEffectDelay_property_dry>` | ``1.0`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`feedback/active<class_AudioEffectDelay_property_feedback/active>` | ``false`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`feedback/delay_ms<class_AudioEffectDelay_property_feedback/delay_ms>` | ``340.0`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`feedback/level_db<class_AudioEffectDelay_property_feedback/level_db>` | ``-6.0`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`feedback/lowpass<class_AudioEffectDelay_property_feedback/lowpass>` | ``16000.0`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`tap1/active<class_AudioEffectDelay_property_tap1/active>` | ``true`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`tap1/delay_ms<class_AudioEffectDelay_property_tap1/delay_ms>` | ``250.0`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`tap1/level_db<class_AudioEffectDelay_property_tap1/level_db>` | ``-6.0`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`tap1/pan<class_AudioEffectDelay_property_tap1/pan>` | ``0.2`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`tap2/active<class_AudioEffectDelay_property_tap2/active>` | ``true`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`tap2/delay_ms<class_AudioEffectDelay_property_tap2/delay_ms>` | ``500.0`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`tap2/level_db<class_AudioEffectDelay_property_tap2/level_db>` | ``-12.0`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`tap2/pan<class_AudioEffectDelay_property_tap2/pan>` | ``-0.4`` |
|
||||
+---------------------------+-----------------------------------------------------------------------------+-------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectDelay_property_dry:
|
||||
|
||||
- :ref:`float<class_float>` **dry**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_dry(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_dry() |
|
||||
+-----------+----------------+
|
||||
|
||||
El porcentaje de salida del sonido original. A 0, sólo se emiten sonidos retrasados. El valor puede variar entre 0 y 1.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_feedback/active:
|
||||
|
||||
- :ref:`bool<class_bool>` **feedback/active**
|
||||
|
||||
+-----------+----------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+----------------------------+
|
||||
| *Setter* | set_feedback_active(value) |
|
||||
+-----------+----------------------------+
|
||||
| *Getter* | is_feedback_active() |
|
||||
+-----------+----------------------------+
|
||||
|
||||
Si ``true``, la retroalimentación está activada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_feedback/delay_ms:
|
||||
|
||||
- :ref:`float<class_float>` **feedback/delay_ms**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``340.0`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_feedback_delay_ms(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_feedback_delay_ms() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
Tiempo de retraso de la retroalimentación en milisegundos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_feedback/level_db:
|
||||
|
||||
- :ref:`float<class_float>` **feedback/level_db**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``-6.0`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_feedback_level_db(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_feedback_level_db() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
Nivel de sonido para ``tap1``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_feedback/lowpass:
|
||||
|
||||
- :ref:`float<class_float>` **feedback/lowpass**
|
||||
|
||||
+-----------+-----------------------------+
|
||||
| *Default* | ``16000.0`` |
|
||||
+-----------+-----------------------------+
|
||||
| *Setter* | set_feedback_lowpass(value) |
|
||||
+-----------+-----------------------------+
|
||||
| *Getter* | get_feedback_lowpass() |
|
||||
+-----------+-----------------------------+
|
||||
|
||||
Filtro de paso bajo para retroalimentación, en Hz. Las frecuencias por debajo de este valor se filtran de la señal de origen.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_tap1/active:
|
||||
|
||||
- :ref:`bool<class_bool>` **tap1/active**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_tap1_active(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | is_tap1_active() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Si ``true``, ``tap1`` se activará.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_tap1/delay_ms:
|
||||
|
||||
- :ref:`float<class_float>` **tap1/delay_ms**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``250.0`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_tap1_delay_ms(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_tap1_delay_ms() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
Tiempo de retardo en milisegundos ``tap1``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_tap1/level_db:
|
||||
|
||||
- :ref:`float<class_float>` **tap1/level_db**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``-6.0`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_tap1_level_db(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_tap1_level_db() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
Nivel de sonido para ``tap1``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_tap1/pan:
|
||||
|
||||
- :ref:`float<class_float>` **tap1/pan**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``0.2`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_tap1_pan(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_tap1_pan() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Posición de Pan para ``tap1``. El valor puede variar entre -1 (completamente a la izquierda) y 1 (completamente a la derecha).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_tap2/active:
|
||||
|
||||
- :ref:`bool<class_bool>` **tap2/active**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_tap2_active(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | is_tap2_active() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Si ``true``, ``tap2`` se habilitara.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_tap2/delay_ms:
|
||||
|
||||
- :ref:`float<class_float>` **tap2/delay_ms**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``500.0`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_tap2_delay_ms(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_tap2_delay_ms() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
Tiempo de retardo en milisegundos **Tap2**.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_tap2/level_db:
|
||||
|
||||
- :ref:`float<class_float>` **tap2/level_db**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``-12.0`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_tap2_level_db(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_tap2_level_db() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
Nivel de sonido para ``tap2``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDelay_property_tap2/pan:
|
||||
|
||||
- :ref:`float<class_float>` **tap2/pan**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``-0.4`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_tap2_pan(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_tap2_pan() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Posición de pan para ``tap2``. El valor puede variar entre -1 (completamente a la izquierda) y 1 (completamente a la derecha).
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,155 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectDistortion.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectDistortion:
|
||||
|
||||
AudioEffectDistortion
|
||||
=====================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Adds a distortion audio effect to an Audio bus.
|
||||
|
||||
Modify the sound to make it distorted.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Different types are available: clip, tan, lo-fi (bit crushing), overdrive, or waveshape.
|
||||
|
||||
By distorting the waveform the frequency content change, which will often make the sound "crunchy" or "abrasive". For games, it can simulate sound coming from some saturated device or speaker very efficiently.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Audio buses <../tutorials/audio/audio_buses>`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+----------------------------------------------+--------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`drive<class_AudioEffectDistortion_property_drive>` | ``0.0`` |
|
||||
+----------------------------------------------+--------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`keep_hf_hz<class_AudioEffectDistortion_property_keep_hf_hz>` | ``16000.0`` |
|
||||
+----------------------------------------------+--------------------------------------------------------------------+-------------+
|
||||
| :ref:`Mode<enum_AudioEffectDistortion_Mode>` | :ref:`mode<class_AudioEffectDistortion_property_mode>` | ``0`` |
|
||||
+----------------------------------------------+--------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`post_gain<class_AudioEffectDistortion_property_post_gain>` | ``0.0`` |
|
||||
+----------------------------------------------+--------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`pre_gain<class_AudioEffectDistortion_property_pre_gain>` | ``0.0`` |
|
||||
+----------------------------------------------+--------------------------------------------------------------------+-------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AudioEffectDistortion_Mode:
|
||||
|
||||
.. _class_AudioEffectDistortion_constant_MODE_CLIP:
|
||||
|
||||
.. _class_AudioEffectDistortion_constant_MODE_ATAN:
|
||||
|
||||
.. _class_AudioEffectDistortion_constant_MODE_LOFI:
|
||||
|
||||
.. _class_AudioEffectDistortion_constant_MODE_OVERDRIVE:
|
||||
|
||||
.. _class_AudioEffectDistortion_constant_MODE_WAVESHAPE:
|
||||
|
||||
enum **Mode**:
|
||||
|
||||
- **MODE_CLIP** = **0** --- Efecto de distorsión digital que corta los picos en la parte superior e inferior de la forma de onda.
|
||||
|
||||
- **MODE_ATAN** = **1**
|
||||
|
||||
- **MODE_LOFI** = **2** --- Efecto de distorsión digital de baja resolución. Puedes usarlo para emular el sonido de los primeros dispositivos de audio digital.
|
||||
|
||||
- **MODE_OVERDRIVE** = **3** --- Emula la distorsión cálida producida por un transistor de efecto de campo, que se utiliza comúnmente en los amplificadores de instrumentos musicales de estado sólido.
|
||||
|
||||
- **MODE_WAVESHAPE** = **4** --- Las distorsiones Waveshaper son usadas principalmente por músicos electrónicos para lograr un sonido extra-abrasivo.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectDistortion_property_drive:
|
||||
|
||||
- :ref:`float<class_float>` **drive**
|
||||
|
||||
+-----------+------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+------------------+
|
||||
| *Setter* | set_drive(value) |
|
||||
+-----------+------------------+
|
||||
| *Getter* | get_drive() |
|
||||
+-----------+------------------+
|
||||
|
||||
Poder de distorsión. El valor puede variar entre 0 y 1.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDistortion_property_keep_hf_hz:
|
||||
|
||||
- :ref:`float<class_float>` **keep_hf_hz**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``16000.0`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_keep_hf_hz(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_keep_hf_hz() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Filtro de paso alto, en Hz. Las frecuencias superiores a este valor no se verán afectadas por la distorsión. El valor puede variar entre 1 y 20.000.Filtro de paso alto, en Hz. Las frecuencias superiores a este valor no se verán afectadas por la distorsión. El valor puede variar entre 1 y 20.000.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDistortion_property_mode:
|
||||
|
||||
- :ref:`Mode<enum_AudioEffectDistortion_Mode>` **mode**
|
||||
|
||||
+-----------+-----------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+-----------------+
|
||||
| *Setter* | set_mode(value) |
|
||||
+-----------+-----------------+
|
||||
| *Getter* | get_mode() |
|
||||
+-----------+-----------------+
|
||||
|
||||
Tipo de distorsión.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDistortion_property_post_gain:
|
||||
|
||||
- :ref:`float<class_float>` **post_gain**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_post_gain(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_post_gain() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Aumenta o disminuye el volumen después del efecto. El valor puede variar entre -80 y 24.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectDistortion_property_pre_gain:
|
||||
|
||||
- :ref:`float<class_float>` **pre_gain**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_pre_gain(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_pre_gain() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Aumenta o disminuye el volumen antes del efecto. El valor puede variar entre -60 y 60.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,63 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectEQ.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectEQ:
|
||||
|
||||
AudioEffectEQ
|
||||
=============
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`AudioEffectEQ10<class_AudioEffectEQ10>`, :ref:`AudioEffectEQ21<class_AudioEffectEQ21>`, :ref:`AudioEffectEQ6<class_AudioEffectEQ6>`
|
||||
|
||||
Clase base para ecualizadores de audio. Te da control sobre las frecuencias.
|
||||
|
||||
Úsalo para crear un ecualizador personalizado si :ref:`AudioEffectEQ6<class_AudioEffectEQ6>`, :ref:`AudioEffectEQ10<class_AudioEffectEQ10>` o :ref:`AudioEffectEQ21<class_AudioEffectEQ21>` no se ajusta a tus necesidades.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
AudioEffectEQ te da control sobre las frecuencias. Utilícelo para compensar las deficiencias existentes en el audio. Los AudioEffectEQs son útiles en el bus maestro para dominar completamente una mezcla y darle más carácter. También son útiles cuando se ejecuta un juego en un dispositivo móvil, para ajustar la mezcla a ese tipo de altavoces (se puede añadir pero se desactiva cuando se conectan los auriculares).
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_band_count<class_AudioEffectEQ_method_get_band_count>` **(** **)** |const| |
|
||||
+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_band_gain_db<class_AudioEffectEQ_method_get_band_gain_db>` **(** :ref:`int<class_int>` band_idx **)** |const| |
|
||||
+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_band_gain_db<class_AudioEffectEQ_method_set_band_gain_db>` **(** :ref:`int<class_int>` band_idx, :ref:`float<class_float>` volume_db **)** |
|
||||
+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectEQ_method_get_band_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_band_count** **(** **)** |const|
|
||||
|
||||
Devuelve el número de bandas del ecualizador.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectEQ_method_get_band_gain_db:
|
||||
|
||||
- :ref:`float<class_float>` **get_band_gain_db** **(** :ref:`int<class_int>` band_idx **)** |const|
|
||||
|
||||
Devuelve la ganancia de la banda en el índice especificado, en dB.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectEQ_method_set_band_gain_db:
|
||||
|
||||
- void **set_band_gain_db** **(** :ref:`int<class_int>` band_idx, :ref:`float<class_float>` volume_db **)**
|
||||
|
||||
Establece la ganancia de la banda en el índice especificado, en dB.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,47 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectEQ10.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectEQ10:
|
||||
|
||||
AudioEffectEQ10
|
||||
===============
|
||||
|
||||
**Inherits:** :ref:`AudioEffectEQ<class_AudioEffectEQ>` **<** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un efecto de audio ecualizador de 10 bandas a un bus de audio. Te da control sobre las frecuencias de 31 Hz a 16000 Hz.
|
||||
|
||||
Cada frecuencia puede ser modulada entre -60/+24 dB.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Bandas de frecuencia:
|
||||
|
||||
Banda 1: 31 Hz
|
||||
|
||||
Banda 2: 62 Hz
|
||||
|
||||
Banda 3: 125 Hz
|
||||
|
||||
Banda 4: 250 Hz
|
||||
|
||||
Banda 5: 500 Hz
|
||||
|
||||
Banda 6: 1000 Hz
|
||||
|
||||
Banda 7: 2000 Hz
|
||||
|
||||
Banda 8: 4000 Hz
|
||||
|
||||
Banda 9: 8000 Hz
|
||||
|
||||
Banda 10: 16000 Hz
|
||||
|
||||
Ver también :ref:`AudioEffectEQ<class_AudioEffectEQ>`, :ref:`AudioEffectEQ6<class_AudioEffectEQ6>`, :ref:`AudioEffectEQ21<class_AudioEffectEQ21>`.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,69 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectEQ21.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectEQ21:
|
||||
|
||||
AudioEffectEQ21
|
||||
===============
|
||||
|
||||
**Inherits:** :ref:`AudioEffectEQ<class_AudioEffectEQ>` **<** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un efecto de audio ecualizador de 21 bandas a un Audiobus. Te da control sobre las frecuencias de 22 Hz a 22000 Hz.
|
||||
|
||||
Cada frecuencia puede ser modulada entre -60/+24 dB.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Bandas de frecuencia:
|
||||
|
||||
Banda 1: 22 Hz
|
||||
|
||||
Banda 2: 32 Hz
|
||||
|
||||
Banda 3: 44 Hz
|
||||
|
||||
Banda 4: 63 Hz
|
||||
|
||||
Banda 5: 90 Hz
|
||||
|
||||
Banda 6: 125 Hz
|
||||
|
||||
Banda 7: 175 Hz
|
||||
|
||||
Banda 8: 250 Hz
|
||||
|
||||
Banda 9: 350 Hz
|
||||
|
||||
Banda 10: 500 Hz
|
||||
|
||||
Banda 11: 700 Hz
|
||||
|
||||
Banda 12: 1000 Hz
|
||||
|
||||
Banda 13: 1400 Hz
|
||||
|
||||
Banda 14: 2000 Hz
|
||||
|
||||
Banda 15: 2800 Hz
|
||||
|
||||
Banda 16: 4000 Hz
|
||||
|
||||
Banda 17: 5600 Hz
|
||||
|
||||
Banda 18: 8000 Hz
|
||||
|
||||
Banda 19: 11000 Hz
|
||||
|
||||
Banda 20: 16000 Hz
|
||||
|
||||
Banda 21: 22000 Hz
|
||||
|
||||
Ver también :ref:`AudioEffectEQ<class_AudioEffectEQ>`, :ref:`AudioEffectEQ6<class_AudioEffectEQ6>`, :ref:`AudioEffectEQ10<class_AudioEffectEQ10>`.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,39 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectEQ6.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectEQ6:
|
||||
|
||||
AudioEffectEQ6
|
||||
==============
|
||||
|
||||
**Inherits:** :ref:`AudioEffectEQ<class_AudioEffectEQ>` **<** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un efecto de audio ecualizador de 6 bandas a un bus de Audio. Te da control sobre las frecuencias de 32 Hz a 10.000 Hz.
|
||||
|
||||
Cada frecuencia puede ser modulada entre -60/+24 dB.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Bandas de frecuencia:
|
||||
|
||||
Banda 1: 32 Hz
|
||||
|
||||
Banda 2: 100 Hz
|
||||
|
||||
Banda 3: 320 Hz
|
||||
|
||||
Banda 4: 1000 Hz
|
||||
|
||||
Banda 5: 3200 Hz
|
||||
|
||||
Banda 6: 10000 Hz
|
||||
|
||||
Ver también :ref:`AudioEffectEQ<class_AudioEffectEQ>`, :ref:`AudioEffectEQ10<class_AudioEffectEQ10>`, :ref:`AudioEffectEQ21<class_AudioEffectEQ21>`.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,129 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectFilter.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectFilter:
|
||||
|
||||
AudioEffectFilter
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`AudioEffectBandLimitFilter<class_AudioEffectBandLimitFilter>`, :ref:`AudioEffectBandPassFilter<class_AudioEffectBandPassFilter>`, :ref:`AudioEffectHighPassFilter<class_AudioEffectHighPassFilter>`, :ref:`AudioEffectHighShelfFilter<class_AudioEffectHighShelfFilter>`, :ref:`AudioEffectLowPassFilter<class_AudioEffectLowPassFilter>`, :ref:`AudioEffectLowShelfFilter<class_AudioEffectLowShelfFilter>`, :ref:`AudioEffectNotchFilter<class_AudioEffectNotchFilter>`
|
||||
|
||||
Añade un filtro al bus de audio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Permite que pasen otras frecuencias distintas a la de :ref:`cutoff_hz<class_AudioEffectFilter_property_cutoff_hz>`.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Audio buses <../tutorials/audio/audio_buses>`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+--------------------------------------------------+--------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`cutoff_hz<class_AudioEffectFilter_property_cutoff_hz>` | ``2000.0`` |
|
||||
+--------------------------------------------------+--------------------------------------------------------------+------------+
|
||||
| :ref:`FilterDB<enum_AudioEffectFilter_FilterDB>` | :ref:`db<class_AudioEffectFilter_property_db>` | ``0`` |
|
||||
+--------------------------------------------------+--------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`gain<class_AudioEffectFilter_property_gain>` | ``1.0`` |
|
||||
+--------------------------------------------------+--------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`resonance<class_AudioEffectFilter_property_resonance>` | ``0.5`` |
|
||||
+--------------------------------------------------+--------------------------------------------------------------+------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AudioEffectFilter_FilterDB:
|
||||
|
||||
.. _class_AudioEffectFilter_constant_FILTER_6DB:
|
||||
|
||||
.. _class_AudioEffectFilter_constant_FILTER_12DB:
|
||||
|
||||
.. _class_AudioEffectFilter_constant_FILTER_18DB:
|
||||
|
||||
.. _class_AudioEffectFilter_constant_FILTER_24DB:
|
||||
|
||||
enum **FilterDB**:
|
||||
|
||||
- **FILTER_6DB** = **0**
|
||||
|
||||
- **FILTER_12DB** = **1**
|
||||
|
||||
- **FILTER_18DB** = **2**
|
||||
|
||||
- **FILTER_24DB** = **3**
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectFilter_property_cutoff_hz:
|
||||
|
||||
- :ref:`float<class_float>` **cutoff_hz**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``2000.0`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_cutoff(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_cutoff() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Frecuencia de umbral para el filtro, en Hz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectFilter_property_db:
|
||||
|
||||
- :ref:`FilterDB<enum_AudioEffectFilter_FilterDB>` **db**
|
||||
|
||||
+-----------+---------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+---------------+
|
||||
| *Setter* | set_db(value) |
|
||||
+-----------+---------------+
|
||||
| *Getter* | get_db() |
|
||||
+-----------+---------------+
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectFilter_property_gain:
|
||||
|
||||
- :ref:`float<class_float>` **gain**
|
||||
|
||||
+-----------+-----------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+-----------------+
|
||||
| *Setter* | set_gain(value) |
|
||||
+-----------+-----------------+
|
||||
| *Getter* | get_gain() |
|
||||
+-----------+-----------------+
|
||||
|
||||
Ganar cantidad de frecuencias después del filtro.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectFilter_property_resonance:
|
||||
|
||||
- :ref:`float<class_float>` **resonance**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``0.5`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_resonance(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_resonance() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Amount of boost in the frequency range near the cutoff frequency.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,23 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectHighPassFilter.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectHighPassFilter:
|
||||
|
||||
AudioEffectHighPassFilter
|
||||
=========================
|
||||
|
||||
**Inherits:** :ref:`AudioEffectFilter<class_AudioEffectFilter>` **<** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un filtro de paso alto al Audio Bus.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Corta las frecuencias más bajas que el :ref:`AudioEffectFilter.cutoff_hz<class_AudioEffectFilter_property_cutoff_hz>` y permite que pasen las frecuencias más altas.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,23 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectHighShelfFilter.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectHighShelfFilter:
|
||||
|
||||
AudioEffectHighShelfFilter
|
||||
==========================
|
||||
|
||||
**Inherits:** :ref:`AudioEffectFilter<class_AudioEffectFilter>` **<** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Reduces all frequencies above the :ref:`AudioEffectFilter.cutoff_hz<class_AudioEffectFilter_property_cutoff_hz>`.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Audio buses <../tutorials/audio/audio_buses>`
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,20 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectInstance.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectInstance:
|
||||
|
||||
AudioEffectInstance
|
||||
===================
|
||||
|
||||
**Inherits:** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`AudioEffectSpectrumAnalyzerInstance<class_AudioEffectSpectrumAnalyzerInstance>`
|
||||
|
||||
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,101 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectLimiter.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectLimiter:
|
||||
|
||||
AudioEffectLimiter
|
||||
==================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un efecto de audio limitador soft-clip a un bus de Audio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Un limitador es similar a un compresor, pero es menos flexible y está diseñado para no permitir que el sonido supere un determinado umbral de dB. Siempre se recomienda añadir un limitador en el bus maestro para reducir los efectos del recorte.
|
||||
|
||||
El soft clipping comienza a reducir los picos un poco por debajo del nivel de umbral y aumenta progresivamente su efecto a medida que el nivel de entrada aumenta de tal manera que el umbral nunca se supera.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+---------------------------------------------------------------------------+----------+
|
||||
| :ref:`float<class_float>` | :ref:`ceiling_db<class_AudioEffectLimiter_property_ceiling_db>` | ``-0.1`` |
|
||||
+---------------------------+---------------------------------------------------------------------------+----------+
|
||||
| :ref:`float<class_float>` | :ref:`soft_clip_db<class_AudioEffectLimiter_property_soft_clip_db>` | ``2.0`` |
|
||||
+---------------------------+---------------------------------------------------------------------------+----------+
|
||||
| :ref:`float<class_float>` | :ref:`soft_clip_ratio<class_AudioEffectLimiter_property_soft_clip_ratio>` | ``10.0`` |
|
||||
+---------------------------+---------------------------------------------------------------------------+----------+
|
||||
| :ref:`float<class_float>` | :ref:`threshold_db<class_AudioEffectLimiter_property_threshold_db>` | ``0.0`` |
|
||||
+---------------------------+---------------------------------------------------------------------------+----------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectLimiter_property_ceiling_db:
|
||||
|
||||
- :ref:`float<class_float>` **ceiling_db**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``-0.1`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_ceiling_db(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_ceiling_db() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
El valor máximo permitido de la forma de onda, en decibeles. El valor puede ir de -20 a -0,1.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectLimiter_property_soft_clip_db:
|
||||
|
||||
- :ref:`float<class_float>` **soft_clip_db**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``2.0`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_soft_clip_db(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_soft_clip_db() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
Aplica una ganancia a las ondas limitadas, en decibelios. El valor puede variar entre 0 y 6.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectLimiter_property_soft_clip_ratio:
|
||||
|
||||
- :ref:`float<class_float>` **soft_clip_ratio**
|
||||
|
||||
+-----------+----------------------------+
|
||||
| *Default* | ``10.0`` |
|
||||
+-----------+----------------------------+
|
||||
| *Setter* | set_soft_clip_ratio(value) |
|
||||
+-----------+----------------------------+
|
||||
| *Getter* | get_soft_clip_ratio() |
|
||||
+-----------+----------------------------+
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectLimiter_property_threshold_db:
|
||||
|
||||
- :ref:`float<class_float>` **threshold_db**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_threshold_db(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_threshold_db() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
Umbral a partir del cual el limitador comienza a estar activo, en decibelios. El valor puede ir de -30 a 0.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,23 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectLowPassFilter.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectLowPassFilter:
|
||||
|
||||
AudioEffectLowPassFilter
|
||||
========================
|
||||
|
||||
**Inherits:** :ref:`AudioEffectFilter<class_AudioEffectFilter>` **<** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un filtro de paso bajo al bus de Audio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Corta las frecuencias más altas que el :ref:`AudioEffectFilter.cutoff_hz<class_AudioEffectFilter_property_cutoff_hz>` y permite que pasen las frecuencias más bajas.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,23 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectLowShelfFilter.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectLowShelfFilter:
|
||||
|
||||
AudioEffectLowShelfFilter
|
||||
=========================
|
||||
|
||||
**Inherits:** :ref:`AudioEffectFilter<class_AudioEffectFilter>` **<** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Reduces all frequencies below the :ref:`AudioEffectFilter.cutoff_hz<class_AudioEffectFilter_property_cutoff_hz>`.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Audio buses <../tutorials/audio/audio_buses>`
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,23 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectNotchFilter.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectNotchFilter:
|
||||
|
||||
AudioEffectNotchFilter
|
||||
======================
|
||||
|
||||
**Inherits:** :ref:`AudioEffectFilter<class_AudioEffectFilter>` **<** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un filtro eliminador de banda al bus de Audio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Atenúa las frecuencias en una banda estrecha alrededor del :ref:`AudioEffectFilter.cutoff_hz<class_AudioEffectFilter_property_cutoff_hz>` y corta las frecuencias fuera de este rango.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,47 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectPanner.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectPanner:
|
||||
|
||||
AudioEffectPanner
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un efecto de audio de panorámica a un Audiobus. Las cacerolas suenan a la izquierda o a la derecha.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Determina cuánta señal de audio se envía a los buses izquierdo y derecho.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+--------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`pan<class_AudioEffectPanner_property_pan>` | ``0.0`` |
|
||||
+---------------------------+--------------------------------------------------+---------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectPanner_property_pan:
|
||||
|
||||
- :ref:`float<class_float>` **pan**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_pan(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_pan() |
|
||||
+-----------+----------------+
|
||||
|
||||
Posición de panoramica. El valor puede variar entre -1 (completamente a la izquierda) y 1 (completamente a la derecha).
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,121 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectPhaser.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectPhaser:
|
||||
|
||||
AudioEffectPhaser
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un efecto de audio phaser a un bus de Audio.
|
||||
|
||||
Combina la señal original con una copia que está ligeramente fuera de fase con la señal original.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Combina las señales de desplazamiento de fase con la señal original. El movimiento de las señales de desplazamiento de fase se controla mediante un oscilador de baja frecuencia.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+--------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`depth<class_AudioEffectPhaser_property_depth>` | ``1.0`` |
|
||||
+---------------------------+--------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`feedback<class_AudioEffectPhaser_property_feedback>` | ``0.7`` |
|
||||
+---------------------------+--------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`range_max_hz<class_AudioEffectPhaser_property_range_max_hz>` | ``1600.0`` |
|
||||
+---------------------------+--------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`range_min_hz<class_AudioEffectPhaser_property_range_min_hz>` | ``440.0`` |
|
||||
+---------------------------+--------------------------------------------------------------------+------------+
|
||||
| :ref:`float<class_float>` | :ref:`rate_hz<class_AudioEffectPhaser_property_rate_hz>` | ``0.5`` |
|
||||
+---------------------------+--------------------------------------------------------------------+------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectPhaser_property_depth:
|
||||
|
||||
- :ref:`float<class_float>` **depth**
|
||||
|
||||
+-----------+------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------+
|
||||
| *Setter* | set_depth(value) |
|
||||
+-----------+------------------+
|
||||
| *Getter* | get_depth() |
|
||||
+-----------+------------------+
|
||||
|
||||
Gobierna cuán altas son las frecuencias de los filtros de barrido. El valor bajo afectará principalmente a las frecuencias bajas. El valor alto puede barrer alto en el triple. El valor puede variar entre 0,1 y 4.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectPhaser_property_feedback:
|
||||
|
||||
- :ref:`float<class_float>` **feedback**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``0.7`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_feedback(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_feedback() |
|
||||
+-----------+---------------------+
|
||||
|
||||
El porcentaje de salida del sonido modificado. El valor puede variar entre 0,1 y 0,9.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectPhaser_property_range_max_hz:
|
||||
|
||||
- :ref:`float<class_float>` **range_max_hz**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``1600.0`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_range_max_hz(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_range_max_hz() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
Determina la máxima frecuencia afectada por las modulaciones del LFO, en Hz. El valor puede variar entre 10 y 10.000.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectPhaser_property_range_min_hz:
|
||||
|
||||
- :ref:`float<class_float>` **range_min_hz**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``440.0`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_range_min_hz(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_range_min_hz() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
Determina la frecuencia mínima afectada por las modulaciones del LFO, en Hz. El valor puede variar entre 10 y 10.000.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectPhaser_property_rate_hz:
|
||||
|
||||
- :ref:`float<class_float>` **rate_hz**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``0.5`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_rate_hz(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | get_rate_hz() |
|
||||
+-----------+--------------------+
|
||||
|
||||
Ajusta la tasa en Hz a la que el efecto barre hacia arriba y hacia abajo a través del rango de frecuencias.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,116 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectPitchShift.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectPitchShift:
|
||||
|
||||
AudioEffectPitchShift
|
||||
=====================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un efecto de audio de cambio de tono a un bus de Audio.
|
||||
|
||||
Sube o baja el tono del sonido original.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Permite la modulación del tono independientemente del tempo. Todas las frecuencias pueden ser aumentadas/disminuidas con un efecto mínimo en los transitorios.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+------------------------------------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`FFT_Size<enum_AudioEffectPitchShift_FFT_Size>` | :ref:`fft_size<class_AudioEffectPitchShift_property_fft_size>` | ``3`` |
|
||||
+------------------------------------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`int<class_int>` | :ref:`oversampling<class_AudioEffectPitchShift_property_oversampling>` | ``4`` |
|
||||
+------------------------------------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`pitch_scale<class_AudioEffectPitchShift_property_pitch_scale>` | ``1.0`` |
|
||||
+------------------------------------------------------+------------------------------------------------------------------------+---------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AudioEffectPitchShift_FFT_Size:
|
||||
|
||||
.. _class_AudioEffectPitchShift_constant_FFT_SIZE_256:
|
||||
|
||||
.. _class_AudioEffectPitchShift_constant_FFT_SIZE_512:
|
||||
|
||||
.. _class_AudioEffectPitchShift_constant_FFT_SIZE_1024:
|
||||
|
||||
.. _class_AudioEffectPitchShift_constant_FFT_SIZE_2048:
|
||||
|
||||
.. _class_AudioEffectPitchShift_constant_FFT_SIZE_4096:
|
||||
|
||||
.. _class_AudioEffectPitchShift_constant_FFT_SIZE_MAX:
|
||||
|
||||
enum **FFT_Size**:
|
||||
|
||||
- **FFT_SIZE_256** = **0** --- Use a buffer of 256 samples for the Fast Fourier transform. Lowest latency, but least stable over time.
|
||||
|
||||
- **FFT_SIZE_512** = **1** --- Use a buffer of 512 samples for the Fast Fourier transform. Low latency, but less stable over time.
|
||||
|
||||
- **FFT_SIZE_1024** = **2** --- Use a buffer of 1024 samples for the Fast Fourier transform. This is a compromise between latency and stability over time.
|
||||
|
||||
- **FFT_SIZE_2048** = **3** --- Use a buffer of 2048 samples for the Fast Fourier transform. High latency, but stable over time.
|
||||
|
||||
- **FFT_SIZE_4096** = **4** --- Use a buffer of 4096 samples for the Fast Fourier transform. Highest latency, but most stable over time.
|
||||
|
||||
- **FFT_SIZE_MAX** = **5** --- Representa el tamaño del enum :ref:`FFT_Size<enum_AudioEffectPitchShift_FFT_Size>`.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectPitchShift_property_fft_size:
|
||||
|
||||
- :ref:`FFT_Size<enum_AudioEffectPitchShift_FFT_Size>` **fft_size**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``3`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_fft_size(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_fft_size() |
|
||||
+-----------+---------------------+
|
||||
|
||||
The size of the `Fast Fourier transform <https://en.wikipedia.org/wiki/Fast_Fourier_transform>`__ buffer. Higher values smooth out the effect over time, but have greater latency. The effects of this higher latency are especially noticeable on sounds that have sudden amplitude changes.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectPitchShift_property_oversampling:
|
||||
|
||||
- :ref:`int<class_int>` **oversampling**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``4`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_oversampling(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_oversampling() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
The oversampling factor to use. Higher values result in better quality, but are more demanding on the CPU and may cause audio cracking if the CPU can't keep up.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectPitchShift_property_pitch_scale:
|
||||
|
||||
- :ref:`float<class_float>` **pitch_scale**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_pitch_scale(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_pitch_scale() |
|
||||
+-----------+------------------------+
|
||||
|
||||
The pitch scale to use. ``1.0`` is the default pitch and plays sounds unaltered. :ref:`pitch_scale<class_AudioEffectPitchShift_property_pitch_scale>` can range from ``0.0`` (infinitely low pitch, inaudible) to ``16`` (16 times higher than the initial pitch).
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,90 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectRecord.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectRecord:
|
||||
|
||||
AudioEffectRecord
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Efecto de audio usado para grabar el sonido de un micrófono.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Permite al usuario grabar el sonido desde un micrófono. Establece y obtiene el formato en el que se grabará el archivo de audio (8-bit, 16-bit o comprimido). Comprueba si la grabación está activa o no, y si lo está, graba el sonido. Luego devuelve la muestra grabada.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Recording with microphone <../tutorials/audio/recording_with_microphone>`
|
||||
|
||||
- `Audio Mic Record Demo <https://godotengine.org/asset-library/asset/527>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+----------------------------------------------+--------------------------------------------------------+-------+
|
||||
| :ref:`Format<enum_AudioStreamSample_Format>` | :ref:`format<class_AudioEffectRecord_property_format>` | ``1`` |
|
||||
+----------------------------------------------+--------------------------------------------------------+-------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AudioStreamSample<class_AudioStreamSample>` | :ref:`get_recording<class_AudioEffectRecord_method_get_recording>` **(** **)** |const| |
|
||||
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_recording_active<class_AudioEffectRecord_method_is_recording_active>` **(** **)** |const| |
|
||||
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_recording_active<class_AudioEffectRecord_method_set_recording_active>` **(** :ref:`bool<class_bool>` record **)** |
|
||||
+---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectRecord_property_format:
|
||||
|
||||
- :ref:`Format<enum_AudioStreamSample_Format>` **format**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_format(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_format() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Especifica el formato en el que se registrará la muestra. Véase :ref:`Format<enum_AudioStreamSample_Format>` para los formatos disponibles.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectRecord_method_get_recording:
|
||||
|
||||
- :ref:`AudioStreamSample<class_AudioStreamSample>` **get_recording** **(** **)** |const|
|
||||
|
||||
Devuelve la muestra registrada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectRecord_method_is_recording_active:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_recording_active** **(** **)** |const|
|
||||
|
||||
Devuelve si la grabación está activa o no.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectRecord_method_set_recording_active:
|
||||
|
||||
- void **set_recording_active** **(** :ref:`bool<class_bool>` record **)**
|
||||
|
||||
Si ``true``, el sonido será grabado. Tenga en cuenta que al reiniciar la grabación se eliminará la muestra previamente grabada.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,180 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectReverb.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectReverb:
|
||||
|
||||
AudioEffectReverb
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Añade un efecto de audio de reverberación a un bus de Audio.
|
||||
|
||||
Simula el sonido de ambientes acústicos como salas, salones de conciertos, cavernas o un espacio abierto.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Simula habitaciones de diferentes tamaños. Sus parámetros pueden ser ajustados para simular el sonido de una habitación específica.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- `Third Person Shooter Demo <https://godotengine.org/asset-library/asset/678>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`damping<class_AudioEffectReverb_property_damping>` | ``0.5`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`dry<class_AudioEffectReverb_property_dry>` | ``1.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`hipass<class_AudioEffectReverb_property_hipass>` | ``0.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`predelay_feedback<class_AudioEffectReverb_property_predelay_feedback>` | ``0.4`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`predelay_msec<class_AudioEffectReverb_property_predelay_msec>` | ``150.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`room_size<class_AudioEffectReverb_property_room_size>` | ``0.8`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`spread<class_AudioEffectReverb_property_spread>` | ``1.0`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`wet<class_AudioEffectReverb_property_wet>` | ``0.5`` |
|
||||
+---------------------------+------------------------------------------------------------------------------+-----------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectReverb_property_damping:
|
||||
|
||||
- :ref:`float<class_float>` **damping**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``0.5`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_damping(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | get_damping() |
|
||||
+-----------+--------------------+
|
||||
|
||||
Define cuán reflexivas son las paredes de la sala imaginaria. El valor puede variar entre 0 y 1.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectReverb_property_dry:
|
||||
|
||||
- :ref:`float<class_float>` **dry**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_dry(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_dry() |
|
||||
+-----------+----------------+
|
||||
|
||||
El porcentaje de salida del sonido original. A 0, sólo se emite el sonido modificado. El valor puede variar entre 0 y 1.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectReverb_property_hipass:
|
||||
|
||||
- :ref:`float<class_float>` **hipass**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_hpf(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_hpf() |
|
||||
+-----------+----------------+
|
||||
|
||||
El filtro de paso alto pasa señales con una frecuencia superior a una determinada frecuencia de corte y atenúa las señales con frecuencias inferiores a la frecuencia de corte. El valor puede variar entre 0 y 1.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectReverb_property_predelay_feedback:
|
||||
|
||||
- :ref:`float<class_float>` **predelay_feedback**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``0.4`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_predelay_feedback(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_predelay_feedback() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
El porcentaje de salida de la preretardo. El valor puede variar entre 0 y 1.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectReverb_property_predelay_msec:
|
||||
|
||||
- :ref:`float<class_float>` **predelay_msec**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``150.0`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_predelay_msec(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_predelay_msec() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
Tiempo entre la señal original y las primeras reflexiones de la señal de reverberación, en milisegundos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectReverb_property_room_size:
|
||||
|
||||
- :ref:`float<class_float>` **room_size**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``0.8`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_room_size(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_room_size() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Dimensiones de la habitación simulada. Más grande significa más ecos. El valor puede variar entre 0 y 1.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectReverb_property_spread:
|
||||
|
||||
- :ref:`float<class_float>` **spread**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_spread(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_spread() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Amplía o estrecha la imagen estéreo de la cola de reverberación. 1 significa que se ensancha completamente. El valor puede variar entre 0 y 1.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectReverb_property_wet:
|
||||
|
||||
- :ref:`float<class_float>` **wet**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``0.5`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_wet(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_wet() |
|
||||
+-----------+----------------+
|
||||
|
||||
El porcentaje de salida del sonido modificado. A 0, sólo se emite el sonido original. El valor puede variar entre 0 y 1.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,121 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectSpectrumAnalyzer.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzer:
|
||||
|
||||
AudioEffectSpectrumAnalyzer
|
||||
===========================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Audio effect that can be used for real-time audio visualizations.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
This audio effect does not affect sound output, but can be used for real-time audio visualizations.
|
||||
|
||||
See also :ref:`AudioStreamGenerator<class_AudioStreamGenerator>` for procedurally generating sounds.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- `https://godotengine.org/asset-library/asset/528 <Audio Spectrum Demo>`__
|
||||
|
||||
- `https://godotengine.org/article/godot-32-will-get-new-audio-features <Godot 3.2 will get new audio features>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+----------+
|
||||
| :ref:`float<class_float>` | :ref:`buffer_length<class_AudioEffectSpectrumAnalyzer_property_buffer_length>` | ``2.0`` |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+----------+
|
||||
| :ref:`FFT_Size<enum_AudioEffectSpectrumAnalyzer_FFT_Size>` | :ref:`fft_size<class_AudioEffectSpectrumAnalyzer_property_fft_size>` | ``2`` |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+----------+
|
||||
| :ref:`float<class_float>` | :ref:`tap_back_pos<class_AudioEffectSpectrumAnalyzer_property_tap_back_pos>` | ``0.01`` |
|
||||
+------------------------------------------------------------+--------------------------------------------------------------------------------+----------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AudioEffectSpectrumAnalyzer_FFT_Size:
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzer_constant_FFT_SIZE_256:
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzer_constant_FFT_SIZE_512:
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzer_constant_FFT_SIZE_1024:
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzer_constant_FFT_SIZE_2048:
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzer_constant_FFT_SIZE_4096:
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzer_constant_FFT_SIZE_MAX:
|
||||
|
||||
enum **FFT_Size**:
|
||||
|
||||
- **FFT_SIZE_256** = **0** --- Use a buffer of 256 samples for the Fast Fourier transform. Lowest latency, but least stable over time.
|
||||
|
||||
- **FFT_SIZE_512** = **1** --- Use a buffer of 512 samples for the Fast Fourier transform. Low latency, but less stable over time.
|
||||
|
||||
- **FFT_SIZE_1024** = **2** --- Use a buffer of 1024 samples for the Fast Fourier transform. This is a compromise between latency and stability over time.
|
||||
|
||||
- **FFT_SIZE_2048** = **3** --- Use a buffer of 2048 samples for the Fast Fourier transform. High latency, but stable over time.
|
||||
|
||||
- **FFT_SIZE_4096** = **4** --- Use a buffer of 4096 samples for the Fast Fourier transform. Highest latency, but most stable over time.
|
||||
|
||||
- **FFT_SIZE_MAX** = **5** --- Representa el tamaño del enum :ref:`FFT_Size<enum_AudioEffectSpectrumAnalyzer_FFT_Size>`.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzer_property_buffer_length:
|
||||
|
||||
- :ref:`float<class_float>` **buffer_length**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``2.0`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_buffer_length(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_buffer_length() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
The length of the buffer to keep (in seconds). Higher values keep data around for longer, but require more memory.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzer_property_fft_size:
|
||||
|
||||
- :ref:`FFT_Size<enum_AudioEffectSpectrumAnalyzer_FFT_Size>` **fft_size**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``2`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_fft_size(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_fft_size() |
|
||||
+-----------+---------------------+
|
||||
|
||||
The size of the `Fast Fourier transform <https://en.wikipedia.org/wiki/Fast_Fourier_transform>`__ buffer. Higher values smooth out the spectrum analysis over time, but have greater latency. The effects of this higher latency are especially noticeable with sudden amplitude changes.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzer_property_tap_back_pos:
|
||||
|
||||
- :ref:`float<class_float>` **tap_back_pos**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``0.01`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_tap_back_pos(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_tap_back_pos() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,47 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectSpectrumAnalyzerInstance.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzerInstance:
|
||||
|
||||
AudioEffectSpectrumAnalyzerInstance
|
||||
===================================
|
||||
|
||||
**Inherits:** :ref:`AudioEffectInstance<class_AudioEffectInstance>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`get_magnitude_for_frequency_range<class_AudioEffectSpectrumAnalyzerInstance_method_get_magnitude_for_frequency_range>` **(** :ref:`float<class_float>` from_hz, :ref:`float<class_float>` to_hz, :ref:`MagnitudeMode<enum_AudioEffectSpectrumAnalyzerInstance_MagnitudeMode>` mode=1 **)** |const| |
|
||||
+-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AudioEffectSpectrumAnalyzerInstance_MagnitudeMode:
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzerInstance_constant_MAGNITUDE_AVERAGE:
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzerInstance_constant_MAGNITUDE_MAX:
|
||||
|
||||
enum **MagnitudeMode**:
|
||||
|
||||
- **MAGNITUDE_AVERAGE** = **0** --- Utilice el valor promedio como magnitud.
|
||||
|
||||
- **MAGNITUDE_MAX** = **1** --- Utilice el valor máximo como magnitud.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectSpectrumAnalyzerInstance_method_get_magnitude_for_frequency_range:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **get_magnitude_for_frequency_range** **(** :ref:`float<class_float>` from_hz, :ref:`float<class_float>` to_hz, :ref:`MagnitudeMode<enum_AudioEffectSpectrumAnalyzerInstance_MagnitudeMode>` mode=1 **)** |const|
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,72 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioEffectStereoEnhance.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioEffectStereoEnhance:
|
||||
|
||||
AudioEffectStereoEnhance
|
||||
========================
|
||||
|
||||
**Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+---------------------------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`pan_pullout<class_AudioEffectStereoEnhance_property_pan_pullout>` | ``1.0`` |
|
||||
+---------------------------+---------------------------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`surround<class_AudioEffectStereoEnhance_property_surround>` | ``0.0`` |
|
||||
+---------------------------+---------------------------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`time_pullout_ms<class_AudioEffectStereoEnhance_property_time_pullout_ms>` | ``0.0`` |
|
||||
+---------------------------+---------------------------------------------------------------------------------+---------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioEffectStereoEnhance_property_pan_pullout:
|
||||
|
||||
- :ref:`float<class_float>` **pan_pullout**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_pan_pullout(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_pan_pullout() |
|
||||
+-----------+------------------------+
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectStereoEnhance_property_surround:
|
||||
|
||||
- :ref:`float<class_float>` **surround**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_surround(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_surround() |
|
||||
+-----------+---------------------+
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioEffectStereoEnhance_property_time_pullout_ms:
|
||||
|
||||
- :ref:`float<class_float>` **time_pullout_ms**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_time_pullout(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_time_pullout() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,534 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioServer.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioServer:
|
||||
|
||||
AudioServer
|
||||
===========
|
||||
|
||||
**Inherits:** :ref:`Object<class_Object>`
|
||||
|
||||
Interfaz de servidor para acceso de audio de bajo nivel.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
``AudioServer`` es una interfaz de servidor de bajo nivel para el acceso al audio. Se encarga de crear datos de muestra (audio reproducible) así como de su reproducción a través de una interfaz de voz.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Audio buses <../tutorials/audio/audio_buses>`
|
||||
|
||||
- `Audio Device Changer Demo <https://godotengine.org/asset-library/asset/525>`__
|
||||
|
||||
- `Audio Mic Record Demo <https://godotengine.org/asset-library/asset/527>`__
|
||||
|
||||
- `Audio Spectrum Demo <https://godotengine.org/asset-library/asset/528>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------+------------------------------------------------------------------------+---------------+
|
||||
| :ref:`int<class_int>` | :ref:`bus_count<class_AudioServer_property_bus_count>` | ``1`` |
|
||||
+-----------------------------+------------------------------------------------------------------------+---------------+
|
||||
| :ref:`String<class_String>` | :ref:`device<class_AudioServer_property_device>` | ``"Default"`` |
|
||||
+-----------------------------+------------------------------------------------------------------------+---------------+
|
||||
| :ref:`float<class_float>` | :ref:`global_rate_scale<class_AudioServer_property_global_rate_scale>` | ``1.0`` |
|
||||
+-----------------------------+------------------------------------------------------------------------+---------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_bus<class_AudioServer_method_add_bus>` **(** :ref:`int<class_int>` at_position=-1 **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_bus_effect<class_AudioServer_method_add_bus_effect>` **(** :ref:`int<class_int>` bus_idx, :ref:`AudioEffect<class_AudioEffect>` effect, :ref:`int<class_int>` at_position=-1 **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`capture_get_device<class_AudioServer_method_capture_get_device>` **(** **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`capture_get_device_list<class_AudioServer_method_capture_get_device_list>` **(** **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`capture_set_device<class_AudioServer_method_capture_set_device>` **(** :ref:`String<class_String>` name **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AudioBusLayout<class_AudioBusLayout>` | :ref:`generate_bus_layout<class_AudioServer_method_generate_bus_layout>` **(** **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_bus_channels<class_AudioServer_method_get_bus_channels>` **(** :ref:`int<class_int>` bus_idx **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AudioEffect<class_AudioEffect>` | :ref:`get_bus_effect<class_AudioServer_method_get_bus_effect>` **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_bus_effect_count<class_AudioServer_method_get_bus_effect_count>` **(** :ref:`int<class_int>` bus_idx **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AudioEffectInstance<class_AudioEffectInstance>` | :ref:`get_bus_effect_instance<class_AudioServer_method_get_bus_effect_instance>` **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx, :ref:`int<class_int>` channel=0 **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_bus_index<class_AudioServer_method_get_bus_index>` **(** :ref:`String<class_String>` bus_name **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_bus_name<class_AudioServer_method_get_bus_name>` **(** :ref:`int<class_int>` bus_idx **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_bus_peak_volume_left_db<class_AudioServer_method_get_bus_peak_volume_left_db>` **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` channel **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_bus_peak_volume_right_db<class_AudioServer_method_get_bus_peak_volume_right_db>` **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` channel **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`get_bus_send<class_AudioServer_method_get_bus_send>` **(** :ref:`int<class_int>` bus_idx **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_bus_volume_db<class_AudioServer_method_get_bus_volume_db>` **(** :ref:`int<class_int>` bus_idx **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`get_device_list<class_AudioServer_method_get_device_list>` **(** **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_mix_rate<class_AudioServer_method_get_mix_rate>` **(** **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_output_latency<class_AudioServer_method_get_output_latency>` **(** **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`SpeakerMode<enum_AudioServer_SpeakerMode>` | :ref:`get_speaker_mode<class_AudioServer_method_get_speaker_mode>` **(** **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_time_since_last_mix<class_AudioServer_method_get_time_since_last_mix>` **(** **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_time_to_next_mix<class_AudioServer_method_get_time_to_next_mix>` **(** **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_bus_bypassing_effects<class_AudioServer_method_is_bus_bypassing_effects>` **(** :ref:`int<class_int>` bus_idx **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_bus_effect_enabled<class_AudioServer_method_is_bus_effect_enabled>` **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_bus_mute<class_AudioServer_method_is_bus_mute>` **(** :ref:`int<class_int>` bus_idx **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_bus_solo<class_AudioServer_method_is_bus_solo>` **(** :ref:`int<class_int>` bus_idx **)** |const| |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`lock<class_AudioServer_method_lock>` **(** **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`move_bus<class_AudioServer_method_move_bus>` **(** :ref:`int<class_int>` index, :ref:`int<class_int>` to_index **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_bus<class_AudioServer_method_remove_bus>` **(** :ref:`int<class_int>` index **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`remove_bus_effect<class_AudioServer_method_remove_bus_effect>` **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bus_bypass_effects<class_AudioServer_method_set_bus_bypass_effects>` **(** :ref:`int<class_int>` bus_idx, :ref:`bool<class_bool>` enable **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bus_effect_enabled<class_AudioServer_method_set_bus_effect_enabled>` **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx, :ref:`bool<class_bool>` enabled **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bus_layout<class_AudioServer_method_set_bus_layout>` **(** :ref:`AudioBusLayout<class_AudioBusLayout>` bus_layout **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bus_mute<class_AudioServer_method_set_bus_mute>` **(** :ref:`int<class_int>` bus_idx, :ref:`bool<class_bool>` enable **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bus_name<class_AudioServer_method_set_bus_name>` **(** :ref:`int<class_int>` bus_idx, :ref:`String<class_String>` name **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bus_send<class_AudioServer_method_set_bus_send>` **(** :ref:`int<class_int>` bus_idx, :ref:`String<class_String>` send **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bus_solo<class_AudioServer_method_set_bus_solo>` **(** :ref:`int<class_int>` bus_idx, :ref:`bool<class_bool>` enable **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bus_volume_db<class_AudioServer_method_set_bus_volume_db>` **(** :ref:`int<class_int>` bus_idx, :ref:`float<class_float>` volume_db **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`swap_bus_effects<class_AudioServer_method_swap_bus_effects>` **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx, :ref:`int<class_int>` by_effect_idx **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`unlock<class_AudioServer_method_unlock>` **(** **)** |
|
||||
+-------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_AudioServer_signal_bus_layout_changed:
|
||||
|
||||
- **bus_layout_changed** **(** **)**
|
||||
|
||||
Se emite cuando cambia el :ref:`AudioBusLayout<class_AudioBusLayout>`.
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AudioServer_SpeakerMode:
|
||||
|
||||
.. _class_AudioServer_constant_SPEAKER_MODE_STEREO:
|
||||
|
||||
.. _class_AudioServer_constant_SPEAKER_SURROUND_31:
|
||||
|
||||
.. _class_AudioServer_constant_SPEAKER_SURROUND_51:
|
||||
|
||||
.. _class_AudioServer_constant_SPEAKER_SURROUND_71:
|
||||
|
||||
enum **SpeakerMode**:
|
||||
|
||||
- **SPEAKER_MODE_STEREO** = **0** --- Se detectaron dos o menos altavoces.
|
||||
|
||||
- **SPEAKER_SURROUND_31** = **1** --- Se detectó una configuración de sonido envolvente de 3.1 canales.
|
||||
|
||||
- **SPEAKER_SURROUND_51** = **2** --- Se detectó una configuración de sonido envolvente de 5.1 canales.
|
||||
|
||||
- **SPEAKER_SURROUND_71** = **3** --- Se detectó una configuración de sonido envolvente de 7.1 canales.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioServer_property_bus_count:
|
||||
|
||||
- :ref:`int<class_int>` **bus_count**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_bus_count(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_bus_count() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Número de buses de audio disponibles.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_property_device:
|
||||
|
||||
- :ref:`String<class_String>` **device**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``"Default"`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_device(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_device() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Nombre del dispositivo actual para la salida de audio (ver :ref:`get_device_list<class_AudioServer_method_get_device_list>`).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_property_global_rate_scale:
|
||||
|
||||
- :ref:`float<class_float>` **global_rate_scale**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_global_rate_scale(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_global_rate_scale() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
Escala la velocidad a la que se reproduce el audio (es decir, si se ajusta a ``0,5`` el audio se reproducirá el doble de rápido).
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioServer_method_add_bus:
|
||||
|
||||
- void **add_bus** **(** :ref:`int<class_int>` at_position=-1 **)**
|
||||
|
||||
Añade un bus en ``at_position``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_add_bus_effect:
|
||||
|
||||
- void **add_bus_effect** **(** :ref:`int<class_int>` bus_idx, :ref:`AudioEffect<class_AudioEffect>` effect, :ref:`int<class_int>` at_position=-1 **)**
|
||||
|
||||
Añade un efecto :ref:`AudioEffect<class_AudioEffect>` al bus ``bus_idx`` en ``at_position``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_capture_get_device:
|
||||
|
||||
- :ref:`String<class_String>` **capture_get_device** **(** **)**
|
||||
|
||||
Nombre del dispositivo actual para la entrada de audio (ver :ref:`capture_get_device_list<class_AudioServer_method_capture_get_device_list>`).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_capture_get_device_list:
|
||||
|
||||
- :ref:`Array<class_Array>` **capture_get_device_list** **(** **)**
|
||||
|
||||
Devuelve los nombres de todos los dispositivos de entrada de audio detectados en el sistema.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_capture_set_device:
|
||||
|
||||
- void **capture_set_device** **(** :ref:`String<class_String>` name **)**
|
||||
|
||||
Establece qué dispositivo de entrada de audio se utiliza para la captura de audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_generate_bus_layout:
|
||||
|
||||
- :ref:`AudioBusLayout<class_AudioBusLayout>` **generate_bus_layout** **(** **)** |const|
|
||||
|
||||
Genera un :ref:`AudioBusLayout<class_AudioBusLayout>` usando los buses y efectos disponibles.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_bus_channels:
|
||||
|
||||
- :ref:`int<class_int>` **get_bus_channels** **(** :ref:`int<class_int>` bus_idx **)** |const|
|
||||
|
||||
Devuelve la cantidad de canales del bus en el índice ``bus_idx``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_bus_effect:
|
||||
|
||||
- :ref:`AudioEffect<class_AudioEffect>` **get_bus_effect** **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx **)**
|
||||
|
||||
Devuelve el :ref:`AudioEffect<class_AudioEffect>` en la posición ``effect_idx`` en el bus ``bus_idx``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_bus_effect_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_bus_effect_count** **(** :ref:`int<class_int>` bus_idx **)**
|
||||
|
||||
Devuelve el número de efectos en el bus en ``bus_idx``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_bus_effect_instance:
|
||||
|
||||
- :ref:`AudioEffectInstance<class_AudioEffectInstance>` **get_bus_effect_instance** **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx, :ref:`int<class_int>` channel=0 **)**
|
||||
|
||||
Devuelve la :ref:`AudioEffectInstance<class_AudioEffectInstance>` asignada al bus dado y los indices de efecto (y opcionalmente el canal).
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_bus_index:
|
||||
|
||||
- :ref:`int<class_int>` **get_bus_index** **(** :ref:`String<class_String>` bus_name **)** |const|
|
||||
|
||||
Devuelve el índice del bus con el nombre ``bus_name``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_bus_name:
|
||||
|
||||
- :ref:`String<class_String>` **get_bus_name** **(** :ref:`int<class_int>` bus_idx **)** |const|
|
||||
|
||||
Devuelve el nombre del bus con el índice ``bus_idx``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_bus_peak_volume_left_db:
|
||||
|
||||
- :ref:`float<class_float>` **get_bus_peak_volume_left_db** **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` channel **)** |const|
|
||||
|
||||
Devuelve el volumen máximo del altavoz izquierdo en el índice de bus ``bus_idx`` y el índice de canal ``channel``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_bus_peak_volume_right_db:
|
||||
|
||||
- :ref:`float<class_float>` **get_bus_peak_volume_right_db** **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` channel **)** |const|
|
||||
|
||||
Devuelve el volumen máximo del altavoz derecho en el índice de bus ``bus_idx`` y el índice de canal ``channel``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_bus_send:
|
||||
|
||||
- :ref:`String<class_String>` **get_bus_send** **(** :ref:`int<class_int>` bus_idx **)** |const|
|
||||
|
||||
Devuelve el nombre del bus al que el bus en el índice ``bus_idx`` envía.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_bus_volume_db:
|
||||
|
||||
- :ref:`float<class_float>` **get_bus_volume_db** **(** :ref:`int<class_int>` bus_idx **)** |const|
|
||||
|
||||
Devuelve el volumen del bus con el índice ``bus_idx`` en dB.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_device_list:
|
||||
|
||||
- :ref:`Array<class_Array>` **get_device_list** **(** **)**
|
||||
|
||||
Devuelve los nombres de todos los dispositivos de audio detectados en el sistema.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_mix_rate:
|
||||
|
||||
- :ref:`float<class_float>` **get_mix_rate** **(** **)** |const|
|
||||
|
||||
Devuelve la frecuencia de muestreo a la salida del ``AudioServer``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_output_latency:
|
||||
|
||||
- :ref:`float<class_float>` **get_output_latency** **(** **)** |const|
|
||||
|
||||
Devuelve la latencia de salida del controlador de audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_speaker_mode:
|
||||
|
||||
- :ref:`SpeakerMode<enum_AudioServer_SpeakerMode>` **get_speaker_mode** **(** **)** |const|
|
||||
|
||||
Devuelve la configuración de los altavoces.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_time_since_last_mix:
|
||||
|
||||
- :ref:`float<class_float>` **get_time_since_last_mix** **(** **)** |const|
|
||||
|
||||
Devuelve el tiempo relativo desde que se produjo la última mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_get_time_to_next_mix:
|
||||
|
||||
- :ref:`float<class_float>` **get_time_to_next_mix** **(** **)** |const|
|
||||
|
||||
Devuelve el tiempo relativo hasta que se produce la siguiente mezcla.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_is_bus_bypassing_effects:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_bus_bypassing_effects** **(** :ref:`int<class_int>` bus_idx **)** |const|
|
||||
|
||||
Si ``true``, el bus en el índice ``bus_idx`` está ignorando los efectos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_is_bus_effect_enabled:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_bus_effect_enabled** **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx **)** |const|
|
||||
|
||||
Si ``true``, se activa el efecto en el índice ``effect_idx`` del bus en al índice ``bus_idx`` de bus habilidato.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_is_bus_mute:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_bus_mute** **(** :ref:`int<class_int>` bus_idx **)** |const|
|
||||
|
||||
Si ``true``, el bus en el índice ``bus_idx`` se silencia.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_is_bus_solo:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_bus_solo** **(** :ref:`int<class_int>` bus_idx **)** |const|
|
||||
|
||||
Si ``true``, el bus en el índice ``bus_idx`` está en modo solo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_lock:
|
||||
|
||||
- void **lock** **(** **)**
|
||||
|
||||
Bloquea el bucle principal del controlador de audio.
|
||||
|
||||
\ **Nota:** Recuerde desbloquearlo después.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_move_bus:
|
||||
|
||||
- void **move_bus** **(** :ref:`int<class_int>` index, :ref:`int<class_int>` to_index **)**
|
||||
|
||||
Mueve el bus desde el índice ``index`` a índice ``to_index``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_remove_bus:
|
||||
|
||||
- void **remove_bus** **(** :ref:`int<class_int>` index **)**
|
||||
|
||||
Elimina el bus en el índice ``index``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_remove_bus_effect:
|
||||
|
||||
- void **remove_bus_effect** **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx **)**
|
||||
|
||||
Elimina el efecto en el índice ``effect_idx`` del bus en el índice ``bus_idx``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_set_bus_bypass_effects:
|
||||
|
||||
- void **set_bus_bypass_effects** **(** :ref:`int<class_int>` bus_idx, :ref:`bool<class_bool>` enable **)**
|
||||
|
||||
Si ``true``, el bus en el índice ``bus_idx`` está ignorando los efectos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_set_bus_effect_enabled:
|
||||
|
||||
- void **set_bus_effect_enabled** **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx, :ref:`bool<class_bool>` enabled **)**
|
||||
|
||||
Si ``true``, se activa el efecto en el índice ``effect_idx`` del bus en al índice ``bus_idx`` de bus habilidato.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_set_bus_layout:
|
||||
|
||||
- void **set_bus_layout** **(** :ref:`AudioBusLayout<class_AudioBusLayout>` bus_layout **)**
|
||||
|
||||
Sobrescribe el :ref:`AudioBusLayout<class_AudioBusLayout>` actualmente utilizado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_set_bus_mute:
|
||||
|
||||
- void **set_bus_mute** **(** :ref:`int<class_int>` bus_idx, :ref:`bool<class_bool>` enable **)**
|
||||
|
||||
Si ``true``, el bus en el índice ``bus_idx`` se silencia.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_set_bus_name:
|
||||
|
||||
- void **set_bus_name** **(** :ref:`int<class_int>` bus_idx, :ref:`String<class_String>` name **)**
|
||||
|
||||
Establece el nombre del bus en el índice ``bus_idx`` a ``name``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_set_bus_send:
|
||||
|
||||
- void **set_bus_send** **(** :ref:`int<class_int>` bus_idx, :ref:`String<class_String>` send **)**
|
||||
|
||||
Conecta la salida del bus en ``bus_idx`` al bus llamado ``send``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_set_bus_solo:
|
||||
|
||||
- void **set_bus_solo** **(** :ref:`int<class_int>` bus_idx, :ref:`bool<class_bool>` enable **)**
|
||||
|
||||
Si ``true``, el bus en el índice ``bus_idx`` está en modo solo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_set_bus_volume_db:
|
||||
|
||||
- void **set_bus_volume_db** **(** :ref:`int<class_int>` bus_idx, :ref:`float<class_float>` volume_db **)**
|
||||
|
||||
Establece el volumen del bus en el índice ``bus_idx`` a ``volume_db``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_swap_bus_effects:
|
||||
|
||||
- void **swap_bus_effects** **(** :ref:`int<class_int>` bus_idx, :ref:`int<class_int>` effect_idx, :ref:`int<class_int>` by_effect_idx **)**
|
||||
|
||||
Cambia la posición de dos efectos en el bus ``bus_idx``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioServer_method_unlock:
|
||||
|
||||
- void **unlock** **(** **)**
|
||||
|
||||
Desbloquea el bucle principal del controlador de audio. (Después de cerrarlo, siempre debes abrirlo.)
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,52 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStream.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStream:
|
||||
|
||||
AudioStream
|
||||
===========
|
||||
|
||||
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`AudioStreamGenerator<class_AudioStreamGenerator>`, :ref:`AudioStreamMP3<class_AudioStreamMP3>`, :ref:`AudioStreamMicrophone<class_AudioStreamMicrophone>`, :ref:`AudioStreamOGGVorbis<class_AudioStreamOGGVorbis>`, :ref:`AudioStreamRandomPitch<class_AudioStreamRandomPitch>`, :ref:`AudioStreamSample<class_AudioStreamSample>`
|
||||
|
||||
Clase base para las transmisiones de audio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Clase base para las transmisiones de audio. Los flujos de audio se usan para efectos de sonido y reproducción de música, y soportan los formatos de archivo WAV (a través de :ref:`AudioStreamSample<class_AudioStreamSample>`) y OGG (a través de :ref:`AudioStreamOGGVorbis<class_AudioStreamOGGVorbis>`).
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Audio streams <../tutorials/audio/audio_streams>`
|
||||
|
||||
- `Audio Generator Demo <https://godotengine.org/asset-library/asset/526>`__
|
||||
|
||||
- `Audio Mic Record Demo <https://godotengine.org/asset-library/asset/527>`__
|
||||
|
||||
- `Audio Spectrum Demo <https://godotengine.org/asset-library/asset/528>`__
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------+----------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_length<class_AudioStream_method_get_length>` **(** **)** |const| |
|
||||
+---------------------------+----------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioStream_method_get_length:
|
||||
|
||||
- :ref:`float<class_float>` **get_length** **(** **)** |const|
|
||||
|
||||
Devuelve la duración del flujo de audio en segundos.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,80 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamGenerator.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamGenerator:
|
||||
|
||||
AudioStreamGenerator
|
||||
====================
|
||||
|
||||
**Inherits:** :ref:`AudioStream<class_AudioStream>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Audio stream that generates sounds procedurally.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
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>`.
|
||||
|
||||
See also :ref:`AudioEffectSpectrumAnalyzer<class_AudioEffectSpectrumAnalyzer>` for performing real-time audio spectrum analysis.
|
||||
|
||||
\ **Note:** Due to performance constraints, this class is best used from C# or from a compiled language via GDNative. If you still want to use this class from GDScript, consider using a lower :ref:`mix_rate<class_AudioStreamGenerator_property_mix_rate>` such as 11,025 Hz or 22,050 Hz.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- `Audio Generator Demo <https://godotengine.org/asset-library/asset/526>`__
|
||||
|
||||
- `https://godotengine.org/article/godot-32-will-get-new-audio-features <Godot 3.2 will get new audio features>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------+-------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`buffer_length<class_AudioStreamGenerator_property_buffer_length>` | ``0.5`` |
|
||||
+---------------------------+-------------------------------------------------------------------------+-------------+
|
||||
| :ref:`float<class_float>` | :ref:`mix_rate<class_AudioStreamGenerator_property_mix_rate>` | ``44100.0`` |
|
||||
+---------------------------+-------------------------------------------------------------------------+-------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamGenerator_property_buffer_length:
|
||||
|
||||
- :ref:`float<class_float>` **buffer_length**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``0.5`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_buffer_length(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_buffer_length() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
The length of the buffer to generate (in seconds). Lower values result in less latency, but require the script to generate audio data faster, resulting in increased CPU usage and more risk for audio cracking if the CPU can't keep up.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamGenerator_property_mix_rate:
|
||||
|
||||
- :ref:`float<class_float>` **mix_rate**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``44100.0`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_mix_rate(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_mix_rate() |
|
||||
+-----------+---------------------+
|
||||
|
||||
The sample rate to use (in Hz). Higher values are more demanding for the CPU to generate, but result in better quality.
|
||||
|
||||
In games, common sample rates in use are ``11025``, ``16000``, ``22050``, ``32000``, ``44100``, and ``48000``.
|
||||
|
||||
According to the `Nyquist-Shannon sampling theorem <https://en.wikipedia.org/wiki/Nyquist%E2%80%93Shannon_sampling_theorem>`__, there is no quality difference to human hearing when going past 40,000 Hz (since most humans can only hear up to ~20,000 Hz, often less). If you are generating lower-pitched sounds such as voices, lower sample rates such as ``32000`` or ``22050`` may be usable with no loss in quality.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,94 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamGeneratorPlayback.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamGeneratorPlayback:
|
||||
|
||||
AudioStreamGeneratorPlayback
|
||||
============================
|
||||
|
||||
**Inherits:** :ref:`AudioStreamPlaybackResampled<class_AudioStreamPlaybackResampled>` **<** :ref:`AudioStreamPlayback<class_AudioStreamPlayback>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Plays back audio generated using :ref:`AudioStreamGenerator<class_AudioStreamGenerator>`.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
This class is meant to be used with :ref:`AudioStreamGenerator<class_AudioStreamGenerator>` to play back the generated audio in real-time.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- `Audio Generator Demo <https://godotengine.org/asset-library/asset/526>`__
|
||||
|
||||
- `https://godotengine.org/article/godot-32-will-get-new-audio-features <Godot 3.2 will get new audio features>`__
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`can_push_buffer<class_AudioStreamGeneratorPlayback_method_can_push_buffer>` **(** :ref:`int<class_int>` amount **)** |const| |
|
||||
+-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear_buffer<class_AudioStreamGeneratorPlayback_method_clear_buffer>` **(** **)** |
|
||||
+-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_frames_available<class_AudioStreamGeneratorPlayback_method_get_frames_available>` **(** **)** |const| |
|
||||
+-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_skips<class_AudioStreamGeneratorPlayback_method_get_skips>` **(** **)** |const| |
|
||||
+-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`push_buffer<class_AudioStreamGeneratorPlayback_method_push_buffer>` **(** :ref:`PoolVector2Array<class_PoolVector2Array>` frames **)** |
|
||||
+-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`push_frame<class_AudioStreamGeneratorPlayback_method_push_frame>` **(** :ref:`Vector2<class_Vector2>` frame **)** |
|
||||
+-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamGeneratorPlayback_method_can_push_buffer:
|
||||
|
||||
- :ref:`bool<class_bool>` **can_push_buffer** **(** :ref:`int<class_int>` amount **)** |const|
|
||||
|
||||
Returns ``true`` if a buffer of the size ``amount`` can be pushed to the audio sample data buffer without overflowing it, ``false`` otherwise.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamGeneratorPlayback_method_clear_buffer:
|
||||
|
||||
- void **clear_buffer** **(** **)**
|
||||
|
||||
Clears the audio sample data buffer.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamGeneratorPlayback_method_get_frames_available:
|
||||
|
||||
- :ref:`int<class_int>` **get_frames_available** **(** **)** |const|
|
||||
|
||||
Returns the number of audio data frames left to play. If this returned number reaches ``0``, the audio will stop playing until frames are added again. Therefore, make sure your script can always generate and push new audio frames fast enough to avoid audio cracking.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamGeneratorPlayback_method_get_skips:
|
||||
|
||||
- :ref:`int<class_int>` **get_skips** **(** **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamGeneratorPlayback_method_push_buffer:
|
||||
|
||||
- :ref:`bool<class_bool>` **push_buffer** **(** :ref:`PoolVector2Array<class_PoolVector2Array>` frames **)**
|
||||
|
||||
Pushes several audio data frames to the buffer. This is usually more efficient than :ref:`push_frame<class_AudioStreamGeneratorPlayback_method_push_frame>` in C# and compiled languages via GDNative, but :ref:`push_buffer<class_AudioStreamGeneratorPlayback_method_push_buffer>` may be *less* efficient in GDScript.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamGeneratorPlayback_method_push_frame:
|
||||
|
||||
- :ref:`bool<class_bool>` **push_frame** **(** :ref:`Vector2<class_Vector2>` frame **)**
|
||||
|
||||
Pushes a single audio data frame to the buffer. This is usually less efficient than :ref:`push_buffer<class_AudioStreamGeneratorPlayback_method_push_buffer>` in C# and compiled languages via GDNative, but :ref:`push_frame<class_AudioStreamGeneratorPlayback_method_push_frame>` may be *more* efficient in GDScript.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,18 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamMicrophone.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamMicrophone:
|
||||
|
||||
AudioStreamMicrophone
|
||||
=====================
|
||||
|
||||
**Inherits:** :ref:`AudioStream<class_AudioStream>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
|
||||
|
||||
.. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
|
||||
.. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
|
||||
.. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
|
||||
@@ -1,83 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamMP3.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamMP3:
|
||||
|
||||
AudioStreamMP3
|
||||
==============
|
||||
|
||||
**Inherits:** :ref:`AudioStream<class_AudioStream>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
MP3 audio stream driver.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
MP3 audio stream driver.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------------------------+---------------------------------------------------------------+-----------------------+
|
||||
| :ref:`PoolByteArray<class_PoolByteArray>` | :ref:`data<class_AudioStreamMP3_property_data>` | ``PoolByteArray( )`` |
|
||||
+-------------------------------------------+---------------------------------------------------------------+-----------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`loop<class_AudioStreamMP3_property_loop>` | ``false`` |
|
||||
+-------------------------------------------+---------------------------------------------------------------+-----------------------+
|
||||
| :ref:`float<class_float>` | :ref:`loop_offset<class_AudioStreamMP3_property_loop_offset>` | ``0.0`` |
|
||||
+-------------------------------------------+---------------------------------------------------------------+-----------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamMP3_property_data:
|
||||
|
||||
- :ref:`PoolByteArray<class_PoolByteArray>` **data**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``PoolByteArray( )`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_data(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_data() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Contiene los datos de audio en bytes.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamMP3_property_loop:
|
||||
|
||||
- :ref:`bool<class_bool>` **loop**
|
||||
|
||||
+-----------+-----------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-----------------+
|
||||
| *Setter* | set_loop(value) |
|
||||
+-----------+-----------------+
|
||||
| *Getter* | has_loop() |
|
||||
+-----------+-----------------+
|
||||
|
||||
Si ``true``, el stream se repite automáticamente cuando llega al final.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamMP3_property_loop_offset:
|
||||
|
||||
- :ref:`float<class_float>` **loop_offset**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_loop_offset(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_loop_offset() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Tiempo en segundos en el que el stream comienza después de ser enlazada.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,83 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamOGGVorbis.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamOGGVorbis:
|
||||
|
||||
AudioStreamOGGVorbis
|
||||
====================
|
||||
|
||||
**Inherits:** :ref:`AudioStream<class_AudioStream>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Controlador de flujo de audio OGG Vorbis.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Controlador de flujo de audio OGG Vorbis.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------------------------+---------------------------------------------------------------------+-----------------------+
|
||||
| :ref:`PoolByteArray<class_PoolByteArray>` | :ref:`data<class_AudioStreamOGGVorbis_property_data>` | ``PoolByteArray( )`` |
|
||||
+-------------------------------------------+---------------------------------------------------------------------+-----------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`loop<class_AudioStreamOGGVorbis_property_loop>` | ``false`` |
|
||||
+-------------------------------------------+---------------------------------------------------------------------+-----------------------+
|
||||
| :ref:`float<class_float>` | :ref:`loop_offset<class_AudioStreamOGGVorbis_property_loop_offset>` | ``0.0`` |
|
||||
+-------------------------------------------+---------------------------------------------------------------------+-----------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamOGGVorbis_property_data:
|
||||
|
||||
- :ref:`PoolByteArray<class_PoolByteArray>` **data**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``PoolByteArray( )`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_data(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_data() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Contiene los datos de audio en bytes.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamOGGVorbis_property_loop:
|
||||
|
||||
- :ref:`bool<class_bool>` **loop**
|
||||
|
||||
+-----------+-----------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-----------------+
|
||||
| *Setter* | set_loop(value) |
|
||||
+-----------+-----------------+
|
||||
| *Getter* | has_loop() |
|
||||
+-----------+-----------------+
|
||||
|
||||
Si ``true``, el stream se repite automáticamente cuando llega al final.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamOGGVorbis_property_loop_offset:
|
||||
|
||||
- :ref:`float<class_float>` **loop_offset**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_loop_offset(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_loop_offset() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Tiempo en segundos en el que el stream comienza después de ser enlazada.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,30 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamPlayback.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamPlayback:
|
||||
|
||||
AudioStreamPlayback
|
||||
===================
|
||||
|
||||
**Inherits:** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`AudioStreamPlaybackResampled<class_AudioStreamPlaybackResampled>`
|
||||
|
||||
Meta clase para reproducir el audio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Puede reproducir, hacer un bucle, pausar un desplazamiento a través del audio. Ver :ref:`AudioStream<class_AudioStream>` y :ref:`AudioStreamOGGVorbis<class_AudioStreamOGGVorbis>` para su uso.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- `Audio Generator Demo <https://godotengine.org/asset-library/asset/526>`__
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,20 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamPlaybackResampled.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamPlaybackResampled:
|
||||
|
||||
AudioStreamPlaybackResampled
|
||||
============================
|
||||
|
||||
**Inherits:** :ref:`AudioStreamPlayback<class_AudioStreamPlayback>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`AudioStreamGeneratorPlayback<class_AudioStreamGeneratorPlayback>`
|
||||
|
||||
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,270 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamPlayer.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamPlayer:
|
||||
|
||||
AudioStreamPlayer
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Reproduce el audio sin posición.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Plays an audio stream non-positionally.
|
||||
|
||||
To play audio positionally, use :ref:`AudioStreamPlayer2D<class_AudioStreamPlayer2D>` or :ref:`AudioStreamPlayer3D<class_AudioStreamPlayer3D>` instead of ``AudioStreamPlayer``.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Audio streams <../tutorials/audio/audio_streams>`
|
||||
|
||||
- `2D Dodge The Creeps Demo <https://godotengine.org/asset-library/asset/515>`__
|
||||
|
||||
- `Audio Device Changer Demo <https://godotengine.org/asset-library/asset/525>`__
|
||||
|
||||
- `Audio Generator Demo <https://godotengine.org/asset-library/asset/526>`__
|
||||
|
||||
- `Audio Mic Record Demo <https://godotengine.org/asset-library/asset/527>`__
|
||||
|
||||
- `Audio Spectrum Demo <https://godotengine.org/asset-library/asset/528>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+----------------------------------------------------+----------------------------------------------------------------------+--------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`autoplay<class_AudioStreamPlayer_property_autoplay>` | ``false`` |
|
||||
+----------------------------------------------------+----------------------------------------------------------------------+--------------+
|
||||
| :ref:`String<class_String>` | :ref:`bus<class_AudioStreamPlayer_property_bus>` | ``"Master"`` |
|
||||
+----------------------------------------------------+----------------------------------------------------------------------+--------------+
|
||||
| :ref:`MixTarget<enum_AudioStreamPlayer_MixTarget>` | :ref:`mix_target<class_AudioStreamPlayer_property_mix_target>` | ``0`` |
|
||||
+----------------------------------------------------+----------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`pitch_scale<class_AudioStreamPlayer_property_pitch_scale>` | ``1.0`` |
|
||||
+----------------------------------------------------+----------------------------------------------------------------------+--------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`playing<class_AudioStreamPlayer_property_playing>` | ``false`` |
|
||||
+----------------------------------------------------+----------------------------------------------------------------------+--------------+
|
||||
| :ref:`AudioStream<class_AudioStream>` | :ref:`stream<class_AudioStreamPlayer_property_stream>` | |
|
||||
+----------------------------------------------------+----------------------------------------------------------------------+--------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`stream_paused<class_AudioStreamPlayer_property_stream_paused>` | ``false`` |
|
||||
+----------------------------------------------------+----------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`volume_db<class_AudioStreamPlayer_property_volume_db>` | ``0.0`` |
|
||||
+----------------------------------------------------+----------------------------------------------------------------------+--------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------------------------------+----------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_playback_position<class_AudioStreamPlayer_method_get_playback_position>` **(** **)** |
|
||||
+-------------------------------------------------------+----------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AudioStreamPlayback<class_AudioStreamPlayback>` | :ref:`get_stream_playback<class_AudioStreamPlayer_method_get_stream_playback>` **(** **)** |
|
||||
+-------------------------------------------------------+----------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`play<class_AudioStreamPlayer_method_play>` **(** :ref:`float<class_float>` from_position=0.0 **)** |
|
||||
+-------------------------------------------------------+----------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`seek<class_AudioStreamPlayer_method_seek>` **(** :ref:`float<class_float>` to_position **)** |
|
||||
+-------------------------------------------------------+----------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`stop<class_AudioStreamPlayer_method_stop>` **(** **)** |
|
||||
+-------------------------------------------------------+----------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_AudioStreamPlayer_signal_finished:
|
||||
|
||||
- **finished** **(** **)**
|
||||
|
||||
Emitido cuando el audio deja de reproducirse.
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AudioStreamPlayer_MixTarget:
|
||||
|
||||
.. _class_AudioStreamPlayer_constant_MIX_TARGET_STEREO:
|
||||
|
||||
.. _class_AudioStreamPlayer_constant_MIX_TARGET_SURROUND:
|
||||
|
||||
.. _class_AudioStreamPlayer_constant_MIX_TARGET_CENTER:
|
||||
|
||||
enum **MixTarget**:
|
||||
|
||||
- **MIX_TARGET_STEREO** = **0** --- El audio se reproducirá sólo en el primer canal.
|
||||
|
||||
- **MIX_TARGET_SURROUND** = **1** --- El audio se reproducirá en todos los canales de sonido envolvente.
|
||||
|
||||
- **MIX_TARGET_CENTER** = **2** --- El audio se reproducirá en el segundo canal, que suele ser el del centro.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamPlayer_property_autoplay:
|
||||
|
||||
- :ref:`bool<class_bool>` **autoplay**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_autoplay(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | is_autoplay_enabled() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Si ``true``, el audio se reproduce cuando se añade al árbol de la escena.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer_property_bus:
|
||||
|
||||
- :ref:`String<class_String>` **bus**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``"Master"`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_bus(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_bus() |
|
||||
+-----------+----------------+
|
||||
|
||||
El bus en el que se está reproduciendo este audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer_property_mix_target:
|
||||
|
||||
- :ref:`MixTarget<enum_AudioStreamPlayer_MixTarget>` **mix_target**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_mix_target(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_mix_target() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Si la configuración de audio tiene más de dos altavoces, esto establece los canales de destino. Ver las constantes de :ref:`MixTarget<enum_AudioStreamPlayer_MixTarget>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer_property_pitch_scale:
|
||||
|
||||
- :ref:`float<class_float>` **pitch_scale**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_pitch_scale(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_pitch_scale() |
|
||||
+-----------+------------------------+
|
||||
|
||||
El tono y el tempo del audio, como multiplicador de la tasa de muestreo de la muestra de audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer_property_playing:
|
||||
|
||||
- :ref:`bool<class_bool>` **playing**
|
||||
|
||||
+-----------+--------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+--------------+
|
||||
| *Getter* | is_playing() |
|
||||
+-----------+--------------+
|
||||
|
||||
Si ``true``, el audio se está reproduciendo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer_property_stream:
|
||||
|
||||
- :ref:`AudioStream<class_AudioStream>` **stream**
|
||||
|
||||
+----------+-------------------+
|
||||
| *Setter* | set_stream(value) |
|
||||
+----------+-------------------+
|
||||
| *Getter* | get_stream() |
|
||||
+----------+-------------------+
|
||||
|
||||
El objeto :ref:`AudioStream<class_AudioStream>` que se va a reproducir.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer_property_stream_paused:
|
||||
|
||||
- :ref:`bool<class_bool>` **stream_paused**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_stream_paused(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_stream_paused() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
Si ``true``, la reproducción se interrumpe. Puede reanudarla ajustando ``stream_paused`` a ``false``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer_property_volume_db:
|
||||
|
||||
- :ref:`float<class_float>` **volume_db**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_volume_db(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_volume_db() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Volumen del sonido, en dB.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamPlayer_method_get_playback_position:
|
||||
|
||||
- :ref:`float<class_float>` **get_playback_position** **(** **)**
|
||||
|
||||
Devuelve la posición en el :ref:`AudioStream<class_AudioStream>` en segundos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer_method_get_stream_playback:
|
||||
|
||||
- :ref:`AudioStreamPlayback<class_AudioStreamPlayback>` **get_stream_playback** **(** **)**
|
||||
|
||||
Devuelve el objeto :ref:`AudioStreamPlayback<class_AudioStreamPlayback>` asociado a este ``AudioStreamPlayer``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer_method_play:
|
||||
|
||||
- void **play** **(** :ref:`float<class_float>` from_position=0.0 **)**
|
||||
|
||||
Reproduce el audio del ``from_position`` dado, en segundos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer_method_seek:
|
||||
|
||||
- void **seek** **(** :ref:`float<class_float>` to_position **)**
|
||||
|
||||
Establece la posición desde la que se reproducirá el audio, en segundos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer_method_stop:
|
||||
|
||||
- void **stop** **(** **)**
|
||||
|
||||
Detiene el audio.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,279 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamPlayer2D.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamPlayer2D:
|
||||
|
||||
AudioStreamPlayer2D
|
||||
===================
|
||||
|
||||
**Inherits:** :ref:`Node2D<class_Node2D>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Plays positional sound in 2D space.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Plays audio that dampens with distance from screen center.
|
||||
|
||||
See also :ref:`AudioStreamPlayer<class_AudioStreamPlayer>` to play a sound non-positionally.
|
||||
|
||||
\ **Note:** Hiding an ``AudioStreamPlayer2D`` node does not disable its audio output. To temporarily disable an ``AudioStreamPlayer2D``'s audio output, set :ref:`volume_db<class_AudioStreamPlayer2D_property_volume_db>` to a very low value like ``-100`` (which isn't audible to human hearing).
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/audio/audio_streams`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------------------+------------------------------------------------------------------------+--------------+
|
||||
| :ref:`int<class_int>` | :ref:`area_mask<class_AudioStreamPlayer2D_property_area_mask>` | ``1`` |
|
||||
+---------------------------------------+------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`attenuation<class_AudioStreamPlayer2D_property_attenuation>` | ``1.0`` |
|
||||
+---------------------------------------+------------------------------------------------------------------------+--------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`autoplay<class_AudioStreamPlayer2D_property_autoplay>` | ``false`` |
|
||||
+---------------------------------------+------------------------------------------------------------------------+--------------+
|
||||
| :ref:`String<class_String>` | :ref:`bus<class_AudioStreamPlayer2D_property_bus>` | ``"Master"`` |
|
||||
+---------------------------------------+------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`max_distance<class_AudioStreamPlayer2D_property_max_distance>` | ``2000.0`` |
|
||||
+---------------------------------------+------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`pitch_scale<class_AudioStreamPlayer2D_property_pitch_scale>` | ``1.0`` |
|
||||
+---------------------------------------+------------------------------------------------------------------------+--------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`playing<class_AudioStreamPlayer2D_property_playing>` | ``false`` |
|
||||
+---------------------------------------+------------------------------------------------------------------------+--------------+
|
||||
| :ref:`AudioStream<class_AudioStream>` | :ref:`stream<class_AudioStreamPlayer2D_property_stream>` | |
|
||||
+---------------------------------------+------------------------------------------------------------------------+--------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`stream_paused<class_AudioStreamPlayer2D_property_stream_paused>` | ``false`` |
|
||||
+---------------------------------------+------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`volume_db<class_AudioStreamPlayer2D_property_volume_db>` | ``0.0`` |
|
||||
+---------------------------------------+------------------------------------------------------------------------+--------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_playback_position<class_AudioStreamPlayer2D_method_get_playback_position>` **(** **)** |
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AudioStreamPlayback<class_AudioStreamPlayback>` | :ref:`get_stream_playback<class_AudioStreamPlayer2D_method_get_stream_playback>` **(** **)** |
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`play<class_AudioStreamPlayer2D_method_play>` **(** :ref:`float<class_float>` from_position=0.0 **)** |
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`seek<class_AudioStreamPlayer2D_method_seek>` **(** :ref:`float<class_float>` to_position **)** |
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`stop<class_AudioStreamPlayer2D_method_stop>` **(** **)** |
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_AudioStreamPlayer2D_signal_finished:
|
||||
|
||||
- **finished** **(** **)**
|
||||
|
||||
Emitido cuando el audio deja de reproducirse.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamPlayer2D_property_area_mask:
|
||||
|
||||
- :ref:`int<class_int>` **area_mask**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_area_mask(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_area_mask() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Áreas en las que se reproduce este sonido.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_property_attenuation:
|
||||
|
||||
- :ref:`float<class_float>` **attenuation**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_attenuation(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_attenuation() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Amortigua el audio a distancia con esto como exponente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_property_autoplay:
|
||||
|
||||
- :ref:`bool<class_bool>` **autoplay**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_autoplay(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | is_autoplay_enabled() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Si ``true``, el audio se reproduce cuando se añade al árbol de la escena.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_property_bus:
|
||||
|
||||
- :ref:`String<class_String>` **bus**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``"Master"`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_bus(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_bus() |
|
||||
+-----------+----------------+
|
||||
|
||||
El bus en el que se está reproduciendo este audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_property_max_distance:
|
||||
|
||||
- :ref:`float<class_float>` **max_distance**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``2000.0`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_max_distance(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_max_distance() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
Distancia máxima desde la que se puede oír el audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_property_pitch_scale:
|
||||
|
||||
- :ref:`float<class_float>` **pitch_scale**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_pitch_scale(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_pitch_scale() |
|
||||
+-----------+------------------------+
|
||||
|
||||
El tono y el tempo del audio, como multiplicador de la tasa de muestreo de la muestra de audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_property_playing:
|
||||
|
||||
- :ref:`bool<class_bool>` **playing**
|
||||
|
||||
+-----------+--------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+--------------+
|
||||
| *Getter* | is_playing() |
|
||||
+-----------+--------------+
|
||||
|
||||
Si ``true``, el audio se está reproduciendo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_property_stream:
|
||||
|
||||
- :ref:`AudioStream<class_AudioStream>` **stream**
|
||||
|
||||
+----------+-------------------+
|
||||
| *Setter* | set_stream(value) |
|
||||
+----------+-------------------+
|
||||
| *Getter* | get_stream() |
|
||||
+----------+-------------------+
|
||||
|
||||
El objeto :ref:`AudioStream<class_AudioStream>` que se va a reproducir.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_property_stream_paused:
|
||||
|
||||
- :ref:`bool<class_bool>` **stream_paused**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_stream_paused(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_stream_paused() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
Si ``true``, la reproducción se interrumpe. Puede reanudarla ajustando ``stream_paused`` a ``false``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_property_volume_db:
|
||||
|
||||
- :ref:`float<class_float>` **volume_db**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_volume_db(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_volume_db() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Volumen de la base sin amortiguar.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamPlayer2D_method_get_playback_position:
|
||||
|
||||
- :ref:`float<class_float>` **get_playback_position** **(** **)**
|
||||
|
||||
Devuelve la posición en el :ref:`AudioStream<class_AudioStream>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_method_get_stream_playback:
|
||||
|
||||
- :ref:`AudioStreamPlayback<class_AudioStreamPlayback>` **get_stream_playback** **(** **)**
|
||||
|
||||
Devuelve el objeto :ref:`AudioStreamPlayback<class_AudioStreamPlayback>` asociado a este ``AudioStreamPlayer2D``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_method_play:
|
||||
|
||||
- void **play** **(** :ref:`float<class_float>` from_position=0.0 **)**
|
||||
|
||||
Reproduce el audio desde la posición dada ``de_posición``, en segundos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_method_seek:
|
||||
|
||||
- void **seek** **(** :ref:`float<class_float>` to_position **)**
|
||||
|
||||
Establece la posición desde la que se reproducirá el audio, en segundos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer2D_method_stop:
|
||||
|
||||
- void **stop** **(** **)**
|
||||
|
||||
Detiene el audio.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,500 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamPlayer3D.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamPlayer3D:
|
||||
|
||||
AudioStreamPlayer3D
|
||||
===================
|
||||
|
||||
**Inherits:** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Plays positional sound in 3D space.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Plays a sound effect with directed sound effects, dampens with distance if needed, generates effect of hearable position in space. For greater realism, a low-pass filter is automatically applied to distant sounds. This can be disabled by setting :ref:`attenuation_filter_cutoff_hz<class_AudioStreamPlayer3D_property_attenuation_filter_cutoff_hz>` to ``20500``.
|
||||
|
||||
By default, audio is heard from the camera position. This can be changed by adding a :ref:`Listener<class_Listener>` node to the scene and enabling it by calling :ref:`Listener.make_current<class_Listener_method_make_current>` on it.
|
||||
|
||||
See also :ref:`AudioStreamPlayer<class_AudioStreamPlayer>` to play a sound non-positionally.
|
||||
|
||||
\ **Note:** Hiding an ``AudioStreamPlayer3D`` node does not disable its audio output. To temporarily disable an ``AudioStreamPlayer3D``'s audio output, set :ref:`unit_db<class_AudioStreamPlayer3D_property_unit_db>` to a very low value like ``-100`` (which isn't audible to human hearing).
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/audio/audio_streams`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`int<class_int>` | :ref:`area_mask<class_AudioStreamPlayer3D_property_area_mask>` | ``1`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`attenuation_filter_cutoff_hz<class_AudioStreamPlayer3D_property_attenuation_filter_cutoff_hz>` | ``5000.0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`attenuation_filter_db<class_AudioStreamPlayer3D_property_attenuation_filter_db>` | ``-24.0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`AttenuationModel<enum_AudioStreamPlayer3D_AttenuationModel>` | :ref:`attenuation_model<class_AudioStreamPlayer3D_property_attenuation_model>` | ``0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`autoplay<class_AudioStreamPlayer3D_property_autoplay>` | ``false`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`String<class_String>` | :ref:`bus<class_AudioStreamPlayer3D_property_bus>` | ``"Master"`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`DopplerTracking<enum_AudioStreamPlayer3D_DopplerTracking>` | :ref:`doppler_tracking<class_AudioStreamPlayer3D_property_doppler_tracking>` | ``0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`emission_angle_degrees<class_AudioStreamPlayer3D_property_emission_angle_degrees>` | ``45.0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`emission_angle_enabled<class_AudioStreamPlayer3D_property_emission_angle_enabled>` | ``false`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`emission_angle_filter_attenuation_db<class_AudioStreamPlayer3D_property_emission_angle_filter_attenuation_db>` | ``-12.0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`max_db<class_AudioStreamPlayer3D_property_max_db>` | ``3.0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`max_distance<class_AudioStreamPlayer3D_property_max_distance>` | ``0.0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`OutOfRangeMode<enum_AudioStreamPlayer3D_OutOfRangeMode>` | :ref:`out_of_range_mode<class_AudioStreamPlayer3D_property_out_of_range_mode>` | ``0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`pitch_scale<class_AudioStreamPlayer3D_property_pitch_scale>` | ``1.0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`playing<class_AudioStreamPlayer3D_property_playing>` | ``false`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`AudioStream<class_AudioStream>` | :ref:`stream<class_AudioStreamPlayer3D_property_stream>` | |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`stream_paused<class_AudioStreamPlayer3D_property_stream_paused>` | ``false`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`unit_db<class_AudioStreamPlayer3D_property_unit_db>` | ``0.0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
| :ref:`float<class_float>` | :ref:`unit_size<class_AudioStreamPlayer3D_property_unit_size>` | ``1.0`` |
|
||||
+--------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+--------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`get_playback_position<class_AudioStreamPlayer3D_method_get_playback_position>` **(** **)** |
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`AudioStreamPlayback<class_AudioStreamPlayback>` | :ref:`get_stream_playback<class_AudioStreamPlayer3D_method_get_stream_playback>` **(** **)** |
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`play<class_AudioStreamPlayer3D_method_play>` **(** :ref:`float<class_float>` from_position=0.0 **)** |
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`seek<class_AudioStreamPlayer3D_method_seek>` **(** :ref:`float<class_float>` to_position **)** |
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`stop<class_AudioStreamPlayer3D_method_stop>` **(** **)** |
|
||||
+-------------------------------------------------------+------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_AudioStreamPlayer3D_signal_finished:
|
||||
|
||||
- **finished** **(** **)**
|
||||
|
||||
Emitido cuando el audio deja de reproducirse.
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AudioStreamPlayer3D_AttenuationModel:
|
||||
|
||||
.. _class_AudioStreamPlayer3D_constant_ATTENUATION_INVERSE_DISTANCE:
|
||||
|
||||
.. _class_AudioStreamPlayer3D_constant_ATTENUATION_INVERSE_SQUARE_DISTANCE:
|
||||
|
||||
.. _class_AudioStreamPlayer3D_constant_ATTENUATION_LOGARITHMIC:
|
||||
|
||||
.. _class_AudioStreamPlayer3D_constant_ATTENUATION_DISABLED:
|
||||
|
||||
enum **AttenuationModel**:
|
||||
|
||||
- **ATTENUATION_INVERSE_DISTANCE** = **0** --- Amortiguación lineal de la sonido según la distancia.
|
||||
|
||||
- **ATTENUATION_INVERSE_SQUARE_DISTANCE** = **1** --- Amortiguación cuadrada del sonido según la distancia.
|
||||
|
||||
- **ATTENUATION_LOGARITHMIC** = **2** --- Amortiguación logarítmica del sonido según la distancia.
|
||||
|
||||
- **ATTENUATION_DISABLED** = **3** --- No dampening of loudness according to distance. The sound will still be heard positionally, unlike an :ref:`AudioStreamPlayer<class_AudioStreamPlayer>`. :ref:`ATTENUATION_DISABLED<class_AudioStreamPlayer3D_constant_ATTENUATION_DISABLED>` can be combined with a :ref:`max_distance<class_AudioStreamPlayer3D_property_max_distance>` value greater than ``0.0`` to achieve linear attenuation clamped to a sphere of a defined size.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_AudioStreamPlayer3D_OutOfRangeMode:
|
||||
|
||||
.. _class_AudioStreamPlayer3D_constant_OUT_OF_RANGE_MIX:
|
||||
|
||||
.. _class_AudioStreamPlayer3D_constant_OUT_OF_RANGE_PAUSE:
|
||||
|
||||
enum **OutOfRangeMode**:
|
||||
|
||||
- **OUT_OF_RANGE_MIX** = **0** --- Mix this audio in, even when it's out of range. This increases CPU usage, but keeps the sound playing at the correct position if the camera leaves and enters the ``AudioStreamPlayer3D``'s :ref:`max_distance<class_AudioStreamPlayer3D_property_max_distance>` radius.
|
||||
|
||||
- **OUT_OF_RANGE_PAUSE** = **1** --- Pause this audio when it gets out of range. This decreases CPU usage, but will cause the sound to restart if the camera leaves and enters the ``AudioStreamPlayer3D``'s :ref:`max_distance<class_AudioStreamPlayer3D_property_max_distance>` radius.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_AudioStreamPlayer3D_DopplerTracking:
|
||||
|
||||
.. _class_AudioStreamPlayer3D_constant_DOPPLER_TRACKING_DISABLED:
|
||||
|
||||
.. _class_AudioStreamPlayer3D_constant_DOPPLER_TRACKING_IDLE_STEP:
|
||||
|
||||
.. _class_AudioStreamPlayer3D_constant_DOPPLER_TRACKING_PHYSICS_STEP:
|
||||
|
||||
enum **DopplerTracking**:
|
||||
|
||||
- **DOPPLER_TRACKING_DISABLED** = **0** --- Desactiva el rastreo doppler.
|
||||
|
||||
- **DOPPLER_TRACKING_IDLE_STEP** = **1** --- Executes doppler tracking in idle step (every rendered frame).
|
||||
|
||||
- **DOPPLER_TRACKING_PHYSICS_STEP** = **2** --- Executes doppler tracking in physics step (every simulated physics frame).
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_area_mask:
|
||||
|
||||
- :ref:`int<class_int>` **area_mask**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_area_mask(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_area_mask() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Áreas en las que se reproduce este sonido.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_attenuation_filter_cutoff_hz:
|
||||
|
||||
- :ref:`float<class_float>` **attenuation_filter_cutoff_hz**
|
||||
|
||||
+-----------+-----------------------------------------+
|
||||
| *Default* | ``5000.0`` |
|
||||
+-----------+-----------------------------------------+
|
||||
| *Setter* | set_attenuation_filter_cutoff_hz(value) |
|
||||
+-----------+-----------------------------------------+
|
||||
| *Getter* | get_attenuation_filter_cutoff_hz() |
|
||||
+-----------+-----------------------------------------+
|
||||
|
||||
Dampens audio using a low-pass filter above this frequency, in Hz. To disable the dampening effect entirely, set this to ``20500`` as this frequency is above the human hearing limit.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_attenuation_filter_db:
|
||||
|
||||
- :ref:`float<class_float>` **attenuation_filter_db**
|
||||
|
||||
+-----------+----------------------------------+
|
||||
| *Default* | ``-24.0`` |
|
||||
+-----------+----------------------------------+
|
||||
| *Setter* | set_attenuation_filter_db(value) |
|
||||
+-----------+----------------------------------+
|
||||
| *Getter* | get_attenuation_filter_db() |
|
||||
+-----------+----------------------------------+
|
||||
|
||||
Amount how much the filter affects the loudness, in decibels.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_attenuation_model:
|
||||
|
||||
- :ref:`AttenuationModel<enum_AudioStreamPlayer3D_AttenuationModel>` **attenuation_model**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_attenuation_model(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_attenuation_model() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
Decide si el audio debe ser más silencioso con la distancia lineal, cuadrática, logarítmica, o no ser afectado por la distancia, desactivando efectivamente la atenuación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_autoplay:
|
||||
|
||||
- :ref:`bool<class_bool>` **autoplay**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_autoplay(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | is_autoplay_enabled() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
If ``true``, audio plays when the AudioStreamPlayer3D node is added to scene tree.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_bus:
|
||||
|
||||
- :ref:`String<class_String>` **bus**
|
||||
|
||||
+-----------+----------------+
|
||||
| *Default* | ``"Master"`` |
|
||||
+-----------+----------------+
|
||||
| *Setter* | set_bus(value) |
|
||||
+-----------+----------------+
|
||||
| *Getter* | get_bus() |
|
||||
+-----------+----------------+
|
||||
|
||||
The bus on which this audio is playing.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_doppler_tracking:
|
||||
|
||||
- :ref:`DopplerTracking<enum_AudioStreamPlayer3D_DopplerTracking>` **doppler_tracking**
|
||||
|
||||
+-----------+-----------------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+-----------------------------+
|
||||
| *Setter* | set_doppler_tracking(value) |
|
||||
+-----------+-----------------------------+
|
||||
| *Getter* | get_doppler_tracking() |
|
||||
+-----------+-----------------------------+
|
||||
|
||||
Decides in which step the `Doppler effect <https://en.wikipedia.org/wiki/Doppler_effect>`__ should be calculated.
|
||||
|
||||
\ **Note:** Only effective if the current :ref:`Camera<class_Camera>`'s :ref:`Camera.doppler_tracking<class_Camera_property_doppler_tracking>` property is set to a value other than :ref:`Camera.DOPPLER_TRACKING_DISABLED<class_Camera_constant_DOPPLER_TRACKING_DISABLED>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_emission_angle_degrees:
|
||||
|
||||
- :ref:`float<class_float>` **emission_angle_degrees**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``45.0`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_emission_angle(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_emission_angle() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
El ángulo en el que el audio llega a las cámaras sin amortiguar.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_emission_angle_enabled:
|
||||
|
||||
- :ref:`bool<class_bool>` **emission_angle_enabled**
|
||||
|
||||
+-----------+-----------------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-----------------------------------+
|
||||
| *Setter* | set_emission_angle_enabled(value) |
|
||||
+-----------+-----------------------------------+
|
||||
| *Getter* | is_emission_angle_enabled() |
|
||||
+-----------+-----------------------------------+
|
||||
|
||||
Si ``true``, el audio debe ser amortiguado de acuerdo a la dirección del sonido.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_emission_angle_filter_attenuation_db:
|
||||
|
||||
- :ref:`float<class_float>` **emission_angle_filter_attenuation_db**
|
||||
|
||||
+-----------+-------------------------------------------------+
|
||||
| *Default* | ``-12.0`` |
|
||||
+-----------+-------------------------------------------------+
|
||||
| *Setter* | set_emission_angle_filter_attenuation_db(value) |
|
||||
+-----------+-------------------------------------------------+
|
||||
| *Getter* | get_emission_angle_filter_attenuation_db() |
|
||||
+-----------+-------------------------------------------------+
|
||||
|
||||
Dampens audio if camera is outside of :ref:`emission_angle_degrees<class_AudioStreamPlayer3D_property_emission_angle_degrees>` and :ref:`emission_angle_enabled<class_AudioStreamPlayer3D_property_emission_angle_enabled>` is set by this factor, in decibels.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_max_db:
|
||||
|
||||
- :ref:`float<class_float>` **max_db**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``3.0`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_max_db(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_max_db() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Sets the absolute maximum of the soundlevel, in decibels.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_max_distance:
|
||||
|
||||
- :ref:`float<class_float>` **max_distance**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_max_distance(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_max_distance() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
Establece la distancia a partir de la cual el :ref:`out_of_range_mode<class_AudioStreamPlayer3D_property_out_of_range_mode>` tiene efecto. No tiene efecto si se pone a 0.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_out_of_range_mode:
|
||||
|
||||
- :ref:`OutOfRangeMode<enum_AudioStreamPlayer3D_OutOfRangeMode>` **out_of_range_mode**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_out_of_range_mode(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_out_of_range_mode() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
Decide si el audio debe hacer una pausa cuando la fuente está fuera del rango de :ref:`max_distance<class_AudioStreamPlayer3D_property_max_distance>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_pitch_scale:
|
||||
|
||||
- :ref:`float<class_float>` **pitch_scale**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_pitch_scale(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_pitch_scale() |
|
||||
+-----------+------------------------+
|
||||
|
||||
El tono y el tempo del audio, como multiplicador de la tasa de muestreo de la muestra de audio.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_playing:
|
||||
|
||||
- :ref:`bool<class_bool>` **playing**
|
||||
|
||||
+-----------+--------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+--------------+
|
||||
| *Getter* | is_playing() |
|
||||
+-----------+--------------+
|
||||
|
||||
Si ``true``, el audio se está reproduciendo.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_stream:
|
||||
|
||||
- :ref:`AudioStream<class_AudioStream>` **stream**
|
||||
|
||||
+----------+-------------------+
|
||||
| *Setter* | set_stream(value) |
|
||||
+----------+-------------------+
|
||||
| *Getter* | get_stream() |
|
||||
+----------+-------------------+
|
||||
|
||||
The :ref:`AudioStream<class_AudioStream>` resource to be played.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_stream_paused:
|
||||
|
||||
- :ref:`bool<class_bool>` **stream_paused**
|
||||
|
||||
+-----------+--------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+--------------------------+
|
||||
| *Setter* | set_stream_paused(value) |
|
||||
+-----------+--------------------------+
|
||||
| *Getter* | get_stream_paused() |
|
||||
+-----------+--------------------------+
|
||||
|
||||
If ``true``, the playback is paused. You can resume it by setting :ref:`stream_paused<class_AudioStreamPlayer3D_property_stream_paused>` to ``false``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_unit_db:
|
||||
|
||||
- :ref:`float<class_float>` **unit_db**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_unit_db(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | get_unit_db() |
|
||||
+-----------+--------------------+
|
||||
|
||||
The base sound level unaffected by dampening, in decibels.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_property_unit_size:
|
||||
|
||||
- :ref:`float<class_float>` **unit_size**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_unit_size(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_unit_size() |
|
||||
+-----------+----------------------+
|
||||
|
||||
The factor for the attenuation effect. Higher values make the sound audible over a larger distance.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamPlayer3D_method_get_playback_position:
|
||||
|
||||
- :ref:`float<class_float>` **get_playback_position** **(** **)**
|
||||
|
||||
Devuelve la posición en el :ref:`AudioStream<class_AudioStream>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_method_get_stream_playback:
|
||||
|
||||
- :ref:`AudioStreamPlayback<class_AudioStreamPlayback>` **get_stream_playback** **(** **)**
|
||||
|
||||
Devuelve el objeto :ref:`AudioStreamPlayback<class_AudioStreamPlayback>` asociado a este ``AudioStreamPlayer3D``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_method_play:
|
||||
|
||||
- void **play** **(** :ref:`float<class_float>` from_position=0.0 **)**
|
||||
|
||||
Reproduce el audio desde la posición dada ``de_posición``, en segundos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_method_seek:
|
||||
|
||||
- void **seek** **(** :ref:`float<class_float>` to_position **)**
|
||||
|
||||
Establece la posición desde la que se reproducirá el audio, en segundos.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamPlayer3D_method_stop:
|
||||
|
||||
- void **stop** **(** **)**
|
||||
|
||||
Detiene el audio.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,63 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamRandomPitch.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamRandomPitch:
|
||||
|
||||
AudioStreamRandomPitch
|
||||
======================
|
||||
|
||||
**Inherits:** :ref:`AudioStream<class_AudioStream>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Reproduce el audio con un cambio de tono aleatorio.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Varía aleatoriamente el tono en cada inicio.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------------------+-------------------------------------------------------------------------+---------+
|
||||
| :ref:`AudioStream<class_AudioStream>` | :ref:`audio_stream<class_AudioStreamRandomPitch_property_audio_stream>` | |
|
||||
+---------------------------------------+-------------------------------------------------------------------------+---------+
|
||||
| :ref:`float<class_float>` | :ref:`random_pitch<class_AudioStreamRandomPitch_property_random_pitch>` | ``1.1`` |
|
||||
+---------------------------------------+-------------------------------------------------------------------------+---------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamRandomPitch_property_audio_stream:
|
||||
|
||||
- :ref:`AudioStream<class_AudioStream>` **audio_stream**
|
||||
|
||||
+----------+-------------------------+
|
||||
| *Setter* | set_audio_stream(value) |
|
||||
+----------+-------------------------+
|
||||
| *Getter* | get_audio_stream() |
|
||||
+----------+-------------------------+
|
||||
|
||||
El actual :ref:`AudioStream<class_AudioStream>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamRandomPitch_property_random_pitch:
|
||||
|
||||
- :ref:`float<class_float>` **random_pitch**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``1.1`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_random_pitch(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_random_pitch() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
La intensidad de la variación del tono aleatorio.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,222 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the AudioStreamSample.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_AudioStreamSample:
|
||||
|
||||
AudioStreamSample
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`AudioStream<class_AudioStream>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Almacena datos de audio cargados desde archivos WAV.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
AudioStreamSample stores sound samples loaded from WAV files. To play the stored sound, use an :ref:`AudioStreamPlayer<class_AudioStreamPlayer>` (for non-positional audio) or :ref:`AudioStreamPlayer2D<class_AudioStreamPlayer2D>`/:ref:`AudioStreamPlayer3D<class_AudioStreamPlayer3D>` (for positional audio). The sound can be looped.
|
||||
|
||||
This class can also be used to store dynamically-generated PCM audio data. See also :ref:`AudioStreamGenerator<class_AudioStreamGenerator>` for procedural audio generation.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+--------------------------------------------------+----------------------------------------------------------------+-----------------------+
|
||||
| :ref:`PoolByteArray<class_PoolByteArray>` | :ref:`data<class_AudioStreamSample_property_data>` | ``PoolByteArray( )`` |
|
||||
+--------------------------------------------------+----------------------------------------------------------------+-----------------------+
|
||||
| :ref:`Format<enum_AudioStreamSample_Format>` | :ref:`format<class_AudioStreamSample_property_format>` | ``0`` |
|
||||
+--------------------------------------------------+----------------------------------------------------------------+-----------------------+
|
||||
| :ref:`int<class_int>` | :ref:`loop_begin<class_AudioStreamSample_property_loop_begin>` | ``0`` |
|
||||
+--------------------------------------------------+----------------------------------------------------------------+-----------------------+
|
||||
| :ref:`int<class_int>` | :ref:`loop_end<class_AudioStreamSample_property_loop_end>` | ``0`` |
|
||||
+--------------------------------------------------+----------------------------------------------------------------+-----------------------+
|
||||
| :ref:`LoopMode<enum_AudioStreamSample_LoopMode>` | :ref:`loop_mode<class_AudioStreamSample_property_loop_mode>` | ``0`` |
|
||||
+--------------------------------------------------+----------------------------------------------------------------+-----------------------+
|
||||
| :ref:`int<class_int>` | :ref:`mix_rate<class_AudioStreamSample_property_mix_rate>` | ``44100`` |
|
||||
+--------------------------------------------------+----------------------------------------------------------------+-----------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`stereo<class_AudioStreamSample_property_stereo>` | ``false`` |
|
||||
+--------------------------------------------------+----------------------------------------------------------------+-----------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------------------+-------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Error<enum_@GlobalScope_Error>` | :ref:`save_to_wav<class_AudioStreamSample_method_save_to_wav>` **(** :ref:`String<class_String>` path **)** |
|
||||
+---------------------------------------+-------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_AudioStreamSample_Format:
|
||||
|
||||
.. _class_AudioStreamSample_constant_FORMAT_8_BITS:
|
||||
|
||||
.. _class_AudioStreamSample_constant_FORMAT_16_BITS:
|
||||
|
||||
.. _class_AudioStreamSample_constant_FORMAT_IMA_ADPCM:
|
||||
|
||||
enum **Format**:
|
||||
|
||||
- **FORMAT_8_BITS** = **0** --- Códec de audio de 8 bits.
|
||||
|
||||
- **FORMAT_16_BITS** = **1** --- Códec de audio de 16 bits.
|
||||
|
||||
- **FORMAT_IMA_ADPCM** = **2** --- El audio se comprime usando IMA ADPCM.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_AudioStreamSample_LoopMode:
|
||||
|
||||
.. _class_AudioStreamSample_constant_LOOP_DISABLED:
|
||||
|
||||
.. _class_AudioStreamSample_constant_LOOP_FORWARD:
|
||||
|
||||
.. _class_AudioStreamSample_constant_LOOP_PING_PONG:
|
||||
|
||||
.. _class_AudioStreamSample_constant_LOOP_BACKWARD:
|
||||
|
||||
enum **LoopMode**:
|
||||
|
||||
- **LOOP_DISABLED** = **0** --- El audio no se reproduce en bucle.
|
||||
|
||||
- **LOOP_FORWARD** = **1** --- El audio hace un bucle con los datos entre :ref:`loop_begin<class_AudioStreamSample_property_loop_begin>` y :ref:`loop_end<class_AudioStreamSample_property_loop_end>`, reproduciéndose sólo hacia adelante.
|
||||
|
||||
- **LOOP_PING_PONG** = **2** --- El audio hace un bucle con los datos entre :ref:`loop_begin<class_AudioStreamSample_property_loop_begin>` y :ref:`loop_end<class_AudioStreamSample_property_loop_end>`, reproduciéndose hacia adelante y hacia atrás.
|
||||
|
||||
- **LOOP_BACKWARD** = **3** --- El audio hace un bucle con los datos entre :ref:`loop_begin<class_AudioStreamSample_property_loop_begin>` y :ref:`loop_end<class_AudioStreamSample_property_loop_end>`, reproduciéndose sólo hacia atrás.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamSample_property_data:
|
||||
|
||||
- :ref:`PoolByteArray<class_PoolByteArray>` **data**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``PoolByteArray( )`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_data(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_data() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Contiene los datos de audio en bytes.
|
||||
|
||||
\ **Nota:** Esta propiedad espera datos firmados de PCM8. Para convertir PCM8 sin firmar en PCM8 firmado, reste 128 de cada byte.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamSample_property_format:
|
||||
|
||||
- :ref:`Format<enum_AudioStreamSample_Format>` **format**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_format(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_format() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Formato de audio. Véase las constantes :ref:`Format<enum_AudioStreamSample_Format>` para los valores.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamSample_property_loop_begin:
|
||||
|
||||
- :ref:`int<class_int>` **loop_begin**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_loop_begin(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_loop_begin() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
El punto de inicio del bucle (en número de muestras, en relación con el inicio de la muestra). Esta información se importará automáticamente desde el archivo WAV si está presente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamSample_property_loop_end:
|
||||
|
||||
- :ref:`int<class_int>` **loop_end**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_loop_end(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_loop_end() |
|
||||
+-----------+---------------------+
|
||||
|
||||
El punto final del bucle (en número de muestras, relativo al comienzo de la muestra). Esta información se importará automáticamente desde el archivo WAV si está presente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamSample_property_loop_mode:
|
||||
|
||||
- :ref:`LoopMode<enum_AudioStreamSample_LoopMode>` **loop_mode**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_loop_mode(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_loop_mode() |
|
||||
+-----------+----------------------+
|
||||
|
||||
El modo de bucle. Esta información se importará automáticamente desde el archivo WAV si está presente. Ver las constantes :ref:`LoopMode<enum_AudioStreamSample_LoopMode>` para los valores.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamSample_property_mix_rate:
|
||||
|
||||
- :ref:`int<class_int>` **mix_rate**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``44100`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_mix_rate(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | get_mix_rate() |
|
||||
+-----------+---------------------+
|
||||
|
||||
The sample rate for mixing this audio. Higher values require more storage space, but result in better quality.
|
||||
|
||||
In games, common sample rates in use are ``11025``, ``16000``, ``22050``, ``32000``, ``44100``, and ``48000``.
|
||||
|
||||
According to the `Nyquist-Shannon sampling theorem <https://en.wikipedia.org/wiki/Nyquist%E2%80%93Shannon_sampling_theorem>`__, there is no quality difference to human hearing when going past 40,000 Hz (since most humans can only hear up to ~20,000 Hz, often less). If you are using lower-pitched sounds such as voices, lower sample rates such as ``32000`` or ``22050`` may be usable with no loss in quality.
|
||||
|
||||
----
|
||||
|
||||
.. _class_AudioStreamSample_property_stereo:
|
||||
|
||||
- :ref:`bool<class_bool>` **stereo**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_stereo(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | is_stereo() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Si ``true``, el audio es estéreo.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_AudioStreamSample_method_save_to_wav:
|
||||
|
||||
- :ref:`Error<enum_@GlobalScope_Error>` **save_to_wav** **(** :ref:`String<class_String>` path **)**
|
||||
|
||||
Guarda el AudioStreamSample como un archivo WAV en ``path``. Las muestras con formato IMA ADPCM no pueden ser guardadas.
|
||||
|
||||
\ **Nota:** Una extensión ``.wav`` se añade automáticamente a ``path`` si falta.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,86 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the BackBufferCopy.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_BackBufferCopy:
|
||||
|
||||
BackBufferCopy
|
||||
==============
|
||||
|
||||
**Inherits:** :ref:`Node2D<class_Node2D>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Copia una región de la pantalla (o toda la pantalla) a un búfer para que se pueda acceder a ella en sus shader scripts a través de la función ``texture(SCREEN_TEXTURE, ...)``.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Node for back-buffering the currently-displayed screen. The region defined in the BackBufferCopy node is buffered with the content of the screen it covers, or the entire screen according to the copy mode set. Use the ``texture(SCREEN_TEXTURE, ...)`` function in your shader scripts to access the buffer.
|
||||
|
||||
\ **Note:** Since this node inherits from :ref:`Node2D<class_Node2D>` (and not :ref:`Control<class_Control>`), anchors and margins won't apply to child :ref:`Control<class_Control>`-derived nodes. This can be problematic when resizing the window. To avoid this, add :ref:`Control<class_Control>`-derived nodes as *siblings* to the BackBufferCopy node instead of adding them as children.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------------------------+-----------------------------------------------------------+-----------------------------------+
|
||||
| :ref:`CopyMode<enum_BackBufferCopy_CopyMode>` | :ref:`copy_mode<class_BackBufferCopy_property_copy_mode>` | ``1`` |
|
||||
+-----------------------------------------------+-----------------------------------------------------------+-----------------------------------+
|
||||
| :ref:`Rect2<class_Rect2>` | :ref:`rect<class_BackBufferCopy_property_rect>` | ``Rect2( -100, -100, 200, 200 )`` |
|
||||
+-----------------------------------------------+-----------------------------------------------------------+-----------------------------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_BackBufferCopy_CopyMode:
|
||||
|
||||
.. _class_BackBufferCopy_constant_COPY_MODE_DISABLED:
|
||||
|
||||
.. _class_BackBufferCopy_constant_COPY_MODE_RECT:
|
||||
|
||||
.. _class_BackBufferCopy_constant_COPY_MODE_VIEWPORT:
|
||||
|
||||
enum **CopyMode**:
|
||||
|
||||
- **COPY_MODE_DISABLED** = **0** --- Deshabilita el modo de almacenamiento intermedio. Esto significa que el nodo BackBufferCopy utilizará directamente la parte de la pantalla que cubre.
|
||||
|
||||
- **COPY_MODE_RECT** = **1** --- BackBufferCopy almacena una región rectangular.
|
||||
|
||||
- **COPY_MODE_VIEWPORT** = **2** --- BackBufferCopy almacena toda la pantalla.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_BackBufferCopy_property_copy_mode:
|
||||
|
||||
- :ref:`CopyMode<enum_BackBufferCopy_CopyMode>` **copy_mode**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_copy_mode(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_copy_mode() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Modo de búfer. Ver las constantes de :ref:`CopyMode<enum_BackBufferCopy_CopyMode>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BackBufferCopy_property_rect:
|
||||
|
||||
- :ref:`Rect2<class_Rect2>` **rect**
|
||||
|
||||
+-----------+-----------------------------------+
|
||||
| *Default* | ``Rect2( -100, -100, 200, 200 )`` |
|
||||
+-----------+-----------------------------------+
|
||||
| *Setter* | set_rect(value) |
|
||||
+-----------+-----------------------------------+
|
||||
| *Getter* | get_rect() |
|
||||
+-----------+-----------------------------------+
|
||||
|
||||
El área cubierta por el BackBufferCopy. Sólo se usa si :ref:`copy_mode<class_BackBufferCopy_property_copy_mode>` es :ref:`COPY_MODE_RECT<class_BackBufferCopy_constant_COPY_MODE_RECT>`.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,547 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the BakedLightmap.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_BakedLightmap:
|
||||
|
||||
BakedLightmap
|
||||
=============
|
||||
|
||||
**Inherits:** :ref:`VisualInstance<class_VisualInstance>` **<** :ref:`CullInstance<class_CullInstance>` **<** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Prerendered indirect light map for a scene.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Baked lightmaps are an alternative workflow for adding indirect (or baked) lighting to a scene. Unlike the :ref:`GIProbe<class_GIProbe>` approach, baked lightmaps work fine on low-end PCs and mobile devices as they consume almost no resources in run-time.
|
||||
|
||||
\ **Procedural generation:** Lightmap baking functionality is only available in the editor. This means ``BakedLightmap`` is not suited to procedurally generated or user-built levels. For procedurally generated or user-built levels, use :ref:`GIProbe<class_GIProbe>` instead.
|
||||
|
||||
\ **Note:** Due to how lightmaps work, most properties only have a visible effect once lightmaps are baked again.
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`../tutorials/3d/baked_lightmaps`
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`atlas_generate<class_BakedLightmap_property_atlas_generate>` | ``true`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`atlas_max_size<class_BakedLightmap_property_atlas_max_size>` | ``4096`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`bias<class_BakedLightmap_property_bias>` | ``0.005`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`bounce_indirect_energy<class_BakedLightmap_property_bounce_indirect_energy>` | ``1.0`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`bounces<class_BakedLightmap_property_bounces>` | ``3`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`capture_cell_size<class_BakedLightmap_property_capture_cell_size>` | ``0.5`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`capture_enabled<class_BakedLightmap_property_capture_enabled>` | ``true`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`capture_propagation<class_BakedLightmap_property_capture_propagation>` | ``1.0`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`BakeQuality<enum_BakedLightmap_BakeQuality>` | :ref:`capture_quality<class_BakedLightmap_property_capture_quality>` | ``1`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`default_texels_per_unit<class_BakedLightmap_property_default_texels_per_unit>` | ``16.0`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`Color<class_Color>` | :ref:`environment_custom_color<class_BakedLightmap_property_environment_custom_color>` | |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`environment_custom_energy<class_BakedLightmap_property_environment_custom_energy>` | |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`Sky<class_Sky>` | :ref:`environment_custom_sky<class_BakedLightmap_property_environment_custom_sky>` | |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`environment_custom_sky_rotation_degrees<class_BakedLightmap_property_environment_custom_sky_rotation_degrees>` | |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`Color<class_Color>` | :ref:`environment_min_light<class_BakedLightmap_property_environment_min_light>` | ``Color( 0, 0, 0, 1 )`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`EnvironmentMode<enum_BakedLightmap_EnvironmentMode>` | :ref:`environment_mode<class_BakedLightmap_property_environment_mode>` | ``0`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`extents<class_BakedLightmap_property_extents>` | ``Vector3( 10, 10, 10 )`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`String<class_String>` | :ref:`image_path<class_BakedLightmap_property_image_path>` | |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`BakedLightmapData<class_BakedLightmapData>` | :ref:`light_data<class_BakedLightmap_property_light_data>` | |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`BakeQuality<enum_BakedLightmap_BakeQuality>` | :ref:`quality<class_BakedLightmap_property_quality>` | ``1`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`use_color<class_BakedLightmap_property_use_color>` | ``true`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`use_denoiser<class_BakedLightmap_property_use_denoiser>` | ``true`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`use_hdr<class_BakedLightmap_property_use_hdr>` | ``true`` |
|
||||
+------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------+---------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`BakeError<enum_BakedLightmap_BakeError>` | :ref:`bake<class_BakedLightmap_method_bake>` **(** :ref:`Node<class_Node>` from_node=null, :ref:`String<class_String>` data_save_path="" **)** |
|
||||
+------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_BakedLightmap_BakeQuality:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_QUALITY_LOW:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_QUALITY_MEDIUM:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_QUALITY_HIGH:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_QUALITY_ULTRA:
|
||||
|
||||
enum **BakeQuality**:
|
||||
|
||||
- **BAKE_QUALITY_LOW** = **0** --- The lowest bake quality mode. Fastest to calculate.
|
||||
|
||||
- **BAKE_QUALITY_MEDIUM** = **1** --- The default bake quality mode.
|
||||
|
||||
- **BAKE_QUALITY_HIGH** = **2** --- A higher bake quality mode. Takes longer to calculate.
|
||||
|
||||
- **BAKE_QUALITY_ULTRA** = **3** --- The highest bake quality mode. Takes the longest to calculate.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_BakedLightmap_BakeError:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_ERROR_OK:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_ERROR_NO_SAVE_PATH:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_ERROR_NO_MESHES:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_ERROR_CANT_CREATE_IMAGE:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_ERROR_LIGHTMAP_SIZE:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_ERROR_INVALID_MESH:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_ERROR_USER_ABORTED:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_ERROR_NO_LIGHTMAPPER:
|
||||
|
||||
.. _class_BakedLightmap_constant_BAKE_ERROR_NO_ROOT:
|
||||
|
||||
enum **BakeError**:
|
||||
|
||||
- **BAKE_ERROR_OK** = **0** --- Baking was successful.
|
||||
|
||||
- **BAKE_ERROR_NO_SAVE_PATH** = **1** --- Returns if no viable save path is found. This can happen where an :ref:`image_path<class_BakedLightmap_property_image_path>` is not specified or when the save location is invalid.
|
||||
|
||||
- **BAKE_ERROR_NO_MESHES** = **2** --- Actualmente sin uso.
|
||||
|
||||
- **BAKE_ERROR_CANT_CREATE_IMAGE** = **3** --- Returns when the baker cannot save per-mesh textures to file.
|
||||
|
||||
- **BAKE_ERROR_LIGHTMAP_SIZE** = **4** --- The size of the generated lightmaps is too large.
|
||||
|
||||
- **BAKE_ERROR_INVALID_MESH** = **5** --- Some mesh contains UV2 values outside the ``[0,1]`` range.
|
||||
|
||||
- **BAKE_ERROR_USER_ABORTED** = **6** --- Returns if user cancels baking.
|
||||
|
||||
- **BAKE_ERROR_NO_LIGHTMAPPER** = **7** --- Returns if lightmapper can't be created. Unless you are using a custom lightmapper, please report this as bug.
|
||||
|
||||
- **BAKE_ERROR_NO_ROOT** = **8** --- There is no root node to start baking from. Either provide ``from_node`` argument or attach this node to a parent that should be used as root.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_BakedLightmap_EnvironmentMode:
|
||||
|
||||
.. _class_BakedLightmap_constant_ENVIRONMENT_MODE_DISABLED:
|
||||
|
||||
.. _class_BakedLightmap_constant_ENVIRONMENT_MODE_SCENE:
|
||||
|
||||
.. _class_BakedLightmap_constant_ENVIRONMENT_MODE_CUSTOM_SKY:
|
||||
|
||||
.. _class_BakedLightmap_constant_ENVIRONMENT_MODE_CUSTOM_COLOR:
|
||||
|
||||
enum **EnvironmentMode**:
|
||||
|
||||
- **ENVIRONMENT_MODE_DISABLED** = **0** --- No environment is used during baking.
|
||||
|
||||
- **ENVIRONMENT_MODE_SCENE** = **1** --- The baked environment is automatically picked from the current scene.
|
||||
|
||||
- **ENVIRONMENT_MODE_CUSTOM_SKY** = **2** --- A custom sky is used as environment during baking.
|
||||
|
||||
- **ENVIRONMENT_MODE_CUSTOM_COLOR** = **3** --- A custom solid color is used as environment during baking.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_BakedLightmap_property_atlas_generate:
|
||||
|
||||
- :ref:`bool<class_bool>` **atlas_generate**
|
||||
|
||||
+-----------+-----------------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+-----------------------------+
|
||||
| *Setter* | set_generate_atlas(value) |
|
||||
+-----------+-----------------------------+
|
||||
| *Getter* | is_generate_atlas_enabled() |
|
||||
+-----------+-----------------------------+
|
||||
|
||||
When enabled, the lightmapper will merge the textures for all meshes into a single large layered texture. Not supported in GLES2.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_atlas_max_size:
|
||||
|
||||
- :ref:`int<class_int>` **atlas_max_size**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``4096`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_max_atlas_size(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_max_atlas_size() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
Maximum size of each lightmap layer, only used when :ref:`atlas_generate<class_BakedLightmap_property_atlas_generate>` is enabled.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_bias:
|
||||
|
||||
- :ref:`float<class_float>` **bias**
|
||||
|
||||
+-----------+-----------------+
|
||||
| *Default* | ``0.005`` |
|
||||
+-----------+-----------------+
|
||||
| *Setter* | set_bias(value) |
|
||||
+-----------+-----------------+
|
||||
| *Getter* | get_bias() |
|
||||
+-----------+-----------------+
|
||||
|
||||
Raycasting bias used during baking to avoid floating point precision issues.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_bounce_indirect_energy:
|
||||
|
||||
- :ref:`float<class_float>` **bounce_indirect_energy**
|
||||
|
||||
+-----------+-----------------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+-----------------------------------+
|
||||
| *Setter* | set_bounce_indirect_energy(value) |
|
||||
+-----------+-----------------------------------+
|
||||
| *Getter* | get_bounce_indirect_energy() |
|
||||
+-----------+-----------------------------------+
|
||||
|
||||
The energy multiplier for each bounce. Higher values will make indirect lighting brighter. A value of ``1.0`` represents physically accurate behavior, but higher values can be used to make indirect lighting propagate more visibly when using a low number of bounces. This can be used to speed up bake times by lowering the number of :ref:`bounces<class_BakedLightmap_property_bounces>` then increasing :ref:`bounce_indirect_energy<class_BakedLightmap_property_bounce_indirect_energy>`. Unlike :ref:`BakedLightmapData.energy<class_BakedLightmapData_property_energy>`, this property does not affect direct lighting emitted by light nodes, emissive materials and the environment.
|
||||
|
||||
\ **Note:** :ref:`bounce_indirect_energy<class_BakedLightmap_property_bounce_indirect_energy>` only has an effect if :ref:`bounces<class_BakedLightmap_property_bounces>` is set to a value greater than or equal to ``1``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_bounces:
|
||||
|
||||
- :ref:`int<class_int>` **bounces**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``3`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_bounces(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | get_bounces() |
|
||||
+-----------+--------------------+
|
||||
|
||||
Number of light bounces that are taken into account during baking. See also :ref:`bounce_indirect_energy<class_BakedLightmap_property_bounce_indirect_energy>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_capture_cell_size:
|
||||
|
||||
- :ref:`float<class_float>` **capture_cell_size**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``0.5`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_capture_cell_size(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_capture_cell_size() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
Grid size used for real-time capture information on dynamic objects.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_capture_enabled:
|
||||
|
||||
- :ref:`bool<class_bool>` **capture_enabled**
|
||||
|
||||
+-----------+----------------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+----------------------------+
|
||||
| *Setter* | set_capture_enabled(value) |
|
||||
+-----------+----------------------------+
|
||||
| *Getter* | get_capture_enabled() |
|
||||
+-----------+----------------------------+
|
||||
|
||||
When enabled, an octree containing the scene's lighting information will be computed. This octree will then be used to light dynamic objects in the scene.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_capture_propagation:
|
||||
|
||||
- :ref:`float<class_float>` **capture_propagation**
|
||||
|
||||
+-----------+--------------------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+--------------------------------+
|
||||
| *Setter* | set_capture_propagation(value) |
|
||||
+-----------+--------------------------------+
|
||||
| *Getter* | get_capture_propagation() |
|
||||
+-----------+--------------------------------+
|
||||
|
||||
Bias value to reduce the amount of light proagation in the captured octree.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_capture_quality:
|
||||
|
||||
- :ref:`BakeQuality<enum_BakedLightmap_BakeQuality>` **capture_quality**
|
||||
|
||||
+-----------+----------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+----------------------------+
|
||||
| *Setter* | set_capture_quality(value) |
|
||||
+-----------+----------------------------+
|
||||
| *Getter* | get_capture_quality() |
|
||||
+-----------+----------------------------+
|
||||
|
||||
Bake quality of the capture data.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_default_texels_per_unit:
|
||||
|
||||
- :ref:`float<class_float>` **default_texels_per_unit**
|
||||
|
||||
+-----------+------------------------------------+
|
||||
| *Default* | ``16.0`` |
|
||||
+-----------+------------------------------------+
|
||||
| *Setter* | set_default_texels_per_unit(value) |
|
||||
+-----------+------------------------------------+
|
||||
| *Getter* | get_default_texels_per_unit() |
|
||||
+-----------+------------------------------------+
|
||||
|
||||
If a baked mesh doesn't have a UV2 size hint, this value will be used to roughly compute a suitable lightmap size.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_environment_custom_color:
|
||||
|
||||
- :ref:`Color<class_Color>` **environment_custom_color**
|
||||
|
||||
+----------+-------------------------------------+
|
||||
| *Setter* | set_environment_custom_color(value) |
|
||||
+----------+-------------------------------------+
|
||||
| *Getter* | get_environment_custom_color() |
|
||||
+----------+-------------------------------------+
|
||||
|
||||
The environment color when :ref:`environment_mode<class_BakedLightmap_property_environment_mode>` is set to :ref:`ENVIRONMENT_MODE_CUSTOM_COLOR<class_BakedLightmap_constant_ENVIRONMENT_MODE_CUSTOM_COLOR>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_environment_custom_energy:
|
||||
|
||||
- :ref:`float<class_float>` **environment_custom_energy**
|
||||
|
||||
+----------+--------------------------------------+
|
||||
| *Setter* | set_environment_custom_energy(value) |
|
||||
+----------+--------------------------------------+
|
||||
| *Getter* | get_environment_custom_energy() |
|
||||
+----------+--------------------------------------+
|
||||
|
||||
The energy scaling factor when when :ref:`environment_mode<class_BakedLightmap_property_environment_mode>` is set to :ref:`ENVIRONMENT_MODE_CUSTOM_COLOR<class_BakedLightmap_constant_ENVIRONMENT_MODE_CUSTOM_COLOR>` or :ref:`ENVIRONMENT_MODE_CUSTOM_SKY<class_BakedLightmap_constant_ENVIRONMENT_MODE_CUSTOM_SKY>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_environment_custom_sky:
|
||||
|
||||
- :ref:`Sky<class_Sky>` **environment_custom_sky**
|
||||
|
||||
+----------+-----------------------------------+
|
||||
| *Setter* | set_environment_custom_sky(value) |
|
||||
+----------+-----------------------------------+
|
||||
| *Getter* | get_environment_custom_sky() |
|
||||
+----------+-----------------------------------+
|
||||
|
||||
The :ref:`Sky<class_Sky>` resource to use when :ref:`environment_mode<class_BakedLightmap_property_environment_mode>` is set o :ref:`ENVIRONMENT_MODE_CUSTOM_SKY<class_BakedLightmap_constant_ENVIRONMENT_MODE_CUSTOM_SKY>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_environment_custom_sky_rotation_degrees:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **environment_custom_sky_rotation_degrees**
|
||||
|
||||
+----------+----------------------------------------------------+
|
||||
| *Setter* | set_environment_custom_sky_rotation_degrees(value) |
|
||||
+----------+----------------------------------------------------+
|
||||
| *Getter* | get_environment_custom_sky_rotation_degrees() |
|
||||
+----------+----------------------------------------------------+
|
||||
|
||||
The rotation of the baked custom sky.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_environment_min_light:
|
||||
|
||||
- :ref:`Color<class_Color>` **environment_min_light**
|
||||
|
||||
+-----------+----------------------------------+
|
||||
| *Default* | ``Color( 0, 0, 0, 1 )`` |
|
||||
+-----------+----------------------------------+
|
||||
| *Setter* | set_environment_min_light(value) |
|
||||
+-----------+----------------------------------+
|
||||
| *Getter* | get_environment_min_light() |
|
||||
+-----------+----------------------------------+
|
||||
|
||||
Minimum ambient light for all the lightmap texels. This doesn't take into account any occlusion from the scene's geometry, it simply ensures a minimum amount of light on all the lightmap texels. Can be used for artistic control on shadow color.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_environment_mode:
|
||||
|
||||
- :ref:`EnvironmentMode<enum_BakedLightmap_EnvironmentMode>` **environment_mode**
|
||||
|
||||
+-----------+-----------------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+-----------------------------+
|
||||
| *Setter* | set_environment_mode(value) |
|
||||
+-----------+-----------------------------+
|
||||
| *Getter* | get_environment_mode() |
|
||||
+-----------+-----------------------------+
|
||||
|
||||
Decides which environment to use during baking.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_extents:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **extents**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``Vector3( 10, 10, 10 )`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_extents(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_extents() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
Size of the baked lightmap. Only meshes inside this region will be included in the baked lightmap, also used as the bounds of the captured region for dynamic lighting.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_image_path:
|
||||
|
||||
- :ref:`String<class_String>` **image_path**
|
||||
|
||||
+----------+-----------------------+
|
||||
| *Setter* | set_image_path(value) |
|
||||
+----------+-----------------------+
|
||||
| *Getter* | get_image_path() |
|
||||
+----------+-----------------------+
|
||||
|
||||
Deprecated, in previous versions it determined the location where lightmaps were be saved.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_light_data:
|
||||
|
||||
- :ref:`BakedLightmapData<class_BakedLightmapData>` **light_data**
|
||||
|
||||
+----------+-----------------------+
|
||||
| *Setter* | set_light_data(value) |
|
||||
+----------+-----------------------+
|
||||
| *Getter* | get_light_data() |
|
||||
+----------+-----------------------+
|
||||
|
||||
The calculated light data.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_quality:
|
||||
|
||||
- :ref:`BakeQuality<enum_BakedLightmap_BakeQuality>` **quality**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_bake_quality(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | get_bake_quality() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
Determines the amount of samples per texel used in indrect light baking. The amount of samples for each quality level can be configured in the project settings.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_use_color:
|
||||
|
||||
- :ref:`bool<class_bool>` **use_color**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_use_color(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | is_using_color() |
|
||||
+-----------+----------------------+
|
||||
|
||||
Store full color values in the lightmap textures. When disabled, lightmap textures will store a single brightness channel. Can be disabled to reduce disk usage if the scene contains only white lights or you don't mind losing color information in indirect lighting.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_use_denoiser:
|
||||
|
||||
- :ref:`bool<class_bool>` **use_denoiser**
|
||||
|
||||
+-----------+-------------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+-------------------------+
|
||||
| *Setter* | set_use_denoiser(value) |
|
||||
+-----------+-------------------------+
|
||||
| *Getter* | is_using_denoiser() |
|
||||
+-----------+-------------------------+
|
||||
|
||||
When enabled, a lightmap denoiser will be used to reduce the noise inherent to Monte Carlo based global illumination.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmap_property_use_hdr:
|
||||
|
||||
- :ref:`bool<class_bool>` **use_hdr**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_use_hdr(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | is_using_hdr() |
|
||||
+-----------+--------------------+
|
||||
|
||||
If ``true``, stores the lightmap textures in a high dynamic range format (EXR). If ``false``, stores the lightmap texture in a low dynamic range PNG image. This can be set to ``false`` to reduce disk usage, but light values over 1.0 will be clamped and you may see banding caused by the reduced precision.
|
||||
|
||||
\ **Note:** Setting :ref:`use_hdr<class_BakedLightmap_property_use_hdr>` to ``true`` will decrease lightmap banding even when using the GLES2 backend or if :ref:`ProjectSettings.rendering/quality/depth/hdr<class_ProjectSettings_property_rendering/quality/depth/hdr>` is ``false``.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_BakedLightmap_method_bake:
|
||||
|
||||
- :ref:`BakeError<enum_BakedLightmap_BakeError>` **bake** **(** :ref:`Node<class_Node>` from_node=null, :ref:`String<class_String>` data_save_path="" **)**
|
||||
|
||||
Bakes the lightmap, scanning from the given ``from_node`` root and saves the resulting :ref:`BakedLightmapData<class_BakedLightmapData>` in ``data_save_path``. If no root node is provided, parent of this node will be used as root instead. If no save path is provided it will try to match the path from the current :ref:`light_data<class_BakedLightmap_property_light_data>`.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,180 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the BakedLightmapData.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_BakedLightmapData:
|
||||
|
||||
BakedLightmapData
|
||||
=================
|
||||
|
||||
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------------------------+------------------------------------------------------------------------------------+-----------------------------------------------------+
|
||||
| :ref:`AABB<class_AABB>` | :ref:`bounds<class_BakedLightmapData_property_bounds>` | ``AABB( 0, 0, 0, 0, 0, 0 )`` |
|
||||
+-------------------------------------------+------------------------------------------------------------------------------------+-----------------------------------------------------+
|
||||
| :ref:`Transform<class_Transform>` | :ref:`cell_space_transform<class_BakedLightmapData_property_cell_space_transform>` | ``Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )`` |
|
||||
+-------------------------------------------+------------------------------------------------------------------------------------+-----------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`cell_subdiv<class_BakedLightmapData_property_cell_subdiv>` | ``1`` |
|
||||
+-------------------------------------------+------------------------------------------------------------------------------------+-----------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`energy<class_BakedLightmapData_property_energy>` | ``1.0`` |
|
||||
+-------------------------------------------+------------------------------------------------------------------------------------+-----------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`interior<class_BakedLightmapData_property_interior>` | ``false`` |
|
||||
+-------------------------------------------+------------------------------------------------------------------------------------+-----------------------------------------------------+
|
||||
| :ref:`PoolByteArray<class_PoolByteArray>` | :ref:`octree<class_BakedLightmapData_property_octree>` | ``PoolByteArray( )`` |
|
||||
+-------------------------------------------+------------------------------------------------------------------------------------+-----------------------------------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_user<class_BakedLightmapData_method_add_user>` **(** :ref:`NodePath<class_NodePath>` path, :ref:`Resource<class_Resource>` lightmap, :ref:`int<class_int>` lightmap_slice, :ref:`Rect2<class_Rect2>` lightmap_uv_rect, :ref:`int<class_int>` instance **)** |
|
||||
+---------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear_data<class_BakedLightmapData_method_clear_data>` **(** **)** |
|
||||
+---------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear_users<class_BakedLightmapData_method_clear_users>` **(** **)** |
|
||||
+---------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_user_count<class_BakedLightmapData_method_get_user_count>` **(** **)** |const| |
|
||||
+---------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Resource<class_Resource>` | :ref:`get_user_lightmap<class_BakedLightmapData_method_get_user_lightmap>` **(** :ref:`int<class_int>` user_idx **)** |const| |
|
||||
+---------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`NodePath<class_NodePath>` | :ref:`get_user_path<class_BakedLightmapData_method_get_user_path>` **(** :ref:`int<class_int>` user_idx **)** |const| |
|
||||
+---------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_BakedLightmapData_property_bounds:
|
||||
|
||||
- :ref:`AABB<class_AABB>` **bounds**
|
||||
|
||||
+-----------+------------------------------+
|
||||
| *Default* | ``AABB( 0, 0, 0, 0, 0, 0 )`` |
|
||||
+-----------+------------------------------+
|
||||
| *Setter* | set_bounds(value) |
|
||||
+-----------+------------------------------+
|
||||
| *Getter* | get_bounds() |
|
||||
+-----------+------------------------------+
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmapData_property_cell_space_transform:
|
||||
|
||||
- :ref:`Transform<class_Transform>` **cell_space_transform**
|
||||
|
||||
+-----------+-----------------------------------------------------+
|
||||
| *Default* | ``Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )`` |
|
||||
+-----------+-----------------------------------------------------+
|
||||
| *Setter* | set_cell_space_transform(value) |
|
||||
+-----------+-----------------------------------------------------+
|
||||
| *Getter* | get_cell_space_transform() |
|
||||
+-----------+-----------------------------------------------------+
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmapData_property_cell_subdiv:
|
||||
|
||||
- :ref:`int<class_int>` **cell_subdiv**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_cell_subdiv(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_cell_subdiv() |
|
||||
+-----------+------------------------+
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmapData_property_energy:
|
||||
|
||||
- :ref:`float<class_float>` **energy**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_energy(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_energy() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Global energy multiplier for baked and dynamic capture objects. This can be changed at run-time without having to bake lightmaps again.
|
||||
|
||||
To adjust only the energy of indirect lighting (without affecting direct lighting or emissive materials), adjust :ref:`BakedLightmap.bounce_indirect_energy<class_BakedLightmap_property_bounce_indirect_energy>` and bake lightmaps again.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmapData_property_interior:
|
||||
|
||||
- :ref:`bool<class_bool>` **interior**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_interior(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | is_interior() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Controls whether dynamic capture objects receive environment lighting or not.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmapData_property_octree:
|
||||
|
||||
- :ref:`PoolByteArray<class_PoolByteArray>` **octree**
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``PoolByteArray( )`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_octree(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_octree() |
|
||||
+-----------+-----------------------+
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_BakedLightmapData_method_add_user:
|
||||
|
||||
- void **add_user** **(** :ref:`NodePath<class_NodePath>` path, :ref:`Resource<class_Resource>` lightmap, :ref:`int<class_int>` lightmap_slice, :ref:`Rect2<class_Rect2>` lightmap_uv_rect, :ref:`int<class_int>` instance **)**
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmapData_method_clear_data:
|
||||
|
||||
- void **clear_data** **(** **)**
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmapData_method_clear_users:
|
||||
|
||||
- void **clear_users** **(** **)**
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmapData_method_get_user_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_user_count** **(** **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmapData_method_get_user_lightmap:
|
||||
|
||||
- :ref:`Resource<class_Resource>` **get_user_lightmap** **(** :ref:`int<class_int>` user_idx **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_BakedLightmapData_method_get_user_path:
|
||||
|
||||
- :ref:`NodePath<class_NodePath>` **get_user_path** **(** :ref:`int<class_int>` user_idx **)** |const|
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,349 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the BaseButton.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_BaseButton:
|
||||
|
||||
BaseButton
|
||||
==========
|
||||
|
||||
**Inherits:** :ref:`Control<class_Control>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
**Inherited By:** :ref:`Button<class_Button>`, :ref:`LinkButton<class_LinkButton>`, :ref:`TextureButton<class_TextureButton>`
|
||||
|
||||
Clase base para diferentes tipos de botones.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
BaseButton es la clase base abstracta para los botones, por lo que no debe usarse directamente (no muestra nada). Otros tipos de botones heredan de ella.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
| :ref:`ActionMode<enum_BaseButton_ActionMode>` | :ref:`action_mode<class_BaseButton_property_action_mode>` | ``1`` |
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`button_mask<class_BaseButton_property_button_mask>` | ``1`` |
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`disabled<class_BaseButton_property_disabled>` | ``false`` |
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
| :ref:`FocusMode<enum_Control_FocusMode>` | :ref:`enabled_focus_mode<class_BaseButton_property_enabled_focus_mode>` | ``2`` |
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
| :ref:`FocusMode<enum_Control_FocusMode>` | focus_mode | ``2`` (overrides :ref:`Control<class_Control_property_focus_mode>`) |
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
| :ref:`ButtonGroup<class_ButtonGroup>` | :ref:`group<class_BaseButton_property_group>` | |
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`keep_pressed_outside<class_BaseButton_property_keep_pressed_outside>` | ``false`` |
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`pressed<class_BaseButton_property_pressed>` | ``false`` |
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
| :ref:`ShortCut<class_ShortCut>` | :ref:`shortcut<class_BaseButton_property_shortcut>` | |
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`shortcut_in_tooltip<class_BaseButton_property_shortcut_in_tooltip>` | ``true`` |
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`toggle_mode<class_BaseButton_property_toggle_mode>` | ``false`` |
|
||||
+-----------------------------------------------+-----------------------------------------------------------------------------+---------------------------------------------------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`_pressed<class_BaseButton_method__pressed>` **(** **)** |virtual| |
|
||||
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`_toggled<class_BaseButton_method__toggled>` **(** :ref:`bool<class_bool>` button_pressed **)** |virtual| |
|
||||
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`DrawMode<enum_BaseButton_DrawMode>` | :ref:`get_draw_mode<class_BaseButton_method_get_draw_mode>` **(** **)** |const| |
|
||||
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_hovered<class_BaseButton_method_is_hovered>` **(** **)** |const| |
|
||||
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_pressed_no_signal<class_BaseButton_method_set_pressed_no_signal>` **(** :ref:`bool<class_bool>` pressed **)** |
|
||||
+-------------------------------------------+-------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Señales
|
||||
--------------
|
||||
|
||||
.. _class_BaseButton_signal_button_down:
|
||||
|
||||
- **button_down** **(** **)**
|
||||
|
||||
Emitido cuando el botón comienza a ser presionado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_signal_button_up:
|
||||
|
||||
- **button_up** **(** **)**
|
||||
|
||||
Emitido cuando el botón deja de ser presionado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_signal_pressed:
|
||||
|
||||
- **pressed** **(** **)**
|
||||
|
||||
Se emite cuando el botón se conmuta o se presiona. Esto está en :ref:`button_down<class_BaseButton_signal_button_down>` si el :ref:`action_mode<class_BaseButton_property_action_mode>` es :ref:`ACTION_MODE_BUTTON_PRESS<class_BaseButton_constant_ACTION_MODE_BUTTON_PRESS>` y en :ref:`button_up<class_BaseButton_signal_button_up>` en caso contrario.
|
||||
|
||||
Si necesita saber el estado de pulsación del botón (y :ref:`toggle_mode<class_BaseButton_property_toggle_mode>` está activo), utilice :ref:`toggled<class_BaseButton_signal_toggled>` en su lugar.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_signal_toggled:
|
||||
|
||||
- **toggled** **(** :ref:`bool<class_bool>` button_pressed **)**
|
||||
|
||||
Emitido cuando el botón acaba de conmutar entre los estados de pulsado y normal (sólo si :ref:`toggle_mode<class_BaseButton_property_toggle_mode>` está activo). El nuevo estado está contenido en el argumento ``button_pressed``.
|
||||
|
||||
Enumeraciones
|
||||
--------------------------
|
||||
|
||||
.. _enum_BaseButton_DrawMode:
|
||||
|
||||
.. _class_BaseButton_constant_DRAW_NORMAL:
|
||||
|
||||
.. _class_BaseButton_constant_DRAW_PRESSED:
|
||||
|
||||
.. _class_BaseButton_constant_DRAW_HOVER:
|
||||
|
||||
.. _class_BaseButton_constant_DRAW_DISABLED:
|
||||
|
||||
.. _class_BaseButton_constant_DRAW_HOVER_PRESSED:
|
||||
|
||||
enum **DrawMode**:
|
||||
|
||||
- **DRAW_NORMAL** = **0** --- El estado normal (es decir, no presionado, no encima del botón, no activado y activado) de los botones.
|
||||
|
||||
- **DRAW_PRESSED** = **1** --- El estado de los botones se presiona.
|
||||
|
||||
- **DRAW_HOVER** = **2** --- El estado de los botones que tienen el cursor encima.
|
||||
|
||||
- **DRAW_DISABLED** = **3** --- El estado de los botones está desactivado.
|
||||
|
||||
- **DRAW_HOVER_PRESSED** = **4** --- El estado de los botones cuyo cursor esta encima y se presiona.
|
||||
|
||||
----
|
||||
|
||||
.. _enum_BaseButton_ActionMode:
|
||||
|
||||
.. _class_BaseButton_constant_ACTION_MODE_BUTTON_PRESS:
|
||||
|
||||
.. _class_BaseButton_constant_ACTION_MODE_BUTTON_RELEASE:
|
||||
|
||||
enum **ActionMode**:
|
||||
|
||||
- **ACTION_MODE_BUTTON_PRESS** = **0** --- Requiere sólo una pulsación para considerar el botón pulsado.
|
||||
|
||||
- **ACTION_MODE_BUTTON_RELEASE** = **1** --- Requiere de una pulsación y una posterior liberación antes de considerar el botón pulsado.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_BaseButton_property_action_mode:
|
||||
|
||||
- :ref:`ActionMode<enum_BaseButton_ActionMode>` **action_mode**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_action_mode(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_action_mode() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Determina cuándo se considera que se ha hecho clic en el botón, una de las constantes de :ref:`ActionMode<enum_BaseButton_ActionMode>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_property_button_mask:
|
||||
|
||||
- :ref:`int<class_int>` **button_mask**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``1`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_button_mask(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | get_button_mask() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Máscara binaria para elegir a qué botones del ratón este botón responderá .
|
||||
|
||||
Para permitir tanto el clic izquierdo como el derecho, use el ``BUTTON_MASK_LEFT | BUTTON_MASK_RIGHT``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_property_disabled:
|
||||
|
||||
- :ref:`bool<class_bool>` **disabled**
|
||||
|
||||
+-----------+---------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------+
|
||||
| *Setter* | set_disabled(value) |
|
||||
+-----------+---------------------+
|
||||
| *Getter* | is_disabled() |
|
||||
+-----------+---------------------+
|
||||
|
||||
Si ``true``, el botón está en estado de desactivación y no se puede hacer clic o alternar el estado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_property_enabled_focus_mode:
|
||||
|
||||
- :ref:`FocusMode<enum_Control_FocusMode>` **enabled_focus_mode**
|
||||
|
||||
+-----------+-------------------------------+
|
||||
| *Default* | ``2`` |
|
||||
+-----------+-------------------------------+
|
||||
| *Setter* | set_enabled_focus_mode(value) |
|
||||
+-----------+-------------------------------+
|
||||
| *Getter* | get_enabled_focus_mode() |
|
||||
+-----------+-------------------------------+
|
||||
|
||||
*Deprecated.* This property has been deprecated due to redundancy and will be removed in Godot 4.0. This property no longer has any effect when set. Please use :ref:`Control.focus_mode<class_Control_property_focus_mode>` instead.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_property_group:
|
||||
|
||||
- :ref:`ButtonGroup<class_ButtonGroup>` **group**
|
||||
|
||||
+----------+-------------------------+
|
||||
| *Setter* | set_button_group(value) |
|
||||
+----------+-------------------------+
|
||||
| *Getter* | get_button_group() |
|
||||
+----------+-------------------------+
|
||||
|
||||
:ref:`ButtonGroup<class_ButtonGroup>` asociado al botón.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_property_keep_pressed_outside:
|
||||
|
||||
- :ref:`bool<class_bool>` **keep_pressed_outside**
|
||||
|
||||
+-----------+---------------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+---------------------------------+
|
||||
| *Setter* | set_keep_pressed_outside(value) |
|
||||
+-----------+---------------------------------+
|
||||
| *Getter* | is_keep_pressed_outside() |
|
||||
+-----------+---------------------------------+
|
||||
|
||||
Si ``true``, el botón permanecee pulsado cuando el cursor se mueve fuera mientras se presiona.
|
||||
|
||||
\ **Nota:** Esta propiedad solo afecta la apariencia visual del botón. Se emitirán señales en el mismo momento sin tener en cuenta el valor de esta propiedad.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_property_pressed:
|
||||
|
||||
- :ref:`bool<class_bool>` **pressed**
|
||||
|
||||
+-----------+--------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+--------------------+
|
||||
| *Setter* | set_pressed(value) |
|
||||
+-----------+--------------------+
|
||||
| *Getter* | is_pressed() |
|
||||
+-----------+--------------------+
|
||||
|
||||
If ``true``, the button's state is pressed. Means the button is pressed down or toggled (if :ref:`toggle_mode<class_BaseButton_property_toggle_mode>` is active). Only works if :ref:`toggle_mode<class_BaseButton_property_toggle_mode>` is ``true``.
|
||||
|
||||
\ **Note:** Setting :ref:`pressed<class_BaseButton_property_pressed>` will result in :ref:`toggled<class_BaseButton_signal_toggled>` to be emitted. If you want to change the pressed state without emitting that signal, use :ref:`set_pressed_no_signal<class_BaseButton_method_set_pressed_no_signal>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_property_shortcut:
|
||||
|
||||
- :ref:`ShortCut<class_ShortCut>` **shortcut**
|
||||
|
||||
+----------+---------------------+
|
||||
| *Setter* | set_shortcut(value) |
|
||||
+----------+---------------------+
|
||||
| *Getter* | get_shortcut() |
|
||||
+----------+---------------------+
|
||||
|
||||
Atajo de teclado asociado al botón.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_property_shortcut_in_tooltip:
|
||||
|
||||
- :ref:`bool<class_bool>` **shortcut_in_tooltip**
|
||||
|
||||
+-----------+----------------------------------+
|
||||
| *Default* | ``true`` |
|
||||
+-----------+----------------------------------+
|
||||
| *Setter* | set_shortcut_in_tooltip(value) |
|
||||
+-----------+----------------------------------+
|
||||
| *Getter* | is_shortcut_in_tooltip_enabled() |
|
||||
+-----------+----------------------------------+
|
||||
|
||||
Si ``true``, el botón añadirá información sobre su atajo en el mensaje de ayuda.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_property_toggle_mode:
|
||||
|
||||
- :ref:`bool<class_bool>` **toggle_mode**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+------------------------+
|
||||
| *Setter* | set_toggle_mode(value) |
|
||||
+-----------+------------------------+
|
||||
| *Getter* | is_toggle_mode() |
|
||||
+-----------+------------------------+
|
||||
|
||||
Si ``true``, el botón está en modo de conmutación. Hace que el botón cambie de estado entre presionado y no presionado cada vez que se hace clic en su área.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_BaseButton_method__pressed:
|
||||
|
||||
- void **_pressed** **(** **)** |virtual|
|
||||
|
||||
Se llama cuando se presiona el botón. Si necesita saber el estado de pulsación del botón (y :ref:`toggle_mode<class_BaseButton_property_toggle_mode>` está activo), utilice en su lugar el :ref:`_toggled<class_BaseButton_method__toggled>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_method__toggled:
|
||||
|
||||
- void **_toggled** **(** :ref:`bool<class_bool>` button_pressed **)** |virtual|
|
||||
|
||||
Se llama cuando se cambia el estado del botón(Activado/Desactivado) (sólo si :ref:`toggle_mode<class_BaseButton_property_toggle_mode>` está activo).
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_method_get_draw_mode:
|
||||
|
||||
- :ref:`DrawMode<enum_BaseButton_DrawMode>` **get_draw_mode** **(** **)** |const|
|
||||
|
||||
Devuelve el estado visual utilizado para dibujar el botón. Esto es útil principalmente cuando implementas tu propio código de dibujo, ya sea anulando _draw() o conectando la señal de "dibujo". El estado visual del botón está definido por el enum :ref:`DrawMode<enum_BaseButton_DrawMode>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_method_is_hovered:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_hovered** **(** **)** |const|
|
||||
|
||||
Devuelve ``true`` si el ratón ha entrado en el botón y no lo ha dejado todavía.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BaseButton_method_set_pressed_no_signal:
|
||||
|
||||
- void **set_pressed_no_signal** **(** :ref:`bool<class_bool>` pressed **)**
|
||||
|
||||
Changes the :ref:`pressed<class_BaseButton_property_pressed>` state of the button, without emitting :ref:`toggled<class_BaseButton_signal_toggled>`. Use when you just want to change the state of the button without sending the pressed event (e.g. when initializing scene). Only works if :ref:`toggle_mode<class_BaseButton_property_toggle_mode>` is ``true``.
|
||||
|
||||
\ **Note:** This method doesn't unpress other buttons in its button :ref:`group<class_BaseButton_property_group>`.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,333 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the Basis.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_Basis:
|
||||
|
||||
Basis
|
||||
=====
|
||||
|
||||
Tipo de datos de matriz 3×3.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Matriz de 3×3 usada para la rotación y la escala 3D. Casi siempre se usa como base ortogonal para una Transformación.
|
||||
|
||||
Contiene 3 campos vectoriales X, Y y Z como sus columnas, que son típicamente interpretados como los vectores base locales de una transformación. Para tal uso, se compone de una matriz de escalamiento y rotación, en ese orden (M = R.S).
|
||||
|
||||
También se puede acceder a ella como matriz de vectores tridimensionales. Estos vectores son normalmente ortogonales entre sí, pero no están necesariamente normalizados (debido a la escala).
|
||||
|
||||
Para más información, lea el artículo de documentación "Matrices y transformaciones".
|
||||
|
||||
Tutoriales
|
||||
--------------------
|
||||
|
||||
- :doc:`Math tutorial index <../tutorials/math/index>`
|
||||
|
||||
- :doc:`Matrices and transforms <../tutorials/math/matrices_and_transforms>`
|
||||
|
||||
- :doc:`Using 3D transforms <../tutorials/3d/using_transforms>`
|
||||
|
||||
- `Matrix Transform Demo <https://godotengine.org/asset-library/asset/584>`__
|
||||
|
||||
- `3D Platformer Demo <https://godotengine.org/asset-library/asset/125>`__
|
||||
|
||||
- `3D Voxel Demo <https://godotengine.org/asset-library/asset/676>`__
|
||||
|
||||
- `2.5D Demo <https://godotengine.org/asset-library/asset/583>`__
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------------+----------------------------------+------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`x<class_Basis_property_x>` | ``Vector3( 1, 0, 0 )`` |
|
||||
+-------------------------------+----------------------------------+------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`y<class_Basis_property_y>` | ``Vector3( 0, 1, 0 )`` |
|
||||
+-------------------------------+----------------------------------+------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`z<class_Basis_property_z>` | ``Vector3( 0, 0, 1 )`` |
|
||||
+-------------------------------+----------------------------------+------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Basis<class_Basis>` | :ref:`Basis<class_Basis_method_Basis>` **(** :ref:`Quat<class_Quat>` from **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Basis<class_Basis>` | :ref:`Basis<class_Basis_method_Basis>` **(** :ref:`Vector3<class_Vector3>` from **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Basis<class_Basis>` | :ref:`Basis<class_Basis_method_Basis>` **(** :ref:`Vector3<class_Vector3>` axis, :ref:`float<class_float>` phi **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Basis<class_Basis>` | :ref:`Basis<class_Basis_method_Basis>` **(** :ref:`Vector3<class_Vector3>` x_axis, :ref:`Vector3<class_Vector3>` y_axis, :ref:`Vector3<class_Vector3>` z_axis **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`determinant<class_Basis_method_determinant>` **(** **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`get_euler<class_Basis_method_get_euler>` **(** **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_orthogonal_index<class_Basis_method_get_orthogonal_index>` **(** **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Quat<class_Quat>` | :ref:`get_rotation_quat<class_Basis_method_get_rotation_quat>` **(** **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`get_scale<class_Basis_method_get_scale>` **(** **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Basis<class_Basis>` | :ref:`inverse<class_Basis_method_inverse>` **(** **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`is_equal_approx<class_Basis_method_is_equal_approx>` **(** :ref:`Basis<class_Basis>` b, :ref:`float<class_float>` epsilon=1e-05 **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Basis<class_Basis>` | :ref:`orthonormalized<class_Basis_method_orthonormalized>` **(** **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Basis<class_Basis>` | :ref:`rotated<class_Basis_method_rotated>` **(** :ref:`Vector3<class_Vector3>` axis, :ref:`float<class_float>` phi **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Basis<class_Basis>` | :ref:`scaled<class_Basis_method_scaled>` **(** :ref:`Vector3<class_Vector3>` scale **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Basis<class_Basis>` | :ref:`slerp<class_Basis_method_slerp>` **(** :ref:`Basis<class_Basis>` to, :ref:`float<class_float>` weight **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`tdotx<class_Basis_method_tdotx>` **(** :ref:`Vector3<class_Vector3>` with **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`tdoty<class_Basis_method_tdoty>` **(** :ref:`Vector3<class_Vector3>` with **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`tdotz<class_Basis_method_tdotz>` **(** :ref:`Vector3<class_Vector3>` with **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Basis<class_Basis>` | :ref:`transposed<class_Basis_method_transposed>` **(** **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`xform<class_Basis_method_xform>` **(** :ref:`Vector3<class_Vector3>` v **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector3<class_Vector3>` | :ref:`xform_inv<class_Basis_method_xform_inv>` **(** :ref:`Vector3<class_Vector3>` v **)** |
|
||||
+-------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Constantes
|
||||
--------------------
|
||||
|
||||
.. _class_Basis_constant_IDENTITY:
|
||||
|
||||
.. _class_Basis_constant_FLIP_X:
|
||||
|
||||
.. _class_Basis_constant_FLIP_Y:
|
||||
|
||||
.. _class_Basis_constant_FLIP_Z:
|
||||
|
||||
- **IDENTITY** = **Basis( 1, 0, 0, 0, 1, 0, 0, 0, 1 )** --- La base de la identidad, sin rotación ni escalonamiento aplicado.
|
||||
|
||||
Esto es idéntico a llamar a ``Basis()`` sin ningún parámetro. Esta constante puede ser usada para hacer su código más claro, y para la consistencia con C#.
|
||||
|
||||
- **FLIP_X** = **Basis( -1, 0, 0, 0, 1, 0, 0, 0, 1 )** --- La base que volteará algo a lo largo del eje X cuando se use en una transformación.
|
||||
|
||||
- **FLIP_Y** = **Basis( 1, 0, 0, 0, -1, 0, 0, 0, 1 )** --- La base que volteará algo a lo largo del eje Y cuando se use en una transformación.
|
||||
|
||||
- **FLIP_Z** = **Basis( 1, 0, 0, 0, 1, 0, 0, 0, -1 )** --- La base que volteará algo a lo largo del eje Z cuando se use en una transformación.
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_Basis_property_x:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **x**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``Vector3( 1, 0, 0 )`` |
|
||||
+-----------+------------------------+
|
||||
|
||||
El vector X de la matriz base (columna 0). Equivalente al índice de la matriz ``0``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_property_y:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **y**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``Vector3( 0, 1, 0 )`` |
|
||||
+-----------+------------------------+
|
||||
|
||||
El vector Y de la matriz base (columna 1). Equivalente al índice de la matriz ``1``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_property_z:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **z**
|
||||
|
||||
+-----------+------------------------+
|
||||
| *Default* | ``Vector3( 0, 0, 1 )`` |
|
||||
+-----------+------------------------+
|
||||
|
||||
El vector Z de la matriz base (columna 2). Equivalente al índice de la matriz ``2``.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_Basis_method_Basis:
|
||||
|
||||
- :ref:`Basis<class_Basis>` **Basis** **(** :ref:`Quat<class_Quat>` from **)**
|
||||
|
||||
Construye una matriz de base de rotación pura a partir del cuaternario dado.
|
||||
|
||||
----
|
||||
|
||||
- :ref:`Basis<class_Basis>` **Basis** **(** :ref:`Vector3<class_Vector3>` from **)**
|
||||
|
||||
Construye una matriz de base de rotación pura a partir de los ángulos de Euler dados (en la convención YXZ: al \*componer\*, primero Y, luego X y Z en último lugar), dados en el formato vectorial como (ángulo X, ángulo Y, ángulo Z).
|
||||
|
||||
Considere el uso del constructor :ref:`Quat<class_Quat>` en su lugar, que utiliza un cuaternio en lugar de los ángulos de Euler.
|
||||
|
||||
----
|
||||
|
||||
- :ref:`Basis<class_Basis>` **Basis** **(** :ref:`Vector3<class_Vector3>` axis, :ref:`float<class_float>` phi **)**
|
||||
|
||||
Construye una matriz de base de rotación pura, rotada alrededor del ``axis`` dado por el ``phi``, en radianes. El eje debe ser un vector normalizado.
|
||||
|
||||
----
|
||||
|
||||
- :ref:`Basis<class_Basis>` **Basis** **(** :ref:`Vector3<class_Vector3>` x_axis, :ref:`Vector3<class_Vector3>` y_axis, :ref:`Vector3<class_Vector3>` z_axis **)**
|
||||
|
||||
Construye una matriz base a partir de vectores de 3 ejes (columnas de la matriz).
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_determinant:
|
||||
|
||||
- :ref:`float<class_float>` **determinant** **(** **)**
|
||||
|
||||
Devuelve el determinante de la matriz base. Si la base está uniformemente escalada, su determinante es el cuadrado de la escala.
|
||||
|
||||
Un determinante negativo significa que la base tiene una escala negativa. Un determinante cero significa que la base no es invertible, y normalmente se considera inválida.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_get_euler:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **get_euler** **(** **)**
|
||||
|
||||
Devuelve la rotación de la base en forma de ángulos de Euler (en la convención YXZ: al descomponerse, primero Z, luego X, y por último Y). El vector devuelto contiene los ángulos de rotación en el formato (ángulo X, ángulo Y, ángulo Z).
|
||||
|
||||
Considera usar el método :ref:`get_rotation_quat<class_Basis_method_get_rotation_quat>` en su lugar, que devuelve una cuaternión :ref:`Quat<class_Quat>` en lugar de ángulos Euler.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_get_orthogonal_index:
|
||||
|
||||
- :ref:`int<class_int>` **get_orthogonal_index** **(** **)**
|
||||
|
||||
Esta función considera una discretización de las rotaciones en 24 puntos de la unidad de la esfera, situados a lo largo de los vectores (x,y,z), siendo cada componente -1, 0, o 1, y devuelve el índice del punto que mejor representa la orientación del objeto. Es utilizado principalmente por el editor :ref:`GridMap<class_GridMap>`. Para más detalles, consulte el código fuente de Godot.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_get_rotation_quat:
|
||||
|
||||
- :ref:`Quat<class_Quat>` **get_rotation_quat** **(** **)**
|
||||
|
||||
Devuelve la rotación de la base en forma de cuaternario. Véase :ref:`get_euler<class_Basis_method_get_euler>` si necesita ángulos de Euler, pero tenga en cuenta que las cuaterniones generalmente deben ser preferidas a los ángulos de Euler.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_get_scale:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **get_scale** **(** **)**
|
||||
|
||||
Asumiendo que la matriz es la combinación de una rotación y un escalado, devuelve el valor absoluto de los factores de escala a lo largo de cada eje.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_inverse:
|
||||
|
||||
- :ref:`Basis<class_Basis>` **inverse** **(** **)**
|
||||
|
||||
Devuelve el inverso de la matriz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_is_equal_approx:
|
||||
|
||||
- :ref:`bool<class_bool>` **is_equal_approx** **(** :ref:`Basis<class_Basis>` b, :ref:`float<class_float>` epsilon=1e-05 **)**
|
||||
|
||||
Returns ``true`` if this basis and ``b`` are approximately equal, by calling ``is_equal_approx`` on each component.
|
||||
|
||||
\ **Note:** For complicated reasons, the epsilon argument is always discarded. Don't use the epsilon argument, it does nothing.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_orthonormalized:
|
||||
|
||||
- :ref:`Basis<class_Basis>` **orthonormalized** **(** **)**
|
||||
|
||||
Devuelve la versión ortonormalizada de la matriz (útil para llamar de vez en cuando para evitar el error de redondeo de las matrices ortogonales). Realiza una ortonormalización de Gram-Schmidt sobre la base de la matriz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_rotated:
|
||||
|
||||
- :ref:`Basis<class_Basis>` **rotated** **(** :ref:`Vector3<class_Vector3>` axis, :ref:`float<class_float>` phi **)**
|
||||
|
||||
Introducir una rotación adicional alrededor del eje dado por phi (radianes). El eje debe ser un vector normalizado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_scaled:
|
||||
|
||||
- :ref:`Basis<class_Basis>` **scaled** **(** :ref:`Vector3<class_Vector3>` scale **)**
|
||||
|
||||
Introducir una escalado adicional especificada por el factor de escala 3D dado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_slerp:
|
||||
|
||||
- :ref:`Basis<class_Basis>` **slerp** **(** :ref:`Basis<class_Basis>` to, :ref:`float<class_float>` weight **)**
|
||||
|
||||
Asumiendo que la matriz es una matriz de rotación adecuada, slerp realiza una interpolación esférica-lineal con otra matriz de rotación.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_tdotx:
|
||||
|
||||
- :ref:`float<class_float>` **tdotx** **(** :ref:`Vector3<class_Vector3>` with **)**
|
||||
|
||||
Producto vectorial transpuesto con el eje X de la matriz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_tdoty:
|
||||
|
||||
- :ref:`float<class_float>` **tdoty** **(** :ref:`Vector3<class_Vector3>` with **)**
|
||||
|
||||
Producto vectorial transpuesto con el eje Y de la matriz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_tdotz:
|
||||
|
||||
- :ref:`float<class_float>` **tdotz** **(** :ref:`Vector3<class_Vector3>` with **)**
|
||||
|
||||
Producto vectorial transpuesto con el eje Z de la matriz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_transposed:
|
||||
|
||||
- :ref:`Basis<class_Basis>` **transposed** **(** **)**
|
||||
|
||||
Devuelve la versión transpuesta de la matriz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_xform:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **xform** **(** :ref:`Vector3<class_Vector3>` v **)**
|
||||
|
||||
Devuelve un vector transformado (multiplicado) por la matriz.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Basis_method_xform_inv:
|
||||
|
||||
- :ref:`Vector3<class_Vector3>` **xform_inv** **(** :ref:`Vector3<class_Vector3>` v **)**
|
||||
|
||||
Devuelve un vector transformado (multiplicado) por la matriz base transpuesta.
|
||||
|
||||
\ **Nota:** Esto da como resultado una multiplicación por el inverso de la matriz sólo si representa una rotación-reflexión.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,117 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the BitMap.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_BitMap:
|
||||
|
||||
BitMap
|
||||
======
|
||||
|
||||
**Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Matriz booleana.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Una matriz bidimensional de valores booleanos, puede ser usada para almacenar eficientemente una matriz binaria (cada elemento de la matriz toma sólo un bit) y consultar los valores usando coordenadas cartesianas naturales.
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`create<class_BitMap_method_create>` **(** :ref:`Vector2<class_Vector2>` size **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`create_from_image_alpha<class_BitMap_method_create_from_image_alpha>` **(** :ref:`Image<class_Image>` image, :ref:`float<class_float>` threshold=0.1 **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`bool<class_bool>` | :ref:`get_bit<class_BitMap_method_get_bit>` **(** :ref:`Vector2<class_Vector2>` position **)** |const| |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`get_size<class_BitMap_method_get_size>` **(** **)** |const| |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_true_bit_count<class_BitMap_method_get_true_bit_count>` **(** **)** |const| |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`grow_mask<class_BitMap_method_grow_mask>` **(** :ref:`int<class_int>` pixels, :ref:`Rect2<class_Rect2>` rect **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Array<class_Array>` | :ref:`opaque_to_polygons<class_BitMap_method_opaque_to_polygons>` **(** :ref:`Rect2<class_Rect2>` rect, :ref:`float<class_float>` epsilon=2.0 **)** |const| |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bit<class_BitMap_method_set_bit>` **(** :ref:`Vector2<class_Vector2>` position, :ref:`bool<class_bool>` bit **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bit_rect<class_BitMap_method_set_bit_rect>` **(** :ref:`Rect2<class_Rect2>` rect, :ref:`bool<class_bool>` bit **)** |
|
||||
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_BitMap_method_create:
|
||||
|
||||
- void **create** **(** :ref:`Vector2<class_Vector2>` size **)**
|
||||
|
||||
Crea un mapa de bits con el tamaño especificado, lleno de ``false``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitMap_method_create_from_image_alpha:
|
||||
|
||||
- void **create_from_image_alpha** **(** :ref:`Image<class_Image>` image, :ref:`float<class_float>` threshold=0.1 **)**
|
||||
|
||||
Crea un mapa de bits que coincide con las dimensiones de la imagen dada, cada elemento del mapa de bits se establece en ``false`` si el valor alfa de la imagen en esa posición es igual al umbral ``threshold`` o menor, y ``true`` en otro caso.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitMap_method_get_bit:
|
||||
|
||||
- :ref:`bool<class_bool>` **get_bit** **(** :ref:`Vector2<class_Vector2>` position **)** |const|
|
||||
|
||||
Devuelve el valor del mapa de bits en la posición especificada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitMap_method_get_size:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **get_size** **(** **)** |const|
|
||||
|
||||
Devuelve las dimensiones del mapa de bits.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitMap_method_get_true_bit_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_true_bit_count** **(** **)** |const|
|
||||
|
||||
Devuelve la cantidad de elementos de mapa de bits que están configurados a ``true``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitMap_method_grow_mask:
|
||||
|
||||
- void **grow_mask** **(** :ref:`int<class_int>` pixels, :ref:`Rect2<class_Rect2>` rect **)**
|
||||
|
||||
Applies morphological dilation or erosion to the bitmap. If ``pixels`` is positive, dilation is applied to the bitmap. If ``pixels`` is negative, erosion is applied to the bitmap. ``rect`` defines the area where the morphological operation is applied. Pixels located outside the ``rect`` are unaffected by :ref:`grow_mask<class_BitMap_method_grow_mask>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitMap_method_opaque_to_polygons:
|
||||
|
||||
- :ref:`Array<class_Array>` **opaque_to_polygons** **(** :ref:`Rect2<class_Rect2>` rect, :ref:`float<class_float>` epsilon=2.0 **)** |const|
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitMap_method_set_bit:
|
||||
|
||||
- void **set_bit** **(** :ref:`Vector2<class_Vector2>` position, :ref:`bool<class_bool>` bit **)**
|
||||
|
||||
Establece el elemento del mapa de bits en la posición especificada, al valor especificado.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitMap_method_set_bit_rect:
|
||||
|
||||
- void **set_bit_rect** **(** :ref:`Rect2<class_Rect2>` rect, :ref:`bool<class_bool>` bit **)**
|
||||
|
||||
Establece una porción rectangular del mapa de bits al valor especificado.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,187 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the BitmapFont.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_BitmapFont:
|
||||
|
||||
BitmapFont
|
||||
==========
|
||||
|
||||
**Inherits:** :ref:`Font<class_Font>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Renderiza el texto usando fuentes en el formato `BMFont <https://www.angelcode.com/products/bmfont/>`__.
|
||||
|
||||
Maneja archivos con la extensión ``.fnt``.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Presenta el texto usando fuentes ``*.fnt`` que contienen atlas de texturas. Soporta campos de distancia. Para usar directamente archivos de fuentes vectoriales como TTF, ver :ref:`DynamicFont<class_DynamicFont>`.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-------------------------------------+-----------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`ascent<class_BitmapFont_property_ascent>` | ``0.0`` |
|
||||
+-------------------------------------+-----------------------------------------------------------------+-----------+
|
||||
| :ref:`bool<class_bool>` | :ref:`distance_field<class_BitmapFont_property_distance_field>` | ``false`` |
|
||||
+-------------------------------------+-----------------------------------------------------------------+-----------+
|
||||
| :ref:`BitmapFont<class_BitmapFont>` | :ref:`fallback<class_BitmapFont_property_fallback>` | |
|
||||
+-------------------------------------+-----------------------------------------------------------------+-----------+
|
||||
| :ref:`float<class_float>` | :ref:`height<class_BitmapFont_property_height>` | ``1.0`` |
|
||||
+-------------------------------------+-----------------------------------------------------------------+-----------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_char<class_BitmapFont_method_add_char>` **(** :ref:`int<class_int>` character, :ref:`int<class_int>` texture, :ref:`Rect2<class_Rect2>` rect, :ref:`Vector2<class_Vector2>` align=Vector2( 0, 0 ), :ref:`float<class_float>` advance=-1 **)** |
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_kerning_pair<class_BitmapFont_method_add_kerning_pair>` **(** :ref:`int<class_int>` char_a, :ref:`int<class_int>` char_b, :ref:`int<class_int>` kerning **)** |
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`add_texture<class_BitmapFont_method_add_texture>` **(** :ref:`Texture<class_Texture>` texture **)** |
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`clear<class_BitmapFont_method_clear>` **(** **)** |
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Error<enum_@GlobalScope_Error>` | :ref:`create_from_fnt<class_BitmapFont_method_create_from_fnt>` **(** :ref:`String<class_String>` path **)** |
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_kerning_pair<class_BitmapFont_method_get_kerning_pair>` **(** :ref:`int<class_int>` char_a, :ref:`int<class_int>` char_b **)** |const| |
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Texture<class_Texture>` | :ref:`get_texture<class_BitmapFont_method_get_texture>` **(** :ref:`int<class_int>` idx **)** |const| |
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_texture_count<class_BitmapFont_method_get_texture_count>` **(** **)** |const| |
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_BitmapFont_property_ascent:
|
||||
|
||||
- :ref:`float<class_float>` **ascent**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``0.0`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_ascent(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_ascent() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Ascenso (número de píxeles por encima de la línea de base).
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitmapFont_property_distance_field:
|
||||
|
||||
- :ref:`bool<class_bool>` **distance_field**
|
||||
|
||||
+-----------+--------------------------------+
|
||||
| *Default* | ``false`` |
|
||||
+-----------+--------------------------------+
|
||||
| *Setter* | set_distance_field_hint(value) |
|
||||
+-----------+--------------------------------+
|
||||
| *Getter* | is_distance_field_hint() |
|
||||
+-----------+--------------------------------+
|
||||
|
||||
Si ``true``, la sugerencia de campo de distancia está activada.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitmapFont_property_fallback:
|
||||
|
||||
- :ref:`BitmapFont<class_BitmapFont>` **fallback**
|
||||
|
||||
+----------+---------------------+
|
||||
| *Setter* | set_fallback(value) |
|
||||
+----------+---------------------+
|
||||
| *Getter* | get_fallback() |
|
||||
+----------+---------------------+
|
||||
|
||||
La fuente alternativa.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitmapFont_property_height:
|
||||
|
||||
- :ref:`float<class_float>` **height**
|
||||
|
||||
+-----------+-------------------+
|
||||
| *Default* | ``1.0`` |
|
||||
+-----------+-------------------+
|
||||
| *Setter* | set_height(value) |
|
||||
+-----------+-------------------+
|
||||
| *Getter* | get_height() |
|
||||
+-----------+-------------------+
|
||||
|
||||
Altura total de la fuente (ascenso más descenso) en píxeles.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_BitmapFont_method_add_char:
|
||||
|
||||
- void **add_char** **(** :ref:`int<class_int>` character, :ref:`int<class_int>` texture, :ref:`Rect2<class_Rect2>` rect, :ref:`Vector2<class_Vector2>` align=Vector2( 0, 0 ), :ref:`float<class_float>` advance=-1 **)**
|
||||
|
||||
Añade un carácter a la fuente, donde ``character`` es el valor Unicode, ``texture`` es el índice de la textura, ``rect`` es la región de la textura (¡en píxeles!), ``align`` es la alineación (opcional) del carácter y ``advance`` es el avance (opcional).
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitmapFont_method_add_kerning_pair:
|
||||
|
||||
- void **add_kerning_pair** **(** :ref:`int<class_int>` char_a, :ref:`int<class_int>` char_b, :ref:`int<class_int>` kerning **)**
|
||||
|
||||
Añade un par de kerning a la ``BitmapFont`` como diferencia. Los pares de Kerning son casos especiales en los que el avance de un tipo de letra viene determinado por el siguiente carácter.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitmapFont_method_add_texture:
|
||||
|
||||
- void **add_texture** **(** :ref:`Texture<class_Texture>` texture **)**
|
||||
|
||||
Añade una textura al ``BitmapFont``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitmapFont_method_clear:
|
||||
|
||||
- void **clear** **(** **)**
|
||||
|
||||
Borra todos los datos y ajustes de la fuente.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitmapFont_method_create_from_fnt:
|
||||
|
||||
- :ref:`Error<enum_@GlobalScope_Error>` **create_from_fnt** **(** :ref:`String<class_String>` path **)**
|
||||
|
||||
Crea una fuente de mapa de bits a partir del archivo ``*.fnt`` en ``path``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitmapFont_method_get_kerning_pair:
|
||||
|
||||
- :ref:`int<class_int>` **get_kerning_pair** **(** :ref:`int<class_int>` char_a, :ref:`int<class_int>` char_b **)** |const|
|
||||
|
||||
Devuelve un par de kerning como diferencia.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitmapFont_method_get_texture:
|
||||
|
||||
- :ref:`Texture<class_Texture>` **get_texture** **(** :ref:`int<class_int>` idx **)** |const|
|
||||
|
||||
Devuelve la textura de la fuente del atlas en el índice ``idx``.
|
||||
|
||||
----
|
||||
|
||||
.. _class_BitmapFont_method_get_texture_count:
|
||||
|
||||
- :ref:`int<class_int>` **get_texture_count** **(** **)** |const|
|
||||
|
||||
Devuelve el número de texturas en el atlas de BitmapFont.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,107 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the Bone2D.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_Bone2D:
|
||||
|
||||
Bone2D
|
||||
======
|
||||
|
||||
**Inherits:** :ref:`Node2D<class_Node2D>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Articulación usada con :ref:`Skeleton2D<class_Skeleton2D>` para controlar y animar otros nodos.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
Usar una jerarquía de ``Bone2D`` unido a un :ref:`Skeleton2D<class_Skeleton2D>` para controlar, y animar otros nodos :ref:`Node2D<class_Node2D>`.
|
||||
|
||||
Puedes usar ``Bone2D`` y ``Skeleton2D`` nodos para animar mallas 2D creadas con el editor UV de Polygon 2D.
|
||||
|
||||
Cada hueso tiene una transformación :ref:`rest<class_Bone2D_property_rest>` a la que puedes volver con :ref:`apply_rest<class_Bone2D_method_apply_rest>`. Estas poses de reposo son relativas al padre del hueso.
|
||||
|
||||
Si en el editor puedes establecer la pose de reposo de un esqueleto entero usando una opción del menú, desde el código, necesitas iterar sobre los huesos para establecer sus poses de reposo individuales.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+---------------------------------------+-------------------------------------------------------------+-------------------------------------+
|
||||
| :ref:`float<class_float>` | :ref:`default_length<class_Bone2D_property_default_length>` | ``16.0`` |
|
||||
+---------------------------------------+-------------------------------------------------------------+-------------------------------------+
|
||||
| :ref:`Transform2D<class_Transform2D>` | :ref:`rest<class_Bone2D_property_rest>` | ``Transform2D( 0, 0, 0, 0, 0, 0 )`` |
|
||||
+---------------------------------------+-------------------------------------------------------------+-------------------------------------+
|
||||
|
||||
Métodos
|
||||
--------------
|
||||
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`apply_rest<class_Bone2D_method_apply_rest>` **(** **)** |
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`get_index_in_skeleton<class_Bone2D_method_get_index_in_skeleton>` **(** **)** |const| |
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------+
|
||||
| :ref:`Transform2D<class_Transform2D>` | :ref:`get_skeleton_rest<class_Bone2D_method_get_skeleton_rest>` **(** **)** |const| |
|
||||
+---------------------------------------+---------------------------------------------------------------------------------------------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_Bone2D_property_default_length:
|
||||
|
||||
- :ref:`float<class_float>` **default_length**
|
||||
|
||||
+-----------+---------------------------+
|
||||
| *Default* | ``16.0`` |
|
||||
+-----------+---------------------------+
|
||||
| *Setter* | set_default_length(value) |
|
||||
+-----------+---------------------------+
|
||||
| *Getter* | get_default_length() |
|
||||
+-----------+---------------------------+
|
||||
|
||||
La longitud de la representación del hueso dibujada en la vista del editor en píxeles.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Bone2D_property_rest:
|
||||
|
||||
- :ref:`Transform2D<class_Transform2D>` **rest**
|
||||
|
||||
+-----------+-------------------------------------+
|
||||
| *Default* | ``Transform2D( 0, 0, 0, 0, 0, 0 )`` |
|
||||
+-----------+-------------------------------------+
|
||||
| *Setter* | set_rest(value) |
|
||||
+-----------+-------------------------------------+
|
||||
| *Getter* | get_rest() |
|
||||
+-----------+-------------------------------------+
|
||||
|
||||
La transformación en reposo del hueso. Puedes reajustar las transformaciones del nodo a este valor usando :ref:`apply_rest<class_Bone2D_method_apply_rest>`.
|
||||
|
||||
Descripciones de Métodos
|
||||
------------------------------------------------
|
||||
|
||||
.. _class_Bone2D_method_apply_rest:
|
||||
|
||||
- void **apply_rest** **(** **)**
|
||||
|
||||
Almacena las transformaciones del nodo actual en :ref:`rest<class_Bone2D_property_rest>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Bone2D_method_get_index_in_skeleton:
|
||||
|
||||
- :ref:`int<class_int>` **get_index_in_skeleton** **(** **)** |const|
|
||||
|
||||
Devuelve el índice del nodo como parte de todo el esqueleto. Ver :ref:`Skeleton2D<class_Skeleton2D>`.
|
||||
|
||||
----
|
||||
|
||||
.. _class_Bone2D_method_get_skeleton_rest:
|
||||
|
||||
- :ref:`Transform2D<class_Transform2D>` **get_skeleton_rest** **(** **)** |const|
|
||||
|
||||
Devuelve el :ref:`rest<class_Bone2D_property_rest>` ``Transform2D`` del nodo si no tiene un padre, o su pose de reposo en relación con su padre.
|
||||
|
||||
.. |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.)`
|
||||
@@ -1,47 +0,0 @@
|
||||
:github_url: hide
|
||||
|
||||
.. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
|
||||
.. DO NOT EDIT THIS FILE, but the BoneAttachment.xml source instead.
|
||||
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
||||
|
||||
.. _class_BoneAttachment:
|
||||
|
||||
BoneAttachment
|
||||
==============
|
||||
|
||||
**Inherits:** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||||
|
||||
Un nodo que se unirá a un hueso.
|
||||
|
||||
Descripción
|
||||
----------------------
|
||||
|
||||
This node must be the child of a :ref:`Skeleton<class_Skeleton>` node. You can then select a bone for this node to attach to. The BoneAttachment node will copy the transform of the selected bone.
|
||||
|
||||
Propiedades
|
||||
----------------------
|
||||
|
||||
+-----------------------------+-----------------------------------------------------------+--------+
|
||||
| :ref:`String<class_String>` | :ref:`bone_name<class_BoneAttachment_property_bone_name>` | ``""`` |
|
||||
+-----------------------------+-----------------------------------------------------------+--------+
|
||||
|
||||
Descripciones de Propiedades
|
||||
--------------------------------------------------------
|
||||
|
||||
.. _class_BoneAttachment_property_bone_name:
|
||||
|
||||
- :ref:`String<class_String>` **bone_name**
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``""`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_bone_name(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_bone_name() |
|
||||
+-----------+----------------------+
|
||||
|
||||
El nombre del hueso unido.
|
||||
|
||||
.. |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.)`
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user