Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using UnityEditor;
- using UnityEngine;
- [CustomEditor(typeof(SkillSO))]
- public class SkillSoEditor : Editor
- {
- public override void OnInspectorGUI()
- {
- SkillSO skillSo = (SkillSO)target;
- DrawDefaultInspector();
- if (GUILayout.Button("SET BUFF NAME"))
- {
- skillSo.AutoFillBuffValue();
- }
- if (GUI.changed)
- {
- EditorUtility.SetDirty(skillSo);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment