Merge branch 'dev' of git.juzugame.com:b6-client/b6-lua into dev
This commit is contained in:
commit
9ac84611b4
@ -230,7 +230,7 @@ function BattleUnitComp:stopRunAction()
|
||||
end
|
||||
|
||||
function BattleUnitComp:playAnimation(name, loop, forceRefresh)
|
||||
if name == SPINE_ANIMATION_NAME.HIT or name == SPINE_ANIMATION_NAME.BLOCK then
|
||||
if name == self.curHurtName or name == SPINE_ANIMATION_NAME.BLOCK then
|
||||
self.isPlayingSubAni = true
|
||||
end
|
||||
self.currAnimationName = name
|
||||
@ -294,6 +294,9 @@ function BattleUnitComp:beforeAttack(actionState)
|
||||
self.team:setCentralizedAttack(true)
|
||||
self.battleController:setIsPauseHpProgress(true)
|
||||
self.curAttackActionState = actionState
|
||||
if actionState == BattleConst.ATTACK_ACTION_STATE.NORMAL then
|
||||
self:checkPassiveEvent(PASSIVE_EVENT.ON_UNI_ATTACK_START, self)
|
||||
end
|
||||
end
|
||||
|
||||
function BattleUnitComp:useAssistingSkill(count, delay, callback)
|
||||
@ -679,7 +682,7 @@ function BattleUnitComp:updateIdleSubAni(...)
|
||||
if not self.currAnimationName or not self.isPlayingSubAni then
|
||||
return
|
||||
end
|
||||
if self.currAnimationName == SPINE_ANIMATION_NAME.HIT then
|
||||
if self.currAnimationName == self.curHurtName then
|
||||
self:updateHurt(...)
|
||||
elseif self.currAnimationName == SPINE_ANIMATION_NAME.BLOCK then
|
||||
self:updateBlock(...)
|
||||
@ -1535,7 +1538,15 @@ function BattleUnitComp:takeDamageOrCure(atker, num, effectType, effectStatus, d
|
||||
end
|
||||
end
|
||||
elseif num > 0 then -- 治疗
|
||||
self:showEffectNumber(BattleConst.EFFECT_COLOR_GREEN, BattleConst.EFFECT_TYPE_BUFF, "+" .. num, x, y, 0)
|
||||
local time = Time:getServerTime()
|
||||
if self.lastHealTime == time then
|
||||
self.lastSameTimeHealCount = self.lastSameTimeHealCount + 1
|
||||
else
|
||||
self.lastHealTime = time
|
||||
self.lastSameTimeHealCount = 0
|
||||
end
|
||||
local delayTime = self.lastSameTimeHealCount * 0.1
|
||||
self:showEffectNumber(BattleConst.EFFECT_COLOR_GREEN, BattleConst.EFFECT_TYPE_BUFF, "+" .. num, x, y, delayTime)
|
||||
end
|
||||
local hpPercent = self.unitEntity:getHpPercent()
|
||||
self.battleController:refreshHp(self.side, hp, hpPercent)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user