DorskFR / LeaguePyBot

A Python computer vision bot for League Of Legends
MIT License
65 stars 19 forks source link

I get an error 'NoneType' object has no attribute 'shape' in line 514. #3

Closed papapapapython closed 3 years ago

papapapapython commented 3 years ago

I have installed every requirement and I don't know what I've done wrong. Here is my output: File "C:\Users\user\source\repos\lleaguepybot\leaguepybot\leaguepybot.py", line 514, in template_match

width = int(template.shape[1] / ratio) File "C:\Users\user\source\repos\leaguepybot\leaguepybot\leaguepybot.py", line 483, in lookup x, y, *_ = template_match(sct_img, template) File "C:\Users\wolf2\source\repos\leaguepybot\leaguepybot\leaguepybot.py", line 596, in screen_watcher (Current frame) if lookup(CLIENT_LOGIN_BOX, "patterns/client/login.png") != (0, 0):

Is there any way to solve this? Thank you

DorskFR commented 3 years ago

I wouldn't waste too much time with v1 if I were you. I'm a bit busy now but will finish v2 soonish.

The stack trace is incomplete to understand the error you are getting.

In any case, v1 being based on screenshots only, the locale of your client has to match the screenshots so there's some manual work to do to prepare the files because the ones in the repo match the japanese client.