public static void AllUnloadAssets()
 {
     BattleObjectPooler.CheckAndRemoveNull();
     foreach (KeyValuePair <string, List <HitEffectParams> > keyValuePair in BattleObjectPooler.hitEffectParamsCache)
     {
         foreach (HitEffectParams hitEffectParams in keyValuePair.Value)
         {
             if (hitEffectParams.gameObject != null)
             {
                 UnityEngine.Object.Destroy(hitEffectParams.gameObject);
             }
         }
     }
     BattleObjectPooler.hitEffectParamsCache.Clear();
     foreach (KeyValuePair <string, List <AlwaysEffectParams> > keyValuePair2 in BattleObjectPooler.alwaysEffectParamsCache)
     {
         foreach (AlwaysEffectParams alwaysEffectParams in keyValuePair2.Value)
         {
             if (alwaysEffectParams.gameObject != null)
             {
                 UnityEngine.Object.Destroy(alwaysEffectParams.gameObject);
             }
         }
     }
     BattleObjectPooler.alwaysEffectParamsCache.Clear();
     Resources.UnloadUnusedAssets();
     GC.Collect();
 }
 public static void CallInitialize()
 {
     if (!BattleObjectPooler.onInitialized)
     {
         BattleObjectPooler.Initialize();
         BattleObjectPooler.onInitialized = true;
     }
     BattleObjectPooler.CheckAndRemoveNull();
 }
 public static void SetAllDeactive()
 {
     BattleObjectPooler.CheckAndRemoveNull();
     foreach (KeyValuePair <string, List <HitEffectParams> > keyValuePair in BattleObjectPooler.hitEffectParamsCache)
     {
         foreach (HitEffectParams hitEffectParams in keyValuePair.Value)
         {
             hitEffectParams.transform.SetParent(BattleObjectPooler.cacheRoot);
             hitEffectParams.gameObject.SetActive(false);
         }
     }
     foreach (KeyValuePair <string, List <AlwaysEffectParams> > keyValuePair2 in BattleObjectPooler.alwaysEffectParamsCache)
     {
         foreach (AlwaysEffectParams alwaysEffectParams in keyValuePair2.Value)
         {
             alwaysEffectParams.transform.SetParent(BattleObjectPooler.cacheRoot);
             alwaysEffectParams.gameObject.SetActive(false);
         }
     }
 }