From 253f53d158512ed1e49ea32e4eda584b3aefa974 Mon Sep 17 00:00:00 2001 From: Tomas Veras Date: Sun, 24 Feb 2019 16:58:45 -0400 Subject: [PATCH] feat: add language to game object. --- src/game.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/game.js b/src/game.js index db18cd1..f1f1ef8 100644 --- a/src/game.js +++ b/src/game.js @@ -33,7 +33,8 @@ function newGame() { gameCandidate = { deck: {}, weight: 100, - players: 0 + players: 0, + language: '', }; } @@ -129,6 +130,7 @@ function getGame(players, language, chosenCards, gameMode) { } gameCandidate.deck = languages.translateDeck(gameCandidate.deck, language); gameCandidate.screenplay = screenplayFromGame(gameCandidate.deck, chosenCards); + gameCandidate.language = language; return gameCandidate; }