Help!!

So me and this guy have been a thing since 6th grade but it’s always been a on and off thing. He’s always played me and made me feel like shit. But I cannot stay away from him. He always “wants” me while I have a boyfriend but once I’m single it’s like he becomes uninterested and when we hangout he tries to kiss on me he tells me he loves me and I’m the only girl he talks to but once I’m not with him it’s like I don’t mean anything to him. I really like him but I don’t know how to stay away from him. What should I do?