【战斗】修复桃子技能错误

dev_chengFeng
gaoxin 2020-10-20 00:39:27 +08:00
parent c6704e6ed4
commit 3625da459f
1 changed files with 4 additions and 2 deletions

View File

@ -3618,7 +3618,8 @@ local passivityList = {
-- 计算分摊伤害
local fenDamage = finalDamage * ff -- 需要分摊的总伤害
list = BattleUtil.SortByProp(list, RoleDataName.Hp, 0)
--根据血量百分比排序
BattleUtil.SortByHpFactor(list, 0)
local targets = {role, list[1], list[2]}
local fd = floor(BattleUtil.ErrorCorrection(fenDamage/#targets)) -- 每个人需要分摊的伤害
@ -3630,7 +3631,8 @@ local passivityList = {
-- 平分给别人
if fd > 0 then
for i = 2, #targets do
BattleUtil.FinalDamage(skill, atkRole, targets[i], fd, nil, 0, dotType)
--不触发被动
BattleUtil.FinalDamage(nil, atkRole, targets[i], fd, nil, 0, dotType)
end
end
end