Пример #1
0
 /// <summary>
 /// 创建指定名称的分组
 /// </summary>
 /// <param name="name"></param>
 /// <returns></returns>
 public UGOPoolGroup CreateGroup(string name)
 {
     if (!groupDic.TryGetValue(name, out UGOPoolGroup group))
     {
         group = new UGOPoolGroup(name, mgrTransform);
         groupDic.Add(name, group);
     }
     return(group);
 }
Пример #2
0
        public UGOPool CreatePool(string groupName, string assetPath, UGOTemplateType itemType, GameObject template)
        {
            UGOPoolGroup group = CreateGroup(groupName);

            return(group.CreatePool(assetPath, itemType, template));
        }
Пример #3
0
        public void DestroyPool(string groupName, string assetPath)
        {
            UGOPoolGroup group = CreateGroup(groupName);

            group.DestroyPool(assetPath);
        }