Forráskód Böngészése

!2 add function get strength

pcacc 3 hónapja
szülő
commit
ef22554c65
5 módosított fájl, 33 hozzáadás és 5 törlés
  1. 4 3
      app_dongri.py
  2. BIN
      dongri_img/check/pet_btn.png
  3. BIN
      dongri_img/check/store_strength.png
  4. 3 0
      dongri_pic.py
  5. 26 2
      dongri_task.py

+ 4 - 3
app_dongri.py

@@ -297,7 +297,6 @@ def add_auto_task(isMaxCollect, isJina, isSimple = False, isAddStrengh = False,
             update_rungame_type(0)
             send_status(f'巨熊行动:在60min内,切换到无尽模式')
             g_times = 2
-            task_queue.appendleft(task_checkActivities())
         elif is_within_n_minutes(get_todo_time("巨熊行动"), 10, 40):
             task_queue.appendleft(task_returnAllLine())
             if len(task_queue) < 5:
@@ -320,11 +319,12 @@ def add_auto_task(isMaxCollect, isJina, isSimple = False, isAddStrengh = False,
             task_queue.appendleft(task_cure(True, g_cureNum))
             task_queue.appendleft(task_cure(True, g_cureNum))
             return
+        
+        if g_switch == False or get_rungame_type() == 0:
+            task_queue.appendleft(task_checkActivities())
         # first run
         if g_times % 3 == 1:
             task_queue.appendleft(check_safe_collect())
-            if g_switch == False or get_rungame_type() == 0:
-                task_queue.appendleft(task_checkActivities())
             
         if isSimple == False:
             task_queue.appendleft(task_information())
@@ -372,6 +372,7 @@ def add_auto_task(isMaxCollect, isJina, isSimple = False, isAddStrengh = False,
             task_queue.appendleft(task_train(train_type))
             task_queue.appendleft(task_useAnnimalSkill())
             task_queue.appendleft(task_read_mails())
+            task_queue.appendleft(task_getStrength())
             if auto_participate:
                 task_queue.appendleft(task_checkConfilits())
             task_queue.appendleft(task_checkDiamond())

BIN
dongri_img/check/pet_btn.png


BIN
dongri_img/check/store_strength.png


+ 3 - 0
dongri_pic.py

@@ -189,6 +189,9 @@ class check_img:
     diamond_saveMax = (310,505,316,511)
     diamond_save_btn = R'dongri_img\check\diamond_save_btn.png'
 
+    # strength
+    pet_btn = R'dongri_img\check\pet_btn.png'
+
 
 
 

+ 26 - 2
dongri_task.py

@@ -695,6 +695,27 @@ class task_gotoTree(dongri_task):
         waitClickImg_noWait_withBool(check_img.life_jam, 2, 1)
         return True
     
+class task_getStrength(dongri_task):
+    def __init__(self):
+        super().__init__(f"获取体力")
+    def run(self):
+        basic_operate.go_town()
+        if waitClickImg_noWait_withBool(train_img.quick_panel, 2, 1) == False:
+            return False
+        
+        myTimeSleep_big()
+        yys_dragAuto(check_img.move_down)
+        yys_dragAuto(check_img.move_down)
+        myTimeSleep_big()
+        if waitClickImg_noWait_withBool(check_img.pet_btn, 2, 1) == False:
+            return False
+        myTimeSleep_big()
+        basic_operate.go_town()
+        if waitClickImg_noWait_withBool(check_img.store_strength, 3, 1):
+            waitClickImg_noWait_withBool((check_img.get,check_img.bigGet), 2, 1)
+        return True
+
+    
 class task_checkStoreRoom(dongri_task):
     def __init__(self):
         super().__init__(f"检查仓库或招募")
@@ -710,7 +731,8 @@ class task_checkStoreRoom(dongri_task):
         if waitClickImg_noWait_withBool((train_img.train_success, check_img.needgo), 2, 1) == False:
             return False
         myTimeSleep_big()
-        if waitFindImg_withBool(check_img.pet_findtreature, 2, 1) == False:
+
+        if waitFindImg_withBool(check_img.pet_findtreature, 2, 1) == False:# storeroom
             waitClickImg_noWait_withBool(check_img.bigGet, 2, 1)
             pcacc_mouse.quickclick_current()
             myTimeSleep_big()
@@ -737,6 +759,7 @@ class task_checkStoreRoom(dongri_task):
 
         return True
     
+    
 class task_checkConfilits(dongri_task):
     def __init__(self):
         super().__init__(f"检查集结")
@@ -1393,7 +1416,8 @@ if __name__ == '__main__':
     #task_gotoTree().run()
     #task_fight_jina_only().run()
     #task_checkConfilits().run()
-    task_checkActivities().run()
+    task_getStrength().run()
+    #task_checkActivities().run()
     #task_checkMaster().run()
     #basic_operate.get_line_num()
     #yys_ocrAuto(check_img.line_orc)