There are several issues here that seem to be getting a bit mixed up.
On the one hand, I am with Riven- why use language that offends people?
On the other hand, how do you as a writer portray offensive characters on the screen if they are not allowed to say anything offensive? This would mean you cannot write scripts about misogynist people, nor about racist people, nor about sadists, nor about any other people with offensive views. Or do you have a speaker voice in the background who says 'this person is secretly thinking offensive thoughts', without elaborating? Or just restrict your script writing to nice, intelligent clued-up people (well, it would make a change in Eastenders ).
Letting a baddie use bad language or a stupid person use stupid language does not indicate that the writer, or his television company, finds the language acceptable. It's about language being in character- and if the character is not very admirable, that will be reflected in the language.
The problem with the thesaurus provided by an earlier poster is that none of those terms would be right for the person portrayed; a writer's job involves more than looking up synonyms in a dictionary.
The other question is, where do you draw the line. 'epi' seems clearly offensive and I think we can all agree on that. But what indeed about 'mental'? Nothing funny about mental illness. I had a friend who died from the consequences of mental illness- certainly not amusing at all. So should Ron Weasley be banned from calling Hermione Granger mental in that amused kind of voice?
I have certainly seen the term 'lunatic' (or its more colloquial spellings) cropping up on MN more than once. Should we self-censure? Or be censured?
What about the light-hearted references to drunkards and drunkenness on MN. They presumably can't amuse those families who have really suffered from the consequences of alcoholism?
What about 'addict' used lightly of less serious addictions? Not funny if your life has been wrecked by a genuine addict.
I haven't got any answers and I am not really taking either side. Just feel that there is a big difference between a writer's own persona (where he does indeed want to watch his language) and characters with whom he may not necessarily identify.