diff --git a/flask/testapp/static/javascript/beautyVote.js b/flask/testapp/static/javascript/beautyVote.js index 87a2bfe..322e757 100644 --- a/flask/testapp/static/javascript/beautyVote.js +++ b/flask/testapp/static/javascript/beautyVote.js @@ -196,7 +196,12 @@ scene = CAPASITY_ERROR } else{ - console.log(xhr.responseText); + var get_players_information = xhr.responseText + var get_split_players_information = get_players_information.split(" "); + sent_player = get_split_players_information[0] + round_player = get_split_players_information[1] + console.log("送った人数" + sent_player); + console.log("現在のラウンドの全プレイヤー" + round_player) } } } @@ -343,6 +348,9 @@ var max_player = 0; // 最大のplayer数(変更不要) var current_player = 0; +var sent_player = 0; // 各ラウンドで、答えを送信した人数 +var round_player = 0; // 各ラウンドでの参加人数 + var timer = 0; var TIME_LIMIT = 900; diff --git a/flask/testapp/static/javascript/resultScreen.js b/flask/testapp/static/javascript/resultScreen.js index 07df5e1..d5d028f 100644 --- a/flask/testapp/static/javascript/resultScreen.js +++ b/flask/testapp/static/javascript/resultScreen.js @@ -73,14 +73,16 @@ } if(scene == WAIT_SCENE){ setAlp(50); - fRect(200, 475, 560, 200, "#208") - sRect(200, 475, 560, 200, "black") + fRect(200, 475, 600, 200, "#208") + sRect(200, 475, 600, 200, "black") setAlp(100) if(language==JPN){ - fText("集計中...", 500, 575, 80, "white"); + fText("集計中..." , 500, 540, 50, "white"); + fText(round_player + "人中" + sent_player + "人送信済み", 500, 610, 50, "white"); } else{ - fText("Counting...", 500, 575, 80, "white"); + fText("Counting..." , 500, 540, 50, "white"); + fText(sent_player + "of" + round_player + "sent", 500, 610, 50, "white"); } } } diff --git a/flask/testapp/views.py b/flask/testapp/views.py index 20d33f7..a8e04c3 100644 --- a/flask/testapp/views.py +++ b/flask/testapp/views.py @@ -107,6 +107,7 @@ if int(request.form.get("round")) == current_round: choices.append(request.form.get("choice")) print(f"Received choice:{choices} Round:{current_round+1}") + return str(len(choices)) + " " + str(current_player) else: return "FAILED"