Merge branch '0功能/本周版本优化内容' of http://60.1.1.230/gaoxin/JL_Client into 0功能/本周版本优化内容
commit
a41f5c524f
|
@ -44,6 +44,7 @@ local _amb_enabled = true
|
||||||
|
|
||||||
local _backgroundSound = {}
|
local _backgroundSound = {}
|
||||||
local _backgroundRes
|
local _backgroundRes
|
||||||
|
local _backgroundResOld
|
||||||
|
|
||||||
local _AmbientChannel = {}
|
local _AmbientChannel = {}
|
||||||
local _AmbientRes
|
local _AmbientRes
|
||||||
|
@ -425,7 +426,7 @@ function SoundManager.PlayMusic(resName, isFade, callback)
|
||||||
if not _backgroundSound then return end
|
if not _backgroundSound then return end
|
||||||
local audioUnit = _backgroundSound[1]
|
local audioUnit = _backgroundSound[1]
|
||||||
if not audioUnit then return end
|
if not audioUnit then return end
|
||||||
|
_backgroundResOld = _backgroundRes
|
||||||
_backgroundRes = resName
|
_backgroundRes = resName
|
||||||
|
|
||||||
local function _SetTimer()
|
local function _SetTimer()
|
||||||
|
@ -462,6 +463,9 @@ function SoundManager.StopMusic()
|
||||||
_backgroundRes = nil
|
_backgroundRes = nil
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function SoundManager.PlayOldMusic()
|
||||||
|
SoundManager.PlayMusic(_backgroundResOld)
|
||||||
|
end
|
||||||
---=============================环境音效============================================
|
---=============================环境音效============================================
|
||||||
function SoundManager.PlayAmbient(resName)
|
function SoundManager.PlayAmbient(resName)
|
||||||
if not resName then return end
|
if not resName then return end
|
||||||
|
|
|
@ -362,6 +362,7 @@ GameEvent = {
|
||||||
OnGuessDataUpdate = "TopMatch.OnGuessDataUpdate",
|
OnGuessDataUpdate = "TopMatch.OnGuessDataUpdate",
|
||||||
OnGuessRateUpdate = "TopMatch.OnGuessRateUpdate",
|
OnGuessRateUpdate = "TopMatch.OnGuessRateUpdate",
|
||||||
OnGuessDataUpdateShowTip = "TopMatch.OnGuessDataUpdateShowTip",
|
OnGuessDataUpdateShowTip = "TopMatch.OnGuessDataUpdateShowTip",
|
||||||
|
CommonInfoRefreshTitle = "TopMatch.CommonInfoRefreshTitle",
|
||||||
},
|
},
|
||||||
FindFairy={
|
FindFairy={
|
||||||
RefreshRedPoint="FindFairy.RefreshRedPoint",
|
RefreshRedPoint="FindFairy.RefreshRedPoint",
|
||||||
|
|
|
@ -3,6 +3,7 @@ local this = ArenaTopMatchManager
|
||||||
this.CurTabIndex = 0
|
this.CurTabIndex = 0
|
||||||
this.curIsShowDoGuessPopup = false
|
this.curIsShowDoGuessPopup = false
|
||||||
local isChange = false
|
local isChange = false
|
||||||
|
this.panelType = 1
|
||||||
local stageNameTable = {
|
local stageNameTable = {
|
||||||
[1] = 32 .. Language[10097],--强
|
[1] = 32 .. Language[10097],--强
|
||||||
[2] = 16 .. Language[10097],--强
|
[2] = 16 .. Language[10097],--强
|
||||||
|
@ -212,13 +213,13 @@ end
|
||||||
|
|
||||||
-- 获取巅峰战基础信息
|
-- 获取巅峰战基础信息
|
||||||
function this.GetBaseData()
|
function this.GetBaseData()
|
||||||
this.ChangeData(this.CurTabIndex)
|
-- this.ChangeData(this.CurTabIndex)
|
||||||
return this.baseInfo
|
return this.baseInfo
|
||||||
end
|
end
|
||||||
|
|
||||||
-- 获取对战信息
|
-- 获取对战信息
|
||||||
function this.GetBattleInfo()
|
function this.GetBattleInfo()
|
||||||
this.ChangeData(this.CurTabIndex)
|
-- this.ChangeData(this.CurTabIndex)
|
||||||
return this.myBattleInfo
|
return this.myBattleInfo
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -363,7 +364,7 @@ end
|
||||||
|
|
||||||
--- 获取竞猜战斗信息
|
--- 获取竞猜战斗信息
|
||||||
function this.GetBetBattleInfo()
|
function this.GetBetBattleInfo()
|
||||||
this.ChangeData(this.CurTabIndex)
|
-- this.ChangeData(this.CurTabIndex)
|
||||||
return this.betBattleInfo
|
return this.betBattleInfo
|
||||||
end
|
end
|
||||||
--- 获取赔率信息
|
--- 获取赔率信息
|
||||||
|
|
|
@ -162,10 +162,10 @@ end
|
||||||
|
|
||||||
--
|
--
|
||||||
function this.OpenView(index)
|
function this.OpenView(index)
|
||||||
|
ArenaTopMatchManager.panelType = index
|
||||||
this._CurLogicIndex = index
|
this._CurLogicIndex = index
|
||||||
ArenaTopMatchManager.SetCurTabIndex(index)
|
ArenaTopMatchManager.SetCurTabIndex(index)
|
||||||
this._CurTabIndex = index
|
this._CurTabIndex = index
|
||||||
|
|
||||||
local logic = this.ViewLogicList[index]
|
local logic = this.ViewLogicList[index]
|
||||||
if not logic then
|
if not logic then
|
||||||
this.ViewLogicList[index] = reimport(_ViewData[index].script)
|
this.ViewLogicList[index] = reimport(_ViewData[index].script)
|
||||||
|
|
|
@ -134,6 +134,7 @@ function this.SetInfoData(panelType, blueData, redData, textType, showScore,batt
|
||||||
elseif this.panelType == 2 then
|
elseif this.panelType == 2 then
|
||||||
this.awaitText.transform.localPosition = Vector3.New(0,515,0)
|
this.awaitText.transform.localPosition = Vector3.New(0,515,0)
|
||||||
end
|
end
|
||||||
|
Game.GlobalEvent:DispatchEvent(GameEvent.TopMatch.CommonInfoRefreshTitle)
|
||||||
end
|
end
|
||||||
|
|
||||||
-- 设置显隐
|
-- 设置显隐
|
||||||
|
@ -196,9 +197,13 @@ function this.RefreshData(showScore, textType)
|
||||||
this.myScore.gameObject:SetActive(false)
|
this.myScore.gameObject:SetActive(false)
|
||||||
end
|
end
|
||||||
-- this.textImg.sprite = Util.LoadSprite(imgRes[textType].resPath)
|
-- this.textImg.sprite = Util.LoadSprite(imgRes[textType].resPath)
|
||||||
this.textImg.sprite = Util.LoadSprite(imgRes[textType].resPath)
|
local imageTextType = textType
|
||||||
this.textImg.gameObject.transform.localPosition = imgRes[textType].pos
|
if ArenaTopMatchManager.GetIsBattleEndState(this.panelType) then
|
||||||
this.textImg.gameObject.transform.sizeDelta = imgRes[textType].size
|
imageTextType = 1
|
||||||
|
end
|
||||||
|
this.textImg.sprite = Util.LoadSprite(imgRes[imageTextType].resPath)
|
||||||
|
this.textImg.gameObject.transform.localPosition = imgRes[imageTextType].pos
|
||||||
|
this.textImg.gameObject.transform.sizeDelta = imgRes[imageTextType].size
|
||||||
-- this.textImg:SetNativeSize()
|
-- this.textImg:SetNativeSize()
|
||||||
|
|
||||||
-- 设置编队按钮状态
|
-- 设置编队按钮状态
|
||||||
|
|
|
@ -8,6 +8,8 @@ function ATM_Title:InitComponent(root)
|
||||||
this.matchName = Util.GetGameObject(this.stagePanel, "name"):GetComponent("Text")
|
this.matchName = Util.GetGameObject(this.stagePanel, "name"):GetComponent("Text")
|
||||||
this.freshTime = Util.GetGameObject(this.stagePanel, "time"):GetComponent("Text")
|
this.freshTime = Util.GetGameObject(this.stagePanel, "time"):GetComponent("Text")
|
||||||
this.timeType = Util.GetGameObject(this.stagePanel, "timelab"):GetComponent("Text")
|
this.timeType = Util.GetGameObject(this.stagePanel, "timelab"):GetComponent("Text")
|
||||||
|
this.freshTimeGo = Util.GetGameObject(this.stagePanel, "time")
|
||||||
|
this.timeTypeGO = Util.GetGameObject(this.stagePanel, "timelab")
|
||||||
|
|
||||||
this.integralPanel = Util.GetGameObject(root.transform, "ImgIntegral")
|
this.integralPanel = Util.GetGameObject(root.transform, "ImgIntegral")
|
||||||
this.score = Util.GetGameObject(this.integralPanel, "integral"):GetComponent("Text")
|
this.score = Util.GetGameObject(this.integralPanel, "integral"):GetComponent("Text")
|
||||||
|
@ -37,11 +39,13 @@ end
|
||||||
--添加事件监听(用于子类重写)
|
--添加事件监听(用于子类重写)
|
||||||
function ATM_Title:AddListener()
|
function ATM_Title:AddListener()
|
||||||
Game.GlobalEvent:AddEvent(GameEvent.TopMatch.OnTopMatchDataUpdate, this.RefreshBaseShow)
|
Game.GlobalEvent:AddEvent(GameEvent.TopMatch.OnTopMatchDataUpdate, this.RefreshBaseShow)
|
||||||
|
Game.GlobalEvent:AddEvent(GameEvent.TopMatch.CommonInfoRefreshTitle, this.RefreshBaseShow)
|
||||||
end
|
end
|
||||||
|
|
||||||
--移除事件监听(用于子类重写)
|
--移除事件监听(用于子类重写)
|
||||||
function ATM_Title:RemoveListener()
|
function ATM_Title:RemoveListener()
|
||||||
Game.GlobalEvent:RemoveEvent(GameEvent.TopMatch.OnTopMatchDataUpdate, this.RefreshBaseShow)
|
Game.GlobalEvent:RemoveEvent(GameEvent.TopMatch.OnTopMatchDataUpdate, this.RefreshBaseShow)
|
||||||
|
Game.GlobalEvent:RemoveEvent(GameEvent.TopMatch.CommonInfoRefreshTitle, this.RefreshBaseShow)
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -90,7 +94,12 @@ function this.RefreshBaseShow()
|
||||||
local tmData = ArenaTopMatchManager.GetBaseData()
|
local tmData = ArenaTopMatchManager.GetBaseData()
|
||||||
local isJoin = tmData.joinState == 1
|
local isJoin = tmData.joinState == 1
|
||||||
local titleName, stageName, stateName = ArenaTopMatchManager.GetCurTopMatchName()
|
local titleName, stageName, stateName = ArenaTopMatchManager.GetCurTopMatchName()
|
||||||
|
-- this.freshTimeGo:SetActive(true)
|
||||||
|
-- this.timeTypeGO:SetActive(true)
|
||||||
|
-- if ArenaTopMatchManager.panelType <= 2 then
|
||||||
|
-- this.freshTimeGo:SetActive(not ArenaTopMatchManager.GetIsBattleEndState(ArenaTopMatchManager.panelType))
|
||||||
|
-- this.timeTypeGO:SetActive(not ArenaTopMatchManager.GetIsBattleEndState(ArenaTopMatchManager.panelType))
|
||||||
|
-- end
|
||||||
if not isOpen then
|
if not isOpen then
|
||||||
if tmData.progress == -2 then
|
if tmData.progress == -2 then
|
||||||
this.matchName.text = " "..titleName
|
this.matchName.text = " "..titleName
|
||||||
|
|
|
@ -75,8 +75,15 @@ function GuildCarDelayLootPopup:OnShow()
|
||||||
this.myScore.text = CarChallenegList.myScore > 0 and CarChallenegList.myScore or Language[10148]
|
this.myScore.text = CarChallenegList.myScore > 0 and CarChallenegList.myScore or Language[10148]
|
||||||
end
|
end
|
||||||
this.emptyObj:SetActive(not CarChallenegList.carChallengeItem or #CarChallenegList.carChallengeItem <= 0)
|
this.emptyObj:SetActive(not CarChallenegList.carChallengeItem or #CarChallenegList.carChallengeItem <= 0)
|
||||||
this.ScrollView:SetData(CarChallenegList.carChallengeItem, function (index, go)
|
local carChallengeItem = {}
|
||||||
this.SingleInfoDataShow(go, CarChallenegList.carChallengeItem[index])
|
if CarChallenegList.carChallengeItem and #CarChallenegList.carChallengeItem > 0 then
|
||||||
|
for i = 1, #CarChallenegList.carChallengeItem do
|
||||||
|
table.insert(carChallengeItem,CarChallenegList.carChallengeItem[i])
|
||||||
|
end
|
||||||
|
table.sort(carChallengeItem, function(a,b) return a.rank < b.rank end)
|
||||||
|
end
|
||||||
|
this.ScrollView:SetData(carChallengeItem, function (index, go)
|
||||||
|
this.SingleInfoDataShow(go, carChallengeItem[index])
|
||||||
end)
|
end)
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
|
@ -77,6 +77,7 @@ end
|
||||||
|
|
||||||
--界面关闭时调用(用于子类重写)
|
--界面关闭时调用(用于子类重写)
|
||||||
function RankingSingleListPanel:OnClose()
|
function RankingSingleListPanel:OnClose()
|
||||||
|
SoundManager.PlayOldMusic()
|
||||||
RankingManager.isRequest=0
|
RankingManager.isRequest=0
|
||||||
this.noneImage:SetActive(false)
|
this.noneImage:SetActive(false)
|
||||||
-- if this.liveNode then
|
-- if this.liveNode then
|
||||||
|
|
Loading…
Reference in New Issue