Endodontia is the branch of dentistry dealing with pulpa (inside layer) diseases.
There is a layer inside teeth called pulpa which is made of nerves and veins. When decaying reaches this layer it commonly induces pain. When decaying caused by microorganisms reach nerves they easily reproduce in this area. Tooth dies.