【战斗】======技能132-140提交

dev_chengFeng
wangzhenxing 2021-11-25 15:07:40 +08:00
parent b15eaf8b19
commit aff13f8904
1 changed files with 211 additions and 0 deletions

View File

@ -2517,6 +2517,217 @@ local effectList = {
target:AddBuff(buff)
end)
end,
--造成主角[a]*[b]攻击伤害
--a[int 1:等级 2.战斗力],b[int]
[132] = function(caster, target, args, interval, skill)
local type = args[1]
local pro = args[2]
BattleLogic.WaitForTrigger(interval, function ()
local value=0
if type==1 then
value=caster.star
elseif type==2 then
value=caster.teamDamage
end
local damage=floor(value*pro)
BattleUtil.FinalDamageCountShield(nil,caster, target,damage)
end)
end,
--对目标造成玩家[a]*[b]的伤害,伤害的[c]%转化为生命,治疗生命百分比最[d]的英雄
--a[int 1:等级 2.战斗力],b[int],c[float],d[int 1:低 0:高]
[133] = function(caster, target, args, interval, skill)
local type=args[1]
local f1 = args[2]
local f2 = args[3]
local sort = args[4]
BattleLogic.WaitForTrigger(interval, function ()
local value=0
if type==1 then
value=caster.star
elseif type==2 then
value=caster.teamDamage
end
local damage=floor(value*f1)
BattleUtil.FinalDamageCountShield(nil,caster, target,damage)
local hp=floor(damage*f2)
local arr = RoleManager.NoOrder(function (r) return r.camp == caster.camp end,false,true)
BattleUtil.SortByHpFactor(arr,sort)
BattleUtil.CalTreat(caster, arr[1],hp,1,skill)
end)
end,
--对目标造成主角[a]*[b]的伤害,并有[c]%概率给目标上[d]类型[e]效果buff持续[f]回合,buff具体参数1 [g]
--a[int 1:等级 2.战斗力],b[int],c[float],d[int],e[int],f[int],g[int]
[134] = function(caster, target, args, interval, skill)
local type=args[1]
local v1 = args[2]
local p1 = args[3]
local t1 = args[4]
local t2 = args[5]
local r1 = args[6]
local v2 = args[7]
BattleLogic.WaitForTrigger(interval, function ()
local value=0
if type==1 then
value=caster.star
elseif type==2 then
value=caster.teamDamage
end
local damage=floor(value*v1)
BattleUtil.FinalDamageCountShield(nil,caster, target,damage)
if t1==BuffName.Control then
BattleUtil.RandomControl(p1,t2,caster,target,r1,skill)
elseif t1==BuffName.DOT then
BattleUtil.RandomDot(p1,t2,caster,target,r1,1,value*v2,skill)
end
end)
end,
--对目标造成主角[a]*[b]的伤害,如果目标处于[c]类型[d]效果,则[e]%概率给目标添加[f]类型[g]效果,持续[h]回合
--a[int 1:等级 2.战斗力],b[int],c[int],d[int],e[float],f[int],g[int],h[int]
[135] = function(caster, target, args, interval, skill)
local type=args[1]
local v1 = args[2]
local t1 = args[3]
local t2 = args[4]
local pro = args[5]
local t3 = args[6]
local t4 = args[7]
local r1 =args[8]
BattleLogic.WaitForTrigger(interval, function ()
local value=0
if type==1 then
value=caster.star
elseif type==2 then
value=caster.teamDamage
end
local damage=floor(value*v1)
BattleUtil.FinalDamageCountShield(nil,caster, target,damage)
if BattleLogic.BuffMgr:HasBuff(target, t1, function (buff)
if t1==BuffName.DOT then
return buff.damageType==t2
end
end) then
if t3==BuffName.Control then
BattleUtil.RandomControl(pro,t4,caster,target,r1,skill)
end
end
end)
end,
--对目标造成主角[a]*[b]攻击伤害,目标每减少[c]个伤害增加[d]%
--a[int 1:等级 2.战斗力],b[int],c[int],d[float]
[136] = function(caster, target, args, interval, skill)
local type = args[1]
local pro = args[2]
local i1 = args[3]
local v1 = args[4]
BattleLogic.WaitForTrigger(interval, function ()
local value=0
if type==1 then
value=caster.star
elseif type==2 then
value=caster.teamDamage
end
-- 改变值 = 技能最大目标数 - 当前目标数
local maxNum = skill:GetMaxTargetNum()
local curNum = #skill:GetDirectTargets()
local lessNum = max(maxNum - curNum, 0)
local level = math.floor(lessNum/i1)
local extra = BattleUtil.ErrorCorrection(level * i1)
local damage=floor(value*pro*(1+extra))
BattleUtil.FinalDamageCountShield(nil,caster, target,damage)
end)
end,
--对目标造成主角[a]*[b]攻击伤害,如果击杀目标,随机减少敌方[c]个神将[d]点怒气
--a[int 1:等级 2.战斗力],b[int],c[int],d[float]
[137] = function(caster, target, args, interval, skill)
local type = args[1]
local pro = args[2]
local i1 = args[3]
local v1 = args[4]
BattleLogic.WaitForTrigger(interval, function ()
local value=0
if type==1 then
value=caster.star
elseif type==2 then
value=caster.teamDamage
end
local damage=floor(value*pro)
BattleUtil.FinalDamageCountShield(nil,caster, target,damage)
if target.isDead then
local arr = RoleManager.Query(function (r) return r.camp == target.camp end)
for i = 1, i1 do
local count = Random.RangeInt(1,#arr)
BattleUtil.CalRage(caster,arr[count],v1,CountTypeName.Sub)
end
end
end)
end,
--技能目标如果大于[a],改变[b]目标[c]点怒气
--a[int],b[int],c[int]
[138] = function(caster, target, args, interval, skill)
local num = args[1]
local ct = args[2]
local v1 = args[3]
BattleLogic.WaitForTrigger(interval, function ()
local curNum = #skill:GetDirectTargets()
if curNum>num then
BattleUtil.CalRage(caster,target,v1,ct)
end
end)
end,
--对目标造成主角[a]*[b]的伤害,如果目标处于[c]类型[d]效果,则伤害改变[e][f]%
--a[int 1:等级 2.战斗力],b[int],c[int],d[int],e[int],f[float]
[139] = function(caster, target, args, interval, skill)
local type=args[1]
local v1 = args[2]
local t1 = args[3]
local t2 = args[4]
local ct = args[5]
local v2 = args[6]
BattleLogic.WaitForTrigger(interval, function ()
local value=0
if type==1 then
value=caster.star
elseif type==2 then
value=caster.teamDamage
end
local add=0
if BattleLogic.BuffMgr:HasBuff(target, t1, function (buff)
if t1==BuffName.DOT then
return buff.damageType==t2
end
end) then
add=v2
end
local damage=floor(value*v1)
damage=floor(BattleUtil.CountValue(damage,add,ct))
BattleUtil.FinalDamageCountShield(nil,caster, target,damage)
end)
end,
--造成主角[a]*[b]攻击伤害,概率[c]改变[d]目标[e]点怒气
--a[int 1:等级 2.战斗力],b[int],c[float],d[int],e[int]
[140] = function(caster, target, args, interval, skill)
local type = args[1]
local pro = args[2]
local p1 = args[3]
local ct = args[4]
local v1 = args[5]
BattleLogic.WaitForTrigger(interval, function ()
local value=0
if type==1 then
value=caster.star
elseif type==2 then
value=caster.teamDamage
end
local damage=floor(value*pro)
BattleUtil.FinalDamageCountShield(nil,caster, target,damage)
BattleUtil.RandomAction(p1, function ()
BattleUtil.CalRage(caster,target,v1,ct)
end)
end)
end,
}
return effectList