My car's GPS does, using dead reckoning.
Trains can also use dead reckoning.
/me checks notes, I've heard that they move on inflexible things called "rails" that almost never change the location.
Also the hard part is knowing the position of the others and their trajectory, which changes in between moving towards them and is done by a third party. The normal passing distance is smaller than the width of your vehicle and you can only change your own direction every few kilometers. That means that the others trajectory towards you can only become known after you are already past your last opportunity to change your trajectory and even within your breaking distance. Good luck!
[1] Friction for cars on the road is 0.010-0.015, for trains 0.001-0.002; train speed 120 km/h * 7.5 = 900 km/h equivalent for car; that's not even a high-speed train.