There are many popular ways to cool down smoke before you inhale, as well as many unconventional and increasingly inventive ways. Let's go over some basics.
By forcing smoke to travel down through water, percolators are a very basic way of cooling hot smoke by dispersing heat in liquid. There are many styles of percolators, from showerheads to inline, which utilize slits to further split the smoke, forcing more smoke to diffuse though the water and filter. Perculators are beautiful and diverse in the many ways they can diffuse smoke. Many people find percolators to be the best way to filter your smoke, allowing for cleaner hits off your water pipe.
Traveling down a spiraling path, the hot smoke cools down. Many times, a coil will be filled in an easy to cool and retain cold fluid which can often be frozen by leaving it in your fridge or refrigerator. These coils are typically filled with glycerin, which retains the chill longer than ice would. As the air travels down it's spiral path, the cool liquid around it rapidly cools down the air, allowing for a smooth hit.
A few slits are carefully positioned around the glass shape in which smoke travels through. When inhaled, air travels from the outside to the inside of the piece where it spirals in a helix or tornado shape, cooling the smoke down in the process. Not only that, but it looks damn cool. These chamber that creates the tornado shape is called a "Venturi Chamber".