|Pic unrelated, but funny.|
So I've always listened to music when writing. Heck, even right now I switched off my podcast to listen to music instead so I could churn this sucker out. For me, I can't write unless I have some sort of music playing in the background. Maybe it's an ADD thing, maybe it's an imagination boosting thing, maybe it's habit by this point; who knows. I do know several other authors who don't listen to any music when they write, and others that (like me) have to listen to music when they write, so it seems to be a mixed bag.
On the same vein of "mixed bag," what people listen to and whether or not it has to relate to what they are writing seems to vary as well. Brandon Sanderson listens to all sorts of stuff when writing his books (techno, video game music, etc.) that isn't necessarily related to what he's writing about. Jason, as mentioned above, tends to listen to whimsical stuff that relates to his writing, and it has to be related for him to successfully write.
Myself, I'm sort of a mixed bag. I do have a few "rules:" 90% of the time the song can't have singing or words, because then I get too invested in the lyrics rather than actually writing. I also try and pick soundtracks that relate to the subject matter at hand, and then pick particular tracks relevant to the scene, though that isn't necessary. For example, I'll pick a creepy song for a creepy scene, but it isn't necessary. I tend to mostly listen to video game soundtracks, as for some reason movie soundtracks draw me out of my writing.
I also avoid repeats across books. I make iTunes playlists for each book I write (and then never delete them because I find it entertaining to go back and remember what I listened to), and there is hardly ever any crossover. This is usually because if I listen to a song I used on a previous book, it triggers that Pavlovian response to write those characters and that setting, rather than the one I'm in. Music has to always draw me into writing in order for it to work for me, which essentially makes almost every song or soundtrack a one-time-use affair.
For fun, here's a list of what I listened to when writing a handful of my novels, with links. It's interesting to see how my tastes have changed, as well as how the different sounds completely changed the style of the book.
Lacrymosa - I wrote most of this book on my LDS mission, which means most of the background noise was the Mormon Tabernacle Choir, predominantly this song because it's awesome. When I got home and finally finished it, it was mostly Rhapsody of Fire and Dragonforce. This is really the only book that broke the "no lyrics" rule, which is probably why the book is awful.
Harbinger - This book is some weird fantasy western vampire angel hybrid abomination, and it didn't really have a defined soundtrack in retrospect. I did listen to this little western number from Cowboy Bebop, if only because 1. It's from the best episode of any anime, ever and 2. It's the only western song I could think off the top of my head. Whatever else I listened to has been lost to the passing of time, which is probably for the best. Oh wait, I did listen to the opening song of Fight Club a lot for some reason. Man, that movie is awesome.
Where Gods and Mortals Dance - Ah, here is where things get interesting. This was almost 100% Epica's The Score, specifically Unholy Trinity. Now, I'm honestly not the biggest fan of Epica, but this album was a purely orchestral release of their previous songs, and it worked pretty well. I also hit up a decent chunk of Final Fantasy Tactics, which also sort of fits the mood of the book (heavy political fantasy). Overall, it was mostly mellow, fantasy-sounding tracks, which makes sense given how the book pans out.
Paradise Seekers - Haibane Renmei. Lots of Haibane Renmei because, damn is that some quality music. Also the book drew (very obvious) inspiration from the show, so I guess it fits. I also listened to Within Temptation's Utopia single about twenty billion times (all three versions), again breaking my "no words" rule. For some reason that song didn't bug me. Oh, and Nightwish's The Escapist, because it has the actual phrase "Paradise Seeker" in it that made me want to use it in some book. Please don't sue, Nightwish.
The Might of the Steelgods - This one was a total mixed bag, and I honestly don't remember most of it. I think it was mostly Super Meat Boy for some weird reason. I also had a mix of Lost Odyssey in there, as well as selections from most Final Fantasy games. Oh, and Shadow of the Colossus. Lots of that.
Effulgent Corruption - This book took like seven months, so I went through a lot of music. It was about this time I discovered the Game of Thrones TV show, which was fantastic, so I listened to lots of that soundtrack (and remixes). Then I discovered Nier (which is another dark, depressing fantasy story so hey, it fit) and listened to boatloads and boatloads of that. I also hit up a little bit of the Gladiator soundtrack for a phase, though it was mostly Nier and Game of Thrones.
The Gears of Anbar - This one was supposed to be some weird steampunk fantasy hybrid, but mostly it was me listening to Within Temptation's Iron about a billion times. Which, again, broke the "no lyrics" rule but hey...that song is a lot like Gears of Anbar. About war and being tempered and...ok I have no idea what this song is actually about but it has a kicking beat. I also did loads of the Bastion soundtrack, which has a sort of western/steampunk vibe to it. Pretty good stuff.
Death's Aria - Still writing this, but it also has a rather extensive soundtrack. I revived Nier for whatever reason, probably because I love the music. In fitting with it's gothic theme I've done a lot of Bloodrayne: Betrayal (a game which I don't own because the game was awful but the soundtrack is pretty good). I've also put some Castlevania: Symphony of the Night on there since, you know, more gothicy stuff. Nightwish's newest album, Imaginarium, only has about two tracks on it I like but the orchestration-only tracks on the special edition make great writing music for this book. Which I can't link to because technically it isn't out in the US except on digital copies. Oh well. Lastly, for the tense scenes, we are Binding of Isaac all over this place, as it fits wonderfully.
Thanks for bearing with me. Hopefully you found some new music to listen to while you write. What do you listen to when you write? Do you listen to anything? Do you even like music?