From f770ccc06f86d6cea529e49ca2631edfe365db34 Mon Sep 17 00:00:00 2001 From: 1 <1@72wo.cn> Date: Tue, 30 Dec 2025 15:04:21 +0000 Subject: [PATCH] =?UTF-8?q?```feat(fight):=20=E6=96=B0=E5=A2=9E=E6=88=98?= =?UTF-8?q?=E6=96=97=E6=95=88=E6=9E=9C60/699/700=E5=B9=B6=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E5=AE=A0=E7=89=A9=E7=89=A9=E5=93=81=E4=BD=BF=E7=94=A8?= =?UTF-8?q?=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- logic/controller/item_use.go | 6 +--- logic/service/fight/boss/NewSeIdx_60.go | 22 +++++++++++++ logic/service/fight/boss/NewSeIdx_699.go | 39 ++++++++++++++++++++++++ logic/service/fight/boss/NewSeIdx_700.go | 29 ++++++++++++++++++ public/config/bossbuff和特性.xml | 10 +++--- 5 files changed, 96 insertions(+), 10 deletions(-) create mode 100644 logic/service/fight/boss/NewSeIdx_699.go create mode 100644 logic/service/fight/boss/NewSeIdx_700.go diff --git a/logic/controller/item_use.go b/logic/controller/item_use.go index aa50dd528..4650243c9 100644 --- a/logic/controller/item_use.go +++ b/logic/controller/item_use.go @@ -52,12 +52,8 @@ func (h Controller) UsePetItemOutOfFight(data *item.C2S_USE_PET_ITEM_OUT_OF_FIGH } oldPetCatchTime := currentPet.CatchTime oldPet := c.Service.Pet.PetInfo_One_Unscoped(currentPet.OldCatchTime) - - copier.CopyWithOption(currentPet, oldPet.Data, copier.Option{DeepCopy: true}) - // println("currentPet.CatchTime", currentPet.CatchTime, currentPet.OldCatchTime) + currentPet = &oldPet.Data currentPet.CatchTime = oldPetCatchTime - - currentPet.EffectInfo = oldPet.Data.EffectInfo } else { handler := item.PetItemRegistry.GetHandler(data.ItemID) if handler == nil { diff --git a/logic/service/fight/boss/NewSeIdx_60.go b/logic/service/fight/boss/NewSeIdx_60.go index 5304b863e..ad640bd39 100644 --- a/logic/service/fight/boss/NewSeIdx_60.go +++ b/logic/service/fight/boss/NewSeIdx_60.go @@ -1,7 +1,10 @@ package effect import ( + "blazing/logic/service/fight/info" "blazing/logic/service/fight/input" + + "github.com/alpacahq/alpacadecimal" ) // 60. 受到攻击时n%几率使受到的伤害降低m点(a1: n, a2: m) @@ -10,6 +13,25 @@ type NewSel60 struct { NewSel0 } +func (e *NewSel60) Damage_SUB_ex(t *info.DamageZone) bool { + if e.ID().GetCatchTime() != e.Ctx().Our.CurrentPet.Info.CatchTime { + return true + } + if e.Ctx().SkillEntity == nil { + return true + } + + if t.Type != info.DamageType.Red { + return true + } + success, _, _ := e.Input.Player.Roll(int(e.Args()[0].IntPart()), 100) + if !success { + return true + } + t.Damage = t.Damage.Sub(alpacadecimal.NewFromInt(int64(e.Args()[1].IntPart()))) + + return true +} func init() { input.InitEffect(input.EffectType.NewSel, 60, &NewSel60{}) } diff --git a/logic/service/fight/boss/NewSeIdx_699.go b/logic/service/fight/boss/NewSeIdx_699.go new file mode 100644 index 000000000..92757b157 --- /dev/null +++ b/logic/service/fight/boss/NewSeIdx_699.go @@ -0,0 +1,39 @@ +package effect + +import ( + "blazing/logic/service/fight/info" + "blazing/logic/service/fight/input" + + "github.com/alpacahq/alpacadecimal" +) + +// 60. "20%弹60点固定伤害" StarLevel="0 + +type NewSel699 struct { + NewSel0 +} + +func (e *NewSel699) Skill_Use_ex() bool { + if e.ID().GetCatchTime() != e.Ctx().Our.CurrentPet.Info.CatchTime { + return true + } + if e.Ctx().SkillEntity == nil { + return true + } + + success, _, _ := e.Input.Player.Roll(int(e.Args()[0].IntPart()), 100) + if !success { + return true + } + + e.Ctx().Opp.Damage(e.Ctx().Our, &info.DamageZone{ + + Type: info.DamageType.Fixed, + Damage: alpacadecimal.Min(e.Ctx().Opp.SumDamage, e.Args()[1]), + }) + + return true +} +func init() { + input.InitEffect(input.EffectType.NewSel, 699, &NewSel699{}) +} diff --git a/logic/service/fight/boss/NewSeIdx_700.go b/logic/service/fight/boss/NewSeIdx_700.go new file mode 100644 index 000000000..e33512917 --- /dev/null +++ b/logic/service/fight/boss/NewSeIdx_700.go @@ -0,0 +1,29 @@ +package effect + +import ( + "blazing/logic/service/fight/action" + "blazing/logic/service/fight/input" +) + +// 60.回复造成伤害的6% + +type NewSel700 struct { + NewSel0 +} + +func (e *NewSel700) Skill_Useed() bool { + if e.ID().GetCatchTime() != e.Ctx().Our.CurrentPet.Info.CatchTime { + return true + } + if e.Ctx().SkillEntity == nil { + return true + } + + e.Input.Heal( + e.Ctx().Our, &action.SelectSkillAction{}, e.Ctx().Our.SumDamage.Div(e.Args()[1]), + ) + return true +} +func init() { + input.InitEffect(input.EffectType.NewSel, 700, &NewSel700{}) +} diff --git a/public/config/bossbuff和特性.xml b/public/config/bossbuff和特性.xml index 8fe9b8da6..3ce2f3110 100644 --- a/public/config/bossbuff和特性.xml +++ b/public/config/bossbuff和特性.xml @@ -901,11 +901,11 @@ - - - - - + + + + +