mirror of
https://github.com/ZZZure/ZZZ-Plugin.git
synced 2025-12-16 13:17:32 +00:00
feat: 上期食欲防卫战
This commit is contained in:
parent
faab10ebfc
commit
8929d12b9b
2 changed files with 8 additions and 3 deletions
|
|
@ -14,7 +14,7 @@ export class Abyss extends ZZZPlugin {
|
||||||
priority: _.get(settings.getConfig('priority'), 'abyss', 70),
|
priority: _.get(settings.getConfig('priority'), 'abyss', 70),
|
||||||
rule: [
|
rule: [
|
||||||
{
|
{
|
||||||
reg: `${rulePrefix}(式舆防卫战|式舆|深渊|防卫战|防卫)$`,
|
reg: `${rulePrefix}(上期|往期)?(式舆防卫战|式舆|深渊|防卫战|防卫)$`,
|
||||||
fnc: 'abyss',
|
fnc: 'abyss',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
|
@ -24,7 +24,8 @@ export class Abyss extends ZZZPlugin {
|
||||||
const { api, deviceFp } = await this.getAPI();
|
const { api, deviceFp } = await this.getAPI();
|
||||||
if (!api) return false;
|
if (!api) return false;
|
||||||
await this.getPlayerInfo();
|
await this.getPlayerInfo();
|
||||||
const abyssData = await api.getFinalData(this.e, 'zzzChallenge', {
|
const method = this.e.msg.match(`(上期|往期)`) ? 'zzzChallenge' : 'zzzChallengePeriod';
|
||||||
|
const abyssData = await api.getFinalData(this.e, method, {
|
||||||
deviceFp,
|
deviceFp,
|
||||||
});
|
});
|
||||||
if (!abyssData?.has_data) {
|
if (!abyssData?.has_data) {
|
||||||
|
|
|
||||||
|
|
@ -55,6 +55,10 @@ export default class ZZZApiTool {
|
||||||
url: `${this.hostRecord}event/game_record_zzz/api/zzz/challenge`,
|
url: `${this.hostRecord}event/game_record_zzz/api/zzz/challenge`,
|
||||||
query: `lang=zh-cn&role_id=${this.uid}&server=${this.server}&schedule_type=1`,
|
query: `lang=zh-cn&role_id=${this.uid}&server=${this.server}&schedule_type=1`,
|
||||||
},
|
},
|
||||||
|
zzzChallengePeriod: {
|
||||||
|
url: `${this.hostRecord}event/game_record_zzz/api/zzz/challenge`,
|
||||||
|
query: `lang=zh-cn&role_id=${this.uid}&server=${this.server}&schedule_type=2`,
|
||||||
|
},
|
||||||
zzzAuthKey: {
|
zzzAuthKey: {
|
||||||
url: `${this.host}binding/api/genAuthKey`,
|
url: `${this.host}binding/api/genAuthKey`,
|
||||||
body: {
|
body: {
|
||||||
|
|
@ -109,4 +113,4 @@ export default class ZZZApiTool {
|
||||||
};
|
};
|
||||||
return urlMap[this.game];
|
return urlMap[this.game];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue