class_lightoccluder2d.rst 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the LightOccluder2D.xml source instead.
  3. .. The source is found in doc/classes or modules/<name>/doc_classes.
  4. .. _class_LightOccluder2D:
  5. LightOccluder2D
  6. ===============
  7. **Inherits:** :ref:`Node2D<class_Node2D>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
  8. **Category:** Core
  9. Brief Description
  10. -----------------
  11. Occludes light cast by a Light2D, casting shadows.
  12. Properties
  13. ----------
  14. +---------------------------------------------------+--------------------------------------------------------------+
  15. | :ref:`int<class_int>` | :ref:`light_mask<class_LightOccluder2D_property_light_mask>` |
  16. +---------------------------------------------------+--------------------------------------------------------------+
  17. | :ref:`OccluderPolygon2D<class_OccluderPolygon2D>` | :ref:`occluder<class_LightOccluder2D_property_occluder>` |
  18. +---------------------------------------------------+--------------------------------------------------------------+
  19. Description
  20. -----------
  21. Occludes light cast by a Light2D, casting shadows. The LightOccluder2D must be provided with an :ref:`OccluderPolygon2D<class_OccluderPolygon2D>` in order for the shadow to be computed.
  22. Tutorials
  23. ---------
  24. - :doc:`../tutorials/2d/2d_lights_and_shadows`
  25. Property Descriptions
  26. ---------------------
  27. .. _class_LightOccluder2D_property_light_mask:
  28. - :ref:`int<class_int>` **light_mask**
  29. +----------+--------------------------------+
  30. | *Setter* | set_occluder_light_mask(value) |
  31. +----------+--------------------------------+
  32. | *Getter* | get_occluder_light_mask() |
  33. +----------+--------------------------------+
  34. The LightOccluder2D's light mask. The LightOccluder2D will cast shadows only from Light2D(s) that have the same light mask(s).
  35. .. _class_LightOccluder2D_property_occluder:
  36. - :ref:`OccluderPolygon2D<class_OccluderPolygon2D>` **occluder**
  37. +----------+-----------------------------+
  38. | *Setter* | set_occluder_polygon(value) |
  39. +----------+-----------------------------+
  40. | *Getter* | get_occluder_polygon() |
  41. +----------+-----------------------------+
  42. The :ref:`OccluderPolygon2D<class_OccluderPolygon2D>` used to compute the shadow.