We all know Jim Carrey as a Hollywood actor with the most unusually erratic characters. The rubber-faced comedian has certainly made plenty of his funny roles memorable enough whether he's starring as Batman's enemy or a sociopathic pet detective in Africa.

RELATED: 10 Best Jim Carrey Comedies, Ranked (According To IMDb)

Then, there are also his serious roles which prove once and for all just how flexible he is as an actor. Hence, we believe his most famous and iconic film characters are varied enough to be categorized in Dungeons and Dragons' moral alignment system. So whether he's going crazy or existential, here's how evil or good Jim Carrey's movie characters are.

ACE VENTURA (ACE VENTURA SERIES) - CHAOTIC GOOD

Jim Carrey in Ace Ventura Pet Detective

Ace Ventura from the couple of Ace Ventura movies he's in, is a prime example of a dysfunctional detective. He's good at what he does but really, who would take a "pet detective" at the police department seriously?

In any case, Ace has proven himself a good example of human decency as he has stopped poachers and illegal animal traders. How he does it leaves a lot to be desired but that makes him a chaotic good character.

STANLEY IPKISS (THE MASK) - CHAOTIC GOOD

Jim Carrey talks to the camera in The Mask

It's hard to imagine which actor would have fit The Mask better than Jim Carrey. It's like he was built for this very role. He proved this well enough after playing as Stanley Ipkiss in the movie adaptation. Surely enough, as soon as he puts on the God of Mischief's mask, the magic happens.

RELATED: Sonic The Hedgehog: 10 Films Starring Jim Carrey You Need To See

It's one of Jim Carrey's most hilarious superhero-related movie where he runs around causing as much mayhem as he can while managing to save everyone in the process. It's unorthodox as superheroes go, but this earns him the title of chaotic good again.

TRUMAN BURBANK (TRUMAN SHOW) - NEUTRAL GOOD

Perhaps one of Jim Carrey's most serious roles in Hollywood, The Truman Show will make you question free will and what the heck are you doing with your life. At the heart of it all is Truman Burbank living a false life since he was born for the sake of reality television.

Of course, it soon starts to fall apart and Truman begins seeking answers and freedom after gradually finding out that he's but a mere guinea pig for other peoples' entertainment. He certainly knows what's good or bad and has no qualms of using unconventional methods to do what he believes is right.

COUNT OLAF (A SERIES OF UNFORTUNATE EVENTS) - LAWFUL EVIL

Count Olaf A Series of Unfortunate Events Jim Carrey

Moving on to Jim Carrey villains, we present you Count Olaf from the movie adaptation of A Series of Unfortunate Events by Lemony Snicket. It's not hard to know Count Olaf's motivations after we find out that the kids he took care of have a hefty sum attached to their names.

RELATED: 10 Most Ridiculous Jim Carrey Characters, Ranked

Count Olaf, for that matter, is a scheming and manipulative wretch who also regularly abuses the protagonists. Only a lawful evil character has the discipline and willpower to maintain such a despicable plan.

COLONEL STARS AND STRIPES (KICK-ASS 2) - LAWFUL GOOD

As ridiculous and disappointing Kick-Ass 2 is, it still gave Jim Carrey an opportunity to play another superhero. Well, vigilante seems to be more apt here as he has no superpowers despite being a semi-serious parody of Captain America named Col. Stars and Stripes.

With a name that practically screams "America!" at your face, Col. Stars and Stripes is every bit as virtuous as the Marvel superhero he's parroting. In that regard, he's a solid lawful good character-- the typical goody-two-shoes type and defender of the downtrodden.

LLOYD CHRISTMAS (DUMB AND DUMBER SERIES) - CHAOTIC NEUTRAL

Quite possibly one of the most intellectually challenged characters Jim Carrey has ever played, Lloyd Christmas has all the actor's trademarks. Lloyd Christmas can be a menace to society even though he's not intentionally harmful.

RELATED: The Best Jim Carrey Movies According To IMDb

His stupid antics with his best friend Harry Dunne (Jeff Daniels) make for comedy gold. While not inherently evil or good, Lloyd's naivete and tendency to deceive his friend make him one of the most troublesome chaotic neutral characters in movies.

JOEL BARISH (ETERNAL SUNSHINE OF THE SPOTLESS MIND) - TRUE NEUTRAL

Yet another of Jim Carrey's serious roles in Hollywood would be Joel Barish, the protagonist of Eternal Sunshine of the Spotless Mind. It's a sci-fi romance film where Joel elects to erase the memories of his ex-girlfriend after a messy breakup with her.

However, the procedure proved to be less effective than advertised and made Joel retain some lingering feelings for his ex without knowing who she is. It's a weird situation but it's safe to say that it made Joel indecisive and clueless, making him true neutral for not having any idea of what's happening for half of the movie.

BRUCE NOLAN (BRUCE ALMIGHTY) - CHAOTIC NEUTRAL

Jim Carrey in Bruce Almighty

Bruce Almighty teaches us that if you spite "god" good enough, then he'll get fed up and give you his job. Turns out his job was not that easy especially if you're someone as morally dubious as Bruce Nolan in Bruce Almighty.

RELATED: Jim Carrey's 10 Best Movies, According To Rotten Tomatoes

After receiving god's powers Bruce immediately abuses it and panders to his own needs, even ruining his enemy's life. Of course, he does learn that it comes with certain responsibilities which he chose to fulfill but he's still chaotic neutral-- someone who values independence and self-satisfaction above all.

THE RIDDLER (BATMAN FOREVER) - NEUTRAL EVIL

The Riddler isn't a Batman villain that gets portrayed much in movies because he hasn't really aged well. Still, Jim Carrey manages to make him a show-stealer in Batman Forever. Alongside Two-Face (Tommy Lee Jones) they go out of their way to ruin Bruce Wayne's nights.

Riddler, however, is a hard character to categorize in D&D's moral alignment system. He abides by his code yet harms people without hesitation and is prone to outbreaks. This makes him a neutral evil character, at least for the one portrayed in Batman Forever.

DOCTOR EGGMAN (SONIC THE HEDGEHOG) - LAWFUL EVIL

Finally, we arrive at one of Jim Carrey's latest AAA-movie role, Doctor Eggman from Sonic the Hedgehog. Whether he nails it or not, you can't deny that Doctor Eggman is a genius-- one that values his own structure and criminally oppressive system.

He wants nothing more than to dominate the entire world and needs Sonic's power to do that. Eggman's intelligent use of his inventions and blatant narcissism earns him the lawful evil alignment-- a villain with deadly ambition.

NEXT: Jim Carrey’s 10 Most Hilarious Characters, Ranked