James Marsden has been confirmed to costar with Jack Black for the low-budget indie comedy "The D-Train." The upcoming comedy is being produced by Black's Electric Dynamite, Ealing Studios and Mike White's RipCord Productions.

The film is the directorial debut of Jarrad Paul and Andre Mogel, who were best known for writing Jim Carrey's "Yes Man" and co-creators of Jonah Hill's "Allan Gregory" animated series.

The movie follows the story of Black's character, a chairman of a Middle America high school reunion committee. Due to his not-so-enjoyable experience back in high school, his character is still longing for acceptance from his former peers. He believes the reunion will be a way for him to gain recognition from his high school batchmates.

This is where Marsden's character comes in. He plays the most popular guy in high school who became a failed actor appearing in TV commercials. Due to his desperation, Black will go to extreme lengths to get Marsden to make an appearance at their reunion.

White ("The School of Rock," "Zombieland") will also appear in the film as Black's only friend.

Filming is set to take place later this month in New Orleans.

If negotiations go well, Black will be returning to child-oriented projects with the film adaptation of R.L. Stine's "Goosebumps," The film will be directed by Rob Letterman, who also worked with Black on "Gulliver's Travels" and "Shark Tale." In the film, the actor will play a Stine-like author who must confront his literary creations after they were brought to life from the pages of his books.

Meanwhile, Marsden is in talks for a role in Nicholas Sparks' "The Best of Me," which was originally meant for Paul Walker. The film will be about two former sweethearts who were separated for twenty years. They meet each other again after returning to their hometown to attend the funeral of a close friend.