Advertisement
CaptainLepidus

Direction/Speed

Jan 25th, 2015
233
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.16 KB | None | 0 0
  1. Vector v = pathpoint.getLocation().toVector().subtract(vehicle.getLocation().toVector());
  2. v.multiply(1/(pathpoint.getLocation().distance(vehicle.getLocation())));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement