public virtual void Initialize <T>(ResourceCacheMask mask, Dictionary <int, ResourceConfig <T> > configs, bool cacheOn = true) where T : GameDataMap <int, T>, new() { ResourceCachePool pool = null; foreach (ResourceConfig <T> config in configs.Values) { if (CheckLevelShow(config.Level)) { if (((int)mask & config.Mask) != 0) { if (!mPools.ContainsKey(config.ID)) { pool = new ResourceCachePool(); pool.Initialize(config, ResourceCacheBindParent.CacheUnused, GetLevel(), this, cacheOn); mPools.Add(config.ID, pool); } } } } if (IsPrintOn) { PrintTimerId = -1; PrintTimer(true); } }
public virtual void Initialize <T>(ResourceCacheMask mask, Dictionary <int, ResourceConfig <T> > configs, bool cacheOn = true) { ResourceCachePool pool = null; foreach (ResourceConfig <T> config in configs.Values) { if (CheckLevelShow(config.Level)) { if (((int)mask & config.Mask) != 0) { if (!mPools.ContainsKey(config.Id)) { pool = new ResourceCachePool(); pool.Initialize(config, ResourceCacheBindParent.CacheUnused, GetLevel(), this, cacheOn); mPools.Add(config.Id, pool); } } } } #if UNITY_EDITOR PrintTimerId = -1; PrintTimer(true); #endif }