I have a cube in a level, it moves by lerping to a position. It’s grid based movement of Left, Right, Up and Down. I’m wondering if there’s a way to make the cube rotate during movement 90 degrees depending on the direction I have moved without using the local rotation of the actor? When I tried rotating left, and then up my cube spun around as the local axis had changed. Is there a simple way of accessing some sort of global axis? Such that you can use in the editor?
Also, during rotating left, after 3 turns the cube rotated the opposite way,as if I tried rotating it right which I hadn’t. I know this has to do with a pitch rotation bug and I’d love to hear any solutions.
Did you ever figure out a solution for this? I’m running into the same issue.
No I have since moved on from that project. Unfortunately the only solutions I found were along the lines of “We’re working on that” but that was around 6-8 months ago.
Dang, thats too bad. The only way I can think of doing it is through branches. If pitch = 90 or -90 rotate around roll, if yaw = 90 rotate pitch around roll, etc. But that would get really messy
There is a better way.
If you want this to be purely visual you could only rotate your mesh and not the whole actor. This would mean if you move your actor it would still be the same rotation and nothing gameplay relevant could change.
You could also try to use “Unrotate Vector” to “undo” the rotation and talk to the vector as if it’d not been rotated… or the other way around with “rotate vector”.