Skip to content

Conversation

@EswarBalasubramanian
Copy link
Contributor

@EswarBalasubramanian EswarBalasubramanian commented Jan 21, 2024

  1. Updated opencv package version
  2. adb screenshot command issue fixed
  3. image_compare max_val reduced tolerance by 0.05 to execute properly in bigger screen sizes.

Copy link
Owner

@CodeWithMa CodeWithMa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your PR. Please check my comments.

# Update the maximum value and corresponding image file and coordinates if necessary
if val > max_val:
# if val > max_val:
if ('max_number_of_games_played_text.en.png' == image_file and val > 0.42):
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you explain why you use val > 0.42? I tested the changes from your PR and I had to change this to 0.43. With 0.42 it detected every screen as max number of games played and just stopped.

Copy link
Contributor Author

@EswarBalasubramanian EswarBalasubramanian Feb 10, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when I used it in my small android device, even after capturing the text in the screenshot, the bot unable to detect it and loops clicking the battle button. The 0.42 is the value where max games played screenshot score exceeds, battle button screenshot score

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK. I have refactored quite a bit in the meantime. I had the same problem and added a priority list if multiple images match. See #4 and

priority_list = [
.

I have cherry picked your other changes for windows support in #3 and merged them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants