Creating distant army illusion using particles?

Hey there. So, this is something I’ve been working on for awhile which I thought was pretty neat, but there are some obvious flaws I was hoping I could get some feedback on. Maybe some work arounds, or new ideas on how to go about this. Also sorry in advance, but the image uploading thing on the forum seems to be broken for me, so I had to use Imgur.

My goal was to create the illusion of an army marching along the terrain. They would be so small, combined with dust and other particles, that all you can really make out is their general figure.

I got pretty close with this prototype.

But there was a problem.

It might be hard to see in this gif (look near the center) but what happens is the particles will randomly pop below the surface. They’re still there, but are moving underground now. Increasing collision thickness of the terrain didn’t help.

The next logical step was to fiddle with all the settings. That’s how I came across “Generate mesh distance fields.” Cool, they’ll have collision even when not on camera? Sounds perfect!

And now gravity only works in a square around me. I assume this has to do with distance field limits. Is there a way to increase that?

That’s as far as I’ve gotten with this. If anyone has any ideas I’d love to hear them. If you’d like to see any of the settings I have for this particular particle system, let me know and I’d be happy to share.

Thanks!

Some notes: I thought of workarounds that might involve instancing imposter cards (one sided planes) with animated flipbook textures or even just the same sort of elongated dots I’m using for the particles right now. I could paint those onto the terrain, but they wouldn’t be moving. Alternatively maybe making a copy of the terrain and having panning dots across it would look cool too, but that was a bit too uniform. But nothing is as dynamic and chaotic as this particle system method. Maybe I should just scale the whole scene down to get around the distance field limit thing.

you could constrain the particles in the Z-axis based on the terrain heightmap (assuming you have one) via the material. with anything WPO based you just have to make sure your particle system bounds are big enough. won’t be needing any collision though.
I may be able to post a material graph for that if i have time during my lunch break.

Thinking about it some more all you have to do is to plug your landscape heightmap multiplied on the Z axis by the landscape height into the WPO slot of your particle. Just make sure the particle system’s position is the same as your terrain’s.

You’ll probably want to add half the particle size to the offset so they dont clip into the terrain, but that is pretty much it.

https://dl.dropboxusercontent.com/u/107682595/Unreal/MarchingSpheres.gif

Hey there, thanks for the reply.

I think I understand what you’re saying, but I would love to see a material graph if you have time.

Some of what you said doesn’t make sense to me quite yet but in the mean time I’ll be playing around with a test map to see if I can figure it out.

One issue is all of my terrains are by hand. I’m not sure if there’s a way to convert that to a heightmap or not.

Thanks again.

about exporting the heightmap i won’t be much help. a quick google told me that it is possible to export landscape heightmaps, but how you’ll have to edit and possibly combine them to use them for that is up to you to figure out.

642f3c7ed09fa4167b0a497460c3eb57a9c5ef6e.jpeg

As far as making the particles follow your heightmap it is pretty much the above. you will have to replace the “UVs” part with some sort of landscape UV thingie. Not using landscape, so I can’t really tell you how exactly.
Z-Height will be the max height of your terrain. Again, can’t tell you how to get that - worst case you’ll have to tweak the value till the particles align with your terrain.

Like I wrote above you will very likely want to add half your particle size to the offset as well, but that shouldn’t be a problem.

Very cool. Seems I’ve got it working for the most part, thank you so much. I can probably figure this one out on my own, but do you have any tips on the best way to line up the landscape and the particle system?