2
0

class_collisionobject.rst 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. .. _class_CollisionObject:
  2. CollisionObject
  3. ===============
  4. Inherits: :ref:`Spatial<class_spatial>`
  5. ---------------------------------------
  6. Category: Core
  7. --------------
  8. Brief Description
  9. -----------------
  10. Member Functions
  11. ----------------
  12. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  13. | void | :ref:`_input_event<class_CollisionObject__input_event>` **(** :ref:`Object<class_object>` camera, :ref:`InputEvent<class_inputevent>` event, :ref:`Vector3<class_vector3>` click_pos, :ref:`Vector3<class_vector3>` click_normal, :ref:`int<class_int>` shape_idx **)** virtual |
  14. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  15. | void | :ref:`add_shape<class_CollisionObject_add_shape>` **(** :ref:`Shape<class_shape>` shape, :ref:`Transform<class_transform>` transform=Transform() **)** |
  16. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  17. | :ref:`int<class_int>` | :ref:`get_shape_count<class_CollisionObject_get_shape_count>` **(** **)** const |
  18. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  19. | void | :ref:`set_shape<class_CollisionObject_set_shape>` **(** :ref:`int<class_int>` shape_idx, :ref:`Shape<class_shape>` shape **)** |
  20. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  21. | void | :ref:`set_shape_transform<class_CollisionObject_set_shape_transform>` **(** :ref:`int<class_int>` shape_idx, :ref:`Transform<class_transform>` transform **)** |
  22. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  23. | void | :ref:`set_shape_as_trigger<class_CollisionObject_set_shape_as_trigger>` **(** :ref:`int<class_int>` shape_idx, :ref:`bool<class_bool>` enable **)** |
  24. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  25. | :ref:`bool<class_bool>` | :ref:`is_shape_set_as_trigger<class_CollisionObject_is_shape_set_as_trigger>` **(** :ref:`int<class_int>` shape_idx **)** const |
  26. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  27. | :ref:`Shape<class_shape>` | :ref:`get_shape<class_CollisionObject_get_shape>` **(** :ref:`int<class_int>` shape_idx **)** const |
  28. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  29. | :ref:`Transform<class_transform>` | :ref:`get_shape_transform<class_CollisionObject_get_shape_transform>` **(** :ref:`int<class_int>` shape_idx **)** const |
  30. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  31. | void | :ref:`remove_shape<class_CollisionObject_remove_shape>` **(** :ref:`int<class_int>` shape_idx **)** |
  32. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  33. | void | :ref:`clear_shapes<class_CollisionObject_clear_shapes>` **(** **)** |
  34. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  35. | void | :ref:`set_ray_pickable<class_CollisionObject_set_ray_pickable>` **(** :ref:`bool<class_bool>` ray_pickable **)** |
  36. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  37. | :ref:`bool<class_bool>` | :ref:`is_ray_pickable<class_CollisionObject_is_ray_pickable>` **(** **)** const |
  38. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  39. | void | :ref:`set_capture_input_on_drag<class_CollisionObject_set_capture_input_on_drag>` **(** :ref:`bool<class_bool>` enable **)** |
  40. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  41. | :ref:`bool<class_bool>` | :ref:`get_capture_input_on_drag<class_CollisionObject_get_capture_input_on_drag>` **(** **)** const |
  42. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  43. | :ref:`RID<class_rid>` | :ref:`get_rid<class_CollisionObject_get_rid>` **(** **)** const |
  44. +------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  45. Signals
  46. -------
  47. - **mouse_enter** **(** **)**
  48. - **input_event** **(** :ref:`Object<class_object>` camera, :ref:`InputEvent<class_inputevent>` event, :ref:`Vector3<class_vector3>` click_pos, :ref:`Vector3<class_vector3>` click_normal, :ref:`int<class_int>` shape_idx **)**
  49. - **mouse_exit** **(** **)**
  50. Member Function Description
  51. ---------------------------
  52. .. _class_CollisionObject__input_event:
  53. - void **_input_event** **(** :ref:`Object<class_object>` camera, :ref:`InputEvent<class_inputevent>` event, :ref:`Vector3<class_vector3>` click_pos, :ref:`Vector3<class_vector3>` click_normal, :ref:`int<class_int>` shape_idx **)** virtual
  54. .. _class_CollisionObject_add_shape:
  55. - void **add_shape** **(** :ref:`Shape<class_shape>` shape, :ref:`Transform<class_transform>` transform=Transform() **)**
  56. .. _class_CollisionObject_get_shape_count:
  57. - :ref:`int<class_int>` **get_shape_count** **(** **)** const
  58. .. _class_CollisionObject_set_shape:
  59. - void **set_shape** **(** :ref:`int<class_int>` shape_idx, :ref:`Shape<class_shape>` shape **)**
  60. .. _class_CollisionObject_set_shape_transform:
  61. - void **set_shape_transform** **(** :ref:`int<class_int>` shape_idx, :ref:`Transform<class_transform>` transform **)**
  62. .. _class_CollisionObject_set_shape_as_trigger:
  63. - void **set_shape_as_trigger** **(** :ref:`int<class_int>` shape_idx, :ref:`bool<class_bool>` enable **)**
  64. .. _class_CollisionObject_is_shape_set_as_trigger:
  65. - :ref:`bool<class_bool>` **is_shape_set_as_trigger** **(** :ref:`int<class_int>` shape_idx **)** const
  66. .. _class_CollisionObject_get_shape:
  67. - :ref:`Shape<class_shape>` **get_shape** **(** :ref:`int<class_int>` shape_idx **)** const
  68. .. _class_CollisionObject_get_shape_transform:
  69. - :ref:`Transform<class_transform>` **get_shape_transform** **(** :ref:`int<class_int>` shape_idx **)** const
  70. .. _class_CollisionObject_remove_shape:
  71. - void **remove_shape** **(** :ref:`int<class_int>` shape_idx **)**
  72. .. _class_CollisionObject_clear_shapes:
  73. - void **clear_shapes** **(** **)**
  74. .. _class_CollisionObject_set_ray_pickable:
  75. - void **set_ray_pickable** **(** :ref:`bool<class_bool>` ray_pickable **)**
  76. .. _class_CollisionObject_is_ray_pickable:
  77. - :ref:`bool<class_bool>` **is_ray_pickable** **(** **)** const
  78. .. _class_CollisionObject_set_capture_input_on_drag:
  79. - void **set_capture_input_on_drag** **(** :ref:`bool<class_bool>` enable **)**
  80. .. _class_CollisionObject_get_capture_input_on_drag:
  81. - :ref:`bool<class_bool>` **get_capture_input_on_drag** **(** **)** const
  82. .. _class_CollisionObject_get_rid:
  83. - :ref:`RID<class_rid>` **get_rid** **(** **)** const