Pain meds, time.
Gallbladder pain is almost always due to blockage of the outflow of bile
from the gallbladder due to a stone.
Usually, the obstructing stone will "fall back" into the gallbladder within an hour or so, leading to complete resolution of the pain. If the attack lasts for hours, it is advisable to go to an er to receive pain meds (which may "break" an attack) +/- admission for definitive care-surgery.