This article originally appeared in our affiliate, The Recorder.

The long-running IP war between Mattel Inc. and MGA Entertainment Inc. over the Bratz line of dolls has ended–for now–with zero damages.

The U.S. Court of Appeals for the Ninth Circuit on Thursday laid waste to Bratz maker MGA’s $170 million trade secret award–an award procured on retrial after the appeals court wiped out Barbie maker Mattel’s $100 million copyright verdict and constructive trust.

But MGA gets the last laugh. The Ninth Circuit left untouched $137 million in attorney fees and costs awarded to MGA for defending against Mattel’s copyright claims.

“While this may not be the last word on the subject, perhaps Mattel and MGA can take a lesson from their target demographic: Play nice,” wrote Chief Judge Alex Kozinski in a nine-page ruling.

MGA was not exactly conciliatory in a press release announcing the decision. CEO Isaac Larian promised to retry the company’s trade secret claims to a new jury. “We are confident that when the second jury hears about Mattel’s sneaking into our showrooms and egregious theft of scores of our secrets over the years, they will be even more appalled than the first jury and award MGA even greater damages,” he said in the statement.

Mattel responded in its own statement that a new lawsuit would be barred by the statute of limitations.

Thursday’s decision caps a remarkable turn of fortune in the eight-year-old litigation. It started when a Mattel designer began discussing with MGA a design for multi-ethnic dolls with pouty lips and big heads. The designer joined MGA a few months later and the dolls were an enormous success. Mattel sued, seeking $1 billion in copyright damages. It won $100 million and the rights to the Bratz dolls following a trial before then-U.S. District Judge Stephen Larson.

But a Ninth Circuit panel led by Kozinski ruled that Larson had erred and imposed an excessive remedy. On retrial before Judge David Carter, a jury not only rejected almost all of Mattel’s claims, but it found for MGA on a new counterclaim, that Mattel had stolen MGA trade secrets by planting spies at a toy industry trade show. Carter ordered Mattel to pay $85 million for stolen trade secrets, $85 million in exemplary damages and nearly $137 million in attorney fees and costs.

As foreshadowed at arguments last month, Kozinski and the Ninth Circuit ruled Thursday that MGA’s new counterclaim was time-barred. MGA had tried to avoid that outcome by presenting it as “a compulsory counterclaim,” but Kozinski ruled it was not sufficiently factually related to Mattel’s trade secret claim to meet that standard.

“Mattel’s specific allegations regarding trade secrets were that several of their employees … defected to MGA and disclosed Mattel’s trade secrets. By contrast, MGA’s trade-secret claim rested on allegations that Mattel’s employees stole MGA trade secrets by engaging in chicanery (such as masquerading as buyers) at toy fairs,” Kozinski wrote. “That both Mattel and MGA claimed they stole each other’s trade secrets isn’t enough to render MGA’s counterclaim compulsory.”

Judges Kim McLane Wardlaw and Stephen Trott concurred.

During arguments, Wardlaw had suggested that MGA still had time to salvage some of its trade secret claims by refiling. The court’s ruling ordered MGA’s trade secret claim dismissed without prejudice, so the door would appear to remain open.

Clifford Sloan, the Skadden, Arps, Slate, Meagher & Flom partner who argued the case for MGA, referred questions to MGA.

As for the attorney fees, Kozinski wrote Carter had not abused his discretion in awarding them under the Copyright Act, and that it didn’t matter whether Mattel’s claims were brought in good faith. “At one point, a copyright defendant had to show that the plaintiff’s claim was frivolous or made in bad faith in order to be entitled to fees; but no longer,” Kozinski wrote.

MGA described it as the largest fee and cost award in a copyright infringement case in U.S. history.

Quinn Emanuel Urquhart & Sullivan partner Kathleen Sullivan, who represented Mattel before the Ninth Circuit, referred questions to Mattel.