feat: cascade 5 global multiplayer systems to all game endpoints
- domino-match.php: add can_player_queue anti-abuse, last_activity tracking,
server-side turn timeout (30s), universal complete_match rewards,
heartbeat + leave handlers
- game.php (chess): add heartbeat + leave handlers, last_activity on moves,
replace homebrew auto-close with server turn timeout (120s),
replace inline reward logic with universal complete_match RPC
- matchmaking.php: add can_player_queue cooldown check before queuing
- ludo.php (old API): add last_activity on moves, complete_match on end
- match-session.js: change ping from move-based to heartbeat action,
handle 'abandoned' status in poll response
- match-ui.js: add showBotReplacement and showTurnTimedOut overlays
- engine.js: add domino endpoint mapping for match recovery
- domino/game.js: add heartbeat (10s interval), handle _turn_timed_out,
update endMatch to send winners array to universal rewards
- domino/result.js: remove duplicate complete call for live games,
use new winners-array format for bot games
- ludo/result.js: add rewards display (coins, XP, rating change)
- Move shared supabaseRpc helper to includes/supabase.php
Co-Authored-By:
Claude Opus 4.6 <noreply@anthropic.com>
Showing
Please register or sign in to comment