“Mudbound” is a serious, searing drama set in the dust bowl 1930s. The acclaimed film now has an Oscar nominated for best adapted screenplay by Virgil Williams and director Dee Rees, based on the novel by Hillary Jordan.

You would never in a million years think there was any connection between this elegiac piece of cinema and the CBS weekly police procedural “Criminal Minds.” Never, right? You’d be wrong.

Turns out that Virgil Williams, who wrote the screenplay, and re wrote and rewrote it, used to write episodes of “Criminal Minds.” And Mr. Williams also happens to be the man who was at the center of a scandal last season concerning “Criminal Minds” star Thomas Gibson.

You may recall there was a scandal over a scuffle on the set of that popular if middling TV show. “He kicked me,” Williams recalled for me recently. Gibson kicked him hard. And Williams reported it to the show’s production company.

They were filming the second episode of season 12 (yes, it’s still on the air!) in the summer of 2016 when Gibson, known for a hot temper and unfriendly attitude, disagreed with Williams about a line in the script. Williams tells me that Gibson decided to go over his head to a producer. In order to accomplish that, Gibson had to walk through a doorway in which Williams was standing. And Gibson kicked him to get him out of the way.

Williams had no idea this would lead to the leading man getting the axe-– especially after 11 seasons of a hit show. Gibson was known before that as the mortal part of a “Bewitched” rip off comedy called “Dharma and Greg,” in which a stuffy lawyer marries a Bohemian with hippie parents. “D&G” ran five for unmemorable seasons. (It was “Bewitched” without the magic. Literally.) Gibson segued right into “Criminal Minds,” which established him and made him rich. But apparently it swelled his head.

Williams, meanwhile, had been slaving away on staffs of TV shows, including “ER” and “24.”

“But all the time I was writing those shows I was working on ‘Mudbound’,” he told me. “Gibson was a horror,” Williams told me. “No one liked him. He was impossible to work with.” The kicking incident was simply the last straw. It’s funny, too. Gibson was not the star of “Criminal Minds.” Even though it’s an ensemble show, Joe Mantegna– a real star– is at its center. And he replaced Mandy Patinkin after the first couple of seasons. Gibson didn’t have the resume of either of those men.

Gibson couldn’t have known that Williams had a dream, and it was “Mudbound.” Soon after the kicking, Williams hooked up with director Dee Rees, and the rest, as we know, is a happy ending. For everyone, that is, except Thomas Gibson. We have that actor– who hasn’t worked since the incident– for an Oscar nominated, award winning and groundbreaking movie.