기술 자료

Unity Engine

Unity Engine

target

The object being inspected.
읽는 시간 1분최근 업데이트: 한 달 전

Definition

  • Type: Property
  • Namespace: UnityEditor
  • Assembly: UnityEditor.CoreModule
public Object target { get; set; }

Remarks

For editors that support multi-object editing, the target property should not be used inside Editor.OnInspectorGUI() since it only refers to the first of the edited objects. It should still be used in OnSceneGUI and Editor.OnPreviewGUI, which will be called once for each of the selected objects with the target property referring to each of them in turn.
Additional Resources: Editor.targets, Editor.serializedObject, Editor class.