Method BuildPhysicsWorldImmediate
BuildPhysicsWorldImmediate(ref SystemState, ref PhysicsWorldData, float, float3, uint)
Fill specified PhysicsWorld with bodies and joints (using entities from specified queries) and build broadphase BoundingVolumeHierarchy (run immediately on the current thread). Needs a system to to update type handles of physics-related components.
Declaration
public static void BuildPhysicsWorldImmediate(ref SystemState systemState, ref PhysicsWorldData physicsData, float timeStep, float3 gravity, uint lastSystemVersion)
Parameters
Type | Name | Description |
---|---|---|
SystemState | systemState | [in,out] State of the system. |
PhysicsWorldData | physicsData | [in,out] Information describing the physics. |
float | timeStep | The time step. |
float3 | gravity | The gravity. |
uint | lastSystemVersion | The last system version. |
BuildPhysicsWorldImmediate(ref PhysicsWorld, NativeReference<int>, in PhysicsWorldComponentHandles, float, float3, uint, EntityQuery, EntityQuery, EntityQuery)
Fill specified PhysicsWorld with bodies and joints (using entities from specified queries) and build broadphase BoundingVolumeHierarchy (run immediately on the current thread).
Declaration
public static void BuildPhysicsWorldImmediate(ref PhysicsWorld world, NativeReference<int> haveStaticBodiesChanged, in PhysicsWorldData.PhysicsWorldComponentHandles componentHandles, float timeStep, float3 gravity, uint lastSystemVersion, EntityQuery dynamicEntityGroup, EntityQuery staticEntityGroup, EntityQuery jointEntityGroup)
Parameters
Type | Name | Description |
---|---|---|
PhysicsWorld | world | [in,out] The world. |
NativeReference<int> | haveStaticBodiesChanged | [in,out] The have static bodies changed. |
PhysicsWorldData.PhysicsWorldComponentHandles | componentHandles | The component handles. |
float | timeStep | The time step. |
float3 | gravity | The gravity. |
uint | lastSystemVersion | The last system version. |
EntityQuery | dynamicEntityGroup | Group the dynamic entity belongs to. |
EntityQuery | staticEntityGroup | Group the static entity belongs to. |
EntityQuery | jointEntityGroup | Group the joint entity belongs to. |