Period Pains

Does anyone else find that if you don’t exercise/eat good your period pains are deathly?

When I was in college I exercised 4/5 days a week and ate good and my period pains were tolerable. Since coming home, i haven’t gone to the gym (literally maybe 8 times) in the past 3 months and my diet hasn’t been great. The other day in work I got sent home cos my cramps were so bad, I mean gagging from pain, not being able to stand up or walk. Anyone else experience this??