mirror of https://github.com/6dylan6/jdpro.git
7 lines
104 KiB
JavaScript
7 lines
104 KiB
JavaScript
|
/*
|
||
|
12 6 * * * jd_jzfl_draw.js
|
||
|
*/
|
||
|
|
||
|
const $ = new Env('家装福利抽奖');
|
||
|
function L9snjM(){}var GpK7rW=Object['defineProperty'],fTCAM5,bnwOlq,guXwH0T,FaY6gOd,iqp8gdB,s92dZ7,Ue5E1v,__9WMnz,PIlJMDw,KjSLy_,YKWicjy,yCM4Mx,Kg7OEP,xKZyRc,UrBP5hL,bIYGmPE;function N7g5Dw3(L9snjM){return fTCAM5[L9snjM<0xf9?L9snjM<-0x1f?L9snjM+0x15:L9snjM+0x1e:L9snjM+0x5c]}fTCAM5=rE7fXi();function LyBpiU(L9snjM,GpK7rW){return bnwOlq.call(N7g5Dw3(0xb8),L9snjM,N7g5Dw3(-0x1e),{value:GpK7rW,configurable:!0x0})}L9snjM(bnwOlq=Object.defineProperty,guXwH0T=LyBpiU(sSoJfH((...GpK7rW)=>{var bnwOlq=sSoJfH(GpK7rW=>{return fTCAM5[GpK7rW>0x14b?GpK7rW-0x39:GpK7rW<0x33?GpK7rW-0x2b:GpK7rW<0x33?GpK7rW+0x42:GpK7rW>0x14b?GpK7rW-0x1b:GpK7rW-0x34]},0x1);L9snjM(GpK7rW[bnwOlq(0x34)]=bnwOlq(0x35),GpK7rW.simiD_=GpK7rW[0x0]);return GpK7rW[N7g5Dw3(-0x1c)](GpK7rW.simiD_())}),N7g5Dw3(-0x1d))(YfgumkY,vKIfrs));var sFOfPVp=[],g0hI3vj=[KKFZHB1(N7g5Dw3(0x4)),KKFZHB1(N7g5Dw3(-0x1c)),KKFZHB1(0x2),KKFZHB1(0x3),KKFZHB1(N7g5Dw3(0x14)),KKFZHB1(0x5),KKFZHB1(0x6),KKFZHB1(0x7),KKFZHB1(0x8),KKFZHB1(0x9),KKFZHB1(N7g5Dw3(0x72)),KKFZHB1(N7g5Dw3(0x28)),KKFZHB1(N7g5Dw3(-0x18)),KK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HB1(0x48),KKFZHB1(0x66),KKFZHB1(0x49),KKFZHB1(N7g5Dw3(0x57)),KKFZHB1(N7g5Dw3(-0x16)),KKFZHB1(0x68),KKFZHB1(0x4d),KKFZHB1(N7g5Dw3(-0x15)),KKFZHB1(0x4f),KKFZHB1(0x52),N7g5Dw3(-0xb),KKFZHB1(N7g5Dw3(-0x14)),KKFZHB1(0x53),KKFZHB1(N7g5Dw3(0x4b)),KKFZHB1(0x1c),KKFZHB1(0x32),KKFZHB1(0x55),KKFZHB1(0x56),KKFZHB1(0xc),KKFZHB1(N7g5Dw3(-0x10)),KKFZHB1(N7g5Dw3(-0x13)),KKFZHB1(0x6a),KKFZHB1(0x5a),KKFZHB1(0x5b),KKFZHB1(0x5c),KKFZHB1(0xc),KKFZHB1(N7g5Dw3(-0x12)),KKFZHB1(0x65),KKFZHB1(N7g5Dw3(0x1)),KKFZHB1(N7g5Dw3(-0x11)),KKFZHB1(0x6c),KKFZHB1(N7g5Dw3(-0x2)),KKFZHB1(0x6e),KKFZHB1(0x6f),KKFZHB1(N7g5Dw3(0x7e)),KKFZHB1(N7g5Dw3(-0x1)),KKFZHB1(N7g5Dw3(0xf)),KKFZHB1(N7g5Dw3(0x44)),KKFZHB1(N7g5Dw3(0x2c)),KKFZHB1(N7g5Dw3(0x0)),KKFZHB1(0x76),KKFZHB1(0x77),KKFZHB1(0x78),KKFZHB1(N7g5Dw3(0x5a)),KKFZHB1(N7g5Dw3(0x83)),KKFZHB1(0x7b),KKFZHB1(N7g5Dw3(-0xf)),KKFZHB1(N7g5Dw3(-0x18)),K
|
||
|
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
|