Unreal Engine 4: Let’s Make: Character Speed based on Slope

Let’s Make a Character Speed system

Character speed that is directly affected by the slope the character is walking on.


LET’S MAKE a movement system that takes into account the current slope under the character and sets their speed over time.

This idea came about when a student of mine wanted to explore a landscape they created in Unreal but felt like running up large mountains and hills at the same speed they moved down was strange and unrealistic. Instead they wanted to simply slow the character down as they climb a steep slope and speed them up when running down hill.

We worked out a quick solution and I wanted to share it here for others! We will make a system that:

  • Sets the character speed based on current angle of their surface
  • Uses two line traces
  • Uses float curve to control our speed
  • Blueprint only
  • Using Unreal Engine 4.8.1

Continue reading