aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorjacopograndi <jacopo.grandi@outlook.it>2022-08-01 23:18:38 +0200
committerjacopograndi <jacopo.grandi@outlook.it>2022-08-01 23:18:38 +0200
commit091160ba70f49ad700b70721c1fd9fbef7bb74ba (patch)
treeccecbd056a25a82126cfef799a367058bd4b9273 /src
parenteff66371bfe431e937419020e3ce6e6dfc45a4be (diff)
bevy_ggrs 0.8
Diffstat (limited to 'src')
-rw-r--r--src/main.rs11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs
index 909e174..d37fdde 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -8,6 +8,16 @@ use bevy::{prelude::*, render::camera::ScalingMode, window::WindowResized};
use bevy_rapier2d::{pipeline::CollisionEvent::*, prelude::*};
+/// i can step the rapier simulation by adding to the rollback systems
+/// the rapier system set. bevy_rapier provides 4 system sets.
+/// bevy_ggrs can take a schedule and a type, so no RapierContext
+/// in the schedule i can
+/// deserialize RapierContext
+/// run the game logic
+/// run the rapier systems
+/// serialize RapierContext
+/// the only problem is the first RapierContext, but default should be fine
+
fn main() {
App::new()
.insert_resource(WindowDescriptor {
@@ -53,7 +63,6 @@ fn camera_follow(
fn spawn_camera(mut commands: Commands) {
let mut camera = Camera2dBundle::default();
camera.projection.scaling_mode = ScalingMode::WindowSize;
- camera.projection.scale = 1.0;
camera.transform = Transform::from_xyz(0.0, 0.0, 100.0);
commands.spawn_bundle(camera);
}