How do I [22M] go from being a shallow, self-centred, selfish, over-confident douche to being a cool, confident, deep person?

Sounds like you're already on your way. Remember that you aren't the best and you aren't always right.
Many people in life are victims of circumstance and bad timing so don't judge them so harshly. You don't know their stories and most people are all just trying to get by as well as they can.
You still have friends--I'd recommend starting out by trying to 'reconnect'. Ask them questions about what's going on in their lives and listen to them. Really listen and take it in and try to understand them and where they're at.
You can be nice and not be a doormat--remember that; you've been going from one extreme to the other (which is quite normal at your age). Now it's time to pick out the good things to keep and the bad things to toss.
Something that someone said to me really changed me.
"Think about the future--what kind of man do you want to be? Is it anything like you are now? If not, why not--and for the things that can be controlled--why aren't you?"
That hit me pretty hard and caused to change a lot. I started trying to pick up different hobbies, started to care for myself and others more, and a lot of other things.
With your mom--be nice because you may regret it if you don't and I'd hate for you to have to live with that guilt.
From now on, if someone pisses you off; just take some time to think about it. If someone tells you you're doing something wrong then don't immediately go on the offensive. Just think to yourself, "are they right?" and be honest with yourself. If they are then own it and if they aren't politely explain yourself.
If someone ever confronts me with something I usually have to take a time out to gather my thoughts. It's a bit odd sometimes but it's better than saying something I'll regret.
Best of luck.

/r/relationships Thread