I learned what i call triangle breathing as a way to deal with anxiety and panic. Works for me.
Imagine a triangle. Up one side--Slow breath in to 4 counts, down the other side--breathe out slowly 4 counts then across the bottom of the triangle--hold for four counts. This builds up the carbon dioxide in your system to alleviate the loss due to hyperventilation. It is hard when you are scared and want to run, but with practice, you can do it, and make a deal with yourself that you will not move until the panic subsides.