question fixes

This commit is contained in:
rogs 2021-11-21 12:15:43 -03:00
parent f3ee589153
commit a6fab6acd2
9 changed files with 35 additions and 6 deletions

View File

Before

Width:  |  Height:  |  Size: 38 KiB

After

Width:  |  Height:  |  Size: 38 KiB

View File

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

BIN
assets/img/p2.jpeg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 109 KiB

View File

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 24 KiB

View File

Before

Width:  |  Height:  |  Size: 35 KiB

After

Width:  |  Height:  |  Size: 35 KiB

BIN
assets/img/p5.jpeg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

View File

@ -31,7 +31,7 @@ body {
margin-top: 5vh; margin-top: 5vh;
} }
.answer-pic { .answers-pic {
width: 100%; width: 100%;
border: 18px ridge yellow; border: 18px ridge yellow;
} }

View File

@ -2,22 +2,22 @@
"initialScore": 10000, "initialScore": 10000,
"questions": [ "questions": [
{ {
"title": "Select the sexiest male:", "title": "Who's the best (and sexiest) president ever:",
"answers": [ "answers": [
{ {
"text": "<img class='answers-pic' src='assets/img/male0.jpeg'>", "text": "<img class='answers-pic' src='assets/img/p0.jpeg'>",
"effect": 2000 "effect": 2000
}, },
{ {
"text": "<img class='answers-pic' src='assets/img/male1.jpeg'>", "text": "<img class='answers-pic' src='assets/img/p2.jpeg'>",
"effect": -9999 "effect": -9999
}, },
{ {
"text": "<img class='answers-pic' src='assets/img/male2.jpeg'>", "text": "<img class='answers-pic' src='assets/img/p3.jpeg'>",
"effect": -9999 "effect": -9999
}, },
{ {
"text": "<img class='answers-pic' src='assets/img/male3.jpeg'>", "text": "<img class='answers-pic' src='assets/img/p5.jpeg'>",
"effect": -9999 "effect": -9999
} }
] ]

View File

@ -33,6 +33,35 @@ $("#playBegin").click(function () {
}); });
var data = {}, cQuestion = {}, indexeslist = [], indexesProgress = 0, total = 100; var data = {}, cQuestion = {}, indexeslist = [], indexesProgress = 0, total = 100;
$.getJSON("data.json", function (d) { $.getJSON("data.json", function (d) {
/*
d =
{
"initialScore": 10000,
"questions": [
{
"title": "Who's the best (and sexiest) president:",
"answers": [
{
"text": "<img class='answers-pic' src='assets/img/p0.jpeg'>",
"effect": 2000
},
{
"text": "<img class='answers-pic' src='assets/img/p2.jpeg'>",
"effect": -9999
},
{
"text": "<img class='answers-pic' src='assets/img/p3.jpeg'>",
"effect": -9999
},
{
"text": "<img class='answers-pic' src='assets/img/p5.jpeg'>",
"effect": -9999
}
]
}
]
};
*/
data = d; data = d;
total = d["initialScore"]; total = d["initialScore"];
$("#counter").html("Social credit score: " + total); $("#counter").html("Social credit score: " + total);