Focus on things you enjoy in life. If you're feeling lonely, make an effort to spend time with the friends and family you do have, and let them know how much they mean to you. Also seek out ways of meeting new people that share an interest with you even if it's uncomfortable and you're pessimistic about the outcome (i.e. going to meetups), just make sure to go in with the attitude of "It may be unlikely but I hope I meet someone I get along with here." and not "This is a waste of time."
You're not a bad person, you're not worthless, and your life won't always be shit. If you make the mistake of suicide, then you'll never enjoy all the good things that will happen to you over the next 40, 60 or 80 years. And that's a lot of good shit.