I am trying to have an actor (ship) have a different rotation for its position X. Ship moves side to side on X axis.
Ive tried to make 6 rules in ship. If ship is in a certain x range, then change its rotation. So if ship X position is between 120-128 then change its rotation to 317. 6 different zones give six different rotation positions. This is not consistent or works well if ship is moving quickly.
I tried graphing the position against rotation. Its an odd curve as we are dealing with 360 degrees. Not a linear relationship to use simple algebra.
Lastly I used actors. If ship collides with different actors it will change its rotation. These are placed along the x axis. This works but not a smooth tight mechanic.
I am hoping this picture will clarify what I am trying to do.
Any thoughts?
Thank-you