From 555ecfa7a3ffde05ff60223b77a4b221359905c0 Mon Sep 17 00:00:00 2001 From: Martysh12 <49569238+Martysh12@users.noreply.github.com> Date: Sun, 19 Dec 2021 20:18:07 +0200 Subject: [PATCH] Added newlines and sorted imports Added newlines and sorted imports according to PEP-8. --- main.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/main.py b/main.py index ba9eccf..f3b3cbe 100644 --- a/main.py +++ b/main.py @@ -1,13 +1,15 @@ -import pyautogui import os -if os.name == 'windows': +import pyautogui + +if os.name == "windows": import d3dshot + class AutomatableGame: def __init__(self): self.loc = pyautogui.locateOnScreen("images/app.png") - + def fetch_sshot(self): return pyautogui.screenshot(region=self.loc) @@ -19,6 +21,6 @@ class AutomatableGame__Windows(AutomatableGame): def __init__(self): super().__init__(self) self.d = d3dshot.create() - + def fetch_sshot(self): - return d.screenshot() # Cut this to self.loc(x, y, w, h) + return d.screenshot() # Cut this to self.loc(x, y, w, h)