faker3/jd_opencard_puls.js

15 lines
52 KiB
JavaScript
Raw Normal View History

2024-08-03 04:27:45 +08:00
/*
不会自动运行请在有水的时候运行
//export jd_opencard_draw="3" //抽奖次数 3
//export jd_opencard_break="true" //IP限制后继续执行true/false
cron:1 1 1 1 *
*/
const $ = new Env('8.3-8.13 Plus尊享 宠爱驾到')
function _0x3208(){const _0x2b3360=['W7RcQdNcUCkSWR5zWQ7cULzJW6lcJSofBa','W7KkyCk3fNidorNcMMRdM3lcT8kx','wUE7VEAFPUAvU+MvGE+/Ta','WQFcPmk5tCoZW4e','W78Br1P0W57cTW','y8k6bmoDWPpcLa7cGgVcONFcTMb5W6tcTe3cOmoaAMnOWPT4WRpcMgTHf1HV','WPnBbKRcKW','rCkZeCkzWP7dSG','W5hcRdO','W7xcPcFdPG','eNi8FmkAW5b0mJ4GWOOv','77+P5BsA5OUp5yQa6ise5yQg55Qd6k6W5PsM6ls/5z6O5zYTh0W','jfVdKmkIpCop','WRBdQaxdLq','WO3cOSoGF8oKW5HZkq8','W5W6i1pcMva','W5z4mSo8CNSv','nUAFSowkIUEjLUAcQoATS+w6KU+8LUA1VUwjRoInTUwnHEAkJ+wiMq','W6VdNWhdMmkrWQr5','W7r7fmklW7CM','WPmNemk4hunDBmoyWQj7W7D+bJhcSa','5zoC6z+R55U15y2d6ycP5l+V5yQE5yI0WO3dImkzW6K','W4FcNCkmsdi','cmkPwa8','BrHEWQOR','sLJcM1ldP8ksgW','WOGaxhbecKRcQKH5','WRKOWQldLmoQxSkJtq','omk/hSoy','56wm5yQ25ycU','gJxdV8kIW7pdPq','aM4QDSkoW7r/jcK','WPWUWRtdJG','tSkyxmkbW5T0W6r7kmkH','WQxdTCoOWQrBBSkRWRZdP8oyWOO','mwRdUCkG','WQhcOmk5uW','e8k1qsZdTCobW4G','WOBcNCkTuCkBqW','W7nLWQOZj8ktW7GkE37dVgLAW7q','W4yjAsFcILhcNmktxq','WRhcS8kRt8oCW5RdMYVcQSosW7S','W4/dN3u','WQZdICoYWRVdQCkCWOBLVARLPBZJGPpKU4hKUBROTQlLJjK','WR0NWO9ckCkVeG','WQldValdNa','W4RcHSk2W7BcT8oE','W5GeuIdcGLK','tmode8kKn8kApG','W7ZcSSk+W7RdKSoY','r8oefmkBemkwnSo1','W7FcPcO','oLVdJ8kM','WPD2nmoNoZvmW60vnt5Pi0FcISoxW6K','WQxdQbJdGa','nvNdLSkQjSovW5dcG8o5hXZcSW','W5TuaIy3vHRdSG','xCkEx8kpW5TfW59Ziq','5OQG5AsV6i6B5B2CFhGR','d8oeWQnBWOpdO8oZiYZdQq','rSkQWRCrW7KP','5OMV5AEF5AwB5AAU5Q+177+55AsT5l+255IP5Q+e5PEx6kY+5yAu5OUd6kgp6isl5PYO','WP7cUCo6zmkyWOP+nGZdL0yDWPhcIwX6Fa','W4RdNNhcQsrfW5FdRW','5yQj5yEi5BUG6zck5l2e5zkV5AwQ6lA177256lA56l2k5Q2v6lw05y6c','WOO3pCk+a0fAACoa','W7n4WPxdMGWlWQ3dISoBmmo5WO8','W4ldK2BcRcDiW4BdPCoMwW','5lM55lUDWRPuW6RdHUs+R+wqHW','W6dcSSk+W5q','WOZcHSk7ESkw','W5rEfsqpxGpdRJWGBq','WPBcH8kYEG','5yMz5yQx56gC776n','vCk0emkpWR7dSq','W5dcJmkuqa','WOHGW7JdTSkxWQi','WQaZWOrK','hCocWRLwWRVdPCoZmWNdV8oQpvusyG','6i2X5y6B5lI65yIgASoUWPRdJSoxmq0ffZ8d6yca5yAX5OUA6kg2776p6k2t6ys45PsM5OU16kcx','6i+X5B6x5ywv5l2v5As05yIiDSk8','W4u+keFdM1XcyCoAaa','DUAERowjRoEkIEAdJow+JUw6V++9HUIUVEAHKoADOEE8MoE7RoAzK+wqSoAUV+w6KCkC','nuddNCozW5ZcGWG','fMm6ESkEW7rLoaqL','W4ZdGhFcQXjaW4ddUa','v8k/gSkkWRBdPmoTWQ8','WR9WkCkeW6m3WPFdImo1WRzjWQhdIG/dP1CCWQuFF17cJCoWWReAWONcK8kTWRTU','W7pdV0hcKq','WQz6WPNdNaa','WQy2W6XhFCkuW6OGEgpdKG','W6BcImkcvCouW5pdHW','W47MIkVKURhdRq','W5O6pLW','WPfVkCo4zubDW6ex','EeegWRBdPgWX','WRlcSmkIW5VdMCkRcmogW5CmW4hdLCoC','ieqrW7z7zu3cRSkfBq','W4RcJmk/','W51RW77cKSkCd8o6zSohW6NcGmkQaG','W5BcP8o6ESotW5bYoKxdJK4hWP3dIIi3FSozEIdcUxJdINhcT0tdTCoOeW','i8kNWPlcGmoFvSoPW58','W4b9lG','A0ysWQ7dPhiG','W53cNSkWttnV','a2e9EmkbW7K','WPvIkW','WO04WRpdJ8osvSk6uCozW7K','44g25O2o56Ac44oR6k6J5ysf6i6I5y6mWOv3WQpdH13cHq','ddxdPCkN','WPXJoG','lw7dP8kWECoc','hCocWRLwWRVdPCoZmW/dVSoG','tSkRgSoZWOLmDa','WQxdPCoVWQrEC8kmWRhdJ8oiW4jM','nmkQWOBcR8oxv8oP','5RAy5yIy5Bcu5z+TCq','WR3dR8oLWRqasSksW6JdISoyWPDDwSobWQ/cVG','W73cVCkUW5pdICoYvmkm','W5LsbG','WQhdVrddGmkHWOy','WRtcOSk+uCoPW5ZdGsBcHSoyWRi','WPxcRmo0','WQFcOmkKxmoWW5G','W7f3nmkdW7iKWOVdMmkFWRPj','jmkBCSoR','WRlcPmk+DCoMW7BdNdVcN8ovW6hdPW','ACoPaSkV','WRL2WPe','W59pmeVdNG9BWOzrW60zeK1lCbxcOSoFW5GOwgTC6zQh5yM65zc557Qt57MN5OUo6kgb772LW40YsJhdMmohrSoXWPH977YM','WPtdKmkQaq','W4atFYVcGL/cM8kqqa','sSkLdG','W6n/kCkAW5y4WPe','W7L6i8kgW7ePWPRdKG','WOxcQmkK','zmkIWRC','W7FcGmkzW7O','amk6amo0W5O','W6bMkCkqW6e','WPfVkCo+yxXCW7e6pq','W6jPWQ4GoSkvW6Kg','W6xcPcddRa','W7pcVZNcOmkPW60cW7JcLunPW6ZdHSocA3VcUSk5W4yNddJcNmoKWPijsSoKW5zPgW','p8oSgmkPW7lcO3BdKG','dSkLrH/dTCou','nmkMWPJcH8oBvSouWOK','B0OrWPFdOxu','gNKhFCkoW7i','W6NcSsddVwpdSCkQxCo0dJxcQCkHW7JcTchcQSocW43dIbRdGNRcIXlcGXxcPCogWROim8kcBCoGWPLyWQdcTYZcQmo0FaBcKmoFxSkWqrGHWP9PhSopW6WDrmoUeYW','W5xcJSkusdb1W4VdRmoVW4VdHK86nmo8','W7bHWQOr','W4FcImkorqHZW4VdVmokW50','WPyHjCkYdLi','jCkrAmoVgHaYW7FdGSkM','WQjObeG','WOm5WQ3dG8ohsW','aZhdTmk2WRhdQCk8W7tcLmkw','b8o9W4ZcKYiKyspcJ3ZdSq','8jwCPfFMGP3LL4lOJydLV4W','pmk/h8osWPK','WRRdVmkNW5VdV8o5xSkuWPGz','WRr6WOldGrCOWRhdL8og','uCk5WQSAW6qjW5ddSSocWPxdKxW','W63cQJm','uSkIWRubW7m2','WRXwaSowuKz3W5G6fW','nxrcjGZdNIxdUNW','bweGD8khW7bDkd41','W67cPt7cTCkUWPrcWRJcKLbO','WOHGW7RdO8kEWRXC','WQqNWOrNjCkU','sfWhWPddG2a5pW','W5hdLwhcSd1v','WRD2WPldLW','k3L5iqtdLG','W
// 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