Most music fans know that to beat on a brat you need a baseball bat, but apparently no one told Barbie. A judge handed down a decision Thursday in a court case between Barbie-maker Mattel and Bratz-maker MGA Entertainment Inc. The judge decided that Mattel has to pay MGA $309 million dollars as part of a lawsuit settlement, The L.A. Times reports. Mattel was suing MGA alleging a former Mattel employee violated the terms of his contract when he took his idea for a new line of dolls to MGA. Mattel has an "inventions agreement" in their contracts. Bratz inventor Carter Bryant worked for Mattel in 1999, when Mattel alleges he took his new idea to MGA. Bryant maintains he thought of the big-headed Bratz dolls in 1998 when he was on a break from working with Mattel.

The lawsuit between the two companies "captivated Southern Californians, nearly put MGA out of business and made toy analysts question Mattel's motives as the litigation dragged on." In 2008 a judge sided with Mattel and rewarded them $100 million dollars. 

The jury in the retrial said Mattel had not proved its claims of copyright infringement and instead found that the company had stolen trade secrets from MGA and owed it $88.5 million. That was seen as a paltry amount for a case that analysts estimated had cost each side hundreds of millions of dollars in legal fees alone.

Thursday, the judge in the retrial decided they made a mathematical error and corrected the payout to MGA to $85 million. MGA asked the judge if their settlement would recoup their legal fees. He complied, and they were awarded the full $309 million for the troubles. Mattel intends to figure a way out of the hefty paycheck. 

This may be only the tip of the financial ice berg between the two toy giants. After dragging the Brantz name through the mud, MGA is alleging the suit cost them $1 billion. Now they're planning to "recoup those losses in a separate and pending antitrust lawsuit against Mattel."