四灵试炼修改提交
parent
d9bef4f49a
commit
ad9e76bda5
|
@ -16,7 +16,6 @@ local canHelpPower = 0
|
||||||
local rate = 0
|
local rate = 0
|
||||||
local waveId = 0
|
local waveId = 0
|
||||||
local curType = 0
|
local curType = 0
|
||||||
local configData = {}
|
|
||||||
local redTrailType = {
|
local redTrailType = {
|
||||||
[1] = RedPointType.PersonTrailHelp,
|
[1] = RedPointType.PersonTrailHelp,
|
||||||
[2] = RedPointType.BuddishTrailHelp,
|
[2] = RedPointType.BuddishTrailHelp,
|
||||||
|
@ -79,7 +78,6 @@ function this:OnShow(_parent,...)
|
||||||
friendHelpHeros = args[3]
|
friendHelpHeros = args[3]
|
||||||
myHeros = args[4]
|
myHeros = args[4]
|
||||||
this:SetMyHeightPower()
|
this:SetMyHeightPower()
|
||||||
configData = ConfigManager.GetConfigDataByDoubleKey(ConfigName.CampTowerConfig,"FloorId",waveId,"CampId",curType)
|
|
||||||
this.titleText.text = FourElementName[curType]
|
this.titleText.text = FourElementName[curType]
|
||||||
rate = tonumber(string.format("%.2f",ConfigManager.GetConfigData(ConfigName.CampTowerSetting,1).HelpFightMax / 10000))
|
rate = tonumber(string.format("%.2f",ConfigManager.GetConfigData(ConfigName.CampTowerSetting,1).HelpFightMax / 10000))
|
||||||
canHelpPower = heightPower*rate
|
canHelpPower = heightPower*rate
|
||||||
|
|
|
@ -99,6 +99,10 @@ function FourElementMonsterCampPanel:BindEvent()
|
||||||
PopupTipPanel.ShowTip("今日挑战次数不足")
|
PopupTipPanel.ShowTip("今日挑战次数不足")
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
if not ConfigManager.TryGetConfigDataByDoubleKey(ConfigName.CampTowerConfig,"CampId",curType,"FloorId",trailData.monsterWave + 1) then
|
||||||
|
PopupTipPanel.ShowTip("已通关全部层数,无法继续挑战")
|
||||||
|
return
|
||||||
|
end
|
||||||
if FormationManager.CheckFormationValid(curType + 2000) then
|
if FormationManager.CheckFormationValid(curType + 2000) then
|
||||||
MonsterCampManager.ExecuteFightBattle(trailData.monsterWave + 1 ,0,function() this:OnShow() end,curType,true)
|
MonsterCampManager.ExecuteFightBattle(trailData.monsterWave + 1 ,0,function() this:OnShow() end,curType,true)
|
||||||
else
|
else
|
||||||
|
|
|
@ -73,9 +73,7 @@ end
|
||||||
|
|
||||||
function MonsterCampMainPanel:OnShow()
|
function MonsterCampMainPanel:OnShow()
|
||||||
local totalWaves = MonsterCampManager.GetFourElementTotalWave()
|
local totalWaves = MonsterCampManager.GetFourElementTotalWave()
|
||||||
LogGreen(totalWaves.." totalWaves")
|
|
||||||
local nextWaves = SacredTreeManager.NextAttriFloor()
|
local nextWaves = SacredTreeManager.NextAttriFloor()
|
||||||
LogGreen(nextWaves.." nextWaves")
|
|
||||||
this.waveNum.text = MonsterCampManager.monsterWave
|
this.waveNum.text = MonsterCampManager.monsterWave
|
||||||
this.btnShenYingText.text = SacredTreeManager.CulAttri().."/"..#attriConfig.PropertyUnlcokLevels
|
this.btnShenYingText.text = SacredTreeManager.CulAttri().."/"..#attriConfig.PropertyUnlcokLevels
|
||||||
this.shenYingProgressText.text = string.format("四灵试炼进度:%d/%d",totalWaves,nextWaves)
|
this.shenYingProgressText.text = string.format("四灵试炼进度:%d/%d",totalWaves,nextWaves)
|
||||||
|
|
|
@ -90,7 +90,10 @@ end
|
||||||
--得到从第1层到当前层的数据
|
--得到从第1层到当前层的数据
|
||||||
function this.GetFourElementMonstersInfo(curType,curWave)
|
function this.GetFourElementMonstersInfo(curType,curWave)
|
||||||
local monsterInfo = {}
|
local monsterInfo = {}
|
||||||
local data = ConfigManager.GetConfigDataByDoubleKey(ConfigName.CampTowerConfig,"CampId",curType,"FloorId",curWave)
|
local data = ConfigManager.TryGetConfigDataByDoubleKey(ConfigName.CampTowerConfig,"CampId",curType,"FloorId",curWave)
|
||||||
|
if not data then
|
||||||
|
data = ConfigManager.TryGetConfigDataByDoubleKey(ConfigName.CampTowerConfig,"CampId",curType,"FloorId",curWave - 1)
|
||||||
|
end
|
||||||
for i = 1, curWave + data.UpLimitWave do
|
for i = 1, curWave + data.UpLimitWave do
|
||||||
local tempData = this.GetFourElementMonsterInfoByWave(curType,i)
|
local tempData = this.GetFourElementMonsterInfoByWave(curType,i)
|
||||||
if tempData then
|
if tempData then
|
||||||
|
@ -101,7 +104,7 @@ function this.GetFourElementMonstersInfo(curType,curWave)
|
||||||
end
|
end
|
||||||
|
|
||||||
function this.GetFourElementMonsterInfoByWave(curType,wave)
|
function this.GetFourElementMonsterInfoByWave(curType,wave)
|
||||||
local tempConfig = ConfigManager.GetConfigDataByDoubleKey(ConfigName.CampTowerConfig,"CampId",curType,"FloorId",wave)
|
local tempConfig = ConfigManager.TryGetConfigDataByDoubleKey(ConfigName.CampTowerConfig,"CampId",curType,"FloorId",wave)
|
||||||
if not tempConfig then
|
if not tempConfig then
|
||||||
return nil
|
return nil
|
||||||
end
|
end
|
||||||
|
|
|
@ -103,6 +103,7 @@ function this.NextAttriFloor()
|
||||||
return num
|
return num
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
return attriConfig.PropertyUnlcokLevels[#attriConfig.PropertyUnlcokLevels][2]
|
||||||
end
|
end
|
||||||
|
|
||||||
--获取当前等级加成的属性
|
--获取当前等级加成的属性
|
||||||
|
|
|
@ -120,7 +120,7 @@ function FourElementSingleWave:OnOpen()
|
||||||
else
|
else
|
||||||
x()
|
x()
|
||||||
end
|
end
|
||||||
elseif self.data.wave == self.trailData.monsterWave + 1 then
|
elseif self.data.wave == self.trailData.monsterWave + 1 then
|
||||||
if self.trailData.canFightTime > 0 then
|
if self.trailData.canFightTime > 0 then
|
||||||
UIManager.OpenPanel(UIName.FormationPanelV2, FORMATION_TYPE.FOUR_ELEMENT, self.trailData.fourElementType,self.data.wave)
|
UIManager.OpenPanel(UIName.FormationPanelV2, FORMATION_TYPE.FOUR_ELEMENT, self.trailData.fourElementType,self.data.wave)
|
||||||
-- if LengthOfTable(FormationManager.GetWuJinFormationHeroIds(self.trailData.fourElementType + 2000)) > 0 then
|
-- if LengthOfTable(FormationManager.GetWuJinFormationHeroIds(self.trailData.fourElementType + 2000)) > 0 then
|
||||||
|
|
Loading…
Reference in New Issue