Skip to content

Commit

Permalink
fix(ScoreCalculation): round bonus score up
Browse files Browse the repository at this point in the history
  • Loading branch information
My-Name-Is-Jeff committed Jan 27, 2025
1 parent 8e82b3e commit fad8f20
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ object ScoreCalculation {
"scorecalctotal"
)
if (DungeonFeatures.dungeonFloor == "E")
first.first.coerceIn(14, 70) + first.second + second.first + (second.second * 0.7).toInt()
first.first.coerceIn(14, 70) + first.second + second.first + ceil(second.second * 0.7).toInt()
else first.first.coerceIn(20, 100) + first.second + second.first + second.second
}.also { state ->
state.onSetValue { score ->
Expand Down Expand Up @@ -295,7 +295,7 @@ object ScoreCalculation {
ScoreCalculationElement.text.add("§f• §eSpeed Score:§a ${speedScore.get()}")

if (DungeonFeatures.dungeonFloor == "E") {
ScoreCalculationElement.text.add("§f• §eBonus Score:§a ${(bonusScore.get() * 0.7).toInt()}")
ScoreCalculationElement.text.add("§f• §eBonus Score:§a ${ceil(bonusScore.get() * 0.7).toInt()}")
ScoreCalculationElement.text.add("§f• §eTotal Score:§a $score" + if (isPaul.get()) " §7(§6+7§7)" else "")
} else {
ScoreCalculationElement.text.add("§f• §eBonus Score:§a ${bonusScore.get()}")
Expand Down

0 comments on commit fad8f20

Please sign in to comment.