Fix Bug:Stuck at Gacha in Himeko Trail#401
Open
zhaoqiman wants to merge 12 commits intoLmeSzinc:masterfrom
Open
Fix Bug:Stuck at Gacha in Himeko Trail#401zhaoqiman wants to merge 12 commits intoLmeSzinc:masterfrom
zhaoqiman wants to merge 12 commits intoLmeSzinc:masterfrom
Conversation
Author
|
This bug can be reproduced as long as the beginner's Gacha remains. 只要新手卡池还在,几乎每次运行都可复现此BUG。 |
LmeSzinc
reviewed
Apr 5, 2024
tasks/daily/trail.py
Outdated
Comment on lines
+77
to
+80
| # Slide down to find Himeko gacha | ||
| if first_gacha: | ||
| self.device.swipe((70, 520), (70, 180)) | ||
| self.wait_until_stable(REGULAR_GACHA_CHECK) |
Owner
There was a problem hiding this comment.
参考 Alas 的 代码规范
- 需要判断新手卡池的存在,无新手卡池不应该有下滑操作
- 操作需要有重试
- 避免手写坐标
- 避免依赖 wait_until_stable
zhaoqiman
commented
Apr 6, 2024
LmeSzinc
reviewed
Apr 8, 2024
tasks/daily/trail.py
Outdated
Comment on lines
+79
to
+80
| elif not self.match_color(CHARACTER_TRIAL, interval=2)\ | ||
| and dragged_time < 5: |
Author
|
感谢 @LmeSzinc 的建议指导。制作了_BEGINNER_GACHA_CHECK_用于模板匹配新手卡池,_match_template_color_的识别间隔置4,尽量减少_swipe_vector_对游戏操作。 |
LmeSzinc
reviewed
Apr 14, 2024
Owner
There was a problem hiding this comment.
- 图片做得精致一点,不要下面漏出杂色背景,一般就裁切到文字上
- 文字类 assets 不能放在 share 目录下,要适配多语言
- 添加 SEARCH 属性 assets,增大搜索区域以适配没有活动卡池的情况
Comment on lines
+78
to
+83
| # Slide down to find regular gacha if beginner gacha found | ||
| if self.match_template_color(BEGINNER_GACHA_CHECK,interval=4): | ||
| swipe_vector = (0, -4*REGULAR_GACHA_CLICK.height) | ||
| self.device.swipe_vector(swipe_vector, box=REGULAR_GACHA_CLICK.search, | ||
| random_range=(-10, -10, 10, 10), name='FIND_REGULAR_GACHA_DRAG') | ||
| continue |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
修复bug: 姬子试用卡在抽卡界面
新手卡池未抽完时,常驻卡池在最下方页面外,无法正常识别,导致在姬子试用环节卡死。
通过添加了左侧的卡池滑动动作,显示出卡池,以防止此bug。
Fix:Stuck at Gacha when Himeko Trail
In Himeko Trial, if beginner's gacha remains, target gacha will be outside of the page, thus program stuch at gacha page.
Add slide action on left of the page to fix it.