Skip to content
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

[Merged by Bors] - Removal detection cleanup #3010

Closed

Conversation

alice-i-cecile
Copy link
Member

Objective

Solution

  • Better docs!
  • Better tests!

Should check for both component removal and entity despawning.
@github-actions github-actions bot added the S-Needs-Triage This issue needs to be labelled label Oct 22, 2021
@alice-i-cecile alice-i-cecile added A-ECS Entities, components, systems, and events C-Code-Quality A section of code that is hard to understand or change C-Docs An addition or correction to our documentation S-Needs-Review and removed S-Needs-Triage This issue needs to be labelled labels Oct 22, 2021
@mockersf mockersf added S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it and removed S-Needs-Review labels Oct 27, 2021
/// note that the `RemovedComponents` list will not be automatically cleared for you,
/// and will need to be manually flushed using [`World::clear_trackers`]
///
/// For users of `bevy` itself, this is automatically done in a system added by `MinimalPlugins`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it should be mentioned that it's also added by DefaultPlugins, not just by MinimalPlugins

@alice-i-cecile
Copy link
Member Author

bors r+

bors bot pushed a commit that referenced this pull request Jan 5, 2022
# Objective

- Fixes #1920.
- Users often want to know how to get the values of removed components (#1655).
- Stand-alone `bevy_ecs` behavior is very unintuitive, as `World::clear_trackers()` must be manually called.
- Fixes #2999 by extending the existing test (thanks @hymm for pointing me to it) to be clearer and check for component removal as well.

## Solution

- Better docs!
- Better tests!
@bors bors bot changed the title Removal detection cleanup [Merged by Bors] - Removal detection cleanup Jan 5, 2022
@bors bors bot closed this Jan 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-ECS Entities, components, systems, and events C-Code-Quality A section of code that is hard to understand or change C-Docs An addition or correction to our documentation S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it
Projects
None yet
Development

Successfully merging this pull request may close these issues.

RemovedComponent removal detection has no tests RemovedComponents is missing documentation
3 participants