I'm losing all my friends.

I'm a freshman in highschool. I lost a friend because she though i was a bad vibe. And she decides to tell everyone shit about me. Next this girl posts me on snapchat calling me a ugly hoe. I ask why and she says because I annoy her and that she found out I said shit about her and I said that she's a crackhead. Now today this girl from my geography class texts me and starts screaming and saying why I'm talking shit about her and I said what are u talking about? She said that 2 friendd told her that I said she she lies and is not truthful. I kept telling her on and on that I didn't say that about her. I didn't. I kept asking why would I say that about her. Why? She's my friend I said. So why would I talk shit about her when she didn't do anything to me? She said idk but don't ever talk to me again I always tried helping u and u talk shit about me. Stay out of my life. Block me. She won't understand. I keep losing friends. People are telling my friends I said something about them and they automatically believe them and stop being friend with me. What do I do? In my geography class I'm usually with her and this other guy for groups. I have another friend in that class but she's in the same group with someone else. Also that whole class has there own groups already. And half the class are guys that would make fun of me and state at me a lot. And 2 of the girls that don't like me are in the class and always judging me. When they see I don't talk to anyone or have a group, they will laugh and talk about me. What do I do I'm crying right now.