From 6cb5c4369202faee5d57fda50be93cfde860c2ed Mon Sep 17 00:00:00 2001 From: Martysh12 <49569238+Martysh12@users.noreply.github.com> Date: Sun, 26 Dec 2021 19:52:37 +0200 Subject: [PATCH] Removed d3dshot Removed d3dshot because newer Python versions do not support it/its dependencies. --- gameio.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/gameio.py b/gameio.py index c18a035..e1a610e 100644 --- a/gameio.py +++ b/gameio.py @@ -8,9 +8,6 @@ import pyautogui PLATFORM_SYS = platform.system() -if PLATFORM_SYS == "Windows": - import d3dshot - class AbstractGameIO(ABC): """Base class for each platform.""" @@ -46,10 +43,9 @@ class AbstractGameIO(ABC): class WindowsGameIO(AbstractGameIO): def __init__(self): super().__init__() - self.d = d3dshot.create() def fetch_sshot(self): - return self.d.screenshot() # TODO: Cut this to self.loc(x, y, w, h) + return pyautogui.screenshot(region=self.loc) def key_up(self, key: str): pyautogui.keyUp(key)