Protect rendering performance
For a technical producer, this purchase confirmation prototype should make every player action and result the player can inspect easy to evaluate. Write how to show the exact item, Koin amount, balance impact, and explicit confirm/cancel actions. Map preview, confirmation, a player cancellation, not enough Koin, pending, success, delivery, owned, and reload. Give every failure a safe next action. Open and close the interface during GPU-heavy scenes, then monitor input, frame pacing, and canvas recovery. A commerce overlay should not leave the game loop paused or controls captured unexpectedly.
Coordinate DOM and canvas state
Make the selected item and outcome visible in both interface and gameplay context. Handle focus loss, pointer lock, fullscreen transitions, and a resized canvas around confirmation and return.
Exercise context recovery
Simulate refresh, background suspension, and a lost rendering context. The player-facing purchase result should reconcile separately from graphics recovery and must never duplicate an item.
Name every state and owner
Separate preview, confirmation, pending, success, delivery, owned, insufficient Koin, cancel, interrupted, and reopened states. Assign later production work for identity, persistence, native billing, security, refunds, policy, and monitoring.
Define idempotent recovery
Repeated confirmation, a slow response, navigation during delivery, and reopening must resolve to one result. Record which state is authoritative and how the player can safely retry without another grant or Koin deduction.
Turn the prototype into tickets
Capture the visible behavior first, then create implementation tasks with expected examples for each transition and platform boundary. Do not translate a working browser interaction into an unsupported claim that backend commerce is complete.
Repeat the complete choice
The confirmation should repeat the selected item, exact Koin amount, current Koin balance, remaining balance, and ownership rule without introducing a different offer. Test that behavior using WebGL games. WebGL rendering and commerce state need separate failure testing.
Separate confirm from cancel
Use distinct actions with clear labels and enough spacing for the target input method. Returning to the game should never spend Koin. Test that behavior using WebGL games. WebGL rendering and commerce state need separate failure testing.
Prevent repeated confirmation
After confirmation, show a pending state and disable repeated input until the result is known. A slow response should not create duplicate grants. Test that behavior using WebGL games. WebGL rendering and commerce state need separate failure testing.