You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
447 B
C#
17 lines
447 B
C#
using UnityEngine;
|
|
using UnityEditor;
|
|
|
|
namespace NaughtyAttributes.Editor
|
|
{
|
|
[CustomPropertyDrawer(typeof(AllowNestingAttribute))]
|
|
public class AllowNestingPropertyDrawer : PropertyDrawerBase
|
|
{
|
|
protected override void OnGUI_Internal(Rect rect, SerializedProperty property, GUIContent label)
|
|
{
|
|
EditorGUI.BeginProperty(rect, label, property);
|
|
EditorGUI.PropertyField(rect, property, label, true);
|
|
EditorGUI.EndProperty();
|
|
}
|
|
}
|
|
}
|