How can I specify the direction in which Lerp rotates my actor?

I need to rotate an actor so I decided to use the Lerp (Rotator) node (Alpha driven by a timeline) however I am running into problems with the actor rotating only between plus/minus 90 degrees and zero.

The actor is essentially a cube and the rotation is supposed to correlate to it rolling however it rotates in the wrong direction half the time.

I’m assuming this has something to do with how UE handles rotators. I need it to rotate in a specific direction, this is how I set it up. If anyone has any insights or workarounds it would be appreciated.

you’re going to run into gimbal lock issues if you’re using rotators and trying to set pitch above 90 or below -90. is that where you run into issues?

It seems like it, the blueprint I posted makes the cube go 0 to 90 to -0 (I know there’s no such thing as negative zero) then back to 90 and so on. Going in the other direction, it goes through 0, -90,and back to zero.

Those angles are according to a tick log of the pitch and they don’t even seem to match up with what it looks like it’s doing.

Ideally, it would go 0, 90, 180, 270, then back to zero and I’ve tried putting in the “Clamp Axis” function but no luck with that. I’ve never dealt with this specific problem so I’m not 100% on how to approach it.

Yeah, unfortunately, you’re not going to be able to use rotators when turning full 360 in every direction, for the most part. Have you tried using the CombineRotators function? That might get you what you need…but really Unreal should be exposing quaternion functions in blueprints so full rotations are possible. I don’t know why that’s not done…

Thanks for letting me know about CombineRotators, i’ll keep it in mind.

I think for what I need letting animations handle the rotations would work better in the long run, I can already see several problems coming up if i keep using rotators.