Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

How do I make an object slide along an arbitrary slope?

I am trying to figure out how to get a pawn to slide along a slope. Right now, I am using a custom movement component that is currently based on UFloatingMovementComponent, and I am using that to make a custom gravitational field that is based on the surface normal.


At high velocities the object will actually launch it self off a slope and cause the gravity to pull it back down towards the surface thus causing that weird jumping motion you are seeing In the video.

My question is how do I go about and make this pawn slide smoothly along a surface? Think of how in Skiing games, a dip in the surface won't normally send the player flying off into the abyss unless it's steep enough.

Product Version: UE 4.14
more ▼

asked Feb 19 '17 at 01:54 AM in C++ Programming

avatar image

1 1 2

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Hi, bit late but for anyone who comes around, one solution would be to use regular movement component and increase the max walk angle to something reasonably higher for example 70, and the in the tick check if the floor angle is greater than a lower threshold like 50, if so apply movement input in code in direction of impact normal. The component will then handle anything higher with that 70 with regular "Falling" state.

some quick pseudo blueprint

more ▼

answered Sep 20 '18 at 03:32 AM

avatar image

8 1 2

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question