Open AmzharTech opened 1 year ago
Hey. I did stop using this for a while. I take long breaks from games sometimes. But I did notice this same issue after coming back. I'm not sure if this is something they did to make botting harder or if I got lucky before.
The issue for me was with the image detection not lining up exactly. If the image pyautogui.locateOnScreen
is looking for doesn't match pixel for pixel it will fail.
You'll see in the updated code I started using a for loop for image matching. I also starting running the game on the same resolution every time.
You can set the window resolution in the game settings so it's consistent.
Then I grabbed a screenshot of the image I want to detect and used that in for for loop as img_0 for example. Then when/if detection fails I grab the screenshot of the text it couldn't find and I save that and add it to the for loop as img_1. And so on.
You might need to delete the images and capture your own if your screen resolution is different than mine (1080p).
If your computer has day/night blue light shift enabled that may make screenshot undetectable when that changes. I'm not sure. I haven't tested that specifically.
The image looping code makes it so it runs a little slower now, but the point is to be able to let it run afk reliably, so loosing a few minutes isn't too bad.
Hope this helps.
Thanks for your reply. I'll try out your suggestions when I have the time.
Hey, I tried your suggestion and it's working now, up to the point where if the magikarp breaks free from the ball, everything stops. I'm trying to see which part of the code detects this but I can't seem to figure it out, would you be willing to help out?
So, I didn't implement code that will catch "any" pokemon. Only magikarp in the safari zone. If you use an old rod, you'll only encounter magikarp.
A cool trick is, if you throw a rock first, then you have a 100% catch rate.
So I detect if the pokemon fled after a rock throw, but I never wrote code to detect if it broke out of a ball since that won't happen for magikarp after one rock throw. It might flee right after the rock throw, though.
So on a complete safari run, the bot gets 30 magikarp every time. Since the pokemon flees after a rock throw, or sticks around for the 100% catch rate.
Yea I get the magikarp part in safari zone. Is throwing rock really 100% catch rate? I haven't tried it honestly.
Also what happens once I run out of balls? Seems like nothing to indicate that it will restart the main().
On Sat, Nov 11, 2023 at 10:37 PM Elijah Blake @.***> wrote:
So, I didn't implement code that will catch "any" pokemon. Only magikarp in the safari zone. If you use and old rod, you'll only encounter magikarp.
A cool trick is, if you throw a rock first, then you have a 100% catch rate.
So I detect if the pokemon fled after a rock throw, but I never wrote code to detect if it broke out of a ball since that won't happen for magikarp after one rock throw.
So on a complete safari run, the bot gets 30 magikarp every time. Since the pokemon flees after a rock throw, or sticks around for the 100% catch rate.
— Reply to this email directly, view it on GitHub https://github.com/Manodiestra/open-pokemmo-bot/issues/2#issuecomment-1806833265, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFSMUSI7FUXZISOGN5SLTZ3YD6EUHAVCNFSM6AAAAAA7DDRQAGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMBWHAZTGMRWGU . You are receiving this because you authored the thread.Message ID: @.***>
Yeah, I didn't add anything to restart the loop. When I used it before I restarted it manually. This is still a WIP. I just decided to share it as a jump off point for people to use in the mean time.
You could probably close that loop by closing the modals that are up at the end of the safari run (by locating them and clicking on them and hitting esc). Then restart the loop.
AmzharTech, would you mind sharing the screenshots you got for the locateonscreen? I'm having trouble getting it to work right.
Yea I get the magikarp part in safari zone. Is throwing rock really 100% catch rate? I haven't tried it honestly. Also what happens once I run out of balls? Seems like nothing to indicate that it will restart the main(). … On Sat, Nov 11, 2023 at 10:37 PM Elijah Blake @.> wrote: So, I didn't implement code that will catch "any" pokemon. Only magikarp in the safari zone. If you use and old rod, you'll only encounter magikarp. A cool trick is, if you throw a rock first, then you have a 100% catch rate. So I detect if the pokemon fled after a rock throw, but I never wrote code to detect if it broke out of a ball since that won't happen for magikarp after one rock throw. So on a complete safari run, the bot gets 30 magikarp every time. Since the pokemon flees after a rock throw, or sticks around for the 100% catch rate. — Reply to this email directly, view it on GitHub <#2 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFSMUSI7FUXZISOGN5SLTZ3YD6EUHAVCNFSM6AAAAAA7DDRQAGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMBWHAZTGMRWGU . You are receiving this because you authored the thread.Message ID: @.>
Hey, not sure if this is still active. I made some changes to the walking/running holdkey to make it go correctly. But once I start fishing, whether it lands or not a nibble, it doesn't continue anything and I'm stumped.
Any ideas? Thanks.