Fix: [CN] core monthly shop never scrolls, items on later pages can never be bought - #5855
Open
wanwan-doudou wants to merge 2 commits into
Open
Fix: [CN] core monthly shop never scrolls, items on later pages can never be bought#5855wanwan-doudou wants to merge 2 commits into
wanwan-doudou wants to merge 2 commits into
Conversation
CoreShop_250814.run() called shop_buy() once and returned, so only the first 2 rows out of about 20 were ever seen. Items placed on later pages could never be found, including the templates added in LmeSzinc#5837. Locate item rows by the core icon in price bar, the static grid only matches when the list is at top. Scroll by dragging the item list instead of the scrollbar, whose lower half overlaps a dark illustration and loses contrast near the bottom.
Allow the top reset to use the same swipe guard as page scanning, and stop the shop run if the top boundary cannot be confirmed.
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.
Summary
Fixes #5853 — the core monthly shop (核心月度商店) never scrolls, so only the first 2 rows out of about 20 are ever seen. Items placed on later pages can never be found or bought, including the torpedo / AP shell / heavy shell templates added in #5837.
CoreShop_250814.run()calledshop_buy()once and returned, unlike medal shop which walks the list page by page.The visible first page is not a reliable assumption: scroll position and exchange state can differ between accounts and runs. The three templates were on the first page on the test account, while #5853 reported them later in the list, so the shop must reset to the top and scan the full list.
Changes
assets/shop/cost/Core_4.png,origin_y = icon_y - 129), the same approach medal shop uses. The static gridorigin=(265, 238)only matches when the list is at top; once scrolled,predict()returns an empty list because every item failspredict_valid, so the log only showsNo shop items foundwith no visible error.device.drag()with a shake at the end rather thanswipe_vector(). Plain swipes keep sliding from inertia, moving about 4 rows per page while only 2 rows are detected, silently skipping half of the items.device.click_record_remove()after each drag, otherwise walking the whole list tripsGameTooManyClickError(the guard fires at 12 clicks on the same button).Testing
Tested against a live CN client (about 20 rows / 99 items):
Type93PureOxygenTorpedo/Type1ArmorPiercingShell/SuperHeavyShellare recognized with the correct names and groups.Chip: item clicked,AMOUNT_MAXselected 10, purchase confirmed, core 17416 → 17066.Type93PureOxygenTorpedo/Type1ArmorPiercingShell/SuperHeavyShellwere each recognized, clicked, confirmed, and marked sold out in one run; core 17066 → 15566 → 14766 → 13966. No other item was purchased.Only tested on CN. Scrolling and row detection use fixed geometry and a text-free core icon rather than localized text, so they are expected to work on other servers, but this remains unverified.