I’m not used to use quaternions, it is the first time I’m working with them. Since there aren’t examples about using them I’ve hit a brick wall.
I’m trying to shoot a ball in the mouse direction. If the mouse is closer to the player the shot will have height, if the mouse is further away the shot is low.
Right now I have this:
I’ve no idea how I can pass a “Z angle” to my quaternion in such way that the shot will be high instead of low. Any ideas how I can achieve this behavior?