So I want to rotate my character according the angle of the surface it is standing on.
For example, if I am standing on a flat horizontal plane and move on to a +45 degree angle plane, I want the character (including camera), to then set it’s new default rotation to +45 degrees.
Yeah line trace, something like from the center of the character to the ground, then break the hit results from out hit and you have the impact normal.
That looks as it should work.^^ Just a small comment, as it can always be seen that the “Out hit” is being taken, broken into its component and then these new outputs are actually used.
Although that is technically of course totally working, you can also just rightclick on the “OutHit” and say “break result” there, thus having one large node less in your graph.
If your Angle never goes beyond 90 degrees, you can use the CharacterMovement’s “FloorHit” variable and check the Normal.
Don’t forget to set the Walking Max Angle to >90 of course.
I have set up the image, and unfortunately it does not work.
Key things to note here for my case:
I am using the default third person character template. So when I use the “getActorLocation” node is it really doing what I need?
When I set up the graph exactly as it is in the image, my character gets smashed into the ground where the trace hits, and rotates violently on the spot and I lose almost all control of it.