Odin-Inspector-系列教程—–HideInPrefabAssetsAttribute

Hide In Prefab Assets Attribute:属性所在的组件在预制体上,且预制体在为Asset(在project中)时,隐藏属性

using Sirenix.OdinInspector;
using UnityEngine;

public class HideInPrefabAssetsAttributeExample : MonoBehaviour
{
    [HideInPrefabAssets] //在Asset中且是预制体时隐藏
    public GameObject HiddenInPrefabAssets;
}

更多教程内容详见:革命性Unity 编辑器扩展工具 — Odin Inspector 系列教程

发表评论