Hoverbike dust-particle adjusting to ground level?

Hi guys,

We are working on a cinematic using UE4 as a render engine. There are no players involved, we just simply import animations files and trigger them via Matinee.

We have a hoverbike going through a desert (think Star Wars) and I have created a particle effect for the dust but I can’t find a way to have the particle effect to stay on groundlevel.
It has a farily uneven ground, so it has to be able to go up and down.

Is there a way to project it downwards so it knows what height the Landscape is?

Or do I need to add a bone, animate it in maya so it stays on ground level, and then add a socket in the engine.

Thanks in advance.

Well if you’re ok with a bit of blueprint coding you can do a “Single Line Trace”. Just get the location (or locations) you want it to be (round about), use that as starting point, subtract like 500 units on the Z axis and use that as end point.

As result (if it hit anything) you will get a hit result which (after you break it) provides you with the location of the hit which will be the ground. Put your emitter there (on event tick) and you should be fine :wink:

Great, thanks for the quick reply.

I will try tomorrow and let you know if I got it to work.

I havent been able to get this done yet. i am trying to get more formilliar with the BP system. However I don’t know how I combine this with the particle effect. Do I still have to put it in a socket?

You spawn your emitter right?

Once you do that save the reference to it and place it at the hit location of your trace. That should be fine already.

Finally got around doing something about this. I haven’t managed to make it work though. I get hits regardless of there being ground or not. It is a level blue print, I am nog sure if that is the right place to create a blue print for this system.

So worked on it some more and this is the at the moment. So the tracing goes to the origin in sted of going straight down.

The level blueprint is okish for animations. Usually you’d want to do this in the blueprint of your vehicle but that works as well. But there are two things I spotted.

  1. You trace from your bike to the point 0,0,-1. This is not relative to your first point but straight up 0,0,-1. Always the same location and certainly not what you want. You should get your slot and add to it on the Z axis -100 or something. Use “One Frame” for the “Draw Debug Type”. If it traces directly downward from your slot it’s what you want otherwise you made some mistake here.

  2. In your second picture the “Spawn Emitter” isn’t connected to the trace so it won’t trigger. Not sure if you fixed this yourself but it will obviously not do anything.

Hey erasio thanks again for helping me on such a short notice. I almost have it working and I understand what you are saying. I only do not understand what you mean with “You should get your slot and add it on the Z-axis -100”

If the “end” parameter is a point a world space and not a vector it doesnt matter what I connect to it it would always be one point in space right?

Well world space consists of vectors as well. What I meant by that it’s not relative to your start position. 0,0,-1 (which is pretty close to 0,0,0) is simply the middle point of the grid.

To get the position relative to your bike just get that position, add a vector and simply use for Z some negative number (the maximum distance you want your particle system to appear… something appropriate would be like 200-1k)

EDIT: Come to think of it subtracting a positive number works just as well^^

In ue4 vectors indicate position AND direction; position vectors are just vectors with an origin at 0,0,0.

To trace downward, you would start at [Get Actor Location], and end at [Get Actor Location] + [0,0,-500] or whatever. That way the local space directional vector -500 is combined with the world space position vector of your actor location. Every time the trace is performed, the Engine will figure out where the actor is (or the socket on the actor that controls the particle system, if it’s like a motor or exhaust pipe or something, it depends on what you choose), and then figure out where 500 units directly below that position is, and perform the trace between those two points.

Got it working! I didnt understand that I had to use the bike position and literally add a vector with -100 to make it work Thanks alot for your help!