diff --git a/flask/testapp/static/javascript/beautyVote.js b/flask/testapp/static/javascript/beautyVote.js index f66ef00..a1a162c 100644 --- a/flask/testapp/static/javascript/beautyVote.js +++ b/flask/testapp/static/javascript/beautyVote.js @@ -366,8 +366,8 @@ var xhr = new XMLHttpRequest(); var result_xhr= new XMLHttpRequest(); -var round = 10; //変更 -var MAX_ROUND = 1; +var round = 0; //変更 +var MAX_ROUND = 10; var CHOICE_NUMBER = 5; var max_player = 0; // 最大のplayer数(変更不要) var current_player = 0; @@ -381,6 +381,8 @@ var D = 3; var E = 4; +var string = ["A", "B", "C", "D"]; + var CORRECT = 1; var WRONG = 0; @@ -400,7 +402,6 @@ var scene = 0; var orderTable = ""; - var language = 0; var question = new Array(MAX_ROUND); @@ -432,6 +433,51 @@ "What kind of shark is a 'Jinbei' in English?", "Which creature does not have a heart?"]; +/* +var questions = ["好きな季節は?", + "千葉県の産出額が全国1位でない農林水産物は?", + "中口先生の出身都道府県は?", + "好きなプログラミング言語は?", + "フロンティア医工学センターの設立年は?", + "最も魅力があると思う都道府県は?", + "中口先生の好きな食べ物は?", + "現在千葉大学で2番目に募集人員が多い学部は?", + "大学生活で最も楽しかった時期は?", + "中口先生の好きな芸能人は?", + "What is your favorite season?", + "Which agriculture product from Chiba isn't largest by production value?", + "What is Professor Nakaguchi's home prefecture?", + "What is your favorite programming language?", + "What is the founding year of the Frontier Medical Engineering Center?", + "Which prefecture do you find the most attractive?", + "What is Professor Nakaguchi's favorite food?", + "What is the second largest faculty in terms of student recruitment at Chiba University?", + "What was the most enjoyable period of your university life?", + "Who is Professor Nakaguchi's favorite comedian?"]; + +var choices = [["春", "夏", "秋", "冬"], + ["伊勢海老", "だいこん", "日本梨", "そらまめ"], + ["兵庫県", "大阪府", "千葉県", "鹿児島県"], + ["Python", "C/C++", "C#", "JavaScript"], + ["平成15年", "平成20年", "昭和60年", "平成7年"], + ["千葉県", "神奈川県", "埼玉県", "茨城県"], + ["たこ焼き", "ジンギスカン", "ギョーザ", "うな重"], + ["工学部", "教育学部", "法政経学部", "理学部"], + ["学部1,2年", "学部3,4年", "修士課程", "博士課程"], + ["山田ルイ53世", "スギちゃん", "浜田雅功", "椿鬼奴"], + ["Spring", "Summer", "Autumn", "Winter"], + ["Spiny lobster", "Daikon", "Japanese pear", "Broad bean"], + ["Hyogo Prefecture", "Osaka Prefecture", "Chiba Prefecture", "Kagoshima Prefecture"], + ["Python", "C/C++", "C#", "JavaScript"], + ["2003", "2008", "1985", "1995"], + ["Chiba Prefecture", "Kanagawa Prefecture", "Saitama Prefecture", "Ibaraki Prefecture"], + ["Takoyaki", "Jingisukan", "Gyoza", "Unadon"], + ["Faculty of Engineering", "Faculty of Education", "Faculty of Law and Economics", "Faculty of Science"], + ["Undergraduate 1st,2nd year", "Undergraduate 3rd,4th year", "Master's course", "Doctoral course"], + ["Yamada Rui 53rd", "Sugi-chan", "Masahiro Hamada", "Tsubaki Oniyakko"]]; + +*/ + var choices = [["がっくり", "げっそり", "むっつり", "しっとり"], ["ドナルド・トランプ", "ボリス・ジョンソン", "ウラジーミル・プーチン", "アンゲラ・メルケル"], ["喧嘩っ早い", "無理やり", "細かい", "意地悪な"], @@ -453,6 +499,8 @@ ["Elephant", "Whale", "Dinosaur", "Mega"], ["Crab", "Sea cucumber", "Octopus", "Scallop"]]; + + var realAnswer = new Array(MAX_ROUND).fill(0); var view_result = 0; \ No newline at end of file diff --git a/flask/testapp/static/javascript/resultScreen.js b/flask/testapp/static/javascript/resultScreen.js index ffdfe49..56b6cd8 100644 --- a/flask/testapp/static/javascript/resultScreen.js +++ b/flask/testapp/static/javascript/resultScreen.js @@ -48,6 +48,7 @@ fText(checkOrder(C, round) + "Pt", 400, 800, 50, "black"); fText(CheckPeople(D, round)+"人", 725, 725, 50, "black"); fText(checkOrder(D, round) + "Pt", 850, 800, 50, "black"); + fText("正解:"+string[question[round].realAnswer], 800, 900, 50, "black"); } if(scene == WAIT_SCENE){ setAlp(50); @@ -68,14 +69,18 @@ fRect(50, 50, 855, 100, "black"); - fText("美人投票ゲーム", 480, 100, 80, "white"); - setAlp(50); - setAlp(20); fRect(100, 800, 760, 300, "black"); setAlp(100); - fTextN("ルール1\nルール2\nルール3\nルール4", 480, 950, 200, 50, "white"); - + + if(language==JPN){ + fText("美人投票ゲーム", 480, 100, 80, "white"); + fTextN("ルール説明\n\n・好きな選択肢を選んでください\n・選んだ選択肢が多数派なら高得点GET!\n・制限時間は30秒\n・途中参加、途中退出は不可", 480, 950, 250, 40, "black"); + } + else{ + fText("Beauty Vote", 480, 100, 80, "white"); + fTextN("Rule Explanation\n\n・Please choose your favorite option\n・If the chosen option is the majority,\nyou get high points!\n・The time limit is 30 seconds\n・No mid-term participation or withdrawal", 480, 950, 230, 35, "black"); + } if(tapC == 1){ tapC ++; @@ -98,7 +103,7 @@ fTextN("次のゲームが始まるまで\nお待ちください...", 480, 500, 100, 50, "red"); } else{ - fText("Please Wait for Next Game...", 480, 500, 100, 50, "red"); + fText("Please Wait for Next Game...", 480, 500, 50, "red"); } } @@ -109,18 +114,22 @@ fill("silver"); fRect(50, 50, 855, 100, "black"); + setAlp(20); + fRect(100, 800, 760, 300, "black"); setAlp(100); if(language==JPN){ fText("美人投票ゲーム", 480, 100, 80, "white"); fText("参加予定者:" + max_player + "人", 480, 300, 50, "black"); fText("現在の参加者:" + current_player + "人", 480, 400, 50, "black"); fText("参加者が揃うまでお待ちください...", 480, 500, 50, "red"); + fTextN("ルール説明\n\n・好きな選択肢を選んでください\n・選んだ選択肢が多数派なら高得点GET!\n・制限時間は30秒\n・途中参加、途中退出は不可", 480, 950, 250, 40, "black"); } else{ fText("Beauty Vote", 480, 100, 80, "white"); fText("Prospective Participant : " + max_player + " players", 480, 300, 50, "black"); fText("Current Participant : " + current_player + " players", 480, 400, 50, "black"); fTextN("Please Wait until\n All Participants are Present...", 480, 500, 50, 50, "red"); + fTextN("Rule Explanation\n\n・Please choose your favorite option\n・If the chosen option is the majority,\nyou get high points!\n・The time limit is 30 seconds\n・No mid-term participation or withdrawal", 480, 950, 230, 35, "black"); } if(player.number == 0){ fRect(200, 580, 560, 200, "black"); @@ -139,11 +148,6 @@ } } } - - setAlp(20); - fRect(100, 800, 760, 300, "black"); - setAlp(100); - fTextN("ルール1\nルール2\nルール3\nルール4", 480, 950, 200, 50, "white"); } // function showResult(){