feat(ui): Websocket

Started implementing functionality to Websocket.
This commit is contained in:
LQ63
2025-11-26 01:35:46 +01:00
committed by Janis
parent 2aee79bb68
commit e0f16a224d
14 changed files with 258 additions and 8 deletions

View File

@@ -5,6 +5,19 @@ function handlePlayCard(card, dog) {
function handleSkipDogLife(button) {
// TODO needs implementation
}
function startGame(gameId, userId, username, userpasswordhash, userinternalid) {
const userpayload = {
internalId: userinternalid,
id: userId,
name: username,
passwordHash: userpasswordhash
}
const payload = {
gameId: gameId,
user: userpayload
};
sendEvent("Start Game", payload)
}
function handleKickPlayer(playerId) {
// TODO needs implementation
}