少年修仙传客户端基础资源
hch
2023-07-26 6794bb89cb6a5116964724cf20e189f5a7ee8a15
0312 资源 Mob文件夹改名Gmodels,鸿蒙系统下Mob会被当作缓存清理
7个文件已修改
84 ■■■■ 已修改文件
Assets/Editor/Actor/ActorEditor.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Assets/Editor/Actor/ModelResourcesBuilder.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Assets/Editor/Actor/ResourcesBuilder.cs 42 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Assets/Editor/Tool/AssetBundleBuildExtersion.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Assets/Editor/Tool/ClientPackage.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Assets/Editor/Tool/ClientPackage_Standalone.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Assets/Editor/Tool/UpdateAssetBundleName.cs 30 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Assets/Editor/Actor/ActorEditor.cs
@@ -244,7 +244,7 @@
    private void ReAssetBundleName()
    {
        string _path = Application.dataPath + "/ResourcesOut/Mob";
        string _path = Application.dataPath + "/ResourcesOut/Gmodels";
        m_Path.Clear();
        GetFileList(_path);
@@ -257,7 +257,7 @@
        {
            int _length = 0;
            _assetPath = _filePath.Substring(_path.IndexOf("Assets"));
            _temp = _filePath.Substring(_filePath.IndexOf("Mob") + 4);
            _temp = _filePath.Substring(_filePath.IndexOf("Gmodels") + 8);
            if (_filePath.Contains("CreateRole"))
            {
Assets/Editor/Actor/ModelResourcesBuilder.cs
@@ -108,7 +108,7 @@
        string _originalePath = string.Format("Assets/ART/Role/{0}/Materials/{1}.mat", path, assetName);
        var _old = AssetDatabase.LoadAssetAtPath<Material>(_originalePath);
        var _material = Object.Instantiate(_old);
        AssetDatabase.CreateAsset(_material, "Assets/ResourcesOut/Mob/" + path + "/Materials/" + assetName + ".mat");
        AssetDatabase.CreateAsset(_material, "Assets/ResourcesOut/Gmodels/" + path + "/Materials/" + assetName + ".mat");
        var _importer = AssetImporter.GetAtPath(AssetDatabase.GetAssetPath(_material));
        _importer.assetBundleName = ResourcesPath.MOB_FOLDER_NAME
            + (InstanceResourcesLoader.raceSuffix + bunedleName).ToLower();
Assets/Editor/Actor/ResourcesBuilder.cs
@@ -158,16 +158,16 @@
            _originalAssetPath = string.Format("Assets/ART/Role/{0}/{1}.FBX", path, resName);
        }
        string _absAssetPath = string.Format("{0}Mob/{1}{2}.prefab", ResourcesPath.ResourcesOutPath, suffix, _tempPrefabName);
        string _assetPath = string.Format("{0}Mob/{1}{2}.prefab", ResourcesPath.ResourcesOutAssetPath, suffix, _tempPrefabName);
        string _absAssetPath = string.Format("{0}Gmodels/{1}{2}.prefab", ResourcesPath.ResourcesOutPath, suffix, _tempPrefabName);
        string _assetPath = string.Format("{0}Gmodels/{1}{2}.prefab", ResourcesPath.ResourcesOutAssetPath, suffix, _tempPrefabName);
        string _acAbsAssetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, path, AnimatorControllerLoader.controllerSuffix, path);
        string _acAssetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, path, AnimatorControllerLoader.controllerSuffix, path);
        string _acAbsAssetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, path, AnimatorControllerLoader.controllerSuffix, path);
        string _acAssetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, path, AnimatorControllerLoader.controllerSuffix, path);
        if (!outName.Equals(resName))
        {
            _acAbsAssetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, path, AnimatorControllerLoader.controllerSuffix, outName);
            _acAssetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, path, AnimatorControllerLoader.controllerSuffix, outName);
            _acAbsAssetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, path, AnimatorControllerLoader.controllerSuffix, outName);
            _acAssetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, path, AnimatorControllerLoader.controllerSuffix, outName);
        }
        if (string.IsNullOrEmpty(_absOriginalePath))
