how can I make an explosion make a dent in the ground?

I need to know how can I make an explosion that will leave a dent in the ground? (BGE)

In what context? What technique do you use to create the ground?

If you want to dynamically deform the actual ground then welcome to the opening of the rabbit hole!

Alternatively you could use the method I’ve seen to add craters to battlefields during tabletop games, where you can’t physically make a crater in the board.


You create an object with raised sides to look like debris blown to the sides then make a crater in that.

@mattaline1 good idea, I never thought of that, can you tell me how can you make bullet holes or craters bend on the terrain.

Mattline1’s ‘rabbit hole’ method mentioned involves basically a lot of Python code to:

  1. Get the ‘home’ vertex underneath the exploding object through a rayCast() function call (most likely),
  2. Get the vertices near that ‘home’ vertex (which can be stored in the objects beforehand in ‘strength’ variables),
  3. Move the vertices downward depending on the distance to the ‘home’ vertex (or the pre-determined ‘strength’ variable), and
  4. Update the physics mesh of the ground terrain (a simple Python function call).

EDIT: Oh, this was meant to be right after Mattline1’s post, basically. As for making the crater bend, you could set up a bones in an armature and use that to make it bend around the terrain.

What about having a displacment map that is edited by a falloff type brush based on uv mapping? Can that be applied/edited in the bge in real time easily?

You can simply make it as a different object ,which spawns there and gets hidden by explosion anyway.

Another method would be to make everything out of pieces, then have the pieces disappear, or become re scaled when struck, or just fly out away from the impact site, this would be the easy way to do this… but it will take many slices etc to look convincing.

This is a very very ruff demo of concept

Attachments

DemoBoomi.blend (667 KB)