Hypocalcemia is a condition characterized by decreased serum calcium. It caused by parathyroid disorder called hypoparathyroidism, Vitamin D deficiency and renal failure.
Vitamin D deficiency has no direct effect but it is responsible for d absorption of calcium from gastrointestinal tract. So deficiency of vitamin D will cause hypocalcemia because no calcium absorption.
Muscle spasm because it is important during muscle contractions.
Cardiac arrest calcium help during pumping of blood to the system.