浇水添加1s延时,连续浇水时请求容易异常

This commit is contained in:
wangsq
2020-12-22 13:39:57 +08:00
parent a535facf15
commit 6480e9ee83

View File

@@ -982,6 +982,9 @@ async function gotStageAwardForFarm(type) {
} }
//浇水API //浇水API
async function waterGoodForFarm() { async function waterGoodForFarm() {
await $.wait(1000);
console.log('等待了1秒');
const functionId = arguments.callee.name.toString(); const functionId = arguments.callee.name.toString();
$.waterResult = await request(functionId); $.waterResult = await request(functionId);
} }
@@ -991,7 +994,7 @@ async function initForTurntableFarm() {
} }
async function lotteryForTurntableFarm() { async function lotteryForTurntableFarm() {
await $.wait(2000); await $.wait(2000);
console.log('等待了5秒') console.log('等待了2秒');
$.lotteryRes = await request(arguments.callee.name.toString(), {type: 1, version: 4, channel: 1}); $.lotteryRes = await request(arguments.callee.name.toString(), {type: 1, version: 4, channel: 1});
} }