koishi-plugin-ggcevo-game 1.4.15 → 1.4.16
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/passivehandler.d.ts +2 -2
- package/lib/index.js +5 -7
- package/package.json +1 -1
|
@@ -151,7 +151,7 @@ export declare const PassiveHandler: {
|
|
|
151
151
|
damageMultiplier: number;
|
|
152
152
|
messages: string[];
|
|
153
153
|
};
|
|
154
|
-
handleHunterAlien: (
|
|
154
|
+
handleHunterAlien: (targetBoss: any, weaponName: string, activeBosses: any[]) => Promise<{
|
|
155
155
|
immune: boolean;
|
|
156
156
|
messages: string[];
|
|
157
157
|
damageMultiplier?: undefined;
|
|
@@ -181,7 +181,7 @@ export declare const PassiveHandler: {
|
|
|
181
181
|
handlePulseDisruptor: (ctx: Context, targetBoss: any, weaponName: string) => Promise<{
|
|
182
182
|
messages: string[];
|
|
183
183
|
}>;
|
|
184
|
-
handlePassives: (ctx: Context, handle: string, targetBoss: any, initialDamage: number, currentHP: number, maxHP: number, weaponName: string, weaponData: any,
|
|
184
|
+
handlePassives: (ctx: Context, handle: string, targetBoss: any, initialDamage: number, currentHP: number, maxHP: number, weaponName: string, weaponData: any, bossGroup: any) => Promise<{
|
|
185
185
|
currentHP: any;
|
|
186
186
|
messages: any;
|
|
187
187
|
skillUpdates: any[];
|
package/lib/index.js
CHANGED
|
@@ -3118,7 +3118,7 @@ var PassiveHandler = {
|
|
|
3118
3118
|
};
|
|
3119
3119
|
}, "handleHellfireBomb"),
|
|
3120
3120
|
// 猎手异形处理(Hunter Alien)
|
|
3121
|
-
handleHunterAlien: /* @__PURE__ */ __name(async function(
|
|
3121
|
+
handleHunterAlien: /* @__PURE__ */ __name(async function(targetBoss, weaponName, activeBosses) {
|
|
3122
3122
|
if (!targetBoss.skills.includes("猎手异形")) return null;
|
|
3123
3123
|
if (weaponName === "焚烧枪" || weaponName === "零度之下") {
|
|
3124
3124
|
return {
|
|
@@ -3126,7 +3126,6 @@ var PassiveHandler = {
|
|
|
3126
3126
|
messages: [`🛡️ 【猎手异形】生效:免疫${weaponName === "焚烧枪" ? "火焰" : "寒冷"}伤害`]
|
|
3127
3127
|
};
|
|
3128
3128
|
}
|
|
3129
|
-
const activeBosses = await ctx.database.get("ggcevo_boss", { isActive: true });
|
|
3130
3129
|
const otherAlive = activeBosses.some(
|
|
3131
3130
|
(boss) => boss.groupId === targetBoss.groupId && boss.name !== targetBoss.name && boss.HP > 0
|
|
3132
3131
|
);
|
|
@@ -3144,7 +3143,7 @@ var PassiveHandler = {
|
|
|
3144
3143
|
if (currentHP / maxHP < 0.5) {
|
|
3145
3144
|
return {
|
|
3146
3145
|
damageMultiplier: -0.5,
|
|
3147
|
-
messages: [
|
|
3146
|
+
messages: [`🔥 【狂暴】生效:血量低于50%,受到的伤害-50%`]
|
|
3148
3147
|
};
|
|
3149
3148
|
}
|
|
3150
3149
|
return null;
|
|
@@ -3279,7 +3278,7 @@ var PassiveHandler = {
|
|
|
3279
3278
|
};
|
|
3280
3279
|
}, "handlePulseDisruptor"),
|
|
3281
3280
|
// 修改后的伤害处理函数
|
|
3282
|
-
handlePassives: /* @__PURE__ */ __name(async function(ctx, handle, targetBoss, initialDamage, currentHP, maxHP, weaponName, weaponData,
|
|
3281
|
+
handlePassives: /* @__PURE__ */ __name(async function(ctx, handle, targetBoss, initialDamage, currentHP, maxHP, weaponName, weaponData, bossGroup) {
|
|
3283
3282
|
let messages = [];
|
|
3284
3283
|
let skillUpdates = [];
|
|
3285
3284
|
let buffMultiplier = 0;
|
|
@@ -3287,6 +3286,7 @@ var PassiveHandler = {
|
|
|
3287
3286
|
let radiationApplied = false;
|
|
3288
3287
|
let freezing = false;
|
|
3289
3288
|
let bileStacks = 0;
|
|
3289
|
+
const activeBosses = await ctx.database.get("ggcevo_boss", { isActive: true });
|
|
3290
3290
|
const solarFlareResult = await this.handleSolarFlare(ctx, targetBoss, weaponName);
|
|
3291
3291
|
if (solarFlareResult.immune) {
|
|
3292
3292
|
return {
|
|
@@ -3351,7 +3351,7 @@ var PassiveHandler = {
|
|
|
3351
3351
|
initialDamage: 0
|
|
3352
3352
|
};
|
|
3353
3353
|
}
|
|
3354
|
-
const hunterImmune = await this.handleHunterAlien(
|
|
3354
|
+
const hunterImmune = await this.handleHunterAlien(targetBoss, weaponName, activeBosses);
|
|
3355
3355
|
if (hunterImmune?.immune) {
|
|
3356
3356
|
return {
|
|
3357
3357
|
currentHP: targetBoss.HP,
|
|
@@ -3821,7 +3821,6 @@ async function handlePrimaryAttack(ctx, session, config, handle, equippedWeapon,
|
|
|
3821
3821
|
maxHP,
|
|
3822
3822
|
weaponName,
|
|
3823
3823
|
weaponData,
|
|
3824
|
-
activeBosses,
|
|
3825
3824
|
bossGroup
|
|
3826
3825
|
);
|
|
3827
3826
|
const currentHP = passiveResult.currentHP;
|
|
@@ -3876,7 +3875,6 @@ async function handleScatterAttack(ctx, session, config, handle, equippedWeapon,
|
|
|
3876
3875
|
getBossMaxHP(secondaryTarget.name),
|
|
3877
3876
|
weaponName,
|
|
3878
3877
|
weaponData,
|
|
3879
|
-
secondaryTargets,
|
|
3880
3878
|
bossGroup
|
|
3881
3879
|
);
|
|
3882
3880
|
const actualDamage = Math.min(passiveResult.initialDamage, secondaryTarget.HP);
|