This usually happens to me when the moods are extreme, but I have a feeling we've all been there.
On the other hand, sometimes emotions take us to strange places as writers, even inspiring us. I had the dubious pleasure recently of being so upset, so absolutely throw-down-and-kick-some-ass angry, that if anyone was around me at the time, I'm sure they would have spontaneous exploded, or would have gotten this kind of response:
But in the middle of my rage, a line came to me out of the blue, and I'm sure if I hadn't been in such a terrible mood, I'd never have thought of it. And no, I'm not going to share it with you...I'm not that generous. But I'm saving it for when I get a chance to use it in some future work of mine.
Has this ever happened to you? Do you write better when you feel the same as the scene you're writing? Or can you turn it off and write whatever you need to, no matter what? Tell me!