[战斗]========被动299 修改
parent
c57a5ec8eb
commit
72844ea7ab
|
|
@ -6230,11 +6230,18 @@ local passivityList = {
|
|||
local f1 = args[2]
|
||||
|
||||
local OnDead = function(atkRole)
|
||||
local arr = BattleUtil.ChooseTarget(role, 100000)
|
||||
for i=1, #arr do
|
||||
local val = floor(BattleUtil.FP_Mul(f1, arr[i]:GetRoleData(BattlePropList[pro])))
|
||||
BattleUtil.CalTreat(role, arr[i], val)
|
||||
end
|
||||
BattleLogic.WaitForTrigger(BattleLogic.GameDeltaTime, function () --延时一帧做处理,我方场上所有单位都结算死亡以后,再处理299被动回血
|
||||
local arr = BattleUtil.ChooseTarget(role, 100000)
|
||||
if arr==nil then
|
||||
return
|
||||
end
|
||||
for i=1, #arr do
|
||||
if not arr[i]:IsDead() then
|
||||
local val = floor(BattleUtil.FP_Mul(f1, arr[i]:GetRoleData(BattlePropList[pro])))
|
||||
BattleUtil.CalTreat(role, arr[i], val)
|
||||
end
|
||||
end
|
||||
end)
|
||||
end
|
||||
role.Event:AddEvent(BattleEventName.RoleDead, OnDead)
|
||||
end,
|
||||
|
|
|
|||
Loading…
Reference in New Issue