Maintain Holo angles relative to the E2's position
Hi all, I have made a holo turret that splits the Pitch and Yaw between two holos, the gun and the base.
The base rotates on Yaw axis, while the Gun rotates on the Pitch axis. The gun holo is parented to the base holo and shares the bases "yaw" axis.
This gives the effect of a two piece holo turret that tracks targets very well.
What my issue here is it all works great untill I rotate the E2 chip, then the yaw and pitch angles get either reversed or switched depending on the E2's world orientation.
Does any1 know how i would make the turret so that it maintains the same up down left right (yaw and pitch) rotations no matter what angle the E2 chip is at, as this is going on a ship and obviously the ship will not remain level all the time! My code implements quaternions and I have pulled the pitch and yaw from that code to divide between the two holos.
Any assistance would be greatly appreciated. Thanks
Re: Maintain Holo angles relative to the E2's position
Hi thanks for the reply, I use toWorld(vec and(ang which is how it got it to work with the e2 chip level, its just when the chip it angled it goes awry, any suggestions?
Bookmarks