(self, goto, num=1)
| 199 | # 我忘记了打完后是否需要关闭 挑战界面 |
| 200 | |
| 201 | def secret(self, goto, num=1): |
| 202 | self.ui_click(goto, self.I_WQSE_FIRE) |
| 203 | for i in range(num): |
| 204 | self.wait_until_appear(self.I_WQSE_FIRE) |
| 205 | # self.ui_click_until_disappear(self.I_WQSE_FIRE) |
| 206 | # 又臭又长的对话针的是服了这个网易 |
| 207 | click_count = 0 |
| 208 | while 1: |
| 209 | self.screenshot() |
| 210 | if not self.appear(self.I_UI_BACK_RED, threshold=0.7): |
| 211 | break |
| 212 | if self.appear_then_click(self.I_WQSE_FIRE, interval=1): |
| 213 | continue |
| 214 | if self.appear(self.I_UI_BACK_RED, threshold=0.7) and not self.appear(self.I_WQSE_FIRE): |
| 215 | self.click(self.C_SECRET_CHAT, interval=0.8) |
| 216 | click_count += 1 |
| 217 | if click_count >= 6: |
| 218 | logger.warning('Secret mission chat too long, force to close') |
| 219 | click_count = 0 |
| 220 | self.device.click_record_clear() |
| 221 | continue |
| 222 | success = self.run_general_battle(self.battle_config) |
| 223 | while 1: |
| 224 | self.screenshot() |
| 225 | if self.appear(self.I_CHECK_EXPLORATION): |
| 226 | break |
| 227 | if self.appear_then_click(self.I_UI_BACK_RED, interval=1): |
| 228 | continue |
| 229 | if self.appear_then_click(self.I_UI_BACK_BLUE, interval=1.5): |
| 230 | continue |
| 231 | logger.info('Secret mission finished') |
| 232 | |
| 233 | def invite_five(self): |
| 234 | """ |
no test coverage detected