Hi,
I’m lerping an actor from one “current” rotation to another “target” rotation.
The basic setup is working fine, but I’ve been struggling for days with how to ‘ignore’ one local rotation plane in the target rotation.
Like sticking a magnet to a fridge door:
- the magnet has a random “current” rotation,
- the fridge door has a “target” rotation
- we don’t care which part of the magnet is pointing up or down, just that the ‘planes’ of the magnet and the fridge are alligned
- the magnet should rotate along the shortest rotation
The question is: if my inputs are the source and the target rotation, how to calculate an ‘adjusted target rotation’ that I can lerp to?
Hope I wrote the question down in a way that is understandable…