Hands-on Rust: Missing Build Scheduler update in Collision Detection at the end of CH6

Apologies again for missing page number, reading this as an epub and having trouble finding it.

Right before we start writing collisions.rs it mentions to add mod collisions; to the top of mod.rs
We are also missing the call to add the collision system to the Schedule builder, this results in the new collision code not getting called.
From the sample code we need to add this:

Schedule::builder()
          .add_system(player_input::player_input_system())
          .add_system(collisions::collisions_system())
          .add_system(map_render::map_render_system())
          .add_system(entity_render::entity_render_system())
          .build()

And then it works fine.

1 Like