So, I have found that texting nonstop can be addictive. I have had that experience myself.
If you find yourself in a position that you don’t want to be in, ask yourself how you got there. Then, backtrack and figure out how to reverse the steps that you took and correct the habit. Find a new hobby to do; you could read a book or binge watch your favorite series.