After you check with the dentist and maybe even a specialist, consider investigating if it is nerve pain. Look up Trigeminal Neuralgia. It could be the dental treatment, and your anxiety about it, triggered an underlying condition which now has the nerves aroused.
I have this problem and it doesn't affect my legs, but I do have pain in my neck. I am seeing a neurologist soon and also an arthritis specialist to see if something of that nature is the cause.
Does Advil or Tylenol relieve your pain? If not, it is possibly a nerve issue requiring a different prescription.
Moist heat will help until you find the right solution or go into remission.
Check with the dentist to see if you have a dry socket or any type of residual infection.