There’s no worse way to end your movie than with a deus ex machina, except for maybe running out of funding at the end of act two and then just releasing the film as is. A similar device to the deus ex machina that I sometimes see is to give the protagonist (or anyone else in your script) an unusual and inexplicable ability right when he needs it. For example, here are some abilities that you should not give to your protagonists without first setting them up thoroughly and believably:
- A priest who knows how to fly a Stealth Bomber.
- A waitress in Idaho who can read hieroglyphics.
- A paralegal who is an expert at underwater welding.
If you put any one of these characters into a position where they will need one of those specific skills, and you haven’t first provided a reasonable explanation as to why they have that skill, then you will actually be able to hear the audience groaning all the way from your house. It’s entirely possible that any of these characters could have one of these abilities, but it’s so unexpected that you would have to set that up beforehand (subtly, of course) in order for the audience to believe it.
Let’s look at some movies that do give their protagonists some extreme abilities, and show how they pulled that off:
- You wouldn’t expect a relatively diminutive slave to be able to defeat the most powerful gladiators in the world, unless you first saw that this particular slave was once a general in the Roman army, as was the case in the movie “Gladiator.”
- A crippled man isn’t likely to become the greatest warrior in a tribe of physically imposing aliens, unless we know in advance that he is a tough ex-marine inhabiting an alien’s body in “Avatar.”
- An orphan who works on his aunt and uncle’s moisture farm isn’t likely to lead a rebellion against the most powerful overlord in the universe unless we know beforehand that he's the son of a Jedi warrior and has a special ability called “the force,” as is the case in “Star Wars.”
- We wouldn’t believe that a college professor could defeat an army of Nazi soldiers in an effort to find the Arc of the Covenant, unless we already know that he has overcome tremendous odds in previous adventures, as we see in “Raiders of the Lost Ark.”
- We wouldn’t expect an uneducated, lower-class woman to overcome a team of powerful corporate lawyers unless we already saw at the beginning of the script that she has breasts — I mean moxie. They’re used interchangeably in “Erin Brockovich.”
If any of the screenwriters of the above movies had tried to spring that background information on the audience right at the point of the protagonist's major showdown with the antagonist, or just at any crisis point where that ability is necessary, those movies would have turned out much, much worse.
The bottom line is that it’s fine for your protagonist to have a particular skill — however extreme or unlikely — as long as you set it up beforehand in a believable way. If you give the audience even a shred of evidence that your hero has a specific high-level ability, then they will gladly, even eagerly, suspend their disbelief long enough to watch him kick the bad guys’ butts with his uncanny ability to, say, rapidly solve complicated math problems with an abacus. (Seriously, how long does the world have to wait for an abacus-toting action hero? Get on that, Hollywood!) But if you give your hero an easy way out of a major challenge by suddenly revealing, for example, that he is fluent in every language on earth, then the audience will never forgive you.