When you like someone who doesn't like you

Rationally I know that we are probably never going to happen and I should be moved on already but idk how to.

I started liking this guy like a year or so ago and we have talked a few times and apparently he knew I liked him during all of this, so anyways a few months ago my guy friend told me that him and the guy talked and he doesn't like me.

So now whenever I see him I literally just dont know how to life. Like I hate myself for feeling like this. I don't want to go to school anymore or anything just seeing him makes me hate myself.

Anyone else ever feel like this?