Story consultant Daniel Manus discusses the use of irony in screenplays.
Irony is a dramatic device that expresses an idea which is the antithesis of the underlying concept to draw attention to it such as the super fit Olympic athlete dying of a heart attack after a marathon.
There are 3 major types of ironies used in screenwriting;
This involves the reader (or audience) knowing something about what’s happening in the plot, about which the character(s) have no knowledge. Dramatic irony can be used in comedies and tragedies, and it works to engage the reader, as one is drawn into what is happening. I have previously referred to this as the audience SUPERIOR POSITION.
One example of this is The Sixth Sense – “I see dead people” is ironic because he doesn’t know he’s dead. Or how Shrek thinks that Fiona could never fall for him because he’s an ugly ogre, but we know that she’s an ogre too!
This occurs when something has two meanings, usually opposing, and when the words have an opposite meaning in the situation than what the speaker is trying to say. It can often come out in sarcasm or double-entendre, which are more deliberate.
This occurs when the outcome of some situation or action is the exact opposite of the intended outcome. But the irony has meaning because of the specific situation the character is in. For example in Rise of the Planet of the Apes when a scientist is murdered by the same monkeys he was trying to save.