Beispiel #1
0
    public static void BatchModeExportAssets()
    {
        ysUiBundleFunc editorFunc = new ysUiBundleFunc();

        editorFunc.InitData();
        editorFunc.ExportUiPrefab();
        editorFunc.ExportAtlasPrefab();
        editorFunc.ExportTexture();
        editorFunc.ExportFont();
    }
Beispiel #2
0
    public static void SetAtlasFormat()
    {
        ysUiBundleFunc func = new ysUiBundleFunc();

        func.InitData();

        List <Texture> prefabList = func.ReadTextureList(func.data.path.AtlasDirectoryPath);

        for (int i = 0; i < prefabList.Count; i++)
        {
            TextureImporter importer = AssetImporter.GetAtPath(AssetDatabase.GetAssetPath(prefabList[i])) as TextureImporter;
            if (importer.textureFormat != TextureImporterFormat.ETC2_RGBA8)
            {
                importer.SetPlatformTextureSettings("Android", 4096, TextureImporterFormat.ETC2_RGBA8, 100, false);
                importer.SaveAndReimport();
            }
        }
    }
Beispiel #3
0
 static void InitData()
 {
     func.InitData();
 }