Skip to content
This repository has been archived by the owner on Jul 24, 2024. It is now read-only.

Commit

Permalink
修复 尝试收取次数不生效导致多次重试的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
TKaxv-7S authored Jun 21, 2024
1 parent 1588a3c commit 654e239
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ public ModelFields setFields() {
modelFields.addField(collectEnergy = new BooleanModelField("collectEnergy", "收集能量", true));
modelFields.addField(batchRobEnergy = new BooleanModelField("batchRobEnergy", "一键收取", true));
modelFields.addField(collectInterval = new StringModelField("collectInterval", "收取间隔(毫秒或毫秒范围)", "500"));
modelFields.addField(advanceTime = new IntegerModelField("advanceTime", "提前时间(毫秒)", 0, Integer.MIN_VALUE, 250));
modelFields.addField(advanceTime = new IntegerModelField("advanceTime", "提前时间(毫秒)", 0, Integer.MIN_VALUE, 500));
modelFields.addField(tryCount = new IntegerModelField("tryCount", "尝试收取(次数)", 1, 0, 10));
modelFields.addField(retryInterval = new IntegerModelField("retryInterval", "重试间隔(毫秒)", 500, 0, 6000));
modelFields.addField(returnWater10 = new IntegerModelField("returnWater10", "浇水10克需收能量(关闭:0)", 0));
Expand Down Expand Up @@ -753,6 +753,7 @@ private void collectUserEnergy(String userId, long bubbleId, String bizNo) {
int thisTryCount = 0;
do {
thisTryCount++;
isDouble = false;
rpcEntity = AntForestRpcCall.getCollectEnergyRpcEntity(null, userId, bubbleId);
ApplicationHook.requestObject(rpcEntity, 0, retryIntervalInt);
if (rpcEntity.getHasError()) {
Expand Down Expand Up @@ -840,6 +841,7 @@ private void collectUserBatchEnergy(String userId, final List<Long> bubbleIdList
int thisTryCount = 0;
do {
thisTryCount++;
isDouble = false;
rpcEntity = AntForestRpcCall.getCollectBatchEnergyRpcEntity(userId, doBubbleIdList);
ApplicationHook.requestObject(rpcEntity, 0, retryIntervalInt);
if (rpcEntity.getHasError()) {
Expand Down

0 comments on commit 654e239

Please sign in to comment.