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

Update docs for Updated, Changed and Mutated #451

Merged
merged 2 commits into from
Sep 7, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Less clunky wording maybe?
  • Loading branch information
BoxyUwU committed Sep 6, 2020
commit 62573522723623c63cdc10d750be4a497250d12f
9 changes: 3 additions & 6 deletions crates/bevy_ecs/hecs/src/query.rs
Original file line number Diff line number Diff line change
Expand Up @@ -322,8 +322,7 @@ pub struct Or<T>(PhantomData<T>);
#[doc(hidden)]
pub struct FetchOr<T>(T);

/// Query transformer that skips entities that have a `T` component that has
/// not been mutated since the start of the frame.
/// Query transformer that retrieves components of type `T` that have been mutated since the start of the frame.
/// Added components do not count as mutated.
pub struct Mutated<'a, T> {
value: &'a T,
Expand Down Expand Up @@ -389,8 +388,7 @@ impl<'a, T: Component> Fetch<'a> for FetchMutated<T> {
}
}

/// Query transformer that skips entities with a `T` component that has
/// not been added since the start of the frame.
/// Query transformer that retrieves components of type `T` that have been added since the start of the frame.
pub struct Added<'a, T> {
value: &'a T,
}
Expand Down Expand Up @@ -453,8 +451,7 @@ impl<'a, T: Component> Fetch<'a> for FetchAdded<T> {
}
}

/// Query transformer that skips entities that have a 'T' component that has
/// not been either mutated or added since the start of the frame.
/// Query transformer that retrieves components of type `T` that have either been mutated or added since the start of the frame.
pub struct Changed<'a, T> {
value: &'a T,
}
Expand Down