Motor6D not taking the shortest path to desired angle

Hi !
I’m working on a game with tanks, and i’m trying to make the movement of my tank smoother with motor6d instead of manually change the rotation of the turret that cause lag

I’ve ran into a problem that my motor6d is not taking the shortest path to desired angle when it goes from 180 to -180

I’ve tried multiple solutions but in vain

Here a video :
https://www.youtube.com/watch?v=oeClpQI5uyM

1 Like

have you tried AlignOrientation?

1 Like

The problem is It is not responsive enough

1 Like

you can set their Responsiveness to the max (200)
then adjust MaxTorque and MaxAngularVelocity if needed

heres an example that can work closely to your old way:
MaxAngularVelocity = 6
MaxTorque = inf (a huge number is fine)
Responsiveness = 200

1 Like

But how do i stick the turret to the body of the tank ? i’ve tried with alignposition but the responsiveness is awful

1 Like

you can use a BallSocketConstraint to connect the turret and the body

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.