GetTransformLookup
Manually gets a TransformLookup object that can access a TransformRef.
阅读时间1 分钟最后更新于 5 天前
Definition
- Type: Method
- Namespace: Unity.Entities
- Assembly: UnityEngine.EntitiesModule
GetTransformLookup(bool)
Manually gets a TransformLookup object that can access a TransformRef.
public TransformLookup GetTransformLookup(bool isReadOnly = false)
Parameters
Whether the transform data is only read or is also written. Access data in a read-only fashion whenever possible.
Returns
Type | Description |
|---|---|
| TransformLookup | An array-like object that provides access to transform data, indexed by Entity. |
Remarks
Remember to call TransformLookup.Update.
Assign the returned object to a field of your Job struct so that you can access the contents of the transform in a Job. The lookup can access GameObject entities.
Additional Resources: ComponentLookup<T>
GetTransformLookup(bool, bool)
Manually gets a TransformLookup object that can access a TransformRef, optionally excluding the transforms of GameObject entities.
public TransformLookup GetTransformLookup(bool isReadOnly, bool excludeGameObjects)
Parameters
Returns
Type | Description |
|---|---|
| TransformLookup | An array-like object that provides access to transform data, indexed by Entity. |
Remarks
Remember to call TransformLookup.Update.