ドキュメント

Unity Engine

Unity Engine

TryGetObjectIdentifier

Tries to convert a persistent Object into an ObjectIdentifier.
読み終わるまでの所要時間 1 分最終更新 1ヶ月前

Definition

TryGetObjectIdentifier(Object, ObjectIdentifier)

Tries to convert a persistent Object into an ObjectIdentifier.
public static bool TryGetObjectIdentifier(Object targetObject, out ObjectIdentifier objectId)

Parameters

targetObject

The Object to look up.

Out parameter with the found object identifier.

Returns

Type

Description

boolTrue if an object identifier was found for the specified Object. Otherwise, false.

Remarks

Returns false if it was not possible. This can happen if the Object is a Scene Object, or was not loaded from an Object on disk.

TryGetObjectIdentifier(EntityId, ObjectIdentifier)

Tries to convert a persistent Object into an ObjectIdentifier.
public static bool TryGetObjectIdentifier(EntityId entityId, out ObjectIdentifier objectId)

Parameters

entityId

The object identifier's entity id to look up.

Out parameter with the found object identifier.

Returns

Type

Description

boolTrue if an object identifier was found for the specified entity ID. Otherwise, false.

Remarks

Returns false if it was not possible. This can happen if the Object is a Scene Object, or was not loaded from and Object on disk.