|
@@ -32,6 +32,11 @@ from dongri_pic import _imported
|
|
|
|
|
|
'''
|
|
'''
|
|
|
|
|
|
|
|
+todo_msg = ''
|
|
|
|
+def get_todo_msg():
|
|
|
|
+ global todo_msg
|
|
|
|
+ return todo_msg
|
|
|
|
+
|
|
def task_getComputerName():
|
|
def task_getComputerName():
|
|
return socket.gethostname()
|
|
return socket.gethostname()
|
|
|
|
|
|
@@ -65,7 +70,7 @@ class basic_operate:
|
|
return
|
|
return
|
|
ret, pos = waitFindImg(place_img.title, 1, 0)
|
|
ret, pos = waitFindImg(place_img.title, 1, 0)
|
|
if ret:
|
|
if ret:
|
|
- pcacc_mouse.click(pos[0], pos[1] + 80)
|
|
|
|
|
|
+ pcacc_mouse.click(pos[0] + 80, pos[1] + 80)
|
|
|
|
|
|
|
|
|
|
def backToGame(preTime = 0):
|
|
def backToGame(preTime = 0):
|
|
@@ -807,12 +812,30 @@ class task_checkMaster(dongri_task):
|
|
return False
|
|
return False
|
|
return True
|
|
return True
|
|
|
|
|
|
|
|
+class task_checkActivities(dongri_task):
|
|
|
|
+
|
|
|
|
+ def __init__(self):
|
|
|
|
+ super().__init__(f"检查各种活动时间")
|
|
|
|
+ def run(self):
|
|
|
|
+ global todo_msg
|
|
|
|
+ basic_operate.go_outside()
|
|
|
|
+ if waitClickImg_noWait_withBool(check_img.activity_open, 2, 1) == False:
|
|
|
|
+ return False
|
|
|
|
+ if waitFindImg_withBool(check_img.todoList, 2, 1) == False:
|
|
|
|
+ return False
|
|
|
|
+
|
|
|
|
+ activityStr = yys_ocrAuto(check_img.todo_region)
|
|
|
|
+ if not activityStr:
|
|
|
|
+ todo_msg = activityStr
|
|
|
|
+ return activityStr
|
|
|
|
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if __name__ == '__main__':
|
|
if __name__ == '__main__':
|
|
- task_checkMaster().run()
|
|
|
|
|
|
+ task_checkActivities().run()
|
|
|
|
+ #task_checkMaster().run()
|
|
#basic_operate.get_line_num()
|
|
#basic_operate.get_line_num()
|
|
#yys_ocrAuto(check_img.line_orc)
|
|
#yys_ocrAuto(check_img.line_orc)
|
|
#basic_operate.go_town()
|
|
#basic_operate.go_town()
|