Example #1
0
        private void HandleRelationsByRecursive(string abName, string refAbName)
        {
            var abHash = _abManifest.GetAssetBundleHash(abName);

            if (_relations.ContainsKey(abHash))
            {
                _relations[abHash].AddReference(refAbName);
            }
            else
            {
                var relation = new AbRelation();
                relation.AddReference(refAbName);
                _relations.Add(abHash, relation);
                HandleRelationsByRecursive(abName);
            }
        }
Example #2
0
        private void HandleRelationsByRecursive(string abName)
        {
            var abHash = _abManifest.GetAssetBundleHash(abName);

            if (_relations.ContainsKey(abHash))
            {
                return;
            }

            var relation     = new AbRelation();
            var dependencies = _abManifest.GetAllDependencies(abName);

            for (int i = 0; i < dependencies.Length; i++)
            {
                relation.AddDependence(dependencies[i]);
                HandleRelationsByRecursive(dependencies[i], abName);
            }

            _relations.Add(abHash, relation);
        }