Rotation Turret upside-down

Hello everyone,

I’m stuck on how to get aiming rotation of attached space ship turret, that are placed upside-down. The turret rotation is split onto two nodes: one for traversion (Y rotation) and another for elevation (X rotation). I removed everything unrelated in my playground (like targeting, firing, damaging etc.), but kept important stuff like clamping turret rotation so you might recognize that the rotation upside-down is mirrored (?) to their corresponding upside turret with equal initial rotation (looks same side at start). I would also appreciate a way to unify my traverse/elevate, because currently traverse() is using Quaternion.LookRotation, while elevate() relies on trigonometry.

I hope someone with a bit of time can help me out.

I was able to get it working, i guess not perfect solution, but acceptable, adding an additional node (or bone) inbetween traverser and elevator to rotate turret without affecting traverser-node and add factor for trigonometry to use upside-down or not.

Edit: You don’t even need the factor or extra node, instead just rotate traverser & unrotate elevator (+ upside-down rotation). Seems perfect now :slight_smile:

3 Likes