mirror of
https://github.com/NoCheatPlus/NoCheatPlus.git
synced 2024-12-26 10:28:05 +01:00
MAXIMALLY.
This commit is contained in:
parent
562f1da59b
commit
a8f326d855
@ -115,7 +115,7 @@ public class FightListener extends CheckListener {
|
||||
// TODO: Maybe use 3d distance if dy(normalized) is too big.
|
||||
targetMove = CheckUtils.distance(data.lastAttackedX, data.lastAttackedZ, targetLoc.getX(), targetLoc.getZ());
|
||||
msAge = (long) (50f * TickTask.getLag(50L * tickAge) * (float) tickAge);
|
||||
normalizedMove = msAge == 0 ? targetMove : targetMove * Math.max(20.0, 1000.0 / (double) msAge);
|
||||
normalizedMove = msAge == 0 ? targetMove : targetMove * Math.min(20.0, 1000.0 / (double) msAge);
|
||||
}
|
||||
// TODO: calculate factor for dists: ticks * 50 * lag
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user