Years beforeJoaquin PhoenixleftTodd Hayneshanging, he dropped out of another major directors film with days to spare.

James McAvoyrecently recounted his last minute preparation for the starring role inM.

Night Shyamalans 2016 thrillerSplitafter the Oscar-winning actor exited the production two weeks before filming kicked off in Philadelphia.

A ‘Split’ still of James McAvoy sitting in a car driver’s seat; a red carpet photo of Joaquin Phoenix

James McAvoy recalls preparing for ‘Split’ after Joaquin Phoenix dropped out of the role.John Baer/Universal Pictures/Courtesy Everett Collection/Vittorio Zunino Celotto/Getty Images

Im confident enough to think Ill do it better.

said McAvoy on theHappy Sad Confusedpodcast.

Hes an amazing actor.

John Lithgow

Anya Taylor-Joy, Haley Lu Richardson, Jessica Sula and James McAvoy inSplit(2016). (John Baer/Universal Pictures/Courtesy Everett Collection)

I think he ditched it two weeks before they started shooting.

It was really last minute.

I had two weeks.

There were a couple of characters that took a little bit longer to find.

Patricia came real quick, Dennis came real quick.

Hedwig took a little while.

It wasnt until the read-through for the table read which I was really nervous for.

It just came on really quick, McAvoy added.

Production is dead on the film, which was set to co-starDanny Ramirez.

I auditioned for it and I think they wanted to put me on a retainer, he explained.

The actor noted of the really strange process, And they offered quite a lot of money.

For me at that time, it was a ton of money.

It was like 40 thousand pounds or something like that.

It was part of the making of me.

I was actually learning and doing all that, said McAvoy.