Hi everyone
I’m working on a 2d side scrolling game in which i have a ufo, i want the ufo to lean smothly towards its move direction (only right and left) relative to the ufo’s velocity in other words i want to change its rotation slowly towards the move direction as well as rotate back to 0 degrees(around the z axis) when the ufo is not moving.
(i think that you can do it with lerp for the rotation, but i’m not sure).
i tried but couldn’t do it so if someone knows how i would love to hear ,thanks!
btw, im a beginer so forgive me for the weird questions sometimes xD