"I'm just sorry that she had to be your fortune cookie - broken, so that you can learn something you already should have known."
closed as unclear what you're asking by Robusto, anongoodnurse, Elian, tchrist♦, aedia λ Jun 2 '14 at 17:42
Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
This question is borderline General Reference, but I’ll go ahead and answer it because it does contain some not-entirely-straightforward metaphor.
A fortune cookie is a small, hollow type of pastry that has a small slip of paper inside, with some kind of generic good advice written on it. Fortune cookies are usually given to guests at Chinese restaurants after they have finished their meal; the advice they contain is usually quite banal and expresses things that people generally know already (“Don’t let adversity get you down”, “The grass is always greener on the other side”, etc.—silly little things).
In order to read the advice given in the cookie, you have to break the cookie apart (and then eat it, of course).
In your quote, a woman (‘she’) is being compared to a fortune cookie. I am going to presume that this is a quote spoken to someone who has just gone through a break-up with this woman. The woman was hurt (‘broken’) in the process, and the person who broke up with her has learnt something from the break-up that they should have known all along (perhaps that they never really loved her or something like that).
The metaphor is thus that the woman ended up being broken apart by ‘you’, and the only thing ‘you’ got out of it was a slip of paper that told him something he probably knew all along, or at least should have known all along—just like when you break open a fortune cookie. The play on words that when a fortune cookie is broken, it is broken physically, whereas (presumably) this woman is instead heartbroken—a different meaning of the word broken.