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"

orient character mesh to surface

Since nobody has answered my previous question about faking wheel simulation, let's try this alternative. Is there a way to orient a bone/mesh in a character pawn to the current surface angle? So far I've not found any nodes in blueprint that can do this effectively. And all the vehicles I've tried to make outside of the 4 wheeled vehicle bp just remain stiff and phase through surfaces, as well as not responding to any collision properties I assign to the mesh (other than the capsule component, and physics assets just cause the whole pawn to fall through the ground). I'm sure I'm likely overlooking something, but any insight or alternatives would be most appreciated

Product Version: Not Selected
more ▼

asked Mar 02 '15 at 06:49 PM in Blueprint Scripting

avatar image

271 14 17 134

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

2 answers: sort voted first

Hi, I answered a similar question earlier, see my answer in that post, it covers both C++ and Blueprint implementation. Hope this helps :)


more ▼

answered Mar 02 '15 at 07:15 PM

avatar image

2.1k 70 38 259

avatar image Daverex Mar 02 '15 at 07:33 PM

Thanks, I'll try that tonight. I was reluctant to use the line trace method at first because I'm not sure how "cheap" it is...

avatar image MickD777 Mar 02 '15 at 07:57 PM

Line tracing is really cheap :) Even more so if you line trace only on 1 component, or if you line trace every X frame instead of every frame.

avatar image Daverex Mar 03 '15 at 02:25 AM

So I tried exactly what you had specified there, but for some reason my mesh (a big bulky tank) will come within raycast range and then begin flipping between the + and - side of the collision for each raycast. Resulting in the tank turning sideways, and the world being inverted repeatedly until I quit.

avatar image MickD777 Mar 03 '15 at 03:50 AM

OK, weird. It should definetly not be moving to the other side of your floor, have you tried not moving the tank and just orienting it as a test?

Also, like I recommended in my other post, have you tried doing it with a simple cube mesh to try and narrow done the issue?

The only thing I can think of is that your tank may be imported differently, making it's transform different or somehting...

avatar image Daverex Mar 03 '15 at 04:10 AM

I'll continue to test it and possibly find an alternative if possible, I'll update you if nothing or something works

avatar image Daverex Mar 03 '15 at 04:26 AM

In fact, it usually sends me to 0,0,0 even when impact point is the "new location"

avatar image Daverex Mar 03 '15 at 05:57 AM

It's the "Normal" on flat BSP surfaces there are no hickups when on a flat untextured surface. And it does align to inclines, however once I am on an incline the camera flipping begins. So apparently we need another way to do this...

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

Fixed it, thank you Michael, you were very close. Take a look at the Random Foliage BP from the "Blueprint Examples" map that was released quite a long time ago. It has a section inside where it does a raycast by channel and uses a make rot from ZX rather than by axis, this is important because Z must always be facing up, where the Make Rot by axis doesn't necessarily care. That may be why testing it with a cube gave you better results. This version of the BP, below, works exactly how I wanted it to. Again, thank you for pointing me in the correct direction. alt text

more ▼

answered Mar 03 '15 at 06:54 AM

avatar image

271 14 17 134

avatar image Kosrona Jul 20 '15 at 12:15 PM

i have do exact this but isnt effect any? Need i chance any stuff ? or do more as that

Its beginner stuff i think and no Tutorial on this can u Add this? to your lernpath on Youtube?)

(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