Hello
Welcome to health care magic, I appreciate your concern.
Bloating might be related to Aerophagia (swallowing of air),
acid peptic disease, ill fitting denture, excessive use of carbonated drinks, smoking or indigestion.
Sudden onset of sever pain pointing towards few conditions like
Appendicitis,
cholecystitis or
peptic ulcer or perforation.
I would advise you to immediately go to Emergency care for an X ray abdomen standing to rule out perforation first, followed by an ultrasound and blood investigation like CBC, liver function test to rule out appendicitis.
If everything comes to be normal than you should not worry, you can take antiacidity medicine like
pantoprazole or ranitidine group of drugs with antacids or sucralfate syrup for 7-10 days.
You should avoid fatty fried spicy and junk food and carbonated beverages.
Try to allay anxiety by relaxation exercises yoga and meditation.
You should take lots of fresh fruits and vegetables and plenty of fluids to maintain good hydration.
Hope you will find my answer informative and useful, please feel free to ask for follow up question I will gladly answer you.
Best wishes