public static void RebuildAllUIAtlas() { int startPos = GPathStaticAPI.ProjectPath.Length; string[] files = Directory.GetFiles(Application.dataPath, "*.fnt", SearchOption.AllDirectories); if (files != null && files.Length > 0) { for (int i = 0, length = files.Length; i < length; i++) { GEditorTexturePackerImporter.DoRebuildNGUIAtlas(files[i].Substring(startPos)); } } }
public static void RebuildUIAtlas() { TextAsset selected = Selection.activeObject as TextAsset; GEditorTexturePackerImporter.DoRebuildNGUIAtlas(AssetDatabase.GetAssetPath(selected)); }