Browse Source

timescore calculation error

pull/10/head
Tim Glasgow 2 years ago
parent
commit
a25e070b28
  1. 5
      squarenotsquare/src/libs/CalculateScore.js

5
squarenotsquare/src/libs/CalculateScore.js

@ -1,5 +1,10 @@
export function calculateSquareScore (answers, finalTime) {
let timeScore = Math.round((60 - finalTime) * 1000);
if (timeScore < 0) {
timeScore = 0;
}
let answerScore = answers * 1000;
let finalScore = timeScore + answerScore;
return finalScore;

Loading…
Cancel
Save