Everytime I masturbate I have pain in my testicles I

Patient: Everytime I masturbate I have pain in my testicles. I use to masturbate 2 times per week but now I do like 1 time in 10 days so I masturbated yesterday it caused pain in the testicles for 2 hours buy then it stopped noe after 24 hours ut started again mostly I have pain in my left testicle. So is the masturbating cause this pain kr I have something else?

Doctor: