From 0c7af7dc5eefc1bdfa700b0610ec0c8de2e41925 Mon Sep 17 00:00:00 2001 From: Pablo Herrera Date: Mon, 16 Sep 2024 22:48:03 +0200 Subject: [PATCH] Fix missing changes of default score (#1400) Signed-off-by: Pablo Herrera --- core/src/main/java/tc/oc/pgm/rotation/pools/VotingPool.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/src/main/java/tc/oc/pgm/rotation/pools/VotingPool.java b/core/src/main/java/tc/oc/pgm/rotation/pools/VotingPool.java index cc453dadb9..b0dc0af2fd 100644 --- a/core/src/main/java/tc/oc/pgm/rotation/pools/VotingPool.java +++ b/core/src/main/java/tc/oc/pgm/rotation/pools/VotingPool.java @@ -70,9 +70,9 @@ public double getMapScore(MapInfo map) { private void tickScores(Match match) { // If the current map isn't from this pool, ignore ticking if (!mapScores.containsKey(match.getMap())) return; - mapScores.replaceAll((mapScores, value) -> value > DEFAULT_SCORE - ? Math.max(value - constants.scoreDecay(), DEFAULT_SCORE) - : Math.min(value + constants.scoreRise(), DEFAULT_SCORE)); + mapScores.replaceAll((mapScores, value) -> value > constants.defaultScore() + ? Math.max(value - constants.scoreDecay(), constants.defaultScore()) + : Math.min(value + constants.scoreRise(), constants.defaultScore())); mapScores.put( match.getMap(), constants.scoreAfterPlay().applyAsDouble(new Context(match.getDuration()))); }