Megan Fox has been cast in Jennifer Westfeldt’s new ensemble comedy Friends With Benefits, THR are reporting.

Fox will star opposite Jon Hamm, Kristen Wiig, Adam Scott and Westfeldt herself.

Friends With Benefits revolves around a pair of thirtysomething best friends who observe the toll that having kids has taken on the couples they know and resolve to bypass that stress by having a child and then date other people.

Hamm will produce alongside real-life partner Westfeldt, with Mike Nichols and Jake Kasdan on board to executive produce.

Kasdan said of the film:

“Jen wrote one of the funniest and most original scripts I’ve read in a long time, the rare great generational character comedy.”