World2D Properties |
The World2D type exposes the following members.
Name | Description | |
---|---|---|
![]() | Canvas | The RID of this world's canvas resource. Used by the VisualServer for 2D drawing. |
![]() | DirectSpaceState | 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 _physics_process(delta) in the main thread. |
![]() | DynamicObject |
Gets a new DynamicGodotObject associated with this instance.
(Inherited from Object.) |
![]() | NativeInstance | (Inherited from Object.) |
![]() | ResourceLocalToScene | If true, the resource will be made unique in each instance of its local scene. It can thus be modified in a scene instance without impacting other instances of that same scene. |
![]() | ResourceName | The name of the resource. This is an optional identifier. If ResourceName is not empty, its value will be displayed to represent the current resource in the editor inspector. For built-in scripts, the ResourceName will be displayed as the tab name in the script editor. |
![]() | ResourcePath | The path to the resource. In case it has its own file, it will return its filepath. If it's tied to the scene, it will return the scene's path, followed by the resource's index. |
![]() | Space | 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. |