Skip to content

Commit e4dabf1

Browse files
committed
fix 25% speed upgrade fail
1 parent 6980965 commit e4dabf1

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

TbsCore/Tasks/LowLevel/UpgradeBuilding.cs

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -335,8 +335,17 @@ private async Task<bool> TryFastUpgrade(Account acc)
335335
await Task.Delay(AccountHelper.Delay(acc));
336336
}
337337

338+
while ( true)
339+
{
340+
acc.Wb.UpdateHtml();
341+
var node = acc.Wb.Html.GetElementbyId("videoFeature");
342+
if (node == null) continue;
343+
var element = acc.Wb.Driver.FindElementById("videoFeature");
344+
if (element == null) continue;
345+
element.Click();
346+
break;
347+
}
338348
// Has to be a legit "click"
339-
acc.Wb.FindElementById("videoFeature").Click();
340349

341350
// wait for finish watching ads
342351
var timeout = DateTime.Now.AddSeconds(100);

0 commit comments

Comments
 (0)