Maybe you should get them some kind of help, or tell their parents what's going on.
I felt like crap throughout my high schooling years and I never knew why, I'd suddenly feel reckless, I'd do really stupid things, I'd spend my money on absolute garbage on a whim. I'd feel like crap, then I'd feel awesome and energetic and angry at the same time.
I did drugs for reasons I never even knew, I drank, I got into fights and I stole things I didn't even need or want. All my friends thought I was just a rebellious teen doing it to be cool.
Then I was diagnosed as bipolar, apparently in many mental illnesses it's quite common to act this way.
It's not just mental illnesses, they could have some problems at home or be generally depressed about something.
This is why you shouldn't write it off as *They are just being idiots* because you could be wrong and there might be a serious problem at hand.
You should definitely tell either your parents or your friends parents that your friends are doing this. From your post it doesn't seem like you like them at all, yet you still refer to them as your friends, so there's something. Even if there isn't anything wrong with them and they are just doing it to be cool, there's the chance they are legitimately having problems and don't know how to ask for help (or think they don't need to).
Or, you could find yourself new friends and ignore them.
The choice is yours I suppose.
EDIT: I'm kind of shocked that nobody has posted something along these lines yet, considering my story and experience is DEFINITELY not unique on this website.