private PoolPrefab GetOrAddPoolPrefabComponent(GameObject obj)
        {
            PoolPrefab o = obj.GetComponent <PoolPrefab>();

            if (o == null)
            {
                o = obj.AddComponent <PoolPrefab>();
            }
            return(o);
        }
示例#2
0
        public static void Revert(GameObject instance)
        {
            PoolPrefab poolPrefab = instance.GetComponent <PoolPrefab>();

            Revert(poolPrefab.SourcePrefab, instance);
        }