fix: FRO-29 Websocket Communication (#104)

Reviewed-on: #104
Co-authored-by: Janis <janis.e.20@gmx.de>
Co-committed-by: Janis <janis.e.20@gmx.de>
This commit is contained in:
2025-12-10 09:42:50 +01:00
committed by Janis
parent 33efc4e107
commit fa3d21e303
7 changed files with 23 additions and 9 deletions

View File

@@ -7,6 +7,7 @@ import model.users.User
import scala.util.Try
case class TrumpInfoDTO(
gameId: String,
chooser: Option[PlayerDTO],
self: Option[PlayerDTO],
selfHand: Option[HandDTO],
@@ -20,6 +21,7 @@ object TrumpInfoDTO {
}.getOrElse(None)
TrumpInfoDTO(
gameId = lobby.id,
chooser = lobby.logic.getTrumpPlayer.map(PlayerDTO(_)),
self = selfPlayer.map(PlayerDTO(_)),
selfHand = selfPlayer.flatMap(_.currentHand()).map(HandDTO(_))