I managed to make a drag and drop jump for my character but it only works in 180 degrees from the axis of the world, but i cant find a way to make that angle rotate with the camera movement so my character can jump in the direction of the camera and not always in the direction of the axis of the world. I tried finding the angle between the camera and the character using an Arctan2, but it still wont work and the character is still stuck jumping in front of him.
here is the code