Major Update - 2.0.0.143
EN: 2.0.0.143 CN: 2.0.0.142 JP: 2.0.0.145 KR: 2.0.0.150
This commit is contained in:
@@ -61,7 +61,7 @@ function TransitionCtrl:_MarkCallback(cb, bIn)
|
||||
local tbCallback = bIn == true and self.tbCallback_In or self.tbCallback_Out
|
||||
table.insert(tbCallback, {cb, false})
|
||||
end
|
||||
function TransitionCtrl:_In(sEventFrom, nType, callback, nParam)
|
||||
function TransitionCtrl:_In(sEventFrom, nType, callback, nParam, bIgnoreCSEvent)
|
||||
local sFrameCount = tostring(CS.UnityEngine.Time.frameCount)
|
||||
if self._panel:GetTransitionStatus() == AllEnum.TransitionStatus.IsPlayingInAnim then
|
||||
printLog("[转场]重复落幕(" .. sEventFrom .. "),落幕 anim playing,frameCount: " .. sFrameCount)
|
||||
@@ -72,33 +72,43 @@ function TransitionCtrl:_In(sEventFrom, nType, callback, nParam)
|
||||
self:_DoCallback(true)
|
||||
elseif self._panel:GetTransitionStatus() == AllEnum.TransitionStatus.IsPlayingOutAnim then
|
||||
printLog("[转场]错误落幕(" .. sEventFrom .. "),开幕 anim playing,frameCount: " .. sFrameCount)
|
||||
if self.timerAnim ~= nil then
|
||||
self.timerAnim:Cancel(true)
|
||||
self.timerAnim = nil
|
||||
end
|
||||
self:_MarkCallback(callback, true)
|
||||
self:OpenTransition(nType, nParam)
|
||||
if bIgnoreCSEvent ~= true then
|
||||
if self.timerAnim ~= nil then
|
||||
self.timerAnim:Cancel(true)
|
||||
self.timerAnim = nil
|
||||
end
|
||||
self:OpenTransition(nType, nParam)
|
||||
end
|
||||
elseif self._panel:GetTransitionStatus() == AllEnum.TransitionStatus.OutAnimDone then
|
||||
printLog("[转场]正常落幕(" .. sEventFrom .. "),开幕 anim done,frameCount: " .. sFrameCount)
|
||||
self:_MarkCallback(callback, true)
|
||||
self:OpenTransition(nType, nParam)
|
||||
if bIgnoreCSEvent ~= true then
|
||||
self:OpenTransition(nType, nParam)
|
||||
end
|
||||
end
|
||||
end
|
||||
function TransitionCtrl:_Out(sEventFrom, callback)
|
||||
function TransitionCtrl:_Out(sEventFrom, callback, bIgnoreCSEvent)
|
||||
local sFrameCount = tostring(CS.UnityEngine.Time.frameCount)
|
||||
if self._panel:GetTransitionStatus() == AllEnum.TransitionStatus.IsPlayingInAnim then
|
||||
printLog("[转场]错误开幕(" .. sEventFrom .. "),落幕 anim playing,frameCount: " .. sFrameCount)
|
||||
if self.timerAnim ~= nil then
|
||||
self.timerAnim:Cancel(true)
|
||||
self.timerAnim = nil
|
||||
end
|
||||
self:_MarkCallback(callback, false)
|
||||
self:CloseTransition()
|
||||
if bIgnoreCSEvent ~= true then
|
||||
if self.timerAnim ~= nil then
|
||||
self.timerAnim:Cancel(true)
|
||||
self.timerAnim = nil
|
||||
end
|
||||
self:CloseTransition()
|
||||
end
|
||||
elseif self._panel:GetTransitionStatus() == AllEnum.TransitionStatus.InAnimDone then
|
||||
printLog("[转场]正常开幕(" .. sEventFrom .. "),落幕 anim done,frameCount: " .. sFrameCount)
|
||||
self:_MarkCallback(callback, false)
|
||||
self:CloseTransition()
|
||||
EventManager.Hit("InputEnable", false, true)
|
||||
if bIgnoreCSEvent ~= true then
|
||||
self:CloseTransition()
|
||||
EventManager.Hit("InputEnable", false, true)
|
||||
else
|
||||
self:_DoCallback(false)
|
||||
end
|
||||
elseif self._panel:GetTransitionStatus() == AllEnum.TransitionStatus.IsPlayingOutAnim then
|
||||
printLog("[转场]重复开幕(" .. sEventFrom .. "),开幕 anim playing,frameCount: " .. sFrameCount)
|
||||
self:_MarkCallback(callback, false)
|
||||
@@ -116,12 +126,15 @@ function TransitionCtrl:OnEvent_SetTrans(nType, callback, nParam)
|
||||
end
|
||||
end
|
||||
function TransitionCtrl:OnEvent_OpenLoadingView(callback, delayTime, fadeTime, tag, nType)
|
||||
self:_In("C#", nType, callback)
|
||||
self:_In("C#", nType, callback, nil, PanelManager.IGNORE_CS_TRANS_EVENT)
|
||||
end
|
||||
function TransitionCtrl:OnEvent_CloseLoadingView(callback, delayTime, fadeTime)
|
||||
self:_Out("C#", callback)
|
||||
self:_Out("C#", callback, PanelManager.IGNORE_CS_TRANS_EVENT)
|
||||
end
|
||||
function TransitionCtrl:OnEvent_UpdateLoadingView(nProgress, sMsg)
|
||||
if PanelManager.IGNORE_CS_TRANS_EVENT == true then
|
||||
return
|
||||
end
|
||||
if self.cs_loading_img ~= nil and self.cs_loading_img:IsNull() == false then
|
||||
NovaAPI.SetImageFillAmount(self.cs_loading_img, nProgress)
|
||||
end
|
||||
@@ -204,9 +217,9 @@ function TransitionCtrl:OnTimer_AnimDone(timer, bIn)
|
||||
self.nType = nil
|
||||
self._mapNode.TransitionRoot.localScale = Vector3.zero
|
||||
EventManager.Hit("InputEnable", true, true)
|
||||
EventManager.Hit(EventId.BlockInput, false)
|
||||
self:_DoCallback(bIn)
|
||||
EventManager.Hit(EventId.TransAnimOutClear)
|
||||
EventManager.Hit(EventId.BlockInput, false)
|
||||
end
|
||||
end
|
||||
function TransitionCtrl:TimeStamp(strTime)
|
||||
@@ -286,7 +299,7 @@ function TransitionCtrl:Set_8(goStyle)
|
||||
end
|
||||
function TransitionCtrl:Set_6(goStyle, nParam)
|
||||
local tr = goStyle.transform
|
||||
for i = AllEnum.MainViewCorner.Role, AllEnum.MainViewCorner.Mainline do
|
||||
for i = AllEnum.MainViewCorner.Role, AllEnum.MainViewCorner.Dorm do
|
||||
tr:GetChild(i).gameObject:SetActive(i == nParam)
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user