unity custom editor save changes
Code Example - unity custom editor save changes
EditorUtility.SetDirty(castedTarget);
EditorUtility.SetDirty(castedTarget);