I am now going to university for the third time in my life. The first try was exactly where you are now and it didn't go well because I didn't know what to do, so I ended up closeted in my room and ended up just dropping out.
I have no idea if what I say that works for me now works for you, but I simply do not allow myself NOT to go to class. The day after I had jaw surgery I still went, gauze and all. If I allow myself not to go for whatever reason, I will find more reasons until I am not going to class anymore and I have dropped out again. Where I am in life now, I cannot afford another failure.
I also play computer games and talk to people online (hi, this counts!) when I am not doing my studies. I do have some friends, but I have to take the train an hour away to see them, so its very rarely. If there is something you like, see if there is a group you can join. It will be horrible the first time you are there because of the social anxiety, but find a way to do it (I tend to reward myself, but I like to train animals so its ingrained).
You just need to be bloody-minded about it and don't give up because its hard now, but if you just keep going and don't allow yourself to back up (going forward is nice, but not giving up is a MUCH bigger win!) you're doing better many with depression and studies.
Hope you find your will to be stubborn.