Hey all, I’m very much still learning Unreal Engine and looking to develop a smooth turning circle for my animal locomotion. I was wondering if my visual script for the character movement component is on the right track? It doesn’t feel like it’s working as smoothly as I’d like
There are two things I’m aiming to achieve:
Slow down the speed of the capsule dynamically depending on the angle of the turn.
Adjust the playback rate of the animation so that when the capsule slows during a turn, the animation speed changes dynamically. (I haven’t scripted this part yet.)
If anyone has suggestions on how I can improve it, I’d be truly grateful! Here’s what I’ve done so far inside the Character BP:
I’ve created a custom rotator called Movement Rotation Target. This allows me to rotate the character’s movement direction based on the Forward and Right Vectors. I’m using an RInterp To node to smoothly blend the capsule’s rotation toward the control rotation (the direction the controller is facing).
I used my Movement Rotation Target node to calculate the desired rotation angle. Then, I calculated the yaw difference using Delta Rotator between Get Actor Rotation and the movement rotation target, and used Break Rotator to extract the yaw value.
I applied the yaw difference to control movement speed using Map Range Clamped. I mapped it to my Max Walk Speed (840 for normal movement) and a slower Turn in Place Speed (20). The values I used were:
In Range A = 0 (start of slowdown)
In Range B = 90 (fully turning in place) — I currently only have a Turn 90 set up, but I’m looking to add a Turn 180 later.
Out Range A = 840 (Max Walk Speed)
Out Range B = 20 (Turn in Place Speed)
Finally, I used the output from Map Range Clamped to dynamically set the character’s Max Walk Speed.
As I mentioned, I’m very new to Unreal Engine, so any help or suggestions on how to improve this system would be amazing! I wish there were more tutorials out there for this type of setup.
Thanks in advance!