Пример #1
0
 static public void ResisterGroupPath(
     string groupPath,
     SEULoaderType loaderType,
     SEUUnLoadType unLoadType  = SEUUnLoadType.REFCOUNT_ZERO,
     string manifestBundlePath = null,
     IPathConverter resToBundlerPathConverter = null,
     SEUBundleLoaderType bundleLoaderType     = SEUBundleLoaderType.Defualt_Memory_BundleLoader
     )
 {
     if (groupPath.EndsWith("/"))
     {
         groupPath = groupPath.Substring(0, groupPath.Length - 1);
     }
     m_ResourcePool.ResisterGroupPath(groupPath, loaderType, unLoadType, resToBundlerPathConverter, bundleLoaderType, manifestBundlePath);
 }
        internal void ResisterGroupPath(
            string groupPath,
            SEULoaderType loaderType,
            SEUUnLoadType unLoadType = SEUUnLoadType.REFCOUNT_ZERO,
            IPathConverter resToBundlerPathConverter = null,
            SEUBundleLoaderType bundleLoaderType     = SEUBundleLoaderType.Defualt_Memory_BundleLoader,
            string manifestBundlePath = null
            )
        {
            SEUResourcesPool pool = m_GroupPoolRegister.ResisterGroupPath(groupPath);

            if (pool != null)
            {
                pool.InitPool(groupPath, loaderType, unLoadType, resToBundlerPathConverter, bundleLoaderType, manifestBundlePath);
                AddGroupPool(pool);
            }
        }
        internal void InitPool(
            string groupPath,
            SEULoaderType loaderType,
            SEUUnLoadType unLoadType = SEUUnLoadType.REFCOUNT_ZERO,
            IPathConverter resToBundlerPathConverter = null,
            SEUBundleLoaderType bundleLoaderType     = SEUBundleLoaderType.Defualt_Memory_BundleLoader,
            string manifestBundlePath = null
            )
        {
            m_GroupPath  = groupPath;
            m_LoaderType = loaderType;
            m_UnloadType = unLoadType;
            m_ResourceToBundlePathConverter = resToBundlerPathConverter;
            m_ManifestPath     = manifestBundlePath;
            m_BundleLoaderType = bundleLoaderType;

            if (m_ResourceToBundlePathConverter == null)
            {
                m_ResourceToBundlePathConverter = new SEUBundlePathConverter();
            }

            Debug_InitPool();
        }
Пример #4
0
    public static SEUBundleLoader GetBundleLoader(SEUBundleLoaderType bundleLoaderType)
    {
        SEUBundleLoader bundleLoader = null;

        switch (bundleLoaderType)
        {
        case SEUBundleLoaderType.Defualt_Memory_BundleLoader:
            bundleLoader = new SEUBundleLoaderFromMemory();
            break;

        case SEUBundleLoaderType.Defualt_FromFile_BundleLoader:
            bundleLoader = new SEUBundleLoaderFromFile();
            break;

        case SEUBundleLoaderType.DGM_BundleLoader:
            bundleLoader = new DGMBundleLoader();
            break;

        default:
            Debug.LogError("Can not find BundleLoader");
            break;
        }
        return(bundleLoader);
    }