]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/race.qc
Merge branch 'master' of ssh://gitlab.com/xonotic/xonotic-data.pk3dir into kickban...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / race.qc
index 8cc7d322c4e3a3fedb09346a9f9fe559fb67d137..1c12058d0d9019ee4bb0ae36366a4db58c588c96 100644 (file)
@@ -1178,7 +1178,7 @@ float race_GetFractionalLapCount(entity e)
        // race_timed_checkpoint == 0: then nextcp==0 means 0.9999x
        float c, nc;
        nc = race_highest_checkpoint + 1;
-       c = (mod(nextcpindex - race_timed_checkpoint + nc + nc - 1, nc) + 1) - bestfraction;
+       c = ((nextcpindex - race_timed_checkpoint + nc + nc - 1) % nc) + 1 - bestfraction;
 
        return l + c / nc;
 }