How would i attempt to make footprints? (Bannerlord)

Users who are viewing this thread

https://cdn.substack.com/image/fetch/f_auto,q_auto:good,fl_progressive:steep/https://bucketeer-e05bbc84-baa3-437e-9518-adb32be77984.s3.amazonaws.com/public/images/ef752108-90d9-41df-96d1-44ce2ce8cf1c_1920x1080.jpeg
As shown in the link, id like to achieve footprints which look similar to that and have them generate under the units/characters foot as they step. How would this be done? Would i have a footprint decal be placed under each step? and if so how to do that, can you link me sites and such to help and give advice.
 
I daresay the footprints in that screenshot are not dynamic.

In any case, in order to create that effect you would need a decal to use. Since those footprints appear to be deep in the snow then I would want to have a normal map (or, if the engine supports it, a tessellation map) on the decal that would give the impression of the foot going into the the snow. I'd make the colour of that decal just the dirt colour, with the normal map overlapping the alpha part of the image - allowing the normal map to deform the snow material.

You would then need a way to spawn the decal - I assume the engine already has a function for spawning decals at a given location. So you would get the location of the character and spawn your decal underneath it every n meters as they move. Given that strides are longer when running as opposed to walking, your distance threshold is going to need to be a function of actor speed.

Then you'll need to make sure the footsteps despawn after a while as they will add up quite quickly and cause some serious slowdown because the engine will need to keep rendering them all.

Needless to say, you would need to be pretty comfortable with programming to get this working, but it's by no means a super advanced task, I would say it's a good challenge for a novice modder. Good luck!
 
Upvote 0
Thank you for the detailed response, but could there be an alternative way of spawning the decals like a way to get timeframe of a walking animation, and at a certain time the left foot steps, thats when i would spawn the decal. I guess id have to test where that left foot ends up by approximating the distance from center of character. If this isnt possible then i will do your solution, which im assuming is all about timing right, like measuring the distance the character would take to take a step and then spawn decal.
 
Upvote 0
Back
Top Bottom