mirror of
https://github.com/godotengine/godot-docs.git
synced 2025-12-31 17:49:03 +03:00
80 lines
4.2 KiB
ReStructuredText
80 lines
4.2 KiB
ReStructuredText
:github_url: hide
|
|
|
|
.. Generated automatically by doc/tools/makerst.py in Godot's source tree.
|
|
.. DO NOT EDIT THIS FILE, but the Physics2DShapeQueryResult.xml source instead.
|
|
.. The source is found in doc/classes or modules/<name>/doc_classes.
|
|
|
|
.. _class_Physics2DShapeQueryResult:
|
|
|
|
Physics2DShapeQueryResult
|
|
=========================
|
|
|
|
**Inherits:** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
|
|
|
|
Result of a 2D shape query in :ref:`Physics2DServer<class_Physics2DServer>`.
|
|
|
|
Description
|
|
-----------
|
|
|
|
The result of a 2D shape query in :ref:`Physics2DServer<class_Physics2DServer>`. See also :ref:`Physics2DShapeQueryParameters<class_Physics2DShapeQueryParameters>`.
|
|
|
|
Methods
|
|
-------
|
|
|
|
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
|
| :ref:`int<class_int>` | :ref:`get_result_count<class_Physics2DShapeQueryResult_method_get_result_count>` **(** **)** |const| |
|
|
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
|
| :ref:`Object<class_Object>` | :ref:`get_result_object<class_Physics2DShapeQueryResult_method_get_result_object>` **(** :ref:`int<class_int>` idx **)** |const| |
|
|
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
|
| :ref:`int<class_int>` | :ref:`get_result_object_id<class_Physics2DShapeQueryResult_method_get_result_object_id>` **(** :ref:`int<class_int>` idx **)** |const| |
|
|
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
|
| :ref:`int<class_int>` | :ref:`get_result_object_shape<class_Physics2DShapeQueryResult_method_get_result_object_shape>` **(** :ref:`int<class_int>` idx **)** |const| |
|
|
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
|
| :ref:`RID<class_RID>` | :ref:`get_result_rid<class_Physics2DShapeQueryResult_method_get_result_rid>` **(** :ref:`int<class_int>` idx **)** |const| |
|
|
+-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------+
|
|
|
|
Method Descriptions
|
|
-------------------
|
|
|
|
.. _class_Physics2DShapeQueryResult_method_get_result_count:
|
|
|
|
- :ref:`int<class_int>` **get_result_count** **(** **)** |const|
|
|
|
|
Returns the number of objects that intersected with the shape.
|
|
|
|
----
|
|
|
|
.. _class_Physics2DShapeQueryResult_method_get_result_object:
|
|
|
|
- :ref:`Object<class_Object>` **get_result_object** **(** :ref:`int<class_int>` idx **)** |const|
|
|
|
|
Returns the :ref:`Object<class_Object>` that intersected with the shape at index ``idx``.
|
|
|
|
----
|
|
|
|
.. _class_Physics2DShapeQueryResult_method_get_result_object_id:
|
|
|
|
- :ref:`int<class_int>` **get_result_object_id** **(** :ref:`int<class_int>` idx **)** |const|
|
|
|
|
Returns the instance ID of the :ref:`Object<class_Object>` that intersected with the shape at index ``idx``.
|
|
|
|
----
|
|
|
|
.. _class_Physics2DShapeQueryResult_method_get_result_object_shape:
|
|
|
|
- :ref:`int<class_int>` **get_result_object_shape** **(** :ref:`int<class_int>` idx **)** |const|
|
|
|
|
Returns the child index of the object's :ref:`Shape<class_Shape>` that intersected with the shape at index ``idx``.
|
|
|
|
----
|
|
|
|
.. _class_Physics2DShapeQueryResult_method_get_result_rid:
|
|
|
|
- :ref:`RID<class_RID>` **get_result_rid** **(** :ref:`int<class_int>` idx **)** |const|
|
|
|
|
Returns the :ref:`RID<class_RID>` of the object that intersected with the shape at index ``idx``.
|
|
|
|
.. |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.)`
|