@sjtdev/koishi-plugin-dota2tracker 2.5.5 → 2.5.6
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/changelog.md +6 -0
- package/lib/index.js +10 -1
- package/package.json +1 -1
package/changelog.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# 更新日志
|
|
2
2
|
|
|
3
|
+
### [2.5.6](https://github.com/sjtdev/koishi-plugin-dota2tracker/compare/v2.5.5...v2.5.6) (2026-03-12)
|
|
4
|
+
|
|
5
|
+
### 🐛 Bug 修复
|
|
6
|
+
|
|
7
|
+
* **daily:** 修复了对于"LVP(头号战犯)"卡片判定的逻辑错误 ([1797209](https://github.com/sjtdev/koishi-plugin-dota2tracker/commit/17972098102dc0479dd9d3a9a3d33b041919cf1b))
|
|
8
|
+
|
|
3
9
|
### [2.5.5](https://github.com/sjtdev/koishi-plugin-dota2tracker/compare/v2.5.4...v2.5.5) (2026-03-08)
|
|
4
10
|
|
|
5
11
|
### 🐛 Bug 修复
|
package/lib/index.js
CHANGED
|
@@ -4710,7 +4710,16 @@ var DailyReportService = class _DailyReportService extends import_koishi18.Servi
|
|
|
4710
4710
|
this.calculateImpactPercentages(impactData);
|
|
4711
4711
|
playerStats.sort((a, b) => b.maxMvpScore - a.maxMvpScore || b.avgKda - a.avgKda);
|
|
4712
4712
|
const mvpStat = playerStats[0];
|
|
4713
|
-
const
|
|
4713
|
+
const getWorstMatchScore = /* @__PURE__ */ __name((stat) => {
|
|
4714
|
+
const ext = extensions.find((e) => Number(e.matchId) === stat.worstMatchId);
|
|
4715
|
+
const playerExt = ext?.data?.players?.find((p) => p.steamAccountId === stat.steamId);
|
|
4716
|
+
return playerExt?.mvpScore ?? 0;
|
|
4717
|
+
}, "getWorstMatchScore");
|
|
4718
|
+
const lvpStat = playerStats.reduce((worst, curr) => {
|
|
4719
|
+
const worstScore = getWorstMatchScore(worst);
|
|
4720
|
+
const currScore = getWorstMatchScore(curr);
|
|
4721
|
+
return currScore < worstScore || currScore === worstScore && curr.avgKda < worst.avgKda ? curr : worst;
|
|
4722
|
+
});
|
|
4714
4723
|
const mvpPlayerData = squadPlayerData.find((p) => p.steamAccount.id === mvpStat.steamId);
|
|
4715
4724
|
const lvpPlayerData = squadPlayerData.find((p) => p.steamAccount.id === lvpStat.steamId);
|
|
4716
4725
|
playerRows.sort((a, b) => parseFloat(b.kda.ratio) - parseFloat(a.kda.ratio));
|
package/package.json
CHANGED