class_physicsmaterial.rst 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. :github_url: hide
  2. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  3. .. DO NOT EDIT THIS FILE, but the PhysicsMaterial.xml source instead.
  4. .. The source is found in doc/classes or modules/<name>/doc_classes.
  5. .. _class_PhysicsMaterial:
  6. PhysicsMaterial
  7. ===============
  8. **Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
  9. **Category:** Core
  10. Brief Description
  11. -----------------
  12. A material for physics properties.
  13. Properties
  14. ----------
  15. +---------------------------+------------------------------------------------------------+-------+
  16. | :ref:`bool<class_bool>` | :ref:`absorbent<class_PhysicsMaterial_property_absorbent>` | false |
  17. +---------------------------+------------------------------------------------------------+-------+
  18. | :ref:`float<class_float>` | :ref:`bounce<class_PhysicsMaterial_property_bounce>` | 0.0 |
  19. +---------------------------+------------------------------------------------------------+-------+
  20. | :ref:`float<class_float>` | :ref:`friction<class_PhysicsMaterial_property_friction>` | 1.0 |
  21. +---------------------------+------------------------------------------------------------+-------+
  22. | :ref:`bool<class_bool>` | :ref:`rough<class_PhysicsMaterial_property_rough>` | false |
  23. +---------------------------+------------------------------------------------------------+-------+
  24. Description
  25. -----------
  26. Provides a means of modifying the collision properties of a :ref:`PhysicsBody<class_PhysicsBody>`.
  27. Property Descriptions
  28. ---------------------
  29. .. _class_PhysicsMaterial_property_absorbent:
  30. - :ref:`bool<class_bool>` **absorbent**
  31. +-----------+----------------------+
  32. | *Default* | false |
  33. +-----------+----------------------+
  34. | *Setter* | set_absorbent(value) |
  35. +-----------+----------------------+
  36. | *Getter* | is_absorbent() |
  37. +-----------+----------------------+
  38. .. _class_PhysicsMaterial_property_bounce:
  39. - :ref:`float<class_float>` **bounce**
  40. +-----------+-------------------+
  41. | *Default* | 0.0 |
  42. +-----------+-------------------+
  43. | *Setter* | set_bounce(value) |
  44. +-----------+-------------------+
  45. | *Getter* | get_bounce() |
  46. +-----------+-------------------+
  47. The body's bounciness. Values range from ``0`` (no bounce) to ``1`` (full bounciness).
  48. .. _class_PhysicsMaterial_property_friction:
  49. - :ref:`float<class_float>` **friction**
  50. +-----------+---------------------+
  51. | *Default* | 1.0 |
  52. +-----------+---------------------+
  53. | *Setter* | set_friction(value) |
  54. +-----------+---------------------+
  55. | *Getter* | get_friction() |
  56. +-----------+---------------------+
  57. The body's friction. Values range from ``0`` (frictionless) to ``1`` (maximum friction).
  58. .. _class_PhysicsMaterial_property_rough:
  59. - :ref:`bool<class_bool>` **rough**
  60. +-----------+------------------+
  61. | *Default* | false |
  62. +-----------+------------------+
  63. | *Setter* | set_rough(value) |
  64. +-----------+------------------+
  65. | *Getter* | is_rough() |
  66. +-----------+------------------+