remaining: this.state.bag.length
})}\n\n`);
- /* Send active claim state if any. */
+ /* Send active claim state if any, including items already claimed. */
if (this.state.claim_queue.length > 0) {
const claimer = this.active_claimer_player();
response.write(`event: claim-start\ndata: ${JSON.stringify({
player_name: claimer ? claimer.name : "Unknown",
timeout_ms: 0,
- warning_ms: 0
+ warning_ms: 0,
+ claimed_letters: this.state.claimed_letters,
+ claimed_words: this.state.claimed_words.map(cw => ({
+ word: cw.word_obj.word,
+ word_id: cw.word_id
+ }))
})}\n\n`);
}