Explorar el Código

Improving scoring logic

Kirk Trombley hace 5 años
padre
commit
c6d4724351
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      server/lib.py

+ 1 - 1
server/lib.py

@@ -56,4 +56,4 @@ def score(target, guess):
         return 0, dist_km
 
     # TODO probably still needs tweaking
-    return int(perfect_score * (1 - (dist_km / max_dist_km) ** 2)), dist_km
+    return int(perfect_score * (1 - ((dist_km - min_dist_km) / max_dist_km) ** 0.5)), dist_km