# Realtime deformation of surface on bullet/projectile hit?

**URL:** <https://forums.unrealengine.com/t/realtime-deformation-of-surface-on-bullet-projectile-hit/254064>\
**Category:** Community & Industry Discussion\
**Tags:** unreal-engine\
**Created:** [October 4, 2021, 3:20pm UTC](https://forums.unrealengine.com/t/realtime-deformation-of-surface-on-bullet-projectile-hit/254064 "2021-10-04T15:20:51Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Defonten](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Defonten](https://forums.unrealengine.com/u/Defonten)\
**Post date:** [October 4, 2021, 3:20pm UTC](https://forums.unrealengine.com/t/realtime-deformation-of-surface-on-bullet-projectile-hit/254064/1 "2021-10-04T15:20:51Z")

</div>

Hi guys,

is it possible to do the effect of a metal deforming upon bullet/projectile hit? Say I shoot to a metal armor wall and it’s being deformed (dented) in that particular place. Thanks a lot in advance!

---

<div class="post-metadata">

**Author:** ![and-rad](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@and-rad](https://forums.unrealengine.com/u/and-rad)\
**Post date:** [October 4, 2021, 4:41pm UTC](https://forums.unrealengine.com/t/realtime-deformation-of-surface-on-bullet-projectile-hit/254064/2 "2021-10-04T16:41:33Z")

</div>

Yes, and there’s a bunch of ways to do it. The easiest one both in terms of setup and performance is probably using decals.

1. Create a decal material that contains at least a normal map with the deformation. You can also use POM nodes and other textures to make it look more interesting. This is the most difficult part if you’re not artistically inclined, but the marketplace is your friend here.
2. When bullet hits wall, get the hit result and from there the impact point and the impact normal.
3. Spawn a decal at the impact point with the spawn transform oriented so that the decals is projected to the wall.
4. Apply the decal material and resize the decal if necessary.
5. Pro tip: you can randomize the decal size and rotation in order to create more variation when a lot of bullets hit the wall close to each other.

---

<div class="post-metadata">

**Author:** ![MostHost\_LA](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/mosthost_la/32/907035_2.png) [@MostHost\_LA](https://forums.unrealengine.com/u/MostHost_LA)\
**Post date:** [October 4, 2021, 9:15pm UTC](https://forums.unrealengine.com/t/realtime-deformation-of-surface-on-bullet-projectile-hit/254064/3 "2021-10-04T21:15:09Z")

</div>

You are better off setting up and implementing either a voxel system or a procedural mesh system.

> **[Mesh Generation and Editing at Runtime in UE4.26 — gradientspace](http://www.gradientspace.com/tutorials/2020/10/23/runtime-mesh-generation-in-ue426)**
>
> In my last tutorial , I showed you how to use the new experimental GeometryProcessing plugin in UE4.26 to do useful meshy things like mesh generation, remeshing, simplification, and Mesh Booleans (zomg!). When people first learn that we are...

That’s a write up on a simple base.

Unless all you need can be done by spawning in a decal. In which case, that’s probably easier (though could kill performance too).

---

<div class="post-metadata">

**Author:** ![Defonten](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Defonten](https://forums.unrealengine.com/u/Defonten)\
**Post date:** [October 5, 2021, 7:57am UTC](https://forums.unrealengine.com/t/realtime-deformation-of-surface-on-bullet-projectile-hit/254064/4 "2021-10-05T07:57:00Z")

</div>

Hey thanks a lot for the breakdown, but unfortunately the decals are not the solution for me cos I really need to deform on a geometry level. Thanks anyway!

---

<div class="post-metadata">

**Author:** ![Defonten](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Defonten](https://forums.unrealengine.com/u/Defonten)\
**Post date:** [October 5, 2021, 7:57am UTC](https://forums.unrealengine.com/t/realtime-deformation-of-surface-on-bullet-projectile-hit/254064/5 "2021-10-05T07:57:42Z")

</div>

Yes voxel system solution looks interesting indeed! Thanks a lot man!
