Some people will love you as much as they can "use" you. Their loyalty ends when the benefits stop. Meaning, there are some people who pretend to love you just to use you and then dump you when they stop getting any benefit from you.
You can't control someone's loyalty. Despite how good you are to some people, they would never love or treat you the same way. There are also some people whose loyalty to you is strong and who love you beyond any reason, but the most important thing is for you to know the difference. You might have helped many people in your life, but when the help stopped, so did the friendship. They aren't there for the friendship but for the benefits and things they can gain from you.
Most people who have encountered this always think something is wrong with them. Just know that you are perfectly fine, and It is those people who are using you that are being selfish. They don't deserve either your love or attention. Choose to be your own priority, love yourself, and take care of yourself.