SetActorRotation bug (maybe)

So, Let me start this with saying… Maybe i’m just an idiot. and it’s not a bug… but I have fought with this for a little bit now and it seems to me like what I’m doing should work.

Also, I know that the math is a little messy, was just testing a bunch of stuff trying to get it to work.

Anyhow, I want the paper character to point in the direction of the left thumb stick (much like a top down shooter) I calculate the y (Pitch) and call SetActorRotation blueprint node. This works as intended for all positive x values, but when I get negative x values, while I get the right angle to set the character, the character gets flipped 180 degrees in both the x (Roll) and z (Yaw)! But I am setting them too 0.0

Anyhow, the function is called updateLocation And I have attached a screen shot of the offending code as well as you can find a project with the issue at the following link.

Notes: I don’t think this is a problem with 4.13, as it exists in 4.12.5 as well (I made a project and could easily reproduce it) So ether I’m using the engine wrong (probably, or this is a bug, or maybe both)

Let me know if this is not how I should be setting the rotation of my character. it seemed like the right way to do it… I know maybe I need to do some linear interpolation for a smooth turn radius and all… but I was just testing some stuff at this point.

Anyhow, let me know if you have any other question!

Marek

Looking into it on Twitch