Beispiel #1
0
        public List <Fragment> GetActiveFragments()
        {
            if (this.pool == null)
            {
                return((List <Fragment>)null);
            }
            List <Fragment> fragmentList = new List <Fragment>(this.pool.Length);

            foreach (Fragment fragment in this.pool)
            {
                if (ExploderUtils.IsActive(((Component)fragment).get_gameObject()))
                {
                    fragmentList.Add(fragment);
                }
            }
            return(fragmentList);
        }
Beispiel #2
0
        /// <summary>
        /// returns list of currently active (visible) fragments
        /// </summary>
        /// <returns></returns>
        public List <Fragment> GetActiveFragments()
        {
            if (pool != null)
            {
                var list = new List <Fragment>(pool.Length);

                foreach (var fragment in pool)
                {
                    if (ExploderUtils.IsActive(fragment.gameObject))
                    {
                        list.Add(fragment);
                    }
                }

                return(list);
            }

            return(null);
        }