How damageble objects can be work

I'm trying to build a damageble object when I fire with gun. I dig in tu lua, tutorials and so on but I'm totaly lost.

I know there is a way. I found out damageble objects in core API doc. but I couldn't figure it out. Can any budy will help for that ?