There are games where you can technically do this, though none that use it as a mechanic built into the game that I know of.
Most of the games where you can do that also have detailed maps that make it unnecessary. I did sometimes use the sky to help me navigate in FFXI when I'd get mixed up from fighting and not want to pull up the map.
A true survival game where you have a compass and the stars and have to make your way through some woods/mountains/desert could be interesting. There are games that have moments of this kind of thing, but I mean a game entirely focused on it. Maybe there's already a game like that and I don't know about it, in which case I'd love to hear about it.