游戏自动答题器
Auto clicker for games
您好,我想在 python 中创建一个脚本,它可以立即接受我的游戏。
我使用 IDLE SHELL:
执行以下操作
import pyautogui
import os
**butt=pyautogui.locateCenterOnScreen('C:\Users\dariu\Desktop\autoclicker\button.png', minSearchTime=2000)**
pyautogui.moveTo(butt)
pyautogui.click(butt)
pyautogui.click(butt)
在粗体代码行之后出现以下错误:
Traceback (most recent call last):
File "<pyshell#6>", line 1, in <module>
butt=pyautogui.locateCenterOnScreen('C:\Users\dariu\Desktop\autoclicker\button.png', minSearchTime=2000)
File "C:\Users\dariu\AppData\Local\Programs\Python\Python310\lib\site-packages\pyautogui\__init__.py", line 175, in wrapper
return wrappedFunction(*args, **kwargs)
File "C:\Users\dariu\AppData\Local\Programs\Python\Python310\lib\site-packages\pyautogui\__init__.py", line 207, in locateCenterOnScreen
return pyscreeze.locateCenterOnScreen(*args, **kwargs)
File "C:\Users\dariu\AppData\Local\Programs\Python\Python310\lib\site-packages\pyscreeze\__init__.py", line 413, in locateCenterOnScreen
coords = locateOnScreen(image, **kwargs)
File "C:\Users\dariu\AppData\Local\Programs\Python\Python310\lib\site-packages\pyscreeze\__init__.py", line 372, in locateOnScreen
screenshotIm = screenshot(region=None) # the locateAll() function must handle cropping to return accurate coordinates, so don't pass a region here.
File "C:\Users\dariu\AppData\Local\Programs\Python\Python310\lib\site-packages\pyscreeze\__init__.py", line 144, in wrapper
raise PyScreezeException('The Pillow package is required to use this function.')
pyscreeze.PyScreezeException: The Pillow package is required to use this function.
似乎需要 Pillow 包才能使用您的包之一。检查回溯错误的最后一行
在粗体行之前导入:link to Pillow PyPI
您好,我想在 python 中创建一个脚本,它可以立即接受我的游戏。 我使用 IDLE SHELL:
执行以下操作import pyautogui
import os
**butt=pyautogui.locateCenterOnScreen('C:\Users\dariu\Desktop\autoclicker\button.png', minSearchTime=2000)**
pyautogui.moveTo(butt)
pyautogui.click(butt)
pyautogui.click(butt)
在粗体代码行之后出现以下错误:
Traceback (most recent call last):
File "<pyshell#6>", line 1, in <module>
butt=pyautogui.locateCenterOnScreen('C:\Users\dariu\Desktop\autoclicker\button.png', minSearchTime=2000)
File "C:\Users\dariu\AppData\Local\Programs\Python\Python310\lib\site-packages\pyautogui\__init__.py", line 175, in wrapper
return wrappedFunction(*args, **kwargs)
File "C:\Users\dariu\AppData\Local\Programs\Python\Python310\lib\site-packages\pyautogui\__init__.py", line 207, in locateCenterOnScreen
return pyscreeze.locateCenterOnScreen(*args, **kwargs)
File "C:\Users\dariu\AppData\Local\Programs\Python\Python310\lib\site-packages\pyscreeze\__init__.py", line 413, in locateCenterOnScreen
coords = locateOnScreen(image, **kwargs)
File "C:\Users\dariu\AppData\Local\Programs\Python\Python310\lib\site-packages\pyscreeze\__init__.py", line 372, in locateOnScreen
screenshotIm = screenshot(region=None) # the locateAll() function must handle cropping to return accurate coordinates, so don't pass a region here.
File "C:\Users\dariu\AppData\Local\Programs\Python\Python310\lib\site-packages\pyscreeze\__init__.py", line 144, in wrapper
raise PyScreezeException('The Pillow package is required to use this function.')
pyscreeze.PyScreezeException: The Pillow package is required to use this function.
似乎需要 Pillow 包才能使用您的包之一。检查回溯错误的最后一行
在粗体行之前导入:link to Pillow PyPI