On Thursday, Lions Gate admitted to failing to properly disclose the details of how it stopped him and agreed to pay $7.5 million to the SEC.

The tale is detailed in the SEC’s order against the company, giving a unique view into a board’s actions to block Mr. Icahn. It reads like a plot for Lions Gate’s next installment of The Hunger Games, including turns with a former ally of Mr. Icahn, urgent text messages and a midnight board meeting.

Here’s the script:

In March 2010, Mr. Icahn, who had an 18% stake, announced a tender offer to acquire 30% of Lions Gate for $6 a share, a 10% premium to the prior day’s closing price. Ten days later, Lions Gate put in a poison pill to block him from acquiring such a stake and urged shareholders to reject the offer.

A short time later, however, Mr. Icahn scored a coup, buying large blocks of shares from two shareholders, boosting his position to 37.9% as of July 2010. Lions Gate’s board, the SEC order says, had been attempting to place those blocks in the hands of some “white squires” but failed.

After Mr. Icahn boosted his stake, the Lions Gate board began planning what would be its ultimate move to block the activist investor, placing a large set of convertible notes into the hands of a friendly director, thereby boosting their allies and diluting Mr. Icahn’s stake.

Lions Gate Vice Chairman Michael Burns, who was leading the public campaign against Mr. Icahn, reached out to a holder of the set of convertible notes and made an offer to exchange them for a new set. The old set carried a conversion rate at nearly double the current stock price, meaning it would cost the shareholder millions more to convert them, the order said. So Mr. Burns made an offer to give the holder new notes with a more favorable price that would motivate whoever held them to convert them to stock.

Meanwhile, Mr. Burns began discussions with another director, labeled the “Friendly Director” by the SEC, about buying this noteholder’s newly minted holdings. The “friendly director” was Mark Rachesky, who had previously worked for Mr. Icahn but had allied himself with Lions Gate.

As this was going on, Mr. Icahn and the board of Lions Gate agreed to a 10-day standstill while the company sought a potential deal with a rival film studio, reported to be Metro-Goldwyn-Mayer Inc.

Amid the standstill, talks between Mr. Rachesky and Mr. Burns continued, according to the order.

“Get me all and [the Shareholder] may leave,” Rachesky wrote in a text message, according to the SEC order. “Its our only chance. I haven’t been wrong yet about him. You have to trust me.”

“Trying like hell,” Mr. Burns replied, the order said.

As talks with MGM collapsed, the standstill was about to end and Mr. Icahn was planning a new tender offer. The SEC said the board was ready. Lions Gate scheduled a meeting of its special board committee for one minute after midnight, as the standstill expired, and the entire board met immediately after that.

At the meeting the board approved the plan to convert the noteholder’s notes to more attractive prices, even agreeing to lower the conversion price further at the request of Mr. Rachesky. It also approved a change to its insider-trading rules that would allow the Mr. Rachesky to convert his notes to shares immediately. The transaction went through, giving Mr. Rachesky about 16 million more shares for a total stake of 28.9%, up from 19.9%, and diluting Mr. Icahn to 33.5% from 37.9%.

At the company’s annual meeting, Mr. Icahn’s slate was defeated. One of his nominees lost by 16 million shares–the number of shares Mr. Rachesky got in the conversion.

The SEC says the events weren’t properly disclosed to shareholders, which is the reason for the $7.5 million fine.