From 96cb4d077c03ecd7699993d14a01e86c69f386c7 Mon Sep 17 00:00:00 2001 From: choelzl Date: Thu, 10 Feb 2022 10:57:32 +0100 Subject: [PATCH] WIP --- twitch/chatguessr.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/twitch/chatguessr.js b/twitch/chatguessr.js index 306021e..5f25e34 100644 --- a/twitch/chatguessr.js +++ b/twitch/chatguessr.js @@ -107,8 +107,8 @@ score:score, streak: 0, }); + guesses.round = seed.round - 1; sendData('guesses',JSON.stringify(guesses)); - } function sendData(tpe, data) { @@ -147,8 +147,7 @@ if(seed.token == undefined) return; var newseed = fetchSeed(seed.token); if(newseed.round > seed.round){ - $.setIniDbBoolean('chatguessr', 'isOpen',false) - //NEW ROUND /Score + $.setIniDbBoolean('chatguessr', 'isOpen',false) //NEW ROUND /Score var gp = newseed.player.guesses[seed.round - 1].lat+","+newseed.player.guesses[seed.round - 1].lng addGuess($.channelName,gp); }else{ @@ -160,7 +159,6 @@ } } seed = newseed; - guesses.round = seed.round - 1; }else if(action.equalsIgnoreCase('gg')){ sendData('guesses',JSON.stringify(guesses)); }else if(action.equalsIgnoreCase('fg')){