i have studied a lot about collision filtering using categories and masks and groups. they involve prevention of collision between related object while they do collide with opposite group. my case is totally different i have two groups and i want they should collide within the group so that bodies of different group can't collide with bodies of opposite group.
for example all blue balls can collide with each other and red ones with red ones. no blue ball can collide with red ball. any thoughts on this