Bläddra i källkod

!2 add jina function

pcacc 5 månader sedan
förälder
incheckning
ac74d19022

+ 1 - 4
.gitignore

@@ -1,8 +1,5 @@
 yys_tmp.png
 yys.png
 yys2.png
-__pycache__/yys_define.cpython-311.pyc
-__pycache__/yys_pic.cpython-311.pyc
-__pycache__/yys_task.cpython-311.pyc
 config.json
-*.pyc
+*.pyc

BIN
__pycache__/dongri_define.cpython-311.pyc


BIN
__pycache__/dongri_pic.cpython-311.pyc


BIN
__pycache__/dongri_task.cpython-311.pyc


+ 4 - 3
app_dongri.py

@@ -181,12 +181,13 @@ def add_auto_task(isMaxCollect, isSimple = False):
         if not isSimple:
             task_queue.appendleft(task_information())
         task_queue.appendleft(task_checkHelp(False))
-        if not isSimple:
-            task_queue.appendleft(task_paticipateInTeam())
+        #if not isSimple:
+        #    task_queue.appendleft(task_paticipateInTeam())
         task_queue.appendleft(check_buildOrResearch())
         task_queue.appendleft(task_cure())
         if not isSimple:
-            task_queue.appendleft(task_fightMonster(False, True, isSimple))
+            #task_queue.appendleft(task_fightMonster(False, True, isSimple))
+            task_queue.appendleft(task_fight_jina(True))
         task_queue.appendleft(task_collect(collectType, isSimple))
         task_queue.appendleft(task_train(False))
         task_queue.appendleft(task_collect(collectType, isSimple))

BIN
dongri_img/check/jina_jiao.png


BIN
dongri_img/check/other.png


BIN
dongri_img/check/other2.png


BIN
dongri_img/check/pack.png


+ 4 - 0
dongri_pic.py

@@ -103,6 +103,10 @@ class check_img:
     annimal_skill = R'dongri_img\check\anninal_skill.png'
     wolf_skill = R'dongri_img\check\wolf_skill.png'
     use = R'dongri_img\check\use.png'
+    pack = R'dongri_img\check\pack.png'
+    other = R'dongri_img\check\other.png'
+    other2 = R'dongri_img\check\other2.png'
+    jina_jiao = R'dongri_img\check\jina_jiao.png'
 
 
 class information_img:

+ 52 - 2
dongri_task.py

@@ -128,7 +128,6 @@ class basic_operate:
         return True
     @staticmethod
     def add_strength():
-        basic_operate.do_back()
         if waitClickImg_noWait_withBool(check_img.no_strength, 2, 1) == False:
             return False
         
@@ -204,6 +203,57 @@ class dongri_task:
     def run(self):
         print(f"Running task: {self.name}")
 
+class task_fight_jina(dongri_task):
+    def __init__(self, add_strengh):
+        super().__init__("战斗吉娜")
+        self.add_strengh = add_strengh
+
+
+    def run(self):
+        basic_operate.go_outside()
+
+        if False == waitFindImg_withBool(monster_img.enough_strengh, 2, 1):
+            if self.add_strengh:
+                basic_operate.add_strength()
+                basic_operate.go_outside()
+            else:
+                print("没有足够的体力了")
+                return False
+            
+        if waitClickImg_noWait_withBool(check_img.pack, 2, 1) == False:
+            return False
+        
+        if waitClickImg_noWait_withBool((check_img.other, check_img.other2), 2, 1) == False:
+            return False
+        
+        if waitClickImg_noWait_withBool(check_img.jina_jiao, 2, 1) == False:
+            return False
+        
+        if waitClickImg_noWait_withBool(check_img.use, 2, 1) == False:
+            return False
+        
+        if waitClickImg_noWait_withBool(monster_img.muti_team, 2, 1) == False:
+            return False
+        waitClickImg_noWait_withBool(monster_img.begin_multi, 2, 1)
+
+        if waitClickImg_noWait_withBool(monster_img.line1, 2, 1) == False:
+            return False
+        if waitFindImg_withBool(monster_img.no_hero, 2, 1) == True:
+            return False
+        if waitClickImg_noWait_withBool(monster_img.all_select, 2, 1) == False:
+            return False
+        waitClickImg_noWait_withBool(monster_img.all_select, 2, 1)
+
+        maxTryTimes = 3
+        while maxTryTimes > 0:
+            maxTryTimes -= 1
+            waitClickImg_withBool([monster_img.fight, monster_img.fight2], 2, 1)
+            waitClickImg_noWait_withBool(monster_img.all_select, 2, 1)
+
+        return True
+        
+            
+
 
 class task_fightMonster(dongri_task):
     def __init__(self, add_strengh, fight_bigMonster, isSimple):
@@ -629,4 +679,4 @@ if __name__ == '__main__':
     #task_collect(4).run()
     #task_returnAllLine().run()
     #task_paticipateInTeam().run()
-    task_useAnnimalSkill().run()
+    task_fight_jina(True).run()