Omg i ve been in the exact same situation...And if u follow some steps i promise u that she ll come back to you.
1) ignore her : i know its really hard, but just do it! whenever you think of her, think that she's the one who lost you, you were the "prize". Don't text and write a "Z" beside her name, which will almost guarantee you that you won't read her name if your scrolling down your contacts list. As for fb, hide all her posts from your home page. Also try not to go on fb that much...
2) Show her that its not a big deal for you : Show her that you go to parties and have a lot of fun! make her regret that she left you...Show her that you're a fun person to be with!
3) Be super polite: Be a gentleman when you talk to her...Forget what she has done to you whenever you guys talk, and NEVER talk about things that pissed you off etc...
4) Take your time: whenever she texts which she will prob after a week, take your time! or don't even text back until the next day and DON'T say sorry for being busy just answer what she said and be like "p.s my phone was dead yesterday"
5) DHV!!! prob the most important part is DHV at this point, be a busy person because you're invited to this girl's birthday party or something....
Hope this helps man

good luck!