It sounds like your problem is some sort of
social anxiety. If underlying anxiety is your issue then all the talk of finding your purpose or fixing your views on having friends won't help much until the real issue is handled.
You sound like your people skills are rusty as well.
This site has been mentioned on this board a few times and is a pretty good resource for that... but again, if the anxiety isn't addressed you'll have a hard time implementing any advice.
Sorry, if you already know that about yourself, which you might