/// <summary>
        /// 取得使用者所有道具資料
        /// </summary>
        /// <param name="uid"></param>
        /// <returns></returns>
        public static async ETTask <RepeatedField <EquipmentInfo> > GetUserAllEquipmentInfo(long uid)
        {
            var list   = new RepeatedField <EquipmentInfo>();
            var listEq = new List <Equipment>();
            var result = await dbProxy.Query <Equipment>(entity => entity.uid == uid);

            for (int i = 0; i < result.Count; i++)
            {
                var equipment = (Equipment)result[i];
                if (TryGetEquipmentConfig(equipment.configId, out CharacterConfig config))
                {
                    if (config.IsStackEquipment())
                    {
                        var obj = OtherHelper.Search(listEq, entity => entity.configId == equipment.configId);
                        if (obj != null)
                        {
                            await _MergeEquipment(uid, obj, equipment);

                            continue;
                        }
                    }
                    list.Add(equipment.ToEquipmentInfo());
                    listEq.Add(equipment);
                }
            }
            return(list);
        }
        public static async ETTask <Room> CreateTeamRoom(this RoomComponent self, RoomInfo roomInfo, TeamRoomData teamRoomData)
        {
            Room room = ComponentFactory.CreateWithId <Room, RoomType>(IdGenerater.GenerateId(), RoomType.Team);

            room.SetData(roomInfo);
            room = await self.MemorySync.Create(room);

            room.AddComponent <RoomTeamComponent, TeamRoomData>(teamRoomData);
            room.AddComponent <RoomBlockComponent, Room>(room);
            var first = OtherHelper.Search(self.TeamList, r => r.Id == room.Id);

            if (first == null)
            {
                self.TeamList.Add(room);
            }
            return(room);
        }
        public static async ETTask <Room> CreateRoamingRoom(this RoomComponent self, RoomInfo roomInfo)
        {
            Room room = ComponentFactory.CreateWithId <Room, RoomType>(IdGenerater.GenerateId(), RoomType.Roaming);

            room.SetData(roomInfo);
            await self.MemorySync.Create(room);

            room.AddComponent <RoomRoamingComponent>();
            room.AddComponent <RoomBlockComponent, Room>(room);
            room.AddComponent <RoomNpcComponent>();
            var first = OtherHelper.Search(self.RoamingList, r => r.Id == room.Id);

            if (first == null)
            {
                self.RoamingList.Add(room);
                self.RoamingSettingDict.Add(roomInfo.RoadSettingId, room);
            }
            return(room);
        }