Refactor: TemplateFinder() (#770)

* init, wip

* time to test

* remove unused dataclass

* tests passing, just need to run in-game

* fix wait logic

* add threading lock, delete excess funcs

* start putting best_match back in to search_and_wait()

* bugfixes, found a bad template

* scope

* fix npc detect
This commit is contained in:
mgleed
2022-05-18 01:35:27 -04:00
committed by GitHub
parent 203dce6775
commit 27ebd1b4db
54 changed files with 497 additions and 520 deletions
+2 -2
View File
@@ -2,7 +2,7 @@ import keyboard
from ui import skills
from utils.custom_mouse import mouse
from char import IChar
from template_finder import TemplateFinder
import template_finder
from pather import Pather
from logger import Logger
from screen import convert_abs_to_monitor, convert_screen_to_abs, grab
@@ -192,7 +192,7 @@ class Basic_Ranged(IChar):
if __name__ == "__main__":
import os
import keyboard
from template_finder import TemplateFinder
import template_finder
from pather import Pather
keyboard.add_hotkey('f12', lambda: Logger.info('Force Exit (f12)') or os._exit(1))
keyboard.wait("f11")