Tl;dr at bottom

So earlier tonight, my friend and I had a falling out of sorts. Hes pretty down on his luck, 22, living with his shitty dad and senile/abusive grandmother and I would give him rides around, hang out with him, give him money and food and pay for a bunch of stuff and I would consider myself pretty friendly with him. Long story short, he doesn't have a place to stay, spam called/texted me asking for help (I was asleep) then got pissed when I didnt respond and said that I dont care about him. I woke up and of course, I was mad, so I told him to apologize or I would block all contact with him and sever ties with him. He essentially ignored me and didnt respond at all after having responded immediately previously, so I said "you have x amount of time to apologize". After that, he tried to call me a couple times, but I was at work so of course I couldn't answer. After I tell him this, he says, verbatim, "stop messaging me. if you dont youd better believe i will walk my happy ass to the courthouse and file an adjunction against harassment against you." I message a couple more times, wanting to give him more of a chance to rationalize and apologize, but he just said "go f*ck yourself you c*ck baby. see you in court" (minus censors of course) and stopped replying, so i blocked him. I don't feel good about this situation at all but I also dont feel like I was the asshole.

Tl;dr - My friend and i got into an argument, and he is now threatening legal action over text messages. 