back_recharge
parent
36206f288c
commit
ba834ed742
|
@ -217,10 +217,10 @@ local effectList = {
|
|||
local f2 = args[3] * (1 + caster:GetRoleData(RoleDataName.Hit) / (1 + target:GetRoleData(RoleDataName.Dodge)))
|
||||
local rid = args[4]
|
||||
local f3 = args[5]
|
||||
--caster.Event:DispatchEvent(BattleEventName.RoleViewBullet, interval)
|
||||
--if caster.camp == 0 and target.camp == 1 then
|
||||
-- BattleLogic.Event:DispatchEvent(BattleEventName.ZoomChange, target, interval)
|
||||
--end
|
||||
caster.Event:DispatchEvent(BattleEventName.RoleViewBullet, interval)
|
||||
if caster.camp == 0 and target.camp == 1 then
|
||||
BattleLogic.Event:DispatchEvent(BattleEventName.ZoomChange, target, interval)
|
||||
end
|
||||
BattleLogic.WaitForTrigger(interval, function ()
|
||||
local layer
|
||||
if target.BuffMgr:HasBuff(BuffName.Brand, function (buff)
|
||||
|
@ -486,6 +486,33 @@ local effectList = {
|
|||
BattleUtil.CalDamage(caster, target, dt, f1)
|
||||
end)
|
||||
end,
|
||||
--造成[a]到[b]次[c]%的[d]伤害,对[e]造成额外[f]%伤害
|
||||
--a[int],b[int],c[float],d[伤害类型],e[职业],f[float]
|
||||
[29] = function(caster, target, args, interval)
|
||||
local i1 = args[1]
|
||||
local i2 = args[2]
|
||||
local f1 = args[3]
|
||||
local dt = args[4]
|
||||
local pt = args[5]
|
||||
local f2 = args[6]
|
||||
|
||||
local count = Random.RangeInt(i1, i2)
|
||||
local d = interval / count
|
||||
if caster.camp == 0 and target.camp == 1 then
|
||||
BattleLogic.Event:DispatchEvent(BattleEventName.ZoomChange, target, d)
|
||||
end
|
||||
for i=1, count do
|
||||
BattleLogic.WaitForTrigger(d * (i-1), function ()
|
||||
caster.Event:DispatchEvent(BattleEventName.RoleViewBullet, d)
|
||||
BattleLogic.WaitForTrigger(d, function ()
|
||||
if target.professionId == pt then
|
||||
f1 = f1 + f2
|
||||
end
|
||||
BattleUtil.CalDamage(caster, target, dt, f1)
|
||||
end)
|
||||
end)
|
||||
end
|
||||
end,
|
||||
}
|
||||
|
||||
return effectList
|
|
@ -2,7 +2,6 @@ local effect = require("Modules/Battle/Logic/Base/Effect")
|
|||
local floor = math.floor
|
||||
local max = math.max
|
||||
local min = math.min
|
||||
local gameFrameRate = BattleLogic.GameFrameRate
|
||||
--local BattleConst = BattleConst
|
||||
--local RoleDataName = RoleDataName
|
||||
--local BattleEventName = BattleEventName
|
||||
|
@ -150,10 +149,15 @@ end
|
|||
|
||||
function Skill:Dispose()
|
||||
local effectGroup
|
||||
local effect
|
||||
while self.effectList.size > 0 do
|
||||
effectGroup = self.effectList.buffer[self.effectList.size]
|
||||
for k=1, #effectGroup[3] do
|
||||
effectPool:Put(effectGroup[3][k])
|
||||
effect = effectGroup[3][k]
|
||||
for j=1, #effect[2] do
|
||||
effect[2][j] = nil
|
||||
end
|
||||
effectPool:Put(effect)
|
||||
effectGroup[3][k] = nil
|
||||
end
|
||||
effectGroupPool:Put(effectGroup)
|
||||
|
|
Loading…
Reference in New Issue