GetBodyUpdateOwnerUserData(Allocator)
Get all PhysicsBody.ownerUserData assigned to each PhysicsBody returned with PhysicsWorld.bodyUpdateEvents. The Native Array returned will be of the same length and be ordered the same as the PhysicsEvents.BodyUpdateEvent returned with PhysicsWorld.bodyUpdateEvents. Any PhysicsBody that are not valid will return a default PhysicsUserData.
読み終わるまでの所要時間 1 分最終更新 21日前
Definition
- Type: Method
- Namespace: Unity.U2D.Physics
- Assembly: UnityEngine.PhysicsCore2DModule
public NativeArray<PhysicsUserData> GetBodyUpdateOwnerUserData(Allocator allocator = Allocator.Temp)
Parameters
The memory allocator to use for the results. This can only be Allocator.Temp, Allocator.TempJob or Allocator.Persistent.
Returns
Type | Description |
|---|---|
| NativeArray<PhysicsUserData> | A Native Array containing all PhysicsUserData for each PhysicsEvents.BodyUpdateEvent returned with PhysicsWorld.bodyUpdateEvents. |