He won't understand. We don't talk to toddlers in the same way as we talk to adults.
How would the "conversation" go
No. Don't bang the wall. Here's your blocks. See? Let's bang the blocks. Bang Bang Bang. Can you bang the block? Can you bang? Yes! bang! No! Not the wall. If you bang the wall you'll make a hole. No! that's naughty. Give daddy the hammer. No, don't bang Daddy. Let's read a book now.....
and so on and so on, with occasional short interruptions from the toddler. The words would be supported with facial expressions, gestures, and intonation that helps the toddler understand the meaning and when you are happy or angry.
In terms of your actual sentence, the formal construction for adults would be
If you hit the wall hard, you will break it.
If you hit the wall hard, it is going to get broken.
The get passive works very well in this situation. But saying any of these to a two-year-old is going to have absolutely no effect.