How to make characters overlap each other but when they do they push away from each other

i found a solution it is to on character capsule component overlap add them to an array of all overlapping characters then on tick iterate through them creating an average from all of the character positions and move in that direction here it is bellow i