Working on film sets surrounded by people doing all kinds of jobs sometimes inspires actors to become multi-hyphenates. Just as some actors have proven themselves to be great directors, like Clint Eastwood and Angelina Jolie, some actors have turned to the pen and written great screenplays. There are also some great actors who have turned out to also be great directors and great writers, like Greta Gerwig.

RELATED: David Lynch's The Straight Story & 9 Other Times A Director Stepped Outside Their Comfort Zone

Gus Van Sant’s Good Will Hunting, written by and starring Matt Damon and Ben Affleck, is a prime example of a movie with fantastic performances and a brilliantly crafted screenplay by the same people.

Good Will Hunting (1997)

Will and Sean sitting in the park in Good Will Hunting

At the age of 25, Ben Affleck became the youngest recipient of the Academy Award for Best Original Screenplay along with his 27-year-old co-writer Matt Damon for their work on Good Will Hunting.

Damon stars as a genius janitor who develops a close bond with a therapist played by Robin Williams. The actor began writing the script as an assignment for a playwriting class, then brought Affleck aboard to help him flesh it out into a feature-length screenplay to give themselves a movie to star in.

Superbad (2007)

Seth Rogen in a liquor store in Superbad

Seth Rogen and Evan Goldberg began writing the screenplay for their raunchy high school comedy Superbad when they were 13 years old, which makes it possibly the only comedy about teenagers trying to lose their virginity that was written by actual virgins.

RELATED: Superbad: Why Fogell Is The Movie's Funniest Character (& 5 Alternatives)

The lead characters are called Seth and Evan, and Rogen initially intended to play Seth. However, since the movie didn’t get made until the writers were in their 20s, Rogen aged out of the role and played the cop Officer Michaels instead.

From Dusk Till Dawn (1995)

Seth and Richie in the strip club in From Dusk Till Dawn

In exchange for doing the effects for Reservoir Dogs’ ear-severing scene, special effects company KNB paid Quentin Tarantino a paltry $1,500 to write the script for From Dusk Till Dawn, a vampire-infested horror actioner that would give them a chance to showcase their abilities.

Although Tarantino originally planned to direct the movie himself between Pulp Fiction and Jackie Brown, it was eventually brought to the screen by Robert Rodriguez. Tarantino stars as career criminal Richie Gecko opposite George Clooney as his brother Seth.

Bridesmaids (2011)

Annie causing a scene on a plane in Bridesmaids

When Kristen Wiig shot her supporting role in Knocked Up, director Judd Apatow was so impressed that he asked her to develop a starring vehicle for herself.

So she teamed up with her comedic partner Annie Mumolo and wrote Bridesmaids, for which they were eventually nominated for the Academy Award for Best Original Screenplay. Wiig plays Annie, whose personal problems come to a head when her best friend gets engaged and chooses her to be the maid of honor.

This Is Spinal Tap (1984)

Spinal Tap perform onstage from This is Spinal Tap

Most of the dialogue in This is Spinal Tap was improvised, but those improvs were drawn from a story outline written in advance to give the filmmakers a roadmap to work with.

RELATED: The 5 Best (& 5 Worst) Mockumentaries

The iconic mock-rock-doc stars Christopher Guest, Michael McKean, and Harry Shearer as one of Britain’s loudest rock bands. They co-wrote the outline with director Rob Reiner, who also plays in-universe director Marty DiBergi.

Bottle Rocket (1996)

Owen Wilson with a gun in Bottle Rocket

Like most of Wes Anderson’s movies, there’s more than one Wilson brother in his debut feature Bottle Rocket. Luke Wilson plays Anthony, Owen Wilson plays his dim-witted wannabe criminal best friend Dignan, and Andrew Wilson plays their mutual friend’s mean-spirited older brother.

Owen Wilson co-wrote the screenplay with Anderson and would go on to co-write the scripts for the director’s next two movies, Rushmore and The Royal Tenenbaums.

Sense And Sensibility (1995)

Kate Winslet and Emma Thompson in Sense and Sensibility

Emma Thompson adapted Jane Austen’s Sense and Sensibility into a screenplay for director Ang Lee, then starred in the movie alongside Alan Rickman, Hugh Grant, and a pre-Titanic Kate Winslet.

Thompson expertly updated the story for modern audiences, including recharacterizing the male leads to be more likable and leaning into the family’s wealth in the first half to make their poverty more apparent in the second.

Anchorman: The Legend Of Ron Burgundy (2004)

Will Ferrell reading the news in Anchorman

Adam McKay and Will Ferrell had been working together on SNL for years, refining their uniquely absurdist comedic style before bringing that sensibility to the big screen with Anchorman. Ferrell developed the character of Ron Burgundy based on real-life ‘70s newsman Mort Crim.

The final movie was very different than McKay and Ferrell’s original draft, in which Ron and a bunch of other newscasters are involved in a plane crash and have to fight an army of intelligent apes in the wilderness.

Before Sunset (2004)

Jesse and Celine rise on a boat in Before Sunset.

Richard Linklater’s Before trilogy is one of the greatest love stories ever told. Over the course of three movies, Jesse and Céline walk around Europe, engage in intellectual discussions, and gradually fall in love. Linklater co-wrote the first installment in the trilogy, Before Sunrise, with Kim Krizan.

RELATED: Before Trilogy: 10 Ways It's One Of The Greatest Love Stories Ever Told

But when he was writing the two sequels, Before Sunset and Before Midnight, he brought on the series’ stars Ethan Hawke and Julie Delpy as co-writers.

Rocky (1976)

Sylvester Stallone reaches the top of the steps in Rocky

Like many actors who turn to screenwriting, Sylvester Stallone was struggling to land a leading role, so he wrote one for himself. When he sold Rocky, he took a significant pay cut in order to secure the privilege of playing the title character.

Stallone’s Oscar-nominated script has since inspired countless uplifting sports dramas about underdogs. Its imitators have missed the fact that Rocky took the time to develop the character in its longer-than-usual first act.

NEXT: Birdman & 9 Other Movies About Acting