@Smont Feeling for you Brother, I have dealt with suicide from both ends. I know the misery and helplessness that leads to that decision, and luckily lived to learn the damage and pain it would have caused my family and friends. So I have the emotional reactions of my family and friends as well as a long scar going up my wrist to remind me to never allow myself to get there again.
If it helps once someone truly hits that level of despair I don't know that there is anything that can bring them back outside of physical interruption. I had my closest friends there in the house actively trying to be there for me and I locked myself in a bathroom turned on the shower slit my wrist and sat down under the hot water. One of my friends realized had disappeared, found the bathroom door locked and kept knocking but I wasn't responding. So he kicked the door down and saved my life. I was half passed out and out of it when he busted the door down. No doubt he saved my life, and I was so angry at him in the moment.
I remember talking with family and friends after and my mom really letting me have it. We were coming up on my birthday which would be the 1 year anniversary of my brother being killed at my birthday party, and i just melted down. No real signs of depression, then got drunk and lost it one night.
I still remember my mother asking me how could I do that to her, that her son was murdered last year and now I was trying to kill the only son she had left. She was so broken... just from knowing she had almost lost me too. It was a very awakening thing to see my mother in that much pain, especially since I lived. Knowing I was the cause of her suffering was excruciating for me. That one moment made me realize that even though I felt hopeless, trying to commit suicide was the most selfish thing I had ever done. The people who would have been left behind would have been my final victims, and may have never fully recovered. Thank goodness I had that awakening, now when it gets bad or those thoughts start to creep in I pay attention and seek out help. Sometimes I will just let my wife know the darkness is back, and I just need her to hold me and make me feel okay for a while. if it gets too bad I will see a therapist. Luckily those moments get farther and farther apart.
Anyway, sorry for the long post, but I just wanted you to know from the point of view of someone who has attempted suicide, that there really isn't anything you could have done. If you were there for him and showed him love and affection you did everything you could have done and brought him more joy than I am sure you can imagine just being his friend. That level of hopelessness hits hard, and hits fast, sometimes out of nowhere, and it encompasses everything suddenly. So don't beat yourself up, you being a good friend is the best thig you could have done for him and that is what you did.