修复假战斗报错的问题

dev_chengFeng
gaoxin 2020-07-29 00:02:19 +08:00
parent 95df60b0fe
commit 2980205399
1 changed files with 9 additions and 2 deletions

View File

@ -644,6 +644,7 @@ function RoleView:DoScale(scale, dur, func)
end
self.dsTween = self.GameObject.transform.parent:DOScale(Vector3.one * scale, dur)
:OnComplete(function ()
-- Log("DoScale = "..scale)
if func then
func()
end
@ -664,6 +665,7 @@ end
function RoleView:SetHighLight(isLight, eScale, dur, func)
-- 设置变灰
-- LogGreen(self.role.camp .."|||"..self.role.position.."|||"..tostring(isLight))
if self.isDead then
Util.SetGray(self.GameObject, true)
Util.SetSpineGray(self.RoleLiveGOGraphic, true)
@ -768,6 +770,8 @@ function RoleView:OnSkillCast(skill)
self:ChangeCardSorting(battleSorting + 20)
end
-- LogRed("Cast skill"..self.role.camp..self.role.position)
-- 高亮
BattleManager.PauseBattle()
self.RootPanel.SetRoleHighLight(self, skill:GetDirectTargets(), function()
@ -806,7 +810,9 @@ function RoleView:OnSkillCast(skill)
BattleManager.ResumeBattle()
self:CheckFullSceenSkill(combat, skill)
-- 取消高亮
self:DelayFunc((combat.KeyFrame + combat.SkillDuration)/1000 + 0.2, function()
self:DelayFunc((combat.KeyFrame + combat.SkillDuration)/1000, function()
-- LogRed("Cast done"..self.role.camp..self.role.position)
self.RootPanel.SetRoleHighLight()
self:ChangeCardSorting(battleSorting + self.role.position)
self.liveRender.transform:SetParent(Util.GetGameObject(self.GameObject, "Mask").transform)
@ -845,8 +851,9 @@ function RoleView:OnSkillCast(skill)
BattleManager.ResumeBattle()
self:CheckFullSceenSkill(combat, skill)
-- 取消高亮
self:DelayFunc((combat.KeyFrame + combat.SkillDuration)/1000 + 0.2, function()
self:DelayFunc((combat.KeyFrame + combat.SkillDuration)/1000, function()
self.RootPanel.SetRoleHighLight()
-- LogRed("Cast done"..self.role.camp..self.role.position)
end)
end)
-- 攻击音效