pychess-variants
pychess-variants copied to clipboard
Chat messages in bughouse are recorded, however lost on reconnect or opening an old game and other issues
Action items:
- [X] Populate the chat list with the recorded chat messages
- [X] Make chat messages clickable and navigate to the move when the message was made
- [X] Depending if game is still in progress or not filter the messages according to only from partner or all players following same behavior as when playing game - chats during first 4 moves visible to all, after that only between partners, again to all after game end
- [X] When opening an old finished game (or on game end automatically) maybe show all messages from all players
- [X] In spectators mode show all messages from all players
- [X] Handle spectators chats differently to be visible only among spectators - currently their messages are visible to players and even recorded
- [X] System message for chat visibility getting changed to only between partners sometimes appears before the last message that is visible to all - should be after it
I have implemented a lot of improvements with the last commit, but still some things need a bit more work. Putting my notes to myself here with more ideas related to chat so i have them written down somewhere:
- [x] tooltip with the move SAN on the chat line
- [x] pointer cursor for text messages not just for icons
- [x] spectators lose spectator chat after refresh - how is this working for normal games?
- [x] double "game over. chat visible to all" message for player on game end
- [x] show all chat on game end for both teams
- [x] hide chat icons for spectators
- [ ] can i invent logic to hide chat icons for finished games as well? mainly i want to leave MB visible for after the game ends. Could for the time being hide them all, but add different buttons like "MB", "GG", "WPP" for when game is over
- [x] anons are allowed to chat - probably shouldnt
Regarding "spectators lose spectator chat after refresh - how is this working for normal games?", the reason is bug spectator chat messages simply not appended to game.messages array because of this line https://github.com/gbtami/pychess-variants/blob/master/server/wsr.py#L627
"can i invent logic to hide chat icons for finished games as well?"
It would be nice to have standard lichess chat buttons before/after game.

Split the remaining one into https://github.com/gbtami/pychess-variants/issues/1759