Beispiel #1
0
 protected override void BeforDestroy()
 {
     if (m_GameObjectPool != null)
     {
         m_GameObjectPool.RemoveAllObject(true, false);
         m_GameObjectPool = null;
     }
 }
Beispiel #2
0
        public void RemovePool(string poolName, bool destroyPrefab)
        {
            GameObjectPool pool = null;

            if (m_PoolMap.TryGetValue(poolName, out pool))
            {
                pool.RemoveAllObject(true, destroyPrefab);
                m_PoolMap.Remove(poolName);
            }
        }