Hello I'm quite new to this but I really need to talk with someone who might be able to understand me.   
4 years ago I met my ex and it was love at first sight, but it quickly turned really abusive(mentally) and even though he made me happy, the relationship was not healthy. There is a lot more to it but I will skip to the part as to why I'm here.   
It's been around 3 years since we broke up but around 10 months ago his current girlfriend contacted me and asked me if he was as horrible to me when I was with him. This lead me to get back in contact with him and even though its been years I knew that I still had feelings for him.(I know this wasn't right of me, but he made me believe that he missed me ever since and that he had broken up with his current gf) He ended up cheating/abusing me again and this lead me to self harm and taking a lot of pills in the need to just not be awake.(I'm very strong when it comes to stuff like self harm so this was the first time I was so far out that I would do something like that) He put me through so much and even thought I know what I want and that's it's not him, he still triggers me.   
I'm so close to graduating with nearly perfect grades, I have plans for the future I'm doing everything I can to become happy, but as soon as I think of him I become extremely depressed, to the point where I can't stand being awake because it consumes me. I'm seeing a psychiatrist once a week and he has been helping me a lot, I feel like I'm finally getting better but;     
Today I just walked home from school, my mood wasn't the best but it could have been worse. But then suddenly boom everything turns dark and the only thing I can feel is this strong feeling of needing to escape to just not be here anymore. (I call it the cave mood because when this feelings hits me I just lock myself in my room). This feeling is very common for me to get, and there is often no reason for it, but lately I been thinking on him again and I know that this time it's connected to him.   
He was my first and only boyfriend, and since him I haven't felt anything for anyone, at least not in the way I feel about him. I'm scared that this attachment I still feel will ruin the potential I have and the future I want.   
Is there anyone here who might have been through the same thing who can tell me how they coped with it because I just don't know what to do at this point.