I allow myself to try new things some of which may be dumb, others of which may be inspired. Inspiration comes from perspiration. That rarely happens. Instead, you have to fool yourself into inspiration. If you're writing a large piece, such as a book or script, then sit yourself down at the same desk or table at the same time each day.
Some people are morning people.
Others are night people. Write during your best time of the day. Sure the writing at first may suck, and you hate your words, but write anyway. Some people most people have to write junk before the good stuff comes. It's cleaning out the carbon.