# How to measure impulse in ammo

**URL:** <https://forum.babylonjs.com/t/how-to-measure-impulse-in-ammo/33897>\
**Category:** Questions\
**Tags:** physics\
**Created:** [September 13, 2022, 11:19am UTC](https://forum.babylonjs.com/t/how-to-measure-impulse-in-ammo/33897 "2022-09-13T11:19:23Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![TheScientist](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/thescientist/32/17996_2.png) [@TheScientist](https://forum.babylonjs.com/u/TheScientist)\
**Post date:** [September 13, 2022, 11:19am UTC](https://forum.babylonjs.com/t/how-to-measure-impulse-in-ammo/33897/1 "2022-09-13T11:19:23Z")

</div>

Hi humans…

I currently have an obstacle in my quest to code completion(or game dev). so I need the earthers’ help with the the project.  
As the title says, I want to measure impulse when objects collide, if possible inside the registerOnPhysicsCollide function. ALSO… Is possible to enable a single mesh to have collision with a physics body in a single code line, calling it to every single physics impostor is a bit… weird.

> **[Babylon.js Playground](https://playground.babylonjs.com/#1NASOD)**
>
> Babylon.js playground is a live editor for Babylon.js WebGL 3D scenes

---

<div class="post-metadata">

**Author:** ![RaananW](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/raananw/32/28955_2.png) [@RaananW](https://forum.babylonjs.com/u/RaananW)\
**Post date:** [September 13, 2022, 12:00pm UTC](https://forum.babylonjs.com/t/how-to-measure-impulse-in-ammo/33897/2 "2022-09-13T12:00:57Z")

</div>

For ammo - CC @Cedric

---

<div class="post-metadata">

**Author:** ![Cedric](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/cedric/32/2742_2.png) [@Cedric](https://forum.babylonjs.com/u/Cedric)\
**Post date:** [September 13, 2022, 12:18pm UTC](https://forum.babylonjs.com/t/how-to-measure-impulse-in-ammo/33897/3 "2022-09-13T12:18:34Z")

</div>

No, there is no API for now to register contact callback between to impostors.  
By impulse, do you mean penetration?

---

<div class="post-metadata">

**Author:** ![TheScientist](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/thescientist/32/17996_2.png) [@TheScientist](https://forum.babylonjs.com/u/TheScientist)\
**Post date:** [September 15, 2022, 2:41pm UTC](https://forum.babylonjs.com/t/how-to-measure-impulse-in-ammo/33897/4 "2022-09-15T14:41:20Z")

</div>

I meant the impact unit of collision. e.g force x time, the rebound or change in momentum when a sphere hits an object,

---

<div class="post-metadata">

**Author:** ![Cedric](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/cedric/32/2742_2.png) [@Cedric](https://forum.babylonjs.com/u/Cedric)\
**Post date:** [September 15, 2022, 4:20pm UTC](https://forum.babylonjs.com/t/how-to-measure-impulse-in-ammo/33897/5 "2022-09-15T16:20:57Z")

</div>

Some more infos added to the collision callback:  
PR [distance and normal in collision callback for ammojs by CedricGuillemet · Pull Request #12986 · BabylonJS/Babylon.js · GitHub](https://github.com/BabylonJS/Babylon.js/pull/12986)

---

<div class="post-metadata">

**Author:** ![carolhmj](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/carolhmj/32/25918_2.png) [@carolhmj](https://forum.babylonjs.com/u/carolhmj)\
**Post date:** [October 14, 2022, 12:08pm UTC](https://forum.babylonjs.com/t/how-to-measure-impulse-in-ammo/33897/6 "2022-10-14T12:08:36Z")

</div>

Hello @TheScientist just checking in if Cedric’s PR solved your issues?

---

<div class="post-metadata">

**Author:** ![TheScientist](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/thescientist/32/17996_2.png) [@TheScientist](https://forum.babylonjs.com/u/TheScientist)\
**Post date:** [December 21, 2022, 9:13pm UTC](https://forum.babylonjs.com/t/how-to-measure-impulse-in-ammo/33897/7 "2022-12-21T21:13:47Z")

</div>

No, but I havent asked again. maybe ill ask later
