- Home /
Question by
komodor · Aug 26, 2014 at 01:21 PM ·
editor-scriptingpropertiessort
[SOLVED] sort array in component by editor script
i thought the code:
Array.Sort(target.a1);
Array.Sort(target.a2);
serializedObject.ApplyModifiedProperties();
will do it, but looks like it does not
Comment
Best Answer
Answer by komodor · Aug 26, 2014 at 01:50 PM
EditorUtility.SetDirty(target);
Array.Sort(target.a1);
Array.Sort(target.a2);
serializedObject.ApplyModifiedProperties();
Your answer
Follow this Question
Related Questions
exposed properties ignore prefab apply 0 Answers
Script for Revert Value to Prefab 1 Answer
Can you set Read/Write on an image in an Editor Script? 1 Answer
reflection propertyinfo.getvalue compiles fine but gives erros in editor 1 Answer
Auto switch max size of a selected texture in Project window 0 Answers