"Let me pass on to you the one thing I've learned about this place. No one here is exactly what he appears. Not Mollari, not Delenn, not Sinclair... and not me." - G'Kar, "Babylon 5"
There are a great many lessons a DM can learn from "Babylon 5". It also has quite a few lessons not to learn - while it may seem like a really cool idea to seed something in session 2 of your campaign, only for it to pay off five years later... and while it in fact is extremely cool when you pull that off... what you don't realise until you've done it is that doing so requires a huge amount of work, no small amount of railroading, and quite possibly leaves you with a campaign that's limping badly towards the end. By the end of "Rivers of Time", I don't think anyone was really enjoying it, but we had a story to tell, so...
(For "The Eberron Code", I adopted a far more Buffy-esque structure, where each year had was something of a mini-campaign in itself, with a beginning, middle, and end. The three together fit together to form a single whole, but it very definitely was "Volume One", "Volume Two", and "Volume Three". That seemed to be a much better structure, and a much more satisfying campaign as a result.)
Anyway, I digress.
For all that they claim to be a storytelling medium, and for all that they are role-playing games, RPGs tend not to do terribly well with nuanced characters. NPCs in published adventures tend to be awfully one-dimensional. The knight in shining armour turns out, almost without exception, to be a goody two-shoes knight in shining armour. The black-hearted villain is, sure enough, a black-hearted villain. (And as for the PCs, well...)
Now, to a large extent this is entirely understandable. Over the course of "Babylon 5", G'Kar has a large amount of screen-time, measured somewhere in hours. In "Game of Thrones", Tyrion Lannister, probably the most complex character, has more screen time than just about anyone else. In D&D, the typical villain lasts four rounds, which is about 24 seconds of game-time. It's not exactly easy to put forward a nuanced portrayal in that time, nor is it really worthwhile to do so.
The solution to this is obvious, of course - give the villain more screen-time. Sure, if he's only around for four rounds, then there's little point in detailing a personality. But if the villain is around for months of game time, then suddenly matters change.
Now, of course, not every campaign will warrant this, and not every villain within a campaign will deserve it. Sometimes, they should just be the bad guys, and make a very satisfying thump when they hit the deck. But sometimes...
That said, if the PCs are the good guys, and they're keen to resolve the plot, just how do you give your villains screentime without them promptly dying? Well...
- Introduce your villains in situations when violence isn't an option. The Bond films do this all the time - he's forever meeting the villain in public locations, or where there are sufficient bystanders around that he can't resort to violence, or where his actions would be misinterpreted. If the PCs are invited to a third party's well, party, they should feel beholden to not make a scene... and that allows the DM to make a scene where the villain shows up.
- Have the villain appear in disguise. If the villain can shapeshift, or possess others as hosts, or whatever, this allows him to interact with the PCs without things necessarily becoming violent. Of course, they need to know, or find out, that they've been dealing with the villain.
- Make the villain ambiguous. Sure, that Inquisitor's methods are questionable, but is he really Evil? Even if he is, does that necessitate his removal, or is he a bulwark against a greater evil? This is especially effective if the PCs first hear about minor actions first, perhaps even things they can agree with, and gradually escalating to horror.
- Make the villain useful. As noted, that Inquisitor might be a bulwark against a worse evil, so the PCs may feel they need to keep him around until they can deal with the other threat first. Or, perhaps early on in the campaign they really need help, and the only person who can offer it is the BBEG - and then they owe him. Or similar.
- If all else fails, always have an escape plan or two. But be prepared to lose your villain if those plans fail - few things annoy players more than the DM using fiat to let his bad guy escape a rightfully-earned death.
Having established means to give the villains screen-time without them dying, that's half the job done. But, of course, there's no point in giving your villain screen-time if you don't do anything with it. If your villain is Profion in full Jeremy Irons scenery-chewing mode, there's not much point in giving him screen-time - there's no real nuance to show.
The big danger, though, is that the DM decides to build a character who is too complex. After all, Tyrion Lannister is a wonderfully detailed and complex character - let's have one just as involved! The problem is that it's really hard to bring out such detail when the PCs get to interact with the villain just a handful of times, and when most of their efforts will necessarily be dedicated to bringing him down.
So, my recommendations here:
- Don't make the character too complex. Most NPCs should have only a single trait. Even major NPCs should only have three or four traits - enough to establish who they are, without swamping the DM with too much work, or confusing the players with too much information. Paint in big, bold strokes!
- Give the villain at least two 'negative' characteristics, and at least one 'positive' one. That gives good reason to oppose the character... and also reason to admire him. (Equally, most 'good' characters should likewise have several noble characteristics and at least one negative trait. Nobody is perfect after all!)
- Make sure the players get to know about these traits! Remember, anything the players don't learn about is just wasted effort - pics, or it didn't happen.
- Members of organisations should always be more than just a member of that organisation. After all, how many of us are just our jobs, and nothing more? If nothing else, there should be an indication of how fully the character believes in the ideals of the organisation - are they a true believer, are they just in it for the money, or do they secretly want out?
And that, I think, is that. There's obviously a whole lot more that could be said about NPC design, but this post is more than long enough as it is.