diff --git a/plugins/genshin/apps/exchange.js b/plugins/genshin/apps/exchange.js index c6a713f..a1a30a2 100644 --- a/plugins/genshin/apps/exchange.js +++ b/plugins/genshin/apps/exchange.js @@ -4,7 +4,7 @@ import fetch from 'node-fetch' import MysInfo from '../model/mys/mysInfo.js' export class exchange extends plugin { - constructor () { + constructor() { super({ name: '兑换码', dsc: '前瞻直播兑换码', @@ -23,7 +23,7 @@ export class exchange extends plugin { }) } - async getCode () { + async getCode() { let reg = this.e.msg.match(/^(#|\*)?(原神|星铁|崩铁|崩三|崩坏三|崩坏3)?(直播|前瞻)?兑换码$/) this.uid = '75276550' if (reg[1] == '*' || ['星铁', '崩铁'].includes(reg[2])) { @@ -76,7 +76,7 @@ export class exchange extends plugin { await this.reply(msg) } - async getData (type) { + async getData(type) { let url = { index: `https://api-takumi.mihoyo.com/event/miyolive/index`, code: `https://api-takumi-static.mihoyo.com/event/miyolive/refreshCode?version=${this.code_ver}&time=${this.now}`, @@ -105,7 +105,7 @@ export class exchange extends plugin { } // 获取 "act_id" - async getActId () { + async getActId() { let ret = await this.getData('actId') if (ret.error || ret.retcode !== 0) { return '' @@ -123,8 +123,16 @@ export class exchange extends plugin { continue } let date = new Date(post.created_at * 1000) - date.setDate(date.getDate() + 1) - this.deadline = `${date.getFullYear()}-${date.getMonth() + 1}-${date.getDate()} 12:00:00` + if (this.uid == '80823548') { + date.setDate(date.getDate() + 1) + this.deadline = `${date.getFullYear()}-${date.getMonth() + 1}-${date.getDate()} 23:59:59` + } else if (this.uid == '73565430') { + date.setDate(date.getDate() + 5) + this.deadline = `${date.getFullYear()}-${date.getMonth() + 1}-${date.getDate()} 12:00:00` + } else { + date.setDate(date.getDate() + 3) + this.deadline = `${date.getFullYear()}-${date.getMonth() + 1}-${date.getDate()} 12:00:00` + } let structured_content = post.structured_content let result = structured_content.match(/{\"link\":\"https:\/\/webstatic.mihoyo.com\/bbs\/event\/live\/index.html\?act_id=(.*?)\\/) if (result) { @@ -134,7 +142,7 @@ export class exchange extends plugin { } // 兑换码使用 - async useCode () { + async useCode() { const cdkCode = this.e.msg.replace(/#(兑换码使用|cdk-u)/, '').trim() const res = await MysInfo.get(this.e, 'useCdk', { cdk: cdkCode }) if (res) { diff --git a/plugins/genshin/defSet/pool/11.yaml b/plugins/genshin/defSet/pool/11.yaml index 6b8bf7c..d8afea2 100644 --- a/plugins/genshin/defSet/pool/11.yaml +++ b/plugins/genshin/defSet/pool/11.yaml @@ -1,3 +1,13 @@ +- from: '2024-05-08 06:00:00' + to: '2024-05-29 11:59:59' + five: + - 知更鸟 + - 托帕&账账 + four: + - 三月七 + - 寒鸦 + - 雪衣 + name: 翼声纯律|落日条款 - from: '2024-04-17 12:00:00' to: '2024-05-07 14:59:59' five: diff --git a/plugins/genshin/defSet/pool/12.yaml b/plugins/genshin/defSet/pool/12.yaml index 9945e2d..eb5eeee 100644 --- a/plugins/genshin/defSet/pool/12.yaml +++ b/plugins/genshin/defSet/pool/12.yaml @@ -1,3 +1,13 @@ +- from: '2024-05-08 06:00:00' + to: '2024-05-29 11:59:59' + five: + - 夜色流光溢彩 + - 烦恼着,幸福着 + four: + - 无边曼舞 + - 论剑 + - 此时恰好 + name: 流光定影|溯回忆象 - from: '2024-04-17 12:00:00' to: '2024-05-07 14:59:59' five: diff --git a/plugins/genshin/defSet/pool/301.yaml b/plugins/genshin/defSet/pool/301.yaml index da67301..afb4619 100644 --- a/plugins/genshin/defSet/pool/301.yaml +++ b/plugins/genshin/defSet/pool/301.yaml @@ -1,3 +1,23 @@ +- from: '2024-05-14 18:00:00' + to: '2024-06-04 14:59:59' + five: + - 流浪者 + - 白术 + four: + - 莱依拉 + - 珐露珊 + - 北斗 + name: 久世浮倾|遵生合和 +- from: '2024-04-24 06:00:00' + to: '2024-05-14 17:59:59' + five: + - 阿蕾奇诺 + - 林尼 + four: + - 菲米尼 + - 琳妮特 + - 香菱 + name: 炉边烬影|光与影的戏术 - from: '2024-04-02 18:00:00' to: '2024-04-23 14:59:59' five: diff --git a/plugins/genshin/defSet/pool/302.yaml b/plugins/genshin/defSet/pool/302.yaml index 2f778a6..1ca07c2 100644 --- a/plugins/genshin/defSet/pool/302.yaml +++ b/plugins/genshin/defSet/pool/302.yaml @@ -1,3 +1,27 @@ +- from: '2024-05-14 18:00:00' + to: '2024-06-04 14:59:59' + five: + - 图莱杜拉的回忆 + - 碧落之珑 + four: + - 勘探钻机 + - 测距规 + - 西风剑 + - 雨裁 + - 祭礼残章 + name: 神铸赋形 +- from: '2024-04-24 06:00:00' + to: '2024-05-14 17:59:59' + five: + - 赤月之形 + - 最初的大魔术 + four: + - 船坞长剑 + - 便携动力锯 + - 匣里灭辰 + - 昭心 + - 西风猎弓 + name: 神铸赋形 - from: '2024-04-02 18:00:00' to: '2024-04-23 14:59:59' five: diff --git a/trss.js b/trss.js index 4a3eca7..9256eae 100644 --- a/trss.js +++ b/trss.js @@ -52,9 +52,9 @@ const qq = readYaml("config/config/qq.yaml") exec("git remote add trss https://gitee.com/TimeRainStarSky/Yunzai") exec("git fetch trss main") -exec("git reset --hard") exec("git clean -df") mv("config/config", "config/config_miao") +exec("git reset --hard") exec("git checkout --track trss/main") rm("plugins/ICQQ-Plugin") exec("git clone --depth 1 --single-branch https://gitee.com/TimeRainStarSky/Yunzai-ICQQ-Plugin plugins/ICQQ-Plugin")