【鸿蒙阵】修改

dev_chengFeng
zhangqiang 2020-12-18 18:25:38 +08:00
parent f84e97f531
commit 4b49661f24
4 changed files with 40 additions and 5 deletions

View File

@ -31683,7 +31683,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 125.3, y: 0}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: 100.75}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &222314792653266900
@ -82090,7 +82090,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 0
m_IsActive: 1
--- !u!224 &8530015653524672247
RectTransform:
m_ObjectHideFlags: 0
@ -88775,7 +88775,7 @@ MonoBehaviour:
m_Calls: []
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI,
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
m_Sprite: {fileID: 21300000, guid: 4413b93004f13514c9a191827d760a5f, type: 3}
m_Sprite: {fileID: 21300000, guid: c046dc80bbbcde94591c38d067db5e1f, type: 3}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1

View File

@ -524,5 +524,36 @@ function this.RefreshUpTowerPoint()
return false
end
end
--票战力
local oldPowerNum = 0
function this.SetOldPowerNum(did)
local isCalculate = true
if did then
local heros = FormationManager.GetAllMainFormationHeroId()
if not heros[did] then
isCalculate = false
end
end
if isCalculate then
oldPowerNum = FormationManager.GetFormationPower(FormationTypeDef.FORMATION_NORMAL)
end
end
function this.WarPowerChangeNotify(did)
local isCalculate = true
if did then
local heros = FormationManager.GetAllMainFormationHeroId()
if not heros[did] then
isCalculate = false
end
end
if oldPowerNum ~= 0 and isCalculate then
local newPowerNum = FormationManager.GetFormationPower(FormationTypeDef.FORMATION_NORMAL)
if oldPowerNum ~= newPowerNum then
UIManager.OpenPanel(UIName.WarPowerChangeNotifyPanelV2,{oldValue = oldPowerNum,newValue = newPowerNum})
if did then
FormationManager.CheckHeroIdExist(did)--如果是主线阵容发生变化 会通知后端 更新任务刷新
end
end
end
end
return HarmonyManager

View File

@ -32,12 +32,14 @@ function HongMengUnLoadPanel:BindEvent()
end)
Util.AddClick(this.BtnYes, function()
local select = HarmonyManager:GetUnLoadData()
HarmonyManager.SetOldPowerNum(select)
NetManager.SendGongMingBox(select,HarmonyManager.UnLoadGongMing,2,function (msg)
-- body HarmonyManager.SelectId
Game.GlobalEvent:DispatchEvent(GameEvent.HongMeng.UnLoadData,msg)
HarmonyManager:RemoveGongMingList(select)
self:ClosePanel()
HarmonyManager.WarPowerChangeNotify(select)
end)
end)
Util.AddClick(this.BtnNo, function()

View File

@ -64,7 +64,7 @@ function RoleChooseListPanel:BindEvent()
HarmonyManager:SetChooseId(TempData.dynamicId)
HarmonyManager.SetOldPowerNum(TempData.dynamicId)
if self.flag then --判断是否是鸿蒙使者 如果是 那就不懈装备
-- body
local data = {}
@ -75,6 +75,7 @@ function RoleChooseListPanel:BindEvent()
-- body
Game.GlobalEvent:DispatchEvent(GameEvent.HongMeng.UpHongMengEnvoy,data)
UIManager.OpenPanel(UIName.GongMingResultPanel,self.flag)
HarmonyManager.WarPowerChangeNotify(TempData.dynamicId)
end)
else
@ -89,6 +90,7 @@ function RoleChooseListPanel:BindEvent()
-- body
Game.GlobalEvent:DispatchEvent(GameEvent.HongMeng.ChooseData,TempData)
UIManager.OpenPanel(UIName.GongMingResultPanel,self.flag)
HarmonyManager.WarPowerChangeNotify(TempData.dynamicId)
end)
end