From 47f0147703d54b0ed0091e14144b4162f2696f15 Mon Sep 17 00:00:00 2001 From: haptear Date: Fri, 10 Jun 2022 09:09:27 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BD=91=E6=98=93=E4=B8=A5=E9=80=892?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- wyyx.js | 33 +++++++++++++++++++++++++++++++-- 1 file changed, 31 insertions(+), 2 deletions(-) diff --git a/wyyx.js b/wyyx.js index a1bd28d..fca43ca 100644 --- a/wyyx.js +++ b/wyyx.js @@ -23,14 +23,14 @@ let hostname = "https://" + host; let ck_status = ""; let CryptoJS = require("crypto-js"); /////////////////////////////////////////////////////////////////// -let VersionCheck = "0.0.1" +let VersionCheck = "0.0.2" let Change = '签到!' let thank = `\n感谢 xx 的投稿` /////////////////////////////////////////////////////////////////// async function tips(ckArr) { // let Version_latest = await Version_Check('wyyx'); - let Version = `\n📌 本地脚本: V 0.0.1` + let Version = `\n📌 本地脚本: V 0.0.2` console.log(`${Version}`); msg += `${Version}` console.log(`📌 🆙 更新内容: ${Change}\n`); @@ -78,6 +78,9 @@ async function start() { console.log("\n开始 三餐水滴"); await scsd(); + console.log("\n开始 浏览商品"); + await llsp(); + console.log("\n开始 浇水"); await js(); @@ -202,6 +205,32 @@ async function scsd() { +/** +* 浏览商品 httpGet +*/ +async function llsp() { + let Options = { + url: `${hostname}/orchard/task/finish.json?taskId=VISIT_ITEM&taskRecordId=0`, + headers: { + 'Host': host, + 'X-WX-3RD-Session': ck[0], + 'Content-Type': 'application/json' + }, + }; + let result = await httpGet(Options, `浏览商品`); + + if (result.result.result == 1) { + DoubleLog(`浏览商品: 收取 10 滴水💧`); + } else if (result.result.result == 2) { + DoubleLog(`浏览商品: 没有可以收取的 💧`); + } else { + DoubleLog(`浏览商品: 失败 ❌ 了呢,原因未知!`); + console.log(result); + } +} + + + /** * 浇水 httpGet