Added lots of examples for editor customization

This commit is contained in:
2026-06-23 18:33:11 +02:00
parent bbb7062c5b
commit 0512201ce0
58 changed files with 920 additions and 116 deletions
@@ -0,0 +1,21 @@
using UnityEditor;
using UnityEngine;
namespace Data.Editor
{
[CustomEditor(typeof(CharacterAttributes))]
public class CharacterAttributesEditor : UnityEditor.Editor
{
public override void OnInspectorGUI()
{
base.OnInspectorGUI();
if (GUILayout.Button("Open Character Attributes Window"))
{
CharacterAttributesWindow window = (CharacterAttributesWindow)EditorWindow.GetWindow(typeof(CharacterAttributesWindow));
window.CharacterAttributesToEdit = target as CharacterAttributes;
window.Show();
}
}
}
}