CBS All Access has set four of the leads for its upcoming series “The Stand.”

Based on the Stephen King novel of the same name, “The Stand” will star James Marsden, Amber Heard, Odessa Young and Henry Zaga in main roles. The streaming platform has also revealed that the prolific author himself will write the final episode of the series, providing a “new coda” that goes beyond the book. The announcements were made by Julie McNamara, executive vice president of original content for All Access at CBS’ summer Television Critics Association presentation.

“The Stand” presents an apocalyptic vision of a world decimated by plague and embroiled in an elemental struggle between good and evil. The fate of mankind rests on the frail shoulders of the 108-year-old other Mother Abagail and a handful of survivors.

Marsden will portray Stu Redman, an ordinary working-class factory man in an extraordinary situation with a damaged quality to him that belies his exterior. Most recently seen on the hit dark comedy “Dead to Me,” Marsden’s other television credits include “Westworld” and “30 Rock.” On the film side, he is set to star in the “Sonic the Hedgehog” movie.

Heard will play Nadine Cross, a deeply conflicted woman who feels the consequences of her actions, but is still compelled by her allegiance to Randall Flagg, the Dark Man. The actress recently starred in the DC-Warner Bros. behemoth “Aquaman” opposite Jason Momoa.

Young will play Frannie Goldsmith, a pregnant young woman navigating a strange new world, who also has the foresight to recognize that there is evil lurking beyond the Dark Man. She will next be seen opposite Elisabeth Moss in the film “Shirley.”

Zaga will portray Nick Andros, a young deaf man who finds himself in a position of authority when the unthinkable happens. He has a habit of risking his own well-being for the safety of others. Zaga is best known for his role in Netflix’s “13 Reasons Why,” which will come to an end after its fourth season.

“The Stand” will be produced by CBS Television Studios. Josh Boone and Ben Cavell will write and executive produce, with Boone also directing. Roy Lee, Jimmy Miller and Richard P. Rubinstein will also serve as executive producers with Will Weiske and Miri Yoon as co-executive producers. Knate Lee, Jill Killington and Owen King will serve as producers.