There are two important moods in writing. The first is the mood of your piece. Is it upbeat or sad and depressing? In some cases, authors try to bring in more than one mood. That works at times, but you need to be careful that it doesn’t jerk the reader around. I recommend that you analyze your story front to back and plan out the moods of it ahead of time and maybe make “mood” notes in your outline.
Mood in a story goes hand in hand with pace, so pay attention to that. If the mood is depressing, you want to slow the pace of your story somewhat to match it. If the mood is anxious, you may want the pace to be a little frenetic to match. In any case, watch the mood and make adjustments where necessary.
The other important mood in writing is your mood. My message on this is brief. Try to match your mood to what you are trying to portray through your story. It’ll help your writing immensely. So, that means if you are in a depressing mood and trying to write an upbeat, happy story, you might want to wait for the mood to pass. Likewise, if you’re on top of the world, it might not be the best time to write about sadness or depression.
In any case, the message here is to pay attention to mood. It’s important in writing.