diff --git a/Assets/ManagedResources/~Lua/Modules/Battle/Logic/Base/Passivity.lua b/Assets/ManagedResources/~Lua/Modules/Battle/Logic/Base/Passivity.lua index 8ae4949cdc..1f786cf6db 100644 --- a/Assets/ManagedResources/~Lua/Modules/Battle/Logic/Base/Passivity.lua +++ b/Assets/ManagedResources/~Lua/Modules/Battle/Logic/Base/Passivity.lua @@ -3943,7 +3943,7 @@ local passivityList = { -- 检测技能伤害治疗加成 local f = BattleUtil.CheckSkillDamageHeal(f1, role, target) -- 治疗自己 - BattleUtil.ApplyTreat(role, role, floor(BattleUtil.ErrorCorrection(finalDmg * f))) + BattleUtil.ApplyTreat(role, role, floor(BattleUtil.ErrorCorrection(damage * f))) end end role.Event:AddEvent(BattleEventName.RoleHit, onHit) diff --git a/Assets/ManagedResources/~Lua/Modules/Battle/View/Unit/BuffCtrl.lua b/Assets/ManagedResources/~Lua/Modules/Battle/View/Unit/BuffCtrl.lua index 7db1e66891..b4343eec14 100644 --- a/Assets/ManagedResources/~Lua/Modules/Battle/View/Unit/BuffCtrl.lua +++ b/Assets/ManagedResources/~Lua/Modules/Battle/View/Unit/BuffCtrl.lua @@ -208,6 +208,16 @@ function BuffCtrl:AddBuffIcon(buff, icon) self.BuffIconList[key]:SetCount(self.BuffIconList[key].count+1) return end + elseif buffType == BuffName.Immune then + if self.BuffIconList[key].immuneType==currBuff.immuneType then + self.BuffIconList[key]:SetCount(self.BuffIconList[key].count+1) + return + end + elseif buffType == BuffName.Curse then + if self.BuffIconList[key].curseType==currBuff.curseType then + self.BuffIconList[key]:SetCount(self.BuffIconList[key].count+1) + return + end end end end @@ -287,6 +297,26 @@ function BuffCtrl:RemoveBuffIcon(buff) end return end + elseif buffType == BuffName.Immune then + if self.BuffIconList[key].immuneType==buff.immuneType then + if floor==1 then + self.BuffIconList[key]:Dispose() + self.BuffIconList[key] = nil + else + self.BuffIconList[key]:SetCount(floor-1) + end + return + elseif buffType == BuffName.Curse then + if self.BuffIconList[key].curseType==buff.curseType then + if floor==1 then + self.BuffIconList[key]:Dispose() + self.BuffIconList[key] = nil + else + self.BuffIconList[key]:SetCount(floor-1) + end + return + end + end end end end diff --git a/Assets/ManagedResources/~Lua/Modules/Battle/View/Unit/BuffView.lua b/Assets/ManagedResources/~Lua/Modules/Battle/View/Unit/BuffView.lua index 5595c3617e..e43477b9bf 100644 --- a/Assets/ManagedResources/~Lua/Modules/Battle/View/Unit/BuffView.lua +++ b/Assets/ManagedResources/~Lua/Modules/Battle/View/Unit/BuffView.lua @@ -14,7 +14,8 @@ function BuffView.New(go, buff, icon) instance.buffDamageFactor = buff.damageFactor instance.buffCtrlType = buff.ctrlType instance.healValue = buff.healValue - + instance.immuneType = buff.immuneType + instance.curseType = buff.curseType instance.levelText = Util.GetGameObject(go, "level"):GetComponent("Text") instance.layerText = Util.GetGameObject(go, "layer"):GetComponent("Text") instance.roundText = Util.GetGameObject(go, "round"):GetComponent("Text")