기술 자료

Unity Engine

Unity Engine

GetIconForGameObject(GameObject)

Retrieves the icon for the given GameObject.
읽는 시간 1분최근 업데이트: 한 달 전

Definition

  • Type: Method
  • Namespace: UnityEditor
  • Assembly: UnityEditor
public static Texture2D GetIconForGameObject(GameObject gameObject)

Parameters

gameObject

The GameObject to get an icon for.

Returns

Type

Description

Texture2DThe icon for the GameObject.

Remarks

This method returns the icon for the GameObject, as it appears in the Hierarchy or Project Browser. Prefab instance or Asset roots have a Prefab, Prefab Mode, or Prefab Variant icon, while other GameObjects have a regular GameObject icon.