So I went for a walk and came back with a better solution, way less complicated than calculating the cg.
You see, if you calculate the centroid every time a character moves the screen will adjust to the position in between them and that will just screw up the whole game because the screen will be shaking like crazy all the time.
What i think you can do is :
1 - set your game to be played like Kirby, the camera follows a main player and the other players just have to deal with it.
2 - Set your camera to move depending on the furthest points. Compare the Xs and Ys of all characters take the smallest and biggest values and set the camera in the middle of those 4 points.
3 - Set the players to follow the camera, just like those beat them up games where the camera moves independently. The camera shows a challenge, when the players are done with the challenge the camera moves to another area and the players have to keep up with the camera until it gets into a new area where it freezes again.
4 - Set a camera fixed and work with boundaries. If ALL the players are to the right of the screen the screen will move to the right, if all of them are to the left, the screen follows. If the players are scattered all over the place, fix the camera and let them come to an agreement before proceeding.
Hope that helps to give you some ideas o/