Fixed makeOutFile: No longer gives segmentation error, kudos to jaremikb. Confirmed that CelObj can write data to file! :)
Fixed segmentation error in addCelObj by copying arrays manually. However, some other crazy error occurs in addCelObj.
Replaced array bodies with vector bodies.
Fixed everything in addCelObj by using built in vector for storing bodies instead of manual array handling. Now it works, and I did it with 1 line instead of 20. FML.