fix: enhancement identification and forced selections#190
Conversation
When a Charm Tag (or similar) opens a free booster pack from BLIND_SELECT, skipping or selecting all cards must return the game to BLIND_SELECT — not SHOP. The polling loop now checks for both states so it doesn't hang waiting for SHOP after a tag-triggered pack. This issue was first noted in PR #190. Co-authored-by: icebear <icebear0828@users.noreply.github.com>
When a Charm Tag (or similar) opens a free booster pack from BLIND_SELECT, skipping or selecting all cards must return the game to BLIND_SELECT — not SHOP. The polling loop now checks for both states so it doesn't hang waiting for SHOP after a tag-triggered pack. This issue was first noted in PR #190. Co-authored-by: icebear <icebear0828@users.noreply.github.com>
… card The Cerulean Bell boss blind (bl_final_bell) forces one random card to always be selected via card.ability.forced_selection. Both endpoints called unhighlight_all() which preserves forced cards, causing the forced card to silently leak into the played/discarded hand alongside the user's requested cards. Add validation that checks for forced_selection on any card in hand and rejects with BAD_REQUEST if the forced card is not included in the request. Replace unhighlight_all() with targeted logic that only clears non-forced highlights and only clicks cards not already highlighted, avoiding reliance on toggle no-op behavior. This issue was first notice in PR #190 Co-authored-by: icebear <icebear0828@users.noreply.github.com>
|
thanks for this PR! Im going through your various suggestion/fix/improvements implementing those myself in the dev branch crediting you as co-author. So far I've fix the issue regarding the tag that reward an arcana pack and the one related to the boss that force one card to be selected. In the latter one I've notice that your fix is wrong: the forced highlighted cards were played/discard along side the API provided cards (even if I was using unhighlight_all, the force_select keep playing them silently). The proper fix I've added a validation mechanism that check that the played/discard cards send in the API request include the forced selected cards. For the time being I keep this PR open and close it when I implemented all the fix/feat that I want to include in balatro. Thanks again for this PR. btw im working on a logging/replay system that should improve bug reproducibility along side with some QoL improvements for |
Fixes unhighlight hack and improves enhancement identification using config center.