@@ -383,7 +383,7 @@
            return;
        }
        string _configPath = ResourcesPath.ResourcesOutAssetPath + "Mob/" + configName + ".asset";
        string _configPath = ResourcesPath.ResourcesOutAssetPath + "Gmodels/" + configName + ".asset";
        HorseEffectConfig _horseEffectConfig = AssetDatabase.LoadAssetAtPath<HorseEffectConfig>(_configPath);
        if (_horseEffectConfig == null
         || _horseEffectConfig.effectConfigList == null
@@ -477,8 +477,8 @@
    {
        string _absOriginaleDirectory = string.Format("{0}/ART/Role/{1}", Application.dataPath, path);
        string _assetOriginalDirectory = string.Format("Assets/ART/Role/{0}", path);
        string _absAssetDirectory = string.Format("{0}/ResourcesOut/Mob/{1}/AnimationClips", Application.dataPath, path);
        string _assetDirectory = string.Format("Assets/ResourcesOut/Mob/{0}/AnimationClips", path);
        string _absAssetDirectory = string.Format("{0}/ResourcesOut/Gmodels/{1}/AnimationClips", Application.dataPath, path);
        string _assetDirectory = string.Format("Assets/ResourcesOut/Gmodels/{0}/AnimationClips", path);
        if (!Directory.Exists(_absOriginaleDirectory))
        {
@@ -569,35 +569,35 @@
            outName = resName;
        }
        string _absAssetPath = string.Format("{0}Mob/{1}", ResourcesPath.ResourcesOutPath, outName);
        string _absAssetPath = string.Format("{0}Gmodels/{1}", ResourcesPath.ResourcesOutPath, outName);
        if (!Directory.Exists(_absAssetPath))
        {
            Directory.CreateDirectory(_absAssetPath);
        }
        _absAssetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, outName, AnimatorControllerLoader.controllerSuffix, outName);
        string _assetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, outName, AnimatorControllerLoader.controllerSuffix, outName);
        _absAssetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, outName, AnimatorControllerLoader.controllerSuffix, outName);
        string _assetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, outName, AnimatorControllerLoader.controllerSuffix, outName);
        if (templeName.Equals("Temple_AnimatorController_BossShow"))
        {
            _absAssetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, resName, AnimatorControllerLoader.controllerShowSuffix, resName);
            _assetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, resName, AnimatorControllerLoader.controllerShowSuffix, resName);
            _absAssetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, resName, AnimatorControllerLoader.controllerShowSuffix, resName);
            _assetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, resName, AnimatorControllerLoader.controllerShowSuffix, resName);
        }
        if (templeName.Equals("Temple_AnimatorController_Realm"))
        {
            _absAssetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, resName, AnimatorControllerLoader.controllerRealmSuffix, resName);
            _assetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, resName, AnimatorControllerLoader.controllerRealmSuffix, resName);
            _absAssetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, resName, AnimatorControllerLoader.controllerRealmSuffix, resName);
            _assetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, resName, AnimatorControllerLoader.controllerRealmSuffix, resName);
        }
        if (templeName.Equals("Temple_AnimatorController_UI"))
        {
            _absAssetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, outName, AnimatorControllerLoader.controllerUISuffix, outName);
            _assetPath = string.Format("{0}Mob/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, outName, AnimatorControllerLoader.controllerUISuffix, outName);
            _absAssetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutPath, outName, AnimatorControllerLoader.controllerUISuffix, outName);
            _assetPath = string.Format("{0}Gmodels/{1}/{2}{3}.controller", ResourcesPath.ResourcesOutAssetPath, outName, AnimatorControllerLoader.controllerUISuffix, outName);
        }
        string _templePath = string.Format("{0}Mob/{1}.controller", ResourcesPath.ResourcesOutPath, templeName);
        string _templePath = string.Format("{0}Gmodels/{1}.controller", ResourcesPath.ResourcesOutPath, templeName);
        if (File.Exists(_absAssetPath))
        {
@@ -628,7 +628,7 @@
        // 读取配置文件
        string _configPath = StringUtility.Contact(ResourcesPath.ResourcesOutAssetPath,
                                                  "mob/",
                                                  "gmodels/",
                                                  configName,
                                                  ".asset");
@@ -729,7 +729,7 @@
    {
        string _assetPath = StringUtility.Contact(ResourcesPath.ResourcesOutAssetPath,
                                                 "mob/",
                                                 "gmodels/",
                                                  modelName,
                                                 "/AnimationClips/",
                                                 clipName,
Assets/Editor/Tool/AssetBundleBuildExtersion.cs
@@ -16,7 +16,7 @@
            for (int i = 0; i < assetBundles.Length; i++)
            {
                var bundleName = assetBundles[i];
                if (bundleName.StartsWith("mob") || bundleName.StartsWith("effect") || bundleName.StartsWith("graphic"))
                if (bundleName.StartsWith("gmodels") || bundleName.StartsWith("effect") || bundleName.StartsWith("graphic"))
                {
                    targetAssetBundles.Add(bundleName);
                }
Assets/Editor/Tool/ClientPackage.cs
@@ -187,7 +187,7 @@
            var excludeFileFullNames = new List<string>();
            var tempFiles = new List<FileInfo>();
            FileExtersion.GetAllDirectoryFileInfos(StringUtility.Contact(_assetBundlePath, "/mob"), tempFiles);
            FileExtersion.GetAllDirectoryFileInfos(StringUtility.Contact(_assetBundlePath, "/gmodels"), tempFiles);
            foreach (var file in tempFiles)
            {
                var extersion = Path.GetExtension(file.FullName);
Assets/Editor/Tool/ClientPackage_Standalone.cs
@@ -155,7 +155,7 @@
        var excludeFileFullNames = new List<string>();
        var tempFiles = new List<FileInfo>();
        FileExtersion.GetAllDirectoryFileInfos(StringUtility.Contact(assetPath, "/mob"), tempFiles);
        FileExtersion.GetAllDirectoryFileInfos(StringUtility.Contact(assetPath, "/gmodels"), tempFiles);
        foreach (var file in tempFiles)
        {
            var extersion = Path.GetExtension(file.FullName);
Assets/Editor/Tool/UpdateAssetBundleName.cs
@@ -185,16 +185,16 @@
public class UpdateMobSetting
{
    static string rootPath = Application.dataPath + "/ResourcesOut/Mob";
    static string assetPath = "Assets/ResourcesOut/Mob";
    static string createroleRoot = Application.dataPath + "/ResourcesOut/Mob/CreateRole";
    static string createroleAssetPath = "Assets/ResourcesOut/Mob/CreateRole";
    static string rootPath = Application.dataPath + "/ResourcesOut/Gmodels";
    static string assetPath = "Assets/ResourcesOut/Gmodels";
    static string createroleRoot = Application.dataPath + "/ResourcesOut/Gmodels/CreateRole";
    static string createroleAssetPath = "Assets/ResourcesOut/Gmodels/CreateRole";
    static string zsMaterialPath_Origin = Application.dataPath + "/Art/Role/A_Zs/Materials";
    static string fsMaterialPath_Origin = Application.dataPath + "/Art/Role/A_Fs/Materials";
    static string zsMaterialPath_OutPut = Application.dataPath + "/ResourcesOut/Mob/A_Zs/Materials";
    static string fsMaterialPath_OutPut = Application.dataPath + "/ResourcesOut/Mob/A_Fs/Materials";
    static string zsMaterialPath_OutPut = Application.dataPath + "/ResourcesOut/Gmodels/A_Zs/Materials";
    static string fsMaterialPath_OutPut = Application.dataPath + "/ResourcesOut/Gmodels/A_Fs/Materials";
    [MenuItem("程序/设置资源包名/更新Mob(All) AssetBundleName")]
    public static void SetAllMobAssetBundleName()
@@ -214,7 +214,7 @@
                                                 .Replace(".prefab", "")
                                                 .Replace("Prefab_Hand", "");
            importer.assetBundleName = StringUtility.Contact("mob/prefab_race", hostfix);
            importer.assetBundleName = StringUtility.Contact("gmodels/prefab_race", hostfix);
            // EditorUtility.SetDirty(importer);
        }
@@ -224,7 +224,7 @@
            var importerPath = createroleAssetPath + Path.DirectorySeparatorChar + file.Name;
            var extersion = Path.GetExtension(file.FullName);
            var importer = AssetImporter.GetAtPath(importerPath);
            importer.assetBundleName = "mob/createrole";
            importer.assetBundleName = "gmodels/createrole";
            // EditorUtility.SetDirty(importer);
        }
@@ -261,12 +261,12 @@
            if (_file.Name.StartsWith("A_Zs_Sz"))
            {
                string _abName = Path.GetFileNameWithoutExtension(_file.Name).Replace("_Dm", "");
                _importer.assetBundleName = "mob/prefab_race_" + _abName;
                _importer.assetBundleName = "gmodels/prefab_race_" + _abName;
            }
            else
            {
                string _abName = Path.GetFileNameWithoutExtension(_file.Name).Replace("_02", "").Replace("_Dm", "").Replace("_Dm_02", "");
                _importer.assetBundleName = "mob/prefab_race_" + _abName;
                _importer.assetBundleName = "gmodels/prefab_race_" + _abName;
            }
            // EditorUtility.SetDirty(_importer);
        }
@@ -280,12 +280,12 @@
            if (_file.Name.StartsWith("A_Fs_Sz"))
            {
                string _abName = Path.GetFileNameWithoutExtension(_file.Name).Replace("_Dm", "");
                _importer.assetBundleName = "mob/prefab_race_" + _abName;
                _importer.assetBundleName = "gmodels/prefab_race_" + _abName;
            }
            else
            {
                string _abName = Path.GetFileNameWithoutExtension(_file.Name).Replace("_02", "").Replace("_Dm", "").Replace("_Dm_02", "");
                _importer.assetBundleName = "mob/prefab_race_" + _abName;
                _importer.assetBundleName = "gmodels/prefab_race_" + _abName;
            }
            // EditorUtility.SetDirty(_importer);
        }
@@ -299,7 +299,7 @@
        //    var importerPath = assetPath + "/A_Zs/Materials/" + file.Name;
        //    var importer = AssetImporter.GetAtPath(importerPath);
        //    importer.assetBundleName = "mob/a_zs_materials";
        //    importer.assetBundleName = "gmodels/a_zs_materials";
        //    EditorUtility.SetDirty(importer);
        //}
@@ -309,10 +309,10 @@
        //    var importerPath = assetPath + "/A_Fs/Materials/" + file.Name;
        //    var importer = AssetImporter.GetAtPath(importerPath);
        //    importer.assetBundleName = "mob/a_fs_materials";
        //    importer.assetBundleName = "gmodels/a_fs_materials";
        //    EditorUtility.SetDirty(importer);
        //}
        DebugEx.Log("Mob资源包名更新完成!");
        DebugEx.Log("Gmodels资源包名更新完成!");
        //AssetDatabase.SaveAssets();
        //AssetDatabase.Refresh();
    }