PhysicsPointQueryParameters2D
Provides parameters for PhysicsDirectSpaceState2D.intersect_point.
Provides parameters for PhysicsDirectSpaceState2D.IntersectPoint.
By changing various properties of this object, such as the point position, you can configure the parameters for PhysicsDirectSpaceState2D.IntersectPoint.
Declarations checked against C# SDK 1.0.0. Expand a name to see declarations and documentation.
Constructors1
PhysicsPointQueryParameters2DConstructor
public PhysicsPointQueryParameters2D();Properties6
CanvasInstanceIdProperty
public ulong CanvasInstanceId { get; set; }If different from 0, restricts the query to a specific canvas layer specified by its instance ID. See ReckfellObject.GetInstanceId.
If 0, restricts the query to the Viewport's default canvas layer.
CollideWithAreasProperty
public bool CollideWithAreas { get; set; }If true, the query will take Area2Ds into account.
CollideWithBodiesProperty
public bool CollideWithBodies { get; set; }If true, the query will take PhysicsBody2Ds into account.
CollisionMaskProperty
public uint CollisionMask { get; set; }The physics layers the query will detect (as a bitmask). By default, all collision layers are detected. See Collision layers and masks in the documentation for more information.
ExcludeProperty
public Reckfell.Collections.Array<Rid> Exclude { get; set; }The list of object Rids that will be excluded from collisions. Use CollisionObject2D.GetRid to get the Rid associated with a CollisionObject2D-derived node.
Note: The returned array is copied and any changes to it will not update the original property value. To update the value you need to modify the returned array, and then assign it to the property again.
PositionProperty
public Vector2 Position { get; set; }The position being queried for, in global coordinates.
Methods12
GetCanvasInstanceIdulong
public ulong GetCanvasInstanceId();ulongGetCollisionMaskuint
public uint GetCollisionMask();uintGetExcludeReckfell.Collections.Array<Rid>
public Reckfell.Collections.Array<Rid> GetExclude();Reckfell.Collections.Array<Rid>GetPositionVector2
public Vector2 GetPosition();Vector2IsCollideWithAreasEnabledbool
public bool IsCollideWithAreasEnabled();boolIsCollideWithBodiesEnabledbool
public bool IsCollideWithBodiesEnabled();boolSetCanvasInstanceIdvoid
public void SetCanvasInstanceId(ulong canvasInstanceId);| Name | Type | Default |
|---|---|---|
canvasInstanceId | ulong | — |
SetCollideWithAreasvoid
public void SetCollideWithAreas(bool enable);| Name | Type | Default |
|---|---|---|
enable | bool | — |
SetCollideWithBodiesvoid
public void SetCollideWithBodies(bool enable);| Name | Type | Default |
|---|---|---|
enable | bool | — |
SetCollisionMaskvoid
public void SetCollisionMask(uint collisionMask);| Name | Type | Default |
|---|---|---|
collisionMask | uint | — |
SetExcludevoid
public void SetExclude(Reckfell.Collections.Array<Rid> exclude);| Name | Type | Default |
|---|---|---|
exclude | Reckfell.Collections.Array<Rid> | — |
SetPositionvoid
public void SetPosition(Vector2 position);| Name | Type | Default |
|---|---|---|
position | Vector2 | — |