Working Compass?

OK, how would you make a compass? I’m wanting it so if the player goes X+ it points North, X- points South, Y- points West, and Y+ points East. Messing around with track to constraint ,but it just points at the player all the time,lol.

A simple hacky way is to parent an empty due north of the player using vertex parenting, then use the Edit Mode “track to” actuator on the compass object to track to that empty. To display this in player space, you’d need to think a little harder (easier to do via scripting).

As far as I know a compass (needle) is expected to always point to the same direction (north) regardless how you hold it.

Vertex parenting makes the child ignoring the rotation of the parent. This might help.

The more I thought about it, the more I realized that the needle does point north. I played around with my watch/compass yesterday and notice that if you walk north,east,west, and south nothing moves til you rotate. So would just rotating the compass needle with the player make for a realistic compass? Or maybe rotate the image with north,east,west,south around the needle?

The question is what you really want.

A real compass works like this:

The needle points north regardless of the hull orientation. This means you need to look from top down onto the device to see the needles orientation.

But this is a game. Typically the viewer look straight forward. Due to perspective you might be able to get an idea where the needle is pointing too. A lot of games present a top-down view of the compass at the HUD. Other games present a compass that can be used from the side [… N … E …].

The question to you is: how do you want to the compass/needle to be shown in your game?

Hey dear co-workers i have some issues with compass… here