What can you do if you are in love with your ex?

Omg i thought i was in love with my ex too for a long time but then I realized I just wanted to “win the breakup” and so i just put myself out there (both romantically with other distractions but also like trying to succeed in life with like my education, career, social life, etc) until i forgot about him