mirror of https://github.com/BIGOSTK/elm
19 lines
162 KiB
JavaScript
19 lines
162 KiB
JavaScript
|
/**
|
|||
|
* @平行绳 飞机频道:https://t.me/tigerorrose
|
|||
|
* 变量:elmck: 必填,账号cookie,短信登录面板项目地址:https://github.com/funaihui/eleWeb
|
|||
|
* 定时随意,每天跑一遍就可以
|
|||
|
* cron: 7 9 * * *
|
|||
|
* 2023.6.15 更新:完成个别任务;任务升级;游戏;自动兑换乐园币;
|
|||
|
* 2023.6.16 更新:新增买房置地和升级称号任务,增加领取部分任务奖励;修改环境变量为 elmck
|
|||
|
* 2023.6.19 更新:新增知识百科游戏
|
|||
|
* 2023.7.7 更新:添加限制
|
|||
|
* 2023.7.9 更新:删除知识百科,只保留成语闯关。通关后也可继续领取游戏奖励,提升每天的金币收入
|
|||
|
*/
|
|||
|
|
|||
|
const $ = new Env('饿了么乐成语闯关');
|
|||
|
|
|||
|
const _0x3d55=['w4fDg8OxwrFR','LVdqw6Q0','w6xlHsOvXw==','Y3MVT8KZ','e3Efwpo8','ccKqw6/DmBTDu8KadyLCr8O1QsK9wrPDvcOv','w7whfsOMwo0=','w7srwqpOcA==','fnguw78X','w45QwqbDt8Ov','JVvCsTlh','eMKjw4zDozY=','EsKbCMKRw7c=','w7zDpsOHwq1C','w75IwqTDjsOT','I8OTwrrClMOLY8OtwoMrw7M7SMOFXAs/TyLCq8O+w4I=','bWwgWsKg','w70BfMOuwrs=','dsK5w4bDnQs=','XkAGwrke','R0k1wrt1wol6wrbDucKz','NkrCnA1q','w5LDl8KV','w73DvMODw4XDhCE=','WcKawqXCv8O8','w67CsMK1VlnCpcKkw6NYw7cpWMK2AB3CvlrChEPCukzCn8OPw5HDhEzDj0xfWcKUw6hFeUvDvVB3AsOIwovDm8KmwooWwr7DqizDgUEoE28=','DMOEJ1tz','w4V7wpbDqMOQ','ZMOpN8Ksw6c=','wqjDkWfCrVA=','YsKCwqs=','ZxnDt8KRwoE=','UW4Rw4ck','ai3DrsKAwrM=','fsOBFsOYeg==','wpR7LMKywr8=','bCjDpsKNwoY=','w73Du8OJw4DDij0o','NBHDsMOqNA==','WsOeAcKcw6s=','wqFKEcKK','I8OTwrrClMOLY8OtwoMrw7M7SMOFXAs/TyLCr8O+w4I=','S2M6dMKL','VcKkwpXCkMOX','S1bDlAPDq8K2Lw==','AGHCsQpq','E8OWbhrCow==','w4EAbh8R','w7zDiMOEDTU=','GsO3wp7CkkfCjcKUdiEj','w65OwqnDgE7Dt2B1KCMYFy7DgsKFw7jCocOCwqPCu8O9','wqzDn3bChGY=','TBbDozU7','HsOsInR8','w7zDu8O5Lwo=','fBPDn8Kwwq0=','EhjCuxjDrw==','RW86U8Oa','EMOgRRPCiw==','w4ohwrlFcA==','w7jDg8OmwpZc','GcOcfRLCjg==','e8ObI8KQw7o=','w4oUThA4','c8Oowo3DjMKa','Q8O7wrTDmcK/DlBhw55Zw7XDqQDCksOtw53CgcOmGxrCrMKkccKKF8KFwoTClMKTw6xwwq3DhsKSNR/CrcOAOlxww7IgNsO4wpgkCTfChCAdY8OwVgcsN35Bwq88PcK7w7/DhcO2PsO1SyI6QcOgCXp5w7rCsMOeLMOSwo09BMKnwrA7LkLDm8O1wodSWV5SEhADGwDCuxjDqiUbw4o4wqHCqsKRwqDCuEt4w4EmJ8OXwqLCoMOOADpRwoXDhcOBUxlETcOJw7I4','PcOeK3Nj','ZMOJGsO0Vg==','fsKUw7TDhis=','OsONwqjCrQA=','EATCjAfDoQ==','GcO4wo0uw5I=','w5ZaPMOudA==','TsOMEsK/w4TDv8KMwoHCqg==','bVvCiA==','w6QNwq/DjAHCuC4rdC8XFy7DgsKMw7TCrcKRw7nCssOldsOqw7LCnMO1EcK4wpYtUcOiw4pmT8KJa2DDnjl/NMOlW3t6c3AYw7HCvcKIEcOQY8KawoQwMMKIw6nCow5/esOHw6rCli5WWMKaw5AYIsORwo8XLsKTMMO0w7k9w4tWDcKMw47Di3BIFcKdw43Ds3xzwrjDhEDDnnnCisOjw6wDbxnDsMKJAsOfw63Du8OFfcOAw54HHcKrw7ELUGbDlMO5ZsOlw5YZLHHDucKXZ8O+w6fDmDbDj1nCtMKlw4XCmA9kw5RHwoFjQsOSwrBxIcKjQhAgF8KawoFCIcOrAUcfBcON','GTzCpynDoQ==','QsKMw7jDpDU=','cQTDqCYG','w4jCucOcBUsSUsKT','w5fDksOAwoNV','NMKaHMOYXw==','HXAtwoBABQ==','w4YGVRY6','w5wjwpJfYw==','w5tIw7IDZA==','w7TDlsOpw4fDuQ==','RsOaFMO9Vw==','w7/Dj8OfwrVD','Y8ONwq7Dp8K9','VcKqwpJIwo8=','e1Udw4UU','WwjDkMKpwq0=','w6w4wqBzZQ==','GXgnwpk=','bkshfMOI','Z3nCqUA1','HzLDkMO/MA==','Q37DuT3Dmw==','w5zDlsKIYGQ=','wrhDC8KNwqA=','w4sCYcOkwoU=','Sl3Dix3DuA==','wpLDuAfDssKR','PcOkDF5o','EEkwdMKtc8KKw4DCucOgbsKcw47DqMKqJsOtbFzChDjCqRjCjxs2T8KySmLCgcOKw47Dowh5PMKVScOFcMOcF8O3XG7Cl1lZScOMw5zDrUrDtWvDoCIuNSzCksOowq1CMzXDmcOYwqHCp8OkRGbDpi0BAMOew45UfcKgwoU=','TgUlccO1M8KLw44=','PynDo8O4Aw==','wrDCvMOMdnEaMsKwOw==','K2lUw5wy','wpbDk2TCvUk=','Ekcpwr5B','w7zCncOuMHI=','CCxgVAI=','P3zCsQJ5','EQ3Du8OOHQ==','bsKEwrjCmcOWM8K+w4Z+','USHCuB5KfwvCi8KZw4Mjwrg/w49M','QF8XUMOD','wrZHA8KXwro=','aXYMS8KmwqY=','wpclwozDqFY=','ZcO3I8Omaw==','fg3Dpg48','NlBUw4I1','Og7Du8OTGg==','HyPDjg==','w611w4kIQA==','w7dKChZI','K3B0w4MV','wo0UwpzDtW8=','EzLDmMOwEw==','w7jDoMOEDDFpBgfCssOfIzd5wqDCqMKq','5bys5Yqy6Yax5buj','YGojwpM6','LwXDlsONMg==','Ql7Cr1oI','wp7DtTrDksKy','BT/Dq8OdHw==','KBDDgsOwPw==','AUAkwrBj','w5bDu8Ocwox3','w7HDucKQRGY=','w5x7J8OWdMOdXxI=','dVvDkybDrQ==','CEgEwq5r','w4PCtcOLE08=','w48DfDID','VcKewqI=','w5rDhsOuAyE=','w4TDncOJw5nDqA==','bnfCvEs9','wqwZwrI=','LsKZVlfDjcKKQsOlXxfCvsOkw6fDrGMvNMOew6HDr8OUw4PDrVfDg8KVEkVvw4PCqXrDoSo=','wrtaDw==','w7vDucOOMDl4Bh4=','GlsYwo1Zw7oYwrDDnA8=','eXIbeMKA','w5sjwqhTZUk=','BMKRwo7CnMOD','H8OBbQ==','anIZbcKrwrfClwg=','wqjDnQrDoMKqw410BQ==','Mx3DnsOdLg==','fcOswrjDmcKq','w61gwpDDucOw','w6FVSUfCq8Kow6Jbw7Eswoo=','wrY5fVDCpw==','STrCmQxI','w4oRYgoH','wp5uKsKqwp8=','KyJeewN+woAvw75ywqPCiEhNYhbDlMOPFFJa','cQDCnRhw','w7dCwqvDucO+','w41iwpfDqcO/','PkvChDZP','S8OFDcOocQ==','EBjDucOmBg==','eVoRbsKn','PsKhNsOLSg==','cHUJwrwI','bkIsSMO3','bkfCll8Qa19PL1TCnyA=','woDDq3zCnHI=','wqRuAsKiJw==','NsOMwoHCsz8=','w4luw5w/aA==','Ji4QwpTCtg==','wpPDhCLDmsKj','wqXDlU7CvX3CtGjCsw==','TXEVZ8KA','w6zDm8ObEjQ=','w6jDm8ORwoZL','w4UjUCsh','wo4PwpvDj0U=','cMKdwq1/woY=','w6zDtMOTBA4=','w68ywopfYQ==','w7d0wpHDrcO+','HMKcA8OCasKv','w4vDp8Ouwo9U','fsO5FsO0dg==','5b2r5Yqg6YSU5bi5','EcOaaxXCgw==','ZDXDhsKswq8UfMKgwqDCl8KzwpsgFH3DuF/
|
|||
|
|
|||
|
// 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
|