I am calling this from tick. When I don’t use this function and instead use the controller yaw, the character does rotate with what it is standing on, a train in this case. However, even though I am adding a delta here, when I use this my character does not rotate with the train it is standing on.
Try to add a trigger then add a branch and check for a variable which is set per the trigger, and enables the RotateYaw. To add a trigger place a Trigger Volume, right click the trigger volume and pick “Add Event”, “On Begin Overlap”. Now click your character, then go back to the Level Blueprint and right click and pick Add actor reference. Now click that new character reference and drop a node, then type into the search “set YourVariableName” (bool). Inside your character you need a bool with a branch on Tick (i.e. RotateNow). If the character enters the trigger volume the bool is enabled, and he should rotate.
I’m not hacking something together with trigger volumes and I am definitely not putting code for character movement systems into a level blueprint. My animations will not work correctly if I was using the controller rotation.
I need to know what is causing rotation to not be inherited from what the character is standing on. It doesn’t make sense because I am adding a rotation, not setting the rotation.
Don’t know if this will do anything to solve YOUR particular problem or not, but I find I can never seem to manipulate rotation with using any of the Actor rotation functions, but always have to resort to using Set Control Rotation to whatever rotation values I need them to be. See if you can give that a try. Once you do your calculations and know what your actual XYZ rotational values should be, plug those into the SetControlRotation. Also, I see you don’t have anything set for your current on your RInterp To. Grab your current control rotation to put in there. This is something I use in one of my blueprints, so I’m pasting it here in case it might give you a hand:
Also, (In case you didn’t know–I didn’t for a while) instead of using the “make” and “Break” rotators, you can simply right click on the rotators and “Split Struct Pin” to save some space and make things a little cleaner.
Curiously, the option to split struct pin is grayed out for me. As to not having an input for the current pin, this is the intended functioning.
Without calling my custom function at all, I still get no inheritance of rotation without UseControllerRotationYaw checked. This tells me that my function is not the problem, rather there is some sort of problem with UE4 that rotation stops being carried over from the object the pawn is standing on when it is unchecked.