Advertisement
funkemunky

Untitled

Jul 29th, 2019
206
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.65 KB | None | 0 0
  1. List<Vector> pastLocation = data.entityPastLocations.getEstimatedLocation(data.ping, 150).stream().map(CustomLocation::toVector).collect(Collectors.toList());
  2.  
  3. float distance = (float) pastLocation.stream().mapToDouble(vec -> vec.clone().setY(0).distance(origin.toVector().clone().setY(0)) - 0.3f).min().orElse(0);
  4.  
  5. if(distance > 3.1f) {
  6. if(data.reachThreshold++ > 10) {
  7. flag(data.player, "distance=" + distance);
  8. }
  9. } else data.reachThreshold-= data.reachThreshold > 0 ? 1 : 0;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement