TagAttributeEditor.cs 479 B

123456789101112131415161718
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4. using UnityEditor;
  5. using KairoEngine.Core;
  6. namespace KairoEngine.Core.Editor
  7. {
  8. [CustomPropertyDrawer(typeof(TagAttribute))]
  9. class TagAttributeEditor : PropertyDrawer
  10. {
  11. public override void OnGUI(Rect position, SerializedProperty property, GUIContent label)
  12. {
  13. property.stringValue = EditorGUI.TagField(position, label, property.stringValue);
  14. }
  15. }
  16. }