diff --git a/lua_probject/base_project/Game/View/Family/FamilyBanDesk.lua b/lua_probject/base_project/Game/View/Family/FamilyBanDesk.lua index 435d0b76..f341c2ee 100644 --- a/lua_probject/base_project/Game/View/Family/FamilyBanDesk.lua +++ b/lua_probject/base_project/Game/View/Family/FamilyBanDesk.lua @@ -64,7 +64,7 @@ local function AddPlayer(data, self) end -- 点击弹出选择成员界面 - local view = FamilySelectNumber.New() + local view = FamilySelectNumber.New(data) view:Show(self.root._group.id, function(number) if Exists(number.uid, data.deskList) then ViewUtil.ErrorTip(-1, "设置失败,成员已经在关系中") diff --git a/lua_probject/base_project/Game/View/Family/FamilyNotice.lua b/lua_probject/base_project/Game/View/Family/FamilyNotice.lua index f38c0079..3a969db8 100644 --- a/lua_probject/base_project/Game/View/Family/FamilyNotice.lua +++ b/lua_probject/base_project/Game/View/Family/FamilyNotice.lua @@ -27,7 +27,9 @@ function M.TryShow(data, callback) local group = data.group local noticeTime = Utils.LoadLocalFile(string.format("Family_%s_notice_time", group.id)) or 0 local noticeText = Utils.LoadLocalFile(string.format("Family_%s_notice_text", group.id)) or "" - if tonumber(os.date("%Y%m%d", tonumber(noticeTime))) - tonumber(os.date("%Y%m%d", os.time())) <= -1 or (group.notice and #group.notice > 0 and noticeText ~= group.notice) then + printlog("lingmeng notice", os.date("%Y%m%d", tonumber(noticeTime)), os.date("%Y%m%d", os.time()), group.notice, + group.notice) + if group.notice and #group.notice > 0 and (tonumber(os.date("%Y%m%d", tonumber(noticeTime))) - tonumber(os.date("%Y%m%d", os.time())) <= -1 or noticeText ~= group.notice) then Utils.SaveLocalFile(string.format("Family_%s_notice_time", group.id), os.time()) Utils.SaveLocalFile(string.format("Family_%s_notice_text", group.id), group.notice) local my = M.New(data, callback) diff --git a/lua_probject/base_project/Game/View/Family/FamilyNumberRecord.lua b/lua_probject/base_project/Game/View/Family/FamilyNumberRecord.lua index 615a60c6..3279f4c8 100644 --- a/lua_probject/base_project/Game/View/Family/FamilyNumberRecord.lua +++ b/lua_probject/base_project/Game/View/Family/FamilyNumberRecord.lua @@ -36,7 +36,9 @@ function FamilyNumberRecord.New(root, page) self.text_score_majiang = self._view:GetChild('text_score_majiang') local box_type = self._view:GetChild('combBox_type') local box_mumberTime = self._view:GetChild('box_mumberTime') - local ctr_day = self._view:GetController('day') + self._ctr_day = self._view:GetController('day') + self._ctr_myday = self._view:GetController('myday') + local ctr_sort = self._view:GetController('sort') local ctr_limitDay = self._view:GetController('limitDay') @@ -71,12 +73,12 @@ function FamilyNumberRecord.New(root, page) self:NumverRankRenderer(group_id) self:NumberRecordDetailRender() - box_mumberTime.onChanged:Set(function() - self._data_leftTime = tonumber(box_mumberTime.value) - self._data_rightTime = tonumber(box_mumberTime.value) + 86399 - self:OnClickNumberRank(group_id, self.rankNumber.uid, 0) - end) - ctr_day.onChanged:Set(function(context) + -- box_mumberTime.onChanged:Set(function() + -- self._data_leftTime = tonumber(box_mumberTime.value) + -- self._data_rightTime = tonumber(box_mumberTime.value) + 86399 + -- self:OnClickNumberRank(group_id, self.rankNumber.uid, 0) + -- end) + self._ctr_day.onChanged:Set(function(context) local timeTable = os.date("*t", os.time()) timeTable.hour = 0 timeTable.min = 0 @@ -104,6 +106,17 @@ function FamilyNumberRecord.New(root, page) end) end) + self._ctr_myday.onChanged:Set(function(context) + local timeTable = os.date("*t", os.time()) + timeTable.hour = 0 + timeTable.min = 0 + timeTable.sec = 0 + local index = context.sender.selectedIndex + self._data_myleftTime = os.time(timeTable) - index * 86400 + self._data_myrightTime = os.time(timeTable) - index * 86400 + 86399 + self:OnClickNumberRank(group_id, self.rankNumber.uid, 0) + end) + ctr_sort.onChanged:Set(function(context) local index = context.sender.selectedIndex self._data_sortType = index @@ -335,13 +348,15 @@ function M:InitBoxTime() end function M:InitTimeAndSord() - local timeTable = os.date("*t", os.time()) - timeTable.hour = 0 - timeTable.min = 0 - timeTable.sec = 0 - self._data_leftTime = os.time(timeTable) - self._data_rightTime = os.time(timeTable) + 86399 - self._data_sortType = 0 + local timeTable = os.date("*t", os.time()) + timeTable.hour = 0 + timeTable.min = 0 + timeTable.sec = 0 + self._data_leftTime = os.time(timeTable) + self._data_rightTime = os.time(timeTable) + 86399 + self._data_myleftTime = os.time(timeTable) + self._data_myrightTime = os.time(timeTable) + 86399 + self._data_sortType = 0 end function M:NumverRecordRenderer() @@ -543,7 +558,11 @@ function M:NumverRankRenderer(groupId) tonumber(info.score)) obj:GetChild('btn_lookRecord').onClick:Set(function() self.ctr_numberRecord.selectedIndex = 1 - self:OnClickNumberRank(groupId, info.uid, info.round) + if self._ctr_day.selectedIndex ~= self._ctr_myday.selectedIndex then + self._ctr_myday.selectedIndex = self._ctr_day.selectedIndex + else + self:OnClickNumberRank(groupId, info.uid, info.round) + end self._view:GetChild('text_numberRecordName').text = info.nick self._view:GetChild('text_numberRecordID').text = string.format("ID:%s", info.uid) ImageLoad.Load(info.portrait, self._view:GetChild('btn_numberRecordHead')._iconObject) @@ -555,8 +574,10 @@ end function M:OnClickSortType() self.rank = {} - local fgCtr = ControllerManager.GetController(NewGroupController) - self:RecursionGetNumberRank(fgCtr, 0, 0, 0, 0) + if self._father._group.lev < 3 then + local fgCtr = ControllerManager.GetController(NewGroupController) + self:RecursionGetNumberRank(fgCtr, 0, 0, 0, 0) + end end function M:RecursionGetNumberRank(fgCtr, index, round, win, cost) @@ -597,8 +618,8 @@ function M:OnClickNumberRank(groupId, uid, round) end function M:RecursionGetNumberRecord(fgCtr, groupId, uid, index) - fgCtr:FG_GetGroupRecordSpe(groupId, GetPlatform(), uid, 0, index * 100, 100, self._data_leftTime, - self._data_rightTime, 0, + fgCtr:FG_GetGroupRecordSpe(groupId, GetPlatform(), uid, 0, index * 100, 100, self._data_myleftTime, + self._data_myrightTime, 0, function(res) pt(res) if res.ReturnCode ~= 0 then diff --git a/lua_probject/base_project/Game/View/Family/FamilySelectNumber.lua b/lua_probject/base_project/Game/View/Family/FamilySelectNumber.lua index 1acf0414..71822041 100644 --- a/lua_probject/base_project/Game/View/Family/FamilySelectNumber.lua +++ b/lua_probject/base_project/Game/View/Family/FamilySelectNumber.lua @@ -3,7 +3,7 @@ local FamilySelectNumber = {} local function search(self) local t = self.input_search.text local re = {} - for _, player in pairs(self.group.members) do + for _, player in pairs(self.group.members) do if string.match(player.nick, t) then re[#re + 1] = player end @@ -12,18 +12,24 @@ local function search(self) self.players = re end -function FamilySelectNumber.New() - setmetatable(FamilySelectNumber, { __index = BaseWindow}) - local inst = setmetatable({}, { __index = FamilySelectNumber}) +function FamilySelectNumber.New(data) + setmetatable(FamilySelectNumber, { __index = BaseWindow }) + local inst = setmetatable({}, { __index = FamilySelectNumber }) --inst._full = true inst._scale = true inst._close_destroy = true inst._full_offset = false inst._anim_pop = 0 inst._animation = false + inst._data = data + + inst._data_deskMap = {} + for k, v in pairs(data.deskList) do + inst._data_deskMap[v.uid] = 1 + end BaseWindow.init(inst, "ui://Family/com_SelectNumber") - + inst:Init() return inst @@ -43,7 +49,6 @@ function FamilySelectNumber:Show(groupId, callback) end function FamilySelectNumber:Init() - self.input_search = self._view:GetChild("input_search") self.list_number = self._view:GetChild("list_number") self.btn_search = self._view:GetChild("btn_search") @@ -58,22 +63,28 @@ function FamilySelectNumber:Init() self:Close() end) + self.list_number:SetVirtual() self.list_number.itemRenderer = function(index, obj) local i = index + 1 local player = self.players[i] --self.group.members[i] obj:GetController('lev').selectedIndex = player.lev - 1 obj:GetController('ban').selectedIndex = player.ban + obj:GetController('banDesk').selectedIndex = self._data_deskMap[player.uid] or 0 + obj:GetChild('name').emojies = EmojiDitc.EmojiesDitc obj:GetChild('name').text = player.nick obj:GetChild('id').text = string.format("ID:%s", player.uid) - obj.onClick:Set(function() - if self.callback then - self.callback(player) - end - self.callback = nil - self:Close() - end) + ImageLoad.Load(player.portrait, obj:GetChild('btn_head')._iconObject) + + if not self._data_deskMap[player.uid] then + obj:GetChild('n17').onClick:Set(function() + if self.callback then + self.callback(player) + end + self.callback = nil + self:Close() + end) + end end - end -return FamilySelectNumber \ No newline at end of file +return FamilySelectNumber diff --git a/lua_probject/base_project/Game/View/FamilyView.lua b/lua_probject/base_project/Game/View/FamilyView.lua index b38ade8b..23bd5cc2 100644 --- a/lua_probject/base_project/Game/View/FamilyView.lua +++ b/lua_probject/base_project/Game/View/FamilyView.lua @@ -234,7 +234,7 @@ function M:init(url) --ViewUtil.ErrorTip(-1,"已在家族中") return end - + self:RefNotice(group.id) self.curGroupIndex = j self:ConnetFamily(j, DataManager.groups.groupList) end) @@ -296,7 +296,6 @@ function M:Reflash() end local btn = self.list_family:GetChildAt(chooseIndex - 1) btn.onClick:Call() - self:RefNotice(DataManager.groups.groupList[chooseIndex].id) else self:JoinFamily(true) self.btn_chatRoom.visible = false @@ -624,7 +623,7 @@ function M:UpdateFamilyRoom(fgCtr, id) local list_room = self._view:GetChild('list_room') list_room:SetVirtual() local pane = list_room.scrollPane - pane.decelerationRate = 0.95 -- 惯性大 + pane.decelerationRate = 0.96 -- 惯性大 pane.bouncebackEffect = true local playList = self._group.playList local roomList = self._group.rooms @@ -988,7 +987,10 @@ function M:OnUpdate() if self._data_falshRoomTime > 0 then self._data_falshRoomTime = self._data_falshRoomTime - deltaTime else - self._flag_falshRoomTime = false + self._flag_falshRoomTime = true + self._data_falshRoomTime = 120 + local fgCtr = ControllerManager.GetController(NewGroupController) + self:UpdateFamilyRoom(fgCtr, self._group.id) self._view:GetChild('list_room').scrollPane:SetPosY(0, true) end end diff --git a/lua_probject/base_project/Game/View/Lobby/LobbyGiftDiamond.lua b/lua_probject/base_project/Game/View/Lobby/LobbyGiftDiamond.lua index a0c8c607..4bcb229c 100644 --- a/lua_probject/base_project/Game/View/Lobby/LobbyGiftDiamond.lua +++ b/lua_probject/base_project/Game/View/Lobby/LobbyGiftDiamond.lua @@ -1,4 +1,6 @@ -local LobbyGiftDiamond = {} +local LobbyGiftDiamond = { + sendPage = 1 +} local M = LobbyGiftDiamond @@ -6,7 +8,9 @@ function M.new(data, callback) setmetatable(M, { __index = BaseWindow }) local self = setmetatable({}, { __index = M }) self.class = "LobbyGiftDiamond" + self._full = true self._close_destroy = true + self._close_zone = false self._data = data self._callback = callback self:init("ui://Lobby/GiftDiamond") @@ -16,8 +20,15 @@ end function M:init(url) BaseWindow.init(self, url) + local input_id = self._view:GetChild('input_id') + + input_id.onFocusOut:Set(function() + --发送查找用户的协议 + printlog("lingmeng send find", input_id.text) + end) + self._view:GetChild('btn_center').onClick:Set(function() - local text_id = self._view:GetChild('input_id').text + local text_id = input_id.text local text_num = self._view:GetChild('input_num').text local lobbyCtr = ControllerManager.GetController(LoddyController) @@ -32,6 +43,23 @@ function M:init(url) end end) end) + + local ctr_page = self._view:GetController('page') + ctr_page.onChanged:Set(function() + if ctr_page.selectedIndex == 0 then + input_id.text = "" + self._view:GetChild('input_num').text = "" + self._view:GetChild('text_name').text = "" + self._view:GetChild('btn_head').url = "" + elseif ctr_page.selectedIndex == 1 then + + end + end) + + self._list_list = self._view:GetChild('list') + self._list_list.itemRenderer = function(index, obj) + + end end return M diff --git a/lua_probject/base_project/table/Table_Error_code.lua b/lua_probject/base_project/table/Table_Error_code.lua index eaf68ab5..e6d528cb 100644 --- a/lua_probject/base_project/table/Table_Error_code.lua +++ b/lua_probject/base_project/table/Table_Error_code.lua @@ -76,7 +76,7 @@ Table_Error_code_Map = { [1023] = { id = 1023, note = "目標玩家是合伙人" }, [1024] = { id = 1024, note = "目標玩家不是合伙人" }, [1025] = { id = 1025, note = "已被管理员禁止娱乐" }, - [1026] = { id = 1026, note = "分数已被限制,请联系管理员" }, + [1026] = { id = 1026, note = "创建亲友圈房间失败,已达到积分限制,请联系亲友圈管理员" }, [1027] = { id = 1027, note = "只能创建一个亲友圈" }, [1028] = { id = 1028, note = "亲友圈玩法必须开启积分" }, [1029] = { id = 1029, note = "还存在该玩法的房间,操作失败" }, @@ -87,7 +87,7 @@ Table_Error_code_Map = { [1034] = { id = 1034, note = "玩家在游戏中,不能下分" }, [1035] = { id = 1035, note = "奖励池积分不足" }, [1036] = { id = 1036, note = " 奖励池没提取" }, - [1037] = { id = 1037, note = "禁止同桌" }, + [1037] = { id = 1037, note = "加入房间失败、距离太近、无法加入房间" }, [1038] = { id = 1038, note = "玩法禁止娱乐" }, [1039] = { id = 1039, note = "亲友圈已关闭申请" }, [1040] = { id = 1040, note = "亲友圈已停止服务" }, diff --git a/lua_probject/extend_project/extend/poker/runfast/RunFast_GameController.lua b/lua_probject/extend_project/extend/poker/runfast/RunFast_GameController.lua index 10b4aeac..9aef4187 100644 --- a/lua_probject/extend_project/extend/poker/runfast/RunFast_GameController.lua +++ b/lua_probject/extend_project/extend/poker/runfast/RunFast_GameController.lua @@ -243,7 +243,9 @@ function M:OnPlaySuccCheck(evt_data) local player = self._room:GetPlayerBySeat(seat) local out_card_list = self:ChangeCodeByFrom(cards, true) player.hand_count = remain - self._cardCheck:InitLastCard(out_card_list) + if remain ~= 0 then + self._cardCheck:InitLastCard(out_card_list) + end local card_type, number, length, plan_three_count = self:GetCardListInfo(out_card_list) player.out_card_list = self:GetSortOutCardList(out_card_list, card_type, number, plan_three_count) DispatchEvent(self._dispatcher, RunFast_GameEvent.OnPlaySucc, player, remain, card_type, number, otherList, diff --git a/lua_probject/extend_project/extend/poker/runfast/RunFast_MainView.lua b/lua_probject/extend_project/extend/poker/runfast/RunFast_MainView.lua index b8aa65f4..1ed2e78a 100644 --- a/lua_probject/extend_project/extend/poker/runfast/RunFast_MainView.lua +++ b/lua_probject/extend_project/extend/poker/runfast/RunFast_MainView.lua @@ -1154,6 +1154,7 @@ function M:EventInit() _gamectr:AddEventListener(RunFast_GameEvent.OnBompScoreNew, function(...) local arg = { ... } + self._popEvent = false local scoreList = arg[1] for i = 1, #scoreList do local score = scoreList[i].pomSore @@ -1162,6 +1163,10 @@ function M:EventInit() head_info:PlayScore(score, true) head_info:UpdateScore(player.total_score) end + coroutine.start(function() + coroutine.wait(1) + self._popEvent = true + end) end) end diff --git a/lua_probject/extend_project/extend/poker/runfast/RunFast_PlayerPokerInfoView.lua b/lua_probject/extend_project/extend/poker/runfast/RunFast_PlayerPokerInfoView.lua index 9df6436f..041bc45c 100644 --- a/lua_probject/extend_project/extend/poker/runfast/RunFast_PlayerPokerInfoView.lua +++ b/lua_probject/extend_project/extend/poker/runfast/RunFast_PlayerPokerInfoView.lua @@ -349,13 +349,10 @@ function M:PlayEffect(type, callback) local y = 0 local x = 0 local width = 0 - pt("lingmeng PlayEffect1", fristXy, lastXy) - pt("lingmeng PlayEffect2", self._view_Out.xy) if type == 10 then effect = "te_liandui" y = self._view_Out.y + fristXy.y x = self._view_Out.x + (lastXy.x + fristXy.x) / 2 - pt("lingmeng PlayEffect2", x, y) elseif type == 4 then effect = "te_sandaidui" y = self._view_Out.y + fristXy.y diff --git a/wb_new_ui/assets/Family/NumberList/com_numberList.xml b/wb_new_ui/assets/Family/NumberList/com_numberList.xml index 0ea09183..7468a173 100644 --- a/wb_new_ui/assets/Family/NumberList/com_numberList.xml +++ b/wb_new_ui/assets/Family/NumberList/com_numberList.xml @@ -41,9 +41,6 @@ - - - diff --git a/wb_new_ui/assets/Family/NumberRecord/comp_numberRecord.xml b/wb_new_ui/assets/Family/NumberRecord/comp_numberRecord.xml index 4542d21a..4f7f5f66 100644 --- a/wb_new_ui/assets/Family/NumberRecord/comp_numberRecord.xml +++ b/wb_new_ui/assets/Family/NumberRecord/comp_numberRecord.xml @@ -6,6 +6,7 @@ + @@ -23,7 +24,7 @@ - + diff --git a/wb_new_ui/assets/Family/SelectNumber/Component/c_numberChild_select.xml b/wb_new_ui/assets/Family/SelectNumber/Component/c_numberChild_select.xml new file mode 100644 index 00000000..1b06169d --- /dev/null +++ b/wb_new_ui/assets/Family/SelectNumber/Component/c_numberChild_select.xml @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +