== to ===
This commit is contained in:
@@ -17,15 +17,15 @@ export function Utility_ConvertSecondToString(second: number) {
|
||||
export function Utility_CalculateScore(difficulty: string, second: number): number {
|
||||
let score = 0
|
||||
const currentTime = Math.min(120, second)
|
||||
if (difficulty == config.DIFFICULTY_TYPE.Easy) {
|
||||
if (difficulty === config.DIFFICULTY_TYPE.Easy) {
|
||||
score = 270 - currentTime
|
||||
} else if (difficulty == config.DIFFICULTY_TYPE.Medium) {
|
||||
} else if (difficulty === config.DIFFICULTY_TYPE.Medium) {
|
||||
score = 420 - currentTime * 2
|
||||
} else if (difficulty == config.DIFFICULTY_TYPE.Hard) {
|
||||
} else if (difficulty === config.DIFFICULTY_TYPE.Hard) {
|
||||
score = 760 - currentTime * 3
|
||||
} else if (difficulty == config.DIFFICULTY_TYPE.Expert) {
|
||||
} else if (difficulty === config.DIFFICULTY_TYPE.Expert) {
|
||||
score = 1120 - currentTime * 3
|
||||
} else if (difficulty == config.DIFFICULTY_TYPE.Extreme) {
|
||||
} else if (difficulty === config.DIFFICULTY_TYPE.Extreme) {
|
||||
score = 1320 - currentTime * 4
|
||||
}
|
||||
// console.log("计算积分 >>>>>", difficulty, second, score)
|
||||
|
||||
Reference in New Issue
Block a user