Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def click_button(self, image_name):
- while not pyautogui.locateOnScreen(image_name):
- print("looking for{}".format(image_name))
- x, y = pyautogui.locateCenterOnScreen(path.join("screenshots", image_name))
- pyautogui.click(x / 2, y / 2) #"problem" here
Add Comment
Please, Sign In to add comment