-
-
Notifications
You must be signed in to change notification settings - Fork 208
Add Context to AnyCollider #665
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
379468d to
6e6a736
Compare
Co-authored-by: Gijs de Jong <[email protected]> Co-authored-by: aecsocket <[email protected]>
6e6a736 to
d983ac4
Compare
Jondolf
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks pretty good, mainly a few stylistic nits and documentation suggestions.
Just to be sure, I'll test later today if this has any measurable perf impact in the default case of an empty context, but I assume it should be basically zero-cost.
Jondolf
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good now! Thanks for the patience on this @NiseVoid and @oxkitsune, I've kept the collider context work sitting here for too long.
I made a couple more small changes just to clean things up, and also ran a quick test to see if this has any measurable perf impact. I didn't notice anything, so it should be good to go :)
Objective
Solution
SimpleCollidertrait that works for colliders with no context to shorten function signaturesChangelog
AnyCollider::ContextAnyCollidermethods, allowing data from theWorldto be fetched_with_colliderSimpleCollidertrait has been added to retain the simplified methods for colliders that don't need contextMigration Guide
ContextSystemParam, if this is unnecessary()should be usedAnyCollideron an implementation with()context,SimpleCollidershould be used insteadAnyColliderhave been suffixed with_with_context