Repository navigation
Conversation
…実機(Pixel 8a)では ?swap=1 のほうが操作しやすかった。ドラッグは 1 tick に 1 マス(約 17ms)で追従し、横に滑る動きは見えなくなる。pnpm sim endless(各 6 回)では 2 フレームに比べ casual の得点 8617 から 8399・生存 436 秒から 446 秒、swiper の得点 7117 から 6997・生存 474 秒から 466 秒、pnpm sim duel の normal 同士の試合時間は 273.9 秒から 245.9 秒、hard 同士は 179.7 秒から 172.3 秒。決定論が変わるのでオンラインの GAME_VERSION を online-v7 に上げる。入れ替え中の状態が tick の外から見えなくなるので、テストは状態の代わりに柄の位置と、宙に浮いたパネルで静止を確かめる
uphy
enabled auto-merge (squash)
October 2, 2026 23:24
|
プレビュー: https://swaprise-pr-87.uphy.workers.dev |
This was referenced Oct 2, 2026
uphy
added a commit
that referenced
this pull request
Oct 3, 2026
…えていたのを滑らかにする。tick は handleInput のあと updateCells なので swapping の状態は draw から一度も見えず、timer から横ずれを出す式は常に 0 だった。swap のイベントに左の列と行を足し、BoardView が [行][列] の残りのずれ(px)に来た向きの 1 マスを積んで、毎フレーム時定数 SWAP_SLIDE_MS(20ms。1 フレーム後 43%、4 フレーム後 3%)で指数的に減らす。論理は今までどおり 1 tick で確定するので決定論と GAME_VERSION は変えない。残りのずれをセルの object でなく位置に持つのは、オンラインの予測が確定盤面を複製するたびにセルを作り直すため。せり上がりで行がずれたら一緒にずらし、タッチの白枠も同じずれで動かす。実機で長さを試せるよう ?slide=<ms> で変えられる (#88) Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
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.
何をなぜ
#86 で入れ替えを 4 フレームから 2 フレームに縮めたが、実機(Pixel 8a)では
?swap=1(#85 のプレビュー)のほうが操作しやすかった。TIMING.swapを 2 から 1 にする。入れ替えはその tick のうちに終わり、ドラッグは 1 tick に 1 マス(約 17ms)で追従する。横に滑る動きは見えなくなる。止まったマスで揃いを判定する挙動は変わらない。GAME_VERSIONをonline-v7に上げて古い版とは対戦させないswapping)が tick の外から見えなくなるので、それを見ていたテストは、柄の位置や宙に浮いたパネルで確かめる形に直したバランス(pnpm sim、各 6 回)
2 フレームと 1 フレームの差は、6 回の試行のばらつきの範囲に収まっている。
確かめたこと
pnpm typecheck・pnpm testpnpm e2e e2e/game.spec.ts e2e/mobile.spec.ts e2e/puzzle.spec.ts e2e/lessons.spec.ts