文档

Unity Engine

Download Unity

Unity Engine

GetRefRW

Gets a safe reference to the component data.
阅读时间1 分钟最后更新于 19 天前

Definition

  • Type: Method
  • Namespace: Unity.Entities
  • Assembly: UnityEngine.EntitiesModule

GetRefRW(SystemHandle)

Gets a safe reference to the component data.
public RefRW<T> GetRefRW(SystemHandle system)

Parameters

The system handle with the referenced entity

Returns

Type

Description

RefRW<T>Returns a safe reference to the component data. Throws an exception if the component doesn't exist.

GetRefRW(Entity)

Gets a safe reference to the component data.
public RefRW<T> GetRefRW(Entity entity)

Parameters

entity

The referenced entity

Returns

Type

Description

RefRW<T>Returns a safe reference to the component data. Throws an exception if the component doesn't exist.