Currently, many objects just have default constructors and then rely on the caller setting fields directly or calling utility methods. Eg, BodyDef, PolygonShape.
Instead, we should have constructors that fully specify fields. This will minimize the code the developer needs to write and help protect from subtle bugs where developers forget to set fields.
Currently, many objects just have default constructors and then rely on the caller setting fields directly or calling utility methods. Eg, BodyDef, PolygonShape.
Instead, we should have constructors that fully specify fields. This will minimize the code the developer needs to write and help protect from subtle bugs where developers forget to set fields.