World2D.xml 1.4 KB

1234567891011121314151617181920212223242526
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <class name="World2D" inherits="Resource" version="4.0">
  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. <link title="Ray-casting">https://docs.godotengine.org/en/latest/tutorials/physics/ray-casting.html</link>
  11. </tutorials>
  12. <members>
  13. <member name="canvas" type="RID" setter="" getter="get_canvas">
  14. The [RID] of this world's canvas resource. Used by the [RenderingServer] for 2D drawing.
  15. </member>
  16. <member name="direct_space_state" type="PhysicsDirectSpaceState2D" setter="" getter="get_direct_space_state">
  17. Direct access to the world's physics 2D space state. Used for querying current and potential collisions. When using multi-threaded physics, access is limited to [code]_physics_process(delta)[/code] in the main thread.
  18. </member>
  19. <member name="navigation_map" type="RID" setter="" getter="get_navigation_map">
  20. The [RID] of this world's navigation map. Used by the [NavigationServer2D].
  21. </member>
  22. <member name="space" type="RID" setter="" getter="get_space">
  23. The [RID] of this world's physics space resource. Used by the [PhysicsServer2D] for 2D physics, treating it as both a space and an area.
  24. </member>
  25. </members>
  26. </class>