toothache that comes randomly and will go away on it’s own after 5-10 minutes, or if i brush extra hard on the area.

getting the most insane toothaches on the upper left side of my mouth, so painful that it makes my left ear ring. not nearly as bad as the pain my wisdom teeth caused before i got them out, but a close 2nd. quite literally an unbearable pain, but it’ll go away on it’s own after 5-10 minutes. or if i rly can’t stand to wait it out it’ll go away within like 10-15 seconds of brushing my teeth. bc of this I’ve been brushing my teeth like 9 times a day lol. can anyone explain why this is happening? and what i could do to help it? i had an appointment today and to put it lightly, my teeth are pretty much destroyed. as a kid i slacked on taking care of them but still did enough, but when i was 18 in 2020 i developed an opiate addiction and HEAVILY disregarded my oral health and the rest of my health in general. lots of cavities and stuff, pretty sure my middle molar over on my top left side needs a root canal, and that’s what my dentist assumed was causing the pain but the pain is actually coming from the 3rd molar. it feels like it’s starting point is right where the molar and gum meets, i have a huge open space from where my wisdom teeth were and it feels like the pain is coming right from where it meets the gum line.