【鸿蒙阵bug 修改】
parent
d989aa5b85
commit
d55b0d58e9
|
@ -15,6 +15,7 @@ HarmonyManager.UnLoadGongMing = 0
|
||||||
--判断是否鸿蒙共享数据
|
--判断是否鸿蒙共享数据
|
||||||
local equipConfig = ConfigManager.GetConfig(ConfigName.EquipConfig)
|
local equipConfig = ConfigManager.GetConfig(ConfigName.EquipConfig)
|
||||||
local heroConfig = ConfigManager.GetConfig(ConfigName.HeroConfig)
|
local heroConfig = ConfigManager.GetConfig(ConfigName.HeroConfig)
|
||||||
|
this.tab=ConfigManager.GetConfig(ConfigName.Hongmeng)
|
||||||
HarmonyManager.TowerStartLimit = 0
|
HarmonyManager.TowerStartLimit = 0
|
||||||
HarmonyManager.equipCount = 0
|
HarmonyManager.equipCount = 0
|
||||||
this.hongmengGongMingList = {}
|
this.hongmengGongMingList = {}
|
||||||
|
@ -27,21 +28,19 @@ this.ChooseDataList = {}
|
||||||
-- 鸿蒙塔升级数据表
|
-- 鸿蒙塔升级数据表
|
||||||
local HongmengUp = ConfigManager.GetConfig(ConfigName.HongmengUp)
|
local HongmengUp = ConfigManager.GetConfig(ConfigName.HongmengUp)
|
||||||
|
|
||||||
|
local keys = nil
|
||||||
function this.InitHongMengData(hongmengGuards, hongmengHeroInfos, hongmengTablet, hongmengAdditions)
|
function this.InitHongMengData(hongmengGuards, hongmengHeroInfos, hongmengTablet, hongmengAdditions)
|
||||||
-- body
|
-- body
|
||||||
this.hongmengGuards = hongmengGuards
|
this.hongmengGuards = hongmengGuards
|
||||||
LogGreen("hongmengGuards",#this.hongmengGuards)
|
LogGreen("hongmengGuards",#this.hongmengGuards)
|
||||||
|
|
||||||
this.TowerStartLimit = tonumber(string.split(ConfigManager.GetConfigData(ConfigName.SpecialConfig,101).Value,"#")[2])
|
this.TowerStartLimit = tonumber(string.split(ConfigManager.GetConfigData(ConfigName.SpecialConfig,101).Value,"#")[2])
|
||||||
-- LogGreen("TowerStartLimit"..HarmonyManager.TowerStartLimit)
|
-- LogGreen("TowerStartLimit"..HarmonyManager.TowerStartLimit)
|
||||||
this.hongmengHeroInfos = hongmengHeroInfos
|
this.hongmengHeroInfos = hongmengHeroInfos
|
||||||
|
|
||||||
|
keys = GameDataBase.SheetBase.GetKeys(this.tab)
|
||||||
|
|
||||||
for i = 1, #this.hongmengGuards do
|
for i = 1, #this.hongmengGuards do
|
||||||
-- if this.hongmengGuards[i].heroId ~= "" then
|
|
||||||
-- -- body
|
|
||||||
-- LogGreen(this.hongmengGuards[i].heroId)
|
|
||||||
-- end
|
|
||||||
|
|
||||||
this.hongmengGuards[i].time = this.hongmengGuards[i].time + GetTimeStamp()
|
this.hongmengGuards[i].time = this.hongmengGuards[i].time + GetTimeStamp()
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -70,7 +69,10 @@ end
|
||||||
|
|
||||||
function this.UpdateHongMengDataGuards(hongmengGuards)
|
function this.UpdateHongMengDataGuards(hongmengGuards)
|
||||||
this.hongmengGuards = hongmengGuards
|
this.hongmengGuards = hongmengGuards
|
||||||
|
for i = 1, #this.hongmengGuards do
|
||||||
|
this.hongmengGuards[i].time = this.hongmengGuards[i].time + GetTimeStamp()
|
||||||
|
end
|
||||||
|
|
||||||
if this.hongmengTablet < this.TowerStartLimit then
|
if this.hongmengTablet < this.TowerStartLimit then
|
||||||
-- body
|
-- body
|
||||||
this:SetInitList()
|
this:SetInitList()
|
||||||
|
@ -81,6 +83,9 @@ end
|
||||||
|
|
||||||
function this.UpdateHongMengDataHeroInfos(hongmengHeroInfos)
|
function this.UpdateHongMengDataHeroInfos(hongmengHeroInfos)
|
||||||
this.hongmengHeroInfos = hongmengHeroInfos
|
this.hongmengHeroInfos = hongmengHeroInfos
|
||||||
|
for i = 1, #this.hongmengHeroInfos do
|
||||||
|
this.hongmengHeroInfos[i].time = this.hongmengHeroInfos[i].time + GetTimeStamp()
|
||||||
|
end
|
||||||
|
|
||||||
if this.hongmengTablet < this.TowerStartLimit then
|
if this.hongmengTablet < this.TowerStartLimit then
|
||||||
-- body
|
-- body
|
||||||
|
@ -532,7 +537,7 @@ function this.RefreshOpenBoxPoint()
|
||||||
-- body
|
-- body
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
if Gold > tab[#this.hongmengHeroInfos].PropPrice[2] or DemonCrystal > tab[#this.hongmengHeroInfos].MoneyPrice[2] then
|
if (Gold > tab[#this.hongmengHeroInfos].PropPrice[2] or DemonCrystal > tab[#this.hongmengHeroInfos].MoneyPrice[2]) and #this.hongmengHeroInfos < #keys then
|
||||||
return true
|
return true
|
||||||
else
|
else
|
||||||
return false
|
return false
|
||||||
|
|
|
@ -89,6 +89,7 @@ function this:InitBox()
|
||||||
--
|
--
|
||||||
|
|
||||||
local keys = GameDataBase.SheetBase.GetKeys(this.tab) --获取数据长度
|
local keys = GameDataBase.SheetBase.GetKeys(this.tab) --获取数据长度
|
||||||
|
|
||||||
this.ScrollView:SetData(keys,function (index, go)
|
this.ScrollView:SetData(keys,function (index, go)
|
||||||
local key = keys[index]
|
local key = keys[index]
|
||||||
this.SingleBoxDataShow(go, this.tab[key], index)
|
this.SingleBoxDataShow(go, this.tab[key], index)
|
||||||
|
@ -111,6 +112,7 @@ function this.RunTimerFun()
|
||||||
for key, value in pairs(ItemList) do
|
for key, value in pairs(ItemList) do
|
||||||
if value <= #HarmonyManager.hongmengHeroInfos then
|
if value <= #HarmonyManager.hongmengHeroInfos then
|
||||||
TextList[value].text = ""
|
TextList[value].text = ""
|
||||||
|
-- print("倒计时开启 .."..HarmonyManager.hongmengHeroInfos[value].time - GetTimeStamp())
|
||||||
if HarmonyManager.hongmengHeroInfos[value].time - GetTimeStamp() > 0 then
|
if HarmonyManager.hongmengHeroInfos[value].time - GetTimeStamp() > 0 then
|
||||||
|
|
||||||
if BoxList[value].activeSelf == false then
|
if BoxList[value].activeSelf == false then
|
||||||
|
@ -123,6 +125,8 @@ function this.RunTimerFun()
|
||||||
HarmonyManager.hongmengHeroInfos[value].time = 0
|
HarmonyManager.hongmengHeroInfos[value].time = 0
|
||||||
TextList[value].text = ""
|
TextList[value].text = ""
|
||||||
end
|
end
|
||||||
|
else
|
||||||
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue