From c3343b1667e50a3c17e8e2e4ccd35a815338b6e0 Mon Sep 17 00:00:00 2001 From: yuni Date: Wed, 20 Nov 2024 00:03:35 +0100 Subject: [PATCH] experimentally, use variable timing for physics calculations --- src/world.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/world.rs b/src/world.rs index 6ef0144..d0530ab 100644 --- a/src/world.rs +++ b/src/world.rs @@ -51,6 +51,7 @@ impl Plugin for WorldPlugin { ); app.add_plugins(PhysicsPlugins::default()); //app.add_plugins(PhysicsDebugPlugin::default()); + app.insert_resource(Time::new_with(Physics::variable(1.0 / 30.0))); app.insert_resource(Gravity(DVec3::splat(0.0))); app.insert_resource(ActiveAsteroids(HashMap::new())); app.add_event::();