From 9e3cf9d78a1176ae24b79c718c33e02e97753dba Mon Sep 17 00:00:00 2001 From: tiennm99 Date: Thu, 1 Oct 2026 22:43:05 +0700 Subject: [PATCH] fix(gacha): park the pointer off the card after tearing the pack The scripted drag released the mouse over where the card lands. Once the card arrived under it, pack-cards tilted the hovered card toward the pointer over its .22s transition, so the face kept moving after the spin stopped. The pointer now moves to the corner when the drag ends. --- renderer/src/render/render-gacha.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/renderer/src/render/render-gacha.js b/renderer/src/render/render-gacha.js index e9de3f6..1c7075a 100644 --- a/renderer/src/render/render-gacha.js +++ b/renderer/src/render/render-gacha.js @@ -276,6 +276,11 @@ const captureFrames = async (cdp, sessionId, request, dir, guard) => { } else if (pressed) { mouse({type: 'mouseReleased', button: 'left', clickCount: 1}); pressed = false; + // Park the pointer in the corner, off the card. Left where the drag ended, + // it sits over the card once the card lands, and pack-cards tilts a + // hovered card toward the pointer, nudging the face after the spin stops. + pointer = {x: 0, y: 0}; + mouse({type: 'mouseMoved'}); } // Input is acknowledged only once a frame consumes it, so draw before // awaiting it. BeginFrame omits the screenshot when nothing changed.