This commit is contained in:
Jesse Boyd
2019-07-18 04:24:21 +10:00
parent 905fbf5a0b
commit ff94a1e5ed
26 changed files with 326 additions and 381 deletions

View File

@ -41,7 +41,8 @@ public class FaweTimer implements Runnable {
if (tick < lastGetTPSTick + tickInterval) {
return lastGetTPSValue;
}
double total = Arrays.stream(history).sum();
double total = 0;
for (double v : history) total += v;
lastGetTPSValue = total / history.length;
lastGetTPSTick = tick;
return lastGetTPSValue;