Question for Mexican families- or Hispanics with this tradition

This weekend was my three year old's birthday. We had part of my DH's family over visiting from Laredo, TX. We did the whole thing with the candles and when I left to go grab a knife to cut the cake, someone from my husband's side of the family smashed my kid's entire face onto the cake. Completely ruining the cake for their own entertainment. I had no idea what to say or do at that point. My daughter was crying hysterically. His family laughed it off and I had to take my daughter upstairs to bathe her and calm her down. 
 The next day we bought her a cake again (to eat, like it's meant to be) with her favorite characters and she was terrified and wanted nothing to do with it! 
Is this a tradition? What is the meaning of this? I just thought it was rude. My family is Hispanic too but we never did this to each other. Just kinda ruins the mood of the celebration imo. I don't mean to just cut off their traditions but I don't see the point.