Change Walk Speed?

Hi everyone,

I am so newly in UE4

i want to change character movement speed when press a key and release and key like below picture.
How can i do that?

29956-walkspeed.png

In your character blueprint, in the event graph, click Show Inherited Variables in the list of variables so you can see the base character class variables, then search for Character Movement.

Get that into your graph and drag off the output.

The Character Movement component holds all of the variables related to character movement that you see under the “character movement” section in the Defaults tab.

Hi there, I know this is a old thread but I just decided to post something visual for those who are a bit lost with the earlier answer (which is not wrong). You have to get your Character Class and from that get the Character Movement (as you can see in the blue nodes). In this BP although you cant see it its a Controller BP, so I had to first cast to My Character. In my case i have a few extra things. These being:

  1. The cast from MyPlayerController to MyCharacter, then promoting MyCharacter reference to variable(could have done the same with Character Movement (like i did with camera, which i used for something else). If you’re doing the events right in your character you just have to go top left where you see your components, look for Character Movement and drag it into the grid with the control key held down(for a “get” node).

  1. From Character Movement added a node that returns a Boolean value saying if I’m touching the ground, so I can’t sprint in air.

  2. After that I just used two “Set Max Walk Speed” nodes with two float variables I made (edit anywhere) so I can modify on the fly.

  3. The “Input Action Sprint” event is basically the same as your V key press event, just that I defined the event in the Input section of the project settings tab. Just that I can now change the key that will make that function without having to go to every single place i set “X” key for that event.

Hope this helps anybody in the future!

1 Like