class_csgbox.rst 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127
  1. :github_url: hide
  2. .. DO NOT EDIT THIS FILE!!!
  3. .. Generated automatically from Godot engine sources.
  4. .. Generator: https://github.com/godotengine/godot/tree/3.6/doc/tools/make_rst.py.
  5. .. XML source: https://github.com/godotengine/godot/tree/3.6/modules/csg/doc_classes/CSGBox.xml.
  6. .. _class_CSGBox:
  7. CSGBox
  8. ======
  9. **Inherits:** :ref:`CSGPrimitive<class_CSGPrimitive>` **<** :ref:`CSGShape<class_CSGShape>` **<** :ref:`GeometryInstance<class_GeometryInstance>` **<** :ref:`VisualInstance<class_VisualInstance>` **<** :ref:`CullInstance<class_CullInstance>` **<** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
  10. A CSG Box shape.
  11. .. rst-class:: classref-introduction-group
  12. Description
  13. -----------
  14. This node allows you to create a box for use with the CSG system.
  15. \ **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a significant CPU cost compared to creating a :ref:`MeshInstance<class_MeshInstance>` with a :ref:`PrimitiveMesh<class_PrimitiveMesh>`. Moving a CSG node within another CSG node also has a significant CPU cost, so it should be avoided during gameplay.
  16. .. rst-class:: classref-introduction-group
  17. Tutorials
  18. ---------
  19. - :doc:`Prototyping levels with CSG <../tutorials/3d/csg_tools>`
  20. .. rst-class:: classref-reftable-group
  21. Properties
  22. ----------
  23. .. table::
  24. :widths: auto
  25. +---------------------------------+-------------------------------------------------+---------+
  26. | :ref:`float<class_float>` | :ref:`depth<class_CSGBox_property_depth>` | ``2.0`` |
  27. +---------------------------------+-------------------------------------------------+---------+
  28. | :ref:`float<class_float>` | :ref:`height<class_CSGBox_property_height>` | ``2.0`` |
  29. +---------------------------------+-------------------------------------------------+---------+
  30. | :ref:`Material<class_Material>` | :ref:`material<class_CSGBox_property_material>` | |
  31. +---------------------------------+-------------------------------------------------+---------+
  32. | :ref:`float<class_float>` | :ref:`width<class_CSGBox_property_width>` | ``2.0`` |
  33. +---------------------------------+-------------------------------------------------+---------+
  34. .. rst-class:: classref-section-separator
  35. ----
  36. .. rst-class:: classref-descriptions-group
  37. Property Descriptions
  38. ---------------------
  39. .. _class_CSGBox_property_depth:
  40. .. rst-class:: classref-property
  41. :ref:`float<class_float>` **depth** = ``2.0``
  42. .. rst-class:: classref-property-setget
  43. - void **set_depth** **(** :ref:`float<class_float>` value **)**
  44. - :ref:`float<class_float>` **get_depth** **(** **)**
  45. Depth of the box measured from the center of the box.
  46. .. rst-class:: classref-item-separator
  47. ----
  48. .. _class_CSGBox_property_height:
  49. .. rst-class:: classref-property
  50. :ref:`float<class_float>` **height** = ``2.0``
  51. .. rst-class:: classref-property-setget
  52. - void **set_height** **(** :ref:`float<class_float>` value **)**
  53. - :ref:`float<class_float>` **get_height** **(** **)**
  54. Height of the box measured from the center of the box.
  55. .. rst-class:: classref-item-separator
  56. ----
  57. .. _class_CSGBox_property_material:
  58. .. rst-class:: classref-property
  59. :ref:`Material<class_Material>` **material**
  60. .. rst-class:: classref-property-setget
  61. - void **set_material** **(** :ref:`Material<class_Material>` value **)**
  62. - :ref:`Material<class_Material>` **get_material** **(** **)**
  63. The material used to render the box.
  64. .. rst-class:: classref-item-separator
  65. ----
  66. .. _class_CSGBox_property_width:
  67. .. rst-class:: classref-property
  68. :ref:`float<class_float>` **width** = ``2.0``
  69. .. rst-class:: classref-property-setget
  70. - void **set_width** **(** :ref:`float<class_float>` value **)**
  71. - :ref:`float<class_float>` **get_width** **(** **)**
  72. Width of the box measured from the center of the box.
  73. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  74. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  75. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  76. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`