Commit Graph

15 Commits

Author SHA1 Message Date
acf32d0418 Redesign status bar to split Turn Info (left) and Player Identity (right) 2025-12-21 20:15:46 +11:00
91535dc8fc Merge status and turn indicator into single UI bar 2025-12-21 20:08:33 +11:00
481de45276 Merge turn indicator with player indicator at top
- Added ID to turn label for easier updates
- Updated multiplayer.js to use turnLabel ID
- Reset turn label when switching modes or resetting game
- Improved UX by keeping player/turn info together
2025-12-21 17:52:12 +11:00
bcf3b0a032 FEATURE: Migrate username storage from localStorage to IndexedDB
- Created storage.js wrapper with IndexedDB support
- Automatic fallback to localStorage if IndexedDB unavailable
- Updated all username storage calls to use async API
- Better performance and more storage capacity
- Improved PWA compatibility

Benefits:
- 50MB+ storage vs 5-10MB localStorage
- Async API doesn't block main thread
- Better for future features (game history, stats, etc.)
2025-12-14 12:15:16 +11:00
8b275de519 CRITICAL FIX: Resolve race condition in socket listener setup
- Set up all socket listeners BEFORE connection completes
- Remove nested 'connect' listener that caused race condition
- Add comprehensive logging for registration flow
- Update all listeners to use socket parameter
- Fix window.multiplayerClient reference in retry link

This fixes the 'Registering...' stuck state issue.
2025-12-13 21:35:47 +11:00
831aa0856d Add debug logging and fix registerPlayer UI feedback 2025-12-13 20:55:30 +11:00
b57611f0c4 Fix variable scope: Ensure global access to game and multiplayer client 2025-12-13 20:34:07 +11:00
dbc3f40019 Fix Join Multiplayer race condition: Save username before socket ready 2025-12-13 20:18:44 +11:00
0739ab6257 Improve UX: Prompt for username immediately in multiplayer 2025-12-13 20:17:23 +11:00
2d34ceb8bd Fix production connection: Remove bad proxies, add UI feedback 2025-12-13 20:13:29 +11:00
d959102db3 Fix multiplayer connection: Add redundant proxies and Socket.io CDN 2025-12-13 19:54:13 +11:00
858a5e52d4 Fix: Use dynamic server URL for Socket.io connection (production fix) 2025-12-13 19:21:29 +11:00
e06ab2457d Fix auto-login loading players bug 2025-12-13 15:06:18 +11:00
a7f3bf9b9e Add localStorage username persistence for auto-login 2025-12-13 15:02:30 +11:00
9465409b2f Add complete multiplayer system with real-time gameplay, challenge system, and 50x50 board option 2025-12-13 14:59:44 +11:00