koishi-plugin-ggcevo-game 1.5.8 → 1.5.10
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/index.js +109 -8
- package/lib/items.d.ts +25 -0
- package/lib/wish.d.ts +1 -1
- package/package.json +1 -1
package/lib/index.js
CHANGED
|
@@ -620,7 +620,12 @@ var initDefaultItems = {
|
|
|
620
620
|
"🥈S1赛季亚军勋章": { id: 107, type: "勋章", description: "" },
|
|
621
621
|
"🥉S1赛季季军勋章": { id: 108, type: "勋章", description: "" },
|
|
622
622
|
"🏅S1赛季前十勋章": { id: 109, type: "勋章", description: "" },
|
|
623
|
-
"🎖S1赛季前二十勋章": { id: 110, type: "勋章", description: "" }
|
|
623
|
+
"🎖S1赛季前二十勋章": { id: 110, type: "勋章", description: "" },
|
|
624
|
+
"🥇S2赛季冠军勋章": { id: 111, type: "勋章", description: "" },
|
|
625
|
+
"🥈S2赛季亚军勋章": { id: 112, type: "勋章", description: "" },
|
|
626
|
+
"🥉S2赛季季军勋章": { id: 113, type: "勋章", description: "" },
|
|
627
|
+
"🏅S2赛季前十勋章": { id: 114, type: "勋章", description: "" },
|
|
628
|
+
"🎖S2赛季前二十勋章": { id: 115, type: "勋章", description: "" }
|
|
624
629
|
};
|
|
625
630
|
var itemConfig = {
|
|
626
631
|
"拾荒者": { quality: "t3", type: "皮肤", cost: 3, isLimited: false },
|
|
@@ -4876,7 +4881,7 @@ var wishConfig = {
|
|
|
4876
4881
|
},
|
|
4877
4882
|
{
|
|
4878
4883
|
name: "王权增幅",
|
|
4879
|
-
effect: "伤害+
|
|
4884
|
+
effect: "伤害+5%"
|
|
4880
4885
|
},
|
|
4881
4886
|
{
|
|
4882
4887
|
name: "金柚赐福",
|
|
@@ -4957,6 +4962,21 @@ var ggcevoUpdates = [
|
|
|
4957
4962
|
- 重制了脉冲干扰和能量消耗的任务要求
|
|
4958
4963
|
- 新增专属模块:脉冲稳定核心和高压电池
|
|
4959
4964
|
`.trim()
|
|
4965
|
+
},
|
|
4966
|
+
{
|
|
4967
|
+
version: "1.5.9",
|
|
4968
|
+
time: "2025-06-30",
|
|
4969
|
+
content: `
|
|
4970
|
+
- 赛季奖励中新增辛迪加海盗阵营的排名奖励
|
|
4971
|
+
- 王权增幅祈愿的伤害加成更改为+5%
|
|
4972
|
+
`.trim()
|
|
4973
|
+
},
|
|
4974
|
+
{
|
|
4975
|
+
version: "1.5.10",
|
|
4976
|
+
time: "2025-07-02",
|
|
4977
|
+
content: `
|
|
4978
|
+
- 新增攻击假人指令可自定义假人名称
|
|
4979
|
+
`.trim()
|
|
4960
4980
|
}
|
|
4961
4981
|
];
|
|
4962
4982
|
function compareVersions(a, b) {
|
|
@@ -5865,8 +5885,8 @@ async function calculateWishAdditive(ctx, handle, weapon) {
|
|
|
5865
5885
|
endTime: { $gte: /* @__PURE__ */ new Date() }
|
|
5866
5886
|
});
|
|
5867
5887
|
if (sovereign) {
|
|
5868
|
-
value += 0.
|
|
5869
|
-
messages.push("👑 王权增幅祈愿:攻击伤害+
|
|
5888
|
+
value += 0.05;
|
|
5889
|
+
messages.push("👑 王权增幅祈愿:攻击伤害+5%");
|
|
5870
5890
|
}
|
|
5871
5891
|
const [lament] = await ctx.database.get("ggcevo_wish", {
|
|
5872
5892
|
handle,
|
|
@@ -7289,8 +7309,8 @@ ${itemDetails.join("\n")}`;
|
|
|
7289
7309
|
if (extraBonus > 0) {
|
|
7290
7310
|
redCrystal += extraBonus;
|
|
7291
7311
|
messages.push(
|
|
7292
|
-
`🎖️ 辛迪加财务经理职业:+${redCrystal - extraBonus}
|
|
7293
|
-
▸
|
|
7312
|
+
`🎖️ 辛迪加财务经理职业:+${redCrystal - extraBonus}枚红晶
|
|
7313
|
+
▸ 红晶储量加成:额外+${extraBonus}枚红晶`
|
|
7294
7314
|
);
|
|
7295
7315
|
} else {
|
|
7296
7316
|
messages.push(`🎖️ 辛迪加财务经理职业:+${redCrystal}枚红晶`);
|
|
@@ -7666,12 +7686,22 @@ ${ticketMessage}${effectMessage}`;
|
|
|
7666
7686
|
sort: { rank: "desc" },
|
|
7667
7687
|
limit: 20
|
|
7668
7688
|
});
|
|
7689
|
+
const allHandles = [...rankedPlayers.map((p) => p.handle)];
|
|
7690
|
+
const careerData = await ctx.database.get("ggcevo_careers", {
|
|
7691
|
+
handle: { $in: allHandles }
|
|
7692
|
+
});
|
|
7693
|
+
const groupMap = new Map(careerData.map((c) => [c.handle, c.group]));
|
|
7669
7694
|
let report = `=== ${currentSeason}赛季结算报告 ===
|
|
7670
7695
|
|
|
7671
7696
|
`;
|
|
7672
7697
|
const rewardDetails = [];
|
|
7673
7698
|
let positiveCount = 0;
|
|
7674
7699
|
let negativeCount = 0;
|
|
7700
|
+
let pirateTop3 = 0;
|
|
7701
|
+
let pirateTop10 = 0;
|
|
7702
|
+
let pirateTop20 = 0;
|
|
7703
|
+
let piratePositive = 0;
|
|
7704
|
+
let pirateNegative = 0;
|
|
7675
7705
|
for (const [index, player] of rankedPlayers.entries()) {
|
|
7676
7706
|
const rank = index + 1;
|
|
7677
7707
|
const { coins, gold } = getRewardByRank(index + 1);
|
|
@@ -7704,6 +7734,23 @@ ${ticketMessage}${effectMessage}`;
|
|
|
7704
7734
|
itemId: medalId,
|
|
7705
7735
|
quantity: (medalData?.quantity || 0) + 1
|
|
7706
7736
|
}], ["handle", "itemId"]);
|
|
7737
|
+
const group = groupMap.get(player.handle);
|
|
7738
|
+
if (group === "辛迪加海盗") {
|
|
7739
|
+
let redcrystal = getPirateRedcrystalByRank(rank);
|
|
7740
|
+
const [career] = await ctx.database.get("ggcevo_careers", { handle: player.handle });
|
|
7741
|
+
if (career) {
|
|
7742
|
+
await ctx.database.upsert("ggcevo_careers", [{
|
|
7743
|
+
handle: player.handle,
|
|
7744
|
+
redcrystal: (career.redcrystal || 0) + redcrystal
|
|
7745
|
+
}], ["handle"]);
|
|
7746
|
+
}
|
|
7747
|
+
if (rank <= 3) pirateTop3++;
|
|
7748
|
+
else if (rank <= 10) pirateTop10++;
|
|
7749
|
+
else pirateTop20++;
|
|
7750
|
+
if (rank <= 3) {
|
|
7751
|
+
rewardDetails[rewardDetails.length - 1] += ` (🏴☠️海盗专属:${redcrystal}红晶)`;
|
|
7752
|
+
}
|
|
7753
|
+
}
|
|
7707
7754
|
}
|
|
7708
7755
|
report += "🏆 精英奖励详情:\n";
|
|
7709
7756
|
report += rewardDetails.join("\n") + "\n";
|
|
@@ -7717,6 +7764,11 @@ ${ticketMessage}${effectMessage}`;
|
|
|
7717
7764
|
rankseason: currentSeason,
|
|
7718
7765
|
handle: { $nin: rankedPlayers.map((p) => p.handle) }
|
|
7719
7766
|
});
|
|
7767
|
+
const otherHandles = otherPlayers.map((p) => p.handle);
|
|
7768
|
+
const otherCareerData = await ctx.database.get("ggcevo_careers", {
|
|
7769
|
+
handle: { $in: otherHandles }
|
|
7770
|
+
});
|
|
7771
|
+
const otherGroupMap = new Map(otherCareerData.map((c) => [c.handle, c.group]));
|
|
7720
7772
|
for (const player of otherPlayers) {
|
|
7721
7773
|
if (player.rank > 0) {
|
|
7722
7774
|
positiveCount++;
|
|
@@ -7726,6 +7778,18 @@ ${ticketMessage}${effectMessage}`;
|
|
|
7726
7778
|
handle: player.handle,
|
|
7727
7779
|
totalRewards: (signData?.totalRewards || 0) + gold
|
|
7728
7780
|
}], ["handle"]);
|
|
7781
|
+
const group = otherGroupMap.get(player.handle);
|
|
7782
|
+
if (group === "辛迪加海盗") {
|
|
7783
|
+
const redcrystal = 10;
|
|
7784
|
+
piratePositive++;
|
|
7785
|
+
const [career] = await ctx.database.get("ggcevo_careers", { handle: player.handle });
|
|
7786
|
+
if (career) {
|
|
7787
|
+
await ctx.database.upsert("ggcevo_careers", [{
|
|
7788
|
+
handle: player.handle,
|
|
7789
|
+
redcrystal: (career.redcrystal || 0) + redcrystal
|
|
7790
|
+
}], ["handle"]);
|
|
7791
|
+
}
|
|
7792
|
+
}
|
|
7729
7793
|
} else if (player.rank <= 0) {
|
|
7730
7794
|
negativeCount++;
|
|
7731
7795
|
const gold = 500;
|
|
@@ -7734,6 +7798,18 @@ ${ticketMessage}${effectMessage}`;
|
|
|
7734
7798
|
handle: player.handle,
|
|
7735
7799
|
totalRewards: (signData?.totalRewards || 0) + gold
|
|
7736
7800
|
}], ["handle"]);
|
|
7801
|
+
const group = otherGroupMap.get(player.handle);
|
|
7802
|
+
if (group === "辛迪加海盗") {
|
|
7803
|
+
const redcrystal = 5;
|
|
7804
|
+
pirateNegative++;
|
|
7805
|
+
const [career] = await ctx.database.get("ggcevo_careers", { handle: player.handle });
|
|
7806
|
+
if (career) {
|
|
7807
|
+
await ctx.database.upsert("ggcevo_careers", [{
|
|
7808
|
+
handle: player.handle,
|
|
7809
|
+
redcrystal: (career.redcrystal || 0) + redcrystal
|
|
7810
|
+
}], ["handle"]);
|
|
7811
|
+
}
|
|
7812
|
+
}
|
|
7737
7813
|
}
|
|
7738
7814
|
}
|
|
7739
7815
|
report += "🎉 参与奖励发放:\n";
|
|
@@ -7742,6 +7818,20 @@ ${ticketMessage}${effectMessage}`;
|
|
|
7742
7818
|
report += `✦ 奋斗玩家(分数≤0):${negativeCount}人,每人获得500枚金币
|
|
7743
7819
|
|
|
7744
7820
|
`;
|
|
7821
|
+
if (pirateTop3 > 0 || pirateTop10 > 0 || pirateTop20 > 0 || piratePositive > 0 || pirateNegative > 0) {
|
|
7822
|
+
report += "🏴☠️ 辛迪加海盗红晶奖励:\n";
|
|
7823
|
+
if (pirateTop3 > 0) report += `✦ 冠军/亚军/季军:${pirateTop3}人,分别获得50/45/40红晶
|
|
7824
|
+
`;
|
|
7825
|
+
if (pirateTop10 > 0) report += `✦ 第4-10名:${pirateTop10}人,每人30红晶
|
|
7826
|
+
`;
|
|
7827
|
+
if (pirateTop20 > 0) report += `✦ 第11-20名:${pirateTop20}人,每人20红晶
|
|
7828
|
+
`;
|
|
7829
|
+
if (piratePositive > 0) report += `✦ 未入榜积极玩家:${piratePositive}人,每人10红晶
|
|
7830
|
+
`;
|
|
7831
|
+
if (pirateNegative > 0) report += `✦ 未入榜奋斗玩家:${pirateNegative}人,每人5红晶
|
|
7832
|
+
|
|
7833
|
+
`;
|
|
7834
|
+
}
|
|
7745
7835
|
report += `✅ 总计发放:
|
|
7746
7836
|
`;
|
|
7747
7837
|
report += `- 赛季奖励:${rankedPlayers.length}人
|
|
@@ -7772,6 +7862,14 @@ ${ticketMessage}${effectMessage}`;
|
|
|
7772
7862
|
return "top20";
|
|
7773
7863
|
}
|
|
7774
7864
|
__name(getMedalType, "getMedalType");
|
|
7865
|
+
function getPirateRedcrystalByRank(rank) {
|
|
7866
|
+
if (rank === 1) return 50;
|
|
7867
|
+
if (rank === 2) return 45;
|
|
7868
|
+
if (rank === 3) return 40;
|
|
7869
|
+
if (rank <= 10) return 30;
|
|
7870
|
+
return 20;
|
|
7871
|
+
}
|
|
7872
|
+
__name(getPirateRedcrystalByRank, "getPirateRedcrystalByRank");
|
|
7775
7873
|
});
|
|
7776
7874
|
ctx.command("ggcevo/排名 [player]", "查询个人排名").alias("rank").usage("输入“排名”查看自己的排名信息").action(async (argv, player) => {
|
|
7777
7875
|
const session = argv.session;
|
|
@@ -9335,9 +9433,12 @@ ${validTypes.join("、")}`;
|
|
|
9335
9433
|
cleanerRewardBroadcast
|
|
9336
9434
|
);
|
|
9337
9435
|
});
|
|
9338
|
-
ctx.command("ggcevo/攻击假人").option("tags", "-t <tags:string> 添加BOSS标签(逗号分隔)").option("passives", "-p <passives:string> 添加被动技能(逗号分隔)").option("hp", "-l <hp:number> 模拟假人血量").option("energy", "-e <energy:number> 模拟假人能量").option("skillStacks", "-s <stacks:number> 技能层数").option("radiation", "-r <rad:number> 辐射层数").option("cold", "-c <cold:number> 寒冷层数").option("status", "-a <status:number> 状态层数").option("armor", "-d <armor:number> 护甲").option("burn", "-b <burn:number> 燃烧层数").action(async (argv) => {
|
|
9436
|
+
ctx.command("ggcevo/攻击假人 [name]").option("tags", "-t <tags:string> 添加BOSS标签(逗号分隔)").option("passives", "-p <passives:string> 添加被动技能(逗号分隔)").option("hp", "-l <hp:number> 模拟假人血量").option("energy", "-e <energy:number> 模拟假人能量").option("skillStacks", "-s <stacks:number> 技能层数").option("radiation", "-r <rad:number> 辐射层数").option("cold", "-c <cold:number> 寒冷层数").option("status", "-a <status:number> 状态层数").option("armor", "-d <armor:number> 护甲").option("burn", "-b <burn:number> 燃烧层数").action(async (argv, name2) => {
|
|
9339
9437
|
const session = argv.session;
|
|
9340
9438
|
const { options } = argv;
|
|
9439
|
+
if (!name2) {
|
|
9440
|
+
name2 = "测试假人";
|
|
9441
|
+
}
|
|
9341
9442
|
let hp = 1e4;
|
|
9342
9443
|
if (typeof options.hp === "number") {
|
|
9343
9444
|
hp = Math.max(1, Math.min(options.hp, 1e4));
|
|
@@ -9370,7 +9471,7 @@ ${validTypes.join("、")}`;
|
|
|
9370
9471
|
});
|
|
9371
9472
|
if (!equippedWeapon) return '请先输入"装备 武器名称"后再测试。';
|
|
9372
9473
|
const dummyBoss = {
|
|
9373
|
-
name:
|
|
9474
|
+
name: name2,
|
|
9374
9475
|
HP: hp,
|
|
9375
9476
|
type: "主宰",
|
|
9376
9477
|
groupId: 0,
|
package/lib/items.d.ts
CHANGED
|
@@ -149,6 +149,31 @@ export declare const initDefaultItems: {
|
|
|
149
149
|
type: string;
|
|
150
150
|
description: string;
|
|
151
151
|
};
|
|
152
|
+
'\uD83E\uDD47S2\u8D5B\u5B63\u51A0\u519B\u52CB\u7AE0': {
|
|
153
|
+
id: number;
|
|
154
|
+
type: string;
|
|
155
|
+
description: string;
|
|
156
|
+
};
|
|
157
|
+
'\uD83E\uDD48S2\u8D5B\u5B63\u4E9A\u519B\u52CB\u7AE0': {
|
|
158
|
+
id: number;
|
|
159
|
+
type: string;
|
|
160
|
+
description: string;
|
|
161
|
+
};
|
|
162
|
+
'\uD83E\uDD49S2\u8D5B\u5B63\u5B63\u519B\u52CB\u7AE0': {
|
|
163
|
+
id: number;
|
|
164
|
+
type: string;
|
|
165
|
+
description: string;
|
|
166
|
+
};
|
|
167
|
+
'\uD83C\uDFC5S2\u8D5B\u5B63\u524D\u5341\u52CB\u7AE0': {
|
|
168
|
+
id: number;
|
|
169
|
+
type: string;
|
|
170
|
+
description: string;
|
|
171
|
+
};
|
|
172
|
+
'\uD83C\uDF96S2\u8D5B\u5B63\u524D\u4E8C\u5341\u52CB\u7AE0': {
|
|
173
|
+
id: number;
|
|
174
|
+
type: string;
|
|
175
|
+
description: string;
|
|
176
|
+
};
|
|
152
177
|
};
|
|
153
178
|
export declare const itemConfig: {
|
|
154
179
|
拾荒者: {
|
package/lib/wish.d.ts
CHANGED