World2D.xml 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <class name="World2D" inherits="Resource" category="Core" version="3.0.alpha.custom_build">
  3. <brief_description>
  4. Class that has everything pertaining to a 2D world.
  5. </brief_description>
  6. <description>
  7. Class that has everything pertaining to a 2D world. A physics space, a visual scenario and a sound space. 2D nodes register their resources into the current 2D world.
  8. </description>
  9. <tutorials>
  10. </tutorials>
  11. <demos>
  12. </demos>
  13. <methods>
  14. <method name="get_canvas">
  15. <return type="RID">
  16. </return>
  17. <description>
  18. Retrieve the [RID] of this world's canvas resource. Used by the [VisualServer] for 2D drawing.
  19. </description>
  20. </method>
  21. <method name="get_direct_space_state">
  22. <return type="Physics2DDirectSpaceState">
  23. </return>
  24. <description>
  25. Retrieve the state of this world's physics space. This allows arbitrary querying for collision.
  26. </description>
  27. </method>
  28. <method name="get_space">
  29. <return type="RID">
  30. </return>
  31. <description>
  32. Retrieve the [RID] of this world's physics space resource. Used by the [Physics2DServer] for 2D physics, treating it as both a space and an area.
  33. </description>
  34. </method>
  35. </methods>
  36. <constants>
  37. </constants>
  38. </class>