From 1e7ee53a03840f911baa0c22f1bbd51ab3b98c06 Mon Sep 17 00:00:00 2001 From: KingRan Date: Fri, 25 Feb 2022 21:42:55 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jd_fruit_help.js | 4 ++-- jd_fruit_task.js | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/jd_fruit_help.js b/jd_fruit_help.js index bbba2ea..6ce9dfb 100644 --- a/jd_fruit_help.js +++ b/jd_fruit_help.js @@ -144,8 +144,8 @@ let llgetshare = false; $.retry = 0; lnrun++; await jdFruit(); - if (lnrun == 5) { - console.log(`\n【访问接口次数达到5次,休息一分钟.....】\n`); + if (lnrun == 3) { + console.log(`\n【访问接口次数达到3次,休息一分钟.....】\n`); await $.wait(60 * 1000); lnrun = 0; } diff --git a/jd_fruit_task.js b/jd_fruit_task.js index ba2ba91..ef0b9c2 100644 --- a/jd_fruit_task.js +++ b/jd_fruit_task.js @@ -132,6 +132,12 @@ async function jdFruit() { await getTenWaterAward(); //领取10浇水奖励 await getWaterFriendGotAward(); //领取为2好友浇水奖励 await duck(); + lnrun++; + if (lnrun == 10) { + console.log(`\n访问接口次数达到10次,休息30秒.....\n`); + await $.wait(30 * 1000); + lnrun = 0; + } if (!process.env.DO_TEN_WATER_AGAIN) { console.log('执行再次浇水') await doTenWaterAgain(); //再次浇水