So basically, I want an object (arm of the player) to rotate according to the rotation of the joystick, can someone please suggest a code or suggest how to go about it, also the joystick returns back once you lift your finger, any way to freeze it?
NOTE - I’m also using Fenerax studios free joystick pack
link to that pack - link text
If the joystick gives you a Vector2 as it’s output, you can use
Quaternion.LookRotation(joystickVector, Vector3.up)
This will return a rotation that faces the direction of the joystick.
If your joystick is giving you two separate X and y values you can turn it into a vector:
Vector2 joystickVector= new Vector2(joystickX,joystickY);