Thanks for posting on HCM
According to your description, even though atypical presentation of occurrence it is probable that you are having gouty attacks. To confirm this you will need to get checked up by a doctor who will ask to do some lab test specifically serum uric acid and other blood tests.
Other possible causes maybe allergic reaction
(cause needs to be determined), autoimmune disorder, infection etc.
If gout is confirmed then appropriate antigout medications can be prescribed associated to pain killers.
If other cause, then treatment will depend on the actual cause.
Hope this helps