Skip to content

Commit

Permalink
hard code time step variable into step()
Browse files Browse the repository at this point in the history
  • Loading branch information
hymm committed Mar 15, 2021
1 parent 1f0c9a9 commit fb19e10
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions examples/game/breakout.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ use bevy::{
};

/// An implementation of the classic game "Breakout"
const TIME_STEP: f32 = 1.0 / 60.0;
fn main() {
App::build()
.add_plugins(DefaultPlugins)
Expand All @@ -16,7 +15,7 @@ fn main() {
.add_stage(
FixedUpdateStage,
SystemStage::parallel()
.with_run_criteria(FixedTimestep::step(TIME_STEP as f64))
.with_run_criteria(FixedTimestep::step(1.0 / 60.0))
.with_system(paddle_movement_system.system())
.with_system(ball_collision_system.system())
.with_system(ball_movement_system.system()),
Expand Down

0 comments on commit fb19e10

Please sign in to comment.