I had serious depression for about 9 months following an incident where someone I loved started to hate me and ignore me. This really damaged my self esteme which was built on the idea that if I was nice to everyone and did as I was expected to, everyone would like me.
Now I've sort of rebuilt my self esteme and I'm currently very happy as I have wonderful friends and my life is going well (and I watch MLP which always helps :P). However I still feel very fragile and have moments were I just feel depressed and suicidal and I worry that these moments are how I really feel and I'm just putting on an emotional mask most of the time.
Now I've sort of rebuilt my self esteme and I'm currently very happy as I have wonderful friends and my life is going well (and I watch MLP which always helps :P). However I still feel very fragile and have moments were I just feel depressed and suicidal and I worry that these moments are how I really feel and I'm just putting on an emotional mask most of the time.

That is not at all how it works.
I wish it were, but it's not. Being nice does not save you from the wrath of craziness, there are even some that will dislike you just for being a nice person. People are going to hate you no matter how you behave or look and there is nothing that you can ever do to prevent it. Sad, but true.
Keep working on being happy. After a few years of practice it will start to feel more real to you.
I just try to keep shifting my focus on the good things. It can be very difficult but I try and it does help