文档

Unity Engine

Unity Engine

NotEditable

The object is not editable in the Inspector.
阅读时间1 分钟最后更新于 1 个月前

Definition

  • Type: Field
  • Namespace: UnityEngine
  • Assembly: UnityEngine.CoreModule
NotEditable = 8

Examples

using UnityEngine;public class Example : MonoBehaviour{ // Create a plane and dont let it be modificable in the Inspector // nor in the Sceneview. void Start() { GameObject createdGO = GameObject.CreatePrimitive(PrimitiveType.Plane); createdGO.hideFlags = HideFlags.NotEditable; }}