【鸿蒙阵】跨天英雄等级为0修复
parent
982e0c5268
commit
fa5446d6d2
|
@ -476,6 +476,7 @@ TEAMONEINFO_TEAM_FIELD = protobuf.FieldDescriptor();
|
|||
TEAMONEINFO_ISAPPLYED_FIELD = protobuf.FieldDescriptor();
|
||||
TEAMONEINFO_USERTITLE_FIELD = protobuf.FieldDescriptor();
|
||||
TEAMONEINFO_PRACTICELEVEL_FIELD = protobuf.FieldDescriptor();
|
||||
TEAMONEINFO_CROSSTEAM_FIELD = protobuf.FieldDescriptor();
|
||||
MONSTERRANKINFO = protobuf.Descriptor();
|
||||
MONSTERRANKINFO_NAME_FIELD = protobuf.FieldDescriptor();
|
||||
MONSTERRANKINFO_SCORE_FIELD = protobuf.FieldDescriptor();
|
||||
|
@ -5255,11 +5256,22 @@ TEAMONEINFO_PRACTICELEVEL_FIELD.default_value = 0
|
|||
TEAMONEINFO_PRACTICELEVEL_FIELD.type = 5
|
||||
TEAMONEINFO_PRACTICELEVEL_FIELD.cpp_type = 1
|
||||
|
||||
TEAMONEINFO_CROSSTEAM_FIELD.name = "crossTeam"
|
||||
TEAMONEINFO_CROSSTEAM_FIELD.full_name = ".rpc.protocols.TeamOneInfo.crossTeam"
|
||||
TEAMONEINFO_CROSSTEAM_FIELD.number = 11
|
||||
TEAMONEINFO_CROSSTEAM_FIELD.index = 10
|
||||
TEAMONEINFO_CROSSTEAM_FIELD.label = 3
|
||||
TEAMONEINFO_CROSSTEAM_FIELD.has_default_value = false
|
||||
TEAMONEINFO_CROSSTEAM_FIELD.default_value = {}
|
||||
TEAMONEINFO_CROSSTEAM_FIELD.message_type = TEAMONETEAMINFO
|
||||
TEAMONEINFO_CROSSTEAM_FIELD.type = 11
|
||||
TEAMONEINFO_CROSSTEAM_FIELD.cpp_type = 10
|
||||
|
||||
TEAMONEINFO.name = "TeamOneInfo"
|
||||
TEAMONEINFO.full_name = ".rpc.protocols.TeamOneInfo"
|
||||
TEAMONEINFO.nested_types = {}
|
||||
TEAMONEINFO.enum_types = {}
|
||||
TEAMONEINFO.fields = {TEAMONEINFO_UID_FIELD, TEAMONEINFO_LEVEL_FIELD, TEAMONEINFO_NAME_FIELD, TEAMONEINFO_HEAD_FIELD, TEAMONEINFO_HEADFRAME_FIELD, TEAMONEINFO_GUILDNAME_FIELD, TEAMONEINFO_TEAM_FIELD, TEAMONEINFO_ISAPPLYED_FIELD, TEAMONEINFO_USERTITLE_FIELD, TEAMONEINFO_PRACTICELEVEL_FIELD}
|
||||
TEAMONEINFO.fields = {TEAMONEINFO_UID_FIELD, TEAMONEINFO_LEVEL_FIELD, TEAMONEINFO_NAME_FIELD, TEAMONEINFO_HEAD_FIELD, TEAMONEINFO_HEADFRAME_FIELD, TEAMONEINFO_GUILDNAME_FIELD, TEAMONEINFO_TEAM_FIELD, TEAMONEINFO_ISAPPLYED_FIELD, TEAMONEINFO_USERTITLE_FIELD, TEAMONEINFO_PRACTICELEVEL_FIELD, TEAMONEINFO_CROSSTEAM_FIELD}
|
||||
TEAMONEINFO.is_extendable = false
|
||||
TEAMONEINFO.extensions = {}
|
||||
MONSTERRANKINFO_NAME_FIELD.name = "name"
|
||||
|
|
|
@ -3002,8 +3002,8 @@ CHALLENGEDEATHPATHRESPONSE_DAMAGE_FIELD.index = 1
|
|||
CHALLENGEDEATHPATHRESPONSE_DAMAGE_FIELD.label = 1
|
||||
CHALLENGEDEATHPATHRESPONSE_DAMAGE_FIELD.has_default_value = false
|
||||
CHALLENGEDEATHPATHRESPONSE_DAMAGE_FIELD.default_value = 0
|
||||
CHALLENGEDEATHPATHRESPONSE_DAMAGE_FIELD.type = 5
|
||||
CHALLENGEDEATHPATHRESPONSE_DAMAGE_FIELD.cpp_type = 1
|
||||
CHALLENGEDEATHPATHRESPONSE_DAMAGE_FIELD.type = 3
|
||||
CHALLENGEDEATHPATHRESPONSE_DAMAGE_FIELD.cpp_type = 2
|
||||
|
||||
CHALLENGEDEATHPATHRESPONSE_DROP_FIELD.name = "drop"
|
||||
CHALLENGEDEATHPATHRESPONSE_DROP_FIELD.full_name = ".rpc.protocols.ChallengeDeathPathResponse.drop"
|
||||
|
@ -3023,8 +3023,8 @@ CHALLENGEDEATHPATHRESPONSE_HISTORYMAX_FIELD.index = 3
|
|||
CHALLENGEDEATHPATHRESPONSE_HISTORYMAX_FIELD.label = 1
|
||||
CHALLENGEDEATHPATHRESPONSE_HISTORYMAX_FIELD.has_default_value = false
|
||||
CHALLENGEDEATHPATHRESPONSE_HISTORYMAX_FIELD.default_value = 0
|
||||
CHALLENGEDEATHPATHRESPONSE_HISTORYMAX_FIELD.type = 5
|
||||
CHALLENGEDEATHPATHRESPONSE_HISTORYMAX_FIELD.cpp_type = 1
|
||||
CHALLENGEDEATHPATHRESPONSE_HISTORYMAX_FIELD.type = 3
|
||||
CHALLENGEDEATHPATHRESPONSE_HISTORYMAX_FIELD.cpp_type = 2
|
||||
|
||||
CHALLENGEDEATHPATHRESPONSE.name = "ChallengeDeathPathResponse"
|
||||
CHALLENGEDEATHPATHRESPONSE.full_name = ".rpc.protocols.ChallengeDeathPathResponse"
|
||||
|
|
|
@ -197,7 +197,12 @@ HONGMENGADDITION = protobuf.Descriptor();
|
|||
HONGMENGADDITION_ADDITIONTYPE_FIELD = protobuf.FieldDescriptor();
|
||||
HONGMENGADDITION_VALUE_FIELD = protobuf.FieldDescriptor();
|
||||
HONGMENGADDITION_HEROTID_FIELD = protobuf.FieldDescriptor();
|
||||
GETHONGMENGINFOREQUEST = protobuf.Descriptor();
|
||||
GETHONGMENGINFORESPONSE = protobuf.Descriptor();
|
||||
GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD = protobuf.FieldDescriptor();
|
||||
GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD = protobuf.FieldDescriptor();
|
||||
GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD = protobuf.FieldDescriptor();
|
||||
GETHONGMENGINFORESPONSE_HONGMENGTABLETMAX_FIELD = protobuf.FieldDescriptor();
|
||||
HONGMENGINFOINDICATION = protobuf.Descriptor();
|
||||
HONGMENGINFOINDICATION_HONGMENGGUARDS_FIELD = protobuf.FieldDescriptor();
|
||||
HONGMENGINFOINDICATION_HONGMENGADDITIONS_FIELD = protobuf.FieldDescriptor();
|
||||
|
@ -1982,11 +1987,61 @@ HONGMENGADDITION.enum_types = {}
|
|||
HONGMENGADDITION.fields = {HONGMENGADDITION_ADDITIONTYPE_FIELD, HONGMENGADDITION_VALUE_FIELD, HONGMENGADDITION_HEROTID_FIELD}
|
||||
HONGMENGADDITION.is_extendable = false
|
||||
HONGMENGADDITION.extensions = {}
|
||||
GETHONGMENGINFOREQUEST.name = "GetHongmengInfoRequest"
|
||||
GETHONGMENGINFOREQUEST.full_name = ".rpc.protocols.GetHongmengInfoRequest"
|
||||
GETHONGMENGINFOREQUEST.nested_types = {}
|
||||
GETHONGMENGINFOREQUEST.enum_types = {}
|
||||
GETHONGMENGINFOREQUEST.fields = {}
|
||||
GETHONGMENGINFOREQUEST.is_extendable = false
|
||||
GETHONGMENGINFOREQUEST.extensions = {}
|
||||
GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD.name = "hongmengGuards"
|
||||
GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD.full_name = ".rpc.protocols.GetHongmengInfoResponse.hongmengGuards"
|
||||
GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD.number = 1
|
||||
GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD.index = 0
|
||||
GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD.label = 3
|
||||
GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD.has_default_value = false
|
||||
GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD.default_value = {}
|
||||
GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD.message_type = HONGMENGHEROINFO
|
||||
GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD.type = 11
|
||||
GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD.cpp_type = 10
|
||||
|
||||
GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD.name = "hongmengAdditions"
|
||||
GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD.full_name = ".rpc.protocols.GetHongmengInfoResponse.hongmengAdditions"
|
||||
GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD.number = 2
|
||||
GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD.index = 1
|
||||
GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD.label = 3
|
||||
GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD.has_default_value = false
|
||||
GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD.default_value = {}
|
||||
GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD.message_type = HONGMENGADDITION
|
||||
GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD.type = 11
|
||||
GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD.cpp_type = 10
|
||||
|
||||
GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD.name = "hongmengResonacnes"
|
||||
GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD.full_name = ".rpc.protocols.GetHongmengInfoResponse.hongmengResonacnes"
|
||||
GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD.number = 3
|
||||
GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD.index = 2
|
||||
GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD.label = 3
|
||||
GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD.has_default_value = false
|
||||
GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD.default_value = {}
|
||||
GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD.message_type = HONGMENGHEROINFO
|
||||
GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD.type = 11
|
||||
GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD.cpp_type = 10
|
||||
|
||||
GETHONGMENGINFORESPONSE_HONGMENGTABLETMAX_FIELD.name = "hongmengTabletMax"
|
||||
GETHONGMENGINFORESPONSE_HONGMENGTABLETMAX_FIELD.full_name = ".rpc.protocols.GetHongmengInfoResponse.hongmengTabletMax"
|
||||
GETHONGMENGINFORESPONSE_HONGMENGTABLETMAX_FIELD.number = 4
|
||||
GETHONGMENGINFORESPONSE_HONGMENGTABLETMAX_FIELD.index = 3
|
||||
GETHONGMENGINFORESPONSE_HONGMENGTABLETMAX_FIELD.label = 1
|
||||
GETHONGMENGINFORESPONSE_HONGMENGTABLETMAX_FIELD.has_default_value = false
|
||||
GETHONGMENGINFORESPONSE_HONGMENGTABLETMAX_FIELD.default_value = 0
|
||||
GETHONGMENGINFORESPONSE_HONGMENGTABLETMAX_FIELD.type = 5
|
||||
GETHONGMENGINFORESPONSE_HONGMENGTABLETMAX_FIELD.cpp_type = 1
|
||||
|
||||
GETHONGMENGINFORESPONSE.name = "GetHongmengInfoResponse"
|
||||
GETHONGMENGINFORESPONSE.full_name = ".rpc.protocols.GetHongmengInfoResponse"
|
||||
GETHONGMENGINFORESPONSE.nested_types = {}
|
||||
GETHONGMENGINFORESPONSE.enum_types = {}
|
||||
GETHONGMENGINFORESPONSE.fields = {}
|
||||
GETHONGMENGINFORESPONSE.fields = {GETHONGMENGINFORESPONSE_HONGMENGGUARDS_FIELD, GETHONGMENGINFORESPONSE_HONGMENGADDITIONS_FIELD, GETHONGMENGINFORESPONSE_HONGMENGRESONACNES_FIELD, GETHONGMENGINFORESPONSE_HONGMENGTABLETMAX_FIELD}
|
||||
GETHONGMENGINFORESPONSE.is_extendable = false
|
||||
GETHONGMENGINFORESPONSE.extensions = {}
|
||||
HONGMENGINFOINDICATION_HONGMENGGUARDS_FIELD.name = "hongmengGuards"
|
||||
|
@ -2313,6 +2368,7 @@ GetEndlessHeroListInfoRequest = protobuf.Message(GETENDLESSHEROLISTINFOREQUEST)
|
|||
GetEndlessHeroListInfoResponse = protobuf.Message(GETENDLESSHEROLISTINFORESPONSE)
|
||||
GetHeroListInfoRequest = protobuf.Message(GETHEROLISTINFOREQUEST)
|
||||
GetHeroListInfoResponse = protobuf.Message(GETHEROLISTINFORESPONSE)
|
||||
GetHongmengInfoRequest = protobuf.Message(GETHONGMENGINFOREQUEST)
|
||||
GetHongmengInfoResponse = protobuf.Message(GETHONGMENGINFORESPONSE)
|
||||
GetSkinIndication = protobuf.Message(GETSKININDICATION)
|
||||
HeroComposeRequest = protobuf.Message(HEROCOMPOSEREQUEST)
|
||||
|
|
|
@ -321,6 +321,7 @@ GETPLAYERONETEAMINFOREQUEST = protobuf.Descriptor();
|
|||
GETPLAYERONETEAMINFOREQUEST_PLAYERID_FIELD = protobuf.FieldDescriptor();
|
||||
GETPLAYERONETEAMINFOREQUEST_TEAMID_FIELD = protobuf.FieldDescriptor();
|
||||
GETPLAYERONETEAMINFOREQUEST_SERVERID_FIELD = protobuf.FieldDescriptor();
|
||||
GETPLAYERONETEAMINFOREQUEST_CROSSTEAMID_FIELD = protobuf.FieldDescriptor();
|
||||
GETPLAYERONETEAMINFORESPONSE = protobuf.Descriptor();
|
||||
GETPLAYERONETEAMINFORESPONSE_TEAMINFO_FIELD = protobuf.FieldDescriptor();
|
||||
TAKESENVENSCOREREWARDRESPONSE = protobuf.Descriptor();
|
||||
|
@ -3551,11 +3552,21 @@ GETPLAYERONETEAMINFOREQUEST_SERVERID_FIELD.default_value = 0
|
|||
GETPLAYERONETEAMINFOREQUEST_SERVERID_FIELD.type = 5
|
||||
GETPLAYERONETEAMINFOREQUEST_SERVERID_FIELD.cpp_type = 1
|
||||
|
||||
GETPLAYERONETEAMINFOREQUEST_CROSSTEAMID_FIELD.name = "crossteamId"
|
||||
GETPLAYERONETEAMINFOREQUEST_CROSSTEAMID_FIELD.full_name = ".rpc.protocols.GetPlayerOneTeamInfoRequest.crossteamId"
|
||||
GETPLAYERONETEAMINFOREQUEST_CROSSTEAMID_FIELD.number = 4
|
||||
GETPLAYERONETEAMINFOREQUEST_CROSSTEAMID_FIELD.index = 3
|
||||
GETPLAYERONETEAMINFOREQUEST_CROSSTEAMID_FIELD.label = 3
|
||||
GETPLAYERONETEAMINFOREQUEST_CROSSTEAMID_FIELD.has_default_value = false
|
||||
GETPLAYERONETEAMINFOREQUEST_CROSSTEAMID_FIELD.default_value = {}
|
||||
GETPLAYERONETEAMINFOREQUEST_CROSSTEAMID_FIELD.type = 5
|
||||
GETPLAYERONETEAMINFOREQUEST_CROSSTEAMID_FIELD.cpp_type = 1
|
||||
|
||||
GETPLAYERONETEAMINFOREQUEST.name = "GetPlayerOneTeamInfoRequest"
|
||||
GETPLAYERONETEAMINFOREQUEST.full_name = ".rpc.protocols.GetPlayerOneTeamInfoRequest"
|
||||
GETPLAYERONETEAMINFOREQUEST.nested_types = {}
|
||||
GETPLAYERONETEAMINFOREQUEST.enum_types = {}
|
||||
GETPLAYERONETEAMINFOREQUEST.fields = {GETPLAYERONETEAMINFOREQUEST_PLAYERID_FIELD, GETPLAYERONETEAMINFOREQUEST_TEAMID_FIELD, GETPLAYERONETEAMINFOREQUEST_SERVERID_FIELD}
|
||||
GETPLAYERONETEAMINFOREQUEST.fields = {GETPLAYERONETEAMINFOREQUEST_PLAYERID_FIELD, GETPLAYERONETEAMINFOREQUEST_TEAMID_FIELD, GETPLAYERONETEAMINFOREQUEST_SERVERID_FIELD, GETPLAYERONETEAMINFOREQUEST_CROSSTEAMID_FIELD}
|
||||
GETPLAYERONETEAMINFOREQUEST.is_extendable = false
|
||||
GETPLAYERONETEAMINFOREQUEST.extensions = {}
|
||||
GETPLAYERONETEAMINFORESPONSE_TEAMINFO_FIELD.name = "teamInfo"
|
||||
|
|
|
@ -16,7 +16,6 @@ local _FuncGuideList = {}
|
|||
function this.Initialize()
|
||||
Game.GlobalEvent:AddEvent(GameEvent.FunctionCtrl.OnFunctionOpen, this.OnFunctionOpen)
|
||||
Game.GlobalEvent:AddEvent(GameEvent.Player.OnLevelChange, this.OnLevelChange)
|
||||
Game.GlobalEvent:AddEvent(GameEvent.HongMeng.HongMengGuide,this.HongMengGuideFun)
|
||||
Game.GlobalEvent:AddEvent(GameEvent.Practice.PracticeGuide,this.PracticeGuideFun)
|
||||
Game.GlobalEvent:AddEvent(GameEvent.EndLess.GuidePanel,this.EndlessGuideFun)
|
||||
end
|
||||
|
@ -29,21 +28,11 @@ end
|
|||
|
||||
function this.HongMengGuideFun(OnOff)
|
||||
--鸿蒙碑开启引导
|
||||
print(Language[12186])
|
||||
if OnOff == 1 then
|
||||
-- body
|
||||
UIManager.OpenPanel(UIName.MainPanel)
|
||||
table.insert(_FuncGuideList, 101612)
|
||||
this.CheckFuncGuide()
|
||||
this.IsFirstOpenHarmonyBei = true
|
||||
-- for i = 1, #HarmonyManager.hongmengGuards do
|
||||
-- -- body
|
||||
-- if HarmonyManager.hongmengGuards[i].heroId ~= "" then
|
||||
-- -- body
|
||||
-- local _heroData = HeroManager.GetSingleHeroData(HarmonyManager.hongmengGuards[i].heroId)
|
||||
-- HeroManager.UpdateSingleHeroDatas(_heroData.dynamicId, 1, _heroData.star, 0, _heroData.upStarId)
|
||||
-- end
|
||||
-- end
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
HarmonyManager = {}
|
||||
local this = HarmonyManager
|
||||
--
|
||||
|
||||
local HongmengUp = ConfigManager.GetConfig(ConfigName.HongmengUp)-- 鸿蒙塔升级数据表
|
||||
-- 第一阶段 鸿蒙阵数据
|
||||
this.hongmengGuards = {}
|
||||
this.hongmengHeroInfos = {}
|
||||
|
@ -21,42 +22,61 @@ HarmonyManager.equipCount = 0
|
|||
this.hongmengGongMingList = {}
|
||||
this.ChooseDataList = {}
|
||||
|
||||
|
||||
-- 第二阶段 鸿蒙塔 数据
|
||||
--330 鸿蒙使者 数据
|
||||
|
||||
|
||||
-- 鸿蒙塔升级数据表
|
||||
local HongmengUp = ConfigManager.GetConfig(ConfigName.HongmengUp)
|
||||
|
||||
local keys = nil
|
||||
function this.InitHongMengData(hongmengGuards, hongmengHeroInfos, hongmengTablet, hongmengAdditions)
|
||||
|
||||
function this.GetHongMengServerData(msg)
|
||||
local data2 = ConfigManager.GetConfigData(ConfigName.SpecialConfig,101).Value
|
||||
local d = string.split(data2,"#")
|
||||
if msg.hongmengTabletMax >= tonumber(d[2]) then
|
||||
HarmonyManager:SetHongMengTowerUpLimit(msg.hongmengTabletMax)
|
||||
end
|
||||
-- LogError("服务器发来的hongmengGuards长度:"..tostring(#msg.hongmengGuards))
|
||||
if msg.hongmengGuards then
|
||||
-- for i = 1, #msg.hongmengGuards do
|
||||
-- if msg.hongmengGuards[i].heroId == "" then
|
||||
-- Log("鸿蒙守卫:"..i.."为nil")
|
||||
-- else
|
||||
-- Log("鸿蒙守卫:"..i..HeroManager.GetSingleHeroData(msg.hongmengGuards[i].heroId).name)
|
||||
-- end
|
||||
-- end
|
||||
HarmonyManager.UpdateHongMengDataGuards(msg.hongmengGuards)
|
||||
end
|
||||
-- LogError("服务器发来的hongmengAdditions长度:"..tostring(#msg.hongmengAdditions))
|
||||
if msg.hongmengAdditions then
|
||||
for i = 1, #msg.hongmengAdditions do
|
||||
-- body
|
||||
this.hongmengGuards = hongmengGuards
|
||||
--LogGreen("hongmengGuards",#this.hongmengGuards)
|
||||
|
||||
|
||||
|
||||
-- --LogGreen("TowerStartLimit"..HarmonyManager.TowerStartLimit)
|
||||
this.hongmengHeroInfos = hongmengHeroInfos
|
||||
|
||||
keys = GameDataBase.SheetBase.GetKeys(this.tab)
|
||||
|
||||
for i = 1, #this.hongmengGuards do
|
||||
this.hongmengGuards[i].time = this.hongmengGuards[i].time + GetTimeStamp()
|
||||
end
|
||||
|
||||
--LogBlue("hongmengTablet "..hongmengTablet)
|
||||
for i = 1, #this.hongmengHeroInfos do
|
||||
this.hongmengHeroInfos[i].time = this.hongmengHeroInfos[i].time + GetTimeStamp()
|
||||
HarmonyManager.UpdateHongMengDataAdditions(msg.hongmengAdditions)
|
||||
end
|
||||
if msg.hongmengResonacnes then
|
||||
HarmonyManager.UpdateHongMengDataHeroInfos(msg.hongmengResonacnes)
|
||||
end
|
||||
if GuideManager.IsFirstOpenHarmonyBei then
|
||||
GuideManager.IsFirstOpenHarmonyBei = false
|
||||
for i = 1, #HarmonyManager.hongmengGuards do
|
||||
if HarmonyManager.hongmengGuards[i].heroId ~= "" then
|
||||
local _heroData = HeroManager.GetSingleHeroData(HarmonyManager.hongmengGuards[i].heroId)
|
||||
HeroManager.UpdateSingleHeroDatas(_heroData.dynamicId, 1, _heroData.star, 0, _heroData.upStarId)
|
||||
end
|
||||
end
|
||||
end
|
||||
--鸿蒙数据有变化时更新英雄战力数据
|
||||
for i = 1, #msg.hongmengGuards do
|
||||
if msg.hongmengGuards[i].heroId~="" then
|
||||
HeroManager.UpdateSingleHeroWarPower(msg.hongmengGuards[i].heroId)
|
||||
end
|
||||
end
|
||||
for i = 1, #msg.hongmengResonacnes do
|
||||
if msg.hongmengResonacnes[i].heroId~="" then
|
||||
HeroManager.UpdateSingleHeroWarPower(msg.hongmengResonacnes[i].heroId)
|
||||
end
|
||||
end
|
||||
this.hongmengTablet = hongmengTablet
|
||||
this.hongmengAdditions = hongmengAdditions
|
||||
|
||||
|
||||
|
||||
end
|
||||
|
||||
|
||||
function this.UpdateHongMengDataGuards(hongmengGuards)
|
||||
this.TowerStartLimit = tonumber(string.split(ConfigManager.GetConfigData(ConfigName.SpecialConfig,101).Value,"#")[2])
|
||||
this.hongmengGuards = hongmengGuards
|
||||
|
@ -64,19 +84,14 @@ function this.UpdateHongMengDataGuards(hongmengGuards)
|
|||
--LogGreen("hongmengGuards "..#this.hongmengGuards)
|
||||
for i = 1, #this.hongmengGuards do
|
||||
if this.hongmengGuards[i].time ~= 0 then
|
||||
-- body
|
||||
this.hongmengGuards[i].time = this.hongmengGuards[i].time + GetTimeStamp()
|
||||
--print(this.hongmengGuards[i].value)
|
||||
end
|
||||
|
||||
end
|
||||
if this.hongmengAdditions[1] then
|
||||
-- body
|
||||
if this.hongmengAdditions[1].heroTid == 0 then
|
||||
-- body
|
||||
this:SetTowerInit()
|
||||
elseif this.hongmengAdditions[1].heroTid == -1 then
|
||||
-- body
|
||||
else
|
||||
this:SetInitList()
|
||||
end
|
||||
|
@ -89,10 +104,8 @@ function this.UpdateHongMengDataHeroInfos(hongmengHeroInfos)
|
|||
-- LogGreen("hongmengHeroInfos "..#this.hongmengHeroInfos)
|
||||
for i = 1, #this.hongmengHeroInfos do
|
||||
if this.hongmengHeroInfos[i].time ~= 0 then
|
||||
-- body
|
||||
this.hongmengHeroInfos[i].time = this.hongmengHeroInfos[i].time + GetTimeStamp()
|
||||
end
|
||||
-- print(HeroManager.)
|
||||
--鸿蒙阵共鸣后直接大于20级 后没有赋值大闹天宫英雄血量 大闹天宫一键上阵报错
|
||||
-- LogYellow("this.hongmengHeroInfos[i].heroId "..this.hongmengHeroInfos[i].heroId)
|
||||
if not ExpeditionManager.heroInfo[this.hongmengHeroInfos[i].heroId] then
|
||||
|
@ -102,12 +115,9 @@ function this.UpdateHongMengDataHeroInfos(hongmengHeroInfos)
|
|||
end
|
||||
|
||||
if this.hongmengAdditions[1] then
|
||||
-- body
|
||||
if this.hongmengAdditions[1].heroTid == 0 then
|
||||
-- body
|
||||
this:SetTowerInit()
|
||||
elseif this.hongmengAdditions[1].heroTid == -1 then
|
||||
-- body
|
||||
else
|
||||
this:SetInitList()
|
||||
end
|
||||
|
@ -116,20 +126,18 @@ end
|
|||
|
||||
function this.UpdateHongMengDataAdditions(hongmengAdditions)
|
||||
this.hongmengAdditions = hongmengAdditions
|
||||
for i = 1, #this.hongmengAdditions do
|
||||
-- for i = 1, #this.hongmengAdditions do
|
||||
-- LogGreen("this.hongmengAdditions[i].heroTid:"..this.hongmengAdditions[i].heroTid)
|
||||
-- LogGreen("this.hongmengAdditions[i].value:"..this.hongmengAdditions[i].value)
|
||||
-- LogGreen("this.hongmengAdditions[i].additionType:"..this.hongmengAdditions[i].additionType)
|
||||
end
|
||||
-- end
|
||||
--LogGreen("hongmengAdditions "..#this.hongmengAdditions)
|
||||
for i = 1, #this.hongmengAdditions do
|
||||
|
||||
if this.hongmengAdditions[i].additionType == HarmonyAddType.AddEquip then
|
||||
if this.hongmengAdditions[i].value > 0 then
|
||||
local curEquipIdList = {}
|
||||
local curEquipConfigs = ConfigManager.GetAllConfigsDataByKey(ConfigName.EquipConfig,"Star",this.hongmengAdditions[i].value)
|
||||
for i = 1, #curEquipConfigs do
|
||||
|
||||
table.insert(curEquipIdList,curEquipConfigs[i].Id)
|
||||
end
|
||||
this.HarmonyUpdateEquipData(curEquipIdList, "")
|
||||
|
@ -137,22 +145,13 @@ function this.UpdateHongMengDataAdditions(hongmengAdditions)
|
|||
end
|
||||
end
|
||||
if this.hongmengAdditions[1] then
|
||||
-- body
|
||||
if this.hongmengAdditions[1].heroTid == 0 then
|
||||
-- body
|
||||
this:SetTowerInit()
|
||||
elseif this.hongmengAdditions[1].heroTid == -1 then
|
||||
-- body
|
||||
else
|
||||
this:SetInitList()
|
||||
end
|
||||
end
|
||||
-- if this.hongmengTablet < this.TowerStartLimit then
|
||||
-- -- body
|
||||
|
||||
-- else
|
||||
|
||||
-- end
|
||||
end
|
||||
|
||||
--初始化共鸣列表数据
|
||||
|
@ -165,8 +164,6 @@ function this:InitGongMingDataList()
|
|||
this.hongmengGongMingList[i] = nil
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
end
|
||||
--鸿蒙塔上限
|
||||
|
||||
|
@ -175,7 +172,6 @@ function this:SetHongMengTowerUpLimit(limit)
|
|||
len = limit
|
||||
end
|
||||
function this:HongMengTowerUpLimit()
|
||||
|
||||
return len
|
||||
end
|
||||
|
||||
|
@ -201,13 +197,11 @@ end
|
|||
|
||||
function this.IsGongMing(did)
|
||||
for i = 1, #this.hongmengHeroInfos do
|
||||
-- body
|
||||
if did == this.hongmengHeroInfos[i].heroId then
|
||||
PopupTipPanel.ShowTip(Language[12192])
|
||||
return
|
||||
end
|
||||
end
|
||||
-- body
|
||||
end
|
||||
--初始化选人列表的长度
|
||||
function this:SetInitList()
|
||||
|
@ -221,16 +215,13 @@ function this:SetInitList()
|
|||
table.insert(list,singleHero)
|
||||
end
|
||||
end
|
||||
|
||||
for i = 1, #this.hongmengHeroInfos do
|
||||
if this.hongmengHeroInfos[i].heroId ~= "" then
|
||||
-- LogYellow("是否有数据:"..i)
|
||||
local data = HeroManager.GetSingleHeroData(this.hongmengHeroInfos[i].heroId)
|
||||
table.insert(list,data)
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
table.sort(list,function(a,b)
|
||||
return a.dynamicId < b.dynamicId
|
||||
end)
|
||||
|
@ -238,7 +229,6 @@ function this:SetInitList()
|
|||
local newList = {}
|
||||
local index = 0
|
||||
local flag = true
|
||||
|
||||
local tempTable = {}
|
||||
for i = 1, #heroDataList do
|
||||
table.insert(tempTable,heroDataList[i])
|
||||
|
@ -308,9 +298,7 @@ end
|
|||
function this:IsEnvoyCount()
|
||||
-- body
|
||||
local count = 1
|
||||
--print("228 ",#this.hongmengGuards)
|
||||
for i = 1, #this.hongmengGuards do
|
||||
-- body
|
||||
if this.hongmengGuards[i].heroId ~= "" then
|
||||
count =count + 1
|
||||
end
|
||||
|
@ -324,18 +312,13 @@ end
|
|||
--是否是鸿蒙使者
|
||||
function this:IsEnvoy(did)
|
||||
if this:HongMengTowerUpLimit() == 0 then
|
||||
-- body
|
||||
return false
|
||||
end
|
||||
-- body
|
||||
-- LogError("hongmengGuards长度:"..tostring(#this.hongmengGuards))
|
||||
for i = 1, #this.hongmengGuards do
|
||||
-- body
|
||||
if this.hongmengGuards[i].heroId == did then
|
||||
-- body
|
||||
return true
|
||||
|
||||
end
|
||||
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
@ -343,7 +326,6 @@ end
|
|||
function this:SetGuardList(list,count)
|
||||
for key, value in pairs(list) do
|
||||
if key<=count then
|
||||
-- body
|
||||
this.GuardList[value.dynamicId] = value
|
||||
end
|
||||
end
|
||||
|
@ -351,7 +333,6 @@ function this:SetGuardList(list,count)
|
|||
end
|
||||
function this:GetGuardList()
|
||||
return this.GuardList
|
||||
-- body
|
||||
end
|
||||
|
||||
function this:SetGongMingList(Id)
|
||||
|
@ -368,9 +349,7 @@ function this:RemoveGongMingList(Id)
|
|||
local data = HeroManager.GetSingleHeroData(Id)
|
||||
for key, value in pairs(this.hongmengGongMingList) do
|
||||
if value then
|
||||
-- body
|
||||
if value==data then
|
||||
-- body
|
||||
value = nil
|
||||
break
|
||||
end
|
||||
|
@ -380,30 +359,22 @@ end
|
|||
|
||||
function this:GetGongMingListSingle(Id)
|
||||
local data = HeroManager.GetSingleHeroData(Id)
|
||||
--return data
|
||||
--print(data.dynamicId,"~~~",Id)
|
||||
for key, value in pairs(this.hongmengGongMingList) do
|
||||
|
||||
if value.dynamicId==data.dynamicId then
|
||||
|
||||
return value
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
function this:SetChooseId(id)
|
||||
SelectId = id
|
||||
end
|
||||
-- 设置、获取卸载的数据
|
||||
function this:SetMingListIndexData(index)
|
||||
|
||||
SelectId = this.hongmengHeroInfos[index].heroId
|
||||
end
|
||||
|
||||
|
||||
function this:GetUnLoadData()
|
||||
-- body
|
||||
return SelectId
|
||||
end
|
||||
|
||||
|
@ -415,7 +386,6 @@ end
|
|||
|
||||
function this.GetSingleAdditions(type)
|
||||
if this.hongmengAdditions then
|
||||
-- body
|
||||
for i = 1, #this.hongmengAdditions do
|
||||
if this.hongmengAdditions[i].additionType == type then
|
||||
--LogGreen("this.hongmengAdditions[i].additionType:"..this.hongmengAdditions[i].additionType.." this.hongmengAdditions[i].value :"..this.hongmengAdditions[i].value )
|
||||
|
@ -423,16 +393,13 @@ function this.GetSingleAdditions(type)
|
|||
end
|
||||
end
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
function this.GetSingleAdditionsData(type)
|
||||
if this.hongmengAdditions then
|
||||
-- body
|
||||
-- LogError("Additions长度:"..tostring(#this.hongmengAdditions))
|
||||
for i = 1, #this.hongmengAdditions do
|
||||
if this.hongmengAdditions[i].additionType == type then
|
||||
|
||||
|
||||
return this.hongmengAdditions[i]
|
||||
end
|
||||
end
|
||||
|
@ -444,23 +411,16 @@ end
|
|||
|
||||
function this.GetHongMengUpData()
|
||||
for i = 1, #this.hongmengAdditions do
|
||||
-- body
|
||||
if this.hongmengAdditions[i].additionType == 1 then
|
||||
-- body
|
||||
if this.hongmengAdditions[i].value < 330 then
|
||||
-- body
|
||||
LogBlue("服务器数据为"..this.hongmengAdditions[i].value)
|
||||
return nil
|
||||
|
||||
end
|
||||
--LogGreen("服务器数据为"..this.hongmengAdditions[i].value)
|
||||
for key, value in ConfigPairs(HongmengUp) do
|
||||
-- body
|
||||
if value.HongmengLevel == this.hongmengAdditions[i].value + 1 then
|
||||
-- body
|
||||
return ConfigManager.TryGetConfigData(ConfigName.HongmengUp,key)
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
end
|
||||
|
@ -528,14 +488,10 @@ end
|
|||
--判断神将的装备是否共鸣
|
||||
function this:IsShowGongMingEqiup(id)
|
||||
for i = 1, #this.hongmengHeroInfos do
|
||||
-- body
|
||||
if id == this.hongmengHeroInfos[i].heroId then
|
||||
|
||||
return true
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
return false
|
||||
end
|
||||
|
||||
|
@ -557,7 +513,6 @@ function this.RefreshOpenBoxPoint()
|
|||
local Gold = BagManager.GetTotalItemNum(UpViewRechargeType.XuanHuangZhiQi)
|
||||
-- local DemonCrystal = BagManager.GetTotalItemNum(UpViewRechargeType.DemonCrystal) or DemonCrystal > tab[#this.hongmengHeroInfos].MoneyPrice[2]
|
||||
if #this.hongmengHeroInfos<=0 then
|
||||
-- body
|
||||
return false
|
||||
end
|
||||
if tab[#this.hongmengHeroInfos + 1] and Gold > tab[#this.hongmengHeroInfos + 1].PropPrice[2] and #this.hongmengHeroInfos < #keys then
|
||||
|
@ -572,52 +527,39 @@ function this.RefreshEnvoyPoint()
|
|||
|
||||
local data = this.GetSingleAdditionsData(HarmonyAddType.AddLv)
|
||||
if data then
|
||||
-- body
|
||||
if data.heroTid == 0 then
|
||||
-- body
|
||||
local sum = this:HongMengTowerUpLimit()
|
||||
if data.value <= sum then
|
||||
-- body
|
||||
for i = 1, #this.hongmengGuards do
|
||||
-- body
|
||||
if data.heroId == "" and data.time == 0 then
|
||||
-- body
|
||||
return true
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
return false
|
||||
end
|
||||
|
||||
function this.RefreshUpTowerPoint()
|
||||
-- body
|
||||
if len == 0 then
|
||||
return false
|
||||
end
|
||||
local data = this.GetSingleAdditionsData(HarmonyAddType.AddLv)
|
||||
if data then
|
||||
-- body
|
||||
if data.heroTid == 0 then
|
||||
-- body
|
||||
local sum = this:HongMengTowerUpLimit()
|
||||
print(sum,data.value)
|
||||
if data.value >= sum then
|
||||
-- body
|
||||
return false
|
||||
else
|
||||
local prop = this.GetHongMengUpData()
|
||||
-- --LogGreen(data.LevelUp[1][2].." "..data.LevelUp[2][2])
|
||||
-- LogYellow(BagManager.GetTotalItemNum(UpViewRechargeType.Gold))
|
||||
if prop and BagManager.GetTotalItemNum(UpViewRechargeType.Gold) >= prop.LevelUp[1][2] then
|
||||
-- body
|
||||
if BagManager.GetTotalItemNum(UpViewRechargeType.GrowthAmulet) >= prop.LevelUp[2][2] then
|
||||
return true
|
||||
end
|
||||
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
@ -626,7 +568,6 @@ function this.RefreshUpTowerPoint()
|
|||
end
|
||||
end
|
||||
return false
|
||||
|
||||
end
|
||||
--检测主城红点
|
||||
function this.CheckRedPoinStatusUpTowerMainCityRed()
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
require("misc.GSetClass")
|
||||
|
||||
local HeroData = GSetClass("Person")
|
||||
local heroConfig = ConfigManager.GetConfig(ConfigName.HeroConfig)
|
||||
HeroData.onCreate = function(self,_msgHeroData, isFindHandBook)
|
||||
self._id = _msgHeroData.heroId
|
||||
self._lv = _msgHeroData.level
|
||||
|
@ -13,61 +14,48 @@ HeroData.onCreate = function(self,_msgHeroData, isFindHandBook)
|
|||
end
|
||||
--等级
|
||||
HeroData.__get__.lv = function(self)
|
||||
-- print(this._lv, " - 属性访问器:get lv")
|
||||
local temp_lv = HarmonyManager.GetSingleAdditions(HarmonyAddType.AddLv)
|
||||
local endLv = 0
|
||||
|
||||
-- LogWarn("名字:"..tostring(heroConfig[self._id].ReadingName)..
|
||||
-- " temp_lv:"..tostring(temp_lv)..
|
||||
-- " Bool:"..tostring(HarmonyManager:HongMengTowerUpLimit() ~= 0)..
|
||||
-- " Bool2:"..tostring(HarmonyManager.GetSingleAdditionsData(HarmonyAddType.AddLv))
|
||||
-- )
|
||||
-- LogWarn(" Bool3:"..tostring(HarmonyManager:IsEnvoy(self.dynamicId)))
|
||||
if temp_lv > 0 and HarmonyManager.IsInfo(self.dynamicId) then
|
||||
|
||||
--LogGreen(tostring(HeroManager.IsElevenStar(self.star)))
|
||||
--print(self._id.." "..HarmonyManager.hongmengAdditions[1].heroTid..self.heroConfig.ReadingName)
|
||||
if HeroManager.IsTenTalent(self._id)and HarmonyManager:HongMengTowerUpLimit() ~= 0 then
|
||||
-- bodys
|
||||
|
||||
endLv = HarmonyManager.GetSingleAdditionsData(HarmonyAddType.AddLv).value
|
||||
--print(endLv," "..self.heroConfig.ReadingName.."!!!!!!!!"..HarmonyManager.hongmengAdditions[1].value)
|
||||
else
|
||||
if HeroManager.IsTenTalent(self._id) then
|
||||
-- body
|
||||
endLv = HarmonyManager.GetSingleAdditionsData(HarmonyAddType.AddLv).value
|
||||
else
|
||||
local curlvEen = HeroManager.heroLvEnd[self._id]
|
||||
endLv = temp_lv > curlvEen and curlvEen or temp_lv
|
||||
end
|
||||
|
||||
|
||||
|
||||
end
|
||||
|
||||
|
||||
return endLv
|
||||
elseif HarmonyManager.GetSingleAdditionsData(HarmonyAddType.AddLv) and HarmonyManager:IsEnvoy(self.dynamicId) then
|
||||
--print("self._id @@@"..HarmonyManager.hongmengAdditions[1].heroTid.."#####"..HarmonyManager.hongmengAdditions[1].value )
|
||||
local data = HarmonyManager.GetSingleAdditionsData(HarmonyAddType.AddLv)
|
||||
if data.heroTid >= 0 and data.value >= 330 then
|
||||
-- body
|
||||
local temp_lv = 0
|
||||
if HeroManager.IsTenTalent(self._id) then
|
||||
-- body
|
||||
temp_lv = data.value
|
||||
else
|
||||
temp_lv = HeroManager.heroLvEnd[self.id]
|
||||
end
|
||||
--print("self._id 222"..self._id)
|
||||
-- LogPink("temp_lv:"..tostring(temp_lv))
|
||||
return temp_lv
|
||||
else
|
||||
return self._lv
|
||||
end
|
||||
-- body
|
||||
--self._lv = HarmonyManager.hongmengTablet
|
||||
|
||||
|
||||
else
|
||||
-- LogBlue("self._lv2:"..tostring(self._lv))
|
||||
return self._lv
|
||||
end
|
||||
end
|
||||
HeroData.__set__.lv = function(self, value)
|
||||
-- print(this._lv, " - 属性访问器:set lv", value)
|
||||
-- LogGreen("SetValue: Name:"..tostring(heroConfig[self._id].ReadingName).." Value:"..tostring(self._lv))
|
||||
self._lv = value
|
||||
end
|
||||
--装备
|
||||
|
@ -142,17 +130,13 @@ HeroData.__get__.breakId = function (self)
|
|||
local endLv = 0
|
||||
local endbreakIdLv = 0
|
||||
if temp_lv > 0 and HarmonyManager.IsInfo(self.dynamicId) then
|
||||
|
||||
--LogGreen(tostring(HeroManager.IsElevenStar(self.star)))
|
||||
--print(self._id.." "..HarmonyManager.hongmengAdditions[1].heroTid..self.heroConfig.ReadingName)
|
||||
if HeroManager.IsTenTalent(self._id) and HarmonyManager.GetSingleAdditionsData(HarmonyAddType.AddLv).heroTid == 0 then
|
||||
-- bodys
|
||||
|
||||
endLv = HarmonyManager.GetSingleAdditionsData(HarmonyAddType.AddLv).value
|
||||
--print(endLv," "..self.heroConfig.ReadingName)
|
||||
else
|
||||
local curlvEen = HeroManager.heroLvEnd[self.id]
|
||||
--
|
||||
endLv = temp_lv > curlvEen and curlvEen or temp_lv
|
||||
end
|
||||
endbreakIdLv = HeroManager.GetAllStarBreakIdData(self._id,endLv)
|
||||
|
@ -162,22 +146,17 @@ HeroData.__get__.breakId = function (self)
|
|||
local data = HarmonyManager.GetSingleAdditionsData(HarmonyAddType.AddLv)
|
||||
--print("self._id @@@"..HarmonyManager.hongmengAdditions[1].heroTid.."#####"..HarmonyManager.hongmengAdditions[1].value )
|
||||
if data.heroTid >= 0 and data.value >= 330 then
|
||||
-- body
|
||||
local temp_lv = 0
|
||||
if HeroManager.IsTenTalent(self._id) then
|
||||
-- body
|
||||
temp_lv = data.value
|
||||
else
|
||||
temp_lv = HeroManager.heroLvEnd[self.id]
|
||||
end
|
||||
endbreakIdLv = HeroManager.GetAllStarBreakIdData(self._id,temp_lv)
|
||||
--print(endbreakIdLv," 222 "..self.heroConfig.ReadingName.."等级"..temp_lv)
|
||||
return endbreakIdLv
|
||||
else
|
||||
|
||||
return self._breakId
|
||||
end
|
||||
|
||||
else
|
||||
return self._breakId
|
||||
end
|
||||
|
|
|
@ -44,7 +44,7 @@ GMPanel = Inherit(BasePanel)
|
|||
local this = GMPanel
|
||||
|
||||
local heroList = {
|
||||
"4#10033#11", "4#10026#11", "4#10008#11", "4#10012#11", "4#10015#11","4#10014#11","4#10033#10","4#10026#10","4#10008#10","4#10012#10","4#10015#10","4#10014#10"
|
||||
"4#10085#11", "4#10089#11", "4#10009#11", "4#10008#11", "4#10006#11","4#10033#11", "4#10023#11"
|
||||
}
|
||||
local baowuList = {
|
||||
"1#100005#1", "1#100010#1", "1#100015#1", "1#100020#1", "1#100025#1","1#100030#1", "1#100035#1","1#100040#1"
|
||||
|
|
|
@ -185,67 +185,61 @@ function this.OpenHongMengTowerGuideIndication(buffer)
|
|||
local data = buffer:DataByte()
|
||||
local msg = HeroInfoProto_pb.HongmengSteleNewHandIndication()
|
||||
msg:ParseFromString(data)
|
||||
--LogGreen(msg.state)
|
||||
|
||||
Game.GlobalEvent:DispatchEvent(GameEvent.HongMeng.HongMengGuide,msg.state)
|
||||
GuideManager.HongMengGuideFun(msg.state)
|
||||
end
|
||||
function this.HongMengIndication(buffer)
|
||||
local data = buffer:DataByte()
|
||||
local msg = HeroInfoProto_pb.HongmengInfoIndication()
|
||||
msg:ParseFromString(data)
|
||||
|
||||
local data = ConfigManager.GetConfigData(ConfigName.SpecialConfig,101).Value
|
||||
local d = string.split(data,"#")
|
||||
if msg.hongmengTabletMax >= tonumber(d[2]) then
|
||||
-- body
|
||||
-- LogYellow("鸿蒙碑开启!!!!!!!!!```````````````````````````` "..msg.hongmengTabletMax)
|
||||
HarmonyManager:SetHongMengTowerUpLimit(msg.hongmengTabletMax)
|
||||
end
|
||||
if msg.hongmengGuards then
|
||||
-- LogError("鸿蒙阵更新数据的Indication..##msg.hongmengGuards:"..tostring(#msg.hongmengGuards))
|
||||
HarmonyManager.GetHongMengServerData(msg)
|
||||
-- local data2 = ConfigManager.GetConfigData(ConfigName.SpecialConfig,101).Value
|
||||
-- LogError("data2:"..tostring(data2))
|
||||
-- local d = string.split(data2,"#")
|
||||
-- LogError("msg.hongmengTabletMax:"..tostring(msg.hongmengTabletMax))
|
||||
-- if msg.hongmengTabletMax >= tonumber(d[2]) then
|
||||
-- HarmonyManager:SetHongMengTowerUpLimit(msg.hongmengTabletMax)
|
||||
-- end
|
||||
-- LogError("服务器发来的hongmengGuards长度:"..tostring(#msg.hongmengGuards))
|
||||
-- if msg.hongmengGuards then
|
||||
-- -- for i = 1, #msg.hongmengGuards do
|
||||
-- -- if msg.hongmengGuards[i].heroId == "" then
|
||||
-- -- Log("鸿蒙守卫:"..i.."为nil")
|
||||
-- -- else
|
||||
-- -- Log("鸿蒙守卫:"..i..HeroManager.GetSingleHeroData(msg.hongmengGuards[i].heroId).name)
|
||||
-- -- end
|
||||
-- -- end
|
||||
-- HarmonyManager.UpdateHongMengDataGuards(msg.hongmengGuards)
|
||||
-- end
|
||||
-- LogError("服务器发来的hongmengAdditions长度:"..tostring(#msg.hongmengAdditions))
|
||||
-- if msg.hongmengAdditions then
|
||||
-- for i = 1, #msg.hongmengAdditions do
|
||||
-- -- body
|
||||
-- end
|
||||
-- HarmonyManager.UpdateHongMengDataAdditions(msg.hongmengAdditions)
|
||||
-- end
|
||||
-- if msg.hongmengResonacnes then
|
||||
-- HarmonyManager.UpdateHongMengDataHeroInfos(msg.hongmengResonacnes)
|
||||
-- end
|
||||
-- if GuideManager.IsFirstOpenHarmonyBei then
|
||||
-- GuideManager.IsFirstOpenHarmonyBei = false
|
||||
-- for i = 1, #HarmonyManager.hongmengGuards do
|
||||
-- if HarmonyManager.hongmengGuards[i].heroId ~= "" then
|
||||
-- local _heroData = HeroManager.GetSingleHeroData(HarmonyManager.hongmengGuards[i].heroId)
|
||||
-- HeroManager.UpdateSingleHeroDatas(_heroData.dynamicId, 1, _heroData.star, 0, _heroData.upStarId)
|
||||
-- end
|
||||
-- end
|
||||
-- end
|
||||
-- --鸿蒙数据有变化时更新英雄战力数据
|
||||
-- for i = 1, #msg.hongmengGuards do
|
||||
-- if msg.hongmengGuards[i].heroId == "" then
|
||||
-- Log("鸿蒙守卫:"..i.."为nil")
|
||||
-- else
|
||||
-- Log("鸿蒙守卫:"..i..HeroManager.GetSingleHeroData(msg.hongmengGuards[i].heroId).name)
|
||||
-- if msg.hongmengGuards[i].heroId~="" then
|
||||
-- HeroManager.UpdateSingleHeroWarPower(msg.hongmengGuards[i].heroId)
|
||||
-- end
|
||||
-- end
|
||||
-- for i = 1, #msg.hongmengResonacnes do
|
||||
-- if msg.hongmengResonacnes[i].heroId~="" then
|
||||
-- HeroManager.UpdateSingleHeroWarPower(msg.hongmengResonacnes[i].heroId)
|
||||
-- end
|
||||
-- end
|
||||
HarmonyManager.UpdateHongMengDataGuards(msg.hongmengGuards)
|
||||
end
|
||||
|
||||
if msg.hongmengAdditions then
|
||||
-- body
|
||||
HarmonyManager.UpdateHongMengDataAdditions(msg.hongmengAdditions)
|
||||
end
|
||||
|
||||
if msg.hongmengResonacnes then
|
||||
-- body UpdateHongMengDataHeroInfos
|
||||
HarmonyManager.UpdateHongMengDataHeroInfos(msg.hongmengResonacnes)
|
||||
end
|
||||
if GuideManager.IsFirstOpenHarmonyBei then
|
||||
GuideManager.IsFirstOpenHarmonyBei = false
|
||||
for i = 1, #HarmonyManager.hongmengGuards do
|
||||
-- body
|
||||
if HarmonyManager.hongmengGuards[i].heroId ~= "" then
|
||||
-- body
|
||||
local _heroData = HeroManager.GetSingleHeroData(HarmonyManager.hongmengGuards[i].heroId)
|
||||
|
||||
HeroManager.UpdateSingleHeroDatas(_heroData.dynamicId, 1, _heroData.star, 0, _heroData.upStarId)
|
||||
|
||||
end
|
||||
end
|
||||
end
|
||||
--鸿蒙数据有变化时更新英雄战力数据
|
||||
for i = 1, #msg.hongmengGuards do
|
||||
if msg.hongmengGuards[i].heroId~="" then
|
||||
HeroManager.UpdateSingleHeroWarPower(msg.hongmengGuards[i].heroId)
|
||||
end
|
||||
end
|
||||
for i = 1, #msg.hongmengResonacnes do
|
||||
if msg.hongmengResonacnes[i].heroId~="" then
|
||||
HeroManager.UpdateSingleHeroWarPower(msg.hongmengResonacnes[i].heroId)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function this.SendFourChallengeInfoIndication(buffer)
|
||||
|
|
|
@ -4920,14 +4920,11 @@ end
|
|||
--鸿蒙阵
|
||||
-- 鸿蒙阵 游戏开始 拿到的数据
|
||||
function this.HongMengInfoResponse(func)
|
||||
-- --LogGreen(tostring(MessageTypeProto_pb.HONGMENG_GET_INFO_REQUEST).." "..tostring(MessageTypeProto_pb.HONGMENG_GET_INFO_RESPONSE))
|
||||
Network:SendMessageWithCallBack(MessageTypeProto_pb.HONGMENG_GET_INFO_REQUEST,MessageTypeProto_pb.HONGMENG_GET_INFO_RESPONSE,nil,function(buffer)
|
||||
-- --LogGreen("请求鸿蒙阵数据")
|
||||
-- local data = buffer:DataByte()
|
||||
-- local msg = HeroInfoProto_pb.GetHongmengInfoResponse()
|
||||
-- msg:ParseFromString(data)
|
||||
-- -- print("接收数据成功")
|
||||
-- HarmonyManager.InitHongMengData(msg.hongmengGuards,msg.hongmengHeroInfos,msg.hongmengTablet,msg.hongmengAdditions)
|
||||
local data = buffer:DataByte()
|
||||
local msg = HeroInfoProto_pb.GetHongmengInfoResponse()
|
||||
msg:ParseFromString(data)
|
||||
HarmonyManager.GetHongMengServerData(msg)
|
||||
if func then
|
||||
func()
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue