mirror of
https://github.com/tiennm99/tiennm99bot.git
synced 2026-10-11 12:28:54 +00:00
/api/gachabeta now tears open a pack-cards collectible pack whose card shows the request's label, the same B/A/S rank as /api/gacha, and one star per rarity level; rarity also picks the card material and the pack colour. pack-cards animates on the browser clock, so the route drives a shared headless Chrome in deterministic mode over a debugging pipe, steps virtual time frame by frame, tears the pack with a scripted drag, and encodes the captured frames with Remotion's bundled ffmpeg. The page and package are served from disk with all other requests blocked. The browser stays alive per process and is warmed at start-up, because the first render compiles the pack's WebGL shaders in software. The Remotion beta composition and its scene code are removed. pack-cards is installed from a GitHub tarball pinned to a commit, since it has no npm release and a moving URL would break npm ci.