Closed dkorbar closed 10 years ago
Hello Luca,
thank you for your feedback.
I am quite aware that a lot of these parameters aren't really optional. But since those parameters were "any" before, I would consider introducing interfaces with non optional parameters a breaking change and I didn't want to introduce that because I thought there might have been a reason for those parameters to allow any kind of input. ;-)
Regarding the broadphase interface: There was a compilation error when I tried to put the interface there. I'll check that later and do the necessary changes.
Sorry for the late reply, my github issue tracker tends to be fairly flooded and things can fall through.
Technically its a breaking change to the API to make the fields non-optional. But should it actually break anyone's code, then their code was already broken in the first place, and this change brings the code in-line with documentation.
Regarding the broadphase, I'd actually revert your change there (Adding validate() implementation). That 'validate()' in the Physics2DBroadphase interface should not be there at all and should be removed, it is not a required/used, nor documented member of the interface.
If you could make that last little change (including removing the validate() from the interface), we'd be happy to merge this in.
No problem. Ok, makes sense! :-)
I just commited that change to the interface and class.
I have added interfaces for most of the create methods of the Physics2DDevice class (e.g. createPointConstraint) as was already done for some methods like createMaterial.
This improves development in Visual Studio as it enables auto completition for these methods.