v0.10.0 fix to engine game state mgmt, client and web ui updates to match
This commit is contained in:
+3
-3
@@ -156,7 +156,7 @@ Returns current game state.
|
||||
|
||||
**Long-polling support:**
|
||||
Add query parameters for real-time updates:
|
||||
- `wait=true` - Enable long-polling (waits up to 25 seconds)
|
||||
- `wait=true` - Enable long-polling (waits up to 30 seconds)
|
||||
- `moveCount=N` - Last known move count
|
||||
|
||||
Returns immediately if game state changed, otherwise waits for updates:
|
||||
@@ -167,7 +167,7 @@ GET /games/{gameId}?wait=true&moveCount=5
|
||||
Response includes all game data. Compare `moves` array length to detect changes.
|
||||
|
||||
**Timeout behavior:**
|
||||
- Returns current state after 25 seconds even if no changes
|
||||
- Returns current state after 30 seconds even if no changes
|
||||
- Client disconnection cancels wait immediately
|
||||
- Game deletion notifies all waiting clients
|
||||
|
||||
@@ -242,4 +242,4 @@ Tokens are HS256-signed JWTs valid for 7 days. Include in Authorization header:
|
||||
Authorization: Bearer <token>
|
||||
```
|
||||
|
||||
Token claims include `sub` (user ID), `username`, `email`, and `exp` (expiration).
|
||||
Token claims include `sub` (user ID), `username`, `email`, and `exp` (expiration).
|
||||
|
||||
Reference in New Issue
Block a user