jdpro/jd_joymatch.js

9 lines
252 KiB
JavaScript
Raw Normal View History

2024-06-28 07:47:44 +00:00
/*
参加双人赛获胜可得300积分
1 1 1 1 * jd_joymatch.js
*/
const $ = new Env('宠汪汪-双人赛');
(function(_0x4c49ba,_0x3d21c6){const _0x26845c={_0xfba75e:'\x30\x78\x36\x30\x39',_0x2a1ab8:'\x30\x78\x35\x39\x30',_0x5b2c3a:'\x30\x78\x36\x33\x66',_0xc1a5d5:'\x5b\x55\x31\x48',_0x537e44:'\x30\x78\x37\x38\x39',_0x3c7da4:'\x30\x78\x36\x34\x36',_0x52835f:'\x30\x78\x37\x39\x34',_0x5aeb01:'\x4a\x40\x37\x21',_0x2c6657:'\x29\x54\x6a\x4c',_0x48c0aa:'\x30\x78\x34\x38\x65',_0x1eec19:'\x30\x78\x35\x32\x65',_0x556a80:'\x30\x78\x34\x64\x38',_0x17725b:'\x30\x78\x34\x65\x34',_0x2469b9:'\x30\x78\x34\x37\x34',_0x180df4:'\x30\x78\x33\x66\x37',_0x31484a:'\x4d\x4b\x34\x6c',_0x5abb18:'\x30\x78\x36\x34\x32',_0x542958:'\x30\x78\x35\x30\x38',_0x237b72:'\x30\x78\x34\x30\x30',_0x5cdd83:'\x6f\x5d\x53\x48',_0x50f64f:'\x6b\x35\x23\x47',_0x209890:'\x30\x78\x34\x35\x30',_0x1feba3:'\x30\x78\x36\x61\x32',_0x3d25dd:'\x30\x78\x35\x37\x35',_0x2b84c8:'\x55\x61\x24\x70',_0x141af9:'\x30\x78\x35\x65\x61',_0x40b8b5:'\x30\x78\x34\x37\x37',_0x2a77b6:'\x30\x78\x35\x36\x31',_0x484fda:'\x30\x78\x36\x30\x61',_0x25245e:'\x30\x78\x36\x33\x32',_0x4cb235:'\x30\x78\x35\x64\x39',_0x5edcf1:'\x5b\x55\x31\x48',_0x405348:'\x29\x54\x6a\x4c',_0x231d10:'\x30\x78\x37\x34\x39',_0x2a1019:'\x30\x78\x37\x37\x61',_0x3ab3be:'\x30\x78\x36\x34\x33'},_0x4897be={_0x52f138:'\x30\x78\x32\x39\x33'},_0x194465={_0x1c512c:'\x30\x78\x32\x39\x36'};function _0x289132(_0x5c4dbb,_0x4c7173,_0x186145,_0x4bf7c1){return _0x4283(_0x4bf7c1-_0x194465._0x1c512c,_0x5c4dbb);}function _0x3be36e(_0x36e655,_0x520e51,_0x56dd23,_0x5d963d){return _0x4283(_0x520e51-_0x4897be._0x52f138,_0x5d963d);}const _0x3b3125=_0x4c49ba();while(!![]){try{const _0x3a7583=parseInt(_0x3be36e(_0x26845c._0xfba75e,_0x26845c._0x2a1ab8,_0x26845c._0x5b2c3a,_0x26845c._0xc1a5d5))/(-0x2697+0x5*0x597+0xaa5)+parseInt(_0x3be36e(_0x26845c._0x537e44,_0x26845c._0x3c7da4,_0x26845c._0x52835f,_0x26845c._0x5aeb01))/(-0x21dd*0x1+-0x1da0+0x3f7f)+-parseInt(_0x289132(_0x26845c._0x2c6657,_0x26845c._0x48c0aa,_0x26845c._0x1eec19,_0x26845c._0x556a80))/(0xb7a+0x2*0x91c+-0x1daf)+parseInt(_0x3be36e(_0x26845c._0x17725b,_0x26845c._0x2469b9,_0x26845c._0x180df4,_0x26845c._0x31484a))/(-0x1e9*-0x4+-0x1a58+-0x1*-0x12b8)*(parseInt(_0x3be36e(_0x26845c._0x5abb18,_0x26845c._0x542958,_0x26845c._0x237b72,_0x26845c._0x5cdd83))/(0xb17*-0x1+-0x385+0xea1))+-parseInt(_0x289132(_0x26845c._0x50f64f,_0x26845c._0x209890,_0x26845c._0x1feba3,_0x26845c._0x3d25dd))/(0x35*-0xad+-0x4a2+0x2879)+parseInt(_0x289132(_0x26845c._0x2b84c8,_0x26845c._0x141af9,_0x26845c._0x40b8b5,_0x26845c._0x2a77b6))/(-0x355+-0x1*0x1154+0x14b0)*(-parseInt(_0x3be36e(_0x26845c._0x484fda,_0x26845c._0x25245e,_0x26845c._0x4cb235,_0x26845c._0x5edcf1))/(0x149*0x11+0x241b+0x544*-0xb))+parseInt(_0x289132(_0x26845c._0x405348,_0x26845c._0x231d10,_0x26845c._0x2a1019,_0x26845c._0x3ab3be))/(0x18eb+-0x1400+-0x4e2);if(_0x3a7583===_0x3d21c6)break;else _0x3b3125['push'](_0x3b3125['shift']());}catch(_0x30bf0a){_0x3b3125['push'](_0x3b3125['shift']());}}}(_0x2452,0xa2fb6*0x1+0x165f7*-0x1+0x49*-0xb27));const _0x190e06=$[_0x25a966('\x30\x78\x39\x37','\x30\x78\x32\x31','\x29\x67\x5d\x55','\x30\x78\x31\x32\x33')]()?require(_0x5c6b06('\x30\x78\x34\x64\x34','\x30\x78\x35\x36\x65','\x30\x78\x36\x62\x63','\x52\x40\x6e\x6f')):'',_0x3c75a9=$[_0x25a966(-'\x30\x78\x31\x31\x35',-'\x30\x78\x31\x62\x31','\x62\x73\x6c\x75',-'\x30\x78\x37\x61')]()?require(_0x25a966(-'\x30\x78\x31\x66\x61',-'\x30\x78\x61\x64','\x30\x66\x32\x58',-'\x30\x78\x31\x30\x39')):'';let _0xcc2443=!![],_0x5a02bf=[],_0x10a129='',_0xc3eda8='';function _0x4283(_0x660ac9,_0x54f4a6){const _0x62d19=_0x2452();return _0x4283=function(_0x206c94,_0x1de91d){_0x206c94=_0x206c94-(0x1471+0x24c2*-0x1+0x3*0x5ff);let _0xde9b6=_0x62d19[_0x206c94];if(_0x4283['\x57\x43\x6b\x67\x4a\x61']===undefined){var _0x1d5978=function(_0x249587){const _0x3991ce='\x61\x62\x63\x64\x65\x66\x67\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f\x70\x71\x72\x73\x74\x75\x76\x77\x78\x79\x7a\x41\x42\x43\x44\x45\x46\x47\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f\x50\x51\x52\x53\x54\x55\x56\x57\x58\x59\x5a\x30\x31\x32\x33\x34\x35\x36\x37\x38\x39\x2b\x2f\x3d';let _0x45a5b1='',_0x344ea0='',_0x739167=_0x45a5b1+_0x1d5978;for(let _0xe254bd=-0x1a*0xf6+-0x950+
// prettier-ignore
function Env(t, e) { "undefined" != typeof process && JSON.stringify(process.env).indexOf("GITHUB") > -1 && process.exit(0); class s { constructor(t) { this.env = t } send(t, e = "GET") { t = "string" == typeof t ? { url: t } : t; let s = this.get; return "POST" === e && (s = this.post), new Promise((e, i) => { s.call(this, t, (t, s, r) => { t ? i(t) : e(s) }) }) } get(t) { return this.send.call(this.env, t) } post(t) { return this.send.call(this.env, t, "POST") } } return new class { constructor(t, e) { this.name = t, this.http = new s(this), this.data = null, this.dataFile = "box.dat", this.logs = [], this.isMute = !1, this.isNeedRewrite = !1, this.logSeparator = "\n", this.startTime = (new Date).getTime(), Object.assign(this, e), this.log("", `🔔${this.name}, 开始!`) } isNode() { return "undefined" != typeof module && !!module.exports } isQuanX() { return "undefined" != typeof $task } isSurge() { return "undefined" != typeof $httpClient && "undefined" == typeof $loon } isLoon() { return "undefined" != typeof $loon } toObj(t, e = null) { try { return JSON.parse(t) } catch { return e } } toStr(t, e = null) { try { return JSON.stringify(t) } catch { return e } } getjson(t, e) { let s = e; const i = this.getdata(t); if (i) try { s = JSON.parse(this.getdata(t)) } catch { } return s } setjson(t, e) { try { return this.setdata(JSON.stringify(t), e) } catch { return !1 } } getScript(t) { return new Promise(e => { this.get({ url: t }, (t, s, i) => e(i)) }) } runScript(t, e) { return new Promise(s => { let i = this.getdata("@chavy_boxjs_userCfgs.httpapi"); i = i ? i.replace(/\n/g, "").trim() : i; let r = this.getdata("@chavy_boxjs_userCfgs.httpapi_timeout"); r = r ? 1 * r : 20, r = e && e.timeout ? e.timeout : r; const [o, h] = i.split("@"), n = { url: `http://${h}/v1/scripting/evaluate`, body: { script_text: t, mock_type: "cron", timeout: r }, headers: { "X-Key": o, Accept: "*/*" } }; this.post(n, (t, e, i) => s(i)) }).catch(t => this.logErr(t)) } loaddata() { if (!this.isNode()) return {}; { this.fs = this.fs ? this.fs : require("fs"), this.path = this.path ? this.path : require("path"); const t = this.path.resolve(this.dataFile), e = this.path.resolve(process.cwd(), this.dataFile), s = this.fs.existsSync(t), i = !s && this.fs.existsSync(e); if (!s && !i) return {}; { const i = s ? t : e; try { return JSON.parse(this.fs.readFileSync(i)) } catch (t) { return {} } } } } writedata() { if (this.isNode()) { this.fs = this.fs ? this.fs : require("fs"), this.path = this.path ? this.path : require("path"); const t = this.path.resolve(this.dataFile), e = this.path.resolve(process.cwd(), this.dataFile), s = this.fs.existsSync(t), i = !s && this.fs.existsSync(e), r = JSON.stringify(this.data); s ? this.fs.writeFileSync(t, r) : i ? this.fs.writeFileSync(e, r) : this.fs.writeFileSync(t, r) } } lodash_get(t, e, s) { const i = e.replace(/\[(\d+)\]/g, ".$1").split("."); let r = t; for (const t of i) if (r = Object(r)[t], void 0 === r) return s; return r } lodash_set(t, e, s) { return Object(t) !== t ? t : (Array.isArray(e) || (e = e.toString().match(/[^.[\]]+/g) || []), e.slice(0, -1).reduce((t, s, i) => Object(t[s]) === t[s] ? t[s] : t[s] = Math.abs(e[i + 1]) >> 0 == +e[i + 1] ? [] : {}, t)[e[e.length - 1]] = s, t) } getdata(t) { let e = this.getval(t); if (/^@/.test(t)) { const [, s, i] = /^@(.*?)\.(.*?)$/.exec(t), r = s ? this.getval(s) : ""; if (r) try { const t = JSON.parse(r); e = t ? this.lodash_get(t, i, "") : e } catch (t) { e = "" } } return e } setdata(t, e) { let s = !1; if (/^@/.test(e)) { const [, i, r] = /^@(.*?)\.(.*?)$/.exec(e), o = this.getval(i), h = i ? "null" === o ? null : o || "{}" : "{}"; try { const e = JSON.parse(h); this.lodash_set(e, r, t), s = this.setval(JSON.stringify(e), i) } catch (e) { const o = {}; this.lodash_set(o, r, t), s = this.setval(JSON.stringify(o), i) } } else s = this.setval(t, e); return s } getval(t) { return this.isSurge() || this.isLoon() ? $persistentStore.read(t) : this.isQuanX() ? $prefs.valueForKey(t) : this.isNode() ? (this.data = this.loaddata(), this.data[t]) : this.data && this.d