refactor config

This commit is contained in:
2022-05-01 17:09:50 +02:00
parent 6bde685a7c
commit 3691bb9f78
32 changed files with 71 additions and 281 deletions

View File

@@ -1,7 +1,7 @@
import random
from time import time
from window_capture import WindowCapture
from stun_vision import StunVision
from vision import Vision
import cv2 as cv
import pytesseract
from hsvfilter import HsvFilter
@@ -18,7 +18,7 @@ def run():
# initialize the StunWindowCapture class
try:
capture_window = WindowCapture(
None, "stun", config)
None, "magic", config)
video_mode = False
except:
# StunWindowCapture.list_window_names()
@@ -27,21 +27,17 @@ def run():
video_mode = True
# initialize the StunVision class
vision_stun = StunVision()
vision_stun = Vision()
# initialize the StunOverlay class
hsv_filter_orange = HsvFilter(10, 156, 0, 17, 255, 255, 0, 0, 0, 0)
hsv_filter_p = HsvFilter(130, 156, 0, 179, 255, 255, 0, 0, 0, 0)
hsv_filter_b = HsvFilter(88, 156, 0, 128, 255, 255, 0, 0, 0, 0)
hsv_filter_g = HsvFilter(34, 156, 0, 74, 255, 255, 0, 0, 0, 0)
hsv_filter_y = HsvFilter(24, 156, 0, 33, 255, 255, 0, 0, 0, 0)
#hsv_filter_0 = HsvFilter(0, 156, 0, 7, 255, 255, 0, 0, 0, 0)
hsv_filter_0 = HsvFilter(0, 0, 0, 179, 255, 255, 255, 0, 0, 0)
hsv_filter_w = HsvFilter(69, 25, 0, 94, 255, 255, 0, 0, 0, 0)
loop_time = time()
event_time = 0.0
pointstore = []
max_results = 0
pause = True
magic_list = {"1": "body", "2": "finding", "3": "mind", "4": "perceiving", "5": "physical", "6": "seeing",
@@ -52,7 +48,6 @@ def run():
needle_list = []
hsv_list = []
# tmp = []
for key1 in tier_list:
for key2 in magic_list: