普工经验
This commit is contained in:
parent
65f695030e
commit
503b50c03e
@ -504,6 +504,9 @@ function BattleUnitComp:updateBuffState(buff, num)
|
||||
end
|
||||
|
||||
function BattleUnitComp:onSkillTakeEffect(skill)
|
||||
if skill == self.unitEntity:getNormalSkill() then
|
||||
self.battleController:addBattleExp(self.side)
|
||||
end
|
||||
local effectList = skill:getEffectList()
|
||||
if effectList == nil then
|
||||
return
|
||||
|
||||
@ -1165,10 +1165,12 @@ function BattleController:snapshotBoard()
|
||||
return snapshot
|
||||
end
|
||||
|
||||
function BattleController:addBattleExp(exp)
|
||||
if not self.battleData or not exp then
|
||||
function BattleController:addBattleExp(side, exp)
|
||||
if side ~= BattleConst.SIDE_ATK or not self.battleData then
|
||||
return
|
||||
end
|
||||
|
||||
exp = exp or 1
|
||||
self.battleData:addExp(exp)
|
||||
end
|
||||
|
||||
@ -1222,12 +1224,11 @@ local function _addCurRoundAttr(self, instruction, callback)
|
||||
end
|
||||
|
||||
local function _assisting(self, instruction, callback)
|
||||
self:addBattleExp(instruction.count)
|
||||
self:addBattleExp(BattleConst.SIDE_ATK, instruction.count) -- 先直接加
|
||||
callback()
|
||||
end
|
||||
|
||||
local function _generalAttack(self, instruction, callback)
|
||||
self:addBattleExp(instruction.count) -- 先直接加
|
||||
self.atkTeam:useNormalSkill(instruction.skillMatch, instruction.count, callback)
|
||||
end
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user