Esempio n. 1
0
        public static void RebuildAllFont()
        {
            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++)
                {
                    GEditorBitmapFontImporter.DoImportBitmapFont(files[i].Substring(startPos));
                }
            }
        }
Esempio n. 2
0
        public static bool CheckRebuildFont()
        {
            if (EditorApplication.isPlaying)
            {
                return(false);
            }
            TextAsset selected = Selection.activeObject as TextAsset;

            if (selected == null)
            {
                return(false);
            }
            return(GEditorBitmapFontImporter.IsFnt(AssetDatabase.GetAssetPath(selected)));
        }
Esempio n. 3
0
        public static void RebuildBitmapFont()
        {
            TextAsset selected = Selection.activeObject as TextAsset;

            GEditorBitmapFontImporter.DoImportBitmapFont(AssetDatabase.GetAssetPath(selected));
        }