mirror of
https://github.com/godotengine/godot-docs-l10n.git
synced 2026-01-05 14:10:19 +03:00
145 lines
5.3 KiB
ReStructuredText
145 lines
5.3 KiB
ReStructuredText
:github_url: hide
|
||
|
||
.. DO NOT EDIT THIS FILE!!!
|
||
.. Generated automatically from Godot engine sources.
|
||
.. Generator: https://github.com/godotengine/godot/tree/4.3/doc/tools/make_rst.py.
|
||
.. XML source: https://github.com/godotengine/godot/tree/4.3/doc/classes/CollisionShape3D.xml.
|
||
|
||
.. _class_CollisionShape3D:
|
||
|
||
CollisionShape3D
|
||
================
|
||
|
||
**继承:** :ref:`Node3D<class_Node3D>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
|
||
|
||
向 :ref:`CollisionObject3D<class_CollisionObject3D>` 父级提供 :ref:`Shape3D<class_Shape3D>` 的节点。
|
||
|
||
.. rst-class:: classref-introduction-group
|
||
|
||
描述
|
||
----
|
||
|
||
向 :ref:`CollisionObject3D<class_CollisionObject3D>` 父级提供 :ref:`Shape3D<class_Shape3D>` 并能够对其进行编辑的节点。可以为 :ref:`Area3D<class_Area3D>` 提供检测形状,也可以将 :ref:`PhysicsBody3D<class_PhysicsBody3D>` 变为实体对象。
|
||
|
||
\ **警告:**\ 非均匀缩放的 **CollisionShape3D** 可能无法按预期运行。请保持在所有轴上使用相同的缩放,需要时可以更改其 :ref:`shape<class_CollisionShape3D_property_shape>` 资源代替。
|
||
|
||
.. rst-class:: classref-introduction-group
|
||
|
||
教程
|
||
----
|
||
|
||
- :doc:`物理介绍 <../tutorials/physics/physics_introduction>`
|
||
|
||
- `3D 动力学角色演示 <https://godotengine.org/asset-library/asset/2739>`__
|
||
|
||
- `3D 平台跳跃演示 <https://godotengine.org/asset-library/asset/2748>`__
|
||
|
||
- `第三人称射击(TPS)演示 <https://godotengine.org/asset-library/asset/2710>`__
|
||
|
||
.. rst-class:: classref-reftable-group
|
||
|
||
属性
|
||
----
|
||
|
||
.. table::
|
||
:widths: auto
|
||
|
||
+-------------------------------+-----------------------------------------------------------+-----------+
|
||
| :ref:`bool<class_bool>` | :ref:`disabled<class_CollisionShape3D_property_disabled>` | ``false`` |
|
||
+-------------------------------+-----------------------------------------------------------+-----------+
|
||
| :ref:`Shape3D<class_Shape3D>` | :ref:`shape<class_CollisionShape3D_property_shape>` | |
|
||
+-------------------------------+-----------------------------------------------------------+-----------+
|
||
|
||
.. rst-class:: classref-reftable-group
|
||
|
||
方法
|
||
----
|
||
|
||
.. table::
|
||
:widths: auto
|
||
|
||
+--------+---------------------------------------------------------------------------------------------------------------------------+
|
||
| |void| | :ref:`make_convex_from_siblings<class_CollisionShape3D_method_make_convex_from_siblings>`\ (\ ) |
|
||
+--------+---------------------------------------------------------------------------------------------------------------------------+
|
||
| |void| | :ref:`resource_changed<class_CollisionShape3D_method_resource_changed>`\ (\ resource\: :ref:`Resource<class_Resource>`\ ) |
|
||
+--------+---------------------------------------------------------------------------------------------------------------------------+
|
||
|
||
.. rst-class:: classref-section-separator
|
||
|
||
----
|
||
|
||
.. rst-class:: classref-descriptions-group
|
||
|
||
属性说明
|
||
--------
|
||
|
||
.. _class_CollisionShape3D_property_disabled:
|
||
|
||
.. rst-class:: classref-property
|
||
|
||
:ref:`bool<class_bool>` **disabled** = ``false`` :ref:`🔗<class_CollisionShape3D_property_disabled>`
|
||
|
||
.. rst-class:: classref-property-setget
|
||
|
||
- |void| **set_disabled**\ (\ value\: :ref:`bool<class_bool>`\ )
|
||
- :ref:`bool<class_bool>` **is_disabled**\ (\ )
|
||
|
||
禁用的碰撞形状对世界没有任何影响。
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_CollisionShape3D_property_shape:
|
||
|
||
.. rst-class:: classref-property
|
||
|
||
:ref:`Shape3D<class_Shape3D>` **shape** :ref:`🔗<class_CollisionShape3D_property_shape>`
|
||
|
||
.. rst-class:: classref-property-setget
|
||
|
||
- |void| **set_shape**\ (\ value\: :ref:`Shape3D<class_Shape3D>`\ )
|
||
- :ref:`Shape3D<class_Shape3D>` **get_shape**\ (\ )
|
||
|
||
该碰撞形状拥有的实际形状。
|
||
|
||
.. rst-class:: classref-section-separator
|
||
|
||
----
|
||
|
||
.. rst-class:: classref-descriptions-group
|
||
|
||
方法说明
|
||
--------
|
||
|
||
.. _class_CollisionShape3D_method_make_convex_from_siblings:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
|void| **make_convex_from_siblings**\ (\ ) :ref:`🔗<class_CollisionShape3D_method_make_convex_from_siblings>`
|
||
|
||
将碰撞形状的形状设置为其所有凸面 :ref:`MeshInstance3D<class_MeshInstance3D>` 同级几何体的相加。
|
||
|
||
.. rst-class:: classref-item-separator
|
||
|
||
----
|
||
|
||
.. _class_CollisionShape3D_method_resource_changed:
|
||
|
||
.. rst-class:: classref-method
|
||
|
||
|void| **resource_changed**\ (\ resource\: :ref:`Resource<class_Resource>`\ ) :ref:`🔗<class_CollisionShape3D_method_resource_changed>`
|
||
|
||
**已弃用:** Use :ref:`Resource.changed<class_Resource_signal_changed>` instead.
|
||
|
||
这个方法什么也不做。
|
||
|
||
.. |virtual| replace:: :abbr:`virtual (本方法通常需要用户覆盖才能生效。)`
|
||
.. |const| replace:: :abbr:`const (本方法无副作用,不会修改该实例的任何成员变量。)`
|
||
.. |vararg| replace:: :abbr:`vararg (本方法除了能接受在此处描述的参数外,还能够继续接受任意数量的参数。)`
|
||
.. |constructor| replace:: :abbr:`constructor (本方法用于构造某个类型。)`
|
||
.. |static| replace:: :abbr:`static (调用本方法无需实例,可直接使用类名进行调用。)`
|
||
.. |operator| replace:: :abbr:`operator (本方法描述的是使用本类型作为左操作数的有效运算符。)`
|
||
.. |bitfield| replace:: :abbr:`BitField (这个值是由下列位标志构成位掩码的整数。)`
|
||
.. |void| replace:: :abbr:`void (无返回值。)`
|