If you have ADHD and autism, it might increase the risk of substance abuse/addictions in general. Some papers on it: https://pubmed.ncbi.nlm.nih.gov/23897915/, https://www.ncbi.nlm.nih.gov/pmc/articles/PMC5222913/, https://www.ncbi.nlm.nih.gov/pmc/articles/PMC3965675/
I had a brush with both alcoholism and video game addiction before. Good to hear that you don’t have to deal with any addictions.
I think what could really help is having a tight circle of friends. When you have nothing going on for you in life and you are not really looking forward for anything, it might get you in this circular thinking of “my life is ruined because my brain doesn’t work right” and really focusing on this thought and seeing your neurodivergency as the root of all discomfort in your life, which may then manifest itself as suicidal thoughts. I have been there and I sometimes still have such episodes because I don’t get what I expect from my friends. So yeah, this is of course no easy task, but try to find people that will enrich your life with new things. Try to find things you can look forward to. You can say that it’s just coping, and it is, you are trying to disassociate from the pain of living with autism, but there is no other way around it; you can’t solve autism, you can only cope with it. There is no shame in coping with something that you cannot change.
Hang in there! If you try, it can only get better.