What causes the total body muscle spasms during panic attack?

Panic & muscles. Fear leads to release of adrenaline which causes the fight-flight reaction where the body starts preparing for strenuous physical activity, which results in blood sugar being drawn away from the brain & into the major muscles, hence the spasms.
System overload. The exact causes of panic attacks are still poorly understood, but what happens during one has been been thoroughly studied. Your body is reacting as if you are in a crisis situation, with all the fight-or-flight responses built into our body for survivial in full functional mode. At times, the result is a stand-off, with neither flight nor fight possible, resulting in "freezing up.".
Adrenaline. A panic attack involves the release of adrenaline, causing your heart to beat faster, your muscles to tighten, and your senses to sharpen. This puts you into fight or flight mode. Of course, what makes panic attacks abnormal is that it occurs at any time and can be debilitating. The muscle spasms can be a result of the adrenaline release during the panic attack.