【大闹天宫】角色爬塔,界面不会跟随显示

dev_chengFeng
zhangqiang 2021-08-11 21:21:11 +08:00
parent 2d065b675c
commit c0c3013e2f
1 changed files with 12 additions and 23 deletions

View File

@ -7,6 +7,7 @@ local timer = Timer.New()
-- local npc -- local npc
local GetCurNodeInfo = {}--当前操作层数据 local GetCurNodeInfo = {}--当前操作层数据
-- local SkeletonGraphic--动画组件 -- local SkeletonGraphic--动画组件
local isPlayerMove = false--是否在播放人物行走动画 local isPlayerMove = false--是否在播放人物行走动画
local isAllHaveAttack = false--是否有状态不一致情况 说明不是失败过 就是未领取圣物状态 local isAllHaveAttack = false--是否有状态不一致情况 说明不是失败过 就是未领取圣物状态
local nodeGoTable = {} local nodeGoTable = {}
@ -241,26 +242,14 @@ function ExpeditionMainPanel:OnShowNodeData(isMoveGrid)
ExpeditionMainPanel:SingleLayNodeShow(layListGrid[i],curAllLayNodeList[i]) ExpeditionMainPanel:SingleLayNodeShow(layListGrid[i],curAllLayNodeList[i])
layListGrid[i]:SetActive(true) layListGrid[i]:SetActive(true)
end end
if isMoveGrid then local curlay = GetCurNodeInfo.lay
local gridH = 2746--self.grid:GetComponent("RectTransform").sizeDelta.y -- local rectH = self.grid.transform.parent:GetComponent("RectTransform").rect.height/2
local rectH = 1656--self.grid.transform.parent:GetComponent("RectTransform").sizeDelta.y -- local y = (#curAllLayNodeList - curlay) * 183.3 + 638.55 - rectH
local endH = gridH - rectH local rectH = self.grid.transform.parent:GetComponent("RectTransform").rect.height/2
local curlay = GetCurNodeInfo.lay local y = 2746.5 - ((curlay - 1) * 183.3) - rectH;
if curlay <= 6 then
local y = endH / 6 self.grid.transform:DOLocalMove(Vector3.New(0,y,0), 0.5, false):SetEase(Ease.Linear)
y = endH - (curlay - 1) * y -- self.grid:GetComponent("RectTransform").anchoredPosition = Vector3.New(0,y,0)
self.grid:GetComponent("RectTransform").anchoredPosition = Vector3.New(0,y,0)
end
end
--self.ScrollView:SetData(curAllLayNodeList, function (index, go)
-- self:SingleLayNodeShow(go,curAllLayNodeList[index],(#AllLayNodeList - index) + 1)
--end)
--LogError("#AllLayNodeList - GetCurNodeInfo.lay "..#AllLayNodeList - GetCurNodeInfo.lay)
--local curIndex = #AllLayNodeList - GetCurNodeInfo.lay
--if curIndex == 0 then
-- curIndex = curIndex + 1
--end
--self.ScrollView:SetIndex(curIndex)
end end
--实例化每层信息 --实例化每层信息
@ -706,11 +695,11 @@ function ExpeditionMainPanel:PlayerMoveFun()
if targetPosGoAndData.curNodeData.type == ExpeditionNodeType.Shop then if targetPosGoAndData.curNodeData.type == ExpeditionNodeType.Shop then
NetManager.StoreNodeRequest(targetPosGoAndData.curNodeData.sortId,function () NetManager.StoreNodeRequest(targetPosGoAndData.curNodeData.sortId,function ()
UIManager.OpenPanel(UIName.ExpeditionMonsterInfoPopup,EXPEDITON_POPUP_TYPE.Shop,targetPosGoAndData.curNodeData,3,function () UIManager.OpenPanel(UIName.ExpeditionMonsterInfoPopup,EXPEDITON_POPUP_TYPE.Shop,targetPosGoAndData.curNodeData,3,function ()
self:OnShowNodeData() self:OnShowNodeData(true)
end) end)
end) end)
else else
self:OnShowNodeData() self:OnShowNodeData(true)
end end
isPlayerMove = false isPlayerMove = false
end, 0.8) end, 0.8)
@ -740,7 +729,7 @@ function ExpeditionMainPanel:SelfUpdataPanelShow()
end end
function ExpeditionMainPanel:RefreshManagerData() function ExpeditionMainPanel:RefreshManagerData()
NetManager.GetExpeditionRequest(ExpeditionManager.expeditionLeve,function () NetManager.GetExpeditionRequest(ExpeditionManager.expeditionLeve,function ()
self:OnShowNodeData() self:OnShowNodeData(true)
end) end)
end end
function ExpeditionMainPanel:HeroResurgence() function ExpeditionMainPanel:HeroResurgence()