What adult? A total stranger? A family member?
Why would someone want to tell you that you've gained weight? (Unless of course, you asked them?)
Do you feel happy with whatever your current weight is? Even if you do not have a scale, do you like the way you feel, are you healthy, do you have fun, do you like the way your clothes fit?
If you do, then ignore whatever that person was telling you, tell them thank you very much but your weight is not a topic that is up for public discussion, and do what feels right for your own body.
You'll know, just by paying attention to your own body, and how comfortable you are in your own skin. That is the ultimate measure.