CodeSmile AssetDatabase 1.10
Unity's AssetDatabase in enjoyable, consistent, concise, convenient, comprehensible, safe, documented form.
Loading...
Searching...
No Matches

◆ CanOpenInEditor() [2/2]

static Boolean CanOpenInEditor ( EntityId entityId)
static

Returns true if the given object can be opened (edited) by the Unity editor.

Throws an exception if entityId is not an asset but an in-memory instance.

Unity marked the AssetDatabase integer instance ID overloads obsolete as a warning on 6000.3.23f1 and 6000.4.11f1 and as an error on 6000.5.10f1, and Object.GetInstanceID as a warning on 6000.4.11f1 and an error on 6000.5.10f1. They still exist in the assemblies but can no longer be called, and no non-obsolete way to turn an integer instance ID into an EntityId remains, so from Unity 6000.4 on this method takes an EntityId.

Parameters
entityIdThe EntityId of an asset object.
Returns
True if Unity can open assets of this type. False if it cannot or if entityId is not an asset.
See also