koishi-plugin-ggcevo-game 1.4.96 → 1.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/boss/BattleEffectProcessor.d.ts +54 -0
- package/lib/index.js +373 -18
- package/lib/update.d.ts +6 -0
- package/package.json +1 -1
|
@@ -586,6 +586,60 @@ export declare const BattleEffectProcessor: {
|
|
|
586
586
|
} | null;
|
|
587
587
|
burnLayerAdded: boolean;
|
|
588
588
|
} | null;
|
|
589
|
+
handleGeneMutation: (targetBoss: any) => {
|
|
590
|
+
messages: string[];
|
|
591
|
+
targetUpdates: {
|
|
592
|
+
name: string;
|
|
593
|
+
updates: Partial<BattleStatistics>;
|
|
594
|
+
} | null;
|
|
595
|
+
tempMark: boolean;
|
|
596
|
+
} | null;
|
|
597
|
+
handleRedundancyOptimization: (targetBoss: any, weaponName: string) => {
|
|
598
|
+
isImmune: boolean;
|
|
599
|
+
messages: string[];
|
|
600
|
+
targetUpdates: {
|
|
601
|
+
name: string;
|
|
602
|
+
updates: Partial<BattleStatistics>;
|
|
603
|
+
} | null;
|
|
604
|
+
} | null;
|
|
605
|
+
handleEnvironmentalAdaptation: (targetBoss: any, weaponName: string) => {
|
|
606
|
+
isImmune: boolean;
|
|
607
|
+
messages: string[];
|
|
608
|
+
targetUpdates: {
|
|
609
|
+
name: string;
|
|
610
|
+
updates: Partial<BattleStatistics>;
|
|
611
|
+
} | null;
|
|
612
|
+
} | null;
|
|
613
|
+
handleAcceleratedDifferentiation: (targetBoss: any) => {
|
|
614
|
+
messages: string[];
|
|
615
|
+
targetUpdates: {
|
|
616
|
+
name: string;
|
|
617
|
+
updates: Partial<BattleStatistics>;
|
|
618
|
+
} | null;
|
|
619
|
+
} | null;
|
|
620
|
+
handleEnduranceEnhancement: (targetBoss: any) => {
|
|
621
|
+
messages: string[];
|
|
622
|
+
targetUpdates: {
|
|
623
|
+
name: string;
|
|
624
|
+
updates: Partial<BattleStatistics>;
|
|
625
|
+
} | null;
|
|
626
|
+
nerfMultiplier: number;
|
|
627
|
+
} | null;
|
|
628
|
+
handleThickenedCarapace: (targetBoss: any) => {
|
|
629
|
+
nerfMultiplier: number;
|
|
630
|
+
messages: string[];
|
|
631
|
+
} | null;
|
|
632
|
+
handleAcceleratedMetabolism: (targetBoss: any) => {
|
|
633
|
+
messages: string[];
|
|
634
|
+
targetUpdates: {
|
|
635
|
+
name: string;
|
|
636
|
+
updates: Partial<BattleStatistics>;
|
|
637
|
+
} | null;
|
|
638
|
+
} | null;
|
|
639
|
+
handleBiologicalSignatureImitation: (targetBoss: any) => {
|
|
640
|
+
isImmune: boolean;
|
|
641
|
+
messages: string[];
|
|
642
|
+
} | null;
|
|
589
643
|
};
|
|
590
644
|
/**
|
|
591
645
|
* 统一处理所有被动效果(包含伤害修正、免疫检查、状态更新等)
|
package/lib/index.js
CHANGED
|
@@ -1600,12 +1600,12 @@ var bossPool = [
|
|
|
1600
1600
|
main: {
|
|
1601
1601
|
name: "坏兄弟",
|
|
1602
1602
|
type: "主宰",
|
|
1603
|
-
maxHP:
|
|
1603
|
+
maxHP: 25e3,
|
|
1604
1604
|
maxShield: 0,
|
|
1605
1605
|
maxEnergy: 1e3,
|
|
1606
1606
|
armor: 3,
|
|
1607
1607
|
shieldArmor: 0,
|
|
1608
|
-
maxStacks:
|
|
1608
|
+
maxStacks: 100,
|
|
1609
1609
|
tags: ["生物", "异形"],
|
|
1610
1610
|
passive: ["基因变异"]
|
|
1611
1611
|
},
|
|
@@ -3737,7 +3737,265 @@ var BattleEffectProcessor = {
|
|
|
3737
3737
|
targetUpdates,
|
|
3738
3738
|
burnLayerAdded
|
|
3739
3739
|
};
|
|
3740
|
-
}, "handleBurnEffect")
|
|
3740
|
+
}, "handleBurnEffect"),
|
|
3741
|
+
// 基因变异处理函数
|
|
3742
|
+
handleGeneMutation: /* @__PURE__ */ __name(function(targetBoss) {
|
|
3743
|
+
const messages = [];
|
|
3744
|
+
let targetUpdates = null;
|
|
3745
|
+
let tempMark = false;
|
|
3746
|
+
if (!targetBoss.skills.includes("基因变异")) {
|
|
3747
|
+
return null;
|
|
3748
|
+
}
|
|
3749
|
+
tempMark = true;
|
|
3750
|
+
const currentStatusLayers = targetBoss.statusLayers || 0;
|
|
3751
|
+
targetUpdates = {
|
|
3752
|
+
name: targetBoss.name,
|
|
3753
|
+
updates: {
|
|
3754
|
+
statusLayersChanged: 1,
|
|
3755
|
+
// statusLayers +1
|
|
3756
|
+
skillStacksChanged: 1
|
|
3757
|
+
// skillStacks +1
|
|
3758
|
+
}
|
|
3759
|
+
};
|
|
3760
|
+
messages.push(`🧬 【基因变异】生效:获得1层「基因变异」`);
|
|
3761
|
+
if ((currentStatusLayers + 1) % 3 === 0) {
|
|
3762
|
+
const geneSkills = targetBoss.skills.filter((skill) => [
|
|
3763
|
+
"优化冗余片段",
|
|
3764
|
+
"开天眼",
|
|
3765
|
+
"环境适应",
|
|
3766
|
+
"加快分化",
|
|
3767
|
+
"耐力强化",
|
|
3768
|
+
"稳定DNA",
|
|
3769
|
+
"增厚甲壳",
|
|
3770
|
+
"质粒增殖",
|
|
3771
|
+
"加速代谢",
|
|
3772
|
+
"组织增生",
|
|
3773
|
+
"模仿生物签名"
|
|
3774
|
+
].includes(skill));
|
|
3775
|
+
const geneSkillCount = geneSkills.length;
|
|
3776
|
+
if (geneSkillCount >= 4) {
|
|
3777
|
+
targetUpdates.updates.statusLayersChanged = -(currentStatusLayers + 1);
|
|
3778
|
+
targetUpdates.updates.skillsRemoved = [...geneSkills];
|
|
3779
|
+
messages.push(`🧬 【基因变异】触发:移除所有基因技能`);
|
|
3780
|
+
} else {
|
|
3781
|
+
const availableSkills = [
|
|
3782
|
+
"优化冗余片段",
|
|
3783
|
+
"开天眼",
|
|
3784
|
+
"环境适应",
|
|
3785
|
+
"加快分化",
|
|
3786
|
+
"耐力强化",
|
|
3787
|
+
"稳定DNA",
|
|
3788
|
+
"增厚甲壳",
|
|
3789
|
+
"质粒增殖",
|
|
3790
|
+
"加速代谢",
|
|
3791
|
+
"组织增生",
|
|
3792
|
+
"模仿生物签名"
|
|
3793
|
+
].filter((skill) => !targetBoss.skills.includes(skill));
|
|
3794
|
+
if (availableSkills.length > 0) {
|
|
3795
|
+
const randomIndex = Math.floor(Math.random() * availableSkills.length);
|
|
3796
|
+
const newSkill = availableSkills[randomIndex];
|
|
3797
|
+
const updates = targetUpdates.updates;
|
|
3798
|
+
updates.skillsAdded = updates.skillsAdded || [];
|
|
3799
|
+
updates.skillsAdded.push(newSkill);
|
|
3800
|
+
messages.push(`🧬 【基因变异】触发:获得基因技能「${newSkill}」`);
|
|
3801
|
+
}
|
|
3802
|
+
}
|
|
3803
|
+
}
|
|
3804
|
+
return {
|
|
3805
|
+
messages,
|
|
3806
|
+
targetUpdates,
|
|
3807
|
+
tempMark
|
|
3808
|
+
};
|
|
3809
|
+
}, "handleGeneMutation"),
|
|
3810
|
+
// 优化冗余片段处理(免疫辐射伤害)
|
|
3811
|
+
handleRedundancyOptimization: /* @__PURE__ */ __name(function(targetBoss, weaponName) {
|
|
3812
|
+
const messages = [];
|
|
3813
|
+
if (!targetBoss.skills.includes("优化冗余片段")) {
|
|
3814
|
+
return null;
|
|
3815
|
+
}
|
|
3816
|
+
const isRadiationDamage = weaponName === "伽马枪";
|
|
3817
|
+
if (!isRadiationDamage) {
|
|
3818
|
+
return null;
|
|
3819
|
+
}
|
|
3820
|
+
if (targetBoss.radiationLayers > 0) {
|
|
3821
|
+
const updates = {
|
|
3822
|
+
radiationLayersChange: -(targetBoss.radiationLayers + 2)
|
|
3823
|
+
};
|
|
3824
|
+
return {
|
|
3825
|
+
isImmune: true,
|
|
3826
|
+
messages: [`🧬 【优化冗余片段】生效:免疫辐射伤害并清空所有辐射层数`],
|
|
3827
|
+
targetUpdates: {
|
|
3828
|
+
name: targetBoss.name,
|
|
3829
|
+
updates
|
|
3830
|
+
}
|
|
3831
|
+
};
|
|
3832
|
+
}
|
|
3833
|
+
return {
|
|
3834
|
+
isImmune: true,
|
|
3835
|
+
messages: [`🧬 【优化冗余片段】生效:免疫辐射伤害`],
|
|
3836
|
+
targetUpdates: null
|
|
3837
|
+
};
|
|
3838
|
+
}, "handleRedundancyOptimization"),
|
|
3839
|
+
// 环境适应处理(免疫火焰和寒冷伤害,任意攻击都会清空寒冷/燃烧层数)
|
|
3840
|
+
handleEnvironmentalAdaptation: /* @__PURE__ */ __name(function(targetBoss, weaponName) {
|
|
3841
|
+
const messages = [];
|
|
3842
|
+
if (!targetBoss.skills.includes("环境适应")) {
|
|
3843
|
+
return null;
|
|
3844
|
+
}
|
|
3845
|
+
const isFireDamage = weaponName === "焚烧枪";
|
|
3846
|
+
const isColdDamage = weaponName === "零度之下";
|
|
3847
|
+
const updates = {};
|
|
3848
|
+
let clearMessage = "";
|
|
3849
|
+
if (targetBoss.burnLayers > 0) {
|
|
3850
|
+
updates.burnLayersChanged = -(targetBoss.burnLayers + 1);
|
|
3851
|
+
clearMessage += `清空所有燃烧层数`;
|
|
3852
|
+
}
|
|
3853
|
+
if (targetBoss.coldLayers > 0) {
|
|
3854
|
+
updates.coldLayersChange = -(targetBoss.coldLayers + 1);
|
|
3855
|
+
if (clearMessage) clearMessage += "和";
|
|
3856
|
+
clearMessage += `清空所有寒冷层数`;
|
|
3857
|
+
}
|
|
3858
|
+
let isImmune = false;
|
|
3859
|
+
let immuneMessage = "";
|
|
3860
|
+
if (isFireDamage || isColdDamage) {
|
|
3861
|
+
isImmune = true;
|
|
3862
|
+
immuneMessage = `免疫${isFireDamage ? "火焰" : "寒冷"}伤害`;
|
|
3863
|
+
}
|
|
3864
|
+
let fullMessage = `🧬 【环境适应】生效:`;
|
|
3865
|
+
if (immuneMessage && clearMessage) {
|
|
3866
|
+
fullMessage += `${immuneMessage}并${clearMessage}`;
|
|
3867
|
+
} else if (immuneMessage) {
|
|
3868
|
+
fullMessage += immuneMessage;
|
|
3869
|
+
} else if (clearMessage) {
|
|
3870
|
+
fullMessage += clearMessage;
|
|
3871
|
+
} else {
|
|
3872
|
+
return null;
|
|
3873
|
+
}
|
|
3874
|
+
return {
|
|
3875
|
+
isImmune,
|
|
3876
|
+
messages: [fullMessage],
|
|
3877
|
+
targetUpdates: Object.keys(updates).length > 0 ? {
|
|
3878
|
+
name: targetBoss.name,
|
|
3879
|
+
updates
|
|
3880
|
+
} : null
|
|
3881
|
+
};
|
|
3882
|
+
}, "handleEnvironmentalAdaptation"),
|
|
3883
|
+
// 加快分化处理(回复生命值)
|
|
3884
|
+
handleAcceleratedDifferentiation: /* @__PURE__ */ __name(function(targetBoss) {
|
|
3885
|
+
if (!targetBoss.skills.includes("加快分化")) {
|
|
3886
|
+
return null;
|
|
3887
|
+
}
|
|
3888
|
+
const geneStacks = targetBoss.skillStacks || 0;
|
|
3889
|
+
if (geneStacks === 0) {
|
|
3890
|
+
return null;
|
|
3891
|
+
}
|
|
3892
|
+
const healAmount = geneStacks * 10;
|
|
3893
|
+
return {
|
|
3894
|
+
messages: [`🧬 【加快分化】生效:回复${healAmount}点生命值`],
|
|
3895
|
+
targetUpdates: {
|
|
3896
|
+
name: targetBoss.name,
|
|
3897
|
+
updates: {
|
|
3898
|
+
hpChange: healAmount
|
|
3899
|
+
}
|
|
3900
|
+
}
|
|
3901
|
+
};
|
|
3902
|
+
}, "handleAcceleratedDifferentiation"),
|
|
3903
|
+
// 耐力强化处理(能量回复和减伤)
|
|
3904
|
+
handleEnduranceEnhancement: /* @__PURE__ */ __name(function(targetBoss) {
|
|
3905
|
+
if (!targetBoss.skills.includes("耐力强化")) {
|
|
3906
|
+
return null;
|
|
3907
|
+
}
|
|
3908
|
+
const messages = [];
|
|
3909
|
+
const updates = {};
|
|
3910
|
+
let nerfMultiplier = 0;
|
|
3911
|
+
const energyGain = 100;
|
|
3912
|
+
updates.energyChange = energyGain;
|
|
3913
|
+
messages.push(`🧬 【耐力强化】生效:回复${energyGain}点能量`);
|
|
3914
|
+
const currentEnergy = targetBoss.energy || 0;
|
|
3915
|
+
const maxEnergy = getMaxEnergyByName(targetBoss.name);
|
|
3916
|
+
const energyPercent = maxEnergy > 0 ? currentEnergy / maxEnergy : 0;
|
|
3917
|
+
if (energyPercent >= 0.8) {
|
|
3918
|
+
nerfMultiplier = 0.8;
|
|
3919
|
+
messages.push(`🧬 【耐力强化】生效:能量≥80%,受到的伤害-80%`);
|
|
3920
|
+
} else if (energyPercent >= 0.5) {
|
|
3921
|
+
nerfMultiplier = 0.5;
|
|
3922
|
+
messages.push(`🧬 【耐力强化】生效:能量≥50%,受到的伤害-50%`);
|
|
3923
|
+
} else if (energyPercent >= 0.3) {
|
|
3924
|
+
nerfMultiplier = 0.3;
|
|
3925
|
+
messages.push(`🧬 【耐力强化】生效:能量≥30%,受到的伤害-30%`);
|
|
3926
|
+
}
|
|
3927
|
+
return {
|
|
3928
|
+
messages,
|
|
3929
|
+
targetUpdates: {
|
|
3930
|
+
name: targetBoss.name,
|
|
3931
|
+
updates
|
|
3932
|
+
},
|
|
3933
|
+
nerfMultiplier
|
|
3934
|
+
};
|
|
3935
|
+
}, "handleEnduranceEnhancement"),
|
|
3936
|
+
// 增厚甲壳处理(减伤)
|
|
3937
|
+
handleThickenedCarapace: /* @__PURE__ */ __name(function(targetBoss) {
|
|
3938
|
+
if (!targetBoss.skills.includes("增厚甲壳")) {
|
|
3939
|
+
return null;
|
|
3940
|
+
}
|
|
3941
|
+
const geneStacks = targetBoss.skillStacks || 0;
|
|
3942
|
+
const nerfMultiplier = geneStacks * 0.05;
|
|
3943
|
+
if (nerfMultiplier === 0) {
|
|
3944
|
+
return null;
|
|
3945
|
+
}
|
|
3946
|
+
return {
|
|
3947
|
+
nerfMultiplier,
|
|
3948
|
+
messages: [`🧬 【增厚甲壳】生效:受到的伤害-${(nerfMultiplier * 100).toFixed(0)}%`]
|
|
3949
|
+
};
|
|
3950
|
+
}, "handleThickenedCarapace"),
|
|
3951
|
+
// 加速代谢处理(额外增加基因变异层数)
|
|
3952
|
+
handleAcceleratedMetabolism: /* @__PURE__ */ __name(function(targetBoss) {
|
|
3953
|
+
if (!targetBoss.skills.includes("加速代谢")) {
|
|
3954
|
+
return null;
|
|
3955
|
+
}
|
|
3956
|
+
const geneSkillsCount = targetBoss.skills.filter((skill) => [
|
|
3957
|
+
"优化冗余片段",
|
|
3958
|
+
"开天眼",
|
|
3959
|
+
"环境适应",
|
|
3960
|
+
"加快分化",
|
|
3961
|
+
"耐力强化",
|
|
3962
|
+
"稳定DNA",
|
|
3963
|
+
"增厚甲壳",
|
|
3964
|
+
"质粒增殖",
|
|
3965
|
+
"加速代谢",
|
|
3966
|
+
"组织增生",
|
|
3967
|
+
"模仿生物签名"
|
|
3968
|
+
].includes(skill)).length;
|
|
3969
|
+
if (geneSkillsCount > 0) {
|
|
3970
|
+
return {
|
|
3971
|
+
messages: [`🧬 【加速代谢】生效:当前拥有${geneSkillsCount}个基因技能,额外增加${geneSkillsCount}层基因变异`],
|
|
3972
|
+
targetUpdates: {
|
|
3973
|
+
name: targetBoss.name,
|
|
3974
|
+
updates: {
|
|
3975
|
+
skillStacksChanged: geneSkillsCount
|
|
3976
|
+
}
|
|
3977
|
+
}
|
|
3978
|
+
};
|
|
3979
|
+
}
|
|
3980
|
+
return null;
|
|
3981
|
+
}, "handleAcceleratedMetabolism"),
|
|
3982
|
+
// 模仿生物签名处理(概率免疫伤害)
|
|
3983
|
+
handleBiologicalSignatureImitation: /* @__PURE__ */ __name(function(targetBoss) {
|
|
3984
|
+
if (!targetBoss.skills.includes("模仿生物签名")) {
|
|
3985
|
+
return null;
|
|
3986
|
+
}
|
|
3987
|
+
const geneStacks = targetBoss.skillStacks || 0;
|
|
3988
|
+
const baseChance = 0.05;
|
|
3989
|
+
const stackBonus = geneStacks * 0.01;
|
|
3990
|
+
const totalChance = Math.min(baseChance + stackBonus, 0.99);
|
|
3991
|
+
if (Math.random() < totalChance) {
|
|
3992
|
+
return {
|
|
3993
|
+
isImmune: true,
|
|
3994
|
+
messages: [`🧬 【模仿生物签名】生效:${(totalChance * 100).toFixed(1)}%概率免疫本次伤害`]
|
|
3995
|
+
};
|
|
3996
|
+
}
|
|
3997
|
+
return null;
|
|
3998
|
+
}, "handleBiologicalSignatureImitation")
|
|
3741
3999
|
};
|
|
3742
4000
|
function applyPassiveEffects(targetBoss, activeBosses, weaponName, damage, hasCrit, ignoreRate, careerData, equippedWeapon) {
|
|
3743
4001
|
const messages = [];
|
|
@@ -3795,6 +4053,16 @@ function applyPassiveEffects(targetBoss, activeBosses, weaponName, damage, hasCr
|
|
|
3795
4053
|
}
|
|
3796
4054
|
];
|
|
3797
4055
|
const fireImmuneEffects = [];
|
|
4056
|
+
const conditionImmuneEffects = [
|
|
4057
|
+
{
|
|
4058
|
+
effect: BattleEffectProcessor.handleRedundancyOptimization,
|
|
4059
|
+
args: [targetBoss, weaponName]
|
|
4060
|
+
},
|
|
4061
|
+
{
|
|
4062
|
+
effect: BattleEffectProcessor.handleEnvironmentalAdaptation,
|
|
4063
|
+
args: [targetBoss, weaponName]
|
|
4064
|
+
}
|
|
4065
|
+
];
|
|
3798
4066
|
const chanceImmuneEffects = [
|
|
3799
4067
|
{
|
|
3800
4068
|
effect: BattleEffectProcessor.handleDeadlyHit,
|
|
@@ -3807,9 +4075,13 @@ function applyPassiveEffects(targetBoss, activeBosses, weaponName, damage, hasCr
|
|
|
3807
4075
|
{
|
|
3808
4076
|
effect: BattleEffectProcessor.handleAncientOmen,
|
|
3809
4077
|
args: [targetBoss, weaponData]
|
|
4078
|
+
},
|
|
4079
|
+
{
|
|
4080
|
+
effect: BattleEffectProcessor.handleBiologicalSignatureImitation,
|
|
4081
|
+
args: [targetBoss]
|
|
3810
4082
|
}
|
|
3811
4083
|
];
|
|
3812
|
-
const allImmuneEffects = [...coldImmuneEffects, ...fireImmuneEffects, ...chanceImmuneEffects];
|
|
4084
|
+
const allImmuneEffects = [...coldImmuneEffects, ...fireImmuneEffects, ...chanceImmuneEffects, ...conditionImmuneEffects];
|
|
3813
4085
|
for (const immuneEffect of allImmuneEffects) {
|
|
3814
4086
|
const result = processEffect(immuneEffect.effect, ...immuneEffect.args);
|
|
3815
4087
|
if (result?.isImmune) immune = true;
|
|
@@ -3851,6 +4123,14 @@ function applyPassiveEffects(targetBoss, activeBosses, weaponName, damage, hasCr
|
|
|
3851
4123
|
}
|
|
3852
4124
|
messages.push(...carpetBombResult.messages);
|
|
3853
4125
|
}
|
|
4126
|
+
const geneMutationResult = BattleEffectProcessor.handleGeneMutation(targetBoss);
|
|
4127
|
+
if (geneMutationResult) {
|
|
4128
|
+
messages.push(...geneMutationResult.messages);
|
|
4129
|
+
if (geneMutationResult.targetUpdates) {
|
|
4130
|
+
updateStatsByName(geneMutationResult.targetUpdates.name, geneMutationResult.targetUpdates.updates);
|
|
4131
|
+
}
|
|
4132
|
+
isolatedImmunityMark = geneMutationResult.tempMark;
|
|
4133
|
+
}
|
|
3854
4134
|
const damageAdjustEffects = [
|
|
3855
4135
|
// 单参数效果
|
|
3856
4136
|
{ effect: BattleEffectProcessor.handleWeakForm, args: [targetBoss] },
|
|
@@ -3878,7 +4158,10 @@ function applyPassiveEffects(targetBoss, activeBosses, weaponName, damage, hasCr
|
|
|
3878
4158
|
{ effect: BattleEffectProcessor.handleHunterAlien, args: [targetBoss, activeBosses, weaponName] },
|
|
3879
4159
|
{ effect: BattleEffectProcessor.handleHiveMind, args: [targetBoss, activeBosses] },
|
|
3880
4160
|
{ effect: BattleEffectProcessor.handleReleasePheromones, args: [targetBoss] },
|
|
3881
|
-
{ effect: BattleEffectProcessor.handleWeakeningSpit, args: [targetBoss, activeBosses] }
|
|
4161
|
+
{ effect: BattleEffectProcessor.handleWeakeningSpit, args: [targetBoss, activeBosses] },
|
|
4162
|
+
{ effect: BattleEffectProcessor.handleThickenedCarapace, args: [targetBoss] },
|
|
4163
|
+
{ effect: BattleEffectProcessor.handleEnduranceEnhancement, args: [targetBoss] },
|
|
4164
|
+
{ effect: BattleEffectProcessor.handleAcceleratedMetabolism, args: [targetBoss] }
|
|
3882
4165
|
];
|
|
3883
4166
|
for (const effectItem of damageAdjustEffects) {
|
|
3884
4167
|
const result = processEffect(effectItem.effect, ...effectItem.args);
|
|
@@ -3959,7 +4242,8 @@ function applyPassiveEffects(targetBoss, activeBosses, weaponName, damage, hasCr
|
|
|
3959
4242
|
// 6. 淬毒撕咬
|
|
3960
4243
|
{ effect: BattleEffectProcessor.handlePoisonedBite, args: [targetBoss] },
|
|
3961
4244
|
{ effect: BattleEffectProcessor.handleHealingSwarm, args: [targetBoss, activeBosses] },
|
|
3962
|
-
{ effect: BattleEffectProcessor.handleBurrowAmbush, args: [targetBoss, activeBosses] }
|
|
4245
|
+
{ effect: BattleEffectProcessor.handleBurrowAmbush, args: [targetBoss, activeBosses] },
|
|
4246
|
+
{ effect: BattleEffectProcessor.handleAcceleratedDifferentiation, args: [targetBoss] }
|
|
3963
4247
|
];
|
|
3964
4248
|
for (const effectItem of healingEffects) {
|
|
3965
4249
|
processEffect(effectItem.effect, ...effectItem.args);
|
|
@@ -4467,7 +4751,7 @@ var passiveConfig = {
|
|
|
4467
4751
|
derivedSkills: []
|
|
4468
4752
|
},
|
|
4469
4753
|
"基因变异": {
|
|
4470
|
-
description: "移除孤立无援状态;每次受击叠加1
|
|
4754
|
+
description: "移除孤立无援状态;每次受击叠加1层「基因变异」(上限100层);每受击3次随机获得1个基因技能,累计获得4个基因后再次触发则移除全部基因技能",
|
|
4471
4755
|
belong: ["坏兄弟"],
|
|
4472
4756
|
derivedSkills: [
|
|
4473
4757
|
"优化冗余片段",
|
|
@@ -4504,7 +4788,7 @@ var passiveConfig = {
|
|
|
4504
4788
|
derivedSkills: []
|
|
4505
4789
|
},
|
|
4506
4790
|
"耐力强化": {
|
|
4507
|
-
description: "
|
|
4791
|
+
description: "每次受击回复100点能量;当能量≥80%时,受到的伤害降低80%;当能量≥50%时,受到的伤害降低50%;当能量≥30%时,受到的伤害降低30%",
|
|
4508
4792
|
belong: [],
|
|
4509
4793
|
derivedSkills: []
|
|
4510
4794
|
},
|
|
@@ -4519,17 +4803,17 @@ var passiveConfig = {
|
|
|
4519
4803
|
derivedSkills: []
|
|
4520
4804
|
},
|
|
4521
4805
|
"质粒增殖": {
|
|
4522
|
-
description: "
|
|
4806
|
+
description: "免疫脉冲手雷",
|
|
4523
4807
|
belong: [],
|
|
4524
4808
|
derivedSkills: []
|
|
4525
4809
|
},
|
|
4526
4810
|
"加速代谢": {
|
|
4527
|
-
description: "每次受击叠加X层「基因变异」(X
|
|
4811
|
+
description: "每次受击叠加X层「基因变异」(X为当前拥有的基因技能数量)",
|
|
4528
4812
|
belong: [],
|
|
4529
4813
|
derivedSkills: []
|
|
4530
4814
|
},
|
|
4531
4815
|
"组织增生": {
|
|
4532
|
-
description: "
|
|
4816
|
+
description: "每层「基因变异」使护甲值临时提高1点",
|
|
4533
4817
|
belong: [],
|
|
4534
4818
|
derivedSkills: []
|
|
4535
4819
|
},
|
|
@@ -4590,6 +4874,34 @@ var wishConfig = {
|
|
|
4590
4874
|
]
|
|
4591
4875
|
};
|
|
4592
4876
|
|
|
4877
|
+
// src/update.ts
|
|
4878
|
+
var ggcevoUpdates = [
|
|
4879
|
+
{
|
|
4880
|
+
version: "1.5.0",
|
|
4881
|
+
time: "2025-06-27",
|
|
4882
|
+
content: `
|
|
4883
|
+
- 回调“伽马辐射”任务奖励为50金币
|
|
4884
|
+
- 修改武器系统科技
|
|
4885
|
+
- 提高人类联盟情报副官转职门槛
|
|
4886
|
+
- 削弱人类联盟警卫长攻击奖励为+75%
|
|
4887
|
+
- 新增“技能”指令用于查询各异形的技能列表
|
|
4888
|
+
`.trim()
|
|
4889
|
+
}
|
|
4890
|
+
];
|
|
4891
|
+
function compareVersions(a, b) {
|
|
4892
|
+
const aParts = a.split(".").map(Number);
|
|
4893
|
+
const bParts = b.split(".").map(Number);
|
|
4894
|
+
for (let i = 0; i < Math.max(aParts.length, bParts.length); i++) {
|
|
4895
|
+
const aVal = aParts[i] || 0;
|
|
4896
|
+
const bVal = bParts[i] || 0;
|
|
4897
|
+
if (aVal !== bVal) {
|
|
4898
|
+
return bVal - aVal;
|
|
4899
|
+
}
|
|
4900
|
+
}
|
|
4901
|
+
return 0;
|
|
4902
|
+
}
|
|
4903
|
+
__name(compareVersions, "compareVersions");
|
|
4904
|
+
|
|
4593
4905
|
// src/utils.ts
|
|
4594
4906
|
async function gachaWithPity(ctx, handle) {
|
|
4595
4907
|
const [record] = await ctx.database.get("ggcevo_records", { handle });
|
|
@@ -4871,7 +5183,13 @@ async function applyItemEffect(ctx, session, handle, itemConfig2, target) {
|
|
|
4871
5183
|
success: false,
|
|
4872
5184
|
message: "无法找到指定的目标。"
|
|
4873
5185
|
};
|
|
4874
|
-
if (targetboss.
|
|
5186
|
+
if (targetboss.skills.includes("开天眼")) {
|
|
5187
|
+
return {
|
|
5188
|
+
success: false,
|
|
5189
|
+
message: `目标免疫闪光弹,无法使用此物品。`
|
|
5190
|
+
};
|
|
5191
|
+
}
|
|
5192
|
+
if (targetboss.tags.includes("建筑") || targetboss.tags.includes("重型") || targetboss.skills.includes("开天眼")) {
|
|
4875
5193
|
return {
|
|
4876
5194
|
success: false,
|
|
4877
5195
|
message: `目标${target}拥有"${targetboss.tags.includes("建筑") ? "建筑" : "重型"}"标签,无法使用此物品。`
|
|
@@ -4905,6 +5223,12 @@ async function applyItemEffect(ctx, session, handle, itemConfig2, target) {
|
|
|
4905
5223
|
name: target,
|
|
4906
5224
|
isActive: true
|
|
4907
5225
|
});
|
|
5226
|
+
if (targetboss.skills.includes("质粒增殖")) {
|
|
5227
|
+
return {
|
|
5228
|
+
success: false,
|
|
5229
|
+
message: `目标免疫脉冲手雷,无法使用此物品。`
|
|
5230
|
+
};
|
|
5231
|
+
}
|
|
4908
5232
|
if (!targetboss || targetboss?.energy === 0) return {
|
|
4909
5233
|
success: false,
|
|
4910
5234
|
message: "您无法对没有能量的目标使用。"
|
|
@@ -5281,11 +5605,17 @@ async function calculateTotalDamage(ctx, session, config, equippedWeapon, target
|
|
|
5281
5605
|
const levelBonusRate = isLegendary ? 0.05 : 0.1;
|
|
5282
5606
|
const baseDamage = weaponData.damage * (1 + levelBonusRate * equippedWeapon.level);
|
|
5283
5607
|
effectMessage.push(`🔫 ${weaponName} Lv.${equippedWeapon.level}:基础伤害${baseDamage.toFixed(1)}`);
|
|
5284
|
-
|
|
5285
|
-
|
|
5286
|
-
if (
|
|
5287
|
-
|
|
5288
|
-
|
|
5608
|
+
let tagMultiplier = 1;
|
|
5609
|
+
let tagAdditive = 0;
|
|
5610
|
+
if (targetBoss.skills && targetBoss.skills.includes("稳定DNA")) {
|
|
5611
|
+
effectMessage.push(`🧬 稳定DNA:目标免疫标签伤害加成`);
|
|
5612
|
+
} else {
|
|
5613
|
+
tagAdditive = await calculateTagMultiplier(weaponData, finalTags, equippedWeapon);
|
|
5614
|
+
tagMultiplier = 1 + tagAdditive;
|
|
5615
|
+
if (tagAdditive !== 0) {
|
|
5616
|
+
const sign = tagAdditive >= 0 ? "+" : "";
|
|
5617
|
+
effectMessage.push(`📌 标签加成:攻击伤害${sign}${Math.round(tagAdditive * 100)}%`);
|
|
5618
|
+
}
|
|
5289
5619
|
}
|
|
5290
5620
|
const { totalModAdd, modMessages } = calculateModifiers(equippedWeapon, weaponName);
|
|
5291
5621
|
effectMessage.push(...modMessages);
|
|
@@ -8254,7 +8584,7 @@ ${Object.keys(categoryStats).join("、")}`;
|
|
|
8254
8584
|
"------------------"
|
|
8255
8585
|
].filter(Boolean).join("\n");
|
|
8256
8586
|
});
|
|
8257
|
-
const permissionNotice = category === "传奇武器" ? "⚠️ 购买传奇武器要求:人类联盟阵营+武器系统5
|
|
8587
|
+
const permissionNotice = category === "传奇武器" ? "⚠️ 购买传奇武器要求:人类联盟阵营+武器系统5级+传奇武器购买权限" : null;
|
|
8258
8588
|
return [
|
|
8259
8589
|
`🏪 咕咕武器库 - ${category} 🏪`,
|
|
8260
8590
|
'使用"购买 武器名称"指令进行购买',
|
|
@@ -10485,6 +10815,31 @@ ${Spacestationtechnology.map((t) => t.techname).join("、")}`;
|
|
|
10485
10815
|
`注:部分技能可触发衍生技能,最多显示二级衍生技能`
|
|
10486
10816
|
].join("\n");
|
|
10487
10817
|
});
|
|
10818
|
+
ctx.command("ggcevo/咕咕更新").action(async ({ session }) => {
|
|
10819
|
+
try {
|
|
10820
|
+
const latestUpdates = [...ggcevoUpdates].sort((a, b) => compareVersions(a.version, b.version)).slice(0, 3);
|
|
10821
|
+
if (latestUpdates.length === 0) {
|
|
10822
|
+
return "🛑 暂无更新记录";
|
|
10823
|
+
}
|
|
10824
|
+
let message = "🕊️ 咕咕之战版本更新内容:\n\n";
|
|
10825
|
+
for (const update of latestUpdates) {
|
|
10826
|
+
message += `🔹【版本 v${update.version} | ${update.time}】
|
|
10827
|
+
`;
|
|
10828
|
+
message += `${update.content}
|
|
10829
|
+
|
|
10830
|
+
`;
|
|
10831
|
+
}
|
|
10832
|
+
const latestVersion = latestUpdates[0].version;
|
|
10833
|
+
message += `✅ 当前最新版本:v${latestVersion}
|
|
10834
|
+
`;
|
|
10835
|
+
message += "输入「ggcevo」查看全部指令\n";
|
|
10836
|
+
message += "输入「ggcevo/武器库」查看可购买武器";
|
|
10837
|
+
return message;
|
|
10838
|
+
} catch (error) {
|
|
10839
|
+
ctx.logger.error("咕咕更新指令出错:", error);
|
|
10840
|
+
return "🛠️ 系统维护中,请稍后再试";
|
|
10841
|
+
}
|
|
10842
|
+
});
|
|
10488
10843
|
}
|
|
10489
10844
|
__name(apply, "apply");
|
|
10490
10845
|
// Annotate the CommonJS export names for ESM import in node:
|
package/lib/update.d.ts
ADDED