From b27dc2f3c3198189967f66ea3e6effdfb2e4d8da Mon Sep 17 00:00:00 2001 From: wangzhenxing Date: Fri, 28 Oct 2022 15:45:53 +0800 Subject: [PATCH] =?UTF-8?q?[gm]=3D=3D=3D=3D=3D=3D=3D=3Dgm=E8=BD=AC?= =?UTF-8?q?=E7=9B=98=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../FindTreasure/FindTreasureMainPanel.prefab | 4 +-- .../~Lua/Message/PlayerInfoProto_pb.lua | 13 ++++++++- .../ActivityGift/ActivityGiftManager.lua | 11 ++++++++ .../DynamicActivityManager.lua | 10 +++++++ .../FindTreasure/FindTreasureMainPanel.lua | 2 +- .../LuckyTurnTable/GMTurnTablePanel.lua | 28 ++++++------------- .../LuckyTurnTable/LuckyTurnTableManager.lua | 1 + .../Modules/Operating/GMShuaChongTeQuan.lua | 12 ++++++-- .../~Lua/Modules/Recharge/View/GiftPre.lua | 19 +++++++++++-- 9 files changed, 73 insertions(+), 27 deletions(-) diff --git a/Assets/ManagedResources/Prefabs/UI/FindTreasure/FindTreasureMainPanel.prefab b/Assets/ManagedResources/Prefabs/UI/FindTreasure/FindTreasureMainPanel.prefab index bf6dd95880..5bdd290d3f 100644 --- a/Assets/ManagedResources/Prefabs/UI/FindTreasure/FindTreasureMainPanel.prefab +++ b/Assets/ManagedResources/Prefabs/UI/FindTreasure/FindTreasureMainPanel.prefab @@ -474,7 +474,7 @@ GameObject: m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 - m_IsActive: 1 + m_IsActive: 0 --- !u!224 &1085493304771748058 RectTransform: m_ObjectHideFlags: 0 @@ -7589,7 +7589,7 @@ GameObject: m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 - m_IsActive: 1 + m_IsActive: 0 --- !u!224 &2926925386452383776 RectTransform: m_ObjectHideFlags: 0 diff --git a/Assets/ManagedResources/~Lua/Message/PlayerInfoProto_pb.lua b/Assets/ManagedResources/~Lua/Message/PlayerInfoProto_pb.lua index cad8b92811..7193733995 100644 --- a/Assets/ManagedResources/~Lua/Message/PlayerInfoProto_pb.lua +++ b/Assets/ManagedResources/~Lua/Message/PlayerInfoProto_pb.lua @@ -390,6 +390,7 @@ GETLUCKWHEELRANDREWARDRESPONSE = protobuf.Descriptor(); GETLUCKWHEELRANDREWARDRESPONSE_ACTIVITYID_FIELD = protobuf.FieldDescriptor(); GETLUCKWHEELRANDREWARDRESPONSE_DIALINFO_FIELD = protobuf.FieldDescriptor(); GETLUCKWHEELRANDREWARDRESPONSE_DROP_FIELD = protobuf.FieldDescriptor(); +GETLUCKWHEELRANDREWARDRESPONSE_ACCUMULATIVENUM_FIELD = protobuf.FieldDescriptor(); GETLUCKWHEELREQUEST = protobuf.Descriptor(); GETLUCKWHEELREQUEST_ACTIVITEID_FIELD = protobuf.FieldDescriptor(); LUCKWHEELINDICATION = protobuf.Descriptor(); @@ -4331,11 +4332,21 @@ GETLUCKWHEELRANDREWARDRESPONSE_DROP_FIELD.message_type = CommonProto_pb.DROP GETLUCKWHEELRANDREWARDRESPONSE_DROP_FIELD.type = 11 GETLUCKWHEELRANDREWARDRESPONSE_DROP_FIELD.cpp_type = 10 +GETLUCKWHEELRANDREWARDRESPONSE_ACCUMULATIVENUM_FIELD.name = "accumulativeNum" +GETLUCKWHEELRANDREWARDRESPONSE_ACCUMULATIVENUM_FIELD.full_name = ".rpc.protocols.GetLuckWheelRandRewardResponse.accumulativeNum" +GETLUCKWHEELRANDREWARDRESPONSE_ACCUMULATIVENUM_FIELD.number = 4 +GETLUCKWHEELRANDREWARDRESPONSE_ACCUMULATIVENUM_FIELD.index = 3 +GETLUCKWHEELRANDREWARDRESPONSE_ACCUMULATIVENUM_FIELD.label = 1 +GETLUCKWHEELRANDREWARDRESPONSE_ACCUMULATIVENUM_FIELD.has_default_value = false +GETLUCKWHEELRANDREWARDRESPONSE_ACCUMULATIVENUM_FIELD.default_value = 0 +GETLUCKWHEELRANDREWARDRESPONSE_ACCUMULATIVENUM_FIELD.type = 5 +GETLUCKWHEELRANDREWARDRESPONSE_ACCUMULATIVENUM_FIELD.cpp_type = 1 + GETLUCKWHEELRANDREWARDRESPONSE.name = "GetLuckWheelRandRewardResponse" GETLUCKWHEELRANDREWARDRESPONSE.full_name = ".rpc.protocols.GetLuckWheelRandRewardResponse" GETLUCKWHEELRANDREWARDRESPONSE.nested_types = {} GETLUCKWHEELRANDREWARDRESPONSE.enum_types = {} -GETLUCKWHEELRANDREWARDRESPONSE.fields = {GETLUCKWHEELRANDREWARDRESPONSE_ACTIVITYID_FIELD, GETLUCKWHEELRANDREWARDRESPONSE_DIALINFO_FIELD, GETLUCKWHEELRANDREWARDRESPONSE_DROP_FIELD} +GETLUCKWHEELRANDREWARDRESPONSE.fields = {GETLUCKWHEELRANDREWARDRESPONSE_ACTIVITYID_FIELD, GETLUCKWHEELRANDREWARDRESPONSE_DIALINFO_FIELD, GETLUCKWHEELRANDREWARDRESPONSE_DROP_FIELD, GETLUCKWHEELRANDREWARDRESPONSE_ACCUMULATIVENUM_FIELD} GETLUCKWHEELRANDREWARDRESPONSE.is_extendable = false GETLUCKWHEELRANDREWARDRESPONSE.extensions = {} GETLUCKWHEELREQUEST_ACTIVITEID_FIELD.name = "activiteId" diff --git a/Assets/ManagedResources/~Lua/Modules/ActivityGift/ActivityGiftManager.lua b/Assets/ManagedResources/~Lua/Modules/ActivityGift/ActivityGiftManager.lua index 8f8c80f045..b82a7472b8 100644 --- a/Assets/ManagedResources/~Lua/Modules/ActivityGift/ActivityGiftManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/ActivityGift/ActivityGiftManager.lua @@ -283,6 +283,17 @@ function this.GetActivityInfo(type, Id) end end +function this.SetActivityInfoProgress(type, Id,pro) + if this.mission[type] then + for _, missInfo in pairs(this.mission[type].mission) do + if missInfo.missionId == Id then + missInfo.progress=pro + end + end + end +end + + function this.GetActivityInfoByType(type) if this.mission[type] then return this.mission[type] diff --git a/Assets/ManagedResources/~Lua/Modules/DynamicActivity/DynamicActivityManager.lua b/Assets/ManagedResources/~Lua/Modules/DynamicActivity/DynamicActivityManager.lua index 5e1082a1b0..1ae5c6df80 100644 --- a/Assets/ManagedResources/~Lua/Modules/DynamicActivity/DynamicActivityManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/DynamicActivity/DynamicActivityManager.lua @@ -813,8 +813,18 @@ function this.CreatSingleData(shopData,DataTypeIndex,buyType,actType) else return nil end + _data.data = data _data.DataType = DataTypeIndex + --特权商城特殊处理 + if data.shopItemData.ShowType==17 then + LogError("shopData.goodsId==="..shopData.goodsId) + local gmConfig=ConfigManager.GetConfigDataByKey(ConfigName.GMMaster,"PackID",shopData.goodsId) + _data.data.shopItemData.Cost=gmConfig.Price + _data.data.price=gmConfig.Price[1][2] + _data.data.finalNum=gmConfig.Price[1][2] + --_data.DataType=DataType.Shop + end _data.sortId = curSortId _data.buyType = buyType return _data diff --git a/Assets/ManagedResources/~Lua/Modules/FindTreasure/FindTreasureMainPanel.lua b/Assets/ManagedResources/~Lua/Modules/FindTreasure/FindTreasureMainPanel.lua index 6f49195064..2ea58d3dd6 100644 --- a/Assets/ManagedResources/~Lua/Modules/FindTreasure/FindTreasureMainPanel.lua +++ b/Assets/ManagedResources/~Lua/Modules/FindTreasure/FindTreasureMainPanel.lua @@ -264,7 +264,7 @@ function FindTreasureMainPanel:OnShowPanelData(isSort,isTop,isAni) curVipState = 3 bool2 = false end - self.textImage:SetActive(bool1 or bool2) + self.textImage:SetActive(false) self.FindTreasureVipEffect:SetActive(curVipState > 1) --self.FindTreasureVipText.text = RefreshItemNum self.FindTreasureVipIcon.sprite = self.spLoader:LoadSprite(FindTreasureVipTypeSprite[curVipState]) diff --git a/Assets/ManagedResources/~Lua/Modules/LuckyTurnTable/GMTurnTablePanel.lua b/Assets/ManagedResources/~Lua/Modules/LuckyTurnTable/GMTurnTablePanel.lua index 8f58fc50b9..fea92279b5 100644 --- a/Assets/ManagedResources/~Lua/Modules/LuckyTurnTable/GMTurnTablePanel.lua +++ b/Assets/ManagedResources/~Lua/Modules/LuckyTurnTable/GMTurnTablePanel.lua @@ -240,6 +240,7 @@ end function this.SwitchTreasureType(treasureType) LogError("treasureType=="..treasureType) curTreasureType=treasureType + local miss=ActivityGiftManager.GetActivityInfo(treasureType,treasureType) priId=ConfigManager.GetConfigData(ConfigName.GlobalActivity,treasureType).Privilege LogError("pridi--"..priId) LuckyTurnTableManager.curTreasureType=treasureType @@ -249,7 +250,7 @@ function this.SwitchTreasureType(treasureType) local rewardConfig=ConfigManager.GetConfigDataByDoubleKey(ConfigName.DialRewardConfig,"ActivityId",treasureType,"Rank",1) local aaa="保底"..rewardConfig.MaxGoalCount.."次中超级大奖" this.infoTxt.text= aaa - this.progressTxt.text=leftTime.."/"..rewardConfig.MaxGoalCount + this.progressTxt.text=miss.progress.."/"..rewardConfig.MaxGoalCount --请求跑马灯物品数据 NetManager.GetLuckyWheelRequest(treasureType,function(msg) LuckyTurnTableManager.luckyData=msg.dialInfo[1].rewardInfo @@ -279,13 +280,11 @@ function this.SwitchTreasureType(treasureType) and leftTime >= oneData[1] then LuckyTurnTableManager.GetLuckyTurnRankRequest(treasureType,false,priId,function() PrivilegeManager.SetPrivilegeUsedTimesById(priId,oneData[1]) - --LuckyTurnTableManager.luckyTempData.dialInfo.rewardInfo[1].pos - this.SetTableTurnEffect(TableTurnType.Expedite,treasureType,1) - --this.SetPropShow(60,TreasureType.Lucky)--更新消耗道具显示 - this.RrFreshInfo() - --LuckyTurnTableManager.SetTimes(LuckyTurnTableManager.luckyTimes + 1) - --this.maxTimes.text =string.format(Language[11156],LuckyTurnTableManager.luckyTimes,maxTimesCount) + this.SetTableTurnEffect(TableTurnType.Expedite,treasureType,1) + local miss=ActivityGiftManager.GetActivityInfo(treasureType,treasureType) + this.progressTxt.text=miss.progress.."/"..rewardConfig.MaxGoalCount + this.RrFreshInfo() isPlayVideo = true this.SetTreasureBtnShow(treasureType) end) @@ -305,14 +304,12 @@ function this.SwitchTreasureType(treasureType) if LuckyTurnTableManager.GetTreasureTicketNum(treasureType)-moreData[2]>=0 and leftTime >= moreData[1] then LuckyTurnTableManager.GetLuckyTurnRankRequest(treasureType,true,priId,function() - --Log("==YSP== 幸运探宝返回的是什么"..tostring(LuckyTurnTableManager.luckyTempData)) this.SetTableTurnEffect(TableTurnType.Expedite,treasureType,1) - -- this.SetPropShow(60,treasureType)--更新消耗道具显示 PrivilegeManager.SetPrivilegeUsedTimesById(priId,moreData[1]) + local miss=ActivityGiftManager.GetActivityInfo(treasureType,treasureType) + this.progressTxt.text=miss.progress.."/"..rewardConfig.MaxGoalCount LogError("moredata[1]==="..moreData[1]) this.RrFreshInfo() - --LuckyTurnTableManager.SetTimes(LuckyTurnTableManager.luckyTimes + 15) - --this.maxTimes.text =string.format(Language[11156],LuckyTurnTableManager.luckyTimes,maxTimesCount) isPlayVideo = true this.SetTreasureBtnShow(treasureType) end) @@ -368,14 +365,6 @@ function this.SetTableTurnEffect(turnType,treasureType,pos) LuckyTurnTableManager.isCanGetWorldMessage=true end)--打开奖励弹窗 this.SetItemViewGray(LuckyTurnTableManager.luckyData)--刷新物品是否置灰 - -- elseif treasureType==TreasureType.Advanced then - -- isPlayVideo = false - -- UIManager.OpenPanel(UIName.RewardItemPopup,LuckyTurnTableManager.luckyTempData.drop,1,function() - -- this.SetTableTurnEffect(TableTurnType.Normal)--恢复转盘旋转 - -- LuckyTurnTableManager.isCanGetWorldMessage=true - -- end) - -- this.SetItemViewGray(LuckyTurnTableManager.advancedData) - -- end end,0.5,1,true) timer:Start() end) @@ -441,6 +430,7 @@ function this.SetItemViewShow(data,func) end ---设置跑马灯物品置灰 function this.SetItemViewGray(data) + local isNoGray=true for i = 1, #data do --LogError("data[i].luckId=="..data[i].luckId) if LuckyTurnTableManager.dialRewardConfig[data[i].luckId].LimitNum~=0 then diff --git a/Assets/ManagedResources/~Lua/Modules/LuckyTurnTable/LuckyTurnTableManager.lua b/Assets/ManagedResources/~Lua/Modules/LuckyTurnTable/LuckyTurnTableManager.lua index 0bb995ab16..e355dbbffa 100644 --- a/Assets/ManagedResources/~Lua/Modules/LuckyTurnTable/LuckyTurnTableManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/LuckyTurnTable/LuckyTurnTableManager.lua @@ -159,6 +159,7 @@ function this.GetLuckyTurnRankRequest(activityId,repeated,priId,func) end end end + ActivityGiftManager.SetActivityInfoProgress(activityId,activityId,msg.accumulativeNum) --for i = 1, #this.luckyData do -- Log("现数据 位置"..this.luckyData[i].pos.." luckId"..this.luckyData[i].luckId.." 已抽次数"..this.luckyData[i].luckTimes) --end diff --git a/Assets/ManagedResources/~Lua/Modules/Operating/GMShuaChongTeQuan.lua b/Assets/ManagedResources/~Lua/Modules/Operating/GMShuaChongTeQuan.lua index 113c197af8..e71a4a2c98 100644 --- a/Assets/ManagedResources/~Lua/Modules/Operating/GMShuaChongTeQuan.lua +++ b/Assets/ManagedResources/~Lua/Modules/Operating/GMShuaChongTeQuan.lua @@ -77,8 +77,16 @@ function GMShuaChongTeQuan:InitComponent() end) end end) - self.ScrollView:SetData(recharge.OpenPrivilege, function (index, go) - self:SingleDataShow(go,recharge.OpenPrivilege[index],lv) + local list=recharge.OpenPrivilege + local newList={} + for i = 1, #list do + local config=ConfigManager.GetConfigData(ConfigName.PrivilegeTypeConfig,list[i]) + if config.isShowName==1 then + table.insert(newList,list[i]) + end + end + self.ScrollView:SetData(newList, function (index, go) + self:SingleDataShow(go,newList[index],lv) end,false) for i = 1, #rewardList do rewardList[i].gameObject:SetActive(false) diff --git a/Assets/ManagedResources/~Lua/Modules/Recharge/View/GiftPre.lua b/Assets/ManagedResources/~Lua/Modules/Recharge/View/GiftPre.lua index 5ba4c945ab..97b7fc394d 100644 --- a/Assets/ManagedResources/~Lua/Modules/Recharge/View/GiftPre.lua +++ b/Assets/ManagedResources/~Lua/Modules/Recharge/View/GiftPre.lua @@ -311,6 +311,7 @@ function GiftPre:SetType2() end function GiftPre:SetTip() + --LogError("self.data.data.shopData.goodsId=="..self.data.data.shopData.goodsId) if self.data.data.shopData.id and self.data.data.shopData.id == 20091 then if GetCurLanguage() ~= 0 then self.tip1_en:SetActive(true) @@ -341,6 +342,12 @@ function GiftPre:SetTip() elseif self.data.data.shopData.goodsId and self.data.data.shopData.goodsId == 7105 then self.tip5:SetActive(true) self.tip5Text.text = Language[12259] + elseif self.data.data.shopData.goodsId and (self.data.data.shopData.goodsId == 2301 + or self.data.data.shopData.goodsId == 2302 or self.data.data.shopData.goodsId == 2303 + or self.data.data.shopData.goodsId == 2304 ) then + self.tip5:SetActive(true) + local rechargeData=ConfigManager.GetConfigData(ConfigName.RechargeCommodityConfig,self.data.data.shopData.goodsId) + self.tip5Text.text = rechargeData.Desc end end @@ -358,6 +365,7 @@ function GiftPre:SetIsCanBuy() end end if isCanBuy == 0 then + --LogError("self.data.data.limitNum=="..self.data.data.limitNum.." self.data.data.boughtNum=="..self.data.data.boughtNum) isCanBuy = (self.data.data.limitNum - self.data.data.boughtNum > 0) and 0 or 2 if self.data.data.linkAct then isCanBuy = self.data.data.state == 0 and 0 or 2 @@ -374,13 +382,20 @@ function GiftPre:SetIcon() self.price.text = Language[10101] end else - if self.data.DataType == DataType.Shop then + --LogError("self.data.DataType=="..self.data.DataType) + self.price.text = self.data.data.price + if self.data.DataType == DataType.Shop then self.icon.gameObject:SetActive(true) self.icon.sprite = self.spLoader:LoadSprite(GetResourcePath(itemConfig[self.data.data.shopItemData.Cost[1][1]].ResourceID)) + elseif self.data.data.shopItemData.ShowType==17 then + local gmConfig=ConfigManager.GetConfigDataByKey(ConfigName.GMMaster,"PackID",self.data.data.shopData.goodsId) + self.icon.gameObject:SetActive(true) + self.icon.sprite = self.spLoader:LoadSprite(GetResourcePath(itemConfig[gmConfig.Price[1][1]].ResourceID)) + self.price.text = gmConfig.Price[1][2] else self.icon.gameObject:SetActive(false) end - self.price.text = self.data.data.price + end end