Pickup ammo from dropped gun

So I’m stuck trying to figure out a way to take an equipped weapon and replenish it’s ammo by walking over a dropped weapon of the same type (Holding AK and replenish it’s ammo walking over dropped AK) I have a gun_parent and children that sets ammo by int and can be picked up by a basic interact interface. I’d appreciate any help to better understand how to solve this problem

It is your code… I don´t think that without exposing your code people can help you.