Parameter | Description |
---|---|
shape | The shape used to cast through the world. |
translation | The translation relative to the shape pose defining the direction the geometry will move through the world. |
filter | The filter to control what results are returned. |
castMode | Controls how many and in what order the results are returned. |
allocator | The memory allocator to use for the results. This can only be Allocator.Temp, Allocator.TempJob or Allocator.Persistent. |
NativeArray<WorldCastResult> The query cast results. This NativeArray must be disposed of after use otherwise leaks will occur. The exception to this is if the array is empty.
Returns the shape(s) that intersect the specified shape as it is cast through the world. Neither PhysicsShape.ShapeType.Segment or PhysicsShape.ShapeType.ChainSegment shape types are supported. See QueryFilter, WorldCastMode, WorldCastResult and Allocator.