As a writer, you need a ritual. I’d recommend staying away from anything poor-hygiene related, and most states tend to frown on animal sacrifice, but whatever oddball habit you need to cultivate to get your mind right, latch onto it, and repeat it over and over and over again.
When it comes to your writing routine, you need to be as superstitious as a major league baseball player on a hitting streak. Think back to a time when you went on a particularly productive writing binge. Your fingers flew across the keys, your characters were equal parts witty, insightful, and funny, and the voice of self-doubt that so often whispers in our ear was silent for a change.
It was a good day. Now go and recreate that experience.