[Unity] 인스펙터에 요소들 카테고리로 묶어서 표출하기
코드 using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.UI; public class InspectorFieldTest : MonoBehaviour { [System.Serializable] public class InspectorComponent { public Button createButton; public Image backgroundImage; } public InspectorComponent inspectorComponent; } 결과이미지 위 처럼 코드를 짰을 때, 관련있는 요소들끼리 묶어서 인스펙터에 보여줄 수 있도록 만들 수 있다.
2021.11.14