From 6d5d4805437361c9fa7eb1650a726776b20fc828 Mon Sep 17 00:00:00 2001 From: zhangqiang <657634622@qq.com> Date: Sat, 3 Jul 2021 17:46:44 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E7=BC=A5=E7=BC=88=E4=B9=8B=E6=97=85?= =?UTF-8?q?=E3=80=91=E6=8F=90=E4=BA=A44?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../UI/Fight/FightPointPassMainPanel.prefab | 4 +- .../ActivityGift/ActivityGiftManager.lua | 9 +++-- .../JourneyWithWind/JourneyWithWindPanel.lua | 38 ++++++++++++++++++- 3 files changed, 43 insertions(+), 8 deletions(-) diff --git a/Assets/ManagedResources/Prefabs/UI/Fight/FightPointPassMainPanel.prefab b/Assets/ManagedResources/Prefabs/UI/Fight/FightPointPassMainPanel.prefab index cdb872d11c..bbd0ef5d3e 100644 --- a/Assets/ManagedResources/Prefabs/UI/Fight/FightPointPassMainPanel.prefab +++ b/Assets/ManagedResources/Prefabs/UI/Fight/FightPointPassMainPanel.prefab @@ -5187,9 +5187,9 @@ RectTransform: m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5} - m_AnchoredPosition: {x: 79.74001, y: 62.900047} + m_AnchoredPosition: {x: 118.7, y: 103.1} m_SizeDelta: {x: 30, y: 30} - m_Pivot: {x: 0.5, y: 0.5} + m_Pivot: {x: 1.1134684, y: 1.1801116} --- !u!222 &603848451 CanvasRenderer: m_ObjectHideFlags: 0 diff --git a/Assets/ManagedResources/~Lua/Modules/ActivityGift/ActivityGiftManager.lua b/Assets/ManagedResources/~Lua/Modules/ActivityGift/ActivityGiftManager.lua index 76e1859d6b..1ec31bb419 100644 --- a/Assets/ManagedResources/~Lua/Modules/ActivityGift/ActivityGiftManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/ActivityGift/ActivityGiftManager.lua @@ -1290,7 +1290,7 @@ end function this.SingleJourneyWithWindRewardNoGet(curRewardTaskData) if curRewardTaskData then local dayNumConFig = ConfigManager.GetConfigData(ConfigName.ActivityRewardConfig,curRewardTaskData.missionId) - LogYellow(curRewardTaskData.missionId .. " curRewardTaskData.state "..curRewardTaskData.state.." curRewardTaskData.progress "..curRewardTaskData.progress.." JourneyWithWindDayAmount[dayNumConFig.Values[1][2]] "..JourneyWithWindDayAmount[dayNumConFig.Values[1][2]]) + -- LogYellow(curRewardTaskData.missionId .. " curRewardTaskData.state "..curRewardTaskData.state.." curRewardTaskData.progress "..curRewardTaskData.progress.." JourneyWithWindDayAmount[dayNumConFig.Values[1][2]] "..JourneyWithWindDayAmount[dayNumConFig.Values[1][2]]) if curRewardTaskData.state == 0 and dayNumConFig and curRewardTaskData.progress >= JourneyWithWindDayAmount[dayNumConFig.Values[1][2]] then return true end @@ -1339,19 +1339,20 @@ function this.GetJourneyWithWindPlayerPrefs(dayNum) if dayNum then return PlayerPrefs.GetString(PlayerManager.uid..PlayerManager.serverInfo.server_id.."JourneyWithWind"..dayNum, 0) end - return false + return 1 end function this.JourneyWithWindCurDayNoOpen() local curDay = math.ceil((CalculateSecondsNowTo_N_OClock(0) + GetTimeStamp() - PlayerManager.userCreateTime)/86400) local curJourneyWithWindAllDayConFigData = this.GetJourneyWithWindAllDayConFigData() for i = 1, #curJourneyWithWindAllDayConFigData do - if curJourneyWithWindAllDayConFigData[i].Values[1][2] <= curDay then + if curDay >= curJourneyWithWindAllDayConFigData[i].Values[1][2] then local curRedPointState = this.GetJourneyWithWindPlayerPrefs(curJourneyWithWindAllDayConFigData[i].Values[1][2]) - if curRedPointState then + if curRedPointState == 0 then return true end end end + return false end return this \ No newline at end of file diff --git a/Assets/ManagedResources/~Lua/Modules/JourneyWithWind/JourneyWithWindPanel.lua b/Assets/ManagedResources/~Lua/Modules/JourneyWithWind/JourneyWithWindPanel.lua index 06934461a7..4ed4cb0a58 100644 --- a/Assets/ManagedResources/~Lua/Modules/JourneyWithWind/JourneyWithWindPanel.lua +++ b/Assets/ManagedResources/~Lua/Modules/JourneyWithWind/JourneyWithWindPanel.lua @@ -127,7 +127,7 @@ function this.SingleDayBtnDataShow(_go,data,index) end end if not redState then - -- redState = ActivityGiftManager.GetJourneyWithWindPlayerPrefs(data.Values[1][2]) + redState = ActivityGiftManager.GetJourneyWithWindPlayerPrefs(data.Values[1][2]) == 0 end redPoint:SetActive(redState) @@ -136,6 +136,10 @@ function this.SingleDayBtnDataShow(_go,data,index) else go.transform.anchoredPosition = Vector3.New(3.05,176.09,0) end + if data.Values[1][2] == curDayIndex then + this.selected.transform:SetParent(Util.GetGameObject(go, "selectedParent").transform) + this.selected.transform.anchoredPosition = Vector3.New(4.3,9.4,0) + end Util.AddOnceClick(go, function() this.ShowDayData(data.Values[1][2]) this.selected.transform:SetParent(Util.GetGameObject(go, "selectedParent").transform) @@ -204,7 +208,36 @@ function this.ShowDayData(_curDayIndex) buyInfo.text = string.format("%s/%s",progress,curDayAllTaskConFigData[i].TaskValue[2][1]) end Util.AddOnceClick(btnJump, function() - JumpManager.GoJump(curDayAllTaskConFigData[i].Jump[1]) + if curDayAllTaskConFigData[i].SystemId == FUNCTION_OPEN_TYPE.EXPEDITION then + if ActTimeCtrlManager.SingleFuncState(FUNCTION_OPEN_TYPE.EXPEDITION) then + if #ExpeditionManager.nodeInfo <= 0 then + if ExpeditionManager.expeditionLeve == -1 then + NetManager.GetExpeditionRequest(2,function() + JumpManager.GoJump(curDayAllTaskConFigData[i].Jump[1]) + end) + else + NetManager.GetExpeditionRequest( + ExpeditionManager.expeditionLeve,function() + JumpManager.GoJump(curDayAllTaskConFigData[i].Jump[1]) + end) + end + else + JumpManager.GoJump(curDayAllTaskConFigData[i].Jump[1]) + end + NetManager.TreasureOfHeavenScoreRequest() + PlayerPrefs.SetInt(PlayerManager.uid.."ExpeditionRed",ActTimeCtrlManager.GetSerDataByTypeId(FUNCTION_OPEN_TYPE.EXPEDITION).endTime) + CheckRedPointStatus(RedPointType.OrdinaryExplore) + else + if ActTimeCtrlManager.IsQualifiled(FUNCTION_OPEN_TYPE.EXPEDITION) then + PopupTipPanel.ShowTip(Language[12183]) + else + PopupTipPanel.ShowTip(ActTimeCtrlManager.GetFuncTip(FUNCTION_OPEN_TYPE.EXPEDITION)) + end + end + else + JumpManager.GoJump(curDayAllTaskConFigData[i].Jump[1]) + end + end) end else @@ -285,6 +318,7 @@ function this.ShowDayDataActivityReward() Util.SetGray(getBtn,true) redPoint:SetActive(false) CheckRedPointStatus(RedPointType.JourneyWithWind) + this.ShowDayBtnsData() end) end) else