Skip to content

Commit

Permalink
docs: use the read function for iterating over events (#290)
Browse files Browse the repository at this point in the history
Co-authored-by: Trevor Morris <[email protected]>
  • Loading branch information
tremorris1999 and tremorris1999 authored Jan 1, 2024
1 parent f4a5803 commit d7f0e8a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/plugins/collision/contact_reporting.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ use crate::prelude::*;
/// }
///
/// fn print_collisions(mut collision_event_reader: EventReader<Collision>) {
/// for Collision(contacts) in collision_event_reader.iter() {
/// for Collision(contacts) in collision_event_reader.read() {
/// println!(
/// "Entities {:?} and {:?} are colliding",
/// contacts.entity1,
Expand Down

0 comments on commit d7f0e8a

Please sign in to comment.