you can’t safely convert vector3 to quat and back.
the best you can do is quanterion.euler(…);
The issue is quanternions have 4 elements and vectors have 3 and there simply is no way to go from quan to vector without losing some data and no way to from vector 3 to quan without picking one of multiple valid answers.
http://blog.preoccupiedgames.com/quaternions-not-satan/
Notice it says there can be multiple euler representations for one rotation.
that 0, 180, 0 is the same as 180, 0 , 180.
YOu might say well just pick one, except while those two rotations are the same, adding something to them doesn’t both produce the same rotation.
So that’s the problem, quats have exactly one answer for any rotation and adding them always gets the same answer.
but 0,180,0 + 90,0,0 to 90,180,0 isn’t facing the same direction as 180,0,180 + 90,0,0 to 270,0,180
even though 0, 180,0 is 180,0,180. adding 90,0,0 to both gives different results. if your rotated this way in one you might be standing facing someone, in the other your butt is facing them and your on your head.
that’s why you can’t really convert because when your converting down from quan do you convert to 180,0,180 or 0,180,0.
Quaternions are better, they don’t suffer from gimbal lock for example is the big thing.
basically eulers have 3 angles and 3 axes.
quaternions have a single axis and rotate around it.
(as i understand it, quats are complex numbers, there great for computers, horrible for humsies)
as such your best thing to do is use quaternions.
otherwise convert to 0-90 from 0-1 and then feed into quaternions.euler I suppose.