【战斗】====清除盾效果添加破盾提示文字,清除免疫,持续伤害,控制效果添加清除提示;被动278修改;被动添加排序;控制效果结束修改
parent
fd9fc05994
commit
2e886d4524
|
@ -2234,4 +2234,6 @@
|
||||||
[12233] = GetLanguageStrById("核心神将:"),
|
[12233] = GetLanguageStrById("核心神将:"),
|
||||||
[12234] = GetLanguageStrById("%d次内必得金色及以上魂印"),
|
[12234] = GetLanguageStrById("%d次内必得金色及以上魂印"),
|
||||||
[12235] = GetLanguageStrById("重连失败,请重新登录"),
|
[12235] = GetLanguageStrById("重连失败,请重新登录"),
|
||||||
|
[12236] = GetLanguageStrById("破盾"),
|
||||||
|
[12237] = GetLanguageStrById("清除"),
|
||||||
}
|
}
|
||||||
|
|
|
@ -976,7 +976,11 @@ end
|
||||||
|
|
||||||
function this.GetArtFontConfig(_ArtFontType)
|
function this.GetArtFontConfig(_ArtFontType)
|
||||||
if _ArtFontType == BattleArtFontType.Immune then
|
if _ArtFontType == BattleArtFontType.Immune then
|
||||||
return {type = 2, content = Language[10203]}
|
return {type = 2, content = Language[10203]}
|
||||||
|
elseif _ArtFontType == BattleArtFontType.Shield then
|
||||||
|
return {type = 2, content = Language[12236]}
|
||||||
|
elseif _ArtFontType == BattleArtFontType.clear then
|
||||||
|
return {type = 2, content = Language[12237]}
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -227,6 +227,13 @@ function BuffManager:ClearBuff(target, func)
|
||||||
while idx <= list.size do
|
while idx <= list.size do
|
||||||
local buff = list.buffer[idx]
|
local buff = list.buffer[idx]
|
||||||
if buff.target == target and (not func or (func and buff.clear and func(buff))) then
|
if buff.target == target and (not func or (func and buff.clear and func(buff))) then
|
||||||
|
if func and func(buff) then
|
||||||
|
if buff.type== BuffName.Shield then
|
||||||
|
buff.target.Event:DispatchEvent(BattleEventName.ShowHintText, BattleArtFontType.Shield)
|
||||||
|
elseif buff.type== BuffName.DOT or buff.type==BuffName.Control or buff.type==BuffName.Immune then
|
||||||
|
buff.target.Event:DispatchEvent(BattleEventName.ShowHintText, BattleArtFontType.clear)
|
||||||
|
end
|
||||||
|
end
|
||||||
buff:OnEnd()
|
buff:OnEnd()
|
||||||
buff.target.Event:DispatchEvent(BattleEventName.BuffEnd, buff)
|
buff.target.Event:DispatchEvent(BattleEventName.BuffEnd, buff)
|
||||||
putBuff(buff)
|
putBuff(buff)
|
||||||
|
|
|
@ -5664,7 +5664,11 @@ local passivityList = {
|
||||||
if defRole and defRole.camp~=role.camp and skill.owner==role and (skill.type==BattleSkillType.Special or skill.type==BattleSkillType.Extra) then
|
if defRole and defRole.camp~=role.camp and skill.owner==role and (skill.type==BattleSkillType.Special or skill.type==BattleSkillType.Extra) then
|
||||||
BattleUtil.RandomAction(pro, function()
|
BattleUtil.RandomAction(pro, function()
|
||||||
BattleLogic.BuffMgr:ClearBuff(defRole, function(buff)
|
BattleLogic.BuffMgr:ClearBuff(defRole, function(buff)
|
||||||
return buff.type == BuffName.Immune and (buff.immuneType == 4 or buff.immuneType == 2)
|
if buff.type == BuffName.Immune and (buff.immuneType == 4 or buff.immuneType == 2) then
|
||||||
|
buff.target.Event:DispatchEvent(BattleEventName.ShowHintText, BattleArtFontType.clear)
|
||||||
|
return true
|
||||||
|
end
|
||||||
|
return false
|
||||||
end)
|
end)
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
@ -6081,7 +6085,7 @@ local passivityList = {
|
||||||
local v1=args[2]
|
local v1=args[2]
|
||||||
local OnBuffEnd=function(buff)
|
local OnBuffEnd=function(buff)
|
||||||
if buff and not buff.target:IsDead() and buff.caster==role and buff.type==BuffName.Shield then
|
if buff and not buff.target:IsDead() and buff.caster==role and buff.type==BuffName.Shield then
|
||||||
local val = floor(BattleUtil.FP_Mul(v1, role:GetRoleData(BattlePropList[pro])))
|
local val = floor(BattleUtil.FP_Mul(v1, buff.target:GetRoleData(BattlePropList[pro])))
|
||||||
BattleUtil.CalTreat(role,buff.target, val)
|
BattleUtil.CalTreat(role,buff.target, val)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -40,6 +40,10 @@ end
|
||||||
|
|
||||||
--效果结束时调用一次
|
--效果结束时调用一次
|
||||||
function Control:OnEnd()
|
function Control:OnEnd()
|
||||||
|
--如果还有同类型的控制效果,就返回
|
||||||
|
if BattleLogic.BuffMgr:HasBuff(self.target, BuffName.Control, function (buff) return buff~=self and buff.ctrlType == self.ctrlType end) then
|
||||||
|
return
|
||||||
|
end
|
||||||
if self.ctrlType == 1 then --眩晕
|
if self.ctrlType == 1 then --眩晕
|
||||||
self.target.ctrl_dizzy = false
|
self.target.ctrl_dizzy = false
|
||||||
elseif self.ctrlType == 2 then --沉默
|
elseif self.ctrlType == 2 then --沉默
|
||||||
|
|
|
@ -328,4 +328,6 @@ BattleRoleElementType = {
|
||||||
|
|
||||||
BattleArtFontType = {
|
BattleArtFontType = {
|
||||||
Immune = 1, -- 免疫文字
|
Immune = 1, -- 免疫文字
|
||||||
|
Shield = 2, --破盾文字
|
||||||
|
clear = 3, --清除文字
|
||||||
}
|
}
|
|
@ -84,6 +84,7 @@ function RoleLogic:Init(uid, data, position)
|
||||||
self.type = BattleUnitType.Role
|
self.type = BattleUnitType.Role
|
||||||
self.passiveList = {}
|
self.passiveList = {}
|
||||||
if data.passivity and #data.passivity > 0 then
|
if data.passivity and #data.passivity > 0 then
|
||||||
|
table.sort(data.passivity,function(a,b)return a[1] < b[1] end)
|
||||||
for i = 1, #data.passivity do
|
for i = 1, #data.passivity do
|
||||||
local v = data.passivity[i]
|
local v = data.passivity[i]
|
||||||
local passivityId=v[1]
|
local passivityId=v[1]
|
||||||
|
@ -96,7 +97,7 @@ function RoleLogic:Init(uid, data, position)
|
||||||
if BattleUtil.Passivity[id] then
|
if BattleUtil.Passivity[id] then
|
||||||
BattleUtil.Passivity[id](self, args,passivityId,judge)
|
BattleUtil.Passivity[id](self, args,passivityId,judge)
|
||||||
-- 加入被动列表
|
-- 加入被动列表
|
||||||
table.insert(self.passiveList, {id, args})
|
table.insert(self.passiveList, {id, args,passivityId})
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue