Skip to content

Commit 0d5185e

Browse files
Added note on need to call .drain to consume
1 parent e1142ad commit 0d5185e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

crates/bevy_ecs/src/event.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,7 @@ impl<'a, T: Component> EventReader<'a, T> {
347347
}
348348
}
349349

350-
/// Reads and consumes all events of type T
350+
/// Reads and consumes all events of type T when .drain or .drain_with_id are called
351351
///
352352
/// Useful for manual event cleanup when [AppBuilder::add_event::<T>] is omitted,
353353
/// allowing events to accumulate on your components or resources until consumed.

0 commit comments

Comments
 (0)