IntegrationParameters
is inconvenient to configure at startup due to private fields on RapierContext
#503
Labels
A-Integration
very bevy specific
C-Enhancement
New feature or request
D-Easy
P-Medium
S-not-started
Work has not started
I was trying to configure the number of solver iterations, which reside in
IntegrationParameters
, stored in theRapierContext
resource. Like how most resources in Bevy are typically configured at start-up, I tried inserting the resource:The property spread operation fails, because there are several private fields. There also doesn't seem to be a way to configure the integration parameters directly through a constructor or builder method.
Instead, an intermediary variable needs to be created for the
RapierContext
.This isn't immediately obvious, and it's different from how resources are typically configured.
Compare this to changing the substep count in e.g. bevy_xpbd:
Either the fields on
RapierContext
should be made public, or (preferably) theIntegrationParameters
should be extracted into their own resource.The text was updated successfully, but these errors were encountered